Commit af243935 authored by 38823's avatar 38823

销项发票工作流反冲附件上传下载优化

parent db8253ea
...@@ -53,6 +53,16 @@ ...@@ -53,6 +53,16 @@
}); });
} }
function open_downloadfile_win_acr_reverse(instance_id) {
new Leaf.Window({
id: 'zj_wfl_approve_history_downloadfile_win',
url: $('prj_attach_downloadfile_link').getUrl() + '?table_name=ZJ_WFL_INSTANCE_ACR_REVERSE&header_id=' + instance_id,
title: '附件查看',
width: 850,
height: 400
});
}
function open_uploadfile_win(rcpt_record_id) { function open_uploadfile_win(rcpt_record_id) {
new Leaf.Window({ new Leaf.Window({
id: 'zj_wfl_approve_history_downloadfile_win', id: 'zj_wfl_approve_history_downloadfile_win',
...@@ -72,31 +82,38 @@ ...@@ -72,31 +82,38 @@
height: 400 height: 400
}); });
} }
function attachement_renderer(value, record, name) {
if (record.get('rcpt_record_id')) {
if(record.get('workflow_code') == 'DCFL_CSH_PAYMENT_REQ' &&
record.get('instance_status') == '10' &&
record.get('node_sequence_num') == '10'){
if(record.get('role_code') == '0014' && record.get('attach_count') == 0){ function attachement_renderer(value, record, name) {
return '<a href="javascript:open_uploadonlyfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>'; if (record.get('rcpt_record_id')) {
}else if(record.get('role_code') == '0014' && record.get('attach_count') >0){ if(record.get('workflow_code') == 'DCFL_CSH_PAYMENT_REQ' &&
return '<a style="color:red" href="javascript:open_uploadonlyfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>'; record.get('instance_status') == '10' &&
}else if((record.get('role_code') == 'HAND'||record.get('role_code') =='0017') && record.get('attach_count') == 0) { record.get('node_sequence_num') == '10'){
return '<a href="javascript:open_uploadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
}else if((record.get('role_code') == 'HAND'||record.get('role_code') =='0017')&& record.get('attach_count') > 0){
return '<a style="color:red" href="javascript:open_uploadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
}
if(record.get('role_code') == '0014' && record.get('attach_count') == 0){
return '<a href="javascript:open_uploadonlyfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
}else if(record.get('role_code') == '0014' && record.get('attach_count') >0){
return '<a style="color:red" href="javascript:open_uploadonlyfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
}else if((record.get('role_code') == 'HAND'||record.get('role_code') =='0017') && record.get('attach_count') == 0) {
return '<a href="javascript:open_uploadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
}else if((record.get('role_code') == 'HAND'||record.get('role_code') =='0017')&& record.get('attach_count') > 0){
return '<a style="color:red" href="javascript:open_uploadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
} }
}
if(record.get('workflow_code') == 'ACR_INVOICE_REVERSE_WFL'){
if (record.get('attach_count') > 0) { if (record.get('attach_count') > 0) {
return '<a style="color:red" href="javascript:open_downloadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>'; return '<a style="color:red" href="javascript:open_downloadfile_win_acr_reverse(' + record.get('instance_id') + ')">附件查看</a>';
}else{
return '<a href="javascript:open_downloadfile_win_acr_reverse(' + record.get('instance_id') + ')">附件查看</a>';
} }
return '<a href="javascript:open_downloadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
} }
if (record.get('attach_count') > 0) {
return '<a style="color:red" href="javascript:open_downloadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
}
return '<a href="javascript:open_downloadfile_win(' + record.get('rcpt_record_id') + ')">附件查看</a>';
} }
}
function prj_atm_renderer(value, record, name) { function prj_atm_renderer(value, record, name) {
if (record.get('rcpt_record_id')) { if (record.get('rcpt_record_id')) {
......
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