and ((${@account_type} = 'PE' and exists (select 1 from con_contract_bp ccb ,hls_bp_master hb
where ccb.bp_id = hb.bp_id
and ccb.contract_id = t1.contract_id
and ccb.bp_category in ('TENANT','GUARANTOR') and (ccb.id_card_no = ${@id_no} or ccb.id_no_sp = ${@id_no})))
or (${@account_type} = 'AG' and exists (select 1 from hls_bp_master_signer hs where hs.hls_bp_signer_id = t1.signer and hs.id_card = ${@id_no}))
or (${@account_type} = 'AG' and exists (select 1 from con_contract_bp cb where cb.contract_id = t1.contract_id and cb.bp_category = 'GUARANTOR' and cb.bp_class = 'ORG' and cb.id_card_no_leg = ${@id_no}))
or (${@account_type} = 'LP' and exists
(select 1
from con_contract_bp cb, hls_bp_master hb
where cb.bp_id = hb.bp_id
and cb.contract_id = t1.contract_id
and hb.social_code = ${@id_no}))
)
UNION ALL
select t1.contract_id,
t1.contract_number,
t1.contract_status,
t1.bp_id_tenant,
...
...
@@ -155,12 +64,19 @@ select *
from con_contract_ele_signer cs
where cs.contract_id = t1.contract_id
and ((${@account_type} = 'AG' and
(cs.id_no =
(select hm.social_code
from hls_bp_master hm, con_contract_bp cb
where hm.bp_id = cb.bp_id
and cb.contract_id = t1.contract_id
and cb.id_card_no_leg = ${@id_no}) or
cs.id_no =
(select hm.social_code
from hls_bp_master hm
where t1.bp_id_tenant = hm.bp_id)) or
(${@account_type} != 'AG' and
cs.id_no = ${@id_no}))
from hls_bp_master hm, hls_bp_master_signer hs
where hm.bp_id = hs.bp_id
and hm.bp_id = t1.bp_id_tenant
and hs.id_card = ${@id_no}))) or
(${@account_type} != 'AG' and cs.id_no = ${@id_no}))
and rownum = 1) sign_url,
(SELECT nvl(cs.ec_sign_status, 'N')
from con_contract_ele_signer cs
...
...
@@ -172,20 +88,32 @@ select *
where t1.data_class = 'NORMAL'
and t1.ec_sign_type in ('INITIATE', 'SIGNING')
and t1.sign_type = 'ELE_SIGN'
and ((${@account_type} = 'PE' and exists (select 1 from con_contract_bp ccb ,hls_bp_master hb
and ((${@account_type} = 'PE' and exists
(select 1
from con_contract_bp ccb, hls_bp_master hb
where ccb.bp_id = hb.bp_id
and ccb.contract_id = t1.contract_id
and ccb.bp_category in ('TENANT','GUARANTOR') and (ccb.id_card_no = ${@id_no} or ccb.id_no_sp = ${@id_no})))
or (${@account_type} = 'AG' and exists (select 1 from hls_bp_master_signer hs where hs.hls_bp_signer_id = t1.signer and hs.id_card = ${@id_no}))
or (${@account_type} = 'AG' and exists (select 1 from con_contract_bp cb where cb.contract_id = t1.contract_id and cb.bp_category = 'GUARANTOR' and cb.bp_class = 'ORG' and cb.id_card_no_leg = ${@id_no}))
var up_file_token_url = 'http://hlsapp.hand-china.com/hl_dr_dev/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=admin'; //文件上传获取token的地址
var up_file_token_url = info_query('UP_FILE_TOKEN_URL').code_value;
//系统参数获取
function info_query(parameter_code) {
var info = new Object();
...
...
@@ -23,9 +23,15 @@
var sign_cancel_map = sign_cancel_bm.queryAsMap({
contract_id:$ctx.parameter.contract_id
});
var flow_Id = sign_cancel_map.getChildren()[0].ele_flow_id;
var sign_cancel_data = sign_cancel_map.getChildren();
var revoke_flows = [];
for (var i = 0; i < sign_cancel_data.length;i++){
revoke_flows.push({
"flowId":sign_cancel_data[i].ele_flow_id
});
}
var revokeParam = {
flowId:flow_Id
revokeFlows:revoke_flows
}
//调用中台取消流程
var info = info_query('HL_SIGN_FLOW_CANCEL');
...
...
@@ -47,14 +53,31 @@
tokenResult:token_sign_result
});
var result_ob = JSON.parse(result); //根据返回参数形式再定
var revoke_flag_update_bm = $bm('cont.CON505.contract_revoke_flag_update');
var up_file_token_url = 'http://hlsapp.hand-china.com/hl_dr_dev/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=admin'; //文件上传获取token的地址
function copyFile(fOld, fNew) {
var fis = new java.io.FileInputStream(fOld);
var fos = new java.io.FileOutputStream(fNew);
...
...
@@ -82,12 +80,16 @@
info.code_value = data[0].code_value;
return info;
}
var up_file_token_url = info_query('UP_FILE_TOKEN_URL').code_value;
var flow_count_bm = $bm('wx.WX100.con_ele_flow_update');
var flow_count_map = flow_count_bm.queryAsMap({
contract_id: $ctx.parameter.contract_id
});
var flow_count_data = flow_count_map.getChildren();
if(flow_count_data[0].ce_num == 0) {
//依据合同文本签署人定义存储签署人信息
var ele_contract_signer_bm = $bm('wx.WX100.con_ele_contract_signer_save');
var up_file_token_url = 'http://hlsapp.hand-china.com/hl_dr_dev/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=admin'; //文件上传获取token的地址
var up_file_token_url = info_query('UP_FILE_TOKEN_URL').code_value;
var up_file_token_url = 'http://hlsapp.hand-china.com/hl_dr_dev/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=admin'; //文件上传获取token的地址
var up_file_token_url = info_query('UP_FILE_TOKEN_URL').code_value;
function copyFile(fOld, fNew) {
var fis = new java.io.FileInputStream(fOld);
...
...
@@ -284,10 +284,11 @@
raise_app_error(result_ob.message.toString());
}else if(result_ob.code == 0){
var flow_id = result_ob.flowId;
var flow_update_bm = $bm('wx.WX100.con_et_flow_update');
var flow_update_bm = $bm('wx.WX100.con_ele_flow_update');
flow_update_bm.update({
contract_id:$ctx.parameter.contract_id,
flow_id:flow_id
contract_id: $ctx.parameter.contract_id,
flow_id: flow_id,
esign_type: 'ET'
})
var sign_url_list = result_ob.signUrlList;
var ele_con_info_bm = $bm('wx.WX100.con_ele_con_info_update');
var up_file_token_url = 'http://hlsapp.hand-china.com/hl_dr_dev/oauth/token?client_id=client2&client_secret=secret&grant_type=password&username=admin&password=admin'; //文件上传获取token的地址
var up_file_token_url = info_query('UP_FILE_TOKEN_URL').code_value;