git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@835709 13f79535-47bb-0310-9956-ffa450edef68
121 lines
6.5 KiB
XML
121 lines
6.5 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.
|
|
-->
|
|
|
|
<!-- These screens are for generating printed documents, such as invoices, bills, statements, etc. -->
|
|
|
|
<screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-screen.xsd">
|
|
|
|
<!-- generate a PDF for the invoice. sharing the same BSH file as the HTML page for viewing invoice -->
|
|
<screen name="InvoicePDF">
|
|
<section>
|
|
<actions>
|
|
<property-map resource="AccountingUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<property-map resource="ProductUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<property-map resource="PartyUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<set field="titleProperty" value="AccountingInvoice"/>
|
|
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/EditInvoice.groovy"/>
|
|
<script location="component://party/webapp/partymgr/WEB-INF/actions/party/GetMyCompany.groovy"/>
|
|
</actions>
|
|
<widgets>
|
|
<section>
|
|
<condition>
|
|
<or>
|
|
<if-has-permission permission="ACCOUNTING" action="_VIEW"/>
|
|
<!-- can always see own invoice -->
|
|
<if-compare field="invoice.partyIdFrom" operator="equals" value="${userLogin.partyId}"/>
|
|
<if-compare field="invoice.partyId" operator="equals" value="${userLogin.partyId}"/>
|
|
<!-- or is a contact of a company who owns the invoice-->
|
|
<if-compare field="invoice.partyIdFrom" operator="equals" value="${myCompanyId}"/>
|
|
<if-compare field="invoice.partyId" operator="equals" value="${myCompanyId}"/>
|
|
</or>
|
|
</condition>
|
|
<widgets>
|
|
<decorator-screen name="FoReportDecorator" location="component://common/widget/CommonScreens.xml">
|
|
<decorator-section name="topLeft">
|
|
<include-screen name="CompanyLogo" location="component://order/widget/ordermgr/OrderPrintScreens.xml"/>
|
|
</decorator-section>
|
|
<decorator-section name="topRight">
|
|
<platform-specific>
|
|
<xsl-fo><html-template location="component://accounting/webapp/accounting/invoice/invoiceReportHeaderInfo.fo.ftl"/></xsl-fo>
|
|
</platform-specific>
|
|
</decorator-section>
|
|
<decorator-section name="body">
|
|
<platform-specific>
|
|
<xsl-fo><html-template location="component://accounting/webapp/accounting/invoice/invoiceReportContactMechs.fo.ftl"/></xsl-fo>
|
|
</platform-specific>
|
|
<platform-specific>
|
|
<xsl-fo><html-template location="component://accounting/webapp/accounting/invoice/invoiceReportItems.fo.ftl"/></xsl-fo>
|
|
</platform-specific>
|
|
</decorator-section>
|
|
</decorator-screen>
|
|
</widgets>
|
|
<fail-widgets>
|
|
<decorator-screen name="FoReportDecorator" location="component://common/widget/CommonScreens.xml">
|
|
<decorator-section name="body">
|
|
<platform-specific>
|
|
<xsl-fo><html-template location="component://accounting/webapp/accounting/invoice/NoAccountingView.fo.ftl"/></xsl-fo>
|
|
</platform-specific>
|
|
</decorator-section>
|
|
</decorator-screen>
|
|
</fail-widgets>
|
|
</section>
|
|
</widgets>
|
|
</section>
|
|
</screen>
|
|
|
|
<screen name="PrintCheckPDF">
|
|
<section>
|
|
<condition>
|
|
<if-has-permission permission="ACCOUNTING" action="_VIEW"/>
|
|
</condition>
|
|
<actions>
|
|
<set field="titleProperty" value="AccountingPrintChecks"/>
|
|
</actions>
|
|
<widgets>
|
|
<platform-specific>
|
|
<xsl-fo><html-template location="component://accounting/webapp/accounting/payment/printCheck.fo.ftl"/></xsl-fo>
|
|
</platform-specific>
|
|
</widgets>
|
|
<fail-widgets>
|
|
<label style="h3" text="${uiLabelMap.AccountingPrintChecksPermissionError}"/>
|
|
</fail-widgets>
|
|
</section>
|
|
</screen>
|
|
<screen name="PrintInvoices">
|
|
<section>
|
|
<actions>
|
|
<property-map resource="AccountingUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<property-map resource="ProductUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<property-map resource="PartyUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
|
|
<set field="invoiceIds" from-field="parameters.invoiceIds" type="List"/>
|
|
<script location="component://accounting/webapp/accounting/WEB-INF/actions/invoice/PrintInvoices.groovy"/>
|
|
</actions>
|
|
<widgets>
|
|
<platform-specific>
|
|
<xsl-fo><html-template location="component://accounting/webapp/accounting/invoice/PrintInvoices.fo.ftl"/></xsl-fo>
|
|
</platform-specific>
|
|
</widgets>
|
|
</section>
|
|
</screen>
|
|
</screens>
|