feat:注释不用的代码
This commit is contained in:
@ -119,7 +119,7 @@ func (c *Demand) Form(params *DemandParams) error {
|
||||
return err
|
||||
} else if !isExist {
|
||||
return errors.New("操作错误,数据不存在")
|
||||
} else if mTechnologyDemand.UID != c.ManageUID {
|
||||
} else if mTechnologyDemand.MUid != c.ManageUID {
|
||||
return errors.New("无权限操作")
|
||||
} else if mTechnologyDemand.Status != model2.TechnologyDemandStatusForRefuse &&
|
||||
mTechnologyDemand.Status != model2.TechnologyDemandStatusForDraft {
|
||||
@ -156,7 +156,7 @@ func (c *Demand) Form(params *DemandParams) error {
|
||||
return model2.Updates(mTechnologyDemand.TechnologyDemand, mTechnologyDemand.TechnologyDemand)
|
||||
}
|
||||
mTechnologyDemand.TenantID = c.TenantID
|
||||
mTechnologyDemand.UID = c.ManageUID
|
||||
mTechnologyDemand.MUid = c.ManageUID
|
||||
mTechnologyDemand.Local.Local = c.local
|
||||
return model2.Create(mTechnologyDemand.TechnologyDemand)
|
||||
}
|
||||
@ -172,7 +172,7 @@ func (c *Demand) Delete(id uint64) error {
|
||||
return err
|
||||
} else if !isExist {
|
||||
return errors.New("操作错误,数据不存在")
|
||||
} else if mTechnologyDemand.UID != c.ManageUID {
|
||||
} else if mTechnologyDemand.MUid != c.ManageUID {
|
||||
return errors.New("无权限操作")
|
||||
}
|
||||
if err = model2.Delete(mTechnologyDemand.TechnologyDemand); err != nil {
|
||||
|
Reference in New Issue
Block a user