|
@@ -354,6 +354,13 @@ func (c *ReimburseController) Reimburse_Edit() {
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ if body.T_money == 0 {
|
|
|
|
+ o.Rollback()
|
|
|
|
+ c.Data["json"] = lib.JSONS{Code: 202, Msg: "报销金额不能为0"}
|
|
|
|
+ c.ServeJSON()
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+
|
|
reimburse.T_money = body.T_money
|
|
reimburse.T_money = body.T_money
|
|
_, err = ReimburseDao.Update_Reimburse(reimburse, "T_money")
|
|
_, err = ReimburseDao.Update_Reimburse(reimburse, "T_money")
|
|
if err != nil {
|
|
if err != nil {
|
|
@@ -502,6 +509,12 @@ func (c *ReimburseController) Reimburse_Submit_Audit() {
|
|
c.ServeJSON()
|
|
c.ServeJSON()
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
+ if reimburse.T_money == 0 {
|
|
|
|
+ c.Data["json"] = lib.JSONS{Code: 202, Msg: "报销总金额为0,请检查!"}
|
|
|
|
+ c.ServeJSON()
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+
|
|
if c.User.T_uuid != reimburse.T_uid {
|
|
if c.User.T_uuid != reimburse.T_uid {
|
|
c.Data["json"] = lib.JSONS{Code: 202, Msg: "没有权限!"}
|
|
c.Data["json"] = lib.JSONS{Code: 202, Msg: "没有权限!"}
|
|
c.ServeJSON()
|
|
c.ServeJSON()
|