Commit cd5b4b80 authored by xiaochao's avatar xiaochao

Merge branch 'develop' of https://hel.hand-china.com/hlcm/leaf-hlcm into develop

parents 26884d61 6d1717f7
...@@ -30,3 +30,5 @@ pom.xml ...@@ -30,3 +30,5 @@ pom.xml
atm_upload.svc atm_upload.svc
atm_upload_unUseSubFolder.svc atm_upload_unUseSubFolder.svc
!/src/main/webapp/WEB-INF/uncertain.local.xml !/src/main/webapp/WEB-INF/uncertain.local.xml
src/main/webapp/WEB-INF/uncertain.local.xml
src/main/webapp/WEB-INF/uncertain.local.xml
package leaf.presentation.component.std;
import leaf.application.LeafApplication;
import leaf.presentation.BuildSession;
import leaf.presentation.ViewContext;
import leaf.presentation.component.std.config.ComponentConfig;
import leaf.presentation.component.std.config.TableColumnConfig;
import leaf.presentation.component.std.config.TableConfig;
import leaf.presentation.component.std.config.UploadConfig;
import leaf.service.ServiceInstance;
import leaf.service.http.HttpServiceInstance;
import leaf.service.http.UserAgentTools;
import org.json.JSONException;
import org.json.JSONObject;
import uncertain.composite.CompositeMap;
import uncertain.ocm.IObjectRegistry;
import javax.servlet.http.HttpServletRequest;
import java.io.IOException;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
@SuppressWarnings("unchecked")
public class Upload extends Component {
public Upload(IObjectRegistry registry) {
super(registry);
}
public static final String VERSION = "$Revision: 1.1 $";
public static final String HTML5_TEMPLATE = "upload_html5.tplt";
public void onPreparePageContent(BuildSession session, ViewContext context) throws IOException {
super.onPreparePageContent(session, context);
addStyleSheet(session, context, "table/Table-min.css");
addStyleSheet(session, context, "upload/upload.css");
addJavaScript(session, context, "table/Table-min.js");
addJavaScript(session, context, "upload/resumable.js");
addJavaScript(session, context, "upload/html5upload.js");
addJavaScript(session, context, "upload/swfupload.js");
addJavaScript(session, context, "upload/swfupload.queue.js");
addJavaScript(session, context, "upload/handler.js");
}
public void onCreateViewContent(BuildSession session, ViewContext context) throws IOException{
super.onCreateViewContent(session, context);
CompositeMap view = context.getView();
Map map = context.getMap();
CompositeMap model = context.getModel();
UploadConfig uc = UploadConfig.getInstance(view);
HttpServiceInstance serviceInstance = (HttpServiceInstance) ServiceInstance.getInstance(model.getRoot());
boolean showList = uc.isShowList();
map.put("linestyle", showList ? "block" : "none");
if(!UploadConfig.DEFAULT_TYPE.equals(uc.getType()) && isSupportFileAPI(serviceInstance.getRequest())) {
context.setTemplate(session.getTemplateByName(HTML5_TEMPLATE));
processHtml5Upload(view,map,model,session);
}else {
processNormalUpload(view,map,model,session);
}
}
private void processHtml5Upload(CompositeMap view, Map map, CompositeMap model,BuildSession session) throws IOException{
UploadConfig uc = UploadConfig.getInstance(view);
addUploadCard(uc,map,session,model);
if(!uc.isShowUpload()) {
map.put(UploadConfig.PROPERTITY_SHOW_UPLOAD, "none");
}else {
HttpServiceInstance serviceInstance = (HttpServiceInstance) ServiceInstance.getInstance(model.getRoot());
String sid = "";
if(uc.isRequireSession()) {
sid = serviceInstance.getRequest().getSession(true).getId();
}
map.put("sessionId", sid);
}
map.put(UploadConfig.PROPERTITY_TEXT, session.getLocalizedPrompt(uc.getText()));
addConfig(UploadConfig.PROPERTITY_SHOW_UPLOAD, uc.isShowUpload());
addConfig(UploadConfig.PROPERTITY_SOURCE_TYPE, uncertain.composite.TextParser.parse(uc.getSourceType(), model));
addConfig(UploadConfig.PROPERTITY_PK_VALUE, uncertain.composite.TextParser.parse(uc.getPKValue(), model));
String context_path = model.getObject("/request/@context_path").toString();
map.put("context_path", context_path);
addConfig(UploadConfig.PROPERTITY_FILE_SIZE, uc.getFileSize());
addConfig(UploadConfig.PROPERTITY_TOTAL_COUNT, new Integer(uc.getTotalCount()));
addConfig(UploadConfig.PROPERTITY_TOTAL_FILE_SIZE, new Integer(uc.getTotalFileSize()));
addConfig(UploadConfig.PROPERTITY_FILE_TYPE, uc.getFileType());
addConfig(UploadConfig.PROPERTITY_DELETE_CONTROL, uc.getDeleteControl());
addConfig("user_id", model.getObject("/session/@user_id"));
addConfig(UploadConfig.PROPERTITY_TYPE, uc.getType());
addConfig(UploadConfig.PROPERTITY_UPLOAD_URL, uncertain.composite.TextParser.parse(uc.getUploadURL(context_path + "/atm_upload.lsc"), model));
addConfig(UploadConfig.PROPERTITY_DELETE_URL, uncertain.composite.TextParser.parse(uc.getDeleteURL(context_path + "/atm_delete.lsc"), model));
addConfig(UploadConfig.PROPERTITY_DOWNLOAD_URL, uncertain.composite.TextParser.parse(uc.getDownloadURL(context_path + "/atm_download.lsc"), model));
map.put(CONFIG, getConfigString());
}
private void addUploadCard(UploadConfig uc,Map map,BuildSession session,CompositeMap model) {
String uid = uc.getId() + "_ul";
map.put("up_table", "<div id=\""+uid+"\"> </div>");
JSONObject config = new JSONObject();
String context_path = model.getObject("/request/@context_path").toString();
try {
config.put(ComponentConfig.PROPERTITY_ID, uid);
config.put(ComponentConfig.PROPERTITY_BINDTARGET, uc.getId() + "_ds");
config.put(UploadConfig.PROPERTITY_SHOW_DELETE, uc.isShowDelete());
config.put(UploadConfig.PROPERTITY_REORDER, uc.isReorder());
config.put(UploadConfig.PROPERTITY_DELETE_CONTROL, uc.getDeleteControl());
config.put(UploadConfig.PROPERTITY_DELETE_URL, uncertain.composite.TextParser.parse(uc.getDeleteURL(context_path + "/atm_delete.lsc"), model));
config.put(UploadConfig.PROPERTITY_DOWNLOAD_URL, uncertain.composite.TextParser.parse(uc.getDownloadURL(context_path + "/atm_download.lsc"), model));
} catch (JSONException e) {
throw new RuntimeException(e);
}
map.put("upload_list", "new Leaf.UploadList("+config.toString()+")");
}
private void addUploadList(UploadConfig uc,Map map,BuildSession session,CompositeMap model) throws IOException{
CompositeMap tb = new CompositeMap(TableConfig.TAG_NAME);
tb.setNameSpaceURI(LeafApplication.LEAF_FRAMEWORK_NAMESPACE);
tb.put(TableConfig.PROPERTITY_PERCENT_WIDTH, new Integer(100));
tb.put(ComponentConfig.PROPERTITY_CLASSNAME, "atmList");
tb.put(TableConfig.PROPERTITY_SHOW_HEAD, Boolean.FALSE);
tb.put(ComponentConfig.PROPERTITY_BINDTARGET, id + "_ds");
tb.put(ComponentConfig.PROPERTITY_STYLE, "border:none;background-color:#fff");
CompositeMap tb_columns = new CompositeMap(TableConfig.PROPERTITY_COLUMNS);
tb_columns.setNameSpaceURI(LeafApplication.LEAF_FRAMEWORK_NAMESPACE);
tb.addChild(tb_columns);
CompositeMap tb_column = new CompositeMap(TableColumnConfig.TAG_NAME);
tb_column.setNameSpaceURI(LeafApplication.LEAF_FRAMEWORK_NAMESPACE);
tb_column.put(TableColumnConfig.PROPERTITY_PERCENT_WIDTH, new Integer(100));
tb_column.put(TableColumnConfig.PROPERTITY_NAME, "file_name");
if(!uc.isShowDelete()) {
tb_column.put(TableColumnConfig.PROPERTITY_RENDERER, uc.isReorder() ? "atmNotDeleteReorderRenderer" : "atmNotDeleteRenderer");
} else if(uc.getDeleteControl()){
tb_column.put(TableColumnConfig.PROPERTITY_RENDERER, uc.isReorder() ? "atmDeleteControlReorderRenderer" : "atmDeleteControlRenderer");
} else {
tb_column.put(TableColumnConfig.PROPERTITY_RENDERER, uc.isReorder() ? "atmReorderRenderer" : "atmRenderer");
}
tb_columns.addChild(tb_column);
try {
boolean showList = uc.isShowList();
// map.put("linestyle", showList ? "block" : "none");
if(showList)
map.put("up_table", session.buildViewAsString(model, tb));
} catch (Exception e) {
throw new IOException(e);
}
}
private void processNormalUpload(CompositeMap view, Map map, CompositeMap model,BuildSession session) throws IOException{
UploadConfig uc = UploadConfig.getInstance(view);
String id = uc.getId();
if(!uc.isShowUpload()) {
map.put(UploadConfig.PROPERTITY_SHOW_UPLOAD, "none");
}else {
String sid = "";
if(uc.isRequireSession()) {
HttpServiceInstance serviceInstance = (HttpServiceInstance) ServiceInstance.getInstance(model.getRoot());
sid = serviceInstance.getRequest().getSession(true).getId();
}
map.put("sessionId", sid);
}
if(UploadConfig.DEFAULT_TYPE.equals(uc.getType())) {
addUploadList(uc,map,session,model);
}else {
addUploadCard(uc,map,session,model);
}
map.put(UploadConfig.PROPERTITY_TEXT, session.getLocalizedPrompt(uc.getText()));
map.put(UploadConfig.PROPERTITY_SOURCE_TYPE, uncertain.composite.TextParser.parse(uc.getSourceType(), model));
map.put(UploadConfig.PROPERTITY_PK_VALUE, uncertain.composite.TextParser.parse(uc.getPKValue(), model));
String context_path = model.getObject("/request/@context_path").toString();
map.put("context_path", context_path);
map.put(UploadConfig.PROPERTITY_BUTTON_WIDTH, new Integer(uc.getButtonWidth()));
map.put(UploadConfig.PROPERTITY_FILE_SIZE, uc.getFileSize());
map.put(UploadConfig.PROPERTITY_TOTAL_COUNT, new Integer(uc.getTotalCount()));
map.put(UploadConfig.PROPERTITY_TOTAL_FILE_SIZE, new Integer(uc.getTotalFileSize()));
map.put(UploadConfig.PROPERTITY_FILE_TYPE, uc.getFileType());
map.put(UploadConfig.PROPERTITY_UPLOAD_URL, uncertain.composite.TextParser.parse(uc.getUploadURL(context_path + "/atm_upload.lsc"), model));
map.put(UploadConfig.PROPERTITY_DELETE_URL, uncertain.composite.TextParser.parse(uc.getDeleteURL(context_path + "/atm_delete.lsc"), model));
map.put(UploadConfig.PROPERTITY_DOWNLOAD_URL, uncertain.composite.TextParser.parse(uc.getDownloadURL(context_path + "/atm_download.lsc"), model));
map.put(CONFIG, getConfigString());
}
private boolean isSupportFileAPI(HttpServletRequest request){
Map m = new HashMap();
m.put("chrome", 13);
m.put("firefox", 4);
m.put("opera", 12);
m.put("safari", 6);
m.put("msie", 10);//使用ie10以上的浏览器时,使用html5方式上传
String agent = request.getHeader("User-Agent");
String[] browsers = UserAgentTools.getBrowser(agent);
String browser = browsers[1];
String version = browsers[2];
// if(browser.equalsIgnoreCase("msie")) {
// return false;
// }
Iterator it = m.keySet().iterator();
while(it.hasNext()){
String br = (String)it.next();
if(br.equalsIgnoreCase(browser)){
int bigVersion = Integer.parseInt(version.split("\\.")[0]);
if(bigVersion>=(Integer)m.get(br)) return true;
}
}
return false;
}
}
...@@ -4,13 +4,13 @@ ...@@ -4,13 +4,13 @@
<bm:operation name="query"> <bm:operation name="query">
<bm:query-sql><![CDATA[ <bm:query-sql><![CDATA[
SELECT * FROM( SELECT * FROM( select t1.spv_company_id, SELECT *
FROM (SELECT *
FROM (select t1.spv_company_id,
NULL journal_header_id, NULL journal_header_id,
NULL journal_line_id, NULL journal_line_id,
t1.company_id, t1.company_id,
t1.project_id, t1.project_id,
t1.project_number,
t1.project_name,
t1.contract_id, t1.contract_id,
t1.contract_number, t1.contract_number,
t1.contract_name, t1.contract_name,
...@@ -21,46 +21,90 @@ ...@@ -21,46 +21,90 @@
t1.billing_method_desc, t1.billing_method_desc,
t1.inv_object_taxpayer_type, t1.inv_object_taxpayer_type,
t1.inv_object_taxpayer_type_desc, t1.inv_object_taxpayer_type_desc,
decode(t2.cf_item,'250',t1.inv_billing_object_id,t1.billing_object_id) billing_object_id, decode(t2.cf_item,
decode(t2.cf_item,'250',t1.inv_billing_object_code,t1.billing_object_code) billing_object_code, '250',
decode(t2.cf_item,'250',t1.inv_billing_object_name,t1.billing_object_name) billing_object_name, t1.inv_billing_object_id,
decode(t2.cf_item,'250',t1.inv_object_taxpayer_type,t1.object_taxpayer_type) object_taxpayer_type, t1.billing_object_id) billing_object_id,
decode(t2.cf_item,'250',t1.inv_object_taxpayer_type_desc,t1.object_taxpayer_type_desc) object_taxpayer_type_desc, decode(t2.cf_item,
'250',
t1.inv_billing_object_code,
t1.billing_object_code) billing_object_code,
decode(t2.cf_item,
'250',
t1.inv_billing_object_name,
t1.billing_object_name) billing_object_name,
decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) object_taxpayer_type,
decode(t2.cf_item,
'250',
t1.inv_object_taxpayer_type_desc,
t1.object_taxpayer_type_desc) object_taxpayer_type_desc,
-- t1.object_taxpayer_type_desc, -- t1.object_taxpayer_type_desc,
decode(t2.cf_item,'250',t1.inv_object_tax_registry_num,t1.object_tax_registry_num) object_tax_registry_num, decode(t2.cf_item,
decode(t2.cf_item,'250',t1.inv_bill_object_bp_class,t1.bill_object_bp_class) bill_object_bp_class, '250',
decode(t2.cf_item,'250',t1.inv_bill_object_bp_class_desc,t1.bill_object_bp_class_desc) bill_object_bp_class_desc, t1.inv_object_tax_registry_num,
t1.object_tax_registry_num) object_tax_registry_num,
decode(t2.cf_item,
'250',
t1.inv_bill_object_bp_class,
t1.bill_object_bp_class) bill_object_bp_class,
decode(t2.cf_item,
'250',
t1.inv_bill_object_bp_class_desc,
t1.bill_object_bp_class_desc) bill_object_bp_class_desc,
t1.tax_type_vat, t1.tax_type_vat,
t1.description, t1.description,
decode(t2.cf_item,'250',t1.inv_invoice_title,t1.invoice_title) invoice_title, decode(t2.cf_item,
decode(t2.cf_item,'250',t1.inv_bp_address_phone_num,t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num, '250',
decode(t2.cf_item,'250',t1.inv_invoice_bp_bank_account,t1.invoice_bp_bank_account) invoice_bp_bank_account, t1.inv_invoice_title,
decode(t2.cf_item,'250',t1.inv_tax_registry_num,t1.tax_registry_num) tax_registry_num, t1.invoice_title) invoice_title,
t1.prj_search_term_1, decode(t2.cf_item,
t1.prj_search_term_2, '250',
t1.con_search_term_1, t1.inv_bp_address_phone_num,
t1.con_search_term_2, t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num,
decode(t2.cf_item,
'250',
t1.inv_invoice_bp_bank_account,
t1.invoice_bp_bank_account) invoice_bp_bank_account,
decode(t2.cf_item,
'250',
t1.inv_tax_registry_num,
t1.tax_registry_num) tax_registry_num,
t1.document_type, t1.document_type,
t1.bp_name, t1.bp_name,
decode(t2.cf_item,'250',t1.inv_invoice_type_desc,t1.invoice_type_desc) invoice_type_desc, decode(t2.cf_item,
'250',
t1.inv_invoice_type_desc,
t1.invoice_type_desc) invoice_type_desc,
t2.cashflow_id, t2.cashflow_id,
t2.cf_item, t2.cf_item,
t2.cf_item_desc, (Select i.description
From hls_cashflow_item i
Where i.cf_item = t2.cf_item) As cf_item_desc,
t2.times, t2.times,
t2.last_received_date, t2.last_received_date,
t2.due_date, t2.due_date,
t2.due_amount, t2.due_amount,
to_char((SELECT wm_concat(distinct c.bp_bank_account_name) to_char((SELECT wm_concat(distinct
c.bp_bank_account_name)
FROM csh_transaction c FROM csh_transaction c
WHERE c.transaction_id IN WHERE c.transaction_id IN
(SELECT coo.csh_transaction_id (SELECT coo.csh_transaction_id
FROM csh_write_off coo FROM csh_write_off coo
WHERE coo.cashflow_id = t2.cashflow_id))) account_name, WHERE coo.cashflow_id = t2.cashflow_id))) account_name,
decode(t1.lease_channel,'01',null,t2.principal) principal, decode(t1.lease_channel, '01', null, t2.principal) principal,
decode(t1.lease_channel,'01',null,t2.interest) interest, decode(t1.lease_channel, '01', null, t2.interest) interest,
t2.received_amount, t2.received_amount,
decode(t1.lease_channel,'01',null,t2.received_principal) received_principal, decode(t1.lease_channel,
decode(t1.lease_channel,'01',null,t2.received_interest) received_interest, '01',
null,
t2.received_principal) received_principal,
decode(t1.lease_channel,
'01',
null,
t2.received_interest) received_interest,
t2.billing_amount, t2.billing_amount,
t2.billing_principal, t2.billing_principal,
t2.billing_interest, t2.billing_interest,
...@@ -70,13 +114,9 @@ ...@@ -70,13 +114,9 @@
t2.net_due_amount, t2.net_due_amount,
t2.net_principal, t2.net_principal,
t2.net_interest, t2.net_interest,
t2.currency,
t2.currency_desc,
t2.exchange_rate, t2.exchange_rate,
t2.exchange_rate_type, t2.exchange_rate_type,
t2.exchange_rate_type_desc,
t2.exchange_rate_quotation, t2.exchange_rate_quotation,
t2.exchange_rate_quotation_desc,
t2.overdue_status, t2.overdue_status,
t2.write_off_flag, t2.write_off_flag,
t2.overdue_max_days, t2.overdue_max_days,
...@@ -89,36 +129,103 @@ ...@@ -89,36 +129,103 @@
t2.cf_status, t2.cf_status,
t1.business_type, t1.business_type,
t1.business_type_desc t1.business_type_desc
from acr_invoice_contract_v t1, ACR_INVOICE_CONTRACT_CF_V t2 from cus_acr_invoice_contract_v t1,
where con_contract_cashflow t2
t1.contract_id=t2.contract_id where t1.contract_id = t2.contract_id
and t1.bp_wfl_status = 'APPROVED'
and t1.invoice_wfl_status = 'APPROVED'
and (t1.invoice_method = 'BILLING' or
(t1.invoice_method = 'NO_BILLING' and
((t1.bill_object_bp_class = 'NP' and
t1.inv_billing_object_code <> 'D00000009' AND
((to_number(to_char(sysdate, 'MM')) in
(3, 6, 9, 12) and trunc(t2.due_date) <= sysdate
and ((to_number(to_char(t2.due_date, 'MM')) in
(3, 6, 9, 12)) or
(to_number(to_char(t2.due_date, 'MM')) in
(1, 4, 7, 10) and
nextduedate(t2.due_date, 2, 1) <= sysdate) or
(to_number(to_char(t2.due_date, 'MM')) in
(2, 5, 8, 11) and
nextduedate(t2.due_date, 1, 1) <= sysdate))
) or (
to_number(to_char(sysdate, 'MM')) in (1, 2) and
trunc(t2.due_date) <=
(trunc(sysdate, 'yyyy') - 1)) or
(
to_number(to_char(sysdate, 'MM')) in (4, 5) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-03',
'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (7, 8) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-06',
'yyyy-mm'))) or
(to_number(to_char(sysdate, 'MM')) in (10, 11) and
t2.due_date <=
last_day(to_date(to_char(sysdate, 'yyyy') ||
'-09',
'yyyy-mm'))))) or
((t1.bill_object_bp_class = 'ORG' or
(t1.inv_billing_object_code = 'D00000009' and
t1.bill_object_bp_class = 'NP')) AND
t1.contract_status in ('TERMINATE', 'ET', 'REPUR')))))
and ((decode(t2.cf_item, and ((decode(t2.cf_item,
'250', '250',
t1.inv_object_taxpayer_type, t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) = 'SMALL_SCALE_TAXPAYER' and t1.object_taxpayer_type) =
to_char(t2.due_date,'yyyy-mm') <= to_char(SYSDATE,'yyyy-mm')) or (t2.write_off_flag = 'FULL' and t1.contract_status not in('REPURING','REPUR')) or(nvl(t2.write_off_flag,'NOT')='FULL' and t1.contract_status in('REPURING','REPUR') and t2.cf_item<>1) or (nvl(t2.write_off_flag,'NOT') <> 'NOT' and t1.contract_status in('REPURING','REPUR') and t2.cf_item=1 ) ) 'SMALL_SCALE_TAXPAYER' and
AND cf_item<> 9 to_char(t2.due_date, 'yyyy-mm') <=
AND ((t2.cf_status='RELEASE' and t1.contract_status not in('REPURING','REPUR') and t2.cf_direction='INFLOW') or(t1.contract_status in ('REPURING','REPUR') and t2.cf_item in(1,2,250) and t2.cf_status='RELEASE' )or ( t2.cf_status in('BLOCK') and nvl(t2.write_off_flag,'NOT')='PARTIAL' and nvl(t2.billing_status,'NOT') != 'FULL' and t1.contract_status in ('REPURING','REPUR') and t2.cf_item =1 and t2.cf_direction='NONCASH' and nvl(t2.billing_amount,0) <> t2.received_amount)) to_char(SYSDATE, 'yyyy-mm')) or
and t2.cashflow_id not in (20265,34267,24445) (t2.write_off_flag = 'FULL' and
and nvl(t2.billing_status,'NOT') != 'FULL' t1.contract_status not in ('REPURING', 'REPUR')) or
(nvl(t2.write_off_flag, 'NOT') = 'FULL' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item <> 1) or
(nvl(t2.write_off_flag, 'NOT') <> 'NOT' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item = 1))
AND cf_item <> 9
AND ((t2.cf_status = 'RELEASE' and
t1.contract_status not in ('REPURING', 'REPUR') and
t2.cf_direction = 'INFLOW') or
(t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item in (1, 2, 250) and
t2.cf_status = 'RELEASE') or
(t2.cf_status in ('BLOCK') and
nvl(t2.write_off_flag, 'NOT') = 'PARTIAL' and
nvl(t2.billing_status, 'NOT') != 'FULL' and
t1.contract_status in ('REPURING', 'REPUR') and
t2.cf_item = 1 and t2.cf_direction = 'NONCASH' and
nvl(t2.billing_amount, 0) <> t2.received_amount))
and t2.cashflow_id not in (20265, 34267, 24445)
and nvl(t2.billing_status, 'NOT') != 'FULL'
--and t2.cf_direction='INFLOW' --and t2.cf_direction='INFLOW'
and ((decode(t2.cf_item, and ((decode(t2.cf_item,
'250', '250',
t1.inv_object_taxpayer_type, t1.inv_object_taxpayer_type,
t1.object_taxpayer_type) <> 'SMALL_SCALE_TAXPAYER' and t1.object_taxpayer_type) <>
received_amount>0) OR (decode(t2.cf_item, 'SMALL_SCALE_TAXPAYER' and received_amount > 0) OR
(decode(t2.cf_item,
'250', '250',
t1.inv_object_taxpayer_type, t1.inv_object_taxpayer_type,
t1.object_taxpayer_type)= 'SMALL_SCALE_TAXPAYER')) t1.object_taxpayer_type) =
ORDER BY t1.contract_id,t2.due_date ) 'SMALL_SCALE_TAXPAYER'))
ORDER BY t1.contract_id, t2.due_date)
UNION ALL UNION ALL
select t1.spv_company_id, select t1.spv_company_id,
t2.journal_header_id, t2.journal_header_id,
t2.journal_line_id, t2.journal_line_id,
t1.company_id, t1.company_id,
t1.project_id, t1.project_id,
t1.project_number,
t1.project_name,
t1.contract_id, t1.contract_id,
t1.contract_number, t1.contract_number,
t1.contract_name, t1.contract_name,
...@@ -144,23 +251,21 @@ ...@@ -144,23 +251,21 @@
(t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num, (t1.invoice_bp_address_phone_num) invoice_bp_address_phone_num,
(t1.invoice_bp_bank_account) invoice_bp_bank_account, (t1.invoice_bp_bank_account) invoice_bp_bank_account,
(t1.tax_registry_num) tax_registry_num, (t1.tax_registry_num) tax_registry_num,
t1.prj_search_term_1,
t1.prj_search_term_2,
t1.con_search_term_1,
t1.con_search_term_2,
t1.document_type, t1.document_type,
t1.bp_name, t1.bp_name,
(t1.invoice_type_desc) invoice_type_desc, (t1.invoice_type_desc) invoice_type_desc,
NULL cashflow_id, NULL cashflow_id,
9 cf_item, 9 cf_item,
(SELECT t.description FROM hls_cashflow_item t WHERE t.cf_item=9) cf_item_desc, (SELECT t.description
FROM hls_cashflow_item t
WHERE t.cf_item = 9) cf_item_desc,
null times, null times,
t2.transaction_date last_received_date, t2.transaction_date last_received_date,
NULL due_date, NULL due_date,
NULL due_amount, NULL due_amount,
(SELECT c.bp_bank_account_name (SELECT c.bp_bank_account_name
FROM csh_transaction c FROM csh_transaction c
WHERE c.transaction_id =t2.csh_transaction_id) account_name, WHERE c.transaction_id = t2.csh_transaction_id) account_name,
--NULL account_name, --NULL account_name,
NULL principal, NULL principal,
NULL interest, NULL interest,
...@@ -169,7 +274,8 @@ ...@@ -169,7 +274,8 @@
NULL received_interest, NULL received_interest,
nvl((SELECT SUM(l.total_amount) nvl((SELECT SUM(l.total_amount)
FROM acr_invoice_ln l FROM acr_invoice_ln l
WHERE l.ref_n04 = t2.journal_line_id),0) billing_amount, WHERE l.ref_n04 = t2.journal_line_id),
0) billing_amount,
NULL billing_principal, NULL billing_principal,
NULL billing_interest, NULL billing_interest,
NULL vat_due_amount, NULL vat_due_amount,
...@@ -178,13 +284,9 @@ ...@@ -178,13 +284,9 @@
NULL net_due_amount, NULL net_due_amount,
NULL net_principal, NULL net_principal,
NULL net_interest, NULL net_interest,
NULL currency,
NULL currency_desc,
NULL exchange_rate, NULL exchange_rate,
NULL exchange_rate_type, NULL exchange_rate_type,
NULL exchange_rate_type_desc,
NULL exchange_rate_quotation, NULL exchange_rate_quotation,
NULL exchange_rate_quotation_desc,
NULL overdue_status, NULL overdue_status,
NULL write_off_flag, NULL write_off_flag,
NULL overdue_max_days, NULL overdue_max_days,
...@@ -197,17 +299,22 @@ ...@@ -197,17 +299,22 @@
NULL cf_status, NULL cf_status,
t1.business_type, t1.business_type,
t1.business_type_desc t1.business_type_desc
from acr_invoice_contract_v t1, acr_invoice_penalty_v t2 from cus_acr_invoice_contract_v t1, acr_invoice_penalty_v t2
where where t2.contract_id = t1.contract_id
t2.contract_id=t1.contract_id and t1.bp_wfl_status = 'APPROVED'
AND (NOT EXISTS (SELECT 1 and t1.invoice_wfl_status = 'APPROVED'
and (t1.invoice_method = 'BILLING' or
(t1.invoice_method = 'NO_BILLING' and
t1.contract_status in ('TERMINATE', 'ET', 'REPUR')))
AND NOT EXISTS
(SELECT 1
FROM acr_invoice_ln l FROM acr_invoice_ln l
WHERE l.ref_n04 = t2.journal_line_id WHERE l.ref_n04 = t2.journal_line_id
GROUP BY journal_line_id GROUP BY journal_line_id
HAVING SUM(l.total_amount)=t2.amount_dr) HAVING SUM(l.total_amount) = t2.amount_dr)
)
) vv
)vv
#WHERE_CLAUSE# #WHERE_CLAUSE#
]]></bm:query-sql> ]]></bm:query-sql>
...@@ -219,8 +326,8 @@ ...@@ -219,8 +326,8 @@
<bm:field name="journal_line_id" databaseType="NUMBER" datatype="java.lang.Long"/> <bm:field name="journal_line_id" databaseType="NUMBER" datatype="java.lang.Long"/>
<bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" required="true"/> <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID" required="true"/>
<bm:field name="project_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PROJECT_ID"/> <bm:field name="project_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PROJECT_ID"/>
<bm:field name="project_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NUMBER"/> <!-- <bm:field name="project_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NUMBER"/>-->
<bm:field name="project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NAME"/> <!-- <bm:field name="project_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PROJECT_NAME"/>-->
<bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" required="true"/> <bm:field name="contract_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CONTRACT_ID" required="true"/>
<bm:field name="contract_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NUMBER"/> <bm:field name="contract_number" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NUMBER"/>
<bm:field name="contract_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NAME"/> <bm:field name="contract_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CONTRACT_NAME"/>
...@@ -246,10 +353,10 @@ ...@@ -246,10 +353,10 @@
<bm:field name="invoice_bp_address_phone_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_ADDRESS_PHONE_NUM"/> <bm:field name="invoice_bp_address_phone_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_ADDRESS_PHONE_NUM"/>
<bm:field name="invoice_bp_bank_account" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_BANK_ACCOUNT"/> <bm:field name="invoice_bp_bank_account" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_BP_BANK_ACCOUNT"/>
<bm:field name="tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_REGISTRY_NUM"/> <bm:field name="tax_registry_num" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="TAX_REGISTRY_NUM"/>
<bm:field name="prj_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PRJ_SEARCH_TERM_1"/> <!-- <bm:field name="prj_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="PRJ_SEARCH_TERM_1"/>-->
<bm:field name="prj_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PRJ_SEARCH_TERM_2"/> <!-- <bm:field name="prj_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="PRJ_SEARCH_TERM_2"/>-->
<bm:field name="con_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CON_SEARCH_TERM_1"/> <!-- <bm:field name="con_search_term_1" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CON_SEARCH_TERM_1"/>-->
<bm:field name="con_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CON_SEARCH_TERM_2"/> <!-- <bm:field name="con_search_term_2" databaseType="NUMBER" datatype="java.lang.Long" physicalName="CON_SEARCH_TERM_2"/>-->
<bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" required="true"/> <bm:field name="document_type" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="DOCUMENT_TYPE" required="true"/>
<bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_NAME"/> <bm:field name="bp_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="BP_NAME"/>
<bm:field name="invoice_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TYPE_DESC"/> <bm:field name="invoice_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="INVOICE_TYPE_DESC"/>
...@@ -274,13 +381,13 @@ ...@@ -274,13 +381,13 @@
<bm:field name="net_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_DUE_AMOUNT"/> <bm:field name="net_due_amount" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_DUE_AMOUNT"/>
<bm:field name="net_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_PRINCIPAL"/> <bm:field name="net_principal" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_PRINCIPAL"/>
<bm:field name="net_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_INTEREST"/> <bm:field name="net_interest" databaseType="NUMBER" datatype="java.lang.Double" physicalName="NET_INTEREST"/>
<bm:field name="currency" databaseType="CHAR" datatype="java.lang.String" physicalName="CURRENCY"/> <!-- <bm:field name="currency" databaseType="CHAR" datatype="java.lang.String" physicalName="CURRENCY"/>-->
<bm:field name="currency_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CURRENCY_DESC"/> <!-- <bm:field name="currency_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="CURRENCY_DESC"/>-->
<bm:field name="exchange_rate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXCHANGE_RATE"/> <bm:field name="exchange_rate" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXCHANGE_RATE"/>
<bm:field name="exchange_rate_type" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE"/> <bm:field name="exchange_rate_type" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE"/>
<bm:field name="exchange_rate_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE_DESC"/> <!-- <bm:field name="exchange_rate_type_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_TYPE_DESC"/>-->
<bm:field name="exchange_rate_quotation" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION"/> <bm:field name="exchange_rate_quotation" databaseType="CHAR" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION"/>
<bm:field name="exchange_rate_quotation_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION_DESC"/> <!-- <bm:field name="exchange_rate_quotation_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXCHANGE_RATE_QUOTATION_DESC"/>-->
<bm:field name="overdue_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OVERDUE_STATUS"/> <bm:field name="overdue_status" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="OVERDUE_STATUS"/>
<bm:field name="overdue_max_days" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_MAX_DAYS"/> <bm:field name="overdue_max_days" databaseType="NUMBER" datatype="java.lang.Long" physicalName="OVERDUE_MAX_DAYS"/>
<bm:field name="bp_id_agent_level1"/> <bm:field name="bp_id_agent_level1"/>
...@@ -334,7 +441,7 @@ ...@@ -334,7 +441,7 @@
<bm:data-filters> <bm:data-filters>
<bm:data-filter enforceOperations="query" expression="vv.contract_status not in ('CANCEL')"/> <bm:data-filter enforceOperations="query" expression="vv.contract_status not in ('CANCEL')"/>
<!--<bm:data-filter enforceOperations="query" expression="t1.contract_id = vv.contract_id"/>--> <!--<bm:data-filter enforceOperations="query" expression="t1.contract_id = vv.contract_id"/>-->
<!-- <bm:data-filter name="contract_status" enforceOperations="query" expression="vv.contract_status in(&apos;NEW&apos;,&apos;INCEPT&apos;,&apos;ETING&apos;,&apos;REPURING&apos;,&apos;CLOSED&apos;)"/>--> <!-- <bm:data-filter name="contract_status" enforceOperations="query" expression="vv.contract_status in(&apos;NEW&apos;,&apos;INCEPT&apos;,&apos;ETING&apos;,&apos;REPURING&apos;,&apos;CLOSED&apos;)"/>-->
</bm:data-filters> </bm:data-filters>
</bm:model> </bm:model>
...@@ -17,11 +17,13 @@ ...@@ -17,11 +17,13 @@
p_note => ${@note}, p_note => ${@note},
p_company_id => ${/session/@company_id}, p_company_id => ${/session/@company_id},
p_user_id => ${/session/@user_id}, p_user_id => ${/session/@user_id},
p_apply_mode => ${@apply_mode}); p_apply_mode => ${@apply_mode},
p_invoice_apply_num=> ${@invoice_apply_num});
end; end;
]]></bm:update-sql> ]]></bm:update-sql>
<bm:parameters> <bm:parameters>
<bm:parameter name="invoice_apply_id" dataType="java.lang.Long" input="false" output="true" outputPath="/parameter/@invoice_apply_id"/> <bm:parameter name="invoice_apply_id" dataType="java.lang.Long" input="false" output="true" outputPath="/parameter/@invoice_apply_id"/>
<bm:parameter name="invoice_apply_num" dataType="java.lang.String" input="false" output="true" outputPath="/parameter/@invoice_apply_num"/>
</bm:parameters> </bm:parameters>
</bm:operation> </bm:operation>
......
...@@ -8,53 +8,86 @@ ...@@ -8,53 +8,86 @@
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm"> <bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:operations> <bm:operations>
<bm:operation name="query"> <bm:operation name="query">
<bm:query-sql><![CDATA[ <bm:query-sql><![CDATA[
SELECT t1.invoice_hd_id, Select t.invoice_apply_id,
t1.document_number, t.invoice_apply_num,
TO_CHAR(t1.invoice_date, 'yyyy-mm-dd') as invoice_date, to_char(t.invoice_apply_date, 'yyyy-mm-dd') invoice_apply_date,
t1.document_category, t.invoice_apply_user,
t1.contract_id, (Select su.description
t1.contract_number, From sys_user su
t1.contract_name, Where su.user_id = t.invoice_apply_user) invoice_apply_user_n,
t1.project_id, t.wfl_instance_id,
t1.project_number, t.wfl_apply_status,
t1.project_name, (Select v.code_value_name
t1.invoice_bp_id, From sys_code_values_v v
t1.invoice_bp_code, Where v.code = 'WFL_STATUS'
t1.invoice_bp_name, And v.code_value = t.wfl_apply_status) wfl_apply_status_n,
t1.vat_interface_status, nvl((Select nvl(Sum(ah.total_amount), 0)
t1.vat_interface_status_desc, From acr_invoice_hd_wfl ah
t1.invoice_title, Where ah.invoice_apply_id = t.invoice_apply_id),
t1.invoice_number, 0) total_amount,
t1.invoice_status, nvl((Select nvl(Sum(ah.tax_amount), 0)
t1.invoice_status_desc, From acr_invoice_hd_wfl ah
t1.currency, Where ah.invoice_apply_id = t.invoice_apply_id),
t1.business_type, 0) tax_amount,
t1.business_type_desc, nvl((Select nvl(Sum(nvl(ah.total_amount, 0) - nvl(ah.tax_amount, 0)),
t1.invoice_kind, 0)
t1.invoice_kind_desc, From acr_invoice_hd_wfl ah
t1.document_type, Where ah.invoice_apply_id = t.invoice_apply_id),
t1.created_by_name, 0) net_amount,
t1.created_by, t.creation_date,
to_char(t1.accounting_date, 'yyyy-mm-dd') as accounting_date, t.created_by,
t1.total_amount, t.last_update_date,
t1.tax_amount, t.last_updated_by,
t1.billing_method, t.note,
t1.lease_organization, t.ref_v01,
t1.lease_channel, t.ref_v02,
t1.division, t.ref_v03,
t1.company_id, t.ref_v04,
t1.confirmed_by, t.ref_v05,
t1.confirmed_by_name, t.ref_n01,
t1.CREATE_JE_FLAG, t.ref_n02,
t1.vat_red_notice_num, t.ref_n03,
to_char(sysdate,'yyyy-mm-dd') as reverse_date t.ref_n04,
FROM acr_invoice_hd_v t1 t.ref_n05,
t.ref_d01,
t.ref_d02,
t.ref_d03,
t.ref_d04,
t.ref_d05,
t.apply_mode,
t.reverse_method,
(Select v.code_value_name
From sys_code_values_v v
Where v.code = 'REVERSE_METHOD'
And v.code_value = t.reverse_method
and v.code_enabled_flag = 'Y'
and v.code_value_enabled_flag = 'Y') As reverse_method_n,
(Select ahd.vat_interface_status
From acr_invoice_hd ahd,acr_invoice_hd_wfl ahdw
Where ahd.invoice_hd_id=ahdw.invoice_hd_id
and ahdw.invoice_apply_id=t.invoice_apply_id
and rownum=1) vat_interface_status,
(Select v.code_value_name
From sys_code_values_v v, acr_invoice_hd ahd,acr_invoice_hd_wfl ahdw
Where v.code = 'ACR515_VAT_INTERFACE_STATUS'
And v.code_value = ahd.vat_interface_status
and v.code_enabled_flag = 'Y'
and v.code_value_enabled_flag = 'Y'
and ahd.invoice_hd_id=ahdw.invoice_hd_id
and ahdw.invoice_apply_id=t.invoice_apply_id
and rownum=1) As vat_interface_status_n,
decode((select count(1)
from acr_invoice_hd ah, acr_invoice_hd_wfl ahw
where ah.invoice_hd_id = ahw.invoice_hd_id
and ahw.invoice_apply_id = t.invoice_apply_id
and nvl(ah.reversed_flag, 'N') = 'I'),0,'N','Y') reversing_flag
From acr_invoice_apply t
#WHERE_CLAUSE# #WHERE_CLAUSE#
ORDER BY t1.invoice_date desc , t1.document_number desc order by t.invoice_apply_id desc
]]></bm:query-sql> ]]></bm:query-sql>
</bm:operation> </bm:operation>
<bm:operation name="update"> <bm:operation name="update">
...@@ -70,35 +103,23 @@ ...@@ -70,35 +103,23 @@
</bm:operation> </bm:operation>
</bm:operations> </bm:operations>
<bm:query-fields> <bm:query-fields>
<bm:query-field name="document_number_f" queryExpression="t1.document_number &gt;= ${@document_number_f}"/> <bm:query-field name="invoice_apply_num"
<bm:query-field name="document_number_t" queryExpression="t1.document_number &lt;= ${@document_number_t}"/> queryExpression="t.invoice_apply_num like &apos;%&apos;||${@invoice_apply_num}||&apos;%&apos;"/>
<bm:query-field name="invoice_number_f" queryExpression="t1.invoice_number &gt;= ${@invoice_number_f}"/> <bm:query-field name="invoice_apply_date"
<bm:query-field name="invoice_number_t" queryExpression="t1.invoice_number &lt;= ${@invoice_number_t}"/> queryExpression="trunc(t.invoice_apply_date) = to_date(${@invoice_apply_date}, 'yyyy-mm-dd')"/>
<bm:query-field name="invoice_date_f" queryExpression="t1.invoice_date &gt;= to_date(${@invoice_date_f},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="invoice_apply_user_n" queryExpression="t.invoice_apply_user = ${@invoice_apply_user}"/>
<bm:query-field name="invoice_date_t" queryExpression="t1.invoice_date &lt;= to_date(${@invoice_date_t},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="wfl_apply_status_n" queryExpression="t.wfl_apply_status = ${@wfl_apply_status}"/>
<bm:query-field name="accounting_date_f" queryExpression="t1.accounting_date &gt;= to_date(${@accounting_date_f},&apos;yyyy-mm-dd&apos;)"/> <bm:query-field name="vat_interface_status_n"
<bm:query-field name="accounting_date_t" queryExpression="t1.accounting_date &lt;= to_date(${@accounting_date_t},&apos;yyyy-mm-dd&apos;)"/> queryExpression="t.vat_interface_status = ${@vat_interface_status}"/>
<bm:query-field name="total_amount_f" queryExpression="t1.total_amount &gt;= ${@total_amount_f}"/> <bm:query-field name="invoice_apply_id" queryExpression="t.invoice_apply_id = ${@invoice_apply_id}"/>
<bm:query-field name="total_amount_t" queryExpression="t1.total_amount &lt;= ${@total_amount_t}"/> <bm:query-field name="apply_mode" queryExpression="nvl(t.apply_mode, &apos;APPLY&apos;) = ${@apply_mode}"/>
<bm:query-field name="invoice_bp_code" queryExpression="t1.invoice_bp_code= ${@invoice_bp_code}"/>
<!--<bm:query-field name="invoice_bp_code_t" queryExpression="t1.invoice_bp_code &lt;= ${@invoice_bp_code_t}"/>-->
<bm:query-field name="currency" queryExpression="t1.currency = ${@currency}"/>
<bm:query-field name="invoice_status" queryExpression="t1.invoice_status = ${@invoice_status}"/>
<bm:query-field name="vat_interface_status" queryExpression="t1.vat_interface_status = ${@vat_interface_status}"/>
<bm:query-field name="business_type" queryExpression="t1.business_type = ${@business_type}"/>
<bm:query-field name="invoice_kind" queryExpression="t1.invoice_kind = ${@invoice_kind}"/>
<bm:query-field name="invoice_title" queryExpression="t1.invoice_title like ${@invoice_title}"/>
<bm:query-field name="created_by" queryExpression="t1.created_by = ${@created_by}"/>
<bm:query-field name="received_flag" queryExpression="(nvl(t1.express_status,&apos;UNDELIVERED&apos;) !=&apos;RECEIVED&apos; or ${@received_flag}=&apos;Y&apos;)"/>
<bm:query-field name="express_status" queryExpression="t1.express_status = ${@express_status}"/>
<bm:query-field name="confirmed_by" queryExpression="t1.confirmed_by = ${@confirmed_by}"/>
<bm:query-field name="query_contract_number" queryExpression="exists (select 1 from con_contract cc where t1.contract_id = cc.contract_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/>
<bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/>
</bm:query-fields> </bm:query-fields>
<bm:data-filters> <bm:data-filters>
<bm:data-filter enforceOperations="query" expression="t1.company_id = ${/session/@company_id}"/> <bm:data-filter enforceOperations="query" expression="t.wfl_apply_status = &apos;APPROVED&apos;"/>
<bm:data-filter enforceOperations="query" expression="t1.reversed_flag = &apos;N&apos;"/> <bm:data-filter enforceOperations="query" expression="exists (select 1
<bm:data-filter enforceOperations="query" expression="t1.invoice_status IN (&apos;CONFIRM&apos;, &apos;POST&apos;)"/> from acr_invoice_hd ah, acr_invoice_hd_wfl ahw
<bm:data-filter enforceOperations="query" expression="not exists (select 1 from acr_invoice_hd_wfl ah where ah.invoice_hd_id = t1.invoice_hd_id and ah.reversed_flag = &apos;I&apos;)"/> where ah.invoice_hd_id = ahw.invoice_hd_id
and ahw.invoice_apply_id = t.invoice_apply_id
and nvl(ah.reversed_flag, 'N') = 'N')" />
</bm:data-filters> </bm:data-filters>
</bm:model> </bm:model>
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: DJ
$Date: 2013-4-13 下午03:08:40
$Revision: 1.0
$Purpose: session中的信息
-->
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm" needAccessControl="false">
<bm:fields>
<bm:field name="today" datatype="java.util.Date"/>
<bm:field name="current_year" datatype="java.lang.Long"/>
<bm:field name="current_month" datatype="java.lang.Long"/>
<bm:field name="current_day" datatype="java.lang.Long"/>
<bm:field name="never_date" datatype="java.util.Date"/>
<bm:field name="company_id" datatype="java.lang.Long"/>
<bm:field name="company_code" datatype="java.lang.String"/>
<bm:field name="company_short_name" datatype="java.lang.String"/>
<bm:field name="company_full_name" datatype="java.lang.String"/>
<bm:field name="role_id" datatype="java.lang.Long"/>
<bm:field name="role_name" datatype="java.lang.String"/>
<bm:field name="role_code" datatype="java.lang.String"/>
<bm:field name="country_id" datatype="java.lang.Long"/>
<bm:field name="country_name" datatype="java.lang.String"/>
<bm:field name="lease_channel" datatype="java.lang.String"/>
<bm:field name="lease_channel_desc" datatype="java.lang.String"/>
<bm:field name="division" datatype="java.lang.String"/>
<bm:field name="division_desc" datatype="java.lang.String"/>
<bm:field name="lease_organization" datatype="java.lang.String"/>
<bm:field name="lease_organization_desc" datatype="java.lang.String"/>
<bm:field name="currency_code" datatype="java.lang.String"/>
<bm:field name="currency_name" datatype="java.lang.String"/>
<bm:field name="user_name" datatype="java.lang.String"/>
<bm:field name="user_desc" datatype="java.lang.String"/>
<bm:field name="bp_category" datatype="java.lang.String"/>
</bm:fields>
<bm:operations>
<bm:operation name="query">
<bm:query-sql><![CDATA[
select to_char(sysdate, 'yyyy-mm-dd') as today,
to_char(sysdate, 'yyyy') as current_year,
to_number(to_char(sysdate, 'mm')) as current_month,
to_number(to_char(sysdate, 'dd')) as current_day,
'3000-01-01' as never_date,
t1.company_id,
t1.company_code,
t1.company_short_name,
t1.company_full_name,
t2.role_id,
t2.role_name,
t2.role_code,
t3.country_id,
t3.description as country_name,
t4.lease_channel,
t4.description as lease_channel_desc,
t5.division,
t5.description as division_desc,
t6.lease_organization,
t6.description as lease_organization_desc,
t7.currency_code,
t7.currency_name,
t8.user_name,
t8.description as user_desc,
t8.bp_category
from dual t
left join fnd_companies_vl t1
on t1.company_id = ${/session/@company_id}
and t1.enabled_flag = 'Y'
left join sys_role_vl t2
on t2.role_id = ${/session/@role_id}
and t2.enabled_flag = 'Y'
left join fnd_country t3
on t3.country_code = 'CHN'
and t3.enabled_flag='Y'
left join hls_lease_channel t4
on t4.lease_channel = ${/session/@lease_channel}
and t4.enabled_flag='Y'
left join hls_division t5
on t5.division = ${/session/@division}
and t5.enabled_flag='Y'
left join hls_lease_organization t6
on t6.lease_organization = ${/session/@lease_organization}
and t6.enabled_flag='Y'
left join gld_currency_vl t7
on t7.currency_code='CNY'
and t7.enabled_flag='Y'
left join sys_user t8
on t8.user_id = ${/session/@user_id}
]]></bm:query-sql>
</bm:operation>
</bm:operations>
</bm:model>
...@@ -20,6 +20,17 @@ ...@@ -20,6 +20,17 @@
insert into ACR_INTERFACE_TMP(session_id,invoice_hd_id) values(${/session/@session_id},${@invoice_hd_id}) insert into ACR_INTERFACE_TMP(session_id,invoice_hd_id) values(${/session/@session_id},${@invoice_hd_id})
]]></bm:update-sql>
</bm:operation>
<bm:operation name="execute">
<bm:update-sql><![CDATA[
begin
acr_invoice_wfl_pkg.check_invoice_select_num(p_invoice_apply_id => ${@invoice_apply_id},
p_select_count => ${@select_count},
p_user_id => ${/session/@user_id});
end;
]]></bm:update-sql> ]]></bm:update-sql>
</bm:operation> </bm:operation>
</bm:operations> </bm:operations>
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
confirmed_by, confirmed_by,
contract_name, contract_name,
invoice_code, invoice_code,
to_char(accounting_date,'yyyy-mm-dd')accounting_date, to_char(accounting_date, 'yyyy-mm-dd') accounting_date,
ref_d04, ref_d04,
invoice_kind, invoice_kind,
contract_id, contract_id,
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
tax_code, tax_code,
description, description,
express_status, express_status,
to_char(invoice_date,'yyyy-mm-dd')invoice_date, to_char(invoice_date, 'yyyy-mm-dd') invoice_date,
manual_invoice_flag, manual_invoice_flag,
exchange_rate_type, exchange_rate_type,
document_category_desc, document_category_desc,
...@@ -125,11 +125,13 @@ ...@@ -125,11 +125,13 @@
division, division,
invoice_hd_id, invoice_hd_id,
ref_n07, ref_n07,
reversed_flag, nvl(reversed_flag,'N')reversed_flag,
claim_status, claim_status,
ref_n02, ref_n02,
vat_interface_status_desc vat_interface_status_desc,
invoice_apply_num,
ACR_INVOICE_WFL_PKG.get_invoice_transaction_flag(t1.invoice_hd_id)csh_transaction_flag,
decode(ACR_INVOICE_WFL_PKG.get_invoice_transaction_flag(t1.invoice_hd_id),'NOT','未收款','PARTIAL','部分收款','FULL','完全收款')csh_transaction_flag_desc
FROM acr_invoice_hd_v t1 FROM acr_invoice_hd_v t1
#WHERE_CLAUSE# #WHERE_CLAUSE#
...@@ -152,21 +154,23 @@ ...@@ -152,21 +154,23 @@
<bm:query-field name="invoice_status_desc" queryExpression="t1.invoice_status_desc = ${@invoice_status_desc}"/> <bm:query-field name="invoice_status_desc" queryExpression="t1.invoice_status_desc = ${@invoice_status_desc}"/>
<bm:query-field name="claim_status" queryExpression="t1.claim_status = ${@claim_status}"/> <bm:query-field name="claim_status" queryExpression="t1.claim_status = ${@claim_status}"/>
<bm:query-field name="claim_status_n" queryExpression="t1.claim_status_n = ${@claim_status_n}"/> <bm:query-field name="claim_status_n" queryExpression="t1.claim_status_n = ${@claim_status_n}"/>
<bm:query-field name="csh_transaction_flag" queryExpression="t1.csh_transaction_flag = ${@csh_transaction_flag}"/>
<bm:query-field name="cf_item_desc" queryExpression="t1.cf_item_desc = ${@cf_item_desc}"/> <bm:query-field name="cf_item_desc" queryExpression="t1.cf_item_desc = ${@cf_item_desc}"/>
<bm:query-field name="document_number" queryExpression="t1.document_number like ${@document_number}"/> <bm:query-field name="document_number" queryExpression="t1.document_number like ${@document_number}"/>
<bm:query-field name="invoice_apply_num" queryExpression="t1.invoice_apply_num like ${@invoice_apply_num}"/>
<bm:query-field name="contract_number" queryExpression="t1.contract_number like ${@contract_number}"/> <bm:query-field name="contract_number" queryExpression="t1.contract_number like ${@contract_number}"/>
<bm:query-field name="contract_name" queryExpression="t1.contract_name like ${@contract_name}"/> <bm:query-field name="contract_name" queryExpression="t1.contract_name like ${@contract_name}"/>
<bm:query-field name="invoice_title" queryExpression="t1.invoice_title like ${@invoice_title}"/> <bm:query-field name="invoice_title" queryExpression="t1.invoice_title like ${@invoice_title}"/>
<bm:query-field name="invoice_code" queryExpression="t1.invoice_code like ${@invoice_code}"/> <bm:query-field name="invoice_code" queryExpression="t1.invoice_code like ${@invoice_code}"/>
<bm:query-field name="vat_invoice_code" queryExpression="t1.vat_invoice_code like ${@vat_invoice_code}"/> <bm:query-field name="vat_invoice_code" queryExpression="t1.vat_invoice_code like ${@vat_invoice_code}"/>
<bm:query-field name="invoice_number" queryExpression="t1.invoice_number like ${@invoice_number}"/> <bm:query-field name="invoice_number" queryExpression="t1.invoice_number like ${@invoice_number}"/>
<bm:query-field name="invoice_date_from" queryExpression=" trunc(t1.invoice_date) &gt;= to_date(${@invoice_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="invoice_date_to" queryExpression="trunct1.invoice_date) &lt;= to_date(${@invoice_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="query_contract_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, con_contract cc where df.contract_id = cc.contract_id and df.ar_invoice_hd_id = t1.invoice_hd_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/> <bm:query-field name="query_contract_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, con_contract cc where df.contract_id = cc.contract_id and df.ar_invoice_hd_id = t1.invoice_hd_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/>
<bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/> <bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/>
</bm:query-fields> </bm:query-fields>
<bm:data-filters> <bm:data-filters>
<!-- <bm:data-filter enforceOperations="query" expression="t1.contract_id = t2.contract_id"/>--> <bm:data-filter enforceOperations="query" expression="nvl(t1.reversed_flag ,'N')= &apos;N&apos;"/>
<!-- <bm:data-filter enforceOperations="query" expression="t2.write_off_flag = &apos;FULL&apos;"/>--> <!-- <bm:data-filter enforceOperations="query" expression="t2.write_off_flag = &apos;FULL&apos;"/>-->
<bm:data-filter enforceOperations="query" expression="t1.vat_interface_status = &apos;BACK&apos;"/> <bm:data-filter enforceOperations="query" expression="t1.vat_interface_status = &apos;BACK&apos;"/>
<!-- <bm:data-filter name="query" expression="rownum &lt;=1000"/>--> <!-- <bm:data-filter name="query" expression="rownum &lt;=1000"/>-->
......
...@@ -128,7 +128,9 @@ ...@@ -128,7 +128,9 @@
reversed_flag, reversed_flag,
claim_status, claim_status,
ref_n02, ref_n02,
vat_interface_status_desc invoice_apply_num,
ACR_INVOICE_WFL_PKG.get_invoice_transaction_flag(t1.invoice_hd_id)csh_transaction_flag,
decode(ACR_INVOICE_WFL_PKG.get_invoice_transaction_flag(t1.invoice_hd_id),'NOT','未收款','PARTIAL','部分收款','FULL','完全收款')csh_transaction_flag_desc
FROM acr_invoice_hd_v t1 FROM acr_invoice_hd_v t1
#WHERE_CLAUSE# #WHERE_CLAUSE#
...@@ -157,10 +159,12 @@ ...@@ -157,10 +159,12 @@
<bm:query-field name="contract_number" queryExpression="t1.contract_number like ${@contract_number}"/> <bm:query-field name="contract_number" queryExpression="t1.contract_number like ${@contract_number}"/>
<bm:query-field name="contract_name" queryExpression="t1.contract_name like ${@contract_name}"/> <bm:query-field name="contract_name" queryExpression="t1.contract_name like ${@contract_name}"/>
<bm:query-field name="invoice_title" queryExpression="t1.invoice_title like ${@invoice_title}"/> <bm:query-field name="invoice_title" queryExpression="t1.invoice_title like ${@invoice_title}"/>
<bm:query-field name="invoice_apply_num" queryExpression="t1.invoice_apply_num like ${@invoice_apply_num}"/>
<bm:query-field name="invoice_code" queryExpression="t1.invoice_code like ${@invoice_code}"/> <bm:query-field name="invoice_code" queryExpression="t1.invoice_code like ${@invoice_code}"/>
<bm:query-field name="vat_invoice_code" queryExpression="t1.vat_invoice_code like ${@vat_invoice_code}"/> <bm:query-field name="vat_invoice_code" queryExpression="t1.vat_invoice_code like ${@vat_invoice_code}"/>
<bm:query-field name="invoice_number" queryExpression="t1.invoice_number like ${@invoice_number}"/> <bm:query-field name="invoice_number" queryExpression="t1.invoice_number like ${@invoice_number}"/>
<bm:query-field name="invoice_date_from" queryExpression=" trunc(t1.invoice_date) &gt;= to_date(${@invoice_date_from},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="invoice_date_to" queryExpression="trunct1.invoice_date) &lt;= to_date(${@invoice_date_to},&apos;yyyy-mm-dd&apos;)"/>
<bm:query-field name="query_contract_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, con_contract cc where df.contract_id = cc.contract_id and df.ar_invoice_hd_id = t1.invoice_hd_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/> <bm:query-field name="query_contract_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, con_contract cc where df.contract_id = cc.contract_id and df.ar_invoice_hd_id = t1.invoice_hd_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/>
<bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/> <bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/>
</bm:query-fields> </bm:query-fields>
......
...@@ -33,99 +33,19 @@ ...@@ -33,99 +33,19 @@
(Select t.times (Select t.times
From con_contract_cashflow t From con_contract_cashflow t
Where t.cashflow_id = al.cashflow_id)) times, Where t.cashflow_id = al.cashflow_id)) times,
decode(al.cf_item,
9,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h
Where h.journal_header_id = al.ref_n03
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code =
'HL_CSH_CONSOLIDATION_DALAY_CM')
And rownum = 1),
1,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_SALES_TAX_ACT_NEW',
'HL_SALES_TAX_ACT_NEW_LB'))
And rownum = 1),
2,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code =
'HL_INCEPT_DOWN_PAYMENT_CF')
And rownum = 1),
11,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code =
'HL_CON_FIN_ETFEE_N')
And rownum = 1),
250,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_FIN_INCOME_REPURCHASE',
'HL_FIN_INCOME_REPURCHASE_N'))
And rownum = 1),
200,
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists
(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_CON_TAX_ET', 'HL_CON_TAX_ET_N'))
And rownum = 1),
8,
(Select to_char(h.journal_date, 'yyyy-mm') (Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id And ((l.cashflow_id = al.cashflow_id
And Exists and al.cf_item<>9) or (al.ref_n04=l.journal_line_id and al.cf_item=9))
(Select 1 And rownum = 1) journal_month,
From gld_je_template_hds jh (Select h.journal_num
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_CON_TAX_ET', 'HL_CON_TAX_ET_N'))
And rownum = 1),
(Select to_char(h.journal_date, 'yyyy-mm')
From hls_journal_header h, hls_journal_detail l From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id And ((l.cashflow_id = al.cashflow_id
And rownum = 1)) journal_month, and al.cf_item<>9) or (al.ref_n04=l.journal_line_id and al.cf_item=9))
And rownum = 1) journal_num,
al.tax_type_rate, al.tax_type_rate,
al.total_amount, al.total_amount,
...@@ -158,113 +78,6 @@ ...@@ -158,113 +78,6 @@
(Select ctr.transaction_num (Select ctr.transaction_num
From csh_transaction ctr From csh_transaction ctr
Where ctr.transaction_id = cwo.csh_transaction_id) transaction_num, Where ctr.transaction_id = cwo.csh_transaction_id) transaction_num,
decode(al.cf_item,
9,
(Select h.journal_num
From hls_journal_header h
Where h.journal_header_id = al.ref_n03
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code =
'HL_CSH_CONSOLIDATION_DALAY_CM')
And rownum = 1),
1,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_SALES_TAX_ACT_NEW',
'HL_SALES_TAX_ACT_NEW_LB'))
And rownum = 1),
101,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_SALES_TAX_ACT_NEW',
'HL_SALES_TAX_ACT_NEW_LB'))
And rownum = 1),
2,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code =
'HL_INCEPT_DOWN_PAYMENT_CF')
And rownum = 1),
11,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code =
'HL_CON_FIN_ETFEE_N')
And rownum = 1),
250,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_FIN_INCOME_REPURCHASE',
'HL_FIN_INCOME_REPURCHASE_N'))
And rownum = 1),
200,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists
(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_CON_TAX_ET', 'HL_CON_TAX_ET_N'))
And rownum = 1),
8,
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And Exists
(Select 1
From gld_je_template_hds jh
Where jh.je_template_hd_id =
h.je_template_hd_id
And jh.je_template_code In
('HL_CON_TAX_ET', 'HL_CON_TAX_ET_N'))
And rownum = 1),
(Select h.journal_num
From hls_journal_header h, hls_journal_detail l
Where h.journal_header_id = l.journal_header_id
And l.cashflow_id = cwo.cashflow_id
And rownum = 1)) journal_num,
ah.invoice_hd_id, ah.invoice_hd_id,
(cwo.write_off_id + al.invoice_ln_wfl_id) file_id (cwo.write_off_id + al.invoice_ln_wfl_id) file_id
From acr_invoice_apply aa, From acr_invoice_apply aa,
......
...@@ -37,24 +37,38 @@ ...@@ -37,24 +37,38 @@
From sys_code_values_v v From sys_code_values_v v
Where v.code = 'ACR510_AR_INVOICE_STATUS' Where v.code = 'ACR510_AR_INVOICE_STATUS'
And v.code_value = h.invoice_status) invoice_status_n, And v.code_value = h.invoice_status) invoice_status_n,
(decode((Select he.status (Select ahd.vat_interface_status
From acr_ele_invoice_hd he From acr_invoice_hd ahd
Where he.invoice_hd_id = h.invoice_hd_id), Where ahd.invoice_hd_id=h.invoice_hd_id) vat_interface_status,
'DOWNLOAD',
'BACK',
h.vat_interface_status)) vat_interface_status,
(Select v.code_value_name (Select v.code_value_name
From sys_code_values_v v From sys_code_values_v v, acr_invoice_hd ahd
Where v.code = 'ACR515_VAT_INTERFACE_STATUS' Where v.code = 'ACR515_VAT_INTERFACE_STATUS'
And v.code_value = And v.code_value = ahd.vat_interface_status
(decode((Select he.status and v.code_enabled_flag = 'Y'
From acr_ele_invoice_hd he and v.code_value_enabled_flag = 'Y'
Where he.invoice_hd_id = h.invoice_hd_id), and ahd.invoice_hd_id=h.invoice_hd_id) As vat_interface_status_n,
'DOWNLOAD',
'金税已回写',
h.vat_interface_status))) vat_interface_status_n,
to_char(h.accounting_date, 'yyyy-mm-dd') accounting_date, to_char(h.accounting_date, 'yyyy-mm-dd') accounting_date,
h.vat_red_notice_num h.vat_red_notice_num,
h.invoice_hd_id,
(Select he.reversed_flag
From acr_invoice_hd he
Where he.invoice_hd_id = h.invoice_hd_id)reversed_flag,
(Select v.code_value_name
From sys_code_values_v v,acr_invoice_hd he
Where v.code = 'ACR514_AR_INVOICE_REVERSED_FLAG'
And v.code_value =nvl(he.reversed_flag,'N')
and he.invoice_hd_id = h.invoice_hd_id)reversed_flag_n,
NVL((Select he.claim_status
From acr_invoice_hd he
Where he.invoice_hd_id = h.invoice_hd_id),'UNCLAIMED')claim_status,
(select v.code_value_name
from sys_code_values_v v
where v.code = 'CLAIM_STATUS'
and v.code_value = NVL((Select he.claim_status
From acr_invoice_hd he
Where he.invoice_hd_id = h.invoice_hd_id),'UNCLAIMED'))claim_status_n
From acr_invoice_hd_wfl h #WHERE_CLAUSE# From acr_invoice_hd_wfl h #WHERE_CLAUSE#
order by h.invoice_hd_wfl_id desc order by h.invoice_hd_wfl_id desc
]]></bm:query-sql> ]]></bm:query-sql>
......
...@@ -113,6 +113,10 @@ ...@@ -113,6 +113,10 @@
<bm:field name="express_by" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXPRESS_BY"/> <bm:field name="express_by" databaseType="NUMBER" datatype="java.lang.Long" physicalName="EXPRESS_BY"/>
<bm:field name="express_note" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXPRESS_NOTE" prompt="ACR.EXPRESS_NOTE"/> <bm:field name="express_note" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="EXPRESS_NOTE" prompt="ACR.EXPRESS_NOTE"/>
<bm:field name="billing_way_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="billing_way_desc" prompt="开票方式"/> <bm:field name="billing_way_desc" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="billing_way_desc" prompt="开票方式"/>
<bm:field name="invoice_apply_num" expression="(select ap.invoice_apply_num from acr_invoice_apply ap, acr_invoice_hd_wfl aw where ap.wfl_apply_status='APPROVED' and ap.apply_mode='APPLY' and ap.invoice_apply_id=aw.invoice_apply_id
and aw.invoice_hd_id=t1.invoice_hd_id)"/>
<bm:field name="invoice_apply_id" expression="(select ap.invoice_apply_id from acr_invoice_apply ap, acr_invoice_hd_wfl aw where ap.wfl_apply_status='APPROVED' and ap.apply_mode='APPLY' and ap.invoice_apply_id=aw.invoice_apply_id
and aw.invoice_hd_id=t1.invoice_hd_id)"/>
</bm:fields> </bm:fields>
<bm:query-fields> <bm:query-fields>
<bm:query-field name="document_number_f" queryExpression="t1.document_number &gt;= ${@document_number_f}"/> <bm:query-field name="document_number_f" queryExpression="t1.document_number &gt;= ${@document_number_f}"/>
...@@ -141,6 +145,8 @@ ...@@ -141,6 +145,8 @@
<bm:query-field name="confirmed_by" queryExpression="t1.confirmed_by = ${@confirmed_by}"/> <bm:query-field name="confirmed_by" queryExpression="t1.confirmed_by = ${@confirmed_by}"/>
<bm:query-field name="query_contract_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, con_contract cc where df.contract_id = cc.contract_id and df.ar_invoice_hd_id = t1.invoice_hd_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/> <bm:query-field name="query_contract_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, con_contract cc where df.contract_id = cc.contract_id and df.ar_invoice_hd_id = t1.invoice_hd_id and cc.contract_number between nvl(${@contract_number_f}, cc.contract_number) and nvl(${@contract_number_t}, cc.contract_number))"/>
<bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/> <bm:query-field name="query_project_number" queryExpression="exists (select 1 from hls_document_flow_all_v df, prj_project pp where df.ar_invoice_hd_id = t1.invoice_hd_id and df.project_id = pp.project_id and pp.project_number between nvl(${@project_number_f}, pp.project_number) and nvl(${@project_number_t}, pp.project_number))"/>
<bm:query-field name="invoice_apply_num" queryExpression="${@invoice_apply_num}=(select ap.invoice_apply_num from acr_invoice_apply ap, acr_invoice_hd_wfl aw where ap.wfl_apply_status='APPROVED' and ap.apply_mode='APPLY' and ap.invoice_apply_id=aw.invoice_apply_id
and aw.invoice_hd_id=t1.invoice_hd_id)"/>
</bm:query-fields> </bm:query-fields>
<bm:data-filters> <bm:data-filters>
......
...@@ -184,6 +184,7 @@ ...@@ -184,6 +184,7 @@
(select to_char(due_date, 'yyyy-mm-dd') (select to_char(due_date, 'yyyy-mm-dd')
from con_contract_cashflow from con_contract_cashflow
where contract_id = ct.contract_id where contract_id = ct.contract_id
and cf_status='RELEASE'
and cf_item = and cf_item =
8) residual_date, 8) residual_date,
-- 合同终了 -- 合同终了
......
<?xml version="1.0" encoding="UTF-8"?>
<uncertain-engine defaultLogLevel="INFO">
<path-config logPath="E:\sanling\leaf-hlcm\logs" uiPackageBasePath="E:\sanling\leaf-hlcm\target\hlcm\lib\LeafUI\src"/>
</uncertain-engine>
...@@ -133,7 +133,7 @@ ...@@ -133,7 +133,7 @@
} }
var datas = ds.getJsonData(true); var datas = ds.getJsonData(true);
var lease_count=0, leaseback_count=0; var lease_count = 0, leaseback_count = 0;
for (var i = 0; i < datas.length; i++) { for (var i = 0; i < datas.length; i++) {
if (datas[i].business_type == 'LEASE') { if (datas[i].business_type == 'LEASE') {
lease_count = lease_count + 1; lease_count = lease_count + 1;
...@@ -267,6 +267,7 @@ ...@@ -267,6 +267,7 @@
<a:dataSet id="allConditionDs" autoCreate="true"> <a:dataSet id="allConditionDs" autoCreate="true">
<a:fields> <a:fields>
<a:field name="business_type"/> <a:field name="business_type"/>
<a:field name="bill_object_bp_class"/>
<a:field name="business_type_desc" displayField="code_value_name" options="business_type_desc_ds" <a:field name="business_type_desc" displayField="code_value_name" options="business_type_desc_ds"
returnField="business_type" valueField="code_value"/> returnField="business_type" valueField="code_value"/>
<a:field name="object_taxpayer_type_desc" displayField="code_value_name" options="taxpayer_type_ds" <a:field name="object_taxpayer_type_desc" displayField="code_value_name" options="taxpayer_type_ds"
...@@ -306,8 +307,11 @@ ...@@ -306,8 +307,11 @@
<a:field name="billing_object_name" lovGridHeight="300" lovHeight="450" lovLabelWidth="100" <a:field name="billing_object_name" lovGridHeight="300" lovHeight="450" lovLabelWidth="100"
lovService="basic.hls_bp_master_v_for_lov" lovWidth="600" title="承租人"> lovService="basic.hls_bp_master_v_for_lov" lovWidth="600" title="承租人">
<a:mapping> <a:mapping>
<a:map from="bp_code" to="billing_object_name"/> <a:map from="bp_code" to="billing_object_code"/>
<a:map from="bp_name" to="billing_object_name"/> <a:map from="bp_name" to="billing_object_name"/>
<a:map from="bp_id" to="billing_object_id"/>
<a:map from="bp_class" to="bill_object_bp_class"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="bp_code_tenant_from" lovGridHeight="300" lovHeight="450" lovLabelWidth="100" <a:field name="bp_code_tenant_from" lovGridHeight="300" lovHeight="450" lovLabelWidth="100"
...@@ -423,7 +427,7 @@ ...@@ -423,7 +427,7 @@
<a:gridButton click="contractDs_grid_clear" text="ACR510.BUTTON.CLEAR_CONTRACT"/> <a:gridButton click="contractDs_grid_clear" text="ACR510.BUTTON.CLEAR_CONTRACT"/>
<a:gridButton click="invoiceHd_confirm" text="ACR510.BUTTON.COMFIRM"/> <a:gridButton click="invoiceHd_confirm" text="ACR510.BUTTON.COMFIRM"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form id="condition_queryForm" width="1300"> <a:form id="condition_queryForm" marginWidth="55">
<a:hBox> <a:hBox>
<a:lov name="billing_object_name" bindTarget="allConditionDs" prompt="开票对象"/> <a:lov name="billing_object_name" bindTarget="allConditionDs" prompt="开票对象"/>
...@@ -446,6 +450,8 @@ ...@@ -446,6 +450,8 @@
<a:datePicker name="last_received_date_from" bindTarget="allConditionDs" prompt="收款日期从"/> <a:datePicker name="last_received_date_from" bindTarget="allConditionDs" prompt="收款日期从"/>
<a:datePicker name="last_received_date_to" bindTarget="allConditionDs" prompt="收款日期到"/> <a:datePicker name="last_received_date_to" bindTarget="allConditionDs" prompt="收款日期到"/>
<a:lov name="bp_id_agent_level1_n" bindTarget="allConditionDs" prompt="代理店"/> <a:lov name="bp_id_agent_level1_n" bindTarget="allConditionDs" prompt="代理店"/>
<a:comboBox name="bill_object_bp_class_desc" bindTarget="allConditionDs" prompt="商业伙伴分类"/>
</a:hBox> </a:hBox>
<!-- <a:formBody column="4" labelWidth="400"> <!-- <a:formBody column="4" labelWidth="400">
<a:lov name="contract_number_from" bindTarget="allConditionDs" prompt="HLS.CONTRACT_NUMBER_FROM"/> <a:lov name="contract_number_from" bindTarget="allConditionDs" prompt="HLS.CONTRACT_NUMBER_FROM"/>
...@@ -509,6 +515,8 @@ ...@@ -509,6 +515,8 @@
<!-- <a:column name="currency_desc" width="60"/> <!-- <a:column name="currency_desc" width="60"/>
<a:column name="exchange_rate" align="right" width="80"/> <a:column name="exchange_rate" align="right" width="80"/>
<a:column name="exchange_rate_type_desc" width="100"/> --> <a:column name="exchange_rate_type_desc" width="100"/> -->
<a:column name="bill_object_bp_class_desc" width="100" align="center" prompt="商业伙伴分类" />
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:tab> </a:tab>
......
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
<batch-apply sourcePath="/parameter/details"> <batch-apply sourcePath="/parameter/details">
<a:model-update model="acr.ACR512N.acr_invoice_update_for_submit" trace="true"/> <a:model-update model="acr.ACR512N.acr_invoice_update_for_submit" trace="true"/>
</batch-apply> </batch-apply>
<!-- <a:model-update model="acr.ACR610.acr_invoice_apply_query" trace="true"/>-->
</a:init-procedure> </a:init-procedure>
<a:service-output output="/parameter"/> <a:service-output output="/parameter"/>
</a:service> </a:service>
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!-- <!--
$Author: LR $Author: LR
$Date: 2013-7-18 上午09:34:43 $Date: 2013-7-15 下午04:39:15
$Revision: 1.0 $Revision: 1.0
$Purpose: $Purpose:
--> -->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true"> <a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true">
<a:init-procedure> <a:init-procedure>
<a:model-query fetchAll="true" model="gld.gld_currency_vl" rootPath="acr514_currency_list"/> <a:model-query model="cont.CON620.get_sys_role" rootPath="role_info"/>
<a:model-query fetchAll="true" model="acr.ACR512.acr_invoice_business_type_list" rootPath="acr514_business_type_list"/>
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="acr514_invoice_readonly_page" url="${/request/@context_path}/modules/cont/CON500/con_contract_update.lview"/> <a:link id="acr_invoice_apply_detail_link"
<a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/> url="${/request/@context_path}/modules/acr/ACR514/acr_invoice_reverse_apply_temp_detail.lview"/>
<a:link id="acr514_update_for_submit_id" url="${/request/@context_path}/modules/acr/ACR512/acr_invoice_update_for_submit.lsc"/> <a:link id="acr514_invoice_apply_status_change" model="acr.acr514.acr_invoice_apply_query"
<a:link id="acr_invoice_reverse_apply_detail_link" url="${/request/@context_path}/modules/acr/ACR620/acr_invoice_reverse_apply_detail.lview"/> modelaction="delete"/>
<script><![CDATA[ <script><![CDATA[
function lock_current_window() { function lock_current_window() {
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
} }
function unlock_current_window() { function unlock_current_window() {
Leaf.Masker.unmask(Ext.getBody()); Leaf.Masker.unmask(Ext.getBody(), '${l:HLS.EXECUTING}');
} }
function acr514_invoice_query() { function acr514_invoice_query() {
...@@ -30,407 +30,166 @@ ...@@ -30,407 +30,166 @@
} }
function acr514_invoice_reset() { function acr514_invoice_reset() {
$('acr514_invoice_query_ds').reset(); $('acr514_invoice_apply_query_ds').reset();
}
function acr514_formatMoney(value, record, name) {
return Leaf.formatNumber(value);
}
function acr514_invoice_query_Onupdate(ds, record, name, value, oldVlaue) {
if (name == 'document_number_f') {
if (Leaf.isEmpty(record.get('document_number_t'))) {
record.set('document_number_t', value);
}
} else if (name == 'project_number_f') {
if (Leaf.isEmpty(record.get('project_number_t'))) {
record.set('project_number_t', value);
}
} else if (name == 'invoice_number_f') {
if (Leaf.isEmpty(record.get('invoice_number_t'))) {
record.set('invoice_number_t', value);
}
} else if (name == 'contract_number_f') {
if (Leaf.isEmpty(record.get('contract_number_t'))) {
record.set('contract_number_t', value);
}
} else if (name == 'invoice_bp_code_f') {
if (Leaf.isEmpty(record.get('invoice_bp_code_t'))) {
record.set('invoice_bp_code_t', value);
}
} else if (name == 'total_amount_f') {
if (Leaf.isEmpty(record.get('total_amount_t'))) {
record.set('total_amount_t', value);
}
} }
if (Ext.isEmpty(record.get('project_number_f')) && Ext.isEmpty(record.get('project_number_t'))) { function acr514_grid_update(record_id, ds_id) {
record.set('query_project_number', ''); debugger;
} else { var readOnly_flag = 'N';
record.set('query_project_number', 'Y'); var url = $('acr_invoice_apply_detail_link').getUrl();
var record = $(ds_id).findById(record_id);
var param = record.data;
param['winId'] = 'acr_invoice_apply_detail_link_winid';
if (("${/model/role_info/record/@role_code}" != "0014" && record.get('vat_interface_status') == 'TRANSFERED')
|| (record.get('reversing_flag') == 'Y')) {
readOnly_flag = 'Y';
} }
if (Ext.isEmpty(record.get('contract_number_f')) && Ext.isEmpty(record.get('contract_number_t'))) { param['readOnly_flag'] = readOnly_flag;
record.set('query_contract_number', ''); var win = new Leaf.Window({
} else { id: 'acr_invoice_apply_detail_link_winid',
record.set('query_contract_number', 'Y'); params: param,
} url: url,
} title: '申请明细',
fullScreen: true
function acr514_grid_query(reocrd_id, invoice_hd_id, status) { });
var maintain_type = 'READONLY'; win.on('close', function () {
var currency_reocrd = $('acr514_invoice_result_ds').findById(reocrd_id); $('acr514_invoice_result_ds').query();
var param = currency_reocrd.data; });
param['function_code'] = 'ACR514';
param['document_id'] = invoice_hd_id;
param['function_usage'] = 'QUERY';
param['maintain_type'] = maintain_type;
param['url_title'] = '${l:ACR.INVOICE_DETAIL}';
hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'acr514_invoice_readonly_page', 'acr514_invoice_result_ds');
}
function acr514_document_number_render(value, record, name) {
return '<a href="javascript:acr514_grid_query(' + record.id + ',' + record.get('invoice_hd_id') + ',\'' + record.get('invoice_status') + '\');">' + value + '</a>';
}
function acr514_invoice_reverse() {
acr514_invoice_handle('REVERSE');
}
function acr514_invoice_invalid() {
acr514_invoice_handle('INVALID');
} }
function is_over_month(start_str, end_str) { function acr514_apply_num_render(value, record, name) {
var start = Leaf.formatDate(start_str); if (name == 'invoice_apply_num') {
var end = Leaf.formatDate(end_str); return '<a href="javascript:acr514_grid_update(\'' + record.id + '\',\'' + record.ds.id + '\')">' + value + '</a>';
var year = Number(end.substr(0, 4)) - Number(start.substr(0, 4));
var month = Number(end.substr(5, 2)) - Number(start.substr(5, 2));
var day = Number(end.substr(8, 2)) - Number(start.substr(8, 2));
if (year == 1 && month == -11 && day <= 0) {
return false;
}
if (year == 0 && month == 0) {
return false;
} }
if (year == 0 && month == 1 && day <= 0) {
return false;
} }
return true;
}
function acr514_invoice_handle(type) {
var ds = $('acr514_invoice_result_ds'); function acr514_formatMoney(value, record, name) {
var records = ds.getSelected(); return Leaf.formatNumber(value);
if (records.length == 0) {
return;
} }
if (type == 'REVERSE') { // function acr514_invoice_cancel() {
for (var i = 0;i < records.length;i++) { // var records = $('acr514_invoice_result_ds').getSelected();
if (records[i].get('invoice_kind') == '0') { // if (records.length == 0) {
records[i].getField('vat_red_notice_num').setRequired(true); // $L.showInfoMessage('提示', '请至少选择一条数据!');
} // return;
} // }
} else if (type == 'INVALID') { // var record = records[0];
for (var i = 0;i < records.length;i++) { // if(record.get('wfl_apply_status') != 'NEW'){
if (is_over_month(records[i].get('invoice_date'), records[i].get('reverse_date'))) { // $L.showInfoMessage('提示', '仅新建状态的申请单据可以取消!');
Leaf.showMessage('${l:HLS.PROMPT}', '单据号:' + records[i].get('document_number') + '日期跨月');
return;
}
}
// for (var i = 0;i < records.length;i++) {
// if (records[i].get('vat_interface_status')=='BACK') {
// Leaf.showMessage('${l:HLS.PROMPT}', '单据号:' + records[i].get('document_number') + '金税状态已回写,不可反冲');
// return; // return;
// } // }
//
// Leaf.showConfirm('提示', "确认执行该操作?", function () {
// lock_current_window();
// Leaf.request({
// url: $('acr514_invoice_apply_status_change').getUrl(),
// para: record.data,
// success: function () {
// unlock_current_window();
// Leaf.SideBar.show({
// msg: '操作成功',
// duration: 2000
// });
// $('acr514_invoice_result_ds').query();
// },
// error: function () {
// unlock_current_window();
// },
// scope: this
// });
// }, function () {
// unlock_current_window();
//
// });
// } // }
for (var i = 0;i < records.length;i++) { function acr514_invoice_result_select(ds, record, bp_seq) {
records[i].getField('vat_red_notice_num').setRequired(false); // if(record.get('wfl_apply_status') != 'NEW'){
} // document.getElementById("acr514_invoice_cancel_id").style.display = "none";
} else { // }else{
return; // document.getElementById("acr514_invoice_cancel_id").style.display = "";
} // }
// if(record.get('wfl_apply_status') == 'CANCEL'){
Leaf.showConfirm('${l:HLS.PROMPT}', '是否确认?', function() { // document.getElementById("acr514_invoice_print_id").style.display = "none";
ds.submitSelected(); // }else{
}, function() { // document.getElementById("acr514_invoice_print_id").style.display = "";
// }
});
}
function acr514_invoice_result_ds_submitsuccess(ds) {
$('acr514_invoice_grid_id').clear();
}
function vat_red_notice_num_editorFunction(record, name) {
if (record.get('invoice_kind') == '0') {
if (name == 'vat_red_notice_num') {
return 'invoice_grid_tf';
}
} }
return '';
}
function acr514_invoice_update(ds, record, name, value, oldVlaue)
{
var time,year,month,day,string;
var d,d_year_month;
if(name=='reverse_date')
{
time = new Date();
year = time.getFullYear();
month = time.getMonth()+1;
if(month<10)
string = String(year)+'0'+String(month);
else
string = String(year)+String(month);
d= new Date(value);
d_year=d.getFullYear();
d_month=d.getMonth()+1;
if(d_month<10)
d_year_month = String(d_year)+'0'+String(d_month);
else
d_year_month = String(d_year)+String(d_month);
//如果小于系统时间 // function acr514_invoice_print(){
if( d_year_month<string) // var record = $('acr514_invoice_result_ds').getSelected()[0];
{ // var document_id = record.get('invoice_apply_id');
record.getField('vat_red_notice_num').setRequired(true); // var url_l = $('acr_invoice_finish_print_link_id').getUrl() + '?document_id=' + document_id + '&document_table=ACR_INVOICE_APPLY&batch_flag=Y&source_type=COMMON';
// var OpenWindow = window.open(href = url_l, target = "_blank");
} // }
else
{
record.getField('vat_red_notice_num').setRequired(false);
}
record.set(name,value);
}
}
function acr514_invoice_insert() {
var records = $('acr514_invoice_result_ds').getSelected();
if (records.length < 1) {
Leaf.showMessage('${l:HLS.PROMPT}', '请选择需要审批的发票!');
return;
}
var datas = {};
var saveData = [];
var invoice_hd_ids = '';
for (var i = 0; i < records.length; i++) {
if (invoice_hd_ids == '') {
invoice_hd_ids = records[i].get('invoice_hd_id');
} else {
invoice_hd_ids = invoice_hd_ids + ',' + records[i].get('invoice_hd_id');
}
records[i].set('_status', 'update');
saveData.push(records[i].data);
}
saveData.sort(function (a, b) {
return a.invoice_hd_id - b.invoice_hd_id;
});
datas['invoice_hd_ids'] = invoice_hd_ids;
datas['apply_mode'] = 'REVERSE';
datas['details'] = saveData;
Leaf.showConfirm('提示', '<span style="color: #ff0000; ">所选发票即将创建反冲申请!如需要取消发票反冲申请,请点击取消申请!</span>', function () {
lock_current_window();
Leaf.request({
url: $('acr514_update_for_submit_id').getUrl(),
para: datas,
success: function (res) {
Leaf.SideBar.show({
msg: '申请成功',
duration: 3000
});
unlock_current_window();
var win = new Leaf.Window({
id: 'acr_invoice_reverse_apply_detail_link_winid',
params: {
invoice_apply_id: res.result.invoice_apply_id,
winId: 'acr_invoice_reverse_apply_detail_link_winid'
},
url: $('acr_invoice_reverse_apply_detail_link').getUrl(),
title: '申请明细',
fullScreen: true
});
win.on('close',function(){
$('acr514_invoice_result_ds').query();
});
},
failure: function () {
unlock_current_window();
},
error: function () {
unlock_current_window();
},
scope: this
});
});
}
]]></script> ]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/> <a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
<a:dataSets> <a:dataSets>
<a:dataSet id="acr514_business_type_ds"> <a:dataSet id="acr514_invoice_apply_status_ds" lookupCode="WFL_STATUS"/>
<a:datas dataSource="/model/acr514_business_type_list"/> <a:dataSet id="acr514_invoice_apply_query_ds">
</a:dataSet>
<a:dataSet id="acr514_currency_ds">
<a:datas dataSource="/model/acr514_currency_list"/>
</a:dataSet>
<a:dataSet id="acr514_invoice_kind_ds" lookupCode="ACR510_INVOICE_KIND"/>
<a:dataSet id="acr514_invoice_statu_ds" lookupCode="ACR510_AR_INVOICE_STATUS"/>
<a:dataSet id="acr514_express_status_ds" lookupCode="ACR518_EXPRESS_STATUS"/>
<a:dataSet id="acr514_vat_interface_status_ds" lookupCode="ACR515_VAT_INTERFACE_STATUS"/>
<a:dataSet id="acr514_invoice_query_ds" autoCreate="true">
<a:fields> <a:fields>
<a:field name="currency_name" displayField="currency_name" options="acr514_currency_ds" returnField="currency" valueField="currency_code"/> <a:field name="invoice_apply_num"/>
<a:field name="invoice_kind_desc" displayField="code_value_name" options="acr514_invoice_kind_ds" returnField="invoice_kind" valueField="code_value"/> <a:field name="invoice_apply_date"/>
<a:field name="invoice_status_desc" displayField="code_value_name" options="acr514_invoice_statu_ds" returnField="invoice_status" valueField="code_value"/> <a:field name="invoice_apply_user_n" lovGridHeight="320" lovHeight="500"
<a:field name="vat_interface_status_desc" displayField="code_value_name" options="acr514_vat_interface_status_ds" returnField="vat_interface_status" valueField="code_value"/> lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="开票人选择">
<a:field name="business_type_desc" displayField="business_type_desc" options="acr514_business_type_ds" returnField="business_type" valueField="business_type"/>
<a:field name="created_by_name" lovGridHeight="320" lovHeight="500" lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="开票人选择">
<a:mapping>
<a:map from="user_id" to="created_by"/>
<a:map from="description" to="created_by_name"/>
</a:mapping>
</a:field>
<a:field name="confirmed_by_name" lovGridHeight="320" lovHeight="500" lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="复核人选择">
<a:mapping>
<a:map from="user_id" to="confirmed_by"/>
<a:map from="description" to="confirmed_by_name"/>
</a:mapping>
</a:field>
<a:field name="invoice_bp_code_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500" title="客户选择">
<a:mapping>
<a:map from="bp_code" to="invoice_bp_code_f"/>
</a:mapping>
</a:field>
<a:field name="invoice_bp_code_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500" title="客户选择">
<a:mapping>
<a:map from="bp_code" to="invoice_bp_code_t"/>
</a:mapping>
</a:field>
<a:field name="project_number_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500" title="项目选择">
<a:mapping>
<a:map from="project_number" to="project_number_f"/>
</a:mapping>
</a:field>
<a:field name="project_number_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500" title="项目选择">
<a:mapping> <a:mapping>
<a:map from="project_number" to="project_number_t"/> <a:map from="user_id" to="invoice_apply_user"/>
<a:map from="description" to="invoice_apply_user_n"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="contract_number_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500" title="合同选择"> <a:field name="invoice_apply_user"/>
<a:mapping> <a:field name="wfl_apply_status_n" displayField="code_value_name"
<a:map from="contract_number" to="contract_number_f"/> options="acr514_invoice_apply_status_ds"
</a:mapping> returnField="wfl_apply_status" valueField="code_value"/>
</a:field>
<a:field name="contract_number_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500" title="合同选择">
<a:mapping>
<a:map from="contract_number" to="contract_number_t"/>
</a:mapping>
</a:field>
<a:field name="received_flag" checkedValue="Y" defaultValue="N" uncheckedValue="N"/>
<a:field name="express_status_name" displayField="code_value_name" options="acr514_express_status_ds" returnField="express_status" valueField="code_value"/>
</a:fields> </a:fields>
<a:events>
<a:event name="update" handler="acr514_invoice_query_Onupdate"/>
</a:events>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr514_invoice_result_ds" autoQuery="true" autoPageSize="true" model="acr.ACR514.acr_invoice_reverse" queryDataSet="acr514_invoice_query_ds" selectable="true"> <a:dataSet id="acr514_invoice_result_ds" autoPageSize="true" autoQuery="true"
<!--<a:fields> model="acr.ACR514.acr_invoice_reverse"
<a:field name="reverse_date" required="true"/> queryUrl="${/request/@context_path}/autocrud/acr.ACR514.acr_invoice_reverse/query?apply_mode=APPLY"
</a:fields> queryDataSet="acr514_invoice_apply_query_ds"
<a:events> selectable="true" selectionModel="single">
<a:event name="submitsuccess" handler="acr514_invoice_result_ds_submitsuccess"/> <!-- <a:events>-->
<a:event name="update" handler="acr514_invoice_update"/> <!-- <a:event name="select" handler="acr514_invoice_result_select"/>-->
</a:events>--> <!-- </a:events>-->
</a:dataSet> </a:dataSet>
</a:dataSets> </a:dataSets>
<a:screenBody> <a:screenBody>
<a:screenTopToolbar> <a:screenTopToolbar>
<a:screenTitle/> <a:screenTitle/>
<a:toolbarButton click="acr514_invoice_query" text="HLS.QUERY"/>
<a:toolbarButton click="acr514_invoice_reset" text="HLS.RESET"/> <a:toolbarButton click="acr514_invoice_reset" text="HLS.RESET"/>
<!-- <a:toolbarButton click="acr514_invoice_reverse" text="HLS.REVERSE"/>--> <a:toolbarButton click="acr514_invoice_query" text="HLS.QUERY"/>
<!--<a:toolbarButton click="acr514_invoice_invalid" text="作废"/>--> <!-- <a:toolbarButton id="acr514_invoice_print_id" click="acr514_invoice_print" text="HLS.PRINT"/>-->
<a:toolbarButton click="acr514_invoice_insert" text="新建申请"/> <!-- <a:toolbarButton id="acr514_invoice_cancel_id" click="acr514_invoice_cancel" text="取消申请"/>-->
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form marginWidth="30" padding="0" title="应收发票反冲" labelWidth="130"> <a:form marginWidth="200" padding="0" title="销项发票申请">
<a:hBox labelSeparator="" labelWidth="120"> <a:hBox labelSeparator=" ">
<a:textField name="document_number_f" bindTarget="acr514_invoice_query_ds" prompt="HLS.DOCUMENT_NUMBER_FROM" width="135"/> <a:textField name="invoice_apply_num" bindTarget="acr514_invoice_apply_query_ds" prompt="申请编号"
<!--<div><![CDATA[${l:HLS.DOCUMENT_NUMBER_TO}]]></div>--> width="135"/>
<a:textField name="document_number_t" bindTarget="acr514_invoice_query_ds" prompt="单据号到" width="135"/> <a:datePicker name="invoice_apply_date" bindTarget="acr514_invoice_apply_query_ds" prompt="申请时间"
<!-- <a:lov name="project_number_f" bindTarget="acr514_invoice_query_ds" prompt="HLS.PROJECT_NUMBER_FROM" width="135"/>--> width="135"/>
<!--<div><![CDATA[${l:HLS.DOCUMENT_NUMBER_TO}]]></div>--> <a:lov name="invoice_apply_user_n" bindTarget="acr514_invoice_apply_query_ds" prompt="申请人"
<!-- <a:lov name="project_number_t" bindTarget="acr514_invoice_query_ds" prompt="申请编号到" width="135"/>--> width="135"/>
<!-- <a:comboBox name="business_type_desc" bindTarget="acr514_invoice_query_ds" prompt="HLS.BUSINESS_TYPE_DESC" width="135"/>--> <a:comboBox name="wfl_apply_status_n" bindTarget="acr514_invoice_apply_query_ds" prompt="申请状态"
<a:comboBox name="currency_name" bindTarget="acr514_invoice_query_ds" prompt="HLS.CURRENCY" width="135"/>--> width="135"/>
<a:textField name="invoice_number_f" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_NUMBER_FROM" width="135"/>
<a:textField name="invoice_number_t" bindTarget="acr514_invoice_query_ds" prompt="发票编号到" width="135"/>
</a:hBox>
<a:hBox labelSeparator="" labelWidth="120">
<!--<div><![CDATA[${l:ACR.INVOICE_NUMBER_TO}]]></div>-->
<a:lov name="contract_number_f" bindTarget="acr514_invoice_query_ds" prompt="合同编号" width="135"/>
<!--<div><![CDATA[${l:HLS.CONTRACT_NUMBER_TO}]]></div>-->
<!--
<a:lov name="contract_number_t" bindTarget="acr514_invoice_query_ds" prompt="合同编号到" width="135"/>
-->
<a:comboBox name="invoice_kind_desc" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_KIND" width="135"/>
<a:lov name="created_by_name" bindTarget="acr514_invoice_query_ds" prompt="创建人" width="135"/>
<a:datePicker name="invoice_date_f" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_DATE_FROM" width="135"/>
<a:datePicker name="invoice_date_t" bindTarget="acr514_invoice_query_ds" prompt="发票日期到" width="135"/>
</a:hBox>
<a:hBox labelSeparator="" labelWidth="120">
<!--<div><![CDATA[${l:ACR.INVOICE_DATE_TO}]]></div>-->
<a:lov name="invoice_bp_code_f" bindTarget="acr514_invoice_query_ds" prompt="客户编号" width="135"/>
<!--<div><![CDATA[${l:HLS.CUSTOMER_NUMBER_TO}]]></div>-->
<!-- <a:lov name="invoice_bp_code_t" bindTarget="acr514_invoice_query_ds" prompt="客户编号到" width="135"/>-->
<a:textField name="invoice_title" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_TITLE" width="135"/>
<a:lov name="confirmed_by_name" bindTarget="acr514_invoice_query_ds" prompt="确认人" width="135"/>
<a:datePicker name="accounting_date_f" bindTarget="acr514_invoice_query_ds" prompt="HLS.ACCOUNT_DATE_FROM" width="135"/>
<a:datePicker name="accounting_date_t" bindTarget="acr514_invoice_query_ds" prompt="记账日期到" width="135"/>
</a:hBox>
<a:hBox labelSeparator="" labelWidth="120">
<!--<div><![CDATA[${l:HLS.ACCOUNT_DATE_TO}]]></div>-->
<a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr514_invoice_query_ds" prompt="ACR.TOTAL_AMOUNT_FROM" width="135"/>
<!--<div><![CDATA[${l:ACR.TOTAL_AMOUNT_TO}]]></div>-->
<a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr514_invoice_query_ds" prompt="发票金额到" width="135"/>
<a:comboBox name="invoice_status_desc" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_STATUS" width="135"/>
<a:comboBox name="vat_interface_status_desc" bindTarget="acr514_invoice_query_ds" prompt="金税状态" width="135"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr514_invoice_grid_id" bindTarget="acr514_invoice_result_ds" marginHeight="260" marginWidth="30" navBar="true"> <a:grid id="acr514_invoice_update_grid_ds" bindTarget="acr514_invoice_result_ds" marginHeight="120"
marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="HLS.DOCUMENT_NUMBER" renderer="acr514_document_number_render" width="120"/> <a:column name="invoice_apply_num" lock="true" prompt="申请编号" renderer="acr514_apply_num_render"
<a:column name="contract_name" autoAdjust="false" prompt="HLS.CONTRACT_NAME" showTitle="true" width="150"/> align="center" width="150"/>
<a:column name="invoice_bp_name" autoAdjust="false" prompt="HLS.CUSTOMER_NAME" showTitle="true" width="150"/> <a:column name="invoice_apply_date" prompt="申请日期" align="center" width="100"/>
<a:column name="business_type_desc" prompt="HLS.BUSINESS_TYPE_DESC" width="80"/> <a:column name="invoice_apply_user_n" prompt="申请人" align="center" width="100"/>
<a:column name="invoice_kind_desc" prompt="ACR.INVOICE_KIND" width="100"/> <a:column name="total_amount" prompt="开票总金额" align="right" renderer="acr514_formatMoney"
<!-- <a:column name="invoice_number" prompt="ACR.INVOICE_NUMBER" width="120"/>--> width="100"/>
<a:column name="invoice_date" prompt="ACR.INVOICE_DATE" width="100"/> <a:column name="net_amount" prompt="不含税总金额" align="right" renderer="acr514_formatMoney"
<!--<a:column name="reverse_date" editor="invoice_grid_dp" prompt="HLS.REVERSE_DATE" renderer="Leaf.formatDate" width="100"/>--> width="100"/>
<!-- <a:column name="vat_red_notice_num" editorFunction="vat_red_notice_num_editorFunction" prompt="ACR.VAT_RED_NOTICE_NUM" width="120"/>--> <a:column name="tax_amount" prompt="税额总金额" align="right" renderer="acr514_formatMoney" width="150"/>
<!-- <a:column name="contract_number" prompt="HLS.CONTRACT_NUMBER" width="120"/> <a:column name="vat_interface_status_n" prompt="金税状态" align="center" width="150"/>
<a:column name="bp_code" prompt="HLS.CUSTOMER_NUMBER" width="100"/> --> <a:column name="wfl_apply_status_n" prompt="申请状态" align="center" width="150"/>
<a:column name="invoice_title" autoAdjust="false" prompt="ACR.INVOICE_TITLE" showTitle="true" width="150"/>
<a:column name="total_amount" align="right" prompt="ACR.TOTAL_AMOUNT" renderer="Leaf.formatMoney" width="90"/>
<!-- <a:column name="currency" prompt="HLS.CURRENCY" width="80"/> -->
<a:column name="created_by_name" autoAdjust="false" prompt="创建人" showTitle="true" width="150"/>
<a:column name="confirmed_by_name" align="center" autoAdjust="false" prompt="确认人" showTitle="true" width="150"/>
<a:column name="invoice_status_desc" prompt="ACR.INVOICE_STATUS" width="100"/>
<a:column name="vat_interface_status_desc" prompt="ACR.VAT_INTERFACE_STATUS_NAME" width="100"/>
<a:column name="accounting_date" prompt="HLS.ACCOUNT_DATE" width="100"/>
<!--<a:column name="create_je_flag" align="center" prompt="ACR.CREATE_JE_FLAG" width="60"/>-->
<!-- <a:column name="project_number" prompt="HLS.PROJECT_NUMBER" width="120"/>
<a:column name="project_name" autoAdjust="false" prompt="HLS.PROJECT_NAME" showTitle="true" width="150"/> -->
</a:columns> </a:columns>
<!--<a:editors>
<a:datePicker id="invoice_grid_dp"/>
<a:textField id="invoice_grid_tf"/>
</a:editors>-->
</a:grid> </a:grid>
</a:screenBody> </a:screenBody>
</a:view> </a:view>
......
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: LR
$Date: 2013-7-18 上午09:34:43
$Revision: 1.0
$Purpose:
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true">
<a:init-procedure>
<a:model-query fetchAll="true" model="gld.gld_currency_vl" rootPath="acr514_currency_list"/>
<a:model-query fetchAll="true" model="acr.ACR512.acr_invoice_business_type_list" rootPath="acr514_business_type_list"/>
</a:init-procedure>
<a:view>
<a:link id="acr514_invoice_readonly_page" url="${/request/@context_path}/modules/cont/CON500/con_contract_update.lview"/>
<a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/>
<a:link id="acr514_update_for_submit_id" url="${/request/@context_path}/modules/acr/ACR512/acr_invoice_update_for_submit.lsc"/>
<a:link id="acr_invoice_reverse_apply_detail_link" url="${/request/@context_path}/modules/acr/ACR620/acr_invoice_reverse_apply_detail.lview"/>
<script><![CDATA[
function lock_current_window() {
Leaf.Masker.mask(Ext.getBody(), '${l:HLS.EXECUTING}');
}
function unlock_current_window() {
Leaf.Masker.unmask(Ext.getBody());
}
function acr514_invoice_query() {
$('acr514_invoice_result_ds').query();
}
function acr514_invoice_reset() {
$('acr514_invoice_query_ds').reset();
}
function acr514_formatMoney(value, record, name) {
return Leaf.formatNumber(value);
}
function acr514_invoice_query_Onupdate(ds, record, name, value, oldVlaue) {
if (name == 'document_number_f') {
if (Leaf.isEmpty(record.get('document_number_t'))) {
record.set('document_number_t', value);
}
} else if (name == 'project_number_f') {
if (Leaf.isEmpty(record.get('project_number_t'))) {
record.set('project_number_t', value);
}
} else if (name == 'invoice_number_f') {
if (Leaf.isEmpty(record.get('invoice_number_t'))) {
record.set('invoice_number_t', value);
}
} else if (name == 'contract_number_f') {
if (Leaf.isEmpty(record.get('contract_number_t'))) {
record.set('contract_number_t', value);
}
} else if (name == 'invoice_bp_code_f') {
if (Leaf.isEmpty(record.get('invoice_bp_code_t'))) {
record.set('invoice_bp_code_t', value);
}
} else if (name == 'total_amount_f') {
if (Leaf.isEmpty(record.get('total_amount_t'))) {
record.set('total_amount_t', value);
}
}
if (Ext.isEmpty(record.get('project_number_f')) && Ext.isEmpty(record.get('project_number_t'))) {
record.set('query_project_number', '');
} else {
record.set('query_project_number', 'Y');
}
if (Ext.isEmpty(record.get('contract_number_f')) && Ext.isEmpty(record.get('contract_number_t'))) {
record.set('query_contract_number', '');
} else {
record.set('query_contract_number', 'Y');
}
}
function acr514_grid_query(reocrd_id, invoice_hd_id, status) {
var maintain_type = 'READONLY';
var currency_reocrd = $('acr514_invoice_result_ds').findById(reocrd_id);
var param = currency_reocrd.data;
param['function_code'] = 'ACR514';
param['document_id'] = invoice_hd_id;
param['function_usage'] = 'QUERY';
param['maintain_type'] = maintain_type;
param['url_title'] = '${l:ACR.INVOICE_DETAIL}';
hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'acr514_invoice_readonly_page', 'acr514_invoice_result_ds');
}
function acr514_document_number_render(value, record, name) {
return '<a href="javascript:acr514_grid_query(' + record.id + ',' + record.get('invoice_hd_id') + ',\'' + record.get('invoice_status') + '\');">' + value + '</a>';
}
function acr514_invoice_reverse() {
acr514_invoice_handle('REVERSE');
}
function acr514_invoice_invalid() {
acr514_invoice_handle('INVALID');
}
function is_over_month(start_str, end_str) {
var start = Leaf.formatDate(start_str);
var end = Leaf.formatDate(end_str);
var year = Number(end.substr(0, 4)) - Number(start.substr(0, 4));
var month = Number(end.substr(5, 2)) - Number(start.substr(5, 2));
var day = Number(end.substr(8, 2)) - Number(start.substr(8, 2));
if (year == 1 && month == -11 && day <= 0) {
return false;
}
if (year == 0 && month == 0) {
return false;
}
if (year == 0 && month == 1 && day <= 0) {
return false;
}
return true;
}
function acr514_invoice_handle(type) {
var ds = $('acr514_invoice_result_ds');
var records = ds.getSelected();
if (records.length == 0) {
return;
}
if (type == 'REVERSE') {
for (var i = 0;i < records.length;i++) {
if (records[i].get('invoice_kind') == '0') {
records[i].getField('vat_red_notice_num').setRequired(true);
}
}
} else if (type == 'INVALID') {
for (var i = 0;i < records.length;i++) {
if (is_over_month(records[i].get('invoice_date'), records[i].get('reverse_date'))) {
Leaf.showMessage('${l:HLS.PROMPT}', '单据号:' + records[i].get('document_number') + '日期跨月');
return;
}
}
// for (var i = 0;i < records.length;i++) {
// if (records[i].get('vat_interface_status')=='BACK') {
// Leaf.showMessage('${l:HLS.PROMPT}', '单据号:' + records[i].get('document_number') + '金税状态已回写,不可反冲');
// return;
// }
// }
for (var i = 0;i < records.length;i++) {
records[i].getField('vat_red_notice_num').setRequired(false);
}
} else {
return;
}
Leaf.showConfirm('${l:HLS.PROMPT}', '是否确认?', function() {
ds.submitSelected();
}, function() {
});
}
function acr514_invoice_result_ds_submitsuccess(ds) {
$('acr514_invoice_grid_id').clear();
}
function vat_red_notice_num_editorFunction(record, name) {
if (record.get('invoice_kind') == '0') {
if (name == 'vat_red_notice_num') {
return 'invoice_grid_tf';
}
}
return '';
}
function acr514_invoice_update(ds, record, name, value, oldVlaue)
{
var time,year,month,day,string;
var d,d_year_month;
if(name=='reverse_date')
{
time = new Date();
year = time.getFullYear();
month = time.getMonth()+1;
if(month<10)
string = String(year)+'0'+String(month);
else
string = String(year)+String(month);
d= new Date(value);
d_year=d.getFullYear();
d_month=d.getMonth()+1;
if(d_month<10)
d_year_month = String(d_year)+'0'+String(d_month);
else
d_year_month = String(d_year)+String(d_month);
//如果小于系统时间
if( d_year_month<string)
{
record.getField('vat_red_notice_num').setRequired(true);
}
else
{
record.getField('vat_red_notice_num').setRequired(false);
}
record.set(name,value);
}
}
function acr514_invoice_insert() {
var records = $('acr514_invoice_result_ds').getSelected();
if (records.length < 1) {
Leaf.showMessage('${l:HLS.PROMPT}', '请选择需要审批的发票!');
return;
}
var datas = {};
var saveData = [];
var invoice_hd_ids = '';
for (var i = 0; i < records.length; i++) {
if (invoice_hd_ids == '') {
invoice_hd_ids = records[i].get('invoice_hd_id');
} else {
invoice_hd_ids = invoice_hd_ids + ',' + records[i].get('invoice_hd_id');
}
records[i].set('_status', 'update');
saveData.push(records[i].data);
}
saveData.sort(function (a, b) {
return a.invoice_hd_id - b.invoice_hd_id;
});
datas['invoice_hd_ids'] = invoice_hd_ids;
datas['apply_mode'] = 'REVERSE';
datas['details'] = saveData;
Leaf.showConfirm('提示', '<span style="color: #ff0000; ">所选发票即将创建反冲申请!如需要取消发票反冲申请,请点击取消申请!</span>', function () {
lock_current_window();
Leaf.request({
url: $('acr514_update_for_submit_id').getUrl(),
para: datas,
success: function (res) {
Leaf.SideBar.show({
msg: '申请成功',
duration: 3000
});
unlock_current_window();
var win = new Leaf.Window({
id: 'acr_invoice_reverse_apply_detail_link_winid',
params: {
invoice_apply_id: res.result.invoice_apply_id,
winId: 'acr_invoice_reverse_apply_detail_link_winid'
},
url: $('acr_invoice_reverse_apply_detail_link').getUrl(),
title: '申请明细',
fullScreen: true
});
win.on('close',function(){
$('acr514_invoice_result_ds').query();
});
},
failure: function () {
unlock_current_window();
},
error: function () {
unlock_current_window();
},
scope: this
});
});
}
]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
<a:dataSets>
<a:dataSet id="acr514_business_type_ds">
<a:datas dataSource="/model/acr514_business_type_list"/>
</a:dataSet>
<a:dataSet id="acr514_currency_ds">
<a:datas dataSource="/model/acr514_currency_list"/>
</a:dataSet>
<a:dataSet id="acr514_invoice_kind_ds" lookupCode="ACR510_INVOICE_KIND"/>
<a:dataSet id="acr514_invoice_statu_ds" lookupCode="ACR510_AR_INVOICE_STATUS"/>
<a:dataSet id="acr514_express_status_ds" lookupCode="ACR518_EXPRESS_STATUS"/>
<a:dataSet id="acr514_vat_interface_status_ds" lookupCode="ACR515_VAT_INTERFACE_STATUS"/>
<a:dataSet id="acr514_invoice_query_ds" autoCreate="true">
<a:fields>
<a:field name="currency_name" displayField="currency_name" options="acr514_currency_ds" returnField="currency" valueField="currency_code"/>
<a:field name="invoice_kind_desc" displayField="code_value_name" options="acr514_invoice_kind_ds" returnField="invoice_kind" valueField="code_value"/>
<a:field name="invoice_status_desc" displayField="code_value_name" options="acr514_invoice_statu_ds" returnField="invoice_status" valueField="code_value"/>
<a:field name="vat_interface_status_desc" displayField="code_value_name" options="acr514_vat_interface_status_ds" returnField="vat_interface_status" valueField="code_value"/>
<a:field name="business_type_desc" displayField="business_type_desc" options="acr514_business_type_ds" returnField="business_type" valueField="business_type"/>
<a:field name="created_by_name" lovGridHeight="320" lovHeight="500" lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="开票人选择">
<a:mapping>
<a:map from="user_id" to="created_by"/>
<a:map from="description" to="created_by_name"/>
</a:mapping>
</a:field>
<a:field name="confirmed_by_name" lovGridHeight="320" lovHeight="500" lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="复核人选择">
<a:mapping>
<a:map from="user_id" to="confirmed_by"/>
<a:map from="description" to="confirmed_by_name"/>
</a:mapping>
</a:field>
<a:field name="invoice_bp_code_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500" title="客户选择">
<a:mapping>
<a:map from="bp_code" to="invoice_bp_code_f"/>
</a:mapping>
</a:field>
<a:field name="invoice_bp_code_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500" title="客户选择">
<a:mapping>
<a:map from="bp_code" to="invoice_bp_code_t"/>
</a:mapping>
</a:field>
<a:field name="project_number_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500" title="项目选择">
<a:mapping>
<a:map from="project_number" to="project_number_f"/>
</a:mapping>
</a:field>
<a:field name="project_number_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500" title="项目选择">
<a:mapping>
<a:map from="project_number" to="project_number_t"/>
</a:mapping>
</a:field>
<a:field name="contract_number_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500" title="合同选择">
<a:mapping>
<a:map from="contract_number" to="contract_number_f"/>
</a:mapping>
</a:field>
<a:field name="contract_number_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500" title="合同选择">
<a:mapping>
<a:map from="contract_number" to="contract_number_t"/>
</a:mapping>
</a:field>
<a:field name="received_flag" checkedValue="Y" defaultValue="N" uncheckedValue="N"/>
<a:field name="express_status_name" displayField="code_value_name" options="acr514_express_status_ds" returnField="express_status" valueField="code_value"/>
</a:fields>
<a:events>
<a:event name="update" handler="acr514_invoice_query_Onupdate"/>
</a:events>
</a:dataSet>
<a:dataSet id="acr514_invoice_result_ds" autoQuery="true" autoPageSize="true" model="acr.ACR514.acr_invoice_reverse" queryDataSet="acr514_invoice_query_ds" selectable="true">
<!--<a:fields>
<a:field name="reverse_date" required="true"/>
</a:fields>
<a:events>
<a:event name="submitsuccess" handler="acr514_invoice_result_ds_submitsuccess"/>
<a:event name="update" handler="acr514_invoice_update"/>
</a:events>-->
</a:dataSet>
</a:dataSets>
<a:screenBody>
<a:screenTopToolbar>
<a:screenTitle/>
<a:toolbarButton click="acr514_invoice_query" text="HLS.QUERY"/>
<a:toolbarButton click="acr514_invoice_reset" text="HLS.RESET"/>
<!-- <a:toolbarButton click="acr514_invoice_reverse" text="HLS.REVERSE"/>-->
<!--<a:toolbarButton click="acr514_invoice_invalid" text="作废"/>-->
<a:toolbarButton click="acr514_invoice_insert" text="新建申请"/>
</a:screenTopToolbar>
<a:form marginWidth="30" padding="0" title="应收发票反冲" labelWidth="130">
<a:hBox labelSeparator="" labelWidth="120">
<a:textField name="document_number_f" bindTarget="acr514_invoice_query_ds" prompt="HLS.DOCUMENT_NUMBER_FROM" width="135"/>
<!--<div><![CDATA[${l:HLS.DOCUMENT_NUMBER_TO}]]></div>-->
<a:textField name="document_number_t" bindTarget="acr514_invoice_query_ds" prompt="单据号到" width="135"/>
<!-- <a:lov name="project_number_f" bindTarget="acr514_invoice_query_ds" prompt="HLS.PROJECT_NUMBER_FROM" width="135"/>-->
<!--<div><![CDATA[${l:HLS.DOCUMENT_NUMBER_TO}]]></div>-->
<!-- <a:lov name="project_number_t" bindTarget="acr514_invoice_query_ds" prompt="申请编号到" width="135"/>-->
<!-- <a:comboBox name="business_type_desc" bindTarget="acr514_invoice_query_ds" prompt="HLS.BUSINESS_TYPE_DESC" width="135"/>-->
<a:comboBox name="currency_name" bindTarget="acr514_invoice_query_ds" prompt="HLS.CURRENCY" width="135"/>-->
<a:textField name="invoice_number_f" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_NUMBER_FROM" width="135"/>
<a:textField name="invoice_number_t" bindTarget="acr514_invoice_query_ds" prompt="发票编号到" width="135"/>
</a:hBox>
<a:hBox labelSeparator="" labelWidth="120">
<!--<div><![CDATA[${l:ACR.INVOICE_NUMBER_TO}]]></div>-->
<a:lov name="contract_number_f" bindTarget="acr514_invoice_query_ds" prompt="合同编号" width="135"/>
<!--<div><![CDATA[${l:HLS.CONTRACT_NUMBER_TO}]]></div>-->
<!--
<a:lov name="contract_number_t" bindTarget="acr514_invoice_query_ds" prompt="合同编号到" width="135"/>
-->
<a:comboBox name="invoice_kind_desc" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_KIND" width="135"/>
<a:lov name="created_by_name" bindTarget="acr514_invoice_query_ds" prompt="创建人" width="135"/>
<a:datePicker name="invoice_date_f" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_DATE_FROM" width="135"/>
<a:datePicker name="invoice_date_t" bindTarget="acr514_invoice_query_ds" prompt="发票日期到" width="135"/>
</a:hBox>
<a:hBox labelSeparator="" labelWidth="120">
<!--<div><![CDATA[${l:ACR.INVOICE_DATE_TO}]]></div>-->
<a:lov name="invoice_bp_code_f" bindTarget="acr514_invoice_query_ds" prompt="客户编号" width="135"/>
<!--<div><![CDATA[${l:HLS.CUSTOMER_NUMBER_TO}]]></div>-->
<!-- <a:lov name="invoice_bp_code_t" bindTarget="acr514_invoice_query_ds" prompt="客户编号到" width="135"/>-->
<a:textField name="invoice_title" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_TITLE" width="135"/>
<a:lov name="confirmed_by_name" bindTarget="acr514_invoice_query_ds" prompt="确认人" width="135"/>
<a:datePicker name="accounting_date_f" bindTarget="acr514_invoice_query_ds" prompt="HLS.ACCOUNT_DATE_FROM" width="135"/>
<a:datePicker name="accounting_date_t" bindTarget="acr514_invoice_query_ds" prompt="记账日期到" width="135"/>
</a:hBox>
<a:hBox labelSeparator="" labelWidth="120">
<!--<div><![CDATA[${l:HLS.ACCOUNT_DATE_TO}]]></div>-->
<a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr514_invoice_query_ds" prompt="ACR.TOTAL_AMOUNT_FROM" width="135"/>
<!--<div><![CDATA[${l:ACR.TOTAL_AMOUNT_TO}]]></div>-->
<a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr514_invoice_query_ds" prompt="发票金额到" width="135"/>
<a:comboBox name="invoice_status_desc" bindTarget="acr514_invoice_query_ds" prompt="ACR.INVOICE_STATUS" width="135"/>
<a:comboBox name="vat_interface_status_desc" bindTarget="acr514_invoice_query_ds" prompt="金税状态" width="135"/>
</a:hBox>
</a:form>
<a:grid id="acr514_invoice_grid_id" bindTarget="acr514_invoice_result_ds" marginHeight="260" marginWidth="30" navBar="true">
<a:columns>
<a:column name="document_number" lock="true" prompt="HLS.DOCUMENT_NUMBER" renderer="acr514_document_number_render" width="120"/>
<a:column name="contract_name" autoAdjust="false" prompt="HLS.CONTRACT_NAME" showTitle="true" width="150"/>
<a:column name="invoice_bp_name" autoAdjust="false" prompt="HLS.CUSTOMER_NAME" showTitle="true" width="150"/>
<a:column name="business_type_desc" prompt="HLS.BUSINESS_TYPE_DESC" width="80"/>
<a:column name="invoice_kind_desc" prompt="ACR.INVOICE_KIND" width="100"/>
<!-- <a:column name="invoice_number" prompt="ACR.INVOICE_NUMBER" width="120"/>-->
<a:column name="invoice_date" prompt="ACR.INVOICE_DATE" width="100"/>
<!--<a:column name="reverse_date" editor="invoice_grid_dp" prompt="HLS.REVERSE_DATE" renderer="Leaf.formatDate" width="100"/>-->
<!-- <a:column name="vat_red_notice_num" editorFunction="vat_red_notice_num_editorFunction" prompt="ACR.VAT_RED_NOTICE_NUM" width="120"/>-->
<!-- <a:column name="contract_number" prompt="HLS.CONTRACT_NUMBER" width="120"/>
<a:column name="bp_code" prompt="HLS.CUSTOMER_NUMBER" width="100"/> -->
<a:column name="invoice_title" autoAdjust="false" prompt="ACR.INVOICE_TITLE" showTitle="true" width="150"/>
<a:column name="total_amount" align="right" prompt="ACR.TOTAL_AMOUNT" renderer="Leaf.formatMoney" width="90"/>
<!-- <a:column name="currency" prompt="HLS.CURRENCY" width="80"/> -->
<a:column name="created_by_name" autoAdjust="false" prompt="创建人" showTitle="true" width="150"/>
<a:column name="confirmed_by_name" align="center" autoAdjust="false" prompt="确认人" showTitle="true" width="150"/>
<a:column name="invoice_status_desc" prompt="ACR.INVOICE_STATUS" width="100"/>
<a:column name="vat_interface_status_desc" prompt="ACR.VAT_INTERFACE_STATUS_NAME" width="100"/>
<a:column name="accounting_date" prompt="HLS.ACCOUNT_DATE" width="100"/>
<!--<a:column name="create_je_flag" align="center" prompt="ACR.CREATE_JE_FLAG" width="60"/>-->
<!-- <a:column name="project_number" prompt="HLS.PROJECT_NUMBER" width="120"/>
<a:column name="project_name" autoAdjust="false" prompt="HLS.PROJECT_NAME" showTitle="true" width="150"/> -->
</a:columns>
<!--<a:editors>
<a:datePicker id="invoice_grid_dp"/>
<a:textField id="invoice_grid_tf"/>
</a:editors>-->
</a:grid>
</a:screenBody>
</a:view>
</a:screen>
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: LR
$Date: 2013-7-15 下午04:39:15
$Revision: 1.0
$Purpose:
-->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true">
<a:init-procedure>
<a:model-query defaultWhereClause="t1.user_id=${/session/@user_id}" model="acr.ACR514.sys_session_info"
rootPath="user_name_path"/>
</a:init-procedure>
<a:view>
<a:link id="acr_invoice_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
modelaction="update"/>
<a:link id="acr620_invoice_reverse_detail_link"
url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_detail_readonly.lview"/>
<a:link id="acr620_detail_submit_link" model="acr.ACR620.acr_invoice_reverse_apply_detail"
modelaction="execute"/>
<a:link id="acr620_invoice_reverse_save_link" model="acr.ACR610.acr_invoice_apply_query" modelaction="update"/>
<a:link id="acr514_update_for_save_id"
url="${/request/@context_path}/modules/acr/ACR512/acr_invoice_update_for_submit.lsc"/>
<script><![CDATA[
function lock_current_detail_window() {
Leaf.Masker.mask($('${/parameter/@winId}').wrap, '${l:HLS.EXECUTING}');
}
function unlock_current_detail_window() {
Leaf.Masker.unmask($('${/parameter/@winId}').wrap);
}
function acr514_invoice_reverse_detail_exit() {
$('${/parameter/@winId}').close();
}
function update_reverse_method(invoice_apply_id) {
var ds = $('acr514_invoice_reverse_apply_basic_ds');
if (ds.validate() && invoice_apply_id) {
var record = ds.getAt(0);
Leaf.request({
url: $('acr620_invoice_reverse_save_link').getUrl(),
para: {
invoice_apply_id: invoice_apply_id,
reverse_method: record.get('reverse_method')
},
success: function () {
Leaf.SideBar.show({
msg: '保存成功',
duration: 3000
});
unlock_current_detail_window();
// $('acr620_invoice_reverse_apply_basic_ds').query();
},
failure: function () {
unlock_current_detail_window();
},
error: function () {
unlock_current_detail_window();
},
scope: this
});
}
}
function acr514_invoice_reverse_detail_submit() {
var ds = $('acr514_invoice_reverse_apply_basic_ds');
var record = ds.getAt(0);
if (!record.get('invoice_apply_num')) {
Leaf.showMessage('提示', '请先保存!');
return;
}
if (ds.validate()) {
Leaf.showConfirm('提示', '您确认提交吗', function () {
lock_current_detail_window();
Leaf.request({
url: $('acr620_detail_submit_link').getUrl(),
para: {
invoice_apply_id: record.get('invoice_apply_id')
},
success: function () {
Leaf.SideBar.show({
msg: '提交成功',
duration: 3000
});
unlock_current_detail_window();
acr514_invoice_reverse_detail_exit();
},
failure: function () {
unlock_current_detail_window();
},
error: function () {
unlock_current_detail_window();
},
scope: this
});
});
}
}
function acr514_detail_grid_readonly(reocrd_id, invoice_hd_wfl_id) {
var currency_reocrd = $('acr514_invoice_reverse_detail_result_ds').findById(reocrd_id);
var param = currency_reocrd.data;
param['winid'] = 'confirm_invoice_detail_win';
param['document_id'] = invoice_hd_wfl_id;
param['url_title'] = '${l:ACR.INVOICE_DETAIL}';
param['function_code'] = 'ACR610R';
param['function_usage'] = 'QUERY';
param['maintain_type'] = 'READONLY';
hls_doc_get_layout_code('acr_invoice_get_layout_code_link_id', param, 'acr620_invoice_reverse_detail_link');
}
function acr514_detail_renderer(value, record, name) {
if (name == 'document_number') {
return '<a href="javascript:acr514_detail_grid_readonly(' + record.id + ',' + record.get('invoice_hd_wfl_id') + ');">' + value + '</a>';
}
}
function acr514_detail_formatMoney(value, record, name) {
return Leaf.formatNumber(value);
}
function acr514_invoice_reverse_load(ds, record) {
if ('${/parameter/@vat_interface_status}' != 'BACK') {
record.set('reverse_method', 'REVERSE');
record.set('reverse_method_n', '反冲');
record.getField('reverse_method_n').setReadOnly(true);
}
}
function acr514_invoice_reverse_detail_save() {
var reversed_count = 0;
var select_reversed_count = 0;
var head_ds = $('acr514_invoice_reverse_apply_basic_ds');
var head_record = head_ds.getAt(0);
var records = $('acr514_invoice_reverse_detail_result_ds').getSelected();
if (records.length < 1) {
Leaf.showMessage('${l:HLS.PROMPT}', '请勾选未反冲的发票!');
return;
}
var datas = {};
var saveData = [];
var invoice_hd_ids = '';
for (var i = 0; i < records.length; i++) {
if (records[i].get('reversed_flag') != 'N') {
Leaf.showMessage('${l:HLS.PROMPT}', '只能勾选未反冲的发票');
return;
}
if (records[i].get('claim_status') == 'CLAIMING') {
Leaf.showMessage('${l:HLS.PROMPT}', '认领中的发票无法申请反冲');
return;
}
select_reversed_count += 1;
if (invoice_hd_ids == '') {
invoice_hd_ids = records[i].get('invoice_hd_id');
} else {
invoice_hd_ids = invoice_hd_ids + ',' + records[i].get('invoice_hd_id');
}
records[i].set('_status', 'update');
saveData.push(records[i].data);
}
saveData.sort(function (a, b) {
return a.invoice_hd_id - b.invoice_hd_id;
});
datas['invoice_hd_ids'] = invoice_hd_ids;
datas['apply_mode'] = 'REVERSE';
datas['details'] = saveData;
if (head_ds.validate()) {
if (head_record.get('reverse_method') == 'REVERSE') {
var all_record = $('acr514_invoice_reverse_detail_result_ds').getAll();
all_record.forEach(function (v, i) {
if (v.get('reversed_flag') == 'N') {
reversed_count += 1;
}
});
if (select_reversed_count != reversed_count) {
Leaf.showMessage('${l:HLS.PROMPT}', '反冲方式为反冲时,请全选未反冲的发票!');
return;
}
}
if (head_record.get('invoice_apply_num')) {
var invoice_apply_id = head_record.get('invoice_apply_id');
update_reverse_method(invoice_apply_id);
} else {
lock_current_detail_window();
Leaf.request({
url: $('acr514_update_for_save_id').getUrl(),
para: datas,
success: function (res) {
Leaf.SideBar.show({
msg: '保存成功',
duration: 3000
});
var invoice_apply_num = res.result.invoice_apply_num
var invoice_apply_id = res.result.invoice_apply_id;
head_record.set('invoice_apply_num', invoice_apply_num);
head_record.set('invoice_apply_id', invoice_apply_id);
update_reverse_method(invoice_apply_id);
$('acr514_invoice_reverse_detail_result_ds').setQueryParameter('invoice_apply_id', invoice_apply_id);
$('acr514_invoice_reverse_detail_result_ds').query();
unlock_current_detail_window();
},
failure: function () {
unlock_current_detail_window();
},
error: function () {
unlock_current_detail_window();
},
scope: this
});
}
}
}
function acr514_invoice_reverse_detail_result_load(ds) {
if ('${/parameter/@vat_interface_status}' != 'BACK') {
var records = ds.getAll();
if (records.length && '${/parameter/@readOnly_flag}' != 'Y') {
records.forEach(function (v, i) {
if (v.get('reversed_flag') == 'N' && v.get('claim_status') != 'CLAIMING') {
setTimeout(function () {
ds.select(v);
}, 1);
}
});
}
}
}
Leaf.onReady(init);
function init() {
var head_ds = $('acr514_invoice_reverse_apply_basic_ds');
var record = head_ds.getAt(0);
acr514_invoice_reverse_load(head_ds, record);
var line_ds = $('acr514_invoice_reverse_detail_result_ds');
if ('${/parameter/@readOnly_flag}' == 'Y') {
line_ds.selectable = false;
record.getField('reverse_method_n').setRequired(false);
record.getField('reverse_method_n').setReadOnly(true);
if (document.getElementById("acr514_invoice_reverse_detail_save_id")) {
document.getElementById("acr514_invoice_reverse_detail_save_id").style.display = "none";
}
if (document.getElementById("acr514_invoice_reverse_detail_submit_id")) {
document.getElementById("acr514_invoice_reverse_detail_submit_id").style.display = "none";
}
}
}
function on_accordion_beforeSelect(ds, record) {
if (record.get('reversed_flag') == 'N' && record.get('claim_status') != 'CLAIMING') {
return true;
} else {
return false;
}
}
]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
<a:dataSets>
<!--<a:dataSet id="acr620_reverse_method_ds" lookupCode="REVERSE_METHOD"/>-->
<a:dataSet id="acr514_reverse_method_ds">
<a:datas>
<a:record code_value="REDPUNCH" code_value_name="红冲"/>
<a:record code_value="INVALID" code_value_name="作废"/>
</a:datas>
</a:dataSet>
<a:dataSet id="acr514_invoice_reverse_apply_basic_ds" autoCreate="true">
<a:fields>
<a:field name="invoice_apply_num"/>
<a:field name="reverse_method"/>
<a:field name="invoice_apply_user_n" defaultValue="${/model/user_name_path/record/@user_desc}"/>
<a:field name="invoice_apply_date" defaultValue="${/model/user_name_path/record/@today}"/>
<a:field name="reverse_method_n" displayField="code_value_name" options="acr514_reverse_method_ds"
returnField="reverse_method" valueField="code_value" required="true"
requiredMessage="请输入必输字段:反冲方式"/>
</a:fields>
</a:dataSet>
<a:dataSet id="acr514_invoice_reverse_detail_result_ds" autoPageSize="true" autoQuery="true" fetchAll="true"
model="acr.ACR620.acr_invoice_reverse_apply_detail"
queryUrl="${/request/@context_path}/autocrud/acr.ACR620.acr_invoice_reverse_apply_detail/query?invoice_apply_id=${/parameter/@invoice_apply_id}"
selectable="true" selectionModel="multiple">
<a:events>
<a:event name="load" handler="acr514_invoice_reverse_detail_result_load"/>
<a:event name="beforeselect" handler="on_accordion_beforeSelect"/>
</a:events>
</a:dataSet>
</a:dataSets>
<a:screenBody>
<a:screenTopToolbar>
<a:screenTitle/>
<a:toolbarButton click="acr514_invoice_reverse_detail_exit" text="HLS.EXIT"/>
<a:toolbarButton click="acr514_invoice_reverse_detail_save" text="HLS.SAVE"
id="acr514_invoice_reverse_detail_save_id"/>
<a:toolbarButton click="acr514_invoice_reverse_detail_submit" text="HLS.SUBMIT"
id="acr514_invoice_reverse_detail_submit_id"/>
</a:screenTopToolbar>
<a:form marginWidth="200" padding="0" title="基本信息">
<a:hBox labelSeparator=" ">
<a:textField name="invoice_apply_num" bindTarget="acr514_invoice_reverse_apply_basic_ds"
prompt="申请编号" width="135" readOnly="true"/>
<a:textField name="invoice_apply_user_n" bindTarget="acr514_invoice_reverse_apply_basic_ds"
prompt="申请人" width="135" readOnly="true"/>
<a:textField name="invoice_apply_date" bindTarget="acr514_invoice_reverse_apply_basic_ds"
prompt="申请时间" width="135" readOnly="true"/>
<a:comboBox name="reverse_method_n" bindTarget="acr514_invoice_reverse_apply_basic_ds" prompt="反冲方式"
width="135"/>
</a:hBox>
</a:form>
<a:grid id="acr514_invoice_reverse_detail_grid_ds" bindTarget="acr514_invoice_reverse_detail_result_ds"
marginHeight="130"
marginWidth="30" navBar="true">
<a:columns>
<a:column name="document_number" lock="true" prompt="单据编号" align="center"
renderer="acr514_detail_renderer" width="120"/>
<a:column name="invoice_number" prompt="发票号码" align="center" width="100"/>
<a:column name="contract_number" prompt="合同编号" align="center" width="100"/>
<a:column name="contract_name" prompt="合同名称" align="center" width="100"/>
<a:column name="bp_name" prompt="客户名称" align="center" width="100"/>
<a:column name="invoice_date" prompt="发票日期" renderer="Leaf.formatDate" align="center" width="95"/>
<a:column name="invoice_title" prompt="发票抬头" align="center" width="100"/>
<a:column name="total_amount" prompt="开票金额" renderer="acr514_detail_formatMoney" align="right"
width="90"/>
<a:column name="created_by_n" prompt="创建人" align="center" width="100"/>
<a:column name="invoice_status_n" prompt="发票状态" align="center" width="100"/>
<a:column name="vat_interface_status_n" prompt="金税状态" align="center" width="95"/>
<a:column name="accounting_date" prompt="记账日期" renderer="Leaf.formatDate" align="center"
width="95"/>
<a:column name="claim_status_n" prompt="认领状态" width="85" align="center"/>
<a:column name="reversed_flag_n" prompt="反冲标志" align="center" width="80"/>
</a:columns>
</a:grid>
</a:screenBody>
</a:view>
</a:screen>
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<a:service xmlns:a="http://www.leaf-framework.org/application" xmlns:p="uncertain.proc" trace="true"> <a:service xmlns:a="http://www.leaf-framework.org/application" xmlns:p="uncertain.proc"
xmlns:t="http://www.leaf-framework.org/application" trace="true">
<a:init-procedure> <a:init-procedure>
<a:model-delete model="acr.ACR515.acr_interface_tmp" trace="true"/> <a:model-delete model="acr.ACR515.acr_interface_tmp" trace="true"/>
<a:model-execute model="acr.ACR515.acr_interface_tmp" trace="true"/>
<batch-apply sourcePath="/parameter/details"> <batch-apply sourcePath="/parameter/details">
<a:model-insert model="acr.ACR515.acr_interface_tmp" trace="true"/> <a:model-insert model="acr.ACR515.acr_interface_tmp" trace="true"/>
</batch-apply> </batch-apply>
......
...@@ -5,22 +5,29 @@ ...@@ -5,22 +5,29 @@
$Revision: 1.0 $Revision: 1.0
$Purpose: $Purpose:
--> -->
<a:screen xmlns:s="leaf.plugin.script" xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true" trace="true"> <a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true"
trace="true">
<a:init-procedure> <a:init-procedure>
<a:model-query fetchAll="true" model="gld.gld_currency_vl" rootPath="acr515_currency_list"/> <a:model-query fetchAll="true" model="gld.gld_currency_vl" rootPath="acr515_currency_list"/>
<a:model-query fetchAll="true" model="acr.ACR512.acr_invoice_business_type_list" rootPath="acr515_business_type_list"/> <a:model-query fetchAll="true" model="acr.ACR512.acr_invoice_business_type_list"
rootPath="acr515_business_type_list"/>
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="acr513_invoice_readonly_page" <a:link id="acr513_invoice_readonly_page"
url="${/request/@context_path}/modules/cont/CON500/con_contract_update.lview"/> url="${/request/@context_path}/modules/cont/CON500/con_contract_update.lview"/>
<a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/> <a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
modelaction="update"/>
<a:link id="bmLink_vat_pause_or_submit" model="acr.ACR515.acr_invoice_vat" modelaction="batch_update"/> <a:link id="bmLink_vat_pause_or_submit" model="acr.ACR515.acr_invoice_vat" modelaction="batch_update"/>
<a:link id="bmLink_vat_receive" model="acr.ACR515.acr_invoice_vat" modelaction="execute"/> <a:link id="bmLink_vat_receive" model="acr.ACR515.acr_invoice_vat" modelaction="execute"/>
<a:link id="acr515_update_post_link" url="${/request/@context_path}/modules/acr/ACR515/acr_invoice_insert_tmp.lsc"/> <a:link id="acr515_update_post_link"
<a:link id="acr515_interface_excel_link" url="${/request/@context_path}/modules/acr/ACR515/acr_invoice_interface_excel_sheets.lsc"/> url="${/request/@context_path}/modules/acr/ACR515/acr_invoice_insert_tmp.lsc"/>
<a:link id="acr515_interface_network_link" url="${/request/@context_path}/modules/acr/ACR515/acr_invoice_interface_network_sheets.lsc"/> <a:link id="acr515_interface_excel_link"
<a:link id="acr515_interface_import_link" url="${/request/@context_path}/modules/acr/ACR515/hls_acr_vat_import_data.lview"/> url="${/request/@context_path}/modules/acr/ACR515/acr_invoice_interface_excel_sheets.lsc"/>
<a:link id="acr515_interface_network_link"
url="${/request/@context_path}/modules/acr/ACR515/acr_invoice_interface_network_sheets.lsc"/>
<a:link id="acr515_interface_import_link"
url="${/request/@context_path}/modules/acr/ACR515/hls_acr_vat_import_data.lview"/>
<a:screen-include screen="modules/hls/hls_common_javascript.lview"/> <a:screen-include screen="modules/hls/hls_common_javascript.lview"/>
<script><![CDATA[ <script><![CDATA[
function acr515_invoice_query() { function acr515_invoice_query() {
...@@ -89,7 +96,7 @@ ...@@ -89,7 +96,7 @@
Leaf.request({ Leaf.request({
url: $('bmLink_vat_pause_or_submit').getUrl(), url: $('bmLink_vat_pause_or_submit').getUrl(),
para: datas, para: datas,
success: function(res) { success: function (res) {
f_hls.winNoMask(); f_hls.winNoMask();
Leaf.SideBar.show({ Leaf.SideBar.show({
msg: '${l:HLS.SUBMIT_SUCCESS}', msg: '${l:HLS.SUBMIT_SUCCESS}',
...@@ -97,10 +104,10 @@ ...@@ -97,10 +104,10 @@
}); });
acr515_invoice_refresh(); acr515_invoice_refresh();
}, },
failure: function() { failure: function () {
f_hls.winNoMask(); f_hls.winNoMask();
}, },
error: function() { error: function () {
f_hls.winNoMask(); f_hls.winNoMask();
}, },
scope: this scope: this
...@@ -111,7 +118,7 @@ ...@@ -111,7 +118,7 @@
Leaf.request({ Leaf.request({
url: $('bmLink_vat_receive').getUrl(), url: $('bmLink_vat_receive').getUrl(),
para: {}, para: {},
success: function(res) { success: function (res) {
f_hls.winNoMask(); f_hls.winNoMask();
Leaf.SideBar.show({ Leaf.SideBar.show({
msg: '${l:HLS.SUBMIT_SUCCESS}', msg: '${l:HLS.SUBMIT_SUCCESS}',
...@@ -119,10 +126,10 @@ ...@@ -119,10 +126,10 @@
}); });
acr515_invoice_refresh(); acr515_invoice_refresh();
}, },
failure: function() { failure: function () {
f_hls.winNoMask(); f_hls.winNoMask();
}, },
error: function() { error: function () {
f_hls.winNoMask(); f_hls.winNoMask();
}, },
scope: this scope: this
...@@ -130,7 +137,6 @@ ...@@ -130,7 +137,6 @@
} }
function acr515_vat_create() { function acr515_vat_create() {
f_hls.winMask(); f_hls.winMask();
...@@ -141,7 +147,7 @@ ...@@ -141,7 +147,7 @@
return; return;
} }
var datas = []; var datas = [];
for (var i = 0;i < records.length;i++) { for (var i = 0; i < records.length; i++) {
var obj = {}; var obj = {};
obj['invoice_hd_id'] = records[i].get('invoice_hd_id'); obj['invoice_hd_id'] = records[i].get('invoice_hd_id');
obj['_status'] = 'insert'; obj['_status'] = 'insert';
...@@ -161,7 +167,7 @@ ...@@ -161,7 +167,7 @@
return; return;
} }
var datas = []; var datas = [];
for (var i = 0;i < records.length;i++) { for (var i = 0; i < records.length; i++) {
var obj = {}; var obj = {};
obj['invoice_hd_id'] = records[i].get('invoice_hd_id'); obj['invoice_hd_id'] = records[i].get('invoice_hd_id');
obj['type'] = type; obj['type'] = type;
...@@ -186,7 +192,7 @@ ...@@ -186,7 +192,7 @@
return; return;
} }
var datas = []; var datas = [];
for (var i = 0;i < records.length;i++) { for (var i = 0; i < records.length; i++) {
var obj = {}; var obj = {};
obj['invoice_hd_id'] = records[i].get('invoice_hd_id'); obj['invoice_hd_id'] = records[i].get('invoice_hd_id');
...@@ -215,12 +221,24 @@ ...@@ -215,12 +221,24 @@
// } else {//否则弹出电子发票 // } else {//否则弹出电子发票
// url = $('acr515_interface_network_link').getUrl(); // url = $('acr515_interface_network_link').getUrl();
// } // }
var invoice_apply_num0 = records[0].get('invoice_apply_num');
var detail_mask = Ext.getBody(); var detail_mask = Ext.getBody();
Leaf.Masker.mask(detail_mask, '${l:HLS.EXECUTING}'); Leaf.Masker.mask(detail_mask, '${l:HLS.EXECUTING}');
for (var i = 0;i < records.length;i++) { for (var i = 0; i < records.length; i++) {
//判断金税状态,已经回传的不能再进行开票 //判断金税状态,已经回传的不能再进行开票
if('BACK'==records[i].get('vat_interface_status')){ if ('BACK' == records[i].get('vat_interface_status')) {
$L.showInfoMessage("提示",'所选择的单据中存在金税已回写状态,请检查后重试!'); $L.showInfoMessage("提示", '所选择的单据中存在金税已回写状态,请检查后重试!');
Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}');
return;
}
if ('TRANSFERED' == records[i].get('vat_interface_status')) {
$L.showInfoMessage("提示", '所选择的单据中存在已传金税状态,请检查后重试!');
Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}');
return;
}
//不同批次的发票不能同时勾选
if (invoice_apply_num0 != records[i].get('invoice_apply_num')) {
$L.showInfoMessage("提示", '不同批次的发票不能同时勾选!');
Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}'); Leaf.Masker.unmask(detail_mask, '${l:HLS.EXECUTING}');
return; return;
} }
...@@ -230,78 +248,83 @@ ...@@ -230,78 +248,83 @@
}); });
} }
param['details'] = saveData; param['details'] = saveData;
param.invoice_apply_id = records[0].get('invoice_apply_id');
param.select_count = records.length;
Leaf.request({ Leaf.request({
url: $('acr515_update_post_link').getUrl(), url: $('acr515_update_post_link').getUrl(),
para: param, para: param,
success: function() { success: function () {
Leaf.Masker.unmask(detail_mask); Leaf.Masker.unmask(detail_mask);
var _url=$('acr515_interface_excel_link').getUrl(); var _url = $('acr515_interface_excel_link').getUrl();
window.open(_url); window.open(_url);
ds.query(); ds.query();
}, },
failure: function() { failure: function () {
Leaf.Masker.unmask(detail_mask); Leaf.Masker.unmask(detail_mask);
}, },
error: function() { error: function () {
Leaf.Masker.unmask(detail_mask); Leaf.Masker.unmask(detail_mask);
}, },
scope: this scope: this
}); });
} }
function acr515_invoice_import(){
function acr515_invoice_import() {
var kind = $('acr515_invoiceVatParaDs').getAt(0).get('invoice_kind'); var kind = $('acr515_invoiceVatParaDs').getAt(0).get('invoice_kind');
//默认为2 //默认为2
kind=2; kind = 2;
new Leaf.Window({ new Leaf.Window({
id: 'gld_interface_window', id: 'gld_interface_window',
url: $('acr515_interface_import_link').getUrl()+'?kind='+kind, url: $('acr515_interface_import_link').getUrl() + '?kind=' + kind,
title: '导入开票结果', title: '导入开票结果',
fullScreen :true fullScreen: true
}); });
// window.location.href = // window.location.href =
} }
function summaryRenderer(datas, name) { function summaryRenderer(datas, name) {
var sum=0; var sum = 0;
var sum1=0; var sum1 = 0;
var sum2=0; var sum2 = 0;
if(name=="invoice_title"){ if (name == "invoice_title") {
return '合计:<font color="red"></font>'; return '合计:<font color="red"></font>';
} }
if(name=="total_amount"){ if (name == "total_amount") {
for(var i=0;i<datas.length;i++){ for (var i = 0; i < datas.length; i++) {
var record=datas[i]; var record = datas[i];
var payment_amount_vl=record.get("total_amount"); var payment_amount_vl = record.get("total_amount");
var payment_amount=parseFloat(payment_amount_vl); var payment_amount = parseFloat(payment_amount_vl);
if(!isNaN(payment_amount)){ if (!isNaN(payment_amount)) {
sum+=payment_amount; sum += payment_amount;
} }
} }
return '<font color="red">' + Leaf.formatNumber(sum ,2)+ '</font>'; return '<font color="red">' + Leaf.formatNumber(sum, 2) + '</font>';
} }
if(name=="tax_amount"){ if (name == "tax_amount") {
for(var j=0;j<datas.length;j++){ for (var j = 0; j < datas.length; j++) {
var record1=datas[j]; var record1 = datas[j];
var payment_amount_vl1=record1.get("tax_amount"); var payment_amount_vl1 = record1.get("tax_amount");
var payment_amount1=parseFloat(payment_amount_vl1); var payment_amount1 = parseFloat(payment_amount_vl1);
if(!isNaN(payment_amount1)){ if (!isNaN(payment_amount1)) {
sum1+=payment_amount1; sum1 += payment_amount1;
} }
} }
return '<font color="red">' + Leaf.formatNumber(sum1 ,2)+ '</font>'; return '<font color="red">' + Leaf.formatNumber(sum1, 2) + '</font>';
} }
if(name=="net_amount"){ if (name == "net_amount") {
for(var k=0;k<datas.length;k++){ for (var k = 0; k < datas.length; k++) {
var record2=datas[k]; var record2 = datas[k];
var payment_amount_vl2=record2.get("net_amount"); var payment_amount_vl2 = record2.get("net_amount");
var payment_amount2=parseFloat(payment_amount_vl2); var payment_amount2 = parseFloat(payment_amount_vl2);
if(!isNaN(payment_amount2)){ if (!isNaN(payment_amount2)) {
sum2+=payment_amount2; sum2 += payment_amount2;
} }
} }
return '<font color="red">' + Leaf.formatNumber(sum2 ,2)+ '</font>'; return '<font color="red">' + Leaf.formatNumber(sum2, 2) + '</font>';
} }
} }
function open_document_win(ds_id, record_id) { function open_document_win(ds_id, record_id) {
var record = $(ds_id).findById(record_id); var record = $(ds_id).findById(record_id);
var param = record.data; var param = record.data;
...@@ -311,6 +334,7 @@ ...@@ -311,6 +334,7 @@
param['url_title'] = '${l:ACR.INVOICE_DETAIL}'; param['url_title'] = '${l:ACR.INVOICE_DETAIL}';
hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'acr513_invoice_readonly_page', 'acr515_invoiceVatDs'); hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'acr513_invoice_readonly_page', 'acr515_invoiceVatDs');
} }
function acr512_document_number_render(value, record, name) { function acr512_document_number_render(value, record, name) {
if (name == 'document_number' && value) { if (name == 'document_number' && value) {
return '<a href="javascript:open_document_win(\'' + record.ds.id + '\',\'' + record.id + '\')">' + value + '</a>'; return '<a href="javascript:open_document_win(\'' + record.ds.id + '\',\'' + record.id + '\')">' + value + '</a>';
...@@ -336,63 +360,87 @@ ...@@ -336,63 +360,87 @@
<a:dataSet id="acr515_invoiceVatParaDs" autoCreate="true" model="acr.acr_invoice_hd_v"> <a:dataSet id="acr515_invoiceVatParaDs" autoCreate="true" model="acr.acr_invoice_hd_v">
<a:fields> <a:fields>
<a:field name="currency_desc" displayField="currency_name" options="acr515_currencyDs" returnField="currency" valueField="currency_code"/> <a:field name="currency_desc" displayField="currency_name" options="acr515_currencyDs"
returnField="currency" valueField="currency_code"/>
<a:field name="invoice_kind"/> <a:field name="invoice_kind"/>
<a:field name="invoice_kind_desc" displayField="code_value_name" options="acr515_invoiceKindDs" returnField="invoice_kind" valueField="code_value"/> <a:field name="invoice_kind_desc" displayField="code_value_name" options="acr515_invoiceKindDs"
<a:field name="invoice_status_desc" displayField="code_value_name" options="acr515_invoiceStatusDs" returnField="invoice_status" valueField="code_value"/> returnField="invoice_kind" valueField="code_value"/>
<a:field name="invoice_status_desc" displayField="code_value_name" options="acr515_invoiceStatusDs"
returnField="invoice_status" valueField="code_value"/>
<a:field name="vat_interface_status" defaultValue="UNTRANSFERED"/> <a:field name="vat_interface_status" defaultValue="UNTRANSFERED"/>
<a:field name="vat_interface_status_desc" defaultValue="未传金税" displayField="code_value_name" options="acr515_vat_interface_status_ds" returnField="vat_interface_status" valueField="code_value"/> <a:field name="vat_interface_status_desc" defaultValue="未传金税" displayField="code_value_name"
<a:field name="business_type_desc" displayField="business_type_desc" options="acr515_businessTypeDs" returnField="business_type" valueField="business_type"/> options="acr515_vat_interface_status_ds" returnField="vat_interface_status"
<a:field name="created_by_name" lovGridHeight="320" lovHeight="500" lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="ACR.CREATED_BY_NAME"> valueField="code_value"/>
<a:field name="business_type_desc" displayField="business_type_desc" options="acr515_businessTypeDs"
returnField="business_type" valueField="business_type"/>
<a:field name="created_by_name" lovGridHeight="320" lovHeight="500"
lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500"
title="ACR.CREATED_BY_NAME">
<a:mapping> <a:mapping>
<a:map from="user_id" to="created_by"/> <a:map from="user_id" to="created_by"/>
<a:map from="description" to="created_by_name"/> <a:map from="description" to="created_by_name"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="confirmed_by_name" lovGridHeight="320" lovHeight="500" lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500" title="ACR.CONFIRMED_BY_NAME"> <a:field name="confirmed_by_name" lovGridHeight="320" lovHeight="500"
lovService="acr.ACR512.acr_invoice_sys_user_lov" lovWidth="500"
title="ACR.CONFIRMED_BY_NAME">
<a:mapping> <a:mapping>
<a:map from="user_id" to="confirmed_by"/> <a:map from="user_id" to="confirmed_by"/>
<a:map from="description" to="confirmed_by_name"/> <a:map from="description" to="confirmed_by_name"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="invoice_bp_code_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500" title="ACR.INVOICE_BP_CODE"> <a:field name="invoice_bp_code_f" lovGridHeight="320" lovHeight="480"
lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500"
title="ACR.INVOICE_BP_CODE">
<a:mapping> <a:mapping>
<a:map from="bp_code" to="invoice_bp_code_f"/> <a:map from="bp_code" to="invoice_bp_code_f"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="invoice_bp_code_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500" title="ACR.INVOICE_BP_CODE"> <a:field name="invoice_bp_code_t" lovGridHeight="320" lovHeight="480"
lovService="acr.ACR512.acr_invoice_bp_master_list" lovWidth="500"
title="ACR.INVOICE_BP_CODE">
<a:mapping> <a:mapping>
<a:map from="bp_code" to="invoice_bp_code_t"/> <a:map from="bp_code" to="invoice_bp_code_t"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="project_number_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500" title="HLS.PROJECT_NUMBER_FROM"> <a:field name="project_number_f" lovGridHeight="320" lovHeight="480"
lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500"
title="HLS.PROJECT_NUMBER_FROM">
<a:mapping> <a:mapping>
<a:map from="project_number" to="project_number_f"/> <a:map from="project_number" to="project_number_f"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="project_number_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500" title="HLS.PROJECT_NUMBER_FROM"> <a:field name="project_number_t" lovGridHeight="320" lovHeight="480"
lovService="acr.ACR512.acr_invoice_project_list" lovWidth="500"
title="HLS.PROJECT_NUMBER_FROM">
<a:mapping> <a:mapping>
<a:map from="project_number" to="project_number_t"/> <a:map from="project_number" to="project_number_t"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="contract_number_f" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500" title="HLS.CONTRACT_NUMBER_FROM"> <a:field name="contract_number_f" lovGridHeight="320" lovHeight="480"
lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500"
title="HLS.CONTRACT_NUMBER_FROM">
<a:mapping> <a:mapping>
<a:map from="contract_number" to="contract_number_f"/> <a:map from="contract_number" to="contract_number_f"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="contract_number_t" lovGridHeight="320" lovHeight="480" lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500" title="HLS.CONTRACT_NUMBER_FROM"> <a:field name="contract_number_t" lovGridHeight="320" lovHeight="480"
lovService="acr.ACR512.acr_invoice_contract_list" lovWidth="500"
title="HLS.CONTRACT_NUMBER_FROM">
<a:mapping> <a:mapping>
<a:map from="contract_number" to="contract_number_t"/> <a:map from="contract_number" to="contract_number_t"/>
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="received_flag" checkedValue="Y" defaultValue="N" uncheckedValue="N"/> <a:field name="received_flag" checkedValue="Y" defaultValue="N" uncheckedValue="N"/>
<a:field name="express_status_name" displayField="code_value_name" options="acr515_express_status_ds" returnField="express_status" valueField="code_value"/> <a:field name="express_status_name" displayField="code_value_name"
options="acr515_express_status_ds" returnField="express_status" valueField="code_value"/>
</a:fields> </a:fields>
<a:events> <a:events>
<a:event name="update" handler="onUpdate_acr515_invoiceVatParaDs"/> <a:event name="update" handler="onUpdate_acr515_invoiceVatParaDs"/>
</a:events> </a:events>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr515_invoiceVatDs" autoPageSize="true" maxPageSize="10000" model="acr.acr_invoice_hd_v" queryDataSet="acr515_invoiceVatParaDs" selectable="true"> <a:dataSet id="acr515_invoiceVatDs" autoPageSize="true" maxPageSize="10000" model="acr.acr_invoice_hd_v"
queryDataSet="acr515_invoiceVatParaDs" selectable="true">
<a:fields><![CDATA[ <a:fields><![CDATA[
]]></a:fields> ]]></a:fields>
<a:events> <a:events>
...@@ -413,53 +461,62 @@ ...@@ -413,53 +461,62 @@
<a:gridButton click="acr515_vat_delete" text="删除接口"/> <a:gridButton click="acr515_vat_delete" text="删除接口"/>
<a:gridButton click="acr515_vat_receive" text="更新开票信息"/> --> <a:gridButton click="acr515_vat_receive" text="更新开票信息"/> -->
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form column="1" marginWidth="30" padding="0"> <a:form marginWidth="30" padding="0">
<a:hBox labelSeparator=" " labelWidth="100" column="4"> <a:hBox labelSeparator=" ">
<a:textField name="document_number_f" bindTarget="acr515_invoiceVatParaDs" prompt="HLS.DOCUMENT_NUMBER_FROM" width="150"/> <a:textField name="document_number_f" bindTarget="acr515_invoiceVatParaDs"
prompt="HLS.DOCUMENT_NUMBER_FROM" width="150"/>
<div><![CDATA[${l:HLS.DOCUMENT_NUMBER_TO}]]></div> <div><![CDATA[${l:HLS.DOCUMENT_NUMBER_TO}]]></div>
<a:textField name="document_number_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/> <a:textField name="document_number_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>
<a:lov name="contract_number_f" bindTarget="acr515_invoiceVatParaDs" prompt="HLS.CONTRACT_NUMBER_FROM" width="150"/> <a:lov name="contract_number_f" bindTarget="acr515_invoiceVatParaDs"
prompt="HLS.CONTRACT_NUMBER_FROM" width="150"/>
<div></div> <div></div>
<a:lov name="contract_number_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/> <a:lov name="contract_number_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>
<a:textField name="invoice_title" bindTarget="acr515_invoiceVatParaDs" width="150"/> <a:textField name="invoice_title" bindTarget="acr515_invoiceVatParaDs" width="150"/>
<a:lov name="confirmed_by_name" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="确认人"/> <a:lov name="confirmed_by_name" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="确认人"/>
</a:hBox> </a:hBox>
<a:hBox labelSeparator=" " labelWidth="100"> <a:hBox labelSeparator=" ">
<a:datePicker name="invoice_date_f" bindTarget="acr515_invoiceVatParaDs" prompt="ACR.INVOICE_DATE_FROM" width="150"/> <a:datePicker name="invoice_date_f" bindTarget="acr515_invoiceVatParaDs"
prompt="ACR.INVOICE_DATE_FROM" width="150"/>
<div><![CDATA[${l:ACR.INVOICE_DATE_TO}]]></div> <div><![CDATA[${l:ACR.INVOICE_DATE_TO}]]></div>
<a:datePicker name="invoice_date_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/> <a:datePicker name="invoice_date_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>
<!-- <div><![CDATA[${l:HLS.CUSTOMER_NUMBER_TO}]]></div> <!-- <div><![CDATA[${l:HLS.CUSTOMER_NUMBER_TO}]]></div>
<a:lov name="invoice_bp_code_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>--> <a:lov name="invoice_bp_code_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>-->
<a:textField name="invoice_number_f" bindTarget="acr515_invoiceVatParaDs" prompt="ACR.INVOICE_NUMBER_FROM" width="150"/> <a:textField name="invoice_number_f" bindTarget="acr515_invoiceVatParaDs"
prompt="ACR.INVOICE_NUMBER_FROM" width="150"/>
<div><![CDATA[${l:ACR.INVOICE_NUMBER_TO}]]></div> <div><![CDATA[${l:ACR.INVOICE_NUMBER_TO}]]></div>
<a:textField name="invoice_number_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/> <a:textField name="invoice_number_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>
<a:comboBox name="invoice_status_desc" bindTarget="acr515_invoiceVatParaDs" width="150"/> <a:comboBox name="invoice_status_desc" bindTarget="acr515_invoiceVatParaDs" width="150"/>
<a:comboBox name="vat_interface_status_desc" bindTarget="acr515_invoiceVatParaDs" width="150"/> <a:comboBox name="vat_interface_status_desc" bindTarget="acr515_invoiceVatParaDs" width="150"/>
</a:hBox> </a:hBox>
<a:hBox labelSeparator=" " labelWidth="100"> <a:hBox labelSeparator=" ">
<a:datePicker name="accounting_date_f" bindTarget="acr515_invoiceVatParaDs" prompt="HLS.ACCOUNT_DATE_FROM" width="150"/> <a:datePicker name="accounting_date_f" bindTarget="acr515_invoiceVatParaDs"
prompt="HLS.ACCOUNT_DATE_FROM" width="150"/>
<div><![CDATA[${l:HLS.ACCOUNT_DATE_TO}]]></div> <div><![CDATA[${l:HLS.ACCOUNT_DATE_TO}]]></div>
<a:datePicker name="accounting_date_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/> <a:datePicker name="accounting_date_t" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/>
<a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr515_invoiceVatParaDs" prompt="发票金额从" width="150"/> <a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr515_invoiceVatParaDs"
prompt="发票金额从" width="150"/>
<div><![CDATA[${l:ACR.TOTAL_AMOUNT_TO}]]></div> <div><![CDATA[${l:ACR.TOTAL_AMOUNT_TO}]]></div>
<a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr515_invoiceVatParaDs" prompt="" width="150"/> <a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr515_invoiceVatParaDs"
prompt="" width="150"/>
<a:comboBox name="invoice_kind_desc" bindTarget="acr515_invoiceVatParaDs" width="150"/> <a:comboBox name="invoice_kind_desc" bindTarget="acr515_invoiceVatParaDs" width="150"/>
<a:lov name="created_by_name" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="创建人"/> <a:lov name="created_by_name" bindTarget="acr515_invoiceVatParaDs" width="150" prompt="创建人"/>
</a:hBox> </a:hBox>
<a:hBox labelWidth="100"> <a:hBox labelSeparator=" ">
<a:lov name="invoice_bp_code_f" bindTarget="acr515_invoiceVatParaDs" prompt="客户编号" width="150"/> <a:lov name="invoice_bp_code_f" bindTarget="acr515_invoiceVatParaDs" prompt="客户编号" width="150"/>
<a:textField name="invoice_apply_num" bindTarget="acr515_invoiceVatParaDs" prompt="申请编号"
width="120"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr515_invoiceVatDs_grid" bindTarget="acr515_invoiceVatDs" marginWidth="80" navBar="true" marginHeight="200"> <a:grid id="acr515_invoiceVatDs_grid" bindTarget="acr515_invoiceVatDs" marginWidth="30" navBar="true"
marginHeight="200">
<a:columns> <a:columns>
<a:column name="contract_number" width="120"/>
<a:column name="document_number" lock="true" width="120" renderer="acr512_document_number_render"/> <a:column name="document_number" lock="true" width="120" renderer="acr512_document_number_render"/>
<!-- <a:column name="business_type_desc" width="80"/>--> <a:column name="invoice_apply_num" width="120" prompt="申请编号" lock="true"/>
<a:column name="contract_number" width="120"/>
<!-- <a:column name="business_type_desc" width="80"/>-->
<a:column name="billing_way_desc" width="80" prompt="开票方式"/> <a:column name="billing_way_desc" width="80" prompt="开票方式"/>
<a:column name="invoice_kind_desc" width="100"/> <a:column name="invoice_kind_desc" width="100"/>
<a:column name="invoice_number" width="120"/> <a:column name="invoice_number" width="120"/>
...@@ -467,12 +524,18 @@ ...@@ -467,12 +524,18 @@
<a:column name="invoice_date" renderer="Leaf.formatDate" width="100"/> <a:column name="invoice_date" renderer="Leaf.formatDate" width="100"/>
<a:column name="invoice_bp_code" width="100"/> <a:column name="invoice_bp_code" width="100"/>
<a:column name="invoice_bp_name" autoAdjust="false" showTitle="true" width="150"/> <a:column name="invoice_bp_name" autoAdjust="false" showTitle="true" width="150"/>
<a:column name="invoice_title" autoAdjust="false" footerRenderer="summaryRenderer" showTitle="true" width="150"/> <a:column name="invoice_title" autoAdjust="false" footerRenderer="summaryRenderer" showTitle="true"
<a:column name="total_amount" align="right" footerRenderer="summaryRenderer" renderer="Leaf.formatMoney" width="100"/> width="150"/>
<a:column name="tax_amount" align="right" footerRenderer="summaryRenderer" renderer="Leaf.formatMoney" width="100"/> <a:column name="total_amount" align="right" footerRenderer="summaryRenderer"
<a:column name="return_tax_amount" align="right" footerRenderer="summaryRenderer" renderer="Leaf.formatMoney" width="100"/> renderer="Leaf.formatMoney" width="100"/>
<a:column name="dif_tax_amount" align="right" footerRenderer="summaryRenderer" renderer="Leaf.formatMoney" width="100"/> <a:column name="tax_amount" align="right" footerRenderer="summaryRenderer"
<a:column name="net_amount" align="right" footerRenderer="summaryRenderer" renderer="Leaf.formatMoney" width="100"/> renderer="Leaf.formatMoney" width="100"/>
<a:column name="return_tax_amount" align="right" footerRenderer="summaryRenderer"
renderer="Leaf.formatMoney" width="100"/>
<a:column name="dif_tax_amount" align="right" footerRenderer="summaryRenderer"
renderer="Leaf.formatMoney" width="100"/>
<a:column name="net_amount" align="right" footerRenderer="summaryRenderer"
renderer="Leaf.formatMoney" width="100"/>
<a:column name="currency" width="80"/> <a:column name="currency" width="80"/>
<a:column name="created_by_name" autoAdjust="false" showTitle="true" width="150" prompt="创建人"/> <a:column name="created_by_name" autoAdjust="false" showTitle="true" width="150" prompt="创建人"/>
<a:column name="confirmed_by_name" autoAdjust="false" showTitle="true" width="150" prompt="确认人"/> <a:column name="confirmed_by_name" autoAdjust="false" showTitle="true" width="150" prompt="确认人"/>
......
...@@ -4,18 +4,20 @@ ...@@ -4,18 +4,20 @@
</a:init-procedure> </a:init-procedure>
<a:view> <a:view>
<a:link id="con_contract_modify_link" url="${/request/@context_path}/modules/cont/CON505/con_contract_modify.lview"/> <a:link id="con_contract_modify_link"
<a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/> url="${/request/@context_path}/modules/cont/CON505/con_contract_modify.lview"/>
<a:link id="con_contract_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
modelaction="update"/>
<script type="text/javascript"><![CDATA[ <script type="text/javascript"><![CDATA[
function document_number_render(value,record,name) function document_number_render(value, record, name) {
{
if (name == 'document_number' && value) { if (name == 'document_number' && value) {
return '<a href="javascript:open_document_win(\'' + record.ds.id + '\',\'' + record.id + '\')">' + value + '</a>'; return '<a href="javascript:open_document_win(\'' + record.ds.id + '\',\'' + record.id + '\')">' + value + '</a>';
} }
return value; return value;
} }
function open_document_win(ds_id, record_id) { function open_document_win(ds_id, record_id) {
var record = $(ds_id).findById(record_id); var record = $(ds_id).findById(record_id);
var param = record.data; var param = record.data;
...@@ -25,6 +27,7 @@ ...@@ -25,6 +27,7 @@
param['url_title'] = '${l:ACR.INVOICE_DETAIL}'; param['url_title'] = '${l:ACR.INVOICE_DETAIL}';
hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'con_contract_modify_link', ds_id); hls_doc_get_layout_code('con_contract_get_layout_code_link_id', param, 'con_contract_modify_link', ds_id);
} }
//发票超练级 //发票超练级
function acr516_invoice_query() { function acr516_invoice_query() {
$('acr516_invoice_result_ds').query(); $('acr516_invoice_result_ds').query();
...@@ -35,20 +38,22 @@ ...@@ -35,20 +38,22 @@
} }
function acr516_invoice_apply() { function acr516_invoice_apply() {
var records=$('acr516_invoice_result_ds').getSelected(); var records = $('acr516_invoice_result_ds').getSelected();
var datas = []; var datas = [];
for (var i = 0;i < records.length;i++) { for (var i = 0; i < records.length; i++) {
datas.push({ datas.push({
'invoice_hd_id':records[i].get('invoice_hd_id'), 'invoice_hd_id': records[i].get('invoice_hd_id'),
'_status': 'update' '_status': 'update'
}) })
} }
$L.showConfirm("提示",'确认执行该操作?',function(){ $L.showConfirm("提示", '确认执行该操作?', function () {
Leaf.Masker.mask(Ext.getBody(),'正在操作...');
Leaf.request({ Leaf.request({
url: '${/request/@context_path}/autocrud/acr.ACR604.acr_invoice_claim_application_new/batch_update', url: '${/request/@context_path}/autocrud/acr.ACR604.acr_invoice_claim_application_new/batch_update',
para: datas, para: datas,
success: function () { success: function () {
Leaf.Masker.unmask(Ext.getBody());
Leaf.SideBar.show({ Leaf.SideBar.show({
msg: '操作成功', msg: '操作成功',
duration: 2000 duration: 2000
...@@ -67,9 +72,11 @@ ...@@ -67,9 +72,11 @@
}) })
} }
function submit_success_btn(){
function submit_success_btn(ds) {
$('acr516_invoice_result_ds').query(); $('acr516_invoice_result_ds').query();
} }
]]></script> ]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/> <a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
<a:dataSets> <a:dataSets>
...@@ -80,17 +87,33 @@ ...@@ -80,17 +87,33 @@
<a:datas dataSource="/model/hls_cashflow_item_list"/> <a:datas dataSource="/model/hls_cashflow_item_list"/>
</a:dataSet> </a:dataSet>
<a:dataSet id="claim_status_ds" loadData="true" lookupCode="CLAIM_STATUS"/> <a:dataSet id="claim_status_ds" loadData="true" lookupCode="CLAIM_STATUS"/>
<a:dataSet id="csh_transaction_flag_ds">
<a:datas>
<a:record code_value="NOT" code_value_name="未收款"/>
<a:record code_value="FULL" code_value_name="完全收款"/>
<a:record code_value="PARTIAL" code_value_name="部分收款"/>
</a:datas>
</a:dataSet>
<a:dataSet id="acr516_invoice_query_ds" autoCreate="true"> <a:dataSet id="acr516_invoice_query_ds" autoCreate="true">
<a:fields> <a:fields>
<a:field name="invoice_apply_num"/>
<a:field name="invoice_kind_desc" displayField="code_value_name" options="acr516_invoice_kind_ds" <a:field name="invoice_kind_desc" displayField="code_value_name" options="acr516_invoice_kind_ds"
returnField="invoice_kind" valueField="code_value"/> returnField="invoice_kind" valueField="code_value"/>
<a:field name="invoice_status_desc" displayField="code_value_name" options="acr516_invoice_statu_ds" returnField="invoice_status" valueField="code_value"/> <a:field name="invoice_status_desc" displayField="code_value_name" options="acr516_invoice_statu_ds"
returnField="invoice_status" valueField="code_value"/>
<a:field name="total_amount"/> <a:field name="total_amount"/>
<a:field name="csh_transaction_flag"/>
<a:field name="csh_transaction_flag_desc" options="csh_transaction_flag_ds"
displayField="code_value_name" returnField="code_value" valueField="csh_transaction_flag"/>
<a:field name="cf_item"/> <a:field name="cf_item"/>
<a:field name="cf_item_n" options="cf_item_options" displayField="description" returnField="cf_item" valueField="cf_item"/> <a:field name="cf_item_n" options="cf_item_options" displayField="description" returnField="cf_item"
<a:field name="claim_status_n" options="claim_status_ds" displayField="code_value_name" valueField="code_value" returnField="claim_status"/> valueField="cf_item"/>
<a:field name="cf_item_desc" autoComplete="true" lovGridHeight="350" lovHeight="500" lovLabelWidth="100" lovService="acr.ACR510.hls_cashflow_item_v_lov" lovWidth="520" title="现金流项目"> <a:field name="claim_status_n" options="claim_status_ds" displayField="code_value_name"
valueField="code_value" returnField="claim_status"/>
<a:field name="cf_item_desc" autoComplete="true" lovGridHeight="350" lovHeight="500"
lovLabelWidth="100" lovService="acr.ACR510.hls_cashflow_item_v_lov" lovWidth="520"
title="现金流项目">
<a:mapping> <a:mapping>
<a:map from="cf_item" to="cf_item"/> <a:map from="cf_item" to="cf_item"/>
<a:map from="cf_item_desc" to="cf_item_desc"/> <a:map from="cf_item_desc" to="cf_item_desc"/>
...@@ -100,8 +123,9 @@ ...@@ -100,8 +123,9 @@
returnField="claim_status" valueField="code_value"/> returnField="claim_status" valueField="code_value"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr516_invoice_result_ds" autoPageSize="true" autoQuery="true" <a:dataSet id="acr516_invoice_result_ds" fetchAll="false" autoPageSize="true" autoQuery="true"
model="acr.ACR604.acr_invoice_claim_application_new" queryDataSet="acr516_invoice_query_ds" selectable="true"> model="acr.ACR604.acr_invoice_claim_application_new" queryDataSet="acr516_invoice_query_ds"
selectable="true">
<a:events> <a:events>
<a:event name="submitsuccess" handler="submit_success_btn"/> <a:event name="submitsuccess" handler="submit_success_btn"/>
</a:events> </a:events>
...@@ -115,45 +139,56 @@ ...@@ -115,45 +139,56 @@
<a:toolbarButton click="acr516_invoice_apply" text="申请"/> <a:toolbarButton click="acr516_invoice_apply" text="申请"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form marginWidth="30" padding="0" title="查询条件" column="4"> <a:form marginWidth="30" padding="0" title="查询条件" column="4">
<a:textField name="document_number" bindTarget="acr516_invoice_query_ds" prompt="单据编号" width="135"/> <a:textField name="document_number" bindTarget="acr516_invoice_query_ds" prompt="单据编号" width="120"/>
<a:textField name="contract_number" bindTarget="acr516_invoice_query_ds" prompt="合同编号" width="135"/> <a:textField name="contract_number" bindTarget="acr516_invoice_query_ds" prompt="合同编号" width="120"/>
<a:textField name="contract_name" bindTarget="acr516_invoice_query_ds" prompt="合同名称" width="135"/> <a:textField name="contract_name" bindTarget="acr516_invoice_query_ds" prompt="合同名称" width="120"/>
<!-- <a:lov name="cf_item_desc" bindTarget="acr516_invoice_query_ds" prompt="现金流项目" width="135"/>--> <!-- <a:lov name="cf_item_desc" bindTarget="acr516_invoice_query_ds" prompt="现金流项目" width="135"/>-->
<a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr516_invoice_query_ds" prompt="开票金额含税额从" width="135"/> <a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr516_invoice_query_ds"
<a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr516_invoice_query_ds" prompt="开票金额含税额到" width="135"/> prompt="开票金额含税额从" width="120"/>
<a:textField name="invoice_title" bindTarget="acr516_invoice_query_ds" prompt="发票抬头" width="135"/> <a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr516_invoice_query_ds"
<a:comboBox name="invoice_kind_desc" bindTarget="acr516_invoice_query_ds" prompt="ACR.INVOICE_KIND" width="135"/> prompt="开票金额含税额到" width="120"/>
<!-- <a:comboBox name="invoice_status_desc" bindTarget="acr516_invoice_query_ds" prompt="发票状态" width="135"/>--> <a:textField name="invoice_title" bindTarget="acr516_invoice_query_ds" prompt="发票抬头" width="120"/>
<a:textField name="vat_invoice_code" bindTarget="acr516_invoice_query_ds" prompt="发票代码" width="135"/> <a:comboBox name="invoice_kind_desc" bindTarget="acr516_invoice_query_ds" prompt="ACR.INVOICE_KIND"
<a:textField name="invoice_number" bindTarget="acr516_invoice_query_ds" prompt="发票号码" width="135"/> width="120"/>
<a:comboBox name="claim_status_n" bindTarget="acr516_invoice_query_ds" prompt="认领状态" width="135"/> <!-- <a:comboBox name="invoice_status_desc" bindTarget="acr516_invoice_query_ds" prompt="发票状态" width="135"/>-->
<a:textField name="vat_invoice_code" bindTarget="acr516_invoice_query_ds" prompt="发票代码" width="120"/>
<a:textField name="invoice_number" bindTarget="acr516_invoice_query_ds" prompt="发票号码" width="120"/>
<a:comboBox name="claim_status_n" bindTarget="acr516_invoice_query_ds" prompt="认领状态" width="120"/>
<a:comboBox name="csh_transaction_flag_desc" bindTarget="acr516_invoice_query_ds" prompt="收款标记"
width="120"/>
<a:textField name="invoice_apply_num" bindTarget="acr516_invoice_query_ds" prompt="申请编号" width="120"/>
<a:datePicker name="invoice_date_from" bindTarget="acr516_invoice_query_ds" prompt="发票日期从" width="120"/>
<a:datePicker name="invoice_date_to" bindTarget="acr516_invoice_query_ds" prompt="发票日期到" width="120"/>
</a:form> </a:form>
<a:grid id="acr516_invoice_grid_id" bindTarget="acr516_invoice_result_ds" marginHeight="225" marginWidth="30" navBar="true"> <a:grid id="acr516_invoice_grid_id" bindTarget="acr516_invoice_result_ds" marginHeight="225"
marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="HLS.DOCUMENT_NUMBER" width="120" renderer="document_number_render"/> <a:column name="document_number" lock="true" prompt="HLS.DOCUMENT_NUMBER" width="120"
<a:column name="contract_number" autoAdjust="false" prompt="HLS.CONTRACT_NUMBER" showTitle="true" width="150"/> renderer="document_number_render"/>
<a:column name="contract_name" width="150" prompt="合同名称"/> <a:column name="contract_number" autoAdjust="false" prompt="HLS.CONTRACT_NUMBER" showTitle="true"
width="150"/>
<!-- <a:column name="contract_name" width="150" prompt="合同名称"/>-->
<a:column name="bp_agent_name" prompt="代理商" width="100"/> <a:column name="bp_agent_name" prompt="代理商" width="100"/>
<a:column name="invoice_kind_desc" prompt="发票种类" width="100"/> <a:column name="invoice_kind_desc" prompt="发票种类" width="100"/>
<a:column name="invoice_number" width="120" prompt="发票号码"/> <a:column name="invoice_number" width="120" prompt="发票号码"/>
<a:column name="vat_invoice_code" width="120" prompt="发票代码"/> <a:column name="vat_invoice_code" width="120" prompt="发票代码"/>
<a:column name="invoice_date" renderer="Leaf.formatDate" prompt="发票日期" width="100"/> <a:column name="invoice_date" renderer="Leaf.formatDate" prompt="发票日期" width="100"/>
<a:column name="invoice_bp_code" prompt="开票客户编号" width="100"/> <a:column name="invoice_bp_code" prompt="开票客户编号" width="100"/>
<a:column name="invoice_bp_name" autoAdjust="false" showTitle="true" prompt="开票客户名称" width="150"/> <!-- <a:column name="invoice_bp_name" autoAdjust="false" showTitle="true" prompt="开票客户名称" width="150"/>-->
<a:column name="invoice_title" autoAdjust="false" showTitle="true" prompt="发票抬头" width="150"/> <a:column name="invoice_title" autoAdjust="false" showTitle="true" prompt="发票抬头" width="150"/>
<a:column name="total_amount" align="right" renderer="Leaf.formatMoney" prompt="发票金额" width="100"/> <a:column name="total_amount" align="right" renderer="Leaf.formatMoney" prompt="发票金额" width="100"/>
<a:column name="tax_amount" align="right" renderer="Leaf.formatMoney" prompt="税额" width="100"/> <a:column name="tax_amount" align="right" renderer="Leaf.formatMoney" prompt="税额" width="100"/>
<a:column name="net_amount" align="right" renderer="Leaf.formatMoney" prompt="不含税金额" width="100"/> <a:column name="net_amount" align="right" renderer="Leaf.formatMoney" prompt="不含税金额" width="100"/>
<a:column name="currency" prompt="币种" width="80"/> <!-- <a:column name="currency" prompt="币种" width="80"/>-->
<a:column name="created_by_name" autoAdjust="false" showTitle="true" prompt="创建人" width="150"/> <a:column name="created_by_name" autoAdjust="false" showTitle="true" prompt="创建人" width="150"/>
<a:column name="invoice_status_desc" prompt="发票状态" width="100"/> <!-- <a:column name="invoice_status_desc" prompt="发票状态" width="100"/>-->
<a:column name="vat_interface_status_desc" prompt="金税状态" width="100"/> <!-- <a:column name="vat_interface_status_desc" prompt="金税状态" width="100"/>-->
<a:column name="accounting_date" renderer="Leaf.formatDate" prompt="期间序号" width="100"/> <a:column name="accounting_date" renderer="Leaf.formatDate" prompt="期间序号" width="100"/>
<a:column name="create_je_flag" prompt="凭证标志" width="60"/> <!-- <a:column name="create_je_flag" prompt="凭证标志" width="60"/>-->
<a:column name="bp_tax_registry_num" prompt="纳税人识别号"/> <a:column name="bp_tax_registry_num" prompt="纳税人识别号"/>
<!-- <a:column name="ele_invoice_status_desc" prompt="电子发票状态"/>-->
<!-- <a:column name="swno" prompt="电子发票流水号" width="100"/>-->
<a:column name="claim_status_n" prompt="认领状态" width="100"/> <a:column name="claim_status_n" prompt="认领状态" width="100"/>
<a:column name="invoice_apply_num" prompt="申请编号" width="120"/>
<a:column name="csh_transaction_flag_desc" prompt="收款标记" width="80"/>
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:screenBody> </a:screenBody>
......
...@@ -103,10 +103,12 @@ ...@@ -103,10 +103,12 @@
} }
$L.showConfirm("提示",'确认执行该操作?',function(){ $L.showConfirm("提示",'确认执行该操作?',function(){
Leaf.Masker.mask(Ext.getBody(),'正在操作...');
Leaf.request({ Leaf.request({
url: '${/request/@context_path}/autocrud/acr.ACR605.acr_invoice_claim_return/batch_update', url: '${/request/@context_path}/autocrud/acr.ACR605.acr_invoice_claim_return/batch_update',
para: datas, para: datas,
success: function () { success: function () {
Leaf.Masker.unmask(Ext.getBody());
Leaf.SideBar.show({ Leaf.SideBar.show({
msg: '操作成功', msg: '操作成功',
duration: 2000 duration: 2000
...@@ -139,14 +141,25 @@ ...@@ -139,14 +141,25 @@
<a:datas dataSource="/model/hls_cashflow_item_list"/> <a:datas dataSource="/model/hls_cashflow_item_list"/>
</a:dataSet> </a:dataSet>
<!-- <a:dataSet id="claim_status_ds" loadData="true" lookupCode="CLAIM_STATUS"/>--> <!-- <a:dataSet id="claim_status_ds" loadData="true" lookupCode="CLAIM_STATUS"/>-->
<a:dataSet id="csh_transaction_flag_ds">
<a:datas>
<a:record code_value="NOT" code_value_name="未收款"/>
<a:record code_value="FULL" code_value_name="完全收款"/>
<a:record code_value="PARTIAL" code_value_name="部分收款"/>
</a:datas>
</a:dataSet>
<a:dataSet id="acr517_invoice_query_ds" autoCreate="true"> <a:dataSet id="acr517_invoice_query_ds" autoCreate="true">
<a:fields> <a:fields>
<a:field name="document_number"/> <a:field name="document_number"/>
<a:field name="invoice_apply_num"/>
<a:field name="invoice_kind_desc" displayField="code_value_name" options="acr517_invoice_kind_ds" <a:field name="invoice_kind_desc" displayField="code_value_name" options="acr517_invoice_kind_ds"
returnField="invoice_kind" valueField="code_value"/> returnField="invoice_kind" valueField="code_value"/>
<a:field name="invoice_status_desc" displayField="code_value_name" options="acr517_invoice_statu_ds" returnField="invoice_status" valueField="code_value"/> <a:field name="invoice_status_desc" displayField="code_value_name" options="acr517_invoice_statu_ds" returnField="invoice_status" valueField="code_value"/>
<a:field name="total_amount"/> <a:field name="total_amount"/>
<a:field name="csh_transaction_flag"/>
<a:field name="csh_transaction_flag_desc" options="csh_transaction_flag_ds"
displayField="code_value_name" returnField="code_value" valueField="csh_transaction_flag"/>
<a:field name="cf_item"/> <a:field name="cf_item"/>
<a:field name="cf_item_n" options="cf_item_options" displayField="description" returnField="cf_item" valueField="cf_item"/> <a:field name="cf_item_n" options="cf_item_options" displayField="description" returnField="cf_item" valueField="cf_item"/>
<!-- <a:field name="claim_status" options="claim_status_ds" displayField="code_value_name" valueField="code_value" returnField="claim_status"/>--> <!-- <a:field name="claim_status" options="claim_status_ds" displayField="code_value_name" valueField="code_value" returnField="claim_status"/>-->
...@@ -160,7 +173,7 @@ ...@@ -160,7 +173,7 @@
returnField="claim_status" valueField="code_value"/> returnField="claim_status" valueField="code_value"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr517_invoice_result_ds" autoPageSize="true" autoQuery="true" <a:dataSet id="acr517_invoice_result_ds" autoQuery="true" fetchAll="false" autoPageSize="true"
model="acr.ACR605.acr_invoice_claim_confirm_new" queryDataSet="acr517_invoice_query_ds" selectable="true"> model="acr.ACR605.acr_invoice_claim_confirm_new" queryDataSet="acr517_invoice_query_ds" selectable="true">
<a:events> <a:events>
<a:event name="submitsuccess" handler="submit_success_btn"/> <a:event name="submitsuccess" handler="submit_success_btn"/>
...@@ -176,18 +189,23 @@ ...@@ -176,18 +189,23 @@
<a:toolbarButton click="acr517_invoice_return" text="退回"/> <a:toolbarButton click="acr517_invoice_return" text="退回"/>
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form marginWidth="30" padding="0" title="查询条件" column="4"> <a:form marginWidth="30" padding="0" title="查询条件" column="4">
<a:textField name="document_number" bindTarget="acr517_invoice_query_ds" prompt="单据编号" width="135"/> <a:textField name="document_number" bindTarget="acr517_invoice_query_ds" prompt="单据编号" width="120"/>
<a:textField name="contract_number" bindTarget="acr517_invoice_query_ds" prompt="合同编号" width="135"/> <a:textField name="contract_number" bindTarget="acr517_invoice_query_ds" prompt="合同编号" width="120"/>
<a:textField name="contract_name" bindTarget="acr517_invoice_query_ds" prompt="合同名称" width="135"/> <a:textField name="contract_name" bindTarget="acr517_invoice_query_ds" prompt="合同名称" width="120"/>
<!-- <a:lov name="cf_item_desc" bindTarget="acr517_invoice_query_ds" prompt="现金流项目" width="135"/>--> <!-- <a:lov name="cf_item_desc" bindTarget="acr517_invoice_query_ds" prompt="现金流项目" width="135"/>-->
<a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr517_invoice_query_ds" prompt="开票金额含税额从" width="135"/> <a:numberField name="total_amount_f" allowFormat="true" bindTarget="acr517_invoice_query_ds" prompt="开票金额含税额从" width="120"/>
<a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr517_invoice_query_ds" prompt="开票金额含税额到" width="135"/> <a:numberField name="total_amount_t" allowFormat="true" bindTarget="acr517_invoice_query_ds" prompt="开票金额含税额到" width="120"/>
<a:textField name="invoice_title" bindTarget="acr517_invoice_query_ds" prompt="发票抬头" width="135"/> <a:textField name="invoice_title" bindTarget="acr517_invoice_query_ds" prompt="发票抬头" width="120"/>
<a:comboBox name="invoice_kind_desc" bindTarget="acr517_invoice_query_ds" prompt="ACR.INVOICE_KIND" width="135"/> <a:comboBox name="invoice_kind_desc" bindTarget="acr517_invoice_query_ds" prompt="ACR.INVOICE_KIND" width="120"/>
<!-- <a:comboBox name="invoice_status_desc" bindTarget="acr517_invoice_query_ds" prompt="发票状态" width="135"/>--> <!-- <a:comboBox name="invoice_status_desc" bindTarget="acr517_invoice_query_ds" prompt="发票状态" width="135"/>-->
<a:textField name="vat_invoice_code" bindTarget="acr517_invoice_query_ds" prompt="发票代码" width="135"/> <a:textField name="vat_invoice_code" bindTarget="acr517_invoice_query_ds" prompt="发票代码" width="120"/>
<a:textField name="invoice_number" bindTarget="acr517_invoice_query_ds" prompt="发票号码" width="135"/> <a:textField name="invoice_number" bindTarget="acr517_invoice_query_ds" prompt="发票号码" width="120"/>
<a:comboBox name="claim_status_n" bindTarget="acr517_invoice_query_ds" prompt="认领状态" width="135"/> <a:comboBox name="claim_status_n" bindTarget="acr517_invoice_query_ds" prompt="认领状态" width="120"/>
<a:comboBox name="csh_transaction_flag_desc" bindTarget="acr516_invoice_query_ds" prompt="收款标记"
width="120"/>
<a:textField name="invoice_apply_num" bindTarget="acr516_invoice_query_ds" prompt="申请编号" width="120"/>
<a:datePicker name="invoice_date_from" bindTarget="acr516_invoice_query_ds" prompt="发票日期从" width="120"/>
<a:datePicker name="invoice_date_to" bindTarget="acr516_invoice_query_ds" prompt="发票日期到" width="120"/>
</a:form> </a:form>
<a:grid id="acr516_invoice_grid_id" bindTarget="acr517_invoice_result_ds" marginHeight="225" marginWidth="30" navBar="true"> <a:grid id="acr516_invoice_grid_id" bindTarget="acr517_invoice_result_ds" marginHeight="225" marginWidth="30" navBar="true">
<a:columns> <a:columns>
...@@ -200,21 +218,23 @@ ...@@ -200,21 +218,23 @@
<a:column name="vat_invoice_code" width="120" prompt="发票代码"/> <a:column name="vat_invoice_code" width="120" prompt="发票代码"/>
<a:column name="invoice_date" renderer="Leaf.formatDate" prompt="发票日期" width="100"/> <a:column name="invoice_date" renderer="Leaf.formatDate" prompt="发票日期" width="100"/>
<a:column name="invoice_bp_code" prompt="开票客户编号" width="100"/> <a:column name="invoice_bp_code" prompt="开票客户编号" width="100"/>
<a:column name="invoice_bp_name" autoAdjust="false" showTitle="true" prompt="开票客户名称" width="150"/> <!-- <a:column name="invoice_bp_name" autoAdjust="false" showTitle="true" prompt="开票客户名称" width="150"/>-->
<a:column name="invoice_title" autoAdjust="false" showTitle="true" prompt="发票抬头" width="150"/> <a:column name="invoice_title" autoAdjust="false" showTitle="true" prompt="发票抬头" width="150"/>
<a:column name="total_amount" align="right" renderer="Leaf.formatMoney" prompt="发票金额" width="100"/> <a:column name="total_amount" align="right" renderer="Leaf.formatMoney" prompt="发票金额" width="100"/>
<a:column name="tax_amount" align="right" renderer="Leaf.formatMoney" prompt="税额" width="100"/> <a:column name="tax_amount" align="right" renderer="Leaf.formatMoney" prompt="税额" width="100"/>
<a:column name="net_amount" align="right" renderer="Leaf.formatMoney" prompt="不含税金额" width="100"/> <a:column name="net_amount" align="right" renderer="Leaf.formatMoney" prompt="不含税金额" width="100"/>
<a:column name="currency" prompt="币种" width="80"/> <!-- <a:column name="currency" prompt="币种" width="80"/>-->
<a:column name="created_by_name" autoAdjust="false" showTitle="true" prompt="创建人" width="150"/> <a:column name="created_by_name" autoAdjust="false" showTitle="true" prompt="创建人" width="150"/>
<a:column name="invoice_status_desc" prompt="发票状态" width="100"/> <!-- <a:column name="invoice_status_desc" prompt="发票状态" width="100"/>-->
<a:column name="vat_interface_status_desc" prompt="金税状态" width="100"/> <!-- <a:column name="vat_interface_status_desc" prompt="金税状态" width="100"/>-->
<a:column name="accounting_date" renderer="Leaf.formatDate" prompt="期间序号" width="100"/> <a:column name="accounting_date" renderer="Leaf.formatDate" prompt="期间序号" width="100"/>
<a:column name="create_je_flag" prompt="凭证标志" width="60"/> <!-- <a:column name="create_je_flag" prompt="凭证标志" width="60"/>-->
<a:column name="bp_tax_registry_num" prompt="纳税人识别号"/> <a:column name="bp_tax_registry_num" prompt="纳税人识别号"/>
<!-- <a:column name="ele_invoice_status_desc" prompt="电子发票状态"/>--> <!-- <a:column name="ele_invoice_status_desc" prompt="电子发票状态"/>-->
<!-- <a:column name="swno" prompt="电子发票流水号" width="100"/>--> <!-- <a:column name="swno" prompt="电子发票流水号" width="100"/>-->
<a:column name="claim_status_n" prompt="认领状态" width="100"/> <a:column name="claim_status_n" prompt="认领状态" width="100"/>
<a:column name="invoice_apply_num" prompt="申请编号" width="120"/>
<a:column name="csh_transaction_flag_desc" prompt="收款标记" width="80"/>
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:screenBody> </a:screenBody>
......
...@@ -7,8 +7,10 @@ ...@@ -7,8 +7,10 @@
--> -->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true"> <a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true">
<a:view> <a:view>
<a:link id="acr_invoice_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/> <a:link id="acr_invoice_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
<a:link id="acr610_invoice_detail_link" url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_detail_readonly.lview"/> modelaction="update"/>
<a:link id="acr610_invoice_detail_link"
url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_detail_readonly.lview"/>
<a:link id="acr610_detail_submit_link" model="acr.ACR610.acr_invoice_apply_detail" modelaction="update"/> <a:link id="acr610_detail_submit_link" model="acr.ACR610.acr_invoice_apply_detail" modelaction="update"/>
<a:link id="attachment_uploadFile_id" url="${/request/@context_path}/uploadFile.lview"/> <a:link id="attachment_uploadFile_id" url="${/request/@context_path}/uploadFile.lview"/>
<a:link id="attachment_downloadFile_id" url="${/request/@context_path}/downloadFile.lview"/> <a:link id="attachment_downloadFile_id" url="${/request/@context_path}/downloadFile.lview"/>
...@@ -75,7 +77,7 @@ ...@@ -75,7 +77,7 @@
} }
function acr610_detail_upload_window(file_id) { function acr610_detail_upload_window(file_id) {
if(file_id){ if (file_id) {
var url = $('attachment_uploadFile_id').getUrl() + '?table_name=ACR_INVOICE_APPLY&header_id=' + file_id; var url = $('attachment_uploadFile_id').getUrl() + '?table_name=ACR_INVOICE_APPLY&header_id=' + file_id;
var win = new Leaf.Window({ var win = new Leaf.Window({
url: url, url: url,
...@@ -84,7 +86,7 @@ ...@@ -84,7 +86,7 @@
width: 850, width: 850,
height: 400 height: 400
}); });
}else { } else {
Leaf.showMessage('${l:HLS.PROMPT}', '无法上传,请联系管理员!'); Leaf.showMessage('${l:HLS.PROMPT}', '无法上传,请联系管理员!');
} }
} }
...@@ -93,8 +95,8 @@ ...@@ -93,8 +95,8 @@
if (name == 'document_number') { if (name == 'document_number') {
return '<a href="javascript:acr610_detail_grid_readonly(' + record.id + ',' + record.get('invoice_hd_wfl_id') + ');">' + value + '</a>'; return '<a href="javascript:acr610_detail_grid_readonly(' + record.id + ',' + record.get('invoice_hd_wfl_id') + ');">' + value + '</a>';
} }
if(name == 'attachment'){ if (name == 'attachment') {
if(record.get('paid_byother_flag') == 'T'){ if (record.get('paid_byother_flag') == 'T') {
return '<a href="javascript:acr610_detail_upload_window(' + record.get('file_id') + ')">附件</a>'; return '<a href="javascript:acr610_detail_upload_window(' + record.get('file_id') + ')">附件</a>';
} }
} }
...@@ -105,11 +107,36 @@ ...@@ -105,11 +107,36 @@
return Leaf.formatNumber(value); return Leaf.formatNumber(value);
} }
function sumFunction_foot(data, name) {
if (name == 'journal_month') {
return '<font color=red>' + '合计' + '</font>';
} else if (name == 'total_amount' || name == 'net_amount' || name == 'tax_amount' || name == 'write_off_due_amount') {
return colum_caculateTotal(data, name);
}
}
function colum_caculateTotal(data, name) {
var total = 0;
var length = data.length;
var value = 0;
for (var i = 0; i < length; i++) {
if (Ext.isEmpty(data[i].get(name))) {
value = 0;
} else {
value = data[i].get(name);
}
total = plus(total, value);
}
return '<font color=red>' + Leaf.formatMoney(total) + '</font>';
}
]]></script> ]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/> <a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
<a:dataSets> <a:dataSets>
<a:dataSet id="acr610_ipaid_byother_flag_ds" lookupCode="PAID_BYOTHER_FLAG"/> <a:dataSet id="acr610_ipaid_byother_flag_ds" lookupCode="PAID_BYOTHER_FLAG"/>
<a:dataSet id="acr610_invoice_apply_basic_ds" autoQuery="true" fetchAll="true" model="acr.ACR610.acr_invoice_apply_query" queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_query/query?invoice_apply_id=${/parameter/@invoice_apply_id}"> <a:dataSet id="acr610_invoice_apply_basic_ds" autoQuery="true" fetchAll="true"
model="acr.ACR610.acr_invoice_apply_query"
queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_query/query?invoice_apply_id=${/parameter/@invoice_apply_id}">
<a:fields> <a:fields>
<a:field name="invoice_apply_num"/> <a:field name="invoice_apply_num"/>
<a:field name="invoice_apply_user_n"/> <a:field name="invoice_apply_user_n"/>
...@@ -121,12 +148,15 @@ ...@@ -121,12 +148,15 @@
<a:field name="contract_number"/> <a:field name="contract_number"/>
<a:field name="bp_code"/> <a:field name="bp_code"/>
<a:field name="journal_month"/> <a:field name="journal_month"/>
<a:field name="paid_byother_flag_n" displayField="code_value_name" options="acr610_ipaid_byother_flag_ds" <a:field name="paid_byother_flag_n" displayField="code_value_name"
options="acr610_ipaid_byother_flag_ds"
returnField="paid_byother_flag" valueField="code_value"/> returnField="paid_byother_flag" valueField="code_value"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr610_invoice_detail_result_ds" autoPageSize="true" autoQuery="true" fetchAll="true" <a:dataSet id="acr610_invoice_detail_result_ds" autoQuery="true" fetchAll="true"
model="acr.ACR610.acr_invoice_apply_detail" queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_detail/query?invoice_apply_id=${/parameter/@invoice_apply_id}" queryDataSet="acr610_invoice_detail_query_ds" model="acr.ACR610.acr_invoice_apply_detail"
queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_detail/query?invoice_apply_id=${/parameter/@invoice_apply_id}"
queryDataSet="acr610_invoice_detail_query_ds"
selectable="false"/> selectable="false"/>
</a:dataSets> </a:dataSets>
<a:screenBody> <a:screenBody>
...@@ -139,39 +169,53 @@ ...@@ -139,39 +169,53 @@
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form marginWidth="200" padding="0" title="查询条件"> <a:form marginWidth="200" padding="0" title="查询条件">
<a:hBox labelSeparator=" "> <a:hBox labelSeparator=" ">
<a:textField name="contract_number" bindTarget="acr610_invoice_detail_query_ds" prompt="合同编号" width="135"/> <a:textField name="contract_number" bindTarget="acr610_invoice_detail_query_ds" prompt="合同编号"
width="135"/>
<a:textField name="bp_code" bindTarget="acr610_invoice_detail_query_ds" prompt="客户编号" width="135"/> <a:textField name="bp_code" bindTarget="acr610_invoice_detail_query_ds" prompt="客户编号" width="135"/>
<a:textField name="journal_month" bindTarget="acr610_invoice_detail_query_ds" prompt="税款所属期" width="135" emptyText="YYYY-MM"/> <a:textField name="journal_month" bindTarget="acr610_invoice_detail_query_ds" prompt="税款所属期"
<a:comboBox name="paid_byother_flag_n" bindTarget="acr610_invoice_detail_query_ds" prompt="担保支付" width="135"/> width="135" emptyText="YYYY-MM"/>
<a:comboBox name="paid_byother_flag_n" bindTarget="acr610_invoice_detail_query_ds" prompt="担保支付"
width="135"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:form marginWidth="200" padding="0" title="基本信息"> <a:form marginWidth="200" padding="0" title="基本信息">
<a:hBox labelSeparator=" "> <a:hBox labelSeparator=" ">
<a:textField name="invoice_apply_num" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请编号" width="135" readOnly="true"/> <a:textField name="invoice_apply_num" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请编号"
<a:textField name="invoice_apply_user_n" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请人" width="135" readOnly="true"/> width="135" readOnly="true"/>
<a:textField name="invoice_apply_date" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请时间" width="135" readOnly="true"/> <a:textField name="invoice_apply_user_n" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请人"
width="135" readOnly="true"/>
<a:textField name="invoice_apply_date" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请时间"
width="135" readOnly="true"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr610_invoice_detail_grid_ds" bindTarget="acr610_invoice_detail_result_ds" marginHeight="250" <a:grid id="acr610_invoice_detail_grid_ds" bindTarget="acr610_invoice_detail_result_ds" marginHeight="250"
marginWidth="30" navBar="true"> marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr610_detail_renderer" width="120"/> <a:column name="document_number" lock="true" prompt="单据编号" align="center"
renderer="acr610_detail_renderer" width="120"/>
<a:column name="contract_number" prompt="合同编号" align="center" width="100"/> <a:column name="contract_number" prompt="合同编号" align="center" width="100"/>
<a:column name="bp_code" prompt="客户编号" align="center" width="100"/> <a:column name="bp_code" prompt="客户编号" align="center" width="100"/>
<a:column name="bp_name" prompt="客户名称" align="center" width="100"/> <a:column name="bp_name" prompt="客户名称" align="center" width="100"/>
<a:column name="times" prompt="租期" align="center" width="60"/> <a:column name="times" prompt="租期" align="center" width="60"/>
<a:column name="journal_month" prompt="税款所属期" align="center" width="120"/> <a:column name="journal_month" prompt="税款所属期" align="center" width="120"
footerRenderer="sumFunction_foot"/>
<a:column name="tax_type_rate" prompt="税率" align="right" width="60"/> <a:column name="tax_type_rate" prompt="税率" align="right" width="60"/>
<a:column name="total_amount" prompt="开票金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> <a:column name="total_amount" prompt="开票金额" footerRenderer="sumFunction_foot"
<a:column name="net_amount" prompt="不含税金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="tax_amount" prompt="税额" renderer="acr610_detail_formatMoney" align="right" width="100"/> <a:column name="net_amount" prompt="不含税金额" footerRenderer="sumFunction_foot"
renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="tax_amount" prompt="税额" footerRenderer="sumFunction_foot"
renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="paid_byother_flag_n" prompt="担保支付" align="center" width="100"/> <a:column name="paid_byother_flag_n" prompt="担保支付" align="center" width="100"/>
<a:column name="bp_bank_account_name" prompt="付款人" align="center" width="100"/> <a:column name="bp_bank_account_name" prompt="付款人" align="center" width="100"/>
<a:column name="transaction_amount" prompt="付款金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> <a:column name="transaction_amount" prompt="付款金额" renderer="acr610_detail_formatMoney" align="right"
<a:column name="write_off_due_amount" prompt="核销金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> width="100"/>
<a:column name="write_off_due_amount" prompt="核销金额" footerRenderer="sumFunction_foot"
renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="transaction_num" prompt="收款业务编号" align="center" width="100"/> <a:column name="transaction_num" prompt="收款业务编号" align="center" width="100"/>
<a:column name="journal_num" prompt="增值税凭证号" align="center" width="100"/> <a:column name="journal_num" prompt="增值税凭证号" align="center" width="100"/>
<a:column name="attachment" prompt="担保代付协议" align="center" width="100" renderer="acr610_detail_renderer"/> <a:column name="attachment" prompt="担保代付协议" align="center" width="100"
renderer="acr610_detail_renderer"/>
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:screenBody> </a:screenBody>
......
...@@ -7,8 +7,10 @@ ...@@ -7,8 +7,10 @@
--> -->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true"> <a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true">
<a:view> <a:view>
<a:link id="acr_invoice_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code" modelaction="update"/> <a:link id="acr_invoice_get_layout_code_link_id" model="cont.CON500.con_contract_get_layout_code"
<a:link id="acr610_invoice_detail_link" url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_detail_readonly.lview"/> modelaction="update"/>
<a:link id="acr610_invoice_detail_link"
url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_detail_readonly.lview"/>
<a:link id="acr610_detail_submit_link" model="acr.ACR610.acr_invoice_apply_detail" modelaction="update"/> <a:link id="acr610_detail_submit_link" model="acr.ACR610.acr_invoice_apply_detail" modelaction="update"/>
<a:link id="attachment_uploadFile_id" url="${/request/@context_path}/uploadFile.lview"/> <a:link id="attachment_uploadFile_id" url="${/request/@context_path}/uploadFile.lview"/>
<a:link id="attachment_downloadFile_id" url="${/request/@context_path}/downloadFile.lview"/> <a:link id="attachment_downloadFile_id" url="${/request/@context_path}/downloadFile.lview"/>
...@@ -75,7 +77,7 @@ ...@@ -75,7 +77,7 @@
} }
function acr610_detail_upload_window(file_id) { function acr610_detail_upload_window(file_id) {
if(file_id){ if (file_id) {
var url = $('attachment_downloadFile_id').getUrl() + '?table_name=ACR_INVOICE_APPLY&header_id=' + file_id; var url = $('attachment_downloadFile_id').getUrl() + '?table_name=ACR_INVOICE_APPLY&header_id=' + file_id;
var win = new Leaf.Window({ var win = new Leaf.Window({
url: url, url: url,
...@@ -84,7 +86,7 @@ ...@@ -84,7 +86,7 @@
width: 850, width: 850,
height: 400 height: 400
}); });
}else { } else {
Leaf.showMessage('${l:HLS.PROMPT}', '无法上传,请联系管理员!'); Leaf.showMessage('${l:HLS.PROMPT}', '无法上传,请联系管理员!');
} }
} }
...@@ -93,8 +95,8 @@ ...@@ -93,8 +95,8 @@
if (name == 'document_number') { if (name == 'document_number') {
return '<a href="javascript:acr610_detail_grid_readonly(' + record.id + ',' + record.get('invoice_hd_wfl_id') + ');">' + value + '</a>'; return '<a href="javascript:acr610_detail_grid_readonly(' + record.id + ',' + record.get('invoice_hd_wfl_id') + ');">' + value + '</a>';
} }
if(name == 'attachment'){ if (name == 'attachment') {
if(record.get('paid_byother_flag') == 'T'){ if (record.get('paid_byother_flag') == 'T') {
return '<a href="javascript:acr610_detail_upload_window(' + record.get('file_id') + ')">附件</a>'; return '<a href="javascript:acr610_detail_upload_window(' + record.get('file_id') + ')">附件</a>';
} }
} }
...@@ -105,10 +107,35 @@ ...@@ -105,10 +107,35 @@
return Leaf.formatNumber(value); return Leaf.formatNumber(value);
} }
function sumFunction_foot(data, name) {
if (name == 'journal_month') {
return '<font color=red>' + '合计' + '</font>';
} else if (name == 'total_amount' || name == 'net_amount' || name == 'tax_amount' || name == 'write_off_due_amount') {
return colum_caculateTotal(data, name);
}
}
function colum_caculateTotal(data, name) {
var total = 0;
var length = data.length;
var value = 0;
for (var i = 0; i < length; i++) {
if (Ext.isEmpty(data[i].get(name))) {
value = 0;
} else {
value = data[i].get(name);
}
total = plus(total, value);
}
return '<font color=red>' + Leaf.formatMoney(total) + '</font>';
}
]]></script> ]]></script>
<a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/> <a:screen-include screen="modules/cont/CON500/con_contract_get_layout_code.lview"/>
<a:dataSets> <a:dataSets>
<a:dataSet id="acr610_invoice_apply_basic_ds" model="acr.ACR610.acr_invoice_apply_query" queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_query/query?invoice_apply_id=${/parameter/@invoice_apply_id}" autoQuery="true"> <a:dataSet id="acr610_invoice_apply_basic_ds" model="acr.ACR610.acr_invoice_apply_query"
queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_query/query?invoice_apply_id=${/parameter/@invoice_apply_id}"
autoQuery="true">
<a:fields> <a:fields>
<a:field name="invoice_apply_num"/> <a:field name="invoice_apply_num"/>
<a:field name="invoice_apply_user_n"/> <a:field name="invoice_apply_user_n"/>
...@@ -121,12 +148,15 @@ ...@@ -121,12 +148,15 @@
<a:field name="contract_number"/> <a:field name="contract_number"/>
<a:field name="bp_code"/> <a:field name="bp_code"/>
<a:field name="journal_month"/> <a:field name="journal_month"/>
<a:field name="paid_byother_flag_n" displayField="code_value_name" options="acr610_ipaid_byother_flag_ds" <a:field name="paid_byother_flag_n" displayField="code_value_name"
options="acr610_ipaid_byother_flag_ds"
returnField="paid_byother_flag" valueField="code_value"/> returnField="paid_byother_flag" valueField="code_value"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr610_invoice_detail_result_ds" autoPageSize="true" autoQuery="true" fetchAll="true" <a:dataSet id="acr610_invoice_detail_result_ds" autoQuery="true" fetchAll="true"
model="acr.ACR610.acr_invoice_apply_detail" queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_detail/query?invoice_apply_id=${/parameter/@invoice_apply_id}" queryDataSet="acr610_invoice_detail_query_ds" model="acr.ACR610.acr_invoice_apply_detail"
queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_detail/query?invoice_apply_id=${/parameter/@invoice_apply_id}"
queryDataSet="acr610_invoice_detail_query_ds"
selectable="false"/> selectable="false"/>
</a:dataSets> </a:dataSets>
<a:screenBody> <a:screenBody>
...@@ -149,39 +179,53 @@ ...@@ -149,39 +179,53 @@
</a:switch> </a:switch>
<a:form marginWidth="200" padding="0" title="查询条件"> <a:form marginWidth="200" padding="0" title="查询条件">
<a:hBox labelSeparator=" "> <a:hBox labelSeparator=" ">
<a:textField name="contract_number" bindTarget="acr610_invoice_detail_query_ds" prompt="合同编号" width="135"/> <a:textField name="contract_number" bindTarget="acr610_invoice_detail_query_ds" prompt="合同编号"
width="135"/>
<a:textField name="bp_code" bindTarget="acr610_invoice_detail_query_ds" prompt="客户编号" width="135"/> <a:textField name="bp_code" bindTarget="acr610_invoice_detail_query_ds" prompt="客户编号" width="135"/>
<a:textField name="journal_month" bindTarget="acr610_invoice_detail_query_ds" prompt="税款所属期" width="135" emptyText="YYYY-MM"/> <a:textField name="journal_month" bindTarget="acr610_invoice_detail_query_ds" prompt="税款所属期"
<a:comboBox name="paid_byother_flag_n" bindTarget="acr610_invoice_detail_query_ds" prompt="担保支付" width="135"/> width="135" emptyText="YYYY-MM"/>
<a:comboBox name="paid_byother_flag_n" bindTarget="acr610_invoice_detail_query_ds" prompt="担保支付"
width="135"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:form marginWidth="200" padding="0" title="基本信息"> <a:form marginWidth="200" padding="0" title="基本信息">
<a:hBox labelSeparator=" "> <a:hBox labelSeparator=" ">
<a:textField name="invoice_apply_num" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请编号" width="135" readOnly="true"/> <a:textField name="invoice_apply_num" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请编号"
<a:textField name="invoice_apply_user_n" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请人" width="135" readOnly="true"/> width="135" readOnly="true"/>
<a:textField name="invoice_apply_date" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请时间" width="135" readOnly="true"/> <a:textField name="invoice_apply_user_n" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请人"
width="135" readOnly="true"/>
<a:textField name="invoice_apply_date" bindTarget="acr610_invoice_apply_basic_ds" prompt="申请时间"
width="135" readOnly="true"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr610_invoice_detail_grid_ds" bindTarget="acr610_invoice_detail_result_ds" marginHeight="250" <a:grid id="acr610_invoice_detail_grid_ds" bindTarget="acr610_invoice_detail_result_ds" marginHeight="250"
marginWidth="30" navBar="true"> marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr610_detail_renderer" width="120"/> <a:column name="document_number" lock="true" prompt="单据编号" align="center"
renderer="acr610_detail_renderer" width="120"/>
<a:column name="contract_number" prompt="合同编号" align="center" width="100"/> <a:column name="contract_number" prompt="合同编号" align="center" width="100"/>
<a:column name="bp_code" prompt="客户编号" align="center" width="100"/> <a:column name="bp_code" prompt="客户编号" align="center" width="100"/>
<a:column name="bp_name" prompt="客户名称" align="center" width="100"/> <a:column name="bp_name" prompt="客户名称" align="center" width="100"/>
<a:column name="times" prompt="租期" align="center" width="60"/> <a:column name="times" prompt="租期" align="center" width="60"/>
<a:column name="journal_month" prompt="税款所属期" align="center" width="120"/> <a:column name="journal_month" prompt="税款所属期" align="center" width="120"
footerRenderer="sumFunction_foot"/>
<a:column name="tax_type_rate" prompt="税率" align="right" width="60"/> <a:column name="tax_type_rate" prompt="税率" align="right" width="60"/>
<a:column name="total_amount" prompt="开票金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> <a:column name="total_amount" prompt="开票金额" footerRenderer="sumFunction_foot"
<a:column name="net_amount" prompt="不含税金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="tax_amount" prompt="税额" renderer="acr610_detail_formatMoney" align="right" width="100"/> <a:column name="net_amount" prompt="不含税金额" footerRenderer="sumFunction_foot"
renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="tax_amount" prompt="税额" footerRenderer="sumFunction_foot"
renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="paid_byother_flag_n" prompt="担保支付" align="center" width="100"/> <a:column name="paid_byother_flag_n" prompt="担保支付" align="center" width="100"/>
<a:column name="bp_bank_account_name" prompt="付款人" align="center" width="100"/> <a:column name="bp_bank_account_name" prompt="付款人" align="center" width="100"/>
<a:column name="transaction_amount" prompt="付款金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> <a:column name="transaction_amount" prompt="付款金额" renderer="acr610_detail_formatMoney" align="right"
<a:column name="write_off_due_amount" prompt="核销金额" renderer="acr610_detail_formatMoney" align="right" width="100"/> width="100"/>
<a:column name="write_off_due_amount" prompt="核销金额" footerRenderer="sumFunction_foot"
renderer="acr610_detail_formatMoney" align="right" width="100"/>
<a:column name="transaction_num" prompt="收款业务编号" align="center" width="100"/> <a:column name="transaction_num" prompt="收款业务编号" align="center" width="100"/>
<a:column name="journal_num" prompt="增值税凭证号" align="center" width="100"/> <a:column name="journal_num" prompt="增值税凭证号" align="center" width="100"/>
<a:column name="attachment" prompt="担保代付协议" align="center" width="100" renderer="acr610_detail_renderer"/> <a:column name="attachment" prompt="担保代付协议" align="center" width="100"
renderer="acr610_detail_renderer"/>
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:screenBody> </a:screenBody>
......
...@@ -7,10 +7,14 @@ ...@@ -7,10 +7,14 @@
--> -->
<a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true"> <a:screen xmlns:a="http://www.leaf-framework.org/application" customizationEnabled="true">
<a:view> <a:view>
<a:link id="acr_invoice_apply_detail_link" url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_apply_detail.lview"/> <a:link id="acr_invoice_apply_detail_link"
<a:link id="acr_invoice_apply_detail_readonly_link" url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_apply_detail_wfl.lview"/> url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_apply_detail.lview"/>
<a:link id="acr610_invoice_apply_status_change" model="acr.ACR610.acr_invoice_apply_query" modelaction="delete"/> <a:link id="acr_invoice_apply_detail_readonly_link"
<a:link id="acr_invoice_finish_print_link_id" url="${/request/@context_path}/modules/csh/CSH501/csh_payment_req_history_pdf_print.lsc"/> url="${/request/@context_path}/modules/acr/ACR610/acr_invoice_apply_detail_wfl.lview"/>
<a:link id="acr610_invoice_apply_status_change" model="acr.ACR610.acr_invoice_apply_query"
modelaction="delete"/>
<a:link id="acr_invoice_finish_print_link_id"
url="${/request/@context_path}/modules/csh/CSH501/csh_payment_req_history_pdf_print.lsc"/>
<script><![CDATA[ <script><![CDATA[
function lock_current_window() { function lock_current_window() {
...@@ -39,7 +43,7 @@ ...@@ -39,7 +43,7 @@
title: '申请明细', title: '申请明细',
fullScreen: true fullScreen: true
}); });
win.on('close',function(){ win.on('close', function () {
$('acr610_invoice_result_ds').query(); $('acr610_invoice_result_ds').query();
}); });
} }
...@@ -47,7 +51,7 @@ ...@@ -47,7 +51,7 @@
function acr610_apply_num_render(value, record, name) { function acr610_apply_num_render(value, record, name) {
if (name == 'invoice_apply_num') { if (name == 'invoice_apply_num') {
if (record.get('wfl_apply_status') == 'NEW') { if (record.get('wfl_apply_status') == 'NEW') {
url = $('acr_invoice_apply_detail_link').getUrl() + '?invoice_apply_id=' + record.get('invoice_apply_id') + '&invoice_apply_num=' + record.get('invoice_apply_num') + '&invoice_apply_user_n=' + record.get('invoice_apply_user_n') + '&invoice_apply_date=' + record.get('invoice_apply_date') ; url = $('acr_invoice_apply_detail_link').getUrl() + '?invoice_apply_id=' + record.get('invoice_apply_id') + '&invoice_apply_num=' + record.get('invoice_apply_num') + '&invoice_apply_user_n=' + record.get('invoice_apply_user_n') + '&invoice_apply_date=' + record.get('invoice_apply_date');
} else { } else {
url = $('acr_invoice_apply_detail_readonly_link').getUrl() + '?invoice_apply_id=' + record.get('invoice_apply_id') + '&invoice_apply_num=' + record.get('invoice_apply_num') + '&invoice_apply_user_n=' + record.get('invoice_apply_user_n') + '&invoice_apply_date=' + record.get('invoice_apply_date') + '&button_flag=YES'; url = $('acr_invoice_apply_detail_readonly_link').getUrl() + '?invoice_apply_id=' + record.get('invoice_apply_id') + '&invoice_apply_num=' + record.get('invoice_apply_num') + '&invoice_apply_user_n=' + record.get('invoice_apply_user_n') + '&invoice_apply_date=' + record.get('invoice_apply_date') + '&button_flag=YES';
} }
...@@ -66,7 +70,7 @@ ...@@ -66,7 +70,7 @@
return; return;
} }
var record = records[0]; var record = records[0];
if(record.get('wfl_apply_status') != 'NEW'){ if (record.get('wfl_apply_status') != 'NEW') {
$L.showInfoMessage('提示', '仅新建状态的申请单据可以取消!'); $L.showInfoMessage('提示', '仅新建状态的申请单据可以取消!');
return; return;
} }
...@@ -96,20 +100,20 @@ ...@@ -96,20 +100,20 @@
} }
function acr610_invoice_result_select(ds, record, bp_seq) { function acr610_invoice_result_select(ds, record, bp_seq) {
if(record.get('wfl_apply_status') != 'NEW'){ if (record.get('wfl_apply_status') != 'NEW') {
document.getElementById("acr610_invoice_cancel_id").style.display = "none"; document.getElementById("acr610_invoice_cancel_id").style.display = "none";
}else{ } else {
document.getElementById("acr610_invoice_cancel_id").style.display = ""; document.getElementById("acr610_invoice_cancel_id").style.display = "";
} }
if(record.get('wfl_apply_status') == 'CANCEL'){ if (record.get('wfl_apply_status') == 'CANCEL') {
document.getElementById("acr610_invoice_print_id").style.display = "none"; document.getElementById("acr610_invoice_print_id").style.display = "none";
}else{ } else {
document.getElementById("acr610_invoice_print_id").style.display = ""; document.getElementById("acr610_invoice_print_id").style.display = "";
} }
} }
function acr610_invoice_print(){ function acr610_invoice_print() {
var record = $('acr610_invoice_result_ds').getSelected()[0]; var record = $('acr610_invoice_result_ds').getSelected()[0];
var document_id = record.get('invoice_apply_id'); var document_id = record.get('invoice_apply_id');
var url_l = $('acr_invoice_finish_print_link_id').getUrl() + '?document_id=' + document_id + '&document_table=ACR_INVOICE_APPLY&batch_flag=Y&source_type=COMMON'; var url_l = $('acr_invoice_finish_print_link_id').getUrl() + '?document_id=' + document_id + '&document_table=ACR_INVOICE_APPLY&batch_flag=Y&source_type=COMMON';
...@@ -132,12 +136,15 @@ ...@@ -132,12 +136,15 @@
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="invoice_apply_user"/> <a:field name="invoice_apply_user"/>
<a:field name="wfl_apply_status_n" displayField="code_value_name" options="acr610_invoice_apply_status_ds" <a:field name="wfl_apply_status_n" displayField="code_value_name"
options="acr610_invoice_apply_status_ds"
returnField="wfl_apply_status" valueField="code_value"/> returnField="wfl_apply_status" valueField="code_value"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="acr610_invoice_result_ds" autoPageSize="true" autoQuery="true" <a:dataSet id="acr610_invoice_result_ds" autoPageSize="true" autoQuery="true"
model="acr.ACR610.acr_invoice_apply_query" queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_query/query?apply_mode=APPLY" queryDataSet="acr610_invoice_apply_query_ds" model="acr.ACR610.acr_invoice_apply_query"
queryUrl="${/request/@context_path}/autocrud/acr.ACR610.acr_invoice_apply_query/query?apply_mode=APPLY"
queryDataSet="acr610_invoice_apply_query_ds"
selectable="true" selectionModel="single"> selectable="true" selectionModel="single">
<a:events> <a:events>
<a:event name="select" handler="acr610_invoice_result_select"/> <a:event name="select" handler="acr610_invoice_result_select"/>
...@@ -154,19 +161,27 @@ ...@@ -154,19 +161,27 @@
</a:screenTopToolbar> </a:screenTopToolbar>
<a:form marginWidth="200" padding="0" title="销项发票申请"> <a:form marginWidth="200" padding="0" title="销项发票申请">
<a:hBox labelSeparator=" "> <a:hBox labelSeparator=" ">
<a:textField name="invoice_apply_num" bindTarget="acr610_invoice_apply_query_ds" prompt="申请编号" width="135"/> <a:textField name="invoice_apply_num" bindTarget="acr610_invoice_apply_query_ds" prompt="申请编号"
<a:datePicker name="invoice_apply_date" bindTarget="acr610_invoice_apply_query_ds" prompt="申请时间" width="135"/> width="135"/>
<a:lov name="invoice_apply_user_n" bindTarget="acr610_invoice_apply_query_ds" prompt="申请人" width="135"/> <a:datePicker name="invoice_apply_date" bindTarget="acr610_invoice_apply_query_ds" prompt="申请时间"
<a:comboBox name="wfl_apply_status_n" bindTarget="acr610_invoice_apply_query_ds" prompt="申请状态" width="135"/> width="135"/>
<a:lov name="invoice_apply_user_n" bindTarget="acr610_invoice_apply_query_ds" prompt="申请人"
width="135"/>
<a:comboBox name="wfl_apply_status_n" bindTarget="acr610_invoice_apply_query_ds" prompt="申请状态"
width="135"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr610_invoice_update_grid_ds" bindTarget="acr610_invoice_result_ds" marginHeight="250" marginWidth="30" navBar="true"> <a:grid id="acr610_invoice_update_grid_ds" bindTarget="acr610_invoice_result_ds" marginHeight="135"
marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="invoice_apply_num" lock="true" prompt="申请编号" renderer="acr610_apply_num_render" align="center" width="150"/> <a:column name="invoice_apply_num" lock="true" prompt="申请编号" renderer="acr610_apply_num_render"
align="center" width="150"/>
<a:column name="invoice_apply_date" prompt="申请日期" align="center" width="100"/> <a:column name="invoice_apply_date" prompt="申请日期" align="center" width="100"/>
<a:column name="invoice_apply_user_n" prompt="申请人" align="center" width="100"/> <a:column name="invoice_apply_user_n" prompt="申请人" align="center" width="100"/>
<a:column name="total_amount" prompt="开票总金额" align="right" renderer="acr610_formatMoney" width="100"/> <a:column name="total_amount" prompt="开票总金额" align="right" renderer="acr610_formatMoney"
<a:column name="net_amount" prompt="不含税总金额" align="right" renderer="acr610_formatMoney" width="100"/> width="100"/>
<a:column name="net_amount" prompt="不含税总金额" align="right" renderer="acr610_formatMoney"
width="100"/>
<a:column name="tax_amount" prompt="税额总金额" align="right" renderer="acr610_formatMoney" width="150"/> <a:column name="tax_amount" prompt="税额总金额" align="right" renderer="acr610_formatMoney" width="150"/>
<a:column name="wfl_apply_status_n" prompt="申请状态" align="center" width="150"/> <a:column name="wfl_apply_status_n" prompt="申请状态" align="center" width="150"/>
</a:columns> </a:columns>
......
...@@ -114,7 +114,10 @@ ...@@ -114,7 +114,10 @@
} }
function acr620_invoice_reverse_load(ds, record, index) { function acr620_invoice_reverse_load(ds, record, index) {
if(ds.data[0].data.vat_interface_status && ds.data[0].data.vat_interface_status == 'UNTRANSFERED'){ debugger;
//reverse_method: "REVERSE"
//if(ds.data[0].data.vat_interface_status && ds.data[0].data.vat_interface_status == 'UNTRANSFERED'){
if(ds.data[0].data.reverse_method && ds.data[0].data.reverse_method == 'REVERSE'){
ds.data[0].getField('reverse_method_n').setReadOnly(true); ds.data[0].getField('reverse_method_n').setReadOnly(true);
} }
} }
...@@ -159,7 +162,7 @@ ...@@ -159,7 +162,7 @@
<a:comboBox name="reverse_method_n" bindTarget="acr620_invoice_reverse_apply_basic_ds" prompt="反冲方式" width="135"/> <a:comboBox name="reverse_method_n" bindTarget="acr620_invoice_reverse_apply_basic_ds" prompt="反冲方式" width="135"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr620_invoice_reverse_detail_grid_ds" bindTarget="acr620_invoice_reverse_detail_result_ds" marginHeight="250" <a:grid id="acr620_invoice_reverse_detail_grid_ds" bindTarget="acr620_invoice_reverse_detail_result_ds" marginHeight="135"
marginWidth="30" navBar="true"> marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr620_detail_renderer" width="120"/> <a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr620_detail_renderer" width="120"/>
...@@ -174,6 +177,8 @@ ...@@ -174,6 +177,8 @@
<a:column name="invoice_status_n" prompt="发票状态" align="center" width="100"/> <a:column name="invoice_status_n" prompt="发票状态" align="center" width="100"/>
<a:column name="vat_interface_status_n" prompt="金税状态" align="center" width="100"/> <a:column name="vat_interface_status_n" prompt="金税状态" align="center" width="100"/>
<a:column name="accounting_date" prompt="记账日期" renderer="Leaf.formatDate" align="center" width="100"/> <a:column name="accounting_date" prompt="记账日期" renderer="Leaf.formatDate" align="center" width="100"/>
<a:column name="claim_status_n" prompt="认领状态" width="85" align="center"/>
<a:column name="reversed_flag_n" prompt="反冲标志" align="center" width="80"/>
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:screenBody> </a:screenBody>
......
...@@ -136,7 +136,7 @@ ...@@ -136,7 +136,7 @@
</a:form> </a:form>
<a:switch test="/parameter/@button_flag"> <a:switch test="/parameter/@button_flag">
<a:case value="YES"> <a:case value="YES">
<a:grid id="acr620_invoice_reverse_detail_grid_ds" bindTarget="acr620_invoice_reverse_detail_result_ds" marginHeight="250" <a:grid id="acr620_invoice_reverse_detail_grid_ds" bindTarget="acr620_invoice_reverse_detail_result_ds" marginHeight="135"
marginWidth="30" navBar="true"> marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr620_detail_renderer" width="120"/> <a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr620_detail_renderer" width="120"/>
...@@ -159,7 +159,7 @@ ...@@ -159,7 +159,7 @@
</a:grid> </a:grid>
</a:case> </a:case>
<a:case value="*"> <a:case value="*">
<a:grid id="acr620_invoice_reverse_detail_grid_ds" bindTarget="acr620_invoice_reverse_detail_result_ds" marginHeight="250" <a:grid id="acr620_invoice_reverse_detail_grid_ds" bindTarget="acr620_invoice_reverse_detail_result_ds" marginHeight="200"
marginWidth="30" navBar="true"> marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr620_detail_renderer" width="120"/> <a:column name="document_number" lock="true" prompt="单据编号" align="center" renderer="acr620_detail_renderer" width="120"/>
...@@ -174,6 +174,8 @@ ...@@ -174,6 +174,8 @@
<a:column name="invoice_status_n" prompt="发票状态" align="center" width="100"/> <a:column name="invoice_status_n" prompt="发票状态" align="center" width="100"/>
<a:column name="vat_interface_status_n" prompt="金税状态" align="center" width="100"/> <a:column name="vat_interface_status_n" prompt="金税状态" align="center" width="100"/>
<a:column name="accounting_date" prompt="记账日期" renderer="Leaf.formatDate" align="center" width="100"/> <a:column name="accounting_date" prompt="记账日期" renderer="Leaf.formatDate" align="center" width="100"/>
<a:column name="claim_status_n" prompt="认领状态" width="85" align="center"/>
<a:column name="reversed_flag_n" prompt="反冲标志" align="center" width="80"/>
</a:columns> </a:columns>
</a:grid> </a:grid>
</a:case> </a:case>
......
...@@ -152,7 +152,7 @@ ...@@ -152,7 +152,7 @@
<a:comboBox name="vat_interface_status_n" bindTarget="acr620_invoice_reverse_apply_query_ds" prompt="金税状态" width="135"/> <a:comboBox name="vat_interface_status_n" bindTarget="acr620_invoice_reverse_apply_query_ds" prompt="金税状态" width="135"/>
</a:hBox> </a:hBox>
</a:form> </a:form>
<a:grid id="acr620_invoice_reverse_update_grid_ds" bindTarget="acr620_invoice_reverse_result_ds" marginHeight="250" marginWidth="30" navBar="true"> <a:grid id="acr620_invoice_reverse_update_grid_ds" bindTarget="acr620_invoice_reverse_result_ds" marginHeight="200" marginWidth="30" navBar="true">
<a:columns> <a:columns>
<a:column name="invoice_apply_num" lock="true" prompt="申请编号" renderer="acr620_apply_num_render" align="center" width="150"/> <a:column name="invoice_apply_num" lock="true" prompt="申请编号" renderer="acr620_apply_num_render" align="center" width="150"/>
<a:column name="invoice_apply_date" prompt="申请日期" align="center" width="100"/> <a:column name="invoice_apply_date" prompt="申请日期" align="center" width="100"/>
......
...@@ -179,8 +179,8 @@ ...@@ -179,8 +179,8 @@
}, },
url: url, url: url,
title: '承租人最大逾期天数', title: '承租人最大逾期天数',
width: 600, width: 900,
height: 400 height: 600
}).on('close', function () { }).on('close', function () {
null; null;
}); });
......
...@@ -308,13 +308,14 @@ ...@@ -308,13 +308,14 @@
debugger; debugger;
// var req_ds_id = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'F_BASE_01', 'con_contract'); // var req_ds_id = get_dsid_by_tabcode_basetable(window['${/parameter/@layout_code}_layoutDataSetList'], 'F_BASE_01', 'con_contract');
var req_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'],'con_contract'); var req_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'],'con_contract');
var req_reason_ds_id = get_dsid_by_basetable(window['${/parameter/@layout_code}_layoutDataSetList'],'con_contract_change_req');
var req_record = $(req_ds_id).getCurrentRecord(); var req_record = $(req_ds_id).getCurrentRecord();
var case_type = ''; var case_type = '';
var document_type = '${/parameter/@document_type}'; var document_type = '${/parameter/@document_type}';
var calc_session_id = req_record.get('calc_session_id'); var calc_session_id = req_record.get('calc_session_id');
//计算标志 //计算标志
var offset_flag=req_record.get('offset_flag'); var offset_flag=req_record.get('offset_flag');
if (req_record.dirty == true) { if (req_record.dirty == true|| $(req_reason_ds_id).getCurrentRecord().dirty == true) {
Leaf.showMessage('${l:PROMPT}', '${l:HLS.EXECUTE_AFTER_SAVE}'); Leaf.showMessage('${l:PROMPT}', '${l:HLS.EXECUTE_AFTER_SAVE}');
window['${/parameter/@bp_seq}${/parameter/@layout_code}_unlock_layout_dynamic_window'](); window['${/parameter/@bp_seq}${/parameter/@layout_code}_unlock_layout_dynamic_window']();
return false; return false;
......
...@@ -103,26 +103,26 @@ ...@@ -103,26 +103,26 @@
} }
function doQuery() { // function doQuery() {
$('close_open_ds').setQueryParameter('period_set_code', '${/model/fieldset/record/@period_set_code}'); // $('close_open_ds').setQueryParameter('period_set_code', '${/model/fieldset/record/@period_set_code}');
$('close_open_ds').query(); // $('close_open_ds').query();
//
} // }
function find_index() { function find_index() {
var close_open_ds = $('close_open_ds'); // var close_open_ds = $('close_open_ds');
var ds_length = close_open_ds.getAll().length; // var ds_length = close_open_ds.getAll().length;
var internal_period_num_max = close_open_ds.getCurrentRecord(0).get('internal_period_num_max'); // var internal_period_num_max = close_open_ds.getCurrentRecord(0).get('internal_period_num_max');
var record = close_open_ds.find('internal_period_num', internal_period_num_max); // var record = close_open_ds.find('internal_period_num', internal_period_num_max);
var index = close_open_ds.indexOf(record); // var index = close_open_ds.indexOf(record);
index = index + 3; // index = index + 3;
// 如果查询的数据是倒数第一条至倒数第三条,则直接定位到倒数第一条 // 如果查询的数据是倒数第一条至倒数第三条,则直接定位到倒数第一条
if (index > ds_length) { // if (index > ds_length) {
close_open_ds.locate(ds_length); // close_open_ds.locate(ds_length);
} else { // } else {
close_open_ds.locate(index); // close_open_ds.locate(index);
} // }
} }
function monthly_closed_flag_save(){ function monthly_closed_flag_save(){
...@@ -147,7 +147,7 @@ ...@@ -147,7 +147,7 @@
<a:field name="company_short_name" prompt="FND_COMPANIES.COMPANY_SHORT_NAME" readOnly="true"/> <a:field name="company_short_name" prompt="FND_COMPANIES.COMPANY_SHORT_NAME" readOnly="true"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="close_open_ds" autoQuery="true" fetchAll="true" model="gld.FND5800.gld_period_status_u_query" queryDataSet="status_fieldset_ds" queryUrl="${/request/@context_path}/autocrud/gld.FND5800.gld_period_status_u_query/query?period_set_code=${/model/fieldset/record/@period_set_code}"> <a:dataSet selectable="true" selectionModel="single" id="close_open_ds" autoQuery="true" fetchAll="true" model="gld.FND5800.gld_period_status_u_query" queryDataSet="status_fieldset_ds" queryUrl="${/request/@context_path}/autocrud/gld.FND5800.gld_period_status_u_query/query?period_set_code=${/model/fieldset/record/@period_set_code}">
<a:fields> <a:fields>
<a:field name="monthly_closed_flag_desc" displayField="code_value_name" options="monthly_closed_flag_ds" returnField="monthly_closed_flag" valueField="code_value"/> <a:field name="monthly_closed_flag_desc" displayField="code_value_name" options="monthly_closed_flag_ds" returnField="monthly_closed_flag" valueField="code_value"/>
</a:fields> </a:fields>
...@@ -166,7 +166,7 @@ ...@@ -166,7 +166,7 @@
<a:textField name="period_set_name" bindTarget="status_fieldset_ds"/> <a:textField name="period_set_name" bindTarget="status_fieldset_ds"/>
<a:textField name="company_short_name" bindTarget="status_fieldset_ds"/> <a:textField name="company_short_name" bindTarget="status_fieldset_ds"/>
</a:fieldSet> </a:fieldSet>
<a:grid id="close_open_grid" bindTarget="close_open_ds" marginHeight="165" marginWidth="30"> <a:grid id="close_open_grid" bindTarget="close_open_ds" marginHeight="165" marginWidth="30" >
<a:columns> <a:columns>
<a:column name="period_year" align="center" prompt="GLD_PERIODS.PERIOD_YEAR" sortable="true" width="100"/> <a:column name="period_year" align="center" prompt="GLD_PERIODS.PERIOD_YEAR" sortable="true" width="100"/>
<a:column name="period_num" align="center" prompt="FND_DIMENSIONS.DIMENSION_SEQUENCE" sortable="true" width="80"/> <a:column name="period_num" align="center" prompt="FND_DIMENSIONS.DIMENSION_SEQUENCE" sortable="true" width="80"/>
......
...@@ -174,7 +174,7 @@ changeFivteenToEighteen = function(card) { ...@@ -174,7 +174,7 @@ changeFivteenToEighteen = function(card) {
function checkMobile(str) { function checkMobile(str) {
// var re = /^1\d{10}$/; // var re = /^1\d{10}$/;
//var re=/^(0[0-9]{2,3}\-)?([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$|(^(13[0-9]|15[0|3|6|7|8|9]|18[8|9])\d{8}$)/; //var re=/^(0[0-9]{2,3}\-)?([2-9][0-9]{6,7})+(\-[0-9]{1,4})?$|(^(13[0-9]|15[0|3|6|7|8|9]|18[8|9])\d{8}$)/;
var re=/^((0\d{2,3}-\d{7,8})|(1[358476]\d{9}))$/; var re=/^((0\d{2,3}-\d{7,8})|(1[3584769]\d{9}))$/;
if (re.test(str)) { if (re.test(str)) {
return true; return true;
} else { } else {
......
...@@ -87,6 +87,8 @@ ...@@ -87,6 +87,8 @@
</a:mapping> </a:mapping>
</a:field> </a:field>
<a:field name="sub_category_desc" displayField="code_value_name" options="sub_category_ds" returnField="sub_category" valueField="code_value"/> <a:field name="sub_category_desc" displayField="code_value_name" options="sub_category_ds" returnField="sub_category" valueField="code_value"/>
<a:field name="enabled_flag_desc" defaultValue="是" displayField="code_value_name" options="yes_no_ds" returnField="enabled_flag" valueField="code_value"/>
<a:field name="enabled_flag" defaultValue="Y"/>
</a:fields> </a:fields>
</a:dataSet> </a:dataSet>
<a:dataSet id="workflowDs" autoPageSize="true" autoQuery="true" model="zjwfl.zj_wfl_workflow" queryDataSet="para_workflowDs" selectable="true"> <a:dataSet id="workflowDs" autoPageSize="true" autoQuery="true" model="zjwfl.zj_wfl_workflow" queryDataSet="para_workflowDs" selectable="true">
...@@ -118,11 +120,12 @@ ...@@ -118,11 +120,12 @@
</a:dataSet> </a:dataSet>
</a:dataSets> </a:dataSets>
<a:screenBody> <a:screenBody>
<a:form column="4" labelWidth="80" marginWidth="30" title="查询条件"> <a:form column="5" labelWidth="80" marginWidth="30" title="查询条件">
<a:lov name="workflow_type_code" bindTarget="para_workflowDs" prompt="工作流类型"/> <a:lov name="workflow_type_code" bindTarget="para_workflowDs" prompt="工作流类型"/>
<a:textField name="workflow_code" bindTarget="para_workflowDs" maxLength="200" prompt="工作流代码" typeCase="upper"/> <a:textField name="workflow_code" bindTarget="para_workflowDs" maxLength="200" prompt="工作流代码" typeCase="upper"/>
<a:textField name="workflow_desc" bindTarget="para_workflowDs" maxLength="2000" prompt="工作流描述"/> <a:textField name="workflow_desc" bindTarget="para_workflowDs" maxLength="2000" prompt="工作流描述"/>
<a:comboBox name="sub_category_desc" bindTarget="para_workflowDs" prompt="主从属性"/> <a:comboBox name="sub_category_desc" bindTarget="para_workflowDs" prompt="主从属性"/>
<a:comboBox name="enabled_flag_desc" bindTarget="para_workflowDs" prompt="是否启用"/>
</a:form> </a:form>
<a:hBox> <a:hBox>
<a:button click="workflowDs_query" text="HAP_QUERY"/> <a:button click="workflowDs_query" text="HAP_QUERY"/>
......
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