github.com/SupenBysz/gf-admin-community@v0.7.4/sys_service/sys_person_lincense.go (about) 1 // ================================================================================ 2 // Code generated and maintained by GoFrame CLI tool. DO NOT EDIT. 3 // You can delete these comments if you wish manually maintain this interface file. 4 // ================================================================================ 5 6 package sys_service 7 8 import ( 9 "context" 10 11 "github.com/SupenBysz/gf-admin-community/sys_model" 12 "github.com/SupenBysz/gf-admin-community/sys_model/sys_entity" 13 "github.com/SupenBysz/gf-admin-community/sys_model/sys_enum" 14 "github.com/kysion/base-library/base_model" 15 ) 16 17 type ( 18 ISysPersonLicense interface { 19 // GetAuditData 订阅审核数据获取Hook, 将审核数据渲染成个人资质然后进行输出 20 GetAuditData(ctx context.Context, auditEvent sys_enum.AuditEvent, info *sys_entity.SysAudit) error 21 // AuditChange 审核成功的处理逻辑 Hook 22 AuditChange(ctx context.Context, auditEvent sys_enum.AuditEvent, info *sys_entity.SysAudit) error 23 // GetLicenseById 根据ID获取个人资质认证|信息 24 GetLicenseById(ctx context.Context, id int64) (*sys_entity.SysPersonLicense, error) 25 // QueryLicenseList 查询个人资质认证|列表 26 QueryLicenseList(ctx context.Context, search base_model.SearchParams) (*sys_model.PersonLicenseListRes, error) 27 // CreateLicense 新增个人资质|信息 28 CreateLicense(ctx context.Context, info sys_model.AuditPersonLicense) (*sys_entity.SysPersonLicense, error) 29 // UpdateLicense 更新个人资质认证,如果是已经通过的认证,需要重新认证通过后才生效|信息 30 UpdateLicense(ctx context.Context, info sys_model.AuditPersonLicense, id int64) (*sys_entity.SysPersonLicense, error) 31 // GetLicenseByLatestAuditId 获取最新的审核记录Id获取资质信息 32 GetLicenseByLatestAuditId(ctx context.Context, auditId int64) *sys_entity.SysPersonLicense 33 // SetLicenseState 设置个人资质信息状态 -1未通过 0待审核 1通过 34 SetLicenseState(ctx context.Context, id int64, state int) (bool, error) 35 // SetLicenseAuditNumber 设置个人资质神审核编号 36 SetLicenseAuditNumber(ctx context.Context, id int64, auditNumber string) (bool, error) 37 // DeleteLicense 删除个人资质 38 DeleteLicense(ctx context.Context, id int64, flag bool) (bool, error) 39 // UpdateLicenseAuditLogId 设置个人资质资质关联的审核ID 40 UpdateLicenseAuditLogId(ctx context.Context, id int64, latestAuditLogId int64) (bool, error) 41 // Masker 资质信息脱敏 42 Masker(license *sys_entity.SysPersonLicense) *sys_entity.SysPersonLicense 43 } 44 ) 45 46 var ( 47 localSysPersonLicense ISysPersonLicense 48 ) 49 50 func SysPersonLicense() ISysPersonLicense { 51 if localSysPersonLicense == nil { 52 panic("implement not found for interface ISysPersonLicense, forgot register?") 53 } 54 return localSysPersonLicense 55 } 56 57 func RegisterSysPersonLicense(i ISysPersonLicense) { 58 localSysPersonLicense = i 59 }