chart_edb_config.go 505 B

12345678910111213141516171819
  1. package data
  2. import (
  3. "eta_gn/eta_api/models/data_manage"
  4. "fmt"
  5. )
  6. // BatchAddNoPermissionAdmin 批量添加配置
  7. func BatchAddNoPermissionAdmin(edbInfoIdList []int, adminIdList []int) (err error) {
  8. errMsgList := make([]string, 0)
  9. for _, edbInfoId := range edbInfoIdList {
  10. obj := data_manage.EdbInfoNoPermissionAdmin{}
  11. err = obj.AddByEdbInfoId(edbInfoId, adminIdList)
  12. if err != nil {
  13. errMsgList = append(errMsgList, fmt.Sprint(edbInfoId, "指标添加失败,err:", err))
  14. }
  15. }
  16. return
  17. }