feat:完善项目信息
This commit is contained in:
@ -46,10 +46,10 @@ func (c *Industry) tree(src []*model2.SysIndustry, parentID uint64) []*IndustryI
|
||||
|
||||
// Instance 首页信息
|
||||
func (c *Industry) Instance() ([]*IndustryInfo, error) {
|
||||
mSysIndustry := new(model.SysIndustry)
|
||||
mSysIndustry := model.NewSysIndustry()
|
||||
out := make([]*model2.SysIndustry, 0)
|
||||
|
||||
if err := model2.ScanFields(mSysIndustry.SysIndustry, out, []string{"id", "parent_id", "name"}); err != nil {
|
||||
if err := model2.ScanFields(mSysIndustry.SysIndustry, &out, []string{"id", "parent_id", "name"}); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return c.tree(out, 0), nil
|
||||
|
Reference in New Issue
Block a user