Commit cf4bcc92 authored by 李贺贺's avatar 李贺贺

Merge branch 'feature/授信额度占用相关功能' into develop

# Conflicts:
#	src/main/webapp/modules/prj/PRJ500N/prj_project_create.lview
parents 7c9a9149 bffcaa5e
......@@ -20,7 +20,9 @@
p_save_source_type =>${@save_source_type},
p_project_status =>${@project_status},
p_bp_id_tenant =>${@bp_id_tenant},
p_cdd_list_id => ${@cdd_list_id});
p_cdd_list_id => ${@cdd_list_id},
p_editable_flag =>${@editable_flag},
p_credit_line =>${@credit_line});
END;
]]></bm:update-sql>
</bm:operation>
......
......@@ -37,7 +37,8 @@
rd.enable_flag,
to_char(rd.last_update_date,'yyyy-mm-dd')last_update_date,
(select description from sys_user s where s.user_id= rd.created_by)last_updated_by_desc,
(select description from sys_user s where s.user_id= rd.temp_user)temp_user_desc
(select description from sys_user s where s.user_id= rd.temp_user)temp_user_desc,
(select v.unit_name from exp_emp_assign_e_v v where v.unit_id = hbm.unit_id and rownum = 1) agent_name
from HLS_BP_MASTER_CREDIT_HD hd,
hls_bp_master hbm,
......
<?xml version="1.0" encoding="UTF-8"?>
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
SELECT r1.employee_type_code
FROM EXP_EMPLOYEES t1, EXP_EMPLOYEE_TYPES_VL r1
WHERE t1.EMPLOYEE_TYPE_ID = r1.EMPLOYEE_TYPE_ID
AND t1.employee_id =
(SELECT su.employee_id FROM sys_user su WHERE su.user_id = ${/session/@user_id})
]]>
</bm:query-sql>
</bm:operation>
</bm:operations>
</bm:model>
<?xml version="1.0" encoding="UTF-8"?>
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
SELECT h.bp_name, h.bp_code, h.bp_id
FROM exp_emp_assign_e_v ee, hls_bp_master h
WHERE ee.user_id = (SELECT zw.submitted_by
FROM zj_wfl_workflow_instance zw
WHERE zw.instance_id = ${/parameter/@instance_id})
AND ee.unit_id = h.unit_id
AND h.bp_category = 'AGENT'
]]>
</bm:query-sql>
</bm:operation>
</bm:operations>
</bm:model>
\ No newline at end of file
......@@ -29,8 +29,9 @@
<a:fieldSet labelWidth="150" style="margin-left:20px">
<a:grid id="hls_bp_master_credit_result_grid_ds" bindTarget="hls_bp_master_credit_result_ds" marginHeight="165" marginWidth="100" navBar="true" >
<a:columns>
<a:column name="bp_code" prompt="代理店编码" align="center" width="120"/>
<a:column name="bp_name" prompt="代理店名称" align="center" width="170"/>
<a:column name="bp_code" prompt="授信对象编码" align="center" width="120"/>
<a:column name="bp_name" prompt="授信对象名称" align="center" width="170"/>
<a:column name="agent_name" prompt="代理店名称" align="center" width="170"/>
<a:column name="credit_total_amount" prompt="授信总额度" align="center" width="200" renderer="Leaf.formatMoney"/>
<a:column name="credit_date_from" prompt="授信日期从" align="center" width="120"/>
<a:column name="credit_date_to" prompt="授信日期到" width="110" align="center"/>
......
......@@ -13,6 +13,7 @@
<a:model-query fetchAll="true" model="prj.PRJ500D.amount_check" rootPath="amount_check"/>
<a:model-query defaultWhereClause="v.role_id = ${/session/@role_id} and v.role_code in (&apos;HAND&apos;,&apos;0017&apos;)" model="zjwfl.sys_role_flag" rootPath="role_flag_path"/>
<a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/>
<a:model-query fetchAll="true" model="prj.PRJ500D.prj_project_get_description" rootPath="description"/>
<s:server-script import="contract_print_path.js"><![CDATA[
$ctx.parameter.file_path = con_print_path['con_print_path'];
$ctx.parameter.tomcat_source = con_print_path['tomcat_source'];
......@@ -636,6 +637,33 @@
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_BRANCH_CODE_prompt').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_BRANCH_CODE').style.display = 'none';
}
//星邦高空作业车 默认承租人为只读;
//厦门恒立兴、福州恒立兴、三明恒立兴、江西恒立兴 可选为必填;
//其它代理店不展示该字段,默认为代理店;
debugger;
//获取员工类型
var description = '${/model/description/record/@employee_type_code}';
var bp_code='${/model/user_agent_description/record/@bp_code}';
if(!Ext.isEmpty(description) && description == 'AGENT'){
if(!Ext.isEmpty(bp_code)){
if(bp_code !== 'C00010180' && bp_code !== 'C00010175' && bp_code !== 'C00010176' && bp_code !== 'C00010187'){
if(bp_code =='D00010001'){
record.set('credit_line','TENANT');
record.set('credit_line_n','承租人');
record.getField('credit_line').setRequired(false);
record.getField('credit_line_n').setRequired(false);
record.getField('credit_line').setReadOnly(true);
record.getField('credit_line_n').setReadOnly(true);
}else {
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE_prompt').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE').style.display = 'none';
}
}
}
}else {
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE_prompt').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE').style.display = 'none';
}
//新增 “限制金额”字段;
//“扣款限额”:“租金支付方式”为“建行扣款(三方)”时展示,必填,大于0,默认20万,可修改;
......
......@@ -14,6 +14,7 @@
defaultWhereClause="v.role_id = ${/session/@role_id} and v.role_code in (&apos;HAND&apos;,&apos;0017&apos;)"
model="zjwfl.sys_role_flag" rootPath="role_flag_path"/>
<a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/>
<a:model-query fetchAll="true" model="prj.PRJ500D.prj_project_get_description" rootPath="description"/>
<s:server-script import="contract_print_path.js"><![CDATA[
$ctx.parameter.file_path = con_print_path['con_print_path'];
$ctx.parameter.tomcat_source = con_print_path['tomcat_source'];
......@@ -943,8 +944,36 @@
record.getField('branch_code').setRequired(false);
record.getField('branch_code_n').setRequired(false);
}
//获取员工类型
debugger;
var description = '${/model/description/record/@employee_type_code}';
var bp_code='${/model/user_agent_description/record/@bp_code}';
var credit_record = $(ds_id).getCurrentRecord();
if(!Ext.isEmpty(description) && description == 'AGENT'){
if(!Ext.isEmpty(bp_code)){
if(bp_code !== 'C00010180' && bp_code !== 'C00010175' && bp_code !== 'C00010176' && bp_code !== 'C00010187'){
if(bp_code =='D00010001'){
credit_record.set('credit_line','TENANT');
credit_record.set('credit_line_n','承租人');
credit_record.getField('credit_line').setReadOnly(true);
credit_record.getField('credit_line_n').setReadOnly(true)
credit_record.getField('credit_line').setRequired(false);
credit_record.getField('credit_line_n').setRequired(false);
}else {
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE_prompt').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE').style.display = 'none';
}
}
}
}else {
credit_record.getField('credit_line').setReadOnly(true);
credit_record.getField('credit_line_n').setReadOnly(true);
credit_record.getField('credit_line').setRequired(false);
credit_record.getField('credit_line_n').setRequired(false);
}
}
if (prj_quotation_ds_id == ds.id && ds_id){
if (prj_quotation_ds_id == ds.id && prj_quotation_ds_id){
var bp_code = '${/model/user_agent_description/record/@bp_code}';
if (!Ext.isEmpty(bp_code)){
// if (bp_code == 'C00010168' || bp_code == 'C00010198' || bp_code == 'C00010170') {
......@@ -982,6 +1011,7 @@
}
}
}
document.getElementById('${/parameter/@layout_code}_save').style.display = "none";
};
//pdf预览 add by zhuxianfei
......
......@@ -11,6 +11,7 @@
<a:model-query defaultWhereClause="t1.user_id=${/session/@user_id}" model="prj.PRJ500D.sys_user_lv"
rootPath="user_name_path"/>
<a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/>
<a:model-query fetchAll="true" model="zjwfl.ZJWFL1060.zi_wfl_approve_get_submitted" rootPath="approve_history_rp"/>
<s:server-script import="contract_print_path.js"><![CDATA[
$ctx.parameter.file_path = con_print_path['con_print_path'];
$ctx.parameter.tomcat_source = con_print_path['tomcat_source'];
......@@ -794,8 +795,38 @@
record.getField('branch_code').setRequired(false);
record.getField('branch_code_n').setRequired(false);
}
//获取员工类型
var create_bp_code = '${/model/approve_history_rp/record/@bp_code}';
var credit_record = $(ds_id).getCurrentRecord();
if(!Ext.isEmpty(create_bp_code)){
debugger;
if(create_bp_code == 'C00010180' || create_bp_code == 'C00010175' || create_bp_code == 'C00010176' || create_bp_code == 'C00010187'){
if('${/parameter/@editable_flag}' == 'Y' || '${/parameter/@editable_flag}' == 'YE'){
credit_record.getField('credit_line').setReadOnly(false);
credit_record.getField('credit_line_n').setReadOnly(false);
credit_record.getField('credit_line').setRequired(true);
credit_record.getField('credit_line_n').setRequired(true);
record.set('editable_flag','Y');
}else {
document.getElementById('${/parameter/@layout_code}_save').style.display = "none";
}
}else if(create_bp_code =='D00010001') {
credit_record.getField('credit_line').setReadOnly(true);
credit_record.getField('credit_line_n').setReadOnly(true);
credit_record.getField('credit_line').setRequired(false);
credit_record.getField('credit_line_n').setRequired(false);
document.getElementById('${/parameter/@layout_code}_save').style.display = "none";
}else {
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE_prompt').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_F_BASIC_INFO_1_PRJ_PROJECT_CREDIT_LINE').style.display = 'none';
document.getElementById('${/parameter/@layout_code}_save').style.display = "none";
}
if('${/parameter/@editable_flag}' == 'YE'){
document.getElementById('${/parameter/@layout_code}_save').style.display = "block";
}
}
if (prj_quotation_ds_id == ds.id && ds_id){
}
if (prj_quotation_ds_id == ds.id && prj_quotation_ds_id){
var bp_code = '${/model/user_agent_description/record/@bp_code}';
if (!Ext.isEmpty(bp_code)){
// if (bp_code == 'C00010168' || bp_code == 'C00010198' || bp_code == 'C00010170') {
......@@ -825,7 +856,23 @@
}
}
};
if('${/parameter/@editable_flag}' == 'Y' || '${/parameter/@editable_flag}' == 'YE'){
zjwfl5110_ApproveChecker_add('zjwfl5110_submit', function (type) {
var prj_project_ds = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'F_BASIC_INFO_1', 'prj_project');
if (type == 'agree') {
if ($(prj_project_ds).validate()) {
if ($(prj_project_ds).isModified()) {
Leaf.showMessage('${HLS.PROMPT}', '请先保存');
return false;
}
//提交先保存
return true;
} else {
return false;
}
} else return true;
});
}
//更新时调用
window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_update'] = function (ds, record, name, value, old_value, bp_seq) {
//选择承租人带出开票信息
......@@ -907,6 +954,9 @@
}
record.getField('bank_account_id').setLovPara('bp_id_tenant', record.get('bp_id_tenant'));
}
if(name == 'credit_line' && value) {
$(prj_project_ds_id).get(0).set('credit_line',value);
}
}
if (name == 'pay_method') {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment