Files
ofbiz-framework/applications/accounting/widget/InvoiceScreens.xml
T
Jacques Le Roux b9c3ddef08 2d part and end of an effort to remove trailing spaces
[ \t]+$ => "" (empty)
Should be easier to review when committing changes with trailing spaces removed automatically by anyedit or such tool (please refer to http://docs.ofbiz.org/x/mg)

Of course this effort to remove trailing spaces has no functional implications.

Actually, I was doing a 1st commit and as it's long to upload, I got conflicts with r763135
In the meantime I did some refactoring also in *.java and *.groovy files :
){ => ) {
if( => if (
while( => while (
}else => } else
else{ => else {
switch( => switch (
try{ => try {
}catch => } catch
catch( => catch (
}finally{ => } finally {

So these changes are also in this commit, should not be a problem anyway.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@763175 13f79535-47bb-0310-9956-ffa450edef68
2009-04-08 10:54:51 +00:00

665 lines
41 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-screen.xsd">
<!-- Custom apps can use their own invoice decorator by specifying its
location in parameters.invoiceDecoratorLocation -->
<screen name="CommonInvoiceDecorator">
<section>
<actions>
<property-map resource="ProjectMgrUiLabels" map-name="uiLabelMap" global="true"/>
<set field="headerItem" value="invoices"/>
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<section>
<condition>
<if-service-permission service-name="acctgInvoicePermissionCheck" main-action="VIEW"/>
</condition>
<widgets>
<section>
<condition><not><if-empty field="parameters.invoiceId"/></not></condition>
<widgets>
<include-menu name="InvoiceTabBar" location="component://accounting/widget/Menus.xml"/>
<include-menu name="InvoiceSubTabBar" location="component://accounting/widget/Menus.xml"/>
<container style="leftclear">
<label style="h1" text="${uiLabelMap[labelTitleProperty]} ${uiLabelMap.CommonFor}: ${invoice.description} [${invoiceId}] ${${extraFunctionName}}"/>
</container>
</widgets>
</section>
<decorator-section-include name="body"/>
</widgets>
<fail-widgets>
<label style="h3">${uiLabelMap.AccountingViewPermissionError}</label>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="FindInvoices">
<section>
<actions>
<set field="headerItem" value="invoices"/>
<set field="titleProperty" value="PageTitleFindInvoice"/>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<section>
<widgets>
<decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml">
<decorator-section name="menu-bar">
<include-menu name="InvoiceSubTabBar" location="component://accounting/widget/Menus.xml"/>
<container style="clear"/>
</decorator-section>
<decorator-section name="search-options">
<include-form name="FindInvoices" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListInvoices" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="NewInvoice">
<section>
<actions>
<set field="titleProperty" value="AccountingCreateNewInvoice"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<section>
<widgets>
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingCreateNewSalesInvoice}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="NewSalesInvoice" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingCreateNewPurchaseInvoice}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="NewPurchaseInvoice" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="EditInvoice">
<section>
<actions>
<set field="titleProperty" value="PageTitleEditInvoice"/>
<set field="tabButtonItem" value="editInvoice"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<property-to-field field="defaultCurrencyUomId" resource="general" property="currency.uom.id.default" default="USD"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<entity-one entity-name="InvoiceType" value-field="invoiceType">
<field-map field-name="invoiceTypeId" from-field="invoice.invoiceTypeId"/>
</entity-one>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<section>
<condition>
<if-compare field="invoice.statusId" operator="equals" value="INVOICE_IN_PROCESS"/>
</condition>
<widgets>
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.PageTitleEditInvoice}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="EditInvoice" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</widgets>
<fail-widgets>
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.PageTitleEditInvoice}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="invoiceHeader" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="invoiceOverview">
<section>
<actions>
<set field="titleProperty" value="PageTitleInvoiceOverview"/>
<set field="tabButtonItem" value="invoiceOverview"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<entity-and entity-name="InvoiceRole" list="invoiceRoles">
<field-map from-field="parameters.invoiceId" field-name="invoiceId"/>
<order-by field-name="partyId"/>
</entity-and>
<entity-and entity-name="InvoiceStatus" list="invoiceStatus">
<field-map from-field="parameters.invoiceId" field-name="invoiceId"/>
<order-by field-name="statusDate"/>
</entity-and>
<entity-and entity-name="InvoiceTerm" list="invoiceTerms">
<field-map from-field="parameters.invoiceId" field-name="invoiceId"/>
<order-by field-name="invoiceTermId"/>
</entity-and>
<entity-and entity-name="TimeEntry" list="timeEntries">
<field-map from-field="parameters.invoiceId" field-name="invoiceId"/>
<order-by field-name="invoiceItemSeqId"/>
</entity-and>
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/CreateApplicationList.groovy"/>
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/OrderListInvoiceItem.groovy"/>
<set field="invoiceAmount" value="${bsh:org.ofbiz.accounting.invoice.InvoiceWorker.getInvoiceTotal(invoice)}" type="BigDecimal"/>
<set field="notAppliedAmount" value="${bsh:org.ofbiz.accounting.invoice.InvoiceWorker.getInvoiceNotApplied(invoice)}" type="BigDecimal"/>
<set field="appliedAmount" value="${bsh:org.ofbiz.accounting.invoice.InvoiceWorker.getInvoiceApplied(invoice)}" type="BigDecimal"/>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<section>
<condition>
<if-compare field="invoice.statusId" operator="equals" value="INVOICE_IN_PROCESS"/>
</condition>
<widgets>
<screenlet title="${uiLabelMap.AccountingInvoiceHeader}">
<container>
<link target="editInvoice" text="${uiLabelMap.CommonUpdate}" style="buttontext">
<parameter param-name="invoiceId"/>
</link>
</container>
<include-form name="invoiceHeader" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<container style="lefthalf">
<screenlet title="${uiLabelMap.AccountingInvoiceStatus}" navigation-form-name="ListInvoiceStatus">
<include-form name="ListInvoiceStatus" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.AccountingAppliedPayments} ${appliedAmount?currency(${invoice.currencyUomId})} ${uiLabelMap.AccountingOpenPayments} ${notAppliedAmount?currency(${invoice.currencyUomId})}"
navigation-form-name="ListInvoiceApplications">
<container>
<link target="editInvoiceApplications" text="${uiLabelMap.CommonUpdate}" style="buttontext">
<parameter param-name="invoiceId"/>
</link>
</container>
<include-form name="ListInvoiceApplications" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</container>
<container style="righthalf">
<screenlet title="${uiLabelMap.AccountingInvoiceRoles}" navigation-form-name="invoiceRoles">
<container>
<link target="invoiceRoles" text="${uiLabelMap.CommonUpdate}" style="buttontext">
<parameter param-name="invoiceId"/>
</link>
</container>
<include-form name="invoiceRoles" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.PartyTerms}">
<include-form name="ListInvoiceTerms" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
<include-form name="ListInvoicePaymentInfo" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</container>
<container style="leftclear"/>
<screenlet title="${uiLabelMap.AccountingInvoiceItems}" navigation-form-name="invoiceItems">
<container>
<link target="listInvoiceItems" text="${uiLabelMap.CommonUpdate}" style="buttontext">
<parameter param-name="invoiceId"/>
</link>
</container>
<include-form name="invoiceItems" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<section>
<condition>
<not><if-empty field="timeEntries"/></not>
</condition>
<widgets>
<screenlet title="${uiLabelMap.AccountingInvoiceTimeEntries}" navigation-form-name="ListTimeEntries">
<container>
<link target="editInvoiceTimeEntries" text="${uiLabelMap.CommonUpdate}" style="buttontext">
<parameter param-name="invoiceId"/>
</link>
</container>
<include-form name="ListTimeEntries" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</widgets>
</section>
<screenlet title="${uiLabelMap.AccountingTransactions}" navigation-form-name="AcctgTransAndEntries">
<include-form name="AcctgTransAndEntries" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
<screenlet title="${uiLabelMap.AccountingInvoiceHeader}">
<include-form name="invoiceHeader" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<container style="lefthalf">
<screenlet title="${uiLabelMap.AccountingInvoiceStatus}" navigation-form-name="ListInvoiceStatus">
<include-form name="ListInvoiceStatus" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.AccountingAppliedPayments} ${appliedAmount?currency(${invoice.currencyUomId})} ${uiLabelMap.AccountingOpenPayments} ${notAppliedAmount?currency(${invoice.currencyUomId})}"
navigation-form-name="ListInvoiceApplications">
<include-form name="ListInvoiceApplications" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</container>
<container style="righthalf">
<screenlet title="${uiLabelMap.AccountingInvoiceRoles}" navigation-form-name="invoiceRoles">
<include-form name="invoiceRoles" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.PartyTerms}">
<include-form name="ListInvoiceTerms" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
<include-form name="ListInvoicePaymentInfo" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</container>
<container style="leftclear"/>
<screenlet title="${uiLabelMap.AccountingInvoiceItems}" navigation-form-name="invoiceItems">
<include-form name="invoiceItems" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<section>
<condition>
<not><if-empty field="timeEntries"/></not>
</condition>
<widgets>
<screenlet title="${uiLabelMap.AccountingInvoiceTimeEntries}" navigation-form-name="ListTimeEntries">
<include-form name="ListTimeEntries" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</widgets>
</section>
<screenlet title="${uiLabelMap.AccountingTransactions}" navigation-form-name="AcctgTransAndEntries">
<include-form name="AcctgTransAndEntries" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="InvoiceStatus">
<section>
<actions>
<set field="titleProperty" value="PageTitleListInvoices"/>
<set field="tabButtonItem" value="invoiceStatus"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<entity-one entity-name="Invoice" value-field="invoice" auto-field-map="true"/>
<entity-and entity-name="InvoiceStatus" list="invoiceStatus">
<field-map from-field="invoice.invoiceId" field-name="invoiceId"/>
<order-by field-name="statusDate"/>
</entity-and>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingInvoiceStatusHistory}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="ListInvoiceStatus" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="EditInvoiceApplications">
<section>
<actions>
<set field="titleProperty" value="PageTitleListEditInvoiceApplications"/>
<set field="tabButtonItem" value="editInvoiceApplications"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/CreateApplicationList.groovy"/>
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/ListNotAppliedPayments.groovy"/>
<set field="invoiceAmount" value="${bsh:org.ofbiz.accounting.invoice.InvoiceWorker.getInvoiceTotal(invoice)}" type="BigDecimal"/>
<set field="notAppliedAmount" value="${bsh:org.ofbiz.accounting.invoice.InvoiceWorker.getInvoiceNotApplied(invoice)}" type="BigDecimal"/>
<set field="appliedAmount" value="${bsh:org.ofbiz.accounting.invoice.InvoiceWorker.getInvoiceApplied(invoice)}" type="BigDecimal"/>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<section>
<condition>
<if-compare field="notAppliedAmount" operator="greater" value="0"/>
</condition>
<widgets>
<screenlet title="${uiLabelMap.AccountingPaymentsApplied} ${appliedAmount?currency(${invoice.currencyUomId})} ${uiLabelMap.AccountingOpenPayments} ${notAppliedAmount?currency(${invoice.currencyUomId})}">
<include-form name="EditInvoiceApplications" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<section>
<condition>
<if-empty field="invoiceApplications"/>
</condition>
<widgets>
<container><label style="h3" text="${uiLabelMap.AccountingNoPaymentsApplicationsfound}"></label></container>
</widgets>
</section>
<section>
<condition>
<or>
<not><if-empty field="payments"/></not>
<not><if-empty field="paymentsActualCurrency"/></not>
</or>
</condition>
<widgets>
<screenlet title="${uiLabelMap.AccountingListPaymentsNotYetApplied} [${invoice.partyIdFrom}] ${uiLabelMap.AccountingPaymentSentForm} [${invoice.partyId}]">
<section>
<condition>
<not><if-empty field="payments"/></not>
</condition>
<widgets>
<include-form name="ListPaymentsNotApplied" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
<section>
<condition>
<not><if-empty field="paymentsActualCurrency"/></not>
</condition>
<widgets>
<include-form name="ListPaymentsNotAppliedForeignCurrency" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</screenlet>
</widgets>
</section>
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingAssignPaymentToInvoice}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="AddPayment" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</widgets>
<fail-widgets>
<screenlet title="${uiLabelMap.AccountingPaymentsApplied} ${appliedAmount?currency(${invoice.currencyUomId})} ${uiLabelMap.AccountingOpenPayments} ${notAppliedAmount?currency(${invoice.currencyUomId})}">
<include-form name="EditInvoiceApplications" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<section>
<condition>
<if-empty field="invoiceApplications"/>
</condition>
<widgets>
<container><label style="h3" text="${uiLabelMap.AccountingNoPaymentsApplicationsfound}"></label></container>
</widgets>
</section>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="EditInvoiceItems">
<section>
<actions>
<set field="titleProperty" value="PageTitleListInvoices"/>
<set field="tabButtonItem" value="listInvoiceItems"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<set field="invoiceItemSeqd" from-field="parameters.invoiceItemSeqId"/>
<property-to-field field="defaultCurrencyUomId" resource="general" property="currency.uom.id.default" default="USD"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<entity-one entity-name="InvoiceItem" value-field="invoiceItem"/>
<entity-and entity-name="InvoiceItem" list="invoiceItems">
<field-map field-name="invoiceId" from-field="parameters.invoiceId"/>
<order-by field-name="invoiceItemSeqId"/>
</entity-and>
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/GetInvoiceItemTypes.groovy"/>
<entity-condition entity-name="InvoiceItemType" list="PayrolGroup">
<condition-expr field-name="parentTypeId" value="PAYROL"/>
</entity-condition>
<entity-condition entity-name="InvoiceItemType" list="PayrolList"></entity-condition>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingInvoiceItems}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="EditInvoiceItems" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingInvoiceItemAdd}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<condition>
<not><if-compare field="invoice.invoiceTypeId" operator="equals" value="PAYROL_INVOICE"/></not>
</condition>
<widgets>
<include-form name="EditInvoiceItem" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
<fail-widgets>
<platform-specific><html><html-template location="component://accounting/webapp/accounting/invoice/InvoiceItemsPayrol.ftl"/></html></platform-specific>
</fail-widgets>
</section>
</container>
</container>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="EditInvoiceTimeEntries">
<section>
<actions>
<set field="titleProperty" value="PageTitleListInvoiceTimeEntries"/>
<set field="tabButtonItem" value="EditInvoiceTimeEntries"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<entity-and entity-name="TimeEntry" list="timeEntries">
<field-map field-name="invoiceId" from-field="parameters.invoiceId"/>
<order-by field-name="timeEntryId"/>
</entity-and>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.AccountingInvoiceTimeEntries}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="EditTimeEntries" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="InvoiceRoles">
<section>
<actions>
<set field="titleProperty" value="PageTitleListInvoiceRoles"/>
<set field="tabButtonItem" value="invoiceRoles"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<entity-and entity-name="InvoiceRole" list="invoiceRoles">
<field-map from-field="invoiceId" field-name="invoiceId"/>
<order-by field-name="partyId"/>
</entity-and>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<screenlet id="PartyInvoiceRolePanel" title="${uiLabelMap.AccountingPartyRoleAdd}" collapsible="true">
<include-form name="EditInvoiceRole" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
<include-form name="ListInvoiceRoles" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="SendPerEmail">
<section>
<actions>
<set field="titleProperty" value="PageTitleSendInvoicePerEmail"/>
<set field="invoiceId" from-field="parameters.invoiceId"/>
<entity-one entity-name="Invoice" value-field="invoice"/>
<set field="tabButtonItem" value="sendPerEmail"/>
</actions>
<widgets>
<decorator-screen name="CommonInvoiceDecorator" location="${parameters.invoiceDecoratorLocation}">
<decorator-section name="body">
<container style="screenlet">
<container style="screenlet-title-bar">
<container style="h3">
<label text="${uiLabelMap.CommonSendPerEmail}"/>
</container>
</container>
<container style="screenlet-body">
<section>
<widgets>
<include-form name="SendPerEmail" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</widgets>
</section>
</container>
</container>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="sendPerEmailBody">
<section>
<widgets>
<platform-specific><html><html-template location="component://accounting/webapp/accounting/invoice/sendPerEmail.ftl"/></html></platform-specific>
</widgets>
</section>
</screen>
<screen name="ListCustomerInvoices">
<section>
<actions>
<script location="component://party/webapp/partymgr/WEB-INF/actions/party/GetMyCompany.groovy"/>
<entity-condition list="invoices" entity-name="Invoice">
<condition-list combine="and">
<condition-expr field-name="partyId" operator="equals" from-field="myCompanyId"/>
<condition-list combine="or">
<condition-expr field-name="statusId" operator="equals" value="INVOICE_APPROVED"/>
<condition-expr field-name="statusId" operator="equals" value="INVOICE_SEND"/>
<condition-expr field-name="statusId" operator="equals" value="INVOICE_READY"/>
<condition-expr field-name="statusId" operator="equals" value="INVOICE_PAID"/>
</condition-list>
</condition-list>
<order-by field-name="invoiceDate DESC"/>
</entity-condition>
</actions>
<widgets>
<screenlet title="${uiLabelMap.PageTitleListInvoices}" navigation-form-name="ListInvoices">
<include-form name="ListCustomerInvoices" location="component://accounting/webapp/accounting/invoice/InvoiceForms.xml"/>
</screenlet>
</widgets>
</section>
</screen>
</screens>