|
- package svc
-
- import (
- "applet/app/db"
- )
-
- func EnterpriseDelete(enterpriseIds []int) (err error) {
- session := db.Db.NewSession()
- defer session.Close()
- session.Begin()
- //1、删除所在单位
- enterpriseDb := db.EnterpriseDb{}
- enterpriseDb.Set()
- _, err = enterpriseDb.EnterpriseDeleteBySession(session, enterpriseIds)
- if err != nil {
- _ = session.Rollback()
- return
- }
-
- return session.Commit()
- }
|