Commit 0fe8a0e0 authored by 25484's avatar 25484

[fix]商业伙伴SBO修改

parent 37b7cb1d
...@@ -102,8 +102,19 @@ ...@@ -102,8 +102,19 @@
// } // }
var bp_record = $(bp_ds_id).getCurrentRecord(); var bp_record = $(bp_ds_id).getCurrentRecord();
var bp_id = bp_record.get('bp_id');
if(old_id_card != new_id_card){
record.set('id_card_no_change_flag','Y');
}else{
record.set('id_card_no_change_flag','N');
}
if(old_bp_name != new_bp_name){
record.set('bp_name_change_flag','Y');
}else{
record.set('bp_name_change_flag','N');
}
// Leaf.request({ // Leaf.request({
...@@ -220,6 +231,11 @@ ...@@ -220,6 +231,11 @@
// return true; // return true;
// } // }
var old_id_card;
var new_id_card;
var old_bp_name;
var new_bp_name;
//新增和加载时调用form //新增和加载时调用form
window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_form_add_and_load'] = function(ds, record, config_records, bp_seq) { 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_credit') != -1 && (ds.id).indexOf('F_ORG_CREDIT') != -1) { // if ((ds.id).indexOf('hls_bp_master_credit') != -1 && (ds.id).indexOf('F_ORG_CREDIT') != -1) {
...@@ -234,6 +250,12 @@ ...@@ -234,6 +250,12 @@
if ((ds.id).indexOf('hls_bp_master') != -1 && (ds.id).indexOf('F_BASIC') != -1) { if ((ds.id).indexOf('hls_bp_master') != -1 && (ds.id).indexOf('F_BASIC') != -1) {
var employee_type_id = '${/model/modify_user/record/@employee_type_id}'; var employee_type_id = '${/model/modify_user/record/@employee_type_id}';
old_bp_name = record.get('bp_name');
new_bp_name = record.get('bp_name');
if(record.get('id_type') == 'ID_CARD'){
old_id_card = record.get('id_card_no');
new_id_card = record.get('id_card_no');
}
if (record.get('bp_category') == 'VENDER') { if (record.get('bp_category') == 'VENDER') {
record.getField('unit_id_n').setReadOnly(true); record.getField('unit_id_n').setReadOnly(true);
...@@ -319,6 +341,10 @@ ...@@ -319,6 +341,10 @@
var bp_record = $(hls_bp_master_ds_id).getCurrentRecord(); var bp_record = $(hls_bp_master_ds_id).getCurrentRecord();
if ((ds.id).indexOf('hls_bp_master') != -1 && (ds.id).indexOf('F_BASIC') != -1) { if ((ds.id).indexOf('hls_bp_master') != -1 && (ds.id).indexOf('F_BASIC') != -1) {
if(name == 'bp_name'){
new_bp_name = record.get('bp_name');
}
if (name == 'agent_type') { if (name == 'agent_type') {
if (value == 'AGENT_NO_REBATE' || value == 'AGENT_EE') { if (value == 'AGENT_NO_REBATE' || value == 'AGENT_EE') {
record.getField('parent_id_n').setReadOnly(false); record.getField('parent_id_n').setReadOnly(false);
...@@ -413,6 +439,9 @@ ...@@ -413,6 +439,9 @@
Leaf.showMessage('提示', '基本信息中,请输入正确格式的身份证!'); Leaf.showMessage('提示', '基本信息中,请输入正确格式的身份证!');
return '请输入正确格式的身份证'; return '请输入正确格式的身份证';
} else if (value.length == 18) { } else if (value.length == 18) {
new_id_card = record.get('id_card_no');
//自动带出籍贯 //自动带出籍贯
record.set('resident_addres', get_native_place(value)); record.set('resident_addres', get_native_place(value));
record.set('date_of_birth', new Date(value.substr(6, 4) + '/' + value.substr(10, 2) + '/' + value.substr(12, 2))); record.set('date_of_birth', new Date(value.substr(6, 4) + '/' + value.substr(10, 2) + '/' + value.substr(12, 2)));
...@@ -435,7 +464,10 @@ ...@@ -435,7 +464,10 @@
Leaf.showMessage('提示', '配偶信息中,请输入正确格式的身份证!'); Leaf.showMessage('提示', '配偶信息中,请输入正确格式的身份证!');
return '请输入正确格式的身份证'; return '请输入正确格式的身份证';
} else if (value.length == 18) { } else if (value.length == 18) {
record.set('resident_addres_sp',get_native_place(value))
new_id_card = record.get('id_card_no_leg');
record.set('resident_addres_sp',get_native_place(value));
record.set('date_of_birth', new Date(value.substr(6, 4) + '/' + value.substr(10, 2) + '/' + value.substr(12, 2))); record.set('date_of_birth', new Date(value.substr(6, 4) + '/' + value.substr(10, 2) + '/' + value.substr(12, 2)));
record.set('age', new Date().getFullYear() - value.substr(6, 4)); record.set('age', new Date().getFullYear() - value.substr(6, 4));
if (value.substr(16, 1) % 2 == 1) { if (value.substr(16, 1) % 2 == 1) {
......
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