Commit 57cba346 authored by Chence's avatar Chence

【update】商业伙伴维护/创建/变更维护 基本信息

parent dd686e05
......@@ -184,6 +184,28 @@
if ((ds.id).indexOf('hls_bp_master') != -1) {
if(record.get('bp_class') && record.get('bp_class') == 'ORG'){
if(record.get('bp_type') == 'TENANT'){
record.getField('etp_sts').setRequired(true);
record.getField('credit_code').setRequired(true);
record.getField('etp_sts_n').setRequired(true);
record.getField('org_type').setRequired(true);
record.getField('org_type_n').setRequired(true);
record.getField('org_type_sub').setRequired(true);
record.getField('org_type_sub_n').setRequired(true);
record.getField('enterprise_scale').setRequired(true);
record.getField('enterprise_scale_n').setRequired(true);
record.getField('due_date').setRequired(true);
record.getField('org_unit_property').setRequired(true);
record.getField('org_unit_property_n').setRequired(true);
record.getField('industry').setRequired(true);
record.getField('industry_n').setRequired(true);
record.getField('nationalities').setRequired(true);
}
}
// record.getField('cell_phone').setRequired(true);
//record.getField('cell_phone').setRequired(true);
//身份证验证
......@@ -308,7 +330,6 @@
}
return true;
}
function CheckSocialCreditCode(Code) {
var patrn = /^[0-9A-Z]+$/;
......@@ -366,17 +387,43 @@
// return true;
// }
// //新增和加载时调用form
// 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.fields.fin_institution_code) {
// // ds.fields.fin_institution_code.pro.validator = fin_institution_code_validate;
// // }
// // if (ds.fields.trade_type_code) {
// // ds.fields.trade_type_code.pro.validator = trade_type_code_validate;
// // }
// }
// };
//新增和加载时调用form
// window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_form_add_and_load'] = function(ds, record, config_records, bp_seq) {
//
// };
//查询时调用(grid,table,gridBox)
// window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_grid_query'] = function(ds, qpara, bp_seq) {
// //商业伙伴类型校验
// debugger;
// var bp_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_master');
// var record = bp_ds_id.getCurrentRecord();
//
// };
//查询时调用(form,fieldboxcolumn)
// window['${/parameter/@bp_seq}${/parameter/@layout_code}_on_layout_dynamic_form_query'] = function(ds,record, qpara, bp_seq) {
// //商业伙伴类型校验
// if(ds.fields.bp_class) {
// if(record.get('bp_class') == 'ORG'){
// if(record.get('bp_type') == 'TENANT'){
// record.getField('credit_code').setRequired(true);
// record.getField('etp_sts').setRequired(true);
// record.getField('etp_sts_n').setRequired(true);
// record.getField('org_type').setRequired(true);
// record.getField('org_type_n').setRequired(true);
// record.getField('org_type_sub').setRequired(true);
// record.getField('org_type_sub_n').setRequired(true);
// record.getField('enterprise_scale').setRequired(true);
// record.getField('enterprise_scale_n').setRequired(true);
// record.getField('due_date').setRequired(true);
// record.getField('org_unit_property').setRequired(true);
// record.getField('org_unit_property_n').setRequired(true);
// record.getField('industry').setRequired(true);
// record.getField('industry_n').setRequired(true);
// record.getField('nationalities').setRequired(true);
// }
// }
// }
// };
/*保存前调用,生成项目编号*/
// window['${/parameter/@layout_code}_on_layout_dynamic_before_submit'] = function (ds, record) {
......@@ -620,6 +667,30 @@
var gird_ds_id = 'BP_NP_CREATE_BP_ASSETS01_hls_bp_assets_ds';
var gird_ds_id2 = 'BP_NP_CREATE_BP_ASSETS04_hls_bp_assets_ds';
var gird_ds_id3 = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_bank_flow');
debugger;
//中征码校验
if (record.get('bp_class') == 'ORG') {
if(record.get('bp_type') == 'TENANT'){
var credit_code = record.get('credit_code');
if (!Leaf.isEmpty(credit_code)) {
if (credit_code.length == '16'){
if(!(/^[A-Z][A-z0-9]*$/).test(credit_code)){
Leaf.showMessage('提示', '中征码首字母需要大写');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}else {
return true;
}
}else {
Leaf.showMessage('提示', '请输入16位中征码');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}
}
}
}
if (gird_ds_id == ds.id || gird_ds_id2 == ds.id) {
if (name == 'relationship_with_bp') {
if (value == 'A7501') {
......@@ -834,6 +905,7 @@
}
}else if (value == 'NO_BILLING'){//暂时不开票
debugger;
//一般纳税人
record.getField('taxpayer_type').setRequired(true);
record.getField('taxpayer_type_n').setRequired(true);
......
......@@ -384,6 +384,26 @@
// }
if ((ds.id).indexOf('hls_bp_master') != -1 && (ds.id).indexOf('F_BASIC') != -1) {
if(record.get('bp_class') && record.get('bp_class') == 'ORG'){
if(record.get('bp_type') == 'TENANT'){
record.getField('etp_sts').setRequired(true);
record.getField('credit_code').setRequired(true);
record.getField('etp_sts_n').setRequired(true);
record.getField('org_type').setRequired(true);
record.getField('org_type_n').setRequired(true);
record.getField('org_type_sub').setRequired(true);
record.getField('org_type_sub_n').setRequired(true);
record.getField('enterprise_scale').setRequired(true);
record.getField('enterprise_scale_n').setRequired(true);
record.getField('due_date').setRequired(true);
record.getField('org_unit_property').setRequired(true);
record.getField('org_unit_property_n').setRequired(true);
record.getField('industry').setRequired(true);
record.getField('industry_n').setRequired(true);
record.getField('nationalities').setRequired(true);
}
}
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');
......@@ -466,6 +486,31 @@
var gird_ds_id = 'BP_NP_MODIFY_N_BP_ASSETS01_hls_bp_assets_ds';
var gird_ds_id2 = 'BP_NP_MODIFY_N_BP_ASSETS04_hls_bp_assets_ds';
var gird_ds_id3 = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_bank_flow');
//中征码校验
if (record.get('bp_class') == 'ORG') {
if(record.get('bp_type') == 'TENANT'){
var credit_code = record.get('credit_code');
if (!Leaf.isEmpty(credit_code)) {
if (credit_code.length == '16'){
if(!(/^[A-Z][A-z0-9]*$/).test(credit_code)){
Leaf.showMessage('提示', '中征码首字母需要大写');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}else {
return true;
}
}else {
Leaf.showMessage('提示', '请输入16位中征码');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}
}
}
}
if (gird_ds_id == ds.id || gird_ds_id2 == ds.id) {
if (name == 'relationship_with_bp') {
if (value == 'A7501') {
......
......@@ -407,6 +407,26 @@
if ((ds.id).indexOf('hls_bp_master_req') != -1 && (ds.id).indexOf('F_BASIC') != -1) {
if(record.get('bp_class') && record.get('bp_class') == 'ORG'){
if(record.get('bp_type') == 'TENANT'){
record.getField('etp_sts').setRequired(true);
record.getField('credit_code').setRequired(true);
record.getField('etp_sts_n').setRequired(true);
record.getField('org_type').setRequired(true);
record.getField('org_type_n').setRequired(true);
record.getField('org_type_sub').setRequired(true);
record.getField('org_type_sub_n').setRequired(true);
record.getField('enterprise_scale').setRequired(true);
record.getField('enterprise_scale_n').setRequired(true);
record.getField('due_date').setRequired(true);
record.getField('org_unit_property').setRequired(true);
record.getField('org_unit_property_n').setRequired(true);
record.getField('industry').setRequired(true);
record.getField('industry_n').setRequired(true);
record.getField('nationalities').setRequired(true);
}
}
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');
......@@ -545,6 +565,30 @@
var gird_ds_id = 'BP_NP_MODIFY_N_BP_ASSETS01_hls_bp_assets_ds';
var gird_ds_id2 = 'BP_NP_MODIFY_N_BP_ASSETS04_hls_bp_assets_ds';
var gird_ds_id3 = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'hls_bp_bank_flow');
//中征码校验
if (record.get('bp_class') == 'ORG') {
if(record.get('bp_type') == 'TENANT'){
var credit_code = record.get('credit_code');
if (!Leaf.isEmpty(credit_code)) {
if (credit_code.length == '16'){
if(!(/^[A-Z][A-z0-9]*$/).test(credit_code)){
Leaf.showMessage('提示', '中征码首字母需要大写');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}else {
return true;
}
}else {
Leaf.showMessage('提示', '请输入16位中征码');
window['${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false;
}
}
}
}
if (gird_ds_id == ds.id || gird_ds_id2 == ds.id) {
if (name == 'relationship_with_bp') {
if (value == 'A7501') {
......
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