animeic 2 年之前
父節點
當前提交
9d35a159e7
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      boxcost/api/bill.go

+ 3 - 0
boxcost/api/bill.go

@@ -315,6 +315,9 @@ func UpdateBill(c *gin.Context, apictx *ApiSession) (interface{}, error) {
 	if bill.Status == "complete" {
 		bill.CompleteTime = time.Now()
 	}
+	if bill.Remark == "" {
+		bill.Remark = " "
+	}
 
 	bill.UpdateTime = time.Now()
 	return repo.RepoUpdateSetDoc(apictx.CreateRepoCtx(), repo.CollectionBillPurchase, bill.Id.Hex(), &bill)