1.补充生成放款明细时逻辑判断(每个流程只能生成同一种放款方式的合同)
This commit is contained in:
parent
dc410b541d
commit
8edeebae64
@ -47,7 +47,15 @@
|
||||
AsDebug.showMessage("提示","每次只能生成放款方式相同的合同!","","",true);
|
||||
return;
|
||||
}
|
||||
contractIds += "@"+getItemValue(0,rows[i],"ID");
|
||||
var result0 = RunJavaMethodTrans("com.tenwa.flow.fund.fundcollection.FundIncomeMethod","check","flowunid=<%=flowunid%>"+",payType="+payType);
|
||||
if(result0=="0"){
|
||||
contractIds += "@"+getItemValue(0,rows[i],"ID");
|
||||
}else{
|
||||
AsDebug.showMessage("提示","每次只能生成放款方式相同的合同!","","",true);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
contractIds = contractIds.substring(1);
|
||||
var result = RunJavaMethodTrans("com.tenwa.flow.fund.fundcollection.FundIncomeMethod","createActualPayment","contractIds="+contractIds+",flowunid=<%=flowunid%>,userId=<%=CurUser.getUserID()%>,orgId=<%=CurUser.getOrgID()%>"+",payType="+payType);
|
||||
|
||||
@ -13,6 +13,7 @@ import jbo.app.tenwa.calc.LC_FUND_INCOME_TEMP;
|
||||
import jbo.app.tenwa.calc.LC_FUND_PLAN;
|
||||
import jbo.app.tenwa.calc.VI_LC_FUND_PLAN;
|
||||
import jbo.com.tenwa.entity.comm.own.OWN_ACCOUNT;
|
||||
import jbo.com.tenwa.lease.comm.LB_PROJECT_INFO;
|
||||
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
@ -447,6 +448,26 @@ public class FundIncomeMethod {
|
||||
// double CerificationMoney= Double.valueOf(corpus)+Double.valueOf(interest)+Double.valueOf(penalty);
|
||||
return c.doubleValue()+"";
|
||||
}
|
||||
|
||||
public String check(JBOTransaction tx) throws Exception{
|
||||
String sql = "SELECT lfit.project_id,lpi.product_id,psl.paytype AS payType FROM"+
|
||||
"lc_fund_income_temp lfit "+
|
||||
"LEFT JOIN lb_project_info lpi ON lfit.project_id=lpi.id "+
|
||||
"LEFT JOIN PRD_SPECIFIC_LIBRARY psl ON psl.productid=lpi.product_id"+
|
||||
"WHERE lfit.flowunid=:flowunid";
|
||||
Map<String,String> params=new HashMap<String,String>();
|
||||
params.put("flowunid", flowunid);
|
||||
List<Map<String, String>> payTypeList = DataOperatorUtil.getDataBySql(tx,sql,params);
|
||||
if(payTypeList.size()<1){
|
||||
return "0";
|
||||
}
|
||||
for(Map<String, String> payType:payTypeList){
|
||||
String paytype = payType.get("payType");
|
||||
if(this.payType.equals(paytype)){
|
||||
return "0";
|
||||
}
|
||||
return "1";
|
||||
}
|
||||
return "1";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user