Commit 31121ce3 authored by lizhe's avatar lizhe

Merge remote-tracking branch 'origin/develop' into develop

parents 318553e8 612a4afe
...@@ -116,7 +116,7 @@ ...@@ -116,7 +116,7 @@
</bm:primary-key> </bm:primary-key>
<bm:data-filters> <bm:data-filters>
<bm:data-filter name="query" expression="(t1.company_id=${/session/@company_id} and t1.posted_flag=&apos;Y&apos; and t1.reversed_flag=&apos;N&apos; and returned_flag not in ( &apos;RETURN&apos;) and t1.transaction_type in (&apos;RECEIPT&apos;,&apos;ADVANCE_RECEIPT&apos;) and (nvl(t1.returned_amount, 0)+nvl(t1.write_off_amount, 0)&lt;=t1.transaction_amount)) "/> <bm:data-filter name="query" expression="(t1.company_id=${/session/@company_id} and t1.posted_flag=&apos;Y&apos; and t1.reversed_flag=&apos;N&apos; and returned_flag not in ( &apos;RETURN&apos;) and t1.transaction_type in (&apos;RECEIPT&apos;,&apos;ADVANCE_RECEIPT&apos;) and (nvl(t1.returned_amount, 0)+nvl(t1.write_off_amount, 0)&lt;=t1.transaction_amount)) "/>
<!-- <bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;) and t1.write_off_flag in(&apos;NOT&apos;,&apos;PARTIAL&apos;))"/>--> <!-- <bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;) and t1.write_off_flag in(&apos;NOT&apos;,&apos;PARTIAL&apos;))"/>-->
<bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;))"/> <bm:data-filter name="query" expression="(t1.confirmed_flag not in (&apos;ACCAUDITING&apos;,&apos;NEW&apos;,&apos;CT_REJECTED&apos;))"/>
</bm:data-filters> </bm:data-filters>
<bm:query-fields> <bm:query-fields>
......
...@@ -119,7 +119,8 @@ ...@@ -119,7 +119,8 @@
||record_data.templet_code == 'CON_CONTRACT_LEASE_BACK'||record_data.templet_code == 'CON_CONTRACT_MORTGAGE'||record_data.templet_code == 'FINANCE_LEASE_CONTRACT_FIN' ||record_data.templet_code == 'CON_CONTRACT_LEASE_BACK'||record_data.templet_code == 'CON_CONTRACT_MORTGAGE'||record_data.templet_code == 'FINANCE_LEASE_CONTRACT_FIN'
||record_data.templet_code == 'FINANCE_LEASE_CONTRACT_FIN_A4'||record_data.templet_code =='FINANCE_LEASE_CONTRACT_TJ'||record_data.templet_code =='CON_CONTRACT_MORTGAGE_TJ' ||record_data.templet_code == 'FINANCE_LEASE_CONTRACT_FIN_A4'||record_data.templet_code =='FINANCE_LEASE_CONTRACT_TJ'||record_data.templet_code =='CON_CONTRACT_MORTGAGE_TJ'
||record_data.templet_code =='FINANCE_LEASE_CONTRACT_TJ_SURE'||record_data.templet_code =='FINANCE_LEASE_CONTRACT_TJ_FR' ||record_data.templet_code =='FINANCE_LEASE_CONTRACT_TJ_SURE'||record_data.templet_code =='FINANCE_LEASE_CONTRACT_TJ_FR'
||record_data.templet_code =='FINANCE_LEASE_CONTRACT_D_ESWJ' ||record_data.templet_code =='BUSINESS_CONTRACT_D_ESWJ_OEC'||record_data.templet_code =='BUSINESS_CONTRACT_D_ESWJ') { ||record_data.templet_code =='FINANCE_LEASE_CONTRACT_D_ESWJ' ||record_data.templet_code =='BUSINESS_CONTRACT_D_ESWJ_OEC'||record_data.templet_code =='BUSINESS_CONTRACT_D_ESWJ'
||record_data.templet_code =='FINANCE_LEASE_CONTRACT_FR_TJ') { //update by xsh35973 添加法人铁甲保证函
// word转pdf // word转pdf
var pdf_file_path=datePath+guid_file_name_tables[0].guid_file_name + 'con_' + record_data.content_id; var pdf_file_path=datePath+guid_file_name_tables[0].guid_file_name + 'con_' + record_data.content_id;
......
...@@ -829,6 +829,39 @@ ...@@ -829,6 +829,39 @@
} }
} }
} }
var role_ds = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_role');
if (role_ds == ds.id) {
var bp_type_flag='N';
var records = $(ds.id).getAll();
if(name=='bp_type'){
for (var i = 0;i < records.length;i++) {
if(records[i].get('bp_type')=='TENANT'){
bp_type_flag='Y';
}
}
if(bp_type_flag=='Y'){
for (var i = 0;i < records.length;i++) {
if(records[i].get('bp_type')=='TENANT'){
records[i].set('primary_flag','Y')
}else{
records[i].set('primary_flag','N')
}
}
}
}
var primary_flag = record.get('primary_flag');
if (primary_flag == 'Y') {
var bm_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
var bm_record = $(bm_ds_id).getCurrentRecord();
bm_record.set('bp_type', record.get('bp_type'));
bm_record.set('bp_type_n', record.get('bp_type_n'));
bm_record.set('bp_category', record.get('bp_category'));
bm_record.set('bp_category_n', record.get('bp_category_n'));
}
}
}; };
function upload_file(id, name, query_only) { function upload_file(id, name, query_only) {
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
<a:init-procedure> <a:init-procedure>
<a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/> <a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/>
<a:model-query fetchAll="true" model="hls.HLS214N.hls_bp_master_modify_user" rootPath="modify_user"/> <a:model-query fetchAll="true" model="hls.HLS214N.hls_bp_master_modify_user" rootPath="modify_user"/>
<a:model-query model="cont.CON620.get_sys_role" rootPath="role_info"/>
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="bank_account_num_link" model="hls.HLS214.hls_bp_bank_account_num" modelaction="update"/> <a:link id="bank_account_num_link" model="hls.HLS214.hls_bp_bank_account_num" modelaction="update"/>
...@@ -46,6 +47,22 @@ ...@@ -46,6 +47,22 @@
// return; // return;
// } // }
// } // }
var role_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_role');
var v_primary_flag_count=0;
var role_records = $(role_ds_id).getAll();
for (var i = 0;i < role_records.length;i++) {
if(role_records[i].get('primary_flag') == 'Y'){
v_primary_flag_count=v_primary_flag_count+1;
}
}
if(v_primary_flag_count!=1){
Leaf.showErrorMessage('错误', '一个商业伙伴有且仅有一个主角色!');
return false;
}
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master'); var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
var bp_record = $(ds_id).getCurrentRecord(); var bp_record = $(ds_id).getCurrentRecord();
...@@ -380,10 +397,11 @@ ...@@ -380,10 +397,11 @@
} }
} }
}; };
window['${/parameter/@layout_code}_on_layout_dynamic_grid_load'] = function (ds, line_record) { window['${/parameter/@layout_code}_on_layout_dynamic_grid_load'] = function (ds,line_record) {
var dsId = ds.id; var dsId = ds.id;
var base_table_temp = 'hls_bp_master_role_ds'; var base_table_temp = 'hls_bp_master_role_ds';
if (dsId.substring(dsId.length - base_table_temp.length, dsId.length) == base_table_temp) { if (dsId.substring(dsId.length - base_table_temp.length, dsId.length) == base_table_temp) {
...@@ -396,7 +414,30 @@ ...@@ -396,7 +414,30 @@
if (ds.fields.parent_id) { if (ds.fields.parent_id) {
record.getField('parent_id_n').setReadOnly(true); record.getField('parent_id_n').setReadOnly(true);
} }
var role_ds_id = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'G_ROLE', 'hls_bp_master_role');
if("${/model/role_info/record/@role_code}"!="0017"&&"${/model/role_info/record/@role_code}"!="HAND"){
if(role_ds_id == ds.id){
var records = $(ds.id).getAll();
for (var i = 0;i < records.length;i++) {
records[i].getField('primary_flag').setReadOnly(true);
}
}
}
}; };
window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_grid_add'] = function(ds, record, config_records, bp_seq) {
var role_ds_id = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'G_ROLE', 'hls_bp_master_role');
if("${/model/role_info/record/@role_code}"!="0017"&&"${/model/role_info/record/@role_code}"!="HAND"){
if(role_ds_id == ds.id){
var records = $(ds.id).getAll();
for (var i = 0;i < records.length;i++) {
records[i].getField('primary_flag').setReadOnly(true);
}
}
}
}
//更新时调用 add by liukang //更新时调用 add by liukang
//填写银行账号时 允许银行账号相同 但是给一个提示(提示一下而已) //填写银行账号时 允许银行账号相同 但是给一个提示(提示一下而已)
...@@ -633,6 +674,30 @@ ...@@ -633,6 +674,30 @@
record.set('tax_registry_num',record.get('social_code')); record.set('tax_registry_num',record.get('social_code'));
} }
} }
var role_ds = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_role');
if (role_ds == ds.id) {
var bp_type_flag='N';
var records = $(ds.id).getAll();
if("${/model/role_info/record/@role_code}"!="0017"&&"${/model/role_info/record/@role_code}"!="HAND"){
if(name=='bp_type'){
for (var i = 0;i < records.length;i++) {
if(records[i].get('bp_type')=='TENANT'){
bp_type_flag='Y';
}
}
if(bp_type_flag=='Y'){
for (var i = 0;i < records.length;i++) {
if(records[i].get('bp_type')=='TENANT'){
records[i].set('primary_flag','Y')
}else{
records[i].set('primary_flag','N')
}
}
}
}
}
}
}; };
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
<a:init-procedure> <a:init-procedure>
<a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/> <a:model-query fetchAll="true" model="prj.PRJ500D.user_agent_description" rootPath="user_agent_description"/>
<a:model-query fetchAll="true" model="hls.HLS214N.hls_bp_master_modify_user" rootPath="modify_user"/> <a:model-query fetchAll="true" model="hls.HLS214N.hls_bp_master_modify_user" rootPath="modify_user"/>
<a:model-query model="cont.CON620.get_sys_role" rootPath="role_info"/>
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="bank_account_num_link" model="hls.HLS214.hls_bp_bank_account_num" modelaction="update"/> <a:link id="bank_account_num_link" model="hls.HLS214.hls_bp_bank_account_num" modelaction="update"/>
...@@ -47,6 +48,22 @@ ...@@ -47,6 +48,22 @@
// return; // return;
// } // }
// } // }
var role_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_role_req');
var v_primary_flag_count=0;
var role_records = $(role_ds_id).getAll();
for (var i = 0;i < role_records.length;i++) {
if(role_records[i].get('primary_flag') == 'Y'){
v_primary_flag_count=v_primary_flag_count+1;
}
}
if(v_primary_flag_count!=1){
Leaf.showErrorMessage('错误', '一个商业伙伴有且仅有一个主角色!');
return false;
}
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_req'); var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_req');
var bp_record = $(ds_id).getCurrentRecord(); var bp_record = $(ds_id).getCurrentRecord();
var address_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_address_req'); var address_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_address_req');
...@@ -363,7 +380,7 @@ ...@@ -363,7 +380,7 @@
} }
}; };
window['${/parameter/@layout_code}_on_layout_dynamic_grid_load'] = function (ds, line_record) { window['${/parameter/@layout_code}_on_layout_dynamic_grid_load'] = function (ds,line_record) {
var dsId = ds.id; var dsId = ds.id;
var grid_id = dsId.replace('ds', 'layout_grid_id'); var grid_id = dsId.replace('ds', 'layout_grid_id');
var base_table_temp = 'hls_bp_master_req_role_ds'; var base_table_temp = 'hls_bp_master_req_role_ds';
...@@ -385,9 +402,31 @@ ...@@ -385,9 +402,31 @@
setListInterval(line_record, grid_id); setListInterval(line_record, grid_id);
} }
} }
var role_ds_id = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'G_ROLE', 'hls_bp_master_role_req');
if("${/model/role_info/record/@role_code}"!="0017"&&"${/model/role_info/record/@role_code}"!="HAND"){
if(role_ds_id == ds.id){
var records = $(ds.id).getAll();
for (var i = 0;i < records.length;i++) {
records[i].getField('primary_flag').setReadOnly(true);
}
}
}
}; };
window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_grid_add'] = function(ds, record, config_records, bp_seq) {
var role_ds_id = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'G_ROLE', 'hls_bp_master_role_req');
if("${/model/role_info/record/@role_code}"!="0017"&&"${/model/role_info/record/@role_code}"!="HAND"){
if(role_ds_id == ds.id){
var records = $(ds.id).getAll();
for (var i = 0;i < records.length;i++) {
records[i].getField('primary_flag').setReadOnly(true);
}
}
}
}
function setListInterval(record, grid_id) { function setListInterval(record, grid_id) {
var btnListInterval = setTimeout(function() { var btnListInterval = setTimeout(function() {
...@@ -459,9 +498,11 @@ ...@@ -459,9 +498,11 @@
} }
} }
} }
var records = $(ds.id).getAll();
var role_ds = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_role_req'); var role_ds = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_role_req');
if (role_ds == ds.id) { if (role_ds == ds.id) {
var bp_type_flag='N';
var primary_flag = record.get('primary_flag'); var primary_flag = record.get('primary_flag');
if (primary_flag == 'Y') { if (primary_flag == 'Y') {
var bm_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_req'); var bm_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master_req');
...@@ -471,6 +512,25 @@ ...@@ -471,6 +512,25 @@
bm_record.set('bp_category', record.get('bp_category')); bm_record.set('bp_category', record.get('bp_category'));
bm_record.set('bp_category_n', record.get('bp_category_n')); bm_record.set('bp_category_n', record.get('bp_category_n'));
} }
if("${/model/role_info/record/@role_code}"!="0017"&&"${/model/role_info/record/@role_code}"!="HAND"){
if(name=='bp_type'){
for (var i = 0;i < records.length;i++) {
if(records[i].get('bp_type')=='TENANT'){
bp_type_flag='Y';
}
}
if(bp_type_flag=='Y'){
for (var i = 0;i < records.length;i++) {
if(records[i].get('bp_type')=='TENANT'){
records[i].set('primary_flag','Y')
}else{
records[i].set('primary_flag','N')
}
}
}
}
}
} }
...@@ -663,7 +723,6 @@ ...@@ -663,7 +723,6 @@
} }
}; };
function upload_file(id, name, query_only) { function upload_file(id, name, query_only) {
......
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