1
This commit is contained in:
@@ -36,6 +36,7 @@ def OnPreparePropertys(e):
|
|||||||
e.FieldKeys.Add("FBillAllAmount");
|
e.FieldKeys.Add("FBillAllAmount");
|
||||||
e.FieldKeys.Add("F_SFYFH");
|
e.FieldKeys.Add("F_SFYFH");
|
||||||
e.FieldKeys.Add("FSaleOrgId");
|
e.FieldKeys.Add("FSaleOrgId");
|
||||||
|
e.FieldKeys.Add("FDocumentStatus");
|
||||||
|
|
||||||
def BeforeDoSaveExecute(e):
|
def BeforeDoSaveExecute(e):
|
||||||
# if this.FormOperation.OperationId == 8:
|
# if this.FormOperation.OperationId == 8:
|
||||||
@@ -82,12 +83,13 @@ WHERE t0.FID IN ({0})
|
|||||||
if res != None and res.Count > 0:
|
if res != None and res.Count > 0:
|
||||||
# raise Exception(JsonUtil.Serialize(res))
|
# raise Exception(JsonUtil.Serialize(res))
|
||||||
item = res[0]
|
item = res[0]
|
||||||
|
|
||||||
currAmount = entity["SAL_DELIVERYNOTICEFIN"][0]["BillAllAmount"]
|
if entity["SAL_DELIVERYNOTICEFIN"] != None and entity["SAL_DELIVERYNOTICEFIN"].Count > 0:
|
||||||
# raise Exception(str(currAmount))
|
currAmount = entity["SAL_DELIVERYNOTICEFIN"][0]["BillAllAmount"]
|
||||||
isYFHFlag = item["累计核销金额"] < item["款到发货应收金额"]
|
# raise Exception(str(currAmount))
|
||||||
isYFHFlag1 = isYFHFlag == True and (item["收款计划条数"] == 1)
|
isYFHFlag = item["累计核销金额"] < item["款到发货应收金额"]
|
||||||
isYFHFlag2 = isYFHFlag == True and (True if isYFHFlag1 else ((item["累计核销金额"] - item["累计已发货金额"]) < currAmount))
|
isYFHFlag1 = isYFHFlag == True and (item["收款计划条数"] == 1)
|
||||||
entity["F_SFYFH"] = '是' if isYFHFlag2 == True else '否'
|
isYFHFlag2 = isYFHFlag == True and (True if isYFHFlag1 else ((item["累计核销金额"] - item["累计已发货金额"]) < currAmount))
|
||||||
|
entity["F_SFYFH"] = '是' if isYFHFlag2 == True else '否'
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|||||||
Reference in New Issue
Block a user