Commit 7788cc59 authored by lijingjing's avatar lijingjing

Merge branch 'refs/heads/feature/acr_create' into develop

parents ef1b9e84 9996fc5f
Pipeline #3902 canceled with stages
......@@ -8,34 +8,16 @@
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
<bm:operations>
<bm:operation name="update">
<bm:parameters>
<bm:parameter name="document_number" output="true" outputPath="/parameter/@document_number"/>
</bm:parameters>
<bm:update-sql><![CDATA[
begin
hls_bp_master_pkg.social_code_exist(p_social_code => ${@social_code},
p_user_id => ${/session/@user_id},
p_exist_flag => ${@exist_flag});
hls_document_save_pkg.get_doc_field(
p_document_category =>${@document_category},
p_document_type =>${@document_type},
p_company_id =>${/session/@company_id},
p_function_code =>${@function_code},
p_function_usage =>${@function_usage},
p_user_id =>${/session/@user_id},
p_bp_class => ${@bp_class},
p_id_type => ${@id_type},
p_id_card_no => ${@id_card_no},
p_organization_code => ${@organization_code},
p_bp_info => ${@bp_info},
p_province_id => ${@province_id},
p_document_number => ${@document_number},
p_document_id => ${@document_id},
p_loan_contract_term_type=>${@loan_contract_term_type}
);
hls_bp_master_pkg.update_bp_master_code(p_bp_id => ${@bp_id},
p_user_id =>${/session/@user_id},
p_document_number =>${@document_number});
end;
]]></bm:update-sql>
<bm:parameters>
<bm:parameter name="document_number" dataType="java.lang.String" input="true" output="true" outputPath="/parameter/@document_number"/>
<bm:parameter name="p_exist_flag" dataType="java.lang.String" input="true" output="true" outputPath="/parameter/@exist_flag"/>
</bm:parameters>
</bm:operation>
</bm:operations>
</bm:model>
......@@ -12,8 +12,8 @@
<a:model-query fetchAll="true" model="hls.HLS214N.hls_bp_master_modify_user" rootPath="modify_user"/>
</a:init-procedure>
<a:view>
<a:link id="get_special_fields_link_id" model="hls.HLS213N.social_code_exist"
modelaction="update"/>
<a:link id="get_special_fields_link_id" model="hls.HLS213N.social_code_exist" modelaction="update"/>
<a:link id="gh_nc_post_addsupplierinfo_link" model="hls.HLS213.hls_bp_master_nc_post" modelaction="update"/>
<a:link id="hls214N_cdd_uploadFile_id" url="${/request/@context_path}/uploadFile.lview"/>
<a:link id="hls214N_cdd_downloadFile_id" url="${/request/@context_path}/downloadFile.lview"/>
......@@ -29,7 +29,7 @@
<!-- <script src="${/request/@context_path}/javascripts/identity_card_info_query.js" type="text/javascript"/>-->
<!-- <a:link id="identity_query_link" model="interface.CCX_INTERFACE.identity_query" modelaction="update"/>-->
<script type="text/javascript"><![CDATA[
Leaf.onReady(function () {debugger;
Leaf.onReady(function () {
var unit_id = '${/model/user_agent_description/record/@unit_id}';
var unit_id_n = '${/model/user_agent_description/record/@bp_name}';
var employee_type_id = '${/model/modify_user/record/@employee_type_id}';
......@@ -124,54 +124,6 @@
}
};
//保存submitsuccess调用
window['${/parameter/@layout_code}_on_layout_dynamic_submitsuccess'] = function (ds, record, res, bp_seq) {
var bp_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
console.log($(bp_ds_id));
var bp_record = $(bp_ds_id).getCurrentRecord();
var bp_id = bp_record.get('bp_id');
// Leaf.request({
// url: $('hls213_sap_eai_create_customer_link').getUrl(),
// para: {
// bp_id: bp_id
// },
// scope: this,
// success: function () {
// Leaf.request({
// url: $('hls213_sap_eai_create_vender_link').getUrl(),
// para: {
// bp_id: bp_id
// },
// scope: this,
// success: function () {
// $(bp_ds_id).setQueryParameter('bp_id', bp_id);
// $(bp_ds_id).query();
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// },
// failure: function () {
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// },
// error: function () {
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// },
// sync: true
// });
// },
// failure: function () {
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// },
// error: function () {
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// },
// sync: true
// });
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
};
window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_form_add_and_load'] = function (ds, record, config_records, bp_seq) {
if ((ds.id).indexOf('hls_bp_master') != -1) {
// record.getField('cell_phone').setRequired(true);
......@@ -376,122 +328,6 @@
}
}
//保存前调用,生成商机编号
window['${/parameter/@layout_code}_on_layout_dynamic_before_submit'] = function (ds, record) {
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
var head_record = $(ds_id).getCurrentRecord();
var bp_class = head_record.get('bp_class');
var social_code = head_record.get('social_code');
var extra_nam = head_record.get('extra_nam');
var regax = /^[A-Z]+$/;
//alert('${/parameter/@unbrand}');
if (bp_class == 'NP') {
// if (card_identity_flag == 'N' || sp_identity_flag == 'N') {
//if (regax.test(extra_nam) && extra_nam.length == 3) {
window['${/parameter/@layout_code}_lock_layout_dynamic_window']();
var check_flag = false;
if (head_record.get('bp_code')) {
return true;
}
Leaf.request({
url: $('get_special_fields_link_id').getUrl(),
para: {
document_category: 'BP',
document_type: head_record.get('bp_type'),
// document_type: 'TENANT',
bp_class: head_record.get('bp_class'),
id_type: head_record.get('id_type'),
id_card_no: head_record.get('id_card_no'),
bp_info: head_record.get('bp_info'),
province_id: head_record.get('province_id'),
organization_code: head_record.get('organization_code'),
function_code: '${/parameter/@function_code}',
function_usage: '${/parameter/@function_usage}'
},
success: function (res) {
var document_number = res.result.document_number;
head_record.set('bp_code', document_number);
head_record.set('company_id', '${/session/@company_id}');
head_record.set('unbrand', '${/parameter/@unbrand}');
check_flag = true;
},
error: function () {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
failure: function () {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
sync: true,
scope: this
});
// }
// else {
// Leaf.showMessage('${l:HLS.PROMPT}', '简称不合规!');
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// return false;
// }
// } else {
// Leaf.showMessage('${l:HLS.PROMPT}', '身份证校验未通过,不能保存!');
// window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
// return false;
// }
} else {
window['${/parameter/@layout_code}_lock_layout_dynamic_window']();
var check_flag = false;
if (!CheckSocialCreditCode(head_record.get('social_code'))) {
Leaf.showMessage('提示', '统一社会信用代码有误,请重新输入!');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}
if (head_record.get('bp_code')) {
return true;
}
Leaf.request({
url: $('get_special_fields_link_id').getUrl(),
para: {
document_category: 'BP',
document_type: head_record.get('bp_type'),
// document_type: 'TENANT',
social_code: head_record.get('social_code'),
exist_flag: 'Y',
bp_class: head_record.get('bp_class'),
id_type: head_record.get('id_type'),
id_card_no: head_record.get('id_card_no'),
bp_info: head_record.get('bp_info'),
province_id: head_record.get('province_id'),
organization_code: head_record.get('organization_code'),
function_code: '${/parameter/@function_code}',
function_usage: '${/parameter/@function_usage}'
},
success: function (res) {
var document_number = res.result.document_number;
var exist_flag = res.result.exist_flag;
// alert(exist_flag);
check_flag = true;
if(exist_flag == 'Y'){
head_record.set('bp_code', document_number);
head_record.set('company_id', '${/session/@company_id}');
head_record.set('unbrand', '${/parameter/@unbrand}');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
}else{
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
}
},
error: function () {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
failure: function () {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
sync: true,
scope: this
});
}
return check_flag;
};
function fin_institution_code_validate(record, name, value) {
// if (!value) {
// return '金融机构代码不能为空';
......@@ -524,33 +360,34 @@
// }
// };
/* //保存submitsuccess调用
//保存submitsuccess调用
window['${/parameter/@layout_code}_on_layout_dynamic_submitsuccess'] = function(ds, record, res, bp_seq) {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
var head_record = $(ds_id).getCurrentRecord();
if (head_record.get('bp_class') == 'AGENT') {
var url = $('gh_nc_post_addsupplierinfo_link').getUrl();
}
Leaf.request({
url: url,
para: {
bp_id: head_record.get('bp_id')
},
success: function(res) {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
error: function() {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
failure: function() {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
sync: true,
scope: this
});
}; */
window['${/parameter/@layout_code}_lock_layout_dynamic_window']();
var ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
var head_record = $(ds_id).getCurrentRecord();
Leaf.request({
url: $('get_special_fields_link_id').getUrl(),
para: {
bp_id:head_record.get('bp_id')
},
success: function (res) {
var document_number = res.result.document_number;
head_record.set('bp_code',document_number);
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
error: function () {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
failure: function () {
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
},
sync: true,
scope: this
});
};
window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_update'] = function (ds, record, name, value, old_value, bp_seq) {
var f_bp_create_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
var gird_ds_id = 'BP_NP_CREATE_BP_ASSETS01_hls_bp_assets_ds';
......
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