262 Commits
Author SHA1 Message Date
Florian Motteau c85550e306 Fixed: Wrong Less file path for some theme/locale combinations (OFBIZ-12660) (#521)
For some themes, we rely on toLowerCase method to build a Less file path.
toLowerCase("I") = "ı" for some locales (TR, AZ), which lead to incorrect
file paths and finally broken themes.
2022-08-10 10:35:49 +02:00
dependabot[bot] 783e91f2bd Bump flot in /themes/common-theme/webapp/common-theme/js (#532)
Bumps [flot](https://github.com/flot/flot) from 4.2.2 to 4.2.3.
- [Release notes](https://github.com/flot/flot/releases)
- [Changelog](https://github.com/flot/flot/blob/master/CHANGELOG.md)
- [Commits](https://github.com/flot/flot/compare/v4.2.2...v4.2.3)

---
updated-dependencies:
- dependency-name: flot
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-02 19:44:57 +02:00
Deepak Dixit 9b79d38ec5 Updated notification tag maxOccurs, as system allow multiple notification per service 2022-07-29 15:11:52 +05:30
Deepak Dixit 6013c74c22 Improved: Updated mysql jdbc-driver class from com.mysql.jdbc.Driver to com.mysql.cj.jdbc.Driver (OFBIZ-12675) (#529)
MySQL Connector/J 8.0 is highly recommended for use with MySQL Server 8.0 and 5.7. Please upgrade to MySQL Connector/J 8.0.
https://dev.mysql.com/doc/connector-j/8.0/en/
2022-07-29 14:49:59 +05:30
Jacques Le Roux b7b981993c Improved: change uglify-js to real version number
"latest" was preventing updates in trunk demo (merge conflict)
2022-07-28 09:55:38 +02:00
Jacques Le Roux df98889c7b Improved: Data of tenant specific component gets loaded in all instances (OFBIZ-6065)
Improves the information provided about importing and loadAll Gradle task
loadTenant Gradle task should be used when necessary
2022-07-28 09:40:28 +02:00
Jacques Le Roux 9351b641e8 Improved: Data of tenant specific component gets loaded in all instances (OFBIZ-6065)
The tenant relevant Gradle tasks are:

OFBiz Server tasks
------------------
createTenant - Create a new tenant in your environment
loadAdminUserLogin - Create admin user with temporary password equal to ofbiz.
You must provide userLoginId
loadAll - Load default data; meant for OFBiz development, testing, and demo
purposes
loadTenant - Load data using tenantId

loadAll is the new "ant load-data" and should clearly only used for
"OFBiz development, testing, and demo purposes".

Remains the import functionalities. We don't want to get to far with that,
a warning is enough.

Thanks: Pierre Smits for report
2022-07-27 16:20:55 +02:00
dependabot[bot] 7c45738700 Bump uglify-js in /themes/common-theme/webapp/common-theme/js (#527)
Bumps [uglify-js](https://github.com/mishoo/UglifyJS) from 3.16.2 to 3.16.3.
- [Release notes](https://github.com/mishoo/UglifyJS/releases)
- [Commits](https://github.com/mishoo/UglifyJS/compare/v3.16.2...v3.16.3)

---
updated-dependencies:
- dependency-name: uglify-js
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-26 19:07:22 +02:00
Jacques Le Roux ead5f29146 Improved: Update Groovy to 2.5.18 (OFBIZ-12673)
See https://lists.apache.org/thread/r3q4mh3nnxyl7p0gclzbshcgz574l3sp, notably:

    This release is a maintenance release of the GROOVY_2_5_X branch.
    It is strongly encouraged that all users using prior
    versions on this branch upgrade to this version.

    This release includes 15 bug fixes/improvements as outlined in the changelog:
    https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12318123&version=12351798
2022-07-25 09:16:58 +02:00
Jacques Le Roux 7875045e5a Fixed: Fix OFBiz speficic Javascript securiy issues reported by GH CodeQL (OFBIZ-12366)
Actually I put in a path error then, it's not
value="/common/js/node_modules/node_modules/dompurify/dist/purify.min.js"
but
value="/common/js/node_modules/dompurify/dist/purify.min.js"

This fixes it
2022-07-25 09:16:58 +02:00
georg1312 d82626974a Improved: Strip data to maximum column length for initialRequest and (#526)
initialReferrer (OFBIZ-12672)

Analogous to the existing limitation of the "initialUserAgent" to 250
characters, installation of a limitation of 2000 characters for
initialRequest and initialReferrer, so as not to exit with
"MysqlDataTruncation: Data truncation: Data too long for column
'INITIAL_REFERRER' at row 1" in the case of very long requests.
2022-07-25 09:14:08 +02:00
Michael Brohl 20ccb4dcfd Improved: Make loading of data containing urls configurable
(OFBIZ-12670)

Introduces a SystemProperty security#security.datafile.loadurls.enable
which can be set to true to allow loading of urls in the XML import.
2022-07-21 15:14:58 +02:00
dependabot[bot] c42d580304 Bump dompurify in /themes/common-theme/webapp/common-theme/js (#522)
Bumps [dompurify](https://github.com/cure53/DOMPurify) from 2.3.9 to 2.3.10.
- [Release notes](https://github.com/cure53/DOMPurify/releases)
- [Commits](https://github.com/cure53/DOMPurify/compare/2.3.9...2.3.10)

---
updated-dependencies:
- dependency-name: dompurify
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-18 17:54:57 +02:00
Nicolas Malin e12c98ac5b Implemented: Define return user message from controller (OFBIZ-12652)
Currently, when you wish return a message to a user after an event request, you need to set it ine the called event.

for a service in java :
  ServiceUtil.returnSuccess("Your service is a success")

for a service in groovy :
  return success("Your service is a success")

for a Java class :
  request.setAttribute("_EVENT_MESSAGE_", "Your service is a success");

If during an integration, you want to use standard service like createProduct, createPartyRelationship, and need a specific message for users, you need to define your own service.

For escape this case and increase the service usability, I propose to implement a new system to override the event return by a definition depending on the buisness context.

For that two improvement :
1. Add new child element to request-map->response on the controller
    With given the exact value:

         <response name="success" type="request" value="json">
             <return-user-message value="Your service is a success"/>
         </response>

    With a flexible expander:

        <response name="success" type="request" value="json">
           <return-user-message value="Your service to change is a success"/>
        </response>

    With a property:

        <response name="success" type="request" value="json">
           <return-user-message ressource="CommonUiLabels" value="CommonSuccessfullyCreated"/>
        </response>

    From a context field:

        <response name="success" type="request" value="json">
           <return-user-message from-field="mySpecificReturnMessage"/>
        </response>

2. From the context directly sent from the form

  <form name="CallEvent" target="MyEvent" .. >
     <field name="_CUSTOM_EVENT_MESSAGE_"> <hidden value="Your service to change is a success"/>
     <field name="_CUSTOM_ERROR_MESSAGE_"> <hidden value="Your service failed"/>

Thanks to Florian Motteau for the implementation help
2022-07-15 15:59:09 +02:00
Nicolas Malin 54c86fd53c Improved: Update documentation for official support of java 11 2022-07-15 15:03:46 +02:00
Nicolas Malin 2c7d552840 Fixed: Calendar in Work Effort does not work (OFBIZ-12665)
Fix a null pointer exception when a menu extend a menu with empty item.
In this case, we use a empty link for the extended menu.

Thanks to Jacques Leroux for the alert
2022-07-15 14:38:16 +02:00
Nicolas Malin 735048f6be Improved: Convert StorageServices.xml mini-lang to groovyDSL (OFBIZ-9350) (OFBIZ-12669)
Convert the service createFacilityLocation from minilang to groovyDSL

Thanks to Tom Gibert for the help
2022-07-15 14:31:18 +02:00
Nicolas Malin d532548e4c Improved: Convert PromoServices.xml mini-lang to groovyDSL (OFBIZ-9350) (OFBIZ-12668)
Convert services createProductPromoCond and updateProductPromoCond from minilang to groovyDSL

Thanks to Tom Gibert for the help
2022-07-15 11:32:29 +02:00
Nicolas Malin c696d232cb Improved: Convert SupplierProductServices.xml mini-lang to groovyDSL (OFBIZ-9350) (OFBIZ-12667)
Convert the service getSupplierProductFeatures from mini-lang to groovyDSL

Thanks to Tom Gibert for the help
2022-07-15 11:32:29 +02:00
dependabot[bot] 80c0676fa6 Bump dompurify in /themes/common-theme/webapp/common-theme/js (#520)
Bumps [dompurify](https://github.com/cure53/DOMPurify) from 2.3.8 to 2.3.9.
- [Release notes](https://github.com/cure53/DOMPurify/releases)
- [Commits](https://github.com/cure53/DOMPurify/compare/2.3.8...2.3.9)

---
updated-dependencies:
- dependency-name: dompurify
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-12 08:45:03 +02:00
Pierre Smits 38230e4262 Improved: WorkEffort - MainActionMenu (OFBIZ-12557) (#498)
Currently the create buttons for the main objects of the work effort  are located within the find and other widgets/templates of those objects.
In order to improve the usability of OFBiz (and thus the appeal of it for adopters and users) these create buttons/links/etc. should be in a main action menu visible at all times when a user is working within the component.

modified:
WorkEffortMenus.xml - added MainActionMenu for users with CREATE permission in the component
CommonScreens.xml - added MainActionMenu as an 'include-menu' ref in various common decorator screens.
Added MainActionMenu as an 'include-menu' in screen definitions in various other Screen.xml files where appropriate
additional cleaning.
2022-07-10 14:47:35 +02:00
Jacques Le Roux d41d8168c1 Improved: dependabot.yml missed an ASL2 licence header 2022-07-10 10:57:28 +02:00
Nicolas Malin f1c2e8732e Improved: Allow DynamicView use in standard performFind services (OFBIZ-12663)
Extend standard find services (prepareFind, executeFind and performFind) to use a built dynamicView instead of just an entityName.

With this, you can prepare a dedicated dynamicView and call the performFind with on result a database optimisation.

Thanks to Leila Mekika for this proposal and patch
2022-07-08 17:33:30 +02:00
dependabot[bot] 87f86c21ae Bump jquery-validation in /themes/common-theme/webapp/common-theme/js (#519)
Bumps [jquery-validation](https://github.com/jquery-validation/jquery-validation) from 1.19.4 to 1.19.5.
- [Release notes](https://github.com/jquery-validation/jquery-validation/releases)
- [Changelog](https://github.com/jquery-validation/jquery-validation/blob/master/changelog.md)
- [Commits](https://github.com/jquery-validation/jquery-validation/compare/1.19.4...1.19.5)

---
updated-dependencies:
- dependency-name: jquery-validation
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-04 18:10:41 +02:00
dependabot[bot] 5923280441 Bump uglify-js in /themes/common-theme/webapp/common-theme/js (#518)
Bumps [uglify-js](https://github.com/mishoo/UglifyJS) from 3.16.1 to 3.16.2.
- [Release notes](https://github.com/mishoo/UglifyJS/releases)
- [Commits](https://github.com/mishoo/UglifyJS/compare/v3.16.1...v3.16.2)

---
updated-dependencies:
- dependency-name: uglify-js
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-04 18:09:49 +02:00
Nicolas Malin 8ee85ec390 Improved: Add sequenceNum field on contentAssoc list (OFBIZ-12654)
By the way, clean unnecessary code and change groovy scripting call by the native date translation

Thanks to Ingo Wolfmayr for this issue
2022-07-01 18:49:06 +02:00
Nicolas Malin 576307ac5c Improved: Add missing parameter on xsd for widget-form:on-field-event-update-area (OFBIZ-12586)
On the widget-form.xsd definition, the element on-field-event-update-area haven't possibility to define some parameters.

But on java code, the on-field-event-update-area is read like on-event-update-area.

If you put some parameters on your code, your editor raise a syntax error but OFBiz analyse and execute it well.

            <wf:field name="reload" >
                <wf:submit/>
                <wf:on-field-event-update-area event-type="click"
                                               area-target="ReloadIt">
                    <wf:auto-parameters-service service-name="computeForReload" send-if-empty="false"/>
                </wf:on-field-event-update-area>
            </wf:field>

By the way we can synchronize the on-field-event-update-area xsd on on-event-update-area.
2022-07-01 18:31:41 +02:00
Nicolas Malin e0f61dceb7 Improved: Convert a display-entity to hyperlink if subhyperlink this empty (OFBIZ-12547)
When you define a display-entity you have the possibility to add a sub-hyperlink related to the element displayed.

             <field name="partyIdFrom">
                <display-entity entity-name="PartyNameView" key-field-name="partyId" description="${groupName}${firstName} ${lastName}">
                    <sub-hyperlink target="viewprofile" description="view">...</sub-hyperlink>
                </display-entity>
            <field>

This display the party name with a link "view" connected.

When you use the name as link without a dedicate sub link, you need to change all the form to resolve the information to display for creating an hyperlink

            <row-actions>
                <entity-one entity-name="PartyNameView" value-field="partyName">
                        <field-map field-name="partyId" from-field="partyIdFrom"/>
                </entity-one>
                <set field="partyNameValue" value=" ${partyName.groupName}${partyName.firstName} ${partyName.lastName}"/>
            </row-actions>
            <field name="partyIdFrom">
                <hyperlink target="viewprofile" description="${partyNameValue}">..</hyperlink>
            </field>

We lost the advantage of the display-entity. With this case, we improve display-entity with the following rule :

If the display-entity has a subhyperlink and the subhyperlink haven't description, the description of the link is the display-entity description.
In the code, if a sub-hyperlink has an empty description, we convert the display entity as a hyperlink
2022-07-01 18:21:49 +02:00
Nicolas Malin 8015dcb02d Improved: Refactoring service resenquence (OFBIZ-12624)
The service "resequence" compute for a content all sequenceNum for linked content assoc.

The code is very old (before apache) so apply a slim refactor and migrate the service name resequence to resequenceContentAssocChildren.

By the way I kept the service definition resequence to move it as deprecated.
2022-07-01 18:04:45 +02:00
Nicolas Malin 7ea371bde3 Fixed: MenuItem doesn't follow correctly extended informations (OFBIZ-12628)
Fix a null pointer exception when the extended menu have an entry without link.

Thanks to Jacques Leroux for the alert
2022-07-01 17:37:14 +02:00
Jacques Le Roux 78ee6f8792 Improved: CustomSafePolicy, also use TagBalancingHtmlStreamEventReceiver (OFBIZ-12653)
Adds <img> and <hr> to CustomSafePolicy, removes obsolete <tt>. <img> allows
only attributes src and alt.

Both <br> and <br /> are correct. For that, this rather uses
TagBalancingHtmlStreamEventReceiver

Thanks: Ingo Wolfmayr
2022-07-01 17:26:18 +02:00
Jacques Le Roux 415b0124fe Improved: Helveticus App-Bar Css Issue - Height change on hover (OFBIZ-12661)
When hovering an app-navigation item, the height of the app bar changes.
Doesn't look good. Attached the correction.

Thanks: Ingo Wolfmayr
2022-06-29 10:52:55 +02:00
Jacques Le Roux 9abd236284 Improved: Update build.gradle to the latest dependencies (OFBIZ-12658)
Reverts asciidoctorj-pdf to 1.5.3

Not sure it will work, at least I have a (another?) problem locally in Win 7
2022-06-29 10:45:34 +02:00
Jacques Le Roux 56fd07118b Improved: Update build.gradle to the latest dependencies (OFBIZ-12658)
Reverts tika-core to 1.28.4 and fop to 2.3

I did not launch the tests, those did not pass:
ecommercetests	testSendOrderConfirmation
widgettests testFopMacroLibrary

Tika is a bit annoying, no security releases after Sept. 30
2022-06-28 19:29:17 +02:00
Jacques Le Roux 5dc416c3c6 Improved: Runs GitHub Gradle build with Java 11
New line just to apply change made in Buildbot config to run w/ Java 11

Thanks to Gavin who noticed I forgot one line in Buildbot config  :/
2022-06-27 20:21:27 +02:00
Jacques Le Roux 1bce4deb5e Improved: Runs GitHub Gradle build with Java 11
New line just to apply change made in Buildbot config to run w/ Java 11

Seems last time Buildbot did not catch up or something is wrong
I double checked Buildbot config is properly set to run w/ Java 11 and change is
committed

Trying again after Gavin confirmed it should be OK on Slack #asfinfra channel
2022-06-27 19:54:35 +02:00
Jacques Le Roux e4777decb4 Improved: Runs GitHub Gradle build with Java 11
New line just to apply change made in Buildbot config to run w/ Java 11

Seems last time Buildbot did not catch up or something is wrong
I double checked Buildbot config is properly set to run w/ Java 11 and change is
committed
2022-06-27 19:15:08 +02:00
Jacques Le Roux a5d949ecde Improved: Runs GitHub Gradle build with Java 11
Trivial change just to apply change made in Buildbot config to run w/ Java 11
2022-06-27 18:39:17 +02:00
Jacques Le Roux 65c766e0c9 Improved: Runs GitHub Gradle build with Java 11 2022-06-27 18:07:28 +02:00
Jacques Le Roux 18d0d75f43 Improved: Update build.gradle to the latest dependencies (OFBIZ-12658)
I noticed that JpegImageParser from Apache Commons Imaging never had a write
option. So I commented it out. I tested uploading, it's OK

org.apache.axiom.om.impl.builder.StAXOMBuilder has been replaced by
org.apache.axiom.om.OMXMLParserWrapper
in SOAPEventHandler.java

The rest of information is in the main build.gradle

I got 2 test errors on Win7. I'll see how it goes on GH and BB.
Maybe it's write.lock issues with Lucene or/and Solr indexes
2022-06-27 15:40:08 +02:00
Jacques Le Roux 80fc052d22 Fixed: [SECURITY] Upgrade Tika to 1.28.4 (OFBIZ-12657)
Mentionned at https://tika.apache.org/
Apache Tika 1.28.4 has been released! This release includes security related
fixes and dependency upgrades
Note: The Apache Tika PMC has set September 30, 2022 as the End Of Life for the
Tika 1.x branch.
2022-06-22 13:52:33 +02:00
Jacques Le Roux 14c58a11c8 Improved: OWASP sanitizer breaks proper rendering of HTML code (OFBIZ-12653)
Allows both <br> and <br /> to pass in UtilCodec::checkStringForHtmlSafe, both
are correct.

Clarifies owasp.properties documentation about how to create own sanitizer
policies
2022-06-21 20:57:37 +02:00
dependabot[bot] a2dbc689fe Bump uglify-js in /themes/common-theme/webapp/common-theme/js (#516)
Bumps [uglify-js](https://github.com/mishoo/UglifyJS) from 3.15.4 to 3.16.1.
- [Release notes](https://github.com/mishoo/UglifyJS/releases)
- [Commits](https://github.com/mishoo/UglifyJS/compare/v3.15.4...v3.16.1)

---
updated-dependencies:
- dependency-name: uglify-js
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-06-17 17:38:07 +02:00
Jacques Le Roux a88bd3b410 Improved: Update npm dependencies to the latest (OFBIZ-12596)
Dependabot does not support paths with "\" as in Windows
2022-06-17 15:44:20 +02:00
Jacques Le Roux 427bc85666 Improved: Update npm dependencies to the latest (OFBIZ-12596)
This supersedes the usage of npx npm-check-updates by automating npm things with Dependabot in GH
2022-06-17 15:28:15 +02:00
Nicolas Malin 59617b38ac Fixed: Service getNextOrderId failed if a customMethod is present (OFBIZ-12651)
When you generate an order on a party who have a PartyAcctgPreference with a customMethod orderSequence_enforced, the service failed due to the missing parameter partyAcctgPreference.

Like quote and invoice it's preferable to forward the partyAcctgPreference information.
2022-06-17 13:45:03 +02:00
Nicolas Malin 41dd06b72f Fixed: MenuItem doesn't follow correctly extended informations (OFBIZ-12628)
When you use two menus where the second extend the first, menu items and menu links aren't correctly propagated.

The menu items and menu links presents on the second menu already have the first menu on their model.

    ****
    <menu name="FirstMenu" extends="CommonInlineBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
        <menu-item name="MyItem">
            <link target="GoAction"/>
        </menu-item>
    </menu>
    <menu name="SecondMenu" extends="FirstMenu"/>
    ****

The result, if during the rendering some information are generated from the menu, in the previous case, it's always the "FirstMenu" that would be use.

Like when your menu generate a hidden-form, the SecondMenu link the bad form

    ****
    <form method="post" action="GoAction" onsubmit="javascript:submitFormDisableSubmits(this)" name="SecondMenu">...</form>
    <a href="javascript:ajaxSubmitFormUpdateAreas('FirstMenu', 'xxx')">MyItem</a>
    ****

To solve it and don't break the thread safe pattern, I introduce two new constructor for ModelItem and MenuLink for duplicate the ModelMenuItem and MenuLink in memory with the new parent. With this, the SecondMenu iw now completely duplicated on memory and now share any reference with the extended menu.

Thanks to Marco Rodrigues that detect this problem
2022-06-17 11:19:22 +02:00
Nicolas Malin 1042b0fc47 Fixed: Function ProductWorker.shippingApplies failed if chargeShipping is empty (OFBIZ-12649)
No functional change (correction on trunk already did by the OFBIZ-12609)

Condensing the code and remove unused errMsg variable.
2022-06-17 10:19:17 +02:00
Jacques Le Roux 84d30a5abc Improved: Unable to upload a file through ecommerce (OFBIZ-12636)
Allows to check for only CSV files. This is not used OOTB in OFBiz.

Thanks: Sachin for report and confirmation it's OK
2022-06-16 17:43:49 +02:00
Jacques Le Roux 26c209f8b4 Fixed: CategoryContentAssoc form vs. grid (OFBIZ-12641)
ScreenWidget links to form  but should be grid.

Thanks: Ingo Wolfmayr
2022-06-14 17:13:18 +02:00
Jacques Le Roux e4f1abfbdc Fixed: Wrong location for service updateContentSEOCategory (OFBIZ-12642)
Service has been moved to groovy but definition still links to minilang.

Thanks: Ingo Wolfmayr
2022-06-14 17:10:53 +02:00
Jacques Le Roux bf12a58826 Improved: updates codeQL to V2 as asked at
https://github.com/apache/ofbiz-framework/actions/runs/2479996158
2022-06-11 16:47:51 +02:00
Jacques Le Roux 658552e4fb Improved: Secure the uploads (OFBIZ-12080)
Few more debug log texts changes for clarity

I backport to ease future merging while backporting
2022-06-11 14:45:09 +02:00
Jacques Le Roux e3f5d31db1 Fixed: Secure the uploads (OFBIZ-12080)
Several changes in SecuredUpload class:
Mostly checks that uploaded CSV files are valid text files
Also few debug log texts changes for clarity
2022-06-11 11:09:26 +02:00
Jacques Le Roux 61645a72c4 Fixed: Unable to upload a file through ecommerce (OFBIZ-12636)
We need to upload a CSV format file as part of project requirement
We were able upload CSV format file under eCommerce in Version 16.11.07.
We are trying to implement the same in version 18.12.05 - there the same upload
module does not work.

jleroux: I missed to check and allow CSV files when all files are allowed.
That now uses:
https://commons.apache.org/proper/commons-csv/apidocs/org/apache/commons/csv/CSVFormat.html

The default CSV format used to check upload of CSV files is set in the property
csvformat=CSVFormat.DEFAULT in security.properties

Thanks: Sachin for report
2022-06-11 08:57:36 +02:00
Deepak Dixit 5e29578ad6 Fixed: Added missing notification tag entry in services.xsd file (OFBIZ-12635) 2022-06-09 15:28:24 +05:30
Michael Brohl d52ded8f54 Improved: Regular expression denial of service in jquery-validation
(OFBIZ-12634)
2022-06-07 22:32:49 +02:00
Michael Brohl a70342279f Improved: German Translation - Category (OFBIZ-12632)
Updates a few german translations for consistency.

Thanks Ingo Wolfmayr for reporting and providing the patch.
2022-06-07 21:27:58 +02:00
Jacques Le Roux ae146e02ef Improved: XML Import fails due to security check (OFBIZ-12602)
Hide the "Received a null Security object from HttpServletRequest" warning when
ControlFilter is in the StackTrace.
2022-06-07 12:04:05 +02:00
Jacques Le Roux 253515f3a5 Improved: Update Groovy to 2.5.17 (OFBIZ-12631)
This release includes 23 bug fixes/improvements as outlined in the changelog:
https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12318123&version=12351416
2022-06-03 12:03:06 +02:00
Jacques Le Roux 6e85417469 Improved: Some translation cosmetics (OFBIZ-12627)
Thanks: Ingo Wolfmayr
2022-06-02 09:42:27 +02:00
Jacques Le Roux 812aaae07c Fixed: [SECURITY] Upgrade Tika to 1.28.3 (OFBIZ-12626)
Apache Tika 1.28.3 contains security-related fixes and dependency upgrades.
Details can be found in the changes file:
https://www.apache.org/dist/tika/1.28.3/CHANGES-1.28.3.txt
2022-05-28 10:04:33 +02:00
Leila 3cc30333d0 Manage groovy DSL error message retrieval (OFBIZ-10692)
Add integration test to validate the good retrieval of the success /
error message.

Ajout de 4 services groovy pour tester le fonctionnement du moteur de service en groovy couplé a des appels de type DSL
2022-05-27 16:27:03 +02:00
Jacques Le Roux 088b22235d Improved: Json response failed when element not serializable (OFBIZ-12621)
No functional changes, just removing a compilation warning

While compiling with Java 11 I got this message:
> Task :compileJava
UtilHttp.java:502: warning: [unchecked] unchecked call to
<R>map(Function<? super T,? extends R>) as a member of the raw type Stream
[...]

This fixes it with the help of Eclipse
2022-05-26 12:24:49 +02:00
Jacques Le Roux b94b6aecaf Fixed: Webtools Service Logs ‘Service Name’ column always empty (OFBIZ-12625)
rs.getModelService().getName() should be used
instead of
rs.getModelService().name

The rest of changes is only non functional formatting and such

Thanks: Emad Radwan for reporting
2022-05-26 11:27:55 +02:00
Nicolas Malin 09cf6eb499 Improved: Redirect unauthenticated user to login on AJAX calls (OFBIZ-12620)
At this time when you aren't logged and you need to be authenticated for access to a page, OFBiz return the login page with a http code 200

This set a problem for ajax call to understand why the page returned isn't the attendee/

This improvement does 3 things :
   * return a HTTP status code 401 (Unauthorized) in LoginWorker::checkLogin if user is not authenticated (no more 200),
   * in common-theme, OfbizUtil.js, on AJAX calls handler, if the request fails with a 401 status code, reload current page (so we land on login form instead of being stuck in a blank modal) with a new search param `clickOn` containing the id of the link that triggered the AJAX call,
   * on page load, if `clickOn` search parameter exists, trigger a click event on the link, so the initial modal pops in after a successful login

Thanks to Florian Motteau for this improvement
2022-05-25 15:38:39 +02:00
Nicolas Malin 82f25f6192 Fixed: Json response failed when element not serializable (OFBIZ-12621)
When you forward a request-map on json response after a service call like this :

     <request-map uri="updateMyEntity">
        <security https="true" auth="true"/>
        <event type="service" invoke="serviceWithUnserializableElement"/>
        <response name="success" type="request" value="json"/>
        <response name="error" type="request" value="json"/>
    </request-map>

The request json works fine if the serviceWithUnserializableElement have an element unserializable on out put at the first level

     <service name="serviceWithUnserializableElement"...>
        <attribute name="outputStream" type="java.io.OutputStream" mode="OUT"/>
     </service>

If the definition is like this

     <service name="serviceWithUnserializableElement"...>
        <attribute name="outputStreamMap" type="Map" mode="OUT"/>
     </service>

The json failed to generate if the outputStream is a map. despite the function UtilHttp.getJSONAttributeMap that safe only the first map level and don't work in deep.

By the way, we improved the getJSONAttributeMap to work in deep by a recursive treatment on Map and List.
2022-05-25 14:35:36 +02:00
Nicolas Malin 4d035a554b Implemented: Configure invoice, quote and order templates for an organizational party (OFBIZ-10215) (OFBIZ-10216) (OFBIZ-10217)
Add the possibility to print invoice, quote and order as pdf from the organizational party configuration.

With this you can define your own xslfo template connected to a custom screen and configure it for each organization through PartyPrefDocTypeTpl

Thanks to Ingo Wolfmayr for patch submission
2022-05-25 13:59:41 +02:00
Jacques Le Roux 3f5536dc54 Tested: No status emails sent to commits@ofbiz.apache.org (INFRA-22689)
After migrating OFBiz BuildBot 0.8 config to 3.2 we no longer receive status
emails (success, failure, exception) to commits@ofbiz.apache.org (answering to
dev@ofbiz.apache.org)

Removes the commented out <<ProductStore storeName="OFBiz E-Commerce Store">>
to hopefully get a successful email from BuildBot

I modified the BuildBot config to test BuildBot sends only emails on status
changes
2022-05-24 17:11:25 +02:00
Jacques Le Roux c5acfa0892 Tested: No status emails sent to commits@ofbiz.apache.org (INFRA-22689)
After migrating OFBiz BuildBot 0.8 config to 3.2 we no longer receive status
emails (success, failure, exception) to commits@ofbiz.apache.org (answering to
dev@ofbiz.apache.org)

Comments out <<ProductStore storeName="OFBiz E-Commerce Store">> to get failing
tests and an email from BuildBot to later removes that to get a successful email

Thanks: Chris Lambertus for last change that always send an email. As sending
emails  works for "all" changes to "change" this to test what we are really
interested in.
2022-05-24 16:53:20 +02:00
Pierre Smits 5d8d7e9f55 Improved: Quote Search-Find - Consistency in UX (OFBIZ-12506) (#462)
Throughout the various components the screens to find a particular record (or multiple) are structured the same way with a decorator-screen called 'FindScreenDecorator' and in there decorator section for 'search-options' and 'search-results', bringing to the users a consistent experience.
The search and find functionality for quotes does not adhere to that paradigm.

modified: QuoteScreens.xml
restructured FindQuote screen to align with paradigm applied to the same vis-a-vis
searching and finding other kinds of records, additional cleanup.

jleroux: very minor changes to test INFRA-22689 "No status emails sent to commits@ofbiz.apache.org"
2022-05-24 11:18:42 +02:00
Jacques Le Roux 708a3b9afe Tested: No status emails sent to commits@ofbiz.apache.org (OFBIZ-22689)
After migrating OFBiz BuildBot 0.8 config to 3.2 we no longer receive status
emails (success, failure, exception) to commits@ofbiz.apache.org (answering to
dev@ofbiz.apache.org)

Removes the commented out <<ProductStore storeName="OFBiz E-Commerce Store">>
to hopefully get a successful email from BuildBot

Thanks:  Gavin McDonald for the work
2022-05-23 17:51:32 +02:00
Jacques Le Roux 7464332b2b Tested: No status emails sent to commits@ofbiz.apache.org (OFBIZ-22689)
After migrating OFBiz BuildBot 0.8 config to 3.2 we no longer receive status
emails (success, failure, exception) to commits@ofbiz.apache.org (answering to
dev@ofbiz.apache.org)

Comments out <<ProductStore storeName="OFBiz E-Commerce Store">> to get failing
tests and an email from BuildBot to later removes that to get a successful email

Thanks:  Gavin McDonald for the work
2022-05-23 17:37:03 +02:00
Pierre Smits c35aadbd59 Improved: Tracking Code menu-item (OFBIZ-12540) (#488)
Add a menu-item to create new Tracking Codes to the MainActionMenu of the Marketing application.

modified: MarketingMenus.xml
2022-05-23 15:21:35 +02:00
Pierre Smits 7973f09eb3 Improved: Have CommonProduct Label for use with LookupProduct function (OFBIZ-12542) (#492)
The LookupProduct function is used across various applications,
intended to assist users with the need to search, find and select
products in forms where one needs to be added or changed.
Also usable in overviews where a product is referenced.

modified: CommonUiLabels.xml
2022-05-22 11:55:42 +02:00
Jacques Le Roux 7a3504eb8a Improved: Required field not working on upload type form (OFBIZ-12619)
Fixes a checkstyle issue
2022-05-21 10:39:58 +02:00
Jacques Le Roux 869a1ea4e4 Fixed: Required field not working on upload type form (OFBIZ-12619)
When trying to submit an upload form with empty required fields, the validation
is not blocked and the submit is made.

Thanks: Leila Mekika
2022-05-21 10:35:11 +02:00
Jacques Le Roux bdf21f3450 Improved: Secure the uploads (OFBIZ-12080)
Attachments to order can be also documents. Accepting only images did not prevent
it, you can always bypass that, but it clarifies things.

Also improves the ContentUploadFileTypeNotMatch English label
2022-05-21 10:05:02 +02:00
Nicolas Malin 484063bb1d Improved: Helveticus, improve keyboard navigation on login page (OFBIZ-12622)
A few improvement to put directly the focus on username field when we arrive on login page for helveticus theme

Thanks to Marine Desmarchelier for this
2022-05-20 17:13:20 +02:00
Nicolas Malin a4cbdec636 Improved: Convert BlogServices.xml mini lang to groovy DSL (OFBIZ-12623)
Convert service createBlogEntry, updateBlogEntry, getBlogEntry and getOwnedOrPublishedBlogEntries from mini lang to
2022-05-19 20:53:38 +02:00
Jacques Le Roux 7abdb9e8ee Fixed: German Translation - Inv. Nr. (OFBIZ-12618)
Correct abbreviation of invoice number - german.

Thanks: Ingo Wolfmayr
2022-05-17 19:16:12 +02:00
Jacques Le Roux 118558239b Fixed: cssImgSmall css class definition missing in Helveticus Theme (OFBIZ-12617)
https://localhost:8443/catalog/control/EditCategory?productCategoryId=FOOD-001
Just upload an image - it will be displayed in full size. cssImageSmall css class
is defined in template but no definition is defined the theme.

Thanks: Ingo Wolfmayr
2022-05-17 19:10:31 +02:00
Jacques Le Roux 9152fbbdec Improved: ProductAssocs Screen confused (Helveticus Theme) (OFBIZ-12615)
Improve the location and look of the label about date/time entries

Thanks: Ingo Wolfmayr
2022-05-17 09:36:12 +02:00
Jacques Le Roux f66f856020 Fixed: Grid linked as form (agreement) (OFBIZ-12616)
ListCommissionAgreements is defined as grid but linked as form and therefore the
screen throws an error.

https://localhost:8443/catalog/control/ViewProductAgreements?productId=WG-9943

Thanks: Ingo Wolfmayr
2022-05-17 08:57:36 +02:00
Jacques Le Roux 592199ba86 Fixed: ProductAssocs Screen confused (Helveticus Theme) (OFBIZ-12615)
The ProductAssocs screen does not display as expected.
https://localhost:8443/catalog/control/EditProductAssoc?productId=WG-9943
This is caused by the tooltip syle (flex) defined for an info text that is used
on that screen.

Solution suggested : keep the text by just removing "style=tooltip".

Thanks: Ingo Wolfmayr
2022-05-16 18:30:04 +02:00
Jacques Le Roux 785ce5c956 Fixed: Grid linked as form (OFBIZ-12614)
ListFeaturePrice is defined as grid but linked as form and therefore the screen
throws an error.
https://localhost:8443/catalog/control/EditFeature?productFeatureId=1000

Thanks: Ingo Wolfmayr
2022-05-16 17:09:28 +02:00
Pierre Smits 188ae8795c Improved: Biling Account Payment - VIEW Permissions (#509)
When accessing
[https://localhost:8443/accounting/control/BillingAccountPayments?billingAccountId=9010]
as a user with only VIEW permissions (e.g. userid=auditor),
the screen shows a form to create a payment.
This should not be visible to such a user as it leads
to a undesired effect and diminished user experience.

modified: BillingAccountScreens.xml
reworked screen BillingAccountPayments to work with 
CREATE permissions
2022-05-13 09:58:18 +02:00
Pierre Smits 7177fea650 Fixed: Quote Edit - wrong decorator screen used (OFBIZ-12554) (#497)
Currently, the EditQuote screen in QuoteScreens.xml is using 'main-decorator' as the decorator-screen reference screen.
Because of this, the menus for the quote (being edited) are not shown to the user.

modified: QuoteScreens.xml
changed decorator-screen ref in screen EditQuote from 'main-decorator' to 'CommonQuoteDecorator
2022-05-12 14:39:17 +02:00
Jacques Le Roux 277b530338 Improved: Update sshd dependency and implementation (OFBIZ-12612)
Adds missing ASL2 license header
2022-05-10 10:39:37 +02:00
Gil Portenseigne edf58cfbb9 Improved: Update sshd dependency and implementation (OFBIZ-12612)
This commit fix an issue that, under high usage, redondant thread are
created.
Update sshd-core to 2.8.0, adding sshd-ftp since it has been separated in its own library.
Add SshClientHelper to hold the unique instance of SshClient.
Update SshFtpClient class to use the unique SshClient, manage the password/identity into the session and clean close the session.
2022-05-06 16:40:46 +02:00
Jacques Le Roux ad019a2217 Improved: Fixes typos 2022-05-05 19:36:03 +02:00
Pierre Smits 4caa0dce12 Fixed: GlSetupScreens.xml - MainActionMenu not shown (OFBIZ-12559) (#507)
The MainActionMenu of the Accounting component is
intended to provide the users with CREATE permissions
a direct way to create the main objects of the
Accounting components (Gl transaction, invoice,
payment), instead of - as such a user - have to go
through multiple screens to get to the action
trigger to create such objects.
The MainActionMenu is applied in various decorator
screens. It is, however, not applied in the
GlSetupScreen.xml file.

Modified: GlSetupScreens.xml
added pre-body decorator section, including ref to
MainActionMenu, to:
- screen ListCompanies
- screen AddCompany
- screen ImportExport
2022-05-04 18:05:09 +02:00
Pierre Smits 6244ad93ce Fixed: Party Main: duplicate action trigger (Person/Group) (OFBIZ-12560) (#508)
When accessing
https://localhost:8443/partymgr/control/main the
screen shows duplicate action triggers for the
creation of a new party of type=PERSON or
of type=PARTYGROUP.
These action triggers come from the MainActionMenu
for the a component, and from the 'CreateNewParty'
menu.

modified: PartyMenus.xml
removed from menu CreateNewParty:
- menu-item for the creation of a PartyGroup
- menu-item for the creation of a Person
as these already exists in the MainActionMenu of
the component.
2022-05-04 17:37:20 +02:00
Jacques Le Roux 8d8b66aadf Improved: Fix some bugs Spotbugs reports (OFBIZ-12386)
Renames SecuredUpload::isValidFile to isValidFileName
2022-05-04 08:09:24 +02:00
Jacques Le Roux 7c9d583e5c Fixed: ProductWorker getBoolean logic update (OFBIZ-12609)
If chargeShipping is null (default) the method ProductWorker.shippingApplies
fails.
GenericEntity::getBoolean has changed. If the passed value equals null, false is
returned. ProductWorker expects "null".

jleroux: GenericEntity::getBoolean has been changed for OFBIZ-12386 "Fix some
bugs SpotBugs reports". I checked at least that
"CommunicationEventServices::sendEmailToContactList handles correctly
tmpResult != null". After this fix I have to check other possible similar cases
I neglected. Fortunately, only trunk is concerned.

Thanks: Ingo Wolfmayr
2022-05-03 16:21:33 +02:00
Jacques Le Roux 5408ddb449 Improved: Secure the uploads (OFBIZ-12080)
I did not have these ones, found there
https://github.com/swisskyrepo/PayloadsAllTheThings/blob/master/Methodology%20and%20Resources/Reverse%20Shell%20Cheatsheet.md
and there https://github.com/tennc/webshell
2022-04-25 10:56:09 +02:00
Jacques Le Roux 428caa1026 Improved: German Translation - Marketing Pack (OFBIZ-12605)
Without this change two product types have the same name.

Thanks: Ingo Wolfmayr
2022-04-25 10:45:26 +02:00
Jacques Le Roux 6f890a656c To send Dependabot to securityML.
Syntax error in previous commit
2022-04-24 13:04:06 +02:00
Jacques Le Roux f57e35fe1f To send Dependabot to securityML.
Also try jira_options: link label, see
https://cwiki.apache.org/confluence/display/INFRA/Git+-+.asf.yaml+features#Git.asf.yamlfeatures-Jiranotificationoptions
2022-04-24 08:47:35 +02:00
Jacques Le Roux 1514824b7d Fixed: no functional changes, fixes chekstyle issues
Also adds javadoc task to GH actions, let's see if it works there.
2022-04-22 18:33:57 +02:00
Nicolas Malin 6f7f03b742 Fixed: RequestMap.event with type service multi doesn't work with dynamic url (OFBIZ-12604)
When you define a controller request-map with an event of type 'service-multi', if your uri contains multiple allocation like 'MyWay/MyAction' the class ServiceMultiEventHandler failed to execute with an EventHandlerException

 *****
    <request-map uri="Payment/QuickSend">
        ...
        <event type="service-multi" invoke="quickSendPayment"/>
        ...
 *****

The reason comes from the necessary to resolve the attribute global-transaction on event definition, and to do that a call to ConfigXMLReader is realized.

But unnecessary because we already have the event element on the context.
Use it directly, simplify the code and fix this issue
2022-04-22 16:09:53 +02:00
Nicolas Malin b3ee0ecc30 Fixed: In place editor wrong enable on display field (OFBIZ-12603)
When, on a form, you set a widget-style on a display field, you activate the inline editor without reason.
The issue comes from HtmlFormMacroLibrary.ftl that initialize some value in a span without control if it's necessary.
2022-04-22 15:31:50 +02:00
Nicolas Malin 4d0827503d Improved: Convert SubscriptionServices.xml service from mini-lang to groovy DSL (OFBIZ-12583)
Thanks to Leila Mekika for solve this issue
2022-04-22 13:43:00 +02:00
Jacques Le Roux bbe05496fb Improved: no functional change, fixes a Javadoc issue
SecurityUtil.java:91: error: unknown tag: String
     * @return List<String>
2022-04-22 12:31:53 +02:00
Jacques Le Roux 9f36c2dc86 Tested: GH Actions and Buildbot Builders are not consistent (OFBIZ-23076)
This is just a try Infra asked about. I have also asked montastic if we can
have 3 different badges. For now I simply backport this one in order to test
all the Buildbot flows.
2022-04-22 12:08:23 +02:00
Giulio Speri 58d05e2e43 Improved: notify message when adding a product to cart (OFBIZ-9521)
When a product is successfully added to the shopping cart, a notify
message is displayed with detail of the productId added.

Thanks Sourabh Punyani for your work.
2022-04-22 00:26:34 +02:00
Jacques Le Roux 389f90cbb6 Improved: Prevent possible DOS attack done using Java deserialisation (OFBIZ-12592)
The previous commit was twice wrong:
1. System properties in gradle.properties are not defined using -D but using
systemProp.
2. Anyway systemProp. is defining system properties only available in JVM where
Gradle is running, not the application you run. For that you need to use
applicationDefaultJvmArgs in application in the main build.gradle.

Here is the system property for jdk.serialFilter
2022-04-21 05:59:48 +02:00
Jacques Le Roux 3de52be907 Fixed: XML Import fails due to security check (OFBIZ-12602)
When importing an entity with "${" in for at least an element it's rejected
because of the security check done to protect from Freemarker unauth attacks
(see OFBIZ-12594).

As suggested by Ingo, allowing users with appropriate permissions seems an
usable solution. We still need to define the "appropriate permissions".
We can start with OFBTOOLS and WEBTOOLS, as it's reported by Ingo, and add
others later if they ever come.

Thanks: Ingo Wolfmayr for report and suggestion
2022-04-20 13:58:48 +02:00
Jacques Le Roux c4206b2806 Improved: GH Actions and Buildbot Builders are not consistent (INFRA-23076)
Lost comment about
https://lists.apache.org/thread/80wzf4kclfk5nh2fss56jd6otf7y4n2f
because of a rebase in previous commit
2022-04-18 09:43:39 +02:00
Jacques Le Roux d3eba54196 Improved: GH Actions and Buildbot Builders are not consistent (INFRA-23076)
Reverts previous commit,
see https://lists.apache.org/thread/80wzf4kclfk5nh2fss56jd6otf7y4n2f
2022-04-18 09:36:43 +02:00
Jacques Le Roux fa9a94ecf8 Improved: GH Actions and Buildbot Builders are not consistent (INFRA-23076)
It's now 2 weeks that INFRA-23076 is open, so like 3 weeks that BuildBot is not
working for OFBiz at all.

So far I did not run the integration tests on GH because
* we have it on BuildBot
* it's complicated to show the results

Hopefully BuildBot will soon run the OFBiz builds again. But it does not hurt
to run the integration tests on GH, even w/o the results, because at least it's
easier than running them for each commit locally (takes time) and we can run
them locally once we know there is a problem demonstrated with GH actions.
2022-04-18 08:57:07 +02:00
Giulio Speri bbc9e2fe9b Fixed: ecomm. listing ProductFacility out of stock issue (OFBIZ-12359)
In method filterOutOfStockProducts added case for "virtual" products.
In case a product isVirtual (= Y), then the available inventory count
(lastInventoryCount) is summed up on all its product variants, across
all the ProductFacility records, and then used to determine if the
(parent/virtual) product is in stock or out of stock.

This fix does not check if the facilityId of the ProductFacility
records retrieved is associated and enabled to the ProductStore.

Thanks Nicola Mazzoni for helping in anlyzing this issue.
2022-04-17 00:57:46 +02:00
Jacques Le Roux 20306613c7 Commit package-lock.json from Linux to see if it removes an issue Jacopo just told me 2022-04-14 13:45:41 +02:00
Jacopo Cappellato 1a567ed42e Improved: In UtilHttp, for regex processing of urls, replace Java regex with Google RE2J. (#512)
The Main advantage of RE2J is that it guarantees linear time execution.
2022-04-14 07:29:09 +02:00
Jacques Le Roux da45698dc5 Fixed: Test run was unsuccessful because of failing solr tests (OFBIZ-12595)
The previous commit for OFBIZ-12594 was only working on Windows. On *nix OSs
there is no way to reliably get "--test" String from java.class.path property.

Also the previous fix was brittle because relying only on 1 space separating
words.

This fix puts in the SolrDispatchFilter system property at the beginning of the
4 Solr tests and removes it at end of them. That presence can reliably be tested
in ControlFilter that is called before SolrDispatchFilter. It allows to bypass
SecurityUtil::containsFreemarkerInterpolation that would else change the
parameters content type that must be application/x-www-form-urlencoded.
content

Thanks: Tom Pietsch for report and Mart Naum for confirmation
2022-04-13 14:38:19 +02:00
Jacques Le Roux c7071d2431 Improved: updates package-lock.json for latest Uglify version 2022-04-13 10:35:36 +02:00
Jacques Le Roux 07eb980cab Improved: Update npm dependencies to the latest (OFBIZ-12597)
Updates:
jquery-migrate from 3.3.2 to 3.4.0
dompurify from 2.3.4 to 3.2.6
jquery-ui-dist from 1.13.0 to 1.13.1
2022-04-09 09:38:18 +02:00
Giulio Speri 08cd4d01be Fixed: inv. reservation places order if not enough qty (OFBIZ-12455)
If quantity not reserved is not 0, requireInventory is set to Y, system
let an order to be placed anyway.

The usage of the service around the project let make an important
assertion: we can consider that also reserveInventory flag of the
ProductStore is Y, since right now is always the caller context that
checks for the reserveInventory flag.

This fix simply returns a specific error to the caller, avoiding the
system to place the order.

Thanks Nicola Mazzoni for helping in debug this issue and Jacopo
Cappellato for the patch review.
2022-04-07 23:24:01 +02:00
Jacques Le Roux b063216cde Improved: Use NPM with gradle to get external JS dependencies (OFBIZ-11960)
Puts the Uglify script in package.json with an example of use for jquery.flot.js

The size diff between jquery.flot.js and jquery.flot.min.js is only 2%, so it's
more an example...

Note: to run the Uglify task alone use "gradlew npm_run_uglify"
2022-04-07 11:45:22 +02:00
Jacques Le Roux 6b44e97271 Revert "Revert "Tested: INFRA-23076""
This reverts commit 6c1265ca06.
Was not the last...
2022-04-07 10:20:25 +02:00
Jacques Le Roux 6c1265ca06 Revert "Tested: INFRA-23076"
This reverts commit 3369051768.

Another hopefully last test
2022-04-07 09:47:19 +02:00
Jacques Le Roux 3369051768 Tested: INFRA-23076
Just a fake change to test INFRA-23076
2022-04-07 09:24:31 +02:00
Jacques Le Roux d5f21f38b8 Tested: INFRA-23076
Just a fake change to test INFRA-23076
2022-04-06 15:14:36 +02:00
Jacques Le Roux b5370cbf51 Fixed: Prevent Freemarker interpolation in fields (OFBIZ-12594)
I did not catch an issue put in by this feature because BuildBot is not running
for few days (see INFRA-23076) and i don't always run tests locally (relying on
BuildBot and GH actions don't run tests).

This is the error Solr tests throw else:
<<Unfortunately, the stream was empty / not available. This may be caused by
another servlet filter calling ServletRequest.getParameter*() before
SolrDispatchFilter>>

Got an issue with previous commit (I guess confusion with 22.01)
2022-04-06 13:36:21 +02:00
Jacques Le Roux e5b0d63b65 Fixed: Prevent Freemarker interpolation in fields (OFBIZ-12594)
I did not catch an issue put in by this feature because BuildBot is not running
for few days (see INFRA-23076) and i don't always run tests locally (relying on
BuildBot and GH actions don't run tests).

This is the error Solr tests throw else:
<<Unfortunately, the stream was empty / not available. This may be caused by
another servlet filter calling ServletRequest.getParameter*() before
SolrDispatchFilter>>
2022-04-06 10:59:56 +02:00
Jacques Le Roux a3068004a1 Fixed: testInvoicePerShipmentSetFalse work with runtime configuration data (OFBIZ-12453)
UtilProperties::setPropertyValueInMemory was only based on files. Thinking by
analogy, as Pierre pushed SystemProperties with OFBIZ-6189, I thought that by
adding an UtilProperties::setPropertyValueInMemory based on
EntityUtilProperties::getProperties it would resolve the issue. But it did not.

Looking closer at the code, I wondered why UtilProperties::setPropertyValueInMemory
was used at all.

This fixes the issue by simply removing setPropertyValueInMemory and setting "Y"
or "N" when calling testInvoicePerShipment.

It though keeps the new UtilProperties::setPropertyValueInMemory variant
2022-04-06 09:31:30 +02:00
Jacques Le Roux 2aeb282cdc Improved: Prevent Freemarker interpolation in fields (OFBIZ-12594)
OFBIZ-12587 is a definitive solution to prevent any kind of Freemarker exploits.
But it's hard to realise because OFBiz exposes objects, like attributes from the
Servlet scopes. So in the meantime preventing Freemarker interpolation in fields
is a pragmatic solution.

This is an improvement but needs to be backported because it kinda affects
security
2022-04-04 08:04:39 +02:00
Jacques Le Roux 5d4dcd2ed4 Improved: just a tiny comment change in security.properties
Make clear that it's impossible to create a complete deniedWebShellTokens
2022-04-02 16:24:17 +02:00
Jacques Le Roux fcf0e456b6 Improved: no functional change, adds GitHub Actions build status emails.
As the name suggests, these are emails that notify of either a failed build
using GitHub Actions, or a change from failure in previous builds to a
successful build. Continuously successful builds will not trigger emails, as
that could be rather spammy.

Please see the documentation on this at: https://s.apache.org/asfyaml-gha
2022-04-02 13:12:31 +02:00
Jacques Le Roux 455bfbe8b8 Fixed: NullPointerException in plugin 'projectMgr' when listing TimeSheets (OFBIZ-12593)
The empty string causes a NullPointerException, because in the WidgetWorker
returns only an anchorElement  if the description of the hyperlink is not empty.

Solution:  If the anchorElement is null, the line is simply not executed:

Thanks: Tom Pietsch
2022-04-02 11:37:32 +02:00
Giulio Speri 691c74c66b Fixed: multiple facility inventory reservation issue (OFBIZ-12264)
The ProductStore is set up to reserve inventory from more than one
facility, so the flag oneInventoryFacility is set to N.
Flags requireInventory and reserveInventory are both to Y.
Flag allocateInventory is N.

A product can be anyway reserved in a ProductStoreFacility with its
thru date set and past, so is disabled, and if is not present enough
inventory quantity on other facilities.

Added filtering by date on multiple facility code in
reserveStoreInventoryMethod() and on isStoreInventoryAvailable().
This is the first part of the problem resolution; the second part is
accomplished by path to OFBIZ-12455 Jira.

Thanks: Jacques Le Roux and Pierre SMith for Jira feedbacks, Nicola
Mazzoni for helping in bug analaysis and Jacopo Cappellato for path
review.
2022-04-01 01:06:33 +02:00
kabutz 0e6732b526 Removed direct call to Class.newInstance() (#510) 2022-03-31 19:16:17 +02:00
Jacques Le Roux 54842fce0f Improved: no functional change, adds GitHub Actions build status emails.
As the name suggests, these are emails that notify of either a failed build
using GitHub Actions, or a change from failure in previous builds to a
successful build. Continuously successful builds will not trigger emails, as
that could be rather spammy.

Please see the documentation on this at: https://s.apache.org/asfyaml-gha
2022-03-29 13:43:28 +02:00
Jacques Le Roux 724ea1ffea Implemented: Restart the ofbiz-vm3 demos server (OFBIZ-22722)
For the next demo to work we need to set the host-headers-allowed to
demo-next.ofbiz.apache.org instead of demo-old.ofbiz.apache.org

Thanks to Drew Foulks for handling the Infra part for us
2022-03-28 18:47:17 +02:00
Jacques Le Roux cf7729157a Improved: Prevent possible DOS attack done using Java deserialisation (OFBIZ-12592)
Qing Xu, a security reporter, alerted us that, despite no current vulnerability,
it could be maybe possible to do DOS attacks using Java deserialisation.

That has been fixed with https://openjdk.java.net/jeps/290 and even implemented
in Java 8, but it needs a little effort on our side, here it is.

There is no real bug, to this is an improvement but a security improvement so it
will be backported

Thanks: Qing Xu for report
2022-03-28 12:36:32 +02:00
Jacques Le Roux 1af04a78a8 Improved: no functional change, updates text to say Git instead of SVN 2022-03-25 08:36:16 +01:00
Jacques Le Roux 9a52393829 Documented: Date picker not initialised in ajax-called form (OFBIZ-12097)
Just adds the missing Jira issue number. As it did not pass on trunk, just adds
a trailing spaces in XlsFormMacroLibrary.ftl
2022-03-20 14:47:11 +01:00
Jacques Le Roux 9a61ffddaa Fixed: Date picker not initialised in ajax-called form (OFBIZ-)
Initially wanting to make an useful commit to test changes I did to allow/fix
the stable RAT report rendering, I randomly picked ofbiz-12111. While working on
it I stumbled upon a wrong result when using example/control/ExampleReportXls.

That's due to isXMLHttpRequest="" missing in the renderDateTimeField macro
signature in XlsFormMacroLibrary.ftl. I added it there, and while at
it at other such signatures.

I initially made the renderDateTimeField macro signatures same then in
HtmlFormMacroLibrary.ftl, but finally decided to only add isXMLHttpRequest=""

Unfortunately this can be backported to 18.12 :D
2022-03-19 12:26:43 +01:00
Jacques Le Roux f49bb67662 Fixed: Secure the uploads (OFBIZ-12080)
Changes name="upload_file_type_bogus" in EditCategory.ftl and
EditProductContent.ftl to name="up_load_file_type_bogus"

The last line of deniedWebShellTokens in SecuredUpload and similarly in
SecurityUtilTest classes should no have a comma and anti-slash as previous lines.

Also logs when an image contains one of the token in deniedWebShellTokens
2022-03-17 18:09:35 +01:00
Jacques Le Roux 86703f0063 Fixed: PartyScreen include-form to include-grid (OFBIZ-12591)
In OFBIZ-11345 the include-form in SecurityForm.xml has been changed to grid.
There is a reference to a form in PartyScreen that has been changed to grid.

Thanks: Ingo Wolfmayr
2022-03-17 12:23:04 +01:00
Jacques Le Roux 38bbdf151b Improved: Change common webapp to common-theme (OFBIZ-12576)
Missed these changes one month ago
2022-03-16 13:07:29 +01:00
Michael Brohl c522a7efd7 Improved: Update to log4j 2.17.2 (OFBIZ-12590)
Contains bugfixes and improvements, see
https://logging.apache.org/log4j/2.x/changes-report.html#a2.17.2
2022-03-15 16:44:27 +01:00
Michael Brohl 9991c9ec63 Improved: Update Tomcat to Version 9.0.60 (OFBIZ-12589)
For changes see https://tomcat.apache.org/tomcat-9.0-doc/changelog.html
2022-03-15 12:05:47 +01:00
Jacques Le Roux 65ae69185c Fixed: Stored XSS in webappPath parameter from content/control/EditWebSite (OFBIZ-12584)
Adds "webappPath" token in deniedWebShellTokens to definitely fix this issue

Also adds "assign" token  for possible future Freemarker exploits
2022-03-13 21:10:21 +01:00
Jacques Le Roux 33fe2aaba5 Fixed: Remove _PREVIOUS_REQUEST_ Session Attribute on non-authentication pages (OFBIZ-12047)
Demo content website cmssite/cms could not be accessed because in this case
requestUri is null. Like login request it does not need auth, I did not dig
further, here is a simple fix.
2022-03-06 09:30:30 +01:00
Jacques Le Roux 0380ab85fd Fixed: Secure the uploads (OFBIZ-12080)
Removes non satisfying last line (because images may contain those strings) in
security.properties and SecurityUtilTest.java

In SecuredUpload, renames deniedFileExtensions and deniedWebShellTokens to
respectively getDeniedFileExtensions and getDeniedWebShellTokens
2022-03-03 17:22:50 +01:00
Jacques Le Roux 9bc5f2b4d4 Improved: no functional change, simple formatting 2022-02-28 18:33:08 +01:00
Jacques Le Roux cf72d425d3 Fixed: Secure the uploads (OFBIZ-12080)
Removes <svg, replaces by onload,build according to
https://portswigger.net/web-security/cross-site-scripting/cheat-sheet
2022-02-27 21:57:38 +01:00
Jacques Le Roux d45795b916 Fixed: Stored XSS in webappPath parameter from content/control/EditWebSite (OFBIZ-12584)
Adds <<",","+",',','+'>> to deniedWebShellTokens as an obviously non satisfying
(because images may contain those strings, I checked) temporary solution before
looking at Freemarker::WhitelistMemberAccessPolicy as suggested by Matei

Thanks to Matei "Mal" Badanoiu for reporting this post-auth vulnerabily
2022-02-27 18:24:20 +01:00
Jacques Le Roux 44534438af Fixed: Secure the uploads (OFBIZ-12080)
Just occurred to my mind that I forgot to lower case the tokens in
DENIEDWEBSHELLTOKENS when checking with SecuredUpload::isValidText
2022-02-27 15:42:10 +01:00
Jacques Le Roux 2752e4e16b Fixed: Stored XSS in webappPath parameter from content/control/EditWebSite (OFBIZ-12584)
A user with rights to modify and/or create websites may insert malicious HTML
elements in the “webappPath” parameter from content/control/EditWebSite
resulting in XSS.

In order to trigger the XSS a victim needs to navigate to main page of the
modified website (eg webpos or ecommerce) and interact with the malicious
HTML elements (eg trigger the “onmouseover” event by navigating with the mouse
over the “form” and/or “a” tags).

Thanks to Matei "Mal" Badanoiu for reporting this post-auth vulnerabily
2022-02-27 13:35:48 +01:00
Jacques Le Roux fe4cefd590 Improved: Reflected XSS in content component (OFBIZ-11840)
This was already fixed but we can do better by using SecuredUpload::isValidText

Also grabs some tokens to security.properties::deniedWebShellTokens from
DataEvents.java, and adds "alert" even it's harmless as is, as it's often used
by attackers to demonstrate issues, so will earn time.

Though an improvement, I backport as it's related to security
2022-02-27 12:00:39 +01:00
Jacques Le Roux 72405ab981 Fixed: Secure the uploads (OFBIZ-12080)
Checks that the content of SecuredUpload::isValidText is not null,
else returns false

Suspenders and belt type of fix.
2022-02-25 12:06:44 +01:00
Jacques Le Roux 53dc91aa0e Fixed: Prevent post-Auth vulnerability: FreeMarker Bypass (OFBIZ-12582)
By inserting malicious content in the “Text” field from
“/content/control/updateLayoutSubContent” -> “Templates”, an attacker may
perform SSTI (Server-Side Template Injection) attacks, which can leverage
FreeMarker exposed objects to bypass restrictions and obtain RCE (Remote Code
Execution).

This fixes it by calling SecuredUpload::isValidText on the “Text” field content.
I'll check that there are no other attack opportunities...

Thanks: Mal Aware <awaremal@gmail.com> for reporting this post-auth vulnerabily
2022-02-23 11:59:41 +01:00
Jacques Le Roux 835934a9c9 Fixed: Secure the uploads (OFBIZ-12080)
Adds some tokens in security.properties::deniedWebShellTokens
Updates SecurityUtilTest::webShellTokensTesting accordingly
2022-02-23 11:59:41 +01:00
Jacques Le Roux 6cb9b12df1 Fixed: Trivial change in ProgramExport.groovy, uses the SecuredUpload import
No Functional change
2022-02-23 11:59:41 +01:00
Benjamin Jugl f3a9f05a30 Improved: Remove Whitespaces before checkboxes (OFBIZ-10461) 2022-02-22 18:58:23 +01:00
Jacques Le Roux 7eec89d523 Fixed: Secure the uploads (OFBIZ-12080)
Fixes deniedWebShellTokens tests
2022-02-21 18:01:18 +01:00
Jacques Le Roux fac2485b2e Fixed: Secure the uploads (OFBIZ-12080)
Trivial change in DataServices.java: uses the SecuredUpload import in 2 places
it was missing.

Adds some tokens in security.properties::deniedWebShellTokens
Removes a duplicated htaccess in security.properties::deniedFileExtensions
2022-02-21 17:02:12 +01:00
Jacques Le Roux 3c9cd7139a Fixed: Secure the uploads (OFBIZ-12080)
Last commits put in an issue in DataServices.java and GroovyBaseScript.groovy.
I should have used SecuredUpload::isValidFileName with dataResourceName and
SecuredUpload::isValidFile  with objectInfo. This fixes that.

Also fixes formatting checkstyle issues in SecuredUpload class.

Also fixes formatting checkstyle issues in SecuredUpload class and move allow
all and check line length in right places (it's about content)
2022-02-20 15:43:43 +01:00
Jacques Le Roux b7f1d28142 Improved: Secure the uploads (OFBIZ-12080)
Manually merges SecuredUpload.java based on 18.12, 2nd time because of previous
commit :/
2022-02-19 11:58:10 +01:00
Jacques Le Roux 04e4433b78 Improved: Secure the uploads (OFBIZ-12080)
In security.properties, adds some deniedFileExtensions and improves few comments
(easier to merge later)

In  DataServices::createFileNoPerm filters file upload to verify the filename
before the content is checked if necessary
2022-02-19 11:45:15 +01:00
Jacques Le Roux 9b497d55cb Improved: Secure the uploads (OFBIZ-12080)
Manually merges SecuredUpload.java based on 18.12
2022-02-19 11:44:32 +01:00
Jacques Le Roux 30cb6da0b1 Fixed: Secure the uploads (OFBIZ-12080)
Prevents special bytes in filename
Adds some deniedFileExtensions
2022-02-18 18:35:09 +01:00
Jacques Le Roux 3f69a54891 Fixed: Secure the uploads (OFBIZ-12080)
Prevents billions laugh attacks
2022-02-18 15:45:07 +01:00
Jacques Le Roux 9a5e1c5efc Fixed: Secure the uploads (OFBIZ-12080)
In previous comment, to prevent linked images inside SVG I used xlink:href
That's no good, it must be followed by <<="http">>, this does it. Else a lot
of SVP images would not be loadable. Because xlink:href can be used in other
cases.
2022-02-18 15:32:31 +01:00
Jacques Le Roux 54e544d302 Improved: Create a deny list to reject webshell tokens (OFBIZ-12324)
Prevents CSV injection (MS Excel or Open Office)
2022-02-18 13:50:50 +01:00
Jacques Le Roux 756b5d237e Fixed: Secure the uploads (OFBIZ-12080)
Prevents
* too long lines (10 000) by default
* linked images inside SVG

Adds a comment about double extensions not allowed
2022-02-17 19:01:05 +01:00
Jacques Le Roux 0e83f09323 Improved: Error in uploading very large files, ie >2GB (OFBIZ-11534)
I reopened, forgot that you need to set -PjvmArgs, as I commented before:
<<For a 2GB+ file you need to set Xmx to more than the double of the file size,
eg: gradlew ofbiz -PjvmArgs="-Xms1024M -Xmx5048M">>

This also adds information in security.properties:
<<By default (OOTB) OFBiz is protected against Large File Denial of Service>>
2022-02-16 17:15:24 +01:00
Jacques Le Roux 887515beef Improved: no functional change, adds a logerror in ProgramExport.groovy
For a reason I did not find, this morning I did not receive any error message in
UI when the Groovy Program content was rejected for security reason.
So I added a logerror  message to be sure something will be reported in case
this issue popup again.

BTW I switched to 22.01 branch and it was OK, then back to trunk it was OK again,
weird :/
2022-02-15 14:11:33 +01:00
Jacques Le Roux 4fa50c87b7 Improved: Create a deny list to reject webshell tokens (OFBIZ-12324)
After reviewing https://github.com/nsacyber/Mitigating-Web-Shells this mostly
adds as tokens the "Linux applications commonly used by attackers and rarely
launched by benign Apache applications"
2022-02-15 07:54:17 +01:00
Jacques Le Roux 2e0a6e4f8c Improved: Create a deny list to reject webshell tokens (OFBIZ-12324)
OK, as ever I did not commit build.gradle because I have to have it
assume-unchanged with node.js version 13.14.0, I'm an outlaw
2022-02-14 13:41:06 +01:00
Jacques Le Roux 719ca41467 Improved: Create a deny list to reject webshell tokens (OFBIZ-12324)
After reviewing https://docs.oracle.com/cd/B14099_19/web.1012/b14014/jspxml.htm,
since we use "<jsp:" this removes "scriptlet>", "declaration>" and "expression>".
They are redundant with "<jsp:"; "<jsp:" covers those already.

Also adds eval( for js and shrinks base64_decode to decode, and processbuilder
to process because of OFBIZ 12571

I always test the denied tokens against a lib of  images with 33 600 elements (
3.99 GB). If an image contains the token it can't be in the denied list.
2022-02-14 13:16:55 +01:00
Jacques Le Roux 88b5c40fdb Improved: Change common webapp to common-theme (OFBIZ-12576)
Currently the ofbiz-component.xml in themes refers to 2 webapps common-theme and
images. The location of the former is location="webapp/common". At least on my
machine this creates, or has created, a local only common directory under themes
At some points (some months ago IIRW) I had to add a bunch of .gitgnore files
unders subdirs of this local only common directory.

I think it's better to have the location of the common-theme webapp at
webapp/common-theme. Hence the possible local only common directory under themes
disappears. Backend and frontend work fine. It's just some rename so should be
easy to revert if ever I miss something.
2022-02-14 13:03:18 +01:00
Jacques Le Roux d473e3f481 Improved: no functional format change
Formatting improvement in DataResourceWorker.java: removes a blank lines
2022-02-12 11:50:09 +01:00
Jacques Le Roux 0f804b86c8 Improved: Quote "Create New Quote Term" Button URL issues (OFBIZ-12551)
Just replaces CommonWorkEfforts that no longer exists by WorkEffortWorkEfforts
2022-02-12 11:29:53 +01:00
Jacques Le Roux 9c9c175c96 Improved: EditTrackingCode screen - duplicate action trigger (OFBIZ-12569)
When accessing
https://localhost:8443/marketing/control/EditTrackingCode?trackingCodeId=9000
the action trigger "Create Tracing Code" is duplicated.

Thanks: Pierre Smits for report
2022-02-12 11:28:13 +01:00
Jacques Le Roux 8792b05c73 Fixed: CLONE - [SECURITY] Upgrade Tika to 1.28.1 (OFBIZ-12573)
Simpler for now, later OFBIZ 12573 needs to be done

Thanks: Tim Allison <tallison@apache.org> for the nice exchanges :)
2022-02-12 10:37:42 +01:00
Jacques Le Roux b52091d4b9 Documented: Continue the common-theme upload (OFBIZ-9138 Create a common theme)
Removes 2 FIXMEs about locations for image.server.path and image.management.path
properties

This follows a message I sent to the user ML
https://lists.apache.org/thread/syysbhl99h0753h77hzd5frb50foclsq
that is:
<<Actually I was wrong when I said that "a feature was lost when common-theme was
put in". The rest is right. This feature is the possibility, through
image.server.path property in catalog.properties file, to place the images, and
other the static files as well, in a location that fits with you for
any reason. Notably following the NSA recommendation to place it in "a non-web
accessible area". This to prevent webshell uploads and all kind of
other malicious files uploads. The same is true for the other property
image.management.path.

So the fact that before common-theme was put in, with the folder for images
/themes/common/images/webapp/images/, this folder was
/framework/images/webapp/images/ has nothing to do with "a non-web accessible
area". That's you to decide...

There is also a ${tenantId} var used in image.server.path property that is used
in case of multi-tenant, that's another thing.

So I finally don't think it's necessary to put the images and image.management
in runtime. This would add nothing. I'll remove the FIXMEs>>

Thanks: APL+Win to help me format the message to 80 chars in a breeze :)
2022-02-11 19:42:49 +01:00
Jacques Le Roux 8aab702d8b Fixed: Quote "Create New Quote Term" Button URL issues (OFBIZ-12551)
When I open up a quote and go to add Quote Terms, the URL of the button matches
the New Role url.

jleroux: Note and workeffort have the same issue. No need to backport, this was
due to recent Pierre Smits's "improvement".

Also removes the OrderCreateOrderQuoteNote, no longer used anywhere.
OrderAddNote was rightly used by Pierre because it's more complete (just
<value xml:lang="de-CH">Neue Anmerkung zu Offerte erstellen</value> lost,
anyway I guess <value xml:lang="de">Anmerkung hinzufügen</value> fits more

Thanks: Justine Nowak for report
2022-02-11 12:06:37 +01:00
Jacques Le Roux 28092f2a75 Fixed: Groovy denied list bypass causes post-auth RCE from webtools/control/ProgramExport (OFBIZ-12571)
The 1st issue was due to use of processbuilder token. It has been added to
deniedWebShellTokens in security.properties by f2cf262 commit for OFBIZ 11948
The tokens function (for js) and class have been added since while browsing
https://github.com/tennc/webshell

As mention the related deniedWebShellTokens TODO comment: "TODO.... to be continued
with known webshell contents... a complete allow list is impossible anyway...

So, later a deeper review of Groovy sandbox possibilities will be done..

Thanks: Y4er for report
2022-02-11 10:52:43 +01:00
Jacques Le Roux 97b3627341 Improved: no functional changes, removes trailing spaces just to pass checkstyle
Check passed locally but not on GH nor BuildBot
2022-02-10 18:27:07 +01:00
Jacques Le Roux 1878e99a7b Improved: Possible authenticated attack related to Tomcat CVE-2020-1938 (OFBIZ-12558)
Change a bit the documentation while workin on
https://cwiki.apache.org/confluence/display/OFBIZ/Keeping+OFBiz+secure wiki page
2022-02-10 17:21:22 +01:00
Jacques Le Roux f2cf262cf5 Fixed: Remote Code Execution (File Upload) Vulnerability (OFBIZ-11948)
This fixes and improves file upload.

Refactor a bit SecuredUpload class and fixes:
Prevent double extensions
Check extensions
Improves getMimeTypeFromFileName() by checking is file exists
In isValidImageFile() finally use isValidText() bypassing encoding

Completely refactor deniedWebShellTokens in security.properties by re-adding
removed tokens in last commit and adding several new ones. I have still to check
encoded, encrypted and obfuscated webshells)
Modifies SecurityUtilTest::webShellTokensTesting accordingly
While at it better format commonsImagingSupportedFormats, deniedFileExtensions
and imagejSupportedFormats properties for legibility.

Check if createAnonFile service is used in GroovyBaseScript.groovy and if a
complete file name is used (file exist) check, using SecuredUpload, extensions
and prevent double extensions, actually check all the file and stop there.

Adds some "Check if a webshell is not uploaded" comments in
ContentManagementServices.java
DataServices.java
ScaleImage.java
FrameImage.java
ImageManagementServices.java
ProductServices.java
HttpRequestFileUpload.java
ProgramExport.groovy

Trivial comments fixes in catalog.properties

Also fixes OFBIZ 12571 (I use here a space because of pending INFRA 22843)
by simply adding processbuilder to deniedWebShellTokens
2022-02-10 14:17:34 +01:00
Jacques Le Roux ff5e473109 Improved: Possible authenticated attack related to Tomcat CVE-2020-1938 (OFBIZ-12558)
As reported by Michael, secretRequired value must be false because secret value
is empty. Else a notifying message appears in log saying that AJP is not available.

This uncomment out secretRequired, so its value is now false, and document more
notably about that. I'll later add more information in the
https://cwiki.apache.org/confluence/display/OFBIZ/Keeping+OFBiz+secure wiki page

Thanks: Michael for report
2022-02-10 14:17:34 +01:00
Jacques Le Roux 03359240f9 Improved: no functional trivial cleaning changes
Removes useless menu-name="secondary" for common-theme webapp
Removes now useless runtime/patches directory. It was only used with Ant
2022-02-10 14:17:34 +01:00
Jacques Le Roux aa1547314b Documented: Possible authenticated attack related to Tomcat CVE-2020-1938 (OFBIZ-12558)
Explains that the current AJP config works only for localhost
2022-02-10 14:17:33 +01:00
Pierre Smits 8c5100d83b Improved: Dutch labels (OFBIZ-10363)
WorkEffortUiLabels.xml
2022-02-07 14:14:36 +01:00
Jacques Le Roux 30770e1cea Fixed: Remote Code Execution (File Upload) Vulnerability (OFBIZ-11948)
In SecuredUpload::isValidImageFile I initially used isValidText() and thought
that decoding would be better so finally used isValidTextFile() instead. But
then valid images files are not passing. So this replaces isValidTextFile by
isValidText there.

Also while at it removes few other PHP tokens, now useless (hopefully, I have
still to check encoded and encrypted PHP webshells), from
security::deniedWebShellTokens. The less tokens we have the better the whole is
legible.
Improves related comments.

Modifies SecurityUtilTest::webShellTokensTesting accordingly
2022-02-05 10:13:44 +01:00
Jacques Le Roux 036a1fde29 Fixed: Remote Code Execution (File Upload) Vulnerability (OFBIZ-11948)
I forgot about SecurityUtilTest::webShellTokensTesting. This fixes it.

Note that I expect to simplify and remove more tokens for PHP, but I have 1st
other things to do...
2022-02-04 15:03:51 +01:00
Jacques Le Roux 5b1843f1c0 Fixed: Possible authenticated attack related to Tomcat CVE-2020-1938 (OFBIZ-12558)
Despite OFBIZ-11407, the 2 values secretRequired and especially
allowedRequestAttributesPattern are commented out because of OFBIZ-12558

The Tomcat default values will be used as recommended by
https://tomcat.apache.org/tomcat-9.0-doc/config/ajp.html#Introduction
This is in relation with
https://tomcat.apache.org/security-9.html#Fixed_in_Apache_Tomcat_9.0.31
and
https://tomcat.apache.org/tomcat-9.0-doc/security-howto.html#Connectors

Thanks: Lion Tree for report
2022-02-04 12:28:47 +01:00
Jacques Le Roux b0b02034ee Fixed: Remote Code Execution (File Upload) Vulnerability (OFBIZ-11948)
Lion Tree <liontree0110@gmail.com> has reported us that
"CVE-2020-1938 is not fully fixed".

Though it was fixed by OFBIZ-11407, it still possible for an authenticated user
to upload a webshell included in an image using one of the upload possibilities
in OFBiz. That is not new and covered by OFBIZ-12080 "Secure the uploads", but
was still incomplete.

This enforces the secured uploads by
* checking in SecuredUpload::isValidImageFile that a webshell is not embedded in
an image.
* Keeping only "<%" as a denied token for JSP webshells, instead of currently
"<%@ page"
* Adds "application/text/x-ruby" to SecuredUpload::isExecutable

Also
* Adds "<jsp", and "<?" for PHP. Even if OFBiz does not use PHP at all,
it's often installed on servers.
* Removes "import=\"java" and "runtime.getruntime().exec(". They are no
longer useful since "<%" and "<jsp" block them.
* Remove php token since I'll put "<?" in.
* Adds "#!", rather than adding other shebangs like perl,python and ruby

This will make deniedWebShellTokens more understandable.

But I'm conscious that despite SecuredUpload::isExecutableI I still need to
better handle encoded webshells. I'll do that soon in a second approach.

I'll also certainly more prune PHP related tokens.

Thanks: Lion Tree for report
2022-02-04 12:10:05 +01:00
Jacques Le Roux 6889ed1c9f Improved: no functional change, adds a BuildBot badge (INFRA-22807)
Better relies on ofbizTrunkFramework build rather than ofbizTrunkFrameworkPlugins
because the later depends on the former
2022-02-03 11:17:49 +01:00
Nicolas Malin c6e44d143f Fixed: Attribute default-field-type hidden doesn't work for auto-fields-service element (OFBIZ-12555)
Fix the compilation error on build bot that not support java11, downgrade the code to java8
2022-02-03 10:46:30 +01:00
Nicolas Malin 850a32df17 Reverted: Improved: no functional change, adds a BuildBot badge (INFRA-22807)
This reverts commit 884864b07f that contains a revert error of 9ea7afe97a
2022-02-03 10:46:10 +01:00
Jacques Le Roux 884864b07f Improved: no functional change, adds a BuildBot badge (INFRA-22807)
It works locally (once you have installed Ruby, asciidoctor and
asciidoctor-diagram). CHecking that it's also OK on BuildBot, let's see result
at https://nightlies.apache.org/ofbiz/trunk/readme/html5/
2022-02-03 09:53:55 +01:00
Nicolas Malin 9ea7afe97a Fixed: Attribute default-field-type hidden doesn't work for auto-fields-service element (OFBIZ-12555)
When you define a widget form and wish populate hidden fields with the element auto-fields-service, OFBiz rendering each as edit field type.

    <form name="ListPartyQuals" ...>
        <auto-fields-service service-name="updatePartyQual" default-field-type="hidden"/>
    </form>

The problem came from the function ModelFormFieldBuilder.induceFieldInfoFromServiceParam didn't manage the case "hidden"

By the way, this function is "if" forest, and simplify reading.
2022-02-02 18:07:37 +01:00
Jacques Le Roux 023a89e29e Fixed: View for ViewBinaryDataResource missing (OFBIZ-12552)
The view definition for ViewBinaryDataResource is missing.
Goto: /content/control/EditDataResource?dataResourceId=GZ-DIG
Click the "Download"-Button.

Thanks: Ingo Wolfmayr for the patch
2022-02-01 13:14:43 +01:00
Jacques Le Roux 418d6e03d4 Fixed: Manufacturing Jobshop find screen by default does not show all production runs (OFBIZ-12550)
The manufacturing jobshop find screen has the seach date initialized to nowdate.
if one wants to see all production runs, one has to clear the date which should
be empty initially

The same problem exists on the MRP log find where the date is filled by default.

Thanks: Hans for report and patches
2022-02-01 08:57:29 +01:00
Jacques Le Roux 9d4f29292e Fixed: [SECURITY] CVE-2022-23437: Infinite loop within Apache XercesJ xml parser (OFBIZ-12549)
Severity: high

Description:

There's a vulnerability within the Apache Xerces Java (XercesJ) XML
parser when handling specially crafted XML document payloads. This
causes, the XercesJ XML parser to wait in an infinite loop, which may
sometimes consume system resources for prolonged duration. This
vulnerability is present within XercesJ version 2.12.1 and the
previous versions.

Mitigation:

Apache XercesJ users, should migrate to version 2.12.2

Credit:

This issue was discovered by Sergey Temnikov and Ziyi Luo, from Amazon
Corretto/JDK Team

References:

https://markmail.org/message/vcmhwbuorfgcdr6l
2022-01-31 17:45:53 +01:00
Nicolas Malin d30d362aa6 Fixed: Element condition-[expr/list/object] doesn't work with compound (OFBIZ-12546)
When you create an entity-condition in a form or grid under a compound element, to write a valid xml you write it with the namespace like this :

    <wf:actions>
        <wf:entity-condition entity-name="PartyRelationship"...>
            <wf:condition-list>
                <wf:condition-expr field-name="partyIdFrom" from-field="parameters.partyIdFrom"/>
                <wf:condition-expr field-name="partyIdTo" from-field="parameters.partyIdTo"/>
            </wf:condition-list>
        </wf:entity-condition>
    </wf:actions>

This failed when OFBiz execute the search with error Invalid element with name '[wf:condition-expr]' found under a condition-list element.

The error came from the class EntityFinderUtil.ConditionList who analyze the condition-list's children with the namespace + node name instead take only the node name.

    if ("condition-expr".equals(subElement.getNodeName()))

To solve this issue we only check the local node name regardless from the namespace used.
2022-01-31 14:39:57 +01:00
Jacques Le Roux 7df68996a7 Fixed: Wrong Field Name Definition in RequirementForms (OFBIZ-12505)
The issue exists also in the older version.

The field "requirementByDate" form "FindApprovedProductRequirements" in
RequirementForms.xml has been set wrongly and it should be "requiredByDate".

This causes the result could not be queried out properly as indicated as below:

The result is governed by the service "getRequirementsForSupplier",
where reads the list from the view "RequirementAndRole".
In the view entity definition, the field is defined as
<alias entity-alias="RQ" name="requiredByDate"/>,
but it is not the case in the form "FindApprovedProductRequirements" above.

After changing it to the correct name, the bug is solved.

jleroux: Same exists in OrderEntryForms::FindRequirements

Thanks: Schumann Ye for report Pierre Smits for creating the initial PR494
2022-01-31 12:26:42 +01:00
Pierre Smits b1c0465202 Improved: List and Grid (OFBIZ-11345) (#495)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

modified:
PerfReviewScreens.xml.xml: from form ref to grid ref
PerfReviewForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
2022-01-31 11:52:15 +01:00
Pierre Smits 1f3229c3f9 Improved: List and Grid (OFBIZ-11345) (#467)
According to the definition in widget-form.xsd the
use of a combination of a form with type="list" is
deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.
Modified:
PersonTrainingForms.xml: from form definition with list
ref to grid definition with list ref, additional clean-up
EmployeeScreens.xml: from form ref to grid ref , additional cleanup
PersonTrainingScreens.xml: from form ref to grid ref , additional cleanup
2022-01-31 11:49:18 +01:00
Jacques Le Roux 7562476e1e Fixed: Attribute 'placeholder' is not allowed to appear in element 'text'
Completes the previous fix by Wei Zhang. This was committed at a wrong place
for OFBIZ-5341. Only text was concerned, not date-time
2022-01-29 10:56:15 +01:00
bjugl 90995f090f Fixed: Webapp Position overrides older entries. (OFBIZ-12496) (#454) 2022-01-28 10:25:11 +01:00
Pierre Smits b2dd912794 Improved: Recruitment screens updated to use Grid rather than list forms (OFBIZ-11345)
According to the definition in widget-form.xsd the
use of a combination of a form with type="list" is
deprecated in favour of a grid. Therefore refactored various
Recruitment forms to use grid and updated references from
relevant screens to forms.

Thanks: Pierre Smits for changes.
2022-01-28 07:49:01 +00:00
Daniel Watford 65dfc407cb Improved: Fix syntax error in package.json 2022-01-27 11:52:41 +00:00
Jacques Le Roux 3c1e659b5e Improved: no functional change, format package.json as done by Eclipse Json editor
Use 4 spaces indenting instead of 2, shared with std text editor
2022-01-27 11:54:34 +01:00
Daniel Watford acf0730c8d Reverted: Labels used for Customer Request Items (OFBIZ-12508) 2022-01-26 17:14:51 +00:00
Jacques Le Roux b16065c0bd Fixed: Upgrade Tomcat from 9.0.54 to 9.0.58 (OFBIZ-12539)
The fix for bug CVE-2020-9484 introduced a time of check, time of use
vulnerability that allowed a local attacker to perform actions with the
privileges of the user that the Tomcat process is using. This issue is only
exploitable when Tomcat is configured to persist sessions using the FileStore.

Note: because I'm a kind of outlaw (using deprecated Win 7) I must use node
13.14.0 and it causes me some issues, like the previous revert.
You can't have your cake and eat it
2022-01-26 13:07:50 +01:00
Jacques Le Roux 74b9146178 Fixed: Upgrade Tomcat from 9.0.54 to 9.0.58 (OFBIZ-12539)
Reverts changes in package.json accidentally committed
2022-01-26 12:52:28 +01:00
Jacques Le Roux 6ed30b7665 Fixed: Upgrade Tomcat from 9.0.54 to 9.0.58 (OFBIZ-12539)
The fix for bug CVE-2020-9484 introduced a time of check, time of use
vulnerability that allowed a local attacker to perform actions with the
privileges of the user that the Tomcat process is using. This issue is only
exploitable when Tomcat is configured to persist sessions using the FileStore.
2022-01-26 12:31:50 +01:00
Jacques Le Roux d57e889a6a Improved: Introduce the option to add the new Customer/Supplier while placing the quotes in system if they don't exist already (OFBIZ-7456)
Rather extends EditPartyGroup than creating a raw EditPartyGroup2
2022-01-26 08:50:32 +01:00
Jacques Le Roux f05bd47646 Improved: Have a Menu in Manufacturing featuring actions to create the main objects (OFBIZ-11782)
Fixes the use of commons label, specific labels are there for a reason!
2022-01-26 07:41:57 +01:00
Jacques Le Roux 986cb1357f Improved: Have a Menu in Accounting featuring actions to create the main objects (OFBIZ-11780)
Fixes the use of commons label, specific labels are there for a reason!
2022-01-26 07:41:03 +01:00
Jacques Le Roux 2f3f451a46 Improved: Have a Menu in Catalog featuring actions to create the main objects (OFBIZ-11774)
Fixes the use of commons label, specific labels are there for a reason!
2022-01-25 12:21:00 +01:00
Nicolas Malin 52c3e61a95 Improved: Use flexible expander to resolve the area target on call back (OFBIZ-12509)
When you use a callback, at this time we haven't to possibility to resolve the area target from the context like this

                <wm:link target="WorkEffortAgreement/delete">
                    ....
                    <wm:set-callback area-target="${useThisTarget}">
                       ...
                    </wm-setcallback>
                </wm:link>
2022-01-24 07:34:09 +01:00
Pierre Smits bbdeb09f67 Improved: Dutch labels (OFBIZ-10363)
A more complete/improved translation of labels increases the appeal of OFBiz.

Modified: CommonUiLabels.xml
improving dutch translations
2022-01-23 16:08:25 +01:00
Pierre Smits 9f978262f5 Improved: Maintenance (demo) dataset(s) (OFBIZ-12526)
Good (demo) data increases the appeal of OFBiz, making it easier for both user and contributor to understand how particular functions like screens, services, etc. (should) work.

modified: MarketingDemoData.xml
added demo data regarding sfa forecasts
2022-01-23 16:03:58 +01:00
Pierre Smits de8fb7fda9 Impoved: Moved new customer request item action to customer request menu (OFBIZ-12508) 2022-01-21 16:31:46 +00:00
Pierre Smits f444aa3477 Improved: dutch labels (OFBIZ-10363) (#465)
Added Dutch labels for Skill(s) (OFBIZ-10363)
2022-01-21 16:09:35 +00:00
Pierre Smits f1c9e0ef03 Improved: List and Grid (OFBIZ-11345) (#460)
* Improved: List and Grid (OFBIZ-11345)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.
Modified:
EntityForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
EntityScreens.xml: from form ref to grid ref , additional cleanup
EntitySyncForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
EntitySyncScreens.xml: from form ref to grid ref , additional cleanup
GeoManagementForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
GeoManagementScreens.xml: from form ref to grid ref , additional cleanup
ServiceForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
ServiceScreens.xml: from form ref to grid ref , additional cleanup
LogScreens.xml: from form ref to grid ref , additional cleanup

modified: ServiceScreens.xml
missed from form ref to grid ref in FindJobManagerLock
2022-01-21 13:36:20 +01:00
Pierre Smits c78c1f10e3 Improved: List and Grid (OFBIZ-11345) (#461)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified:
EmployeeForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
EmployeeScreens.xml: from form ref to grid ref , additional cleanup
2022-01-21 11:52:25 +01:00
Pierre Smits 1359cf8d44 Improved: List and Grid (OFBIZ-11345) (#459)
According to the definition in widget-form.xsd the
use of a combination of a form with type="list" is
deprecated in favour of a grid.

Refactor various list forms into grids.
Refactor various list form references in screens.

modified:
- SecurityForms.xml: from form definition with list
ref to grid definition with list ref, additional clean-up
- SecurityScreens.xml: from form ref to grid ref , additional cleanup
2022-01-21 10:06:49 +01:00
Pierre Smits ceac361521 Improved: List and Grid (OFBIZ-11345) (#458)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified
InventoryItemLabelForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
InventoryItemLabelScreens.xml: from form ref to grid ref , additional cleanup
2022-01-21 10:05:09 +01:00
Pierre Smits 76d53d1bbb Improved: list and grid (OFBIZ-11345) (#455)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified:
ReturnForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
OrderReturnScreens.xml: from form ref to grid ref , additional cleanup
2022-01-21 10:04:17 +01:00
Pierre Smits ee8a4008b5 Improved: List and Grid (OFBIZ-22345) (#453)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

modified:
- JobshopScreens.xml: from form definition with list ref to grid definition with list ref, additional clean-up
- ProductionRunForms.xml: from form ref to grid ref , additional cleanup
2022-01-21 10:02:51 +01:00
Jacques Le Roux 5fe736d828 Improved: improves a French label
"Report du devis" does not make sense "Etat du devis" is slightly better
2022-01-20 19:58:28 +01:00
Pierre Smits 609af860c8 Improved: Quote - Action Triggers, Permissions & ux (OFBIZ-12499) (#451)
* Improved: Quote - Action Triggers, Permissions & ux (OFBIZ-12499)

Currently, as can be seen in https://localhost:8443/ordermgr/control/ViewQuote?quoteId=CQ0001, action triggers (for users with CREATE/UPDATE permissions are located within screens instead of the action menu for quotes. Also triggers can be seen and invoked by users with VIEW permissions.

modified:
- OrderMenus.xml
added inQuoteSubTabBar menu-items for users with CREATE/UPDATE permissions (move from various quote screens), additional cleanup
- QuoteScreens.xml
added QuoteSubTabBar to CommonQuoteDecorator
moved quote label to above menus in CommonQuoteDecorator
removed QuoteSubTabBar from various quote screens
removed action triggers from various quote screens
additional cleanup, label harmonisation and ux consistency
- QuoteWorkEffortScreens.xml
removed action triggers from various quote screens
additional cleanup, label harmonisation and ux consistency

* Modify few labels to use larger descriptions
Co-authored-by: Jacques Le Roux <jacques.le.roux@les7arts.com>
2022-01-20 19:55:13 +01:00
Jacques Le Roux b3ae505714 Improved: Quote - Action Triggers, Permissions & ux (OFBIZ-12499)
Before sligtly modifying labels in OrderMenus.xml in PR451, here are few labels
enhancements.

Copies nl labels from CommonWorkEffort/s to WorkEffortWorkEffort/s
Removes duplicate and incomplete CommonWorkEffort/s labels in CommonUiLabels.
2022-01-20 19:53:27 +01:00
Pierre Smits f3775bde2d Improved: Request Roles - VIEW permissions (OFBIZ-12495) (#448)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the Request Roles screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
https://localhost:8443/ordermgr/control/requestroles?custRequestId=9000

Modified: CustRequestScreens.xml
- screen RequestRoles, restructured to work with permissions.
2022-01-20 13:25:36 +01:00
Pierre Smits 935dbbbb78 Improved: Move edit of Request to RequestSubTabBar (OFBIZ-12494) (#447)
In general, a <object>TabBar menu is intended to give users access to overviews related to the <object>. And a <object>SubTabBar menu is intended to give users access to actions to be performed on the <object>, like status changes, adding new related records, etc.
The menu-item for editing a request is currently located in the RequestTabBar menu in OrderMenus.xml.
Given that this menu-item is intended for users with UPDATE permissions and to give those users access to a screen to edit the data, this menu-item must move to the RequestSubTabBar menu.

modified: OrderMenus.xml
- menu RequestTabBar, removed menu-item editRequest (moved to RequestSubTabBar), additional cleanup
- menu RequestSubTabBar, added menu-item editRequest, added permission condition, additional cleanup
2022-01-20 13:21:44 +01:00
Pierre Smits f34a796857 Improved: Config Screen - VIEW permission (OFBIZ-12493) (#446)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the config item screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/catalog/control/EditProductConfigItem?configItemId=SC00000

modified:
- ConfigScreens.xml - restructured screen EditProductConfigItem to work with permissions
- ConfigForms.xml - added form ProductConfigItem for users with VIEW permission
2022-01-20 13:18:07 +01:00
Pierre Smits 761a56f23e Improved: Store Screen - VIIEW permission (OFBIZ-12492) (#445)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the store screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/catalog/control/EditProductStore?productStoreId=9000

mdified:
StoreScreens.xml - restructured screen EditProductStore to work with permissions
StoreFirms - added form ProductStore for users with VIEW permissions
2022-01-20 13:09:55 +01:00
Pierre Smits 81df0433bb Improved: Catalog Screen - VIEW permissions (OFBIZ-12491) (#444)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the catalog screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/catalog/control/EditProdCatalog?prodCatalogId=DemoCatalog

modified:
- CatalogScreens.xml
restructured screen EditProductCatalog vis-a-vis permissions
- ProdCatalogForms.xml
added form Catalog for users with VIEW permission
2022-01-20 13:08:19 +01:00
Pierre Smits 456df81cfe Improved: PaymentGroup Payments - VIEW permissions (OFBIZ-12502) (#457)
Currently, a user with only 'VIEW' permissions, as
demonstrated in trunk demo with userId = auditor,
accessing the Payment Group Payments screen, sees
editable fields and/or triggers (to requests)
reserved for users with 'CREATE' or 'UPDATE' permissions.

To see/test:
https://localhost:8443/accounting/control/EditPaymentGroupMember?paymentGroupId=9000

Modified: PaymentGroupScreens.xml
restructured screen ditPaymentGroupMember to work with permissions
2022-01-20 12:02:44 +01:00
Pierre Smits f6625639b5 Improved: Category Products - VIEW permissions (OFBIZ-12490) (#443)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the category products screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/catalog/control/EditCategoryProducts?productCategoryId=100

modified:
- CategoryScreens.xml
restructured EditCategoryProducts vis-a-vis permissions, additional cleanup
- CategoryForms.xml
added grid CategoryProducts for users with VIEW permissions
2022-01-20 12:00:27 +01:00
Pierre Smits 2a1438acc7 Improved: Product Prices - VIEW permissions (OFBIZ-12489) (#442)
* Improved: Product Prices - VIEW permissions (OFBIZ-12489)

Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the product prices screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/catalog/control/EditProductPrices?productId=WG-9943

Modified:
- ProductScreens.xml - restructured for working with permissions
- ProductForms.xml - added grid ProductPrices for users with VIEW permissions

* Improved: Product Prices - VIEW permissions (OFBIZ-12489)

Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the product prices screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/catalog/control/EditProductPrices?productId=WG-9943

modified: ProductForms.xml
added display type to fields
2022-01-20 11:56:03 +01:00
Pierre Smits 906f0637bb Improved: VIEW permissions - Agreement (OFBIZ-12488) (#441)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the agreement screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/accounting/control/EditAgreement?agreementId=DS-1000-SALES

Modified:
- AgreementScreens.xml
restructured EditAgreement screen regarding permissions, additional cleanup
- AgreementForms.xml
added form Agreement for users with VIEW permission, additional cleanup, label harmonisation
2022-01-20 11:54:12 +01:00
Pierre Smits b53d56f8eb Improved: VIEW permissions - BillingAccount roles (OFBIZ-12487) (#440)
Currently, a user with only 'VIEW' permissions, as demonstrated in trunk demo with userId = auditor, accessing the billing account roles screen, sees editable fields and/or triggers (to requests) reserved for users with 'CREATE' or 'UPDATE' permissions.
See (test with): https://localhost:8443/accounting/control/EditBillingAccountRoles?billingAccountId=9010

Modified:
BillingAccountScreens.xml, re EditBillingAccountRoles:
- added permission rules for CREATE/UPDATE
- restructured section and widget/fail-widget elements, additional cleanup
BillingAccountForms.xml
- added grid BillingAccountRoles (based on ListBillingAccountRoles)
- additional cleanup/label harmonisation
2022-01-20 11:47:36 +01:00
Jacques Le Roux 343438784c Improved: Use NPM with gradle to get external JS dependencies (OFBIZ-11960)
This replaces jquery-ui-timepicker-addon-1.6.3 by its equivalent from npm.

It should be noted that the 1.6.3 version is the EOL and
jquery-ui-timepicker-addon is no longer maintained.

Despite that according to
https://snyk.io/advisor/npm-package/jquery-ui-timepicker-addon
it's still a good choice, notably there are known no security issues.

I tried to use https://www.npmjs.com/package/jquery-datetimepicker instead
but crossed too much issues and let it go.
2022-01-20 10:11:24 +01:00
Pierre Smits 8c37ca2664 Improved: Move edit of Payment Group to SubTabBar (OFBIZ-12501) (#456)
In general, a <object>TabBar menu is intended to give
users access to overviews related to the <object>.
And a <object>SubTabBar menu is intended to give
users access to actions to be performed on the <object>,
like status changes, adding new related records, etc.
The menu-item for editing a payment group  is currently
located in the PaymentGroupTabBar menu in AccountingMenus.xml.
The menu item  belongs in the PaymentGroupSubTabBar

Improved: AccountingMenus.xml
PaymentGroupTabBar: removed menu item to edit the payment group, additonal cleanup
PaymentGroupSubTabBar: Added menu iteem to edit the payment group, additional cleanup
2022-01-18 15:48:14 +01:00
Pierre Smits 7787757d8f Improved: PaymentGroup - action items visible to viewer (OFBIZ-12486) (#439)
Menu items to perform actions in PaymentGroupSubTabBar are visible to users with only VIEW permissions. As shows when logged in with userId = auditor.

Modified: AccountingMenus.xml
added permissions rules to menu-items of PaymentGroupSubTabBar
2022-01-18 13:10:38 +01:00
Pierre Smits a4602d33fc Improved: Payment Group Common Decorator (OFBIZ-12463) (#438)
title of a payment group is shown below its menu(s)

Modified: CommonScreens.xml
- restructured CommonPaymentGroupDecorator, additional clean-up
2022-01-18 11:20:23 +01:00
Jacques Le Roux 495733f764 Improved: Use gradlew npm_outdated gradle-node-plugin taks to check outdated scripts (OFBIZ-12480)
Forgot to put back _form in OfbizUtil.js. THis is necessary for query-ui (1.13.0)
cf. OFBIZ-12480

Coincidentally removes trailing blanks
2022-01-18 10:43:26 +01:00
Jacques Le Roux d088f954b5 Improved: removes unused for 1,4 years CHANGELOG.adoc file
It can still be revivified from the Git log.
See https://lists.apache.org/thread/b9627b89zjc8qkym5kq2ycnh3cfllzlz for details
2022-01-17 13:38:29 +01:00
Pierre SmitsandJacques Le Roux 8fbc698542 Improved: Party - MainActionMenus (OFBIZ-12482) (#437)
* Improved: Party - MainActionMenus (OFBIZ-12482)

Currently the create buttons for the main objects of the party component are located within the find and other widgets/templates of those objects.
In order to improve the usability of OFBiz (and thus the appeal of it for adopters and users) these create buttons/links/etc. should be in a main action menu visible at all times when a user is working within the component.

Modified:
PartyMenus.xml: added MainActionMenu
CommonScreens.xml: included MainActionMenu where appropriate
CommunicationEventScreens.xml: included MainActionMenu where appropriate
PartyClassificationScreens.xml: included MainActionMenu where appropriate
PartyInvitationScreens.xml: included MainActionMenu where appropriate
VisitScreens.xml: included MainActionMenu where appropriate

* Uses PartyCreateNewPerson instead of CommonNew & CommonPerson

Co-authored-by: Jacques Le Roux <jacques.le.roux@les7arts.com>
2022-01-16 18:39:17 +01:00
Pierre Smits 4b19137635 Improved: List and Grid (OFBIZ-11345) (#436)
According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified:
InventoryForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
FacilityScreens.xml: from form ref to grid ref , additional cleanup
2022-01-16 15:11:10 +01:00
Pierre Smits 092f8f532a Improved: List and Grid (OFBIZ-11345) (#423)
According to the definition in widget-form.xsd the use of a combination of a
form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified:
SubscriptionScreens.xml: from form ref to grid ref , additional cleanup
SubscriptionForms.xml: from form definition with list ref to grid definition
with list ref, additional clean-up

jleroux: some modification after pushing previous commit from GH

In previous commit I noticed that Pierre used the CommonProduct label that I
committed for Pierre's "Adding som Dutch translations to common labels."
OFBIZ-6016

I did not notice then that there was already a more complete ProductProduct
label. I see no reason to create a new CommonProduct label. So I copied 2 lines
not present in ProductProduct from CommonProduct and removed the "nl" line that
is a duplicate of the "en" line.

With Michael we already said to Pierre that we don't like to review, before
pushing PR, not related changes mixed with what is announced by the title. It
complicates the review. I still remember being admonished by David E. Jones when
committing as a new committer doing the same. In the same David's spirit I see
no necessity to remove empty lines when it complicates the review...

Long story short, better make 2 different PR when such things is really
necessary...

I did not remove the <sub-hyperlink from communicationEventId lookup in
SubscriptionForms.xml. I checked there are 21 other cases like that in code.

Also better to remember to have lines not longer than 80 chars in commit comment.

All the rest is OK with me
2022-01-16 14:58:32 +01:00
Pierre Smits 5b909e41e2 Improved: List and Grid (OFBIZ-11345) (#423)
* Improved: List and Grid (OFBIZ-11345)

According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified:
SubscriptionScreens.xml: from form ref to grid ref , additional cleanup
SubscriptionForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up

* Improved: List and Grid (OFBIZ-11345)

According to the definition in widget-form.xsd the use of a combination of a form with type="list" is deprecated in favour of a grid.
Refactor various list forms into grids.
Refactor various list form references in screens.

Modified:
SubscriptionScreens.xml: from form ref to grid ref , additional cleanup
SubscriptionForms.xml: from form definition with list ref to grid definition with list ref, additional clean-up
2022-01-16 14:05:55 +01:00
Pierre Smits 1ba999e528 Improved: Routing (Task) Screens - consistency in ux (OFBIZ-12500) (#452)
Currently, when accessing screens related to production schemas and schema tasks (routing and routing tasks) in Manufacturing, the title of the shown object is below the menu items for that object (as shown in image attached).
To get to a more consistent user experience, this should be above the menu items for the object, like is done in many other screens in OFBiz.

modified: RoutingScreens.xml
CommonRoutingDecorator: moved title of object to above its menu, additional cleanup
CommonRoutingTaskDecorator: moved title of object to above its menu, additional cleanup
2022-01-16 12:00:09 +01:00
Jacques Le Roux d599d7718b Improved: no functional change, labels improvements
In French, and maybe other languages, there is not only one word for new.
There are nouveau (masculine), nouvelle (féminine) and nouvel (masculine followed
by a word starting with a vowel)

Here are few related changes with misc. labels, and use of these labels in
MainActionMenu of marketing order and catalog menus
2022-01-16 10:28:20 +01:00
Jacques Le Roux 8a9596be84 Improved: no functional change, labels improvements
In French, and maybe other languages, there is not only one word for new.
There are nouveau (masculine), nouvelle (féminine) and nouvel (masculine followed
by a word starting with a vowel)

Here are few related changes with existing AccountingUiLabels, HumanResUiLabel
changes and a new CommonUiLabels French labels improvements and use of
HumanResNew* labels in MainActionMenu of HumanresMenus.xml

Also alongside replaces tabs by spaces in HumanResUiLabel
2022-01-16 08:51:03 +01:00
Jacques Le Roux c3fa39ce8e Improved: no functional change, labels improvements
In French, and maybe other languages, there is not only one word for new.
There are nouveau (masculine), nouvelle (féminine) and nouvel (masculine followed
by a word starting with a vowel)

This takes that into account by using rather
ManufacturingNewRouting and ManufacturingNewRoutingTask than
uiLabelMap.CommonNew and uiLabelMap.ManufacturingRoutingn same for
ManufacturingNewRoutingTask

I'll certainly do more when possible (all cases are not traduced)
2022-01-15 13:51:07 +01:00
Jacques Le Roux 5115b9b29e Improved: no functional change, removes tests in GH actions
Adding testIntegration in the GH Gradle process does not work.

For a reason I'll not dig in, it ALWAYS fails at:
Cannot find service [indexProductsFromContent] location class
(org.apache.ofbiz.content.search.SearchServices)
2022-01-15 12:25:59 +01:00
Pierre Smits 52678afeae Improved: Routing Screens - remove redundant action triggers (OFBIZ-12497) (#449)
* Improved: Routing Screens - remove redundant action triggers (OFBIZ-12497)

With the inclusion of the MainActionMenu for the Manufacturing application, several screens in RoutingScreens.xml now have redundant and obsolete action triggers also available in the MainActionMenu.
These action triggers must be removed, as these don't adhere to common permission conventions or are redundant.

Modified: RoutingScreens.xml
- removed action triggers from various routing and routing task screens, as well as their surrounding style widget elements.
- additional clean-up

* Additional removal of trigger action
2022-01-15 12:09:15 +01:00
Pierre Smits 0f77436a53 Improved: Invoice Screens = consistency in ux (OFBIZ-12498) (#450)
The majority of the invoice screens have grids encapsulated by a screenlet widget with a title. However some do not have this.

Modified: InvoiceScreens.xml
- screen InvoiceRoles - have grids in screenlet with title
- screen InvoiceTerms - have grids in screenlet with title
2022-01-15 10:50:04 +01:00
Jacques Le Roux fcf7c725c0 Improved: no functional change, add tests to GH actions
Buildbot is stale at the moment and it's better to not rely only on it.
This adds testIntegration to the GH Gradle process
2022-01-15 10:01:12 +01:00
Jacques Le Roux a5dc85c2a5 Tested: no functional change; just change VERSION to check BB config
With last commits BB config for R22 is stale
Back to 2022-01-01 when things worked
To test last schedulers changes
2022-01-14 09:41:26 +01:00
Jacques Le Roux afa56b0d24 Tested: no functional change; just change VERSION to check BB config
BB config for R22 is stale, checking trunk is still OK
2022-01-13 15:27:25 +01:00
Jacques Le Roux 0202b2b090 Fixed: Use NPM with gradle to get external JS dependencies (OFBIZ-11960)
Reverts build.gradle from previous commit ("Updates flot from 0.8.2 to 4.2.2
using npm"). It was mistakenly pushed then :/
2022-01-11 08:40:20 +01:00
706 changed files with 3913 additions and 4546 deletions
+6
View File
@@ -16,6 +16,8 @@
github:
description: "Apache OFBiz is an open source product for the automation of enterprise processes. It includes framework components and business applications for ERP, CRM, E-Business/E-Commerce, Supply Chain Management and Manufacturing Resource Planning. OFBiz provides a foundation and starting point for reliable, secure and scalable enterprise solutions."
homepage: https://ofbiz.apache.org/
dependabot_alerts: true
dependabot_updates: false
labels:
- ofbiz
- plugins
@@ -29,3 +31,7 @@ github:
- https
- content
- geospatial
notifications:
jobs: notifications@ofbiz.apache.org
jira_options: link label
+26
View File
@@ -0,0 +1,26 @@
# 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.
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
version: 2
updates:
- package-ecosystem: "npm" # See documentation for possible values
directory: "themes/common-theme/webapp/common-theme/js" # Location of package manifests
schedule:
interval: "daily"
+3 -3
View File
@@ -57,7 +57,7 @@ jobs:
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
debug: true
@@ -69,7 +69,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1
uses: github/codeql-action/autobuild@v2
# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
@@ -83,4 +83,4 @@ jobs:
# make release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
uses: github/codeql-action/analyze@v2
+6 -3
View File
@@ -32,11 +32,14 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Set up JDK 1.8
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 1.8
java-version: 11
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew pullAllPluginsSource check
run: ./gradlew pullAllPluginsSource check javadoc
# Below does not work, see see https://lists.apache.org/thread/80wzf4kclfk5nh2fss56jd6otf7y4n2f
# - name: Builds with Gradle, checks style and run integration tests (just to know if they pass)
# run: ./gradlew pullAllPluginsSource check javadoc loadAll testIntegration
-2
View File
@@ -1,2 +0,0 @@
[[apache-ofbiz-framework-changelog]]
= Apache OFBiz Framework Changelog
+1 -1
View File
@@ -6,7 +6,7 @@ your business.
System requirements
The only requirement to run OFBiz is to have the Java Development Kit (JDK)
version 8 installed on your system (not just the JRE, but the full JDK) which
version 11 installed on your system (not just the JRE, but the full JDK) which
you can download from the below link. Make sure of setting the $JAVA_HOME
environment variable.
+2 -2
View File
@@ -209,10 +209,10 @@ For details, see framework/resources/fonts/NotoSans/.
=========================================================================
This product bundles "timezones" files, which are available in the "Public Domain".
For details, see themes/common/webapp/common/js/plugins/date/timezones.
For details, see themes/common/webapp/common-theme/js/plugins/date/timezones.
=========================================================================
This product bundles "jQuery Input Mask plugin", which is available
under the "MIT" license.
For details, see themes/common-theme/webapp/common/js/jquery/plugins/inputmask/jquery.inputmask*
For details, see themes/common-theme/webapp/common-theme/js/jquery/plugins/inputmask/jquery.inputmask*
+1 -1
View File
@@ -1,6 +1,6 @@
DESCRIPTION
This file contains information about libraries that are supported
by code in OFBiz but that are left out of SVN because of licensing issues.
by code in OFBiz but that are left out of Git because of licensing issues.
What is below is a list of jar files and where to put them, and the file(s)
to change to include them in the OFBiz build and/or run-time configuration.
+7 -4
View File
@@ -22,9 +22,11 @@ The Apache OFBiz Project
image:https://img.shields.io/badge/License-Apache%202.0-blue.svg[link=http://www.apache.org/licenses/LICENSE-2.0]
image:https://img.shields.io/badge/Version-trunk-blue.svg[link=https://github.com/apache/ofbiz-framework]
image:https://ci2.apache.org/badges/ofbizTrunkFramework.svg[link=https://ci2.apache.org/badges/ofbizTrunkFramework.svg]
image:https://github.com/apache/ofbiz-framework/actions/workflows/gradle.yaml/badge.svg?branch=trunk[link=https://github.com/apache/ofbiz-framework/actions/workflows/gradle.yaml]
image:https://sonarcloud.io/api/project_badges/measure?project=apache_ofbiz-framework&metric=alert_status[link=https://sonarcloud.io/dashboard?id=apache_ofbiz-framework]
image:https://github.com/apache/ofbiz-framework/actions/workflows/codeql-analysis.yml/badge.svg[link=https://github.com/apache/ofbiz-framework/actions/workflows/codeql-analysis.yml]
image:https://qpkb254zxeu.montastic.io/badge[link=https://qpkb254zxeu.montastic.io]
If you are reading this file in AsciiDoc format you may want to see it at
https://nightlies.apache.org/ofbiz/trunk/readme/html5/[HTML]
@@ -68,7 +70,7 @@ ________________________________________________________________________________
The only requirements to run OFBiz is
* to have the Java Development Kit (JDK) version 8 installed on your system
* to have the Java Development Kit (JDK) version 11 installed on your system
(not just the JRE, but the full JDK) that you can download from the below link.
Make sure of setting the $JAVA_HOME environment variable. +
https://adoptopenjdk.net/[JDK download].
@@ -95,7 +97,7 @@ the command line at the OFBiz top level directory (folder).
MS Windows: `init-gradle-wrapper`
[IMPORTANT]
====
* If you cross the error
* If you cross the error
[quote]
____
"Powershell is not recognized as an internal or external command, operable program or batch file"
@@ -166,7 +168,8 @@ Once proper mitigations to the security issues are complete the OFBiz team will
disclose this information to the public mailing list.
* If you find a post-auth security issue, please https://s.apache.org/dsj2p[create a bug in our issue tracker (Jira)] .
* If you want to use AJP on a non localhost OFBiz instance, you need to set the value of allowedRequestAttributesPattern
in framework/catalina/ofbiz-component.xml
You can find more information about security in OFBiz at
https://cwiki.apache.org/confluence/display/OFBIZ/Keeping+OFBiz+secure[Keeping OFBiz secure]
@@ -834,7 +837,7 @@ options:
* Search for the JDBC driver in https://bintray.com/bintray/jcenter[jcenter] and
place it in build.gradle dependencies e.g.
`runtime 'mysql:mysql-connector-java:5.1.36'`
`runtime 'mysql:mysql-connector-java:8.0.30'`
+
OR
* Download the JDBC driver jar and place it in $OFBIZ_HOME/lib or the lib
+1 -1
View File
@@ -1 +1 @@
Trunk
Trunk
@@ -7312,7 +7312,7 @@
<property key="AccountingInvNr">
<value xml:lang="ar">رقم الفاتورة</value>
<value xml:lang="cs">Číslo faktury</value>
<value xml:lang="de">Inv.Nr</value>
<value xml:lang="de">Rg.Nr</value>
<value xml:lang="en">Inv.Nr</value>
<value xml:lang="es">Nr.Fact</value>
<value xml:lang="es-CL">Factura N°</value>
@@ -22296,7 +22296,7 @@
<value xml:lang="de">Hauptbuch Transaktion</value>
<value xml:lang="en">a Gl Transaction</value>
<value xml:lang="es">uno Transaccione GL</value>
<value xml:lang="fr">une opération comptable</value>
<value xml:lang="fr">une transaction comptable</value>
<value xml:lang="ja">GLトランザクション</value>
<value xml:lang="pt">Transaçõe contábei</value>
</property>
@@ -48,6 +48,6 @@ under the License.
systemPropertyValue="Y"
description="Create a 'not-paid' payment record if the sales order is completed and no payment exist yet. Options:: Y, N"/>
<!-- <SystemProperty systemResourceId="accounting" systemPropertyId="create.invoice.per.shipment" systemPropertyValue="Y"
description="create invoice per shipment. Options: = Y (Invoice per shipment), N (Invoice per order)"/> -->
<SystemProperty systemResourceId="accounting" systemPropertyId="create.invoice.per.shipment" systemPropertyValue="Y"
description="create invoice per shipment. Options: = Y (Invoice per shipment), N (Invoice per order)"/>
</entity-engine-xml>
@@ -19,6 +19,7 @@
package org.apache.ofbiz.accounting
import javax.servlet.http.HttpSession
import org.apache.ofbiz.base.util.UtilProperties
import org.apache.ofbiz.base.util.UtilValidate
import org.apache.ofbiz.entity.GenericValue
@@ -142,49 +143,43 @@ public class InvoicePerShipmentTests extends OFBizTestCase {
}
void testInvoicePerShipmentSetFalse() {
/* Test Invoice Per Shipment
Step 1) Set create.invoice.per.shipment=N in accounting.properties file.
Step 2) Create order and approve order.
Step 3) Pack Shipment For Ship Group.
Step 4) Check invoice should not created.
*/
UtilProperties.setPropertyValueInMemory("accounting", "create.invoice.per.shipment", "N")
logInfo("===== >>> Set Accounting.properties / create.invoice.per.shipment = N")
List invoices = testInvoicePerShipment("GZ-1000", null)
Step 1) Set create.invoice.per.shipment=N in accounting.properties file.
Step 2) Create order and approve order.
Step 3) Pack Shipment For Ship Group.
Step 4) Check invoice should not created.
*/
List invoices = testInvoicePerShipment("GZ-1000", "N")
assert UtilValidate.isEmpty(invoices)
}
void testInvoicePerShipmentSetTrue() {
/* Test Invoice Per Shipment
Step 1) Set create.invoice.per.shipment=Y in accounting.properties file.
Step 2) Create order and approve order.
Step 3) Pack Shipment For Ship Group.
Step 4) Check invoice should be created.
Step 1) Set create.invoice.per.shipment=Y in accounting.properties file.
Step 2) Create order and approve order.
Step 3) Pack Shipment For Ship Group.
Step 4) Check invoice should be created.
*/
UtilProperties.setPropertyValueInMemory("accounting", "create.invoice.per.shipment", "Y")
logInfo("===== >>> Set Accounting.properties / create.invoice.per.shipment = Y")
List invoices = testInvoicePerShipment("GZ-1000", null)
List invoices = testInvoicePerShipment("GZ-1000", "Y")
assert UtilValidate.isNotEmpty(invoices)
}
void testInvoicePerShipmentSetOrderFalse() {
/* Test Invoice Per Shipment
Step 1) Create order and set invoicePerShipment=N.
Step 2) Pack Shipment For Ship Group.
Step 3) Check invoice should not be created.
*/
Step 1) Create order and set invoicePerShipment=N.
Step 2) Pack Shipment For Ship Group.
Step 3) Check invoice should not be created.
*/
List invoices = testInvoicePerShipment("GZ-2644", "N")
assert UtilValidate.isEmpty(invoices)
}
void testInvoicePerShipmentSetOrderTrue() {
/* Test Invoice Per Shipment
Step 1) Create order and set invoicePerShipment=Y
Step 2) Pack Shipment For Ship Group.
Step 3) Check invoice should be created.
*/
Step 1) Create order and set invoicePerShipment=Y
Step 2) Pack Shipment For Ship Group.
Step 3) Check invoice should be created.
*/
List invoices = testInvoicePerShipment("GZ-2644", "Y")
assert UtilValidate.isNotEmpty(invoices)
}
}
}
@@ -63,7 +63,7 @@ under the License.
<parameter param-name="organizationPartyId"/>
</link>
</menu-item>
<menu-item name="NewInvoice" title="${uiLabelMap.CommonCreate} ${uiLabelMap.CommonInvoice}">
<menu-item name="NewInvoice" title="${uiLabelMap.AccountingCreateNewInvoice}">
<condition>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
@@ -688,38 +688,53 @@ under the License.
</link>
</menu-item>
</menu>
<menu name="PaymentGroupTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
<menu-item name="PaymentGroupOverview" title="${uiLabelMap.AccountingPaymentTabOverview}">
<link target="PaymentGroupOverview">
<parameter param-name="paymentGroupId" from-field="paymentGroup.paymentGroupId"/>
</link>
</menu-item>
<menu-item name="EditPaymentGroup" title="${uiLabelMap.CommonGroup}">
<condition><not><if-empty field="paymentGroup.paymentGroupId"/></not></condition>
<link target="EditPaymentGroup">
<parameter param-name="paymentGroupId" from-field="paymentGroup.paymentGroupId"/>
</link>
</menu-item>
<menu-item name="EditPaymentGroupMember" title="${uiLabelMap.AccountingGroupMembers}">
<menu-item name="EditPaymentGroupMember" title="${uiLabelMap.CommonPayments}">
<condition><not><if-empty field="paymentGroup.paymentGroupId"/></not></condition>
<link target="EditPaymentGroupMember">
<parameter param-name="paymentGroupId" from-field="paymentGroup.paymentGroupId"/>
</link>
</menu-item>
</menu>
<menu name="PaymentGroupSubTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml"
menu-container-style="button-bar button-style-2">
<menu-item name="createNew" title="${uiLabelMap.CommonCreate}" widget-style="buttontext create">
<condition>
<not><if-empty field="paymentGroup"/></not>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
</or>
<not><if-empty field="paymentGroup"/></not>
</and>
</condition>
<link target="EditPaymentGroup"/>
</menu-item>
<menu-item name="EditPaymentGroup" title="${uiLabelMap.CommonEdit}">
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
<not><if-empty field="paymentGroup"/></not>
</and>
</condition>
<link target="EditPaymentGroup">
<parameter param-name="paymentGroupId" from-field="paymentGroup.paymentGroupId"/>
</link>
</menu-item>
<menu-item name="depositSlip" title="${uiLabelMap.AccountingDepositSlip}">
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
<if-compare field="display" operator="equals" value="true"/>
<if-compare field="paymentGroup.paymentGroupTypeId" operator="equals" value="BATCH_PAYMENT"/>
<not><if-empty field="paymentGroupMembers"/></not>
@@ -732,6 +747,10 @@ under the License.
<menu-item name="printCheck" title="${uiLabelMap.AccountingPrintChecks}">
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
<if-compare field="display" operator="equals" value="true"/>
<if-compare field="paymentGroup.paymentGroupTypeId" operator="equals" value="CHECK_RUN"/>
<not><if-empty field="paymentGroupMembers"/></not>
@@ -744,6 +763,10 @@ under the License.
<menu-item name="cancelpaymentGroup" title="${uiLabelMap.AccountingCancelBatchPayments}">
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
<not><if-empty field="paymentGroupMembers"/></not>
<not><if-empty field="paymentGroup"/></not>
<if-empty field="glReconciliationId"/>
@@ -757,6 +780,10 @@ under the License.
<menu-item name="cancelCheckRunPayments" title="${uiLabelMap.AccountingCancelCheckRun}">
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
<not><if-empty field="paymentGroupMembers"/></not>
<not><if-empty field="paymentGroup"/></not>
<if-compare field="paymentGroup.paymentGroupTypeId" operator="equals" value="CHECK_RUN"/>
@@ -767,7 +794,6 @@ under the License.
</link>
</menu-item>
</menu>
<menu name="FixedAssetMaintTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml"
selected-menuitem-context-field-name="tabButtonItemFixedAssetMaint" default-menu-item-name="EditFixedAssetMaint">
<menu-item name="EditFixedAssetMaint" title="${uiLabelMap.AccountingFixedAssetMaint}">
@@ -25,6 +25,19 @@ under the License.
<!-- generate a PDF for the invoice. Sharing the same script file as the HTML page for viewing invoice -->
<screen name="InvoicePDF">
<section>
<actions>
<set field="defaultTemplateLocation" value="component://accounting/widget/AccountingPrintScreens.xml"/>
<set field="defaultTemplateName" value="DefaultInvoicePDF"/>
<script location="component://commonext/groovyScripts/template/DocTypeTemplate.groovy"/>
</actions>
<widgets>
<include-screen name="${templateName}" location="${templateLocation}"/>
</widgets>
</section>
</screen>
<screen name="DefaultInvoicePDF">
<section>
<actions>
<property-map resource="AccountingUiLabels" map-name="uiLabelMap" global="true"/>
@@ -99,7 +99,6 @@ under the License.
</hyperlink>
</field>
</grid>
<form name="EditAgreement" type="single" target="updateAgreement" title="" default-map-name="agreement"
header-row-style="header-row" default-table-style="basic-table">
<alt-target use-when="agreement==null" target="createAgreement"/>
@@ -136,7 +135,33 @@ under the License.
<submit button-type="button"/>
</field>
</form>
<form name="Agreement" type="single" default-map-name="agreement"
header-row-style="header-row" default-table-style="basic-table">
<auto-fields-service service-name="updateAgreement" default-field-type="display" map-name="agreement"/>
<field name="agreementId" title="${uiLabelMap.CommonId}"><display/></field>
<field name="agreementTypeId" title="${uiLabelMap.CommonType}" position="2"><display-entity entity-name="AgreementType"/></field>
<field name="agreementDate" title="${uiLabelMap.CommonDate}"><display type="date-time"/></field>
<field name="productId" title="${uiLabelMap.CommonProduct}">
<display-entity entity-name="Product" key-field-name="productId" description="${internalName}"/>
</field>
<field name="partyIdFrom" title="${uiLabelMap.AccountingPartyIdFrom}">
<display-entity also-hidden="false" entity-name="PartyNameView"
key-field-name="partyId" description="[${partyId}] ${groupName}${firstName} ${lastName}"/>
</field>
<field name="partyIdTo" title="${uiLabelMap.AccountingPartyIdTo}" position="2">
<display-entity entity-name="PartyNameView"
key-field-name="partyId" description="[${partyId}] ${groupName}${firstName} ${lastName}"/>
</field>
<field name="roleTypeIdFrom" title="${uiLabelMap.AccountingRoleTypeIdFrom}">
<display-entity entity-name="RoleType" key-field-name="roleTypeId" description="[${roleTypeId}] ${description}"/>
</field>
<field name="roleTypeIdTo" title="${uiLabelMap.AccountingRoleTypeIdTo}" position="2">
<display-entity entity-name="RoleType" key-field-name="roleTypeId" description="[${roleTypeId}] ${description}"/>
</field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display type="date-time"/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}" position="2"><display type="date-time"/></field>
<field name="statusId" title="${uiLabelMap.CommonStatus}"><display-entity entity-name="StatusItem"/></field>
</form>
<grid name="ListAgreementItems" list-name="agreementItems" target="" title="" paginate-target="ListAgreementItems"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<auto-fields-entity entity-name="AgreementItem" default-field-type="display"/>
@@ -131,17 +131,33 @@ under the License.
<set field="helpAnchor" value="_help_for_edit_agreement"/>
<set field="agreementId" from-field="parameters.agreementId"/>
<entity-one entity-name="Agreement" value-field="agreement"/>
</actions>
<widgets>
<decorator-screen name="CommonAgreementDecorator" location="${parameters.agreementDecoratorLocation}">
<decorator-section name="body">
<screenlet title="${uiLabelMap.PageTitleEditAgreement}">
<include-form name="EditAgreement" location="component://accounting/widget/AgreementForms.xml"/>
</screenlet>
<platform-specific>
<html><html-template location="component://accounting/template/agreement/CopyAgreement.ftl"/></html>
</platform-specific>
<section>
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
</and>
</condition>
<widgets>
<screenlet title="${uiLabelMap.PageTitleEditAgreement}">
<include-form name="EditAgreement" location="component://accounting/widget/AgreementForms.xml"/>
</screenlet>
<platform-specific>
<html><html-template location="component://accounting/template/agreement/CopyAgreement.ftl"/></html>
</platform-specific>
</widgets>
<fail-widgets>
<screenlet id="agreement">
<include-form name="Agreement" location="component://accounting/widget/AgreementForms.xml"/>
</screenlet>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
@@ -185,18 +185,18 @@ under the License.
</actions>
<auto-fields-service service-name="updateBillingAccountRole" default-field-type="edit"/>
<field name="billingAccountId"><hidden/></field>
<field name="partyId" title="${uiLabelMap.PartyPartyId}">
<field name="partyId" title="${uiLabelMap.CommonParty}">
<display-entity entity-name="PartyNameView" description="${firstName} ${middleName} ${lastName} ${groupName}">
<sub-hyperlink description="${partyId}" target="/partymgr/control/viewprofile" target-type="inter-app" link-style="buttontext">
<parameter param-name="partyId"/>
</sub-hyperlink>
</display-entity>
</field>
<field name="roleTypeId" title="${uiLabelMap.PartyRoleTypeId}">
<field name="roleTypeId" title="${uiLabelMap.CommonRole}">
<display-entity entity-name="RoleType"/>
</field>
<field name="fromDate" title="${uiLabelMap.CommonFromDate}"><display/></field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display type="date-time"/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}"><date-time/></field>
<field name="submitButton" title="${uiLabelMap.CommonUpdate}" widget-style="smallSubmit"><submit button-type="button"/></field>
<field name="deleteLink" title=" " widget-style="buttontext">
<hyperlink description="${uiLabelMap.CommonDelete}" target="deleteBillingAccountRole" also-hidden="false">
@@ -207,19 +207,43 @@ under the License.
</hyperlink>
</field>
</grid>
<grid name="BillingAccountRoles" list-name="billingAccountRoleList"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar"
paginate-target="EditBillingAccountRoles" separate-columns="true">
<actions>
<entity-condition entity-name="BillingAccountRole" list="billingAccountRoleList">
<condition-expr field-name="billingAccountId" from-field="billingAccountId"/>
<order-by field-name="roleTypeId"/>
</entity-condition>
</actions>
<field name="billingAccountId"><hidden/></field>
<field name="partyId" title="${uiLabelMap.CommonParty}">
<display-entity entity-name="PartyNameView" description="${firstName} ${middleName} ${lastName} ${groupName}">
<sub-hyperlink description="${partyId}" target="/partymgr/control/viewprofile" target-type="inter-app" link-style="buttontext">
<parameter param-name="partyId"/>
</sub-hyperlink>
</display-entity>
</field>
<field name="roleTypeId" title="${uiLabelMap.CommonRole}">
<display-entity entity-name="RoleType"/>
</field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display type="date-time"/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}"><display type="date-time"/></field>
</grid>
<form name="AddBillingAccountRole" type="single" target="createBillingAccountRole" default-map-name="billingAccountRole"
header-row-style="header-row" default-table-style="basic-table">
<auto-fields-service service-name="createBillingAccountRole"/>
<field name="billingAccountId"><hidden/></field>
<field name="roleTypeId" title="${uiLabelMap.PartyRoleTypeId}">
<field name="roleTypeId" title="${uiLabelMap.CommonRole}">
<drop-down allow-empty="false" no-current-selected-key="BILL_TO_CUSTOMER">
<entity-options entity-name="RoleType">
<entity-order-by field-name="description"/>
</entity-options>
</drop-down>
</field>
<field name="fromDate"><date-time default-value="${nowTimestamp}"/></field>
<field name="partyId" title="${uiLabelMap.PartyPartyId}" required-field="true"><lookup target-form-name="LookupPartyName"/></field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><date-time default-value="${nowTimestamp}"/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}"><date-time/></field>
<field name="partyId" title="${uiLabelMap.CommonParty}" required-field="true"><lookup target-form-name="LookupPartyName"/></field>
<field name="submitButton" title="${uiLabelMap.CommonAdd}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<grid name="ListBillingAccountTerms" list-name="billingAccountTermsList" default-entity-name="BillingAccountTerm" paginate-target="EditBillingAccountTerms"
@@ -169,17 +169,32 @@ under the License.
<set field="headerItem" value="billingaccount"/>
<set field="tabButtonItem" value="EditBillingAccountRoles"/>
<set field="helpAnchor" value="_help_for_billing_account_roles"/>
<set field="billingAccountId" from-field="parameters.billingAccountId"/>
<entity-one entity-name="BillingAccount" value-field="billingAccount"/>
</actions>
<widgets>
<decorator-screen name="CommonBillingAccountDecorator" location="${parameters.billingAccountDecoratorLocation}">
<decorator-section name="body">
<screenlet id="BllingAccountRolePanel" title="${uiLabelMap.PageTitleAddBillingAccountRoles}" collapsible="true">
<include-form name="AddBillingAccountRole" location="component://accounting/widget/BillingAccountForms.xml"/>
</screenlet>
<include-grid name="ListBillingAccountRoles" location="component://accounting/widget/BillingAccountForms.xml"/>
<section>
<condition>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
</condition>
<widgets>
<screenlet id="BllingAccountRolePanel" title="${uiLabelMap.PageTitleAddBillingAccountRoles}" collapsible="true">
<include-form name="AddBillingAccountRole" location="component://accounting/widget/BillingAccountForms.xml"/>
</screenlet>
<screenlet>
<include-grid name="ListBillingAccountRoles" location="component://accounting/widget/BillingAccountForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
<include-grid name="BillingAccountRoles" location="component://accounting/widget/BillingAccountForms.xml"/>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
@@ -290,9 +305,16 @@ under the License.
<widgets>
<decorator-screen name="CommonBillingAccountDecorator" location="${parameters.billingAccountDecoratorLocation}">
<decorator-section name="body">
<screenlet id="BillingAccountPaymentPanel" title="${uiLabelMap.AccountingCreatePayment}" collapsible="true">
<include-form name="CreateIncomingBillingAccountPayment" location="component://accounting/widget/BillingAccountForms.xml"/>
</screenlet>
<section>
<condition>
<if-has-permission permission="ACCOUNTING" action="CREATE"/>
</condition>
<widgets>
<screenlet id="BillingAccountPaymentPanel" title="${uiLabelMap.AccountingCreatePayment}" collapsible="true">
<include-form name="CreateIncomingBillingAccountPayment" location="component://accounting/widget/BillingAccountForms.xml"/>
</screenlet>
</widgets>
</section>
<include-grid name="ListBillingAccountPayments" location="component://accounting/widget/BillingAccountForms.xml"/>
</decorator-section>
</decorator-screen>
@@ -30,7 +30,6 @@ under the License.
<property-map resource="WorkEffortUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="ManufacturingUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
<set field="layoutSettings.companyName" from-field="uiLabelMap.AccountingCompanyName" global="true"/>
<set field="layoutSettings.companySubtitle" from-field="uiLabelMap.AccountingCompanySubtitle" global="true"/>
<!-- layoutSettings.headerImageUrl can be used to specify an application specific logo; if not set,
@@ -104,7 +103,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="CommonPaymentDecorator">
<section>
<actions>
@@ -126,7 +124,6 @@ under the License.
</decorator-section>
<decorator-section name="body">
<section>
<!-- do check for ACCOUNTING, _VIEW permission -->
<condition>
<if-service-permission service-name="acctgBasePermissionCheck" main-action="VIEW"/>
</condition>
@@ -153,7 +150,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="CommonPaymentGroupDecorator">
<section>
<actions>
@@ -176,29 +172,21 @@ under the License.
</and>
</condition>
<widgets>
<label style="h1">${uiLabelMap.AccountingPaymentGroup}: ${paymentGroupId}</label>
<include-menu name="PaymentGroupTabBar" location="component://accounting/widget/AccountingMenus.xml"/>
<include-menu name="PaymentGroupSubTabBar" location="component://accounting/widget/AccountingMenus.xml"/>
</widgets>
<fail-widgets>
<label style="h1">${uiLabelMap.AccountingNewPaymentGroup}</label>
</fail-widgets>
</section>
</decorator-section>
<decorator-section name="body">
<section>
<!-- do check for ACCOUNTING, _VIEW permission -->
<condition>
<if-service-permission service-name="acctgBasePermissionCheck" main-action="VIEW"/>
</condition>
<widgets>
<section>
<condition>
<not><if-empty field="paymentGroup"/></not>
</condition>
<widgets>
<include-menu name="PaymentGroupSubTabBar" location="component://accounting/widget/AccountingMenus.xml"/>
<label style="h1">${uiLabelMap[titleProperty]} ${uiLabelMap.CommonFor} ${paymenGroup.paymentGroupName} [${paymentGroupId}]</label>
</widgets>
<fail-widgets>
<label style="h1">${uiLabelMap.AccountingNewPaymentGroup}</label>
</fail-widgets>
</section>
<decorator-section-include name="body"/>
</widgets>
<fail-widgets>
@@ -210,7 +198,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="CommonPartyDecorator">
<section>
<actions>
@@ -243,7 +230,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="CommonOrganizationAccountingReportsDecorator">
<section>
<actions>
@@ -263,7 +249,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="CommonAdminChecksDecorator">
<section>
<actions>
@@ -284,7 +269,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="main">
<section>
<condition>
@@ -325,7 +309,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="creditCardFields">
<section>
<widgets>
@@ -333,7 +316,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="GlobalGLSettingsDecorator">
<section>
<actions>
@@ -352,7 +334,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="CommonInvoiceDecorator"><!-- used for invoice commission runs -->
<section>
<widgets>
@@ -360,5 +341,4 @@ under the License.
</widgets>
</section>
</screen>
</screens>
@@ -67,6 +67,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://accounting/widget/AccountingMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<screenlet title="${uiLabelMap.AccountingAvailableInternalOrganizations}" navigation-menu-name="NewAccountOrganization">
<include-menu name="NewAccountOrganization" location="component://accounting/widget/AccountingMenus.xml"/>
@@ -84,6 +87,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://accounting/widget/AccountingMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<screenlet title="${uiLabelMap.AccountingNewCompany}">
<include-form name="AddCompany" location="component://accounting/widget/GlSetupForms.xml"/>
@@ -103,6 +109,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://accounting/widget/AccountingMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<screenlet title="${uiLabelMap.AccountingInvoice} ${uiLabelMap.CommonImportExport} ${uiLabelMap.CommonFor}: ${partyGroup.groupName} [${organizationPartyId}]">
<container style="lefthalf">
@@ -710,12 +710,12 @@ under the License.
<screenlet id="PartyInvoiceRolePanel" title="${uiLabelMap.AccountingPartyRoleAdd}" collapsible="true">
<include-form name="EditInvoiceRole" location="component://accounting/widget/InvoiceForms.xml"/>
</screenlet>
<screenlet>
<screenlet title="${uiLabelMap.CommonRoles}">
<include-grid name="ListInvoiceRoles" location="component://accounting/widget/InvoiceForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
<screenlet>
<screenlet title="${uiLabelMap.CommonRoles}">
<include-grid name="InvoiceRoles" location="component://accounting/widget/InvoiceForms.xml"/>
</screenlet>
</fail-widgets>
@@ -765,10 +765,14 @@ under the License.
</screenlet>
</widgets>
</section>
<include-grid name="ListInvoiceTerms" location="component://accounting/widget/InvoiceForms.xml"/>
<screenlet title="${uiLabelMap.PartyTerms}">
<include-grid name="ListInvoiceTerms" location="component://accounting/widget/InvoiceForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
<include-grid name="InvoiceTerms" location="component://accounting/widget/InvoiceForms.xml"/>
<screenlet title="${uiLabelMap.PartyTerms}">
<include-grid name="InvoiceTerms" location="component://accounting/widget/InvoiceForms.xml"/>
</screenlet>
</fail-widgets>
</section>
</decorator-section>
@@ -93,12 +93,30 @@ under the License.
<widgets>
<decorator-screen name="CommonPaymentGroupDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<screenlet name="listPaymentGroupMember" title="${uiLabelMap.AccountingPaymentGroupMembers}" collapsible="true">
<include-form name="ListPaymentGroupMember" location="component://accounting/widget/PaymentGroupForms.xml"/>
</screenlet>
<screenlet name="addPaymentGroupMember" title="${uiLabelMap.AccountingAddPaymentGroupMember}" collapsible="true">
<include-form name="AddPaymentGroupMember" location="component://accounting/widget/PaymentGroupForms.xml"/>
</screenlet>
<section>
<condition>
<and>
<or>
<if-has-permission permission="ACCOUNTING" action="_CREATE"/>
<if-has-permission permission="ACCOUNTING" action="_UPDATE"/>
</or>
<not><if-empty field="paymentGroupId"/></not>
</and>
</condition>
<widgets>
<screenlet name="listPaymentGroupMember" title="${uiLabelMap.CommonPayments}" collapsible="true">
<include-form name="ListPaymentGroupMember" location="component://accounting/widget/PaymentGroupForms.xml"/>
</screenlet>
<screenlet name="addPaymentGroupMember" title="${uiLabelMap.AccountingAddPaymentGroupMember}" collapsible="true">
<include-form name="AddPaymentGroupMember" location="component://accounting/widget/PaymentGroupForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
<screenlet name="listPaymentGroupMember" title="${uiLabelMap.CommonPayments}" collapsible="true">
<include-form name="PaymentGroupMembers" location="component://accounting/widget/PaymentGroupForms.xml"/>
</screenlet>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
@@ -0,0 +1,70 @@
package org.apache.ofbiz.common.template
/*
* 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.
*/
import org.apache.ofbiz.entity.GenericValue
import org.apache.ofbiz.entity.model.ModelUtil
def getFieldTypeName(String entityName) {
return ModelUtil.lowerFirstChar(entityName) + 'Id'
}
/**
* For a entityTypeName and a value return the matching templating document screen
* If no value found, do a recursive search on parentType
*/
def getCustomScreenTemplate(String entityTypeName, String fieldTypeValue) {
if (! fieldTypeValue) {
return null
}
GenericValue tplCustScreen = from("PartyPrefDocTypeTplAndCustomScreen")
.where(getFieldTypeName(entityTypeName), fieldTypeValue)
.cache()
.queryFirst()
if (tplCustScreen) {
return tplCustScreen
}
// No template found for this type, try if the parent had
String parentTypeValue = from(entityTypeName).where().cache().queryFirst().parentTypeId
return getCustomScreenTemplate(entityTypeName, parentTypeValue)
}
// first resolve the document reference passed on the context
String entityName = ""
String entityTypeName = ""
if (parameters.orderId) {
entityName = "OrderHeader"
entityTypeName = "OrderType"
} else if (parameters.invoiceId) {
entityName ="Invoice"
} else if (parameters.quoteId) {
entityName = "Quote"
}
// second ask for this entity the custom screen to use
GenericValue tplCustScreen
if (entityName) {
entityTypeName = entityTypeName ?: entityName + 'Type'
GenericValue entityValue = from(entityName).where(parameters).queryOne()
if (entityValue) {
tplCustScreen = getCustomScreenTemplate(entityTypeName, entityValue[getFieldTypeName(entityTypeName)])
}
}
context.templateLocation = tplCustScreen ? tplCustScreen.customScreenLocation : context.defaultTemplateLocation
context.templateName = tplCustScreen ? tplCustScreen.customScreenName : context.defaultTemplateName
@@ -3141,7 +3141,7 @@
<value xml:lang="zh-TW">你沒有檢視本頁面的權限.(需要具備"CONTENTMGR_UPDATE"或"CONTENTMGR_ADMIN")</value>
</property>
<property key="ContentUploadFileTypeNotMatch">
<value xml:lang="en">Upload file type not match your selected.</value>
<value xml:lang="en">Upload file type not match your selection.</value>
<value xml:lang="fr">Le type de fichier chargé ne correspond pas avec votre selection.</value>
<value xml:lang="it">Tipo file da caricare non corrisponde alla tua selezione.</value>
<value xml:lang="ja">選択したアップロードファイルの種類が一致しません。</value>
@@ -7147,4 +7147,4 @@
<value xml:lang="zh">生成缺失的搜索引擎优化的网址</value>
<value xml:lang="zh-TW">產生缺失的搜尋引擎優化的網址</value>
</property>
</resource>
</resource>
@@ -1,325 +0,0 @@
<?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.
-->
<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://ofbiz.apache.org/Simple-Method" xsi:schemaLocation="http://ofbiz.apache.org/Simple-Method http://ofbiz.apache.org/dtds/simple-methods.xsd">
<simple-method method-name="createBlogEntry" short-description="Create a new Blog Entry">
<set field="contentAssocTypeId" value="PUBLISH_LINK"/>
<set field="ownerContentId" from-field="parameters.blogContentId"/>
<set field="contentIdFrom" from-field="parameters.blogContentId"/>
<if-empty field="parameters.statusId">
<set field="parameters.statusId" value="CTNT_INITIAL_DRAFT"/>
</if-empty>
<if-empty field="parameters.templateDataResourceId">
<set field="parameters.templateDataResourceId" value="BLOG_TPL_TOPLEFT"/>
</if-empty>
<!-- determine of we need to create complex template structure or simple content structure -->
<if-empty field="parameters.contentName">
<add-error>
<fail-property resource="ContentUiLabels" property="ContentArticleNameIsMissing"/>
</add-error>
</if-empty>
<check-errors/>
<!-- complex template structure (image & text) -->
<set field="createMain.dataResourceId" from-field="parameters.templateDataResourceId"/>
<set field="createMain.contentAssocTypeId" from-field="contentAssocTypeId"/>
<set field="createMain.contentName" from-field="parameters.contentName"/>
<set field="createMain.description" from-field="parameters.description"/>
<set field="createMain.statusId" from-field="parameters.statusId"/>
<set field="createMain.contentIdFrom" from-field="contentIdFrom"/>
<set field="createMain.partyId" from-field="userLogin.partyId"/>
<set field="createMain.ownerContentId" from-field="ownerContentId"/>
<set field="createMain.dataTemplateTypeId" value="SCREEN_COMBINED"/>
<set field="createMain.mapKey" value="MAIN"/>
<call-service service-name="createContent" in-map-name="createMain">
<result-to-field result-name="contentId" field="contentId"/>
</call-service>
<!-- reset contentIdFrom to new contentId -->
<set field="contentAssocTypeId" value="SUB_CONTENT"/>
<set field="contentIdFrom" from-field="contentId"/>
<if-not-empty field="parameters._uploadedFile_fileName">
<!-- upload a picture -->
<set field="createImage.dataResourceTypeId" value="LOCAL_FILE"/>
<set field="createImage.dataTemplateTypeId" value="NONE"/>
<set field="createImage.mapKey" value="IMAGE"/>
<set field="createImage.ownerContentId" from-field="ownerContentId"/>
<set field="createImage.contentName" from-field="parameters.contentName"/>
<set field="createImage.description" from-field="parameters.description"/>
<set field="createImage.statusId" from-field="parameters.statusId"/>
<set field="createImage.contentAssocTypeId" from-field="contentAssocTypeId"/>
<set field="createImage.contentIdFrom" from-field="contentIdFrom"/>
<set field="createImage.partyId" from-field="userLogin.partyId"/>
<set field="createImage.isPublic" value="Y"/>
<set field="createImage.uploadedFile" from-field="parameters.uploadedFile"/>
<set field="createImage._uploadedFile_fileName" from-field="parameters._uploadedFile_fileName"/>
<set field="createImage._uploadedFile_contentType" from-field="parameters._uploadedFile_contentType"/>
<call-service service-name="createContentFromUploadedFile" in-map-name="createImage">
<result-to-field result-name="contentId" field="imageContentId"/>
</call-service>
</if-not-empty>
<if-not-empty field="parameters.articleData">
<!-- create text data -->
<set field="createText.dataResourceTypeId" value="ELECTRONIC_TEXT"/>
<set field="createText.contentPurposeTypeId" value="ARTICLE"/>
<set field="createText.dataTemplateTypeId" value="NONE"/>
<set field="createText.mapKey" value="MAIN"/>
<set field="createText.ownerContentId" from-field="ownerContentId"/>
<set field="createText.contentName" from-field="parameters.contentName"/>
<set field="createText.description" from-field="parameters.description"/>
<set field="createText.statusId" from-field="parameters.statusId"/>
<set field="createText.contentAssocTypeId" from-field="contentAssocTypeId"/>
<set field="createText.textData" from-field="parameters.articleData"/>
<set field="createText.contentIdFrom" from-field="contentIdFrom"/>
<set field="createText.partyId" from-field="userLogin.partyId"/>
<set field="createText.mapKey" value="ARTICLE"/>
<log level="info" message="calling createTextContent with map: ${createText}"/>
<call-service service-name="createTextContent" in-map-name="createText">
<result-to-field result-name="contentId" field="textContentId"/>
</call-service>
</if-not-empty>
<if-not-empty field="contentId">
<if-not-empty field="parameters.summaryData">
<!-- create the summary data -->
<set field="createSummary.dataResourceTypeId" value="ELECTRONIC_TEXT"/>
<set field="createSummary.dataTemplateTypeId" value="NONE"/>
<set field="createSummary.mapKey" value="SUMMARY"/>
<set field="createSummary.ownerContentId" from-field="ownerContentId"/>
<set field="createSummary.contentName" from-field="parameters.contentName"/>
<set field="createSummary.description" from-field="parameters.description"/>
<set field="createSummary.statusId" from-field="parameters.statusId"/>
<set field="createSummary.contentAssocTypeId" from-field="contentAssocTypeId"/>
<set field="createSummary.textData" from-field="parameters.summaryData"/>
<set field="createSummary.contentIdFrom" from-field="contentIdFrom"/>
<set field="createSummary.partyId" from-field="userLogin.partyId"/>
<call-service service-name="createTextContent" in-map-name="createSummary"/>
</if-not-empty>
</if-not-empty>
<field-to-result field="contentIdFrom" result-name="contentId"/>
<field-to-result field="parameters.blogContentId" result-name="blogContentId"/>
</simple-method>
<simple-method method-name="updateBlogEntry" short-description="Update a existing Blog Entry">
<set field="showNoResult" value="Y"/>
<call-simple-method method-name="getBlogEntry"/>
<if>
<condition>
<or>
<if-compare-field field="parameters.contentName" operator="not-equals" to-field="contentName"/>
<if-compare-field field="parameters.description" operator="not-equals" to-field="description"/>
<if-compare-field field="parameters.summaryData" operator="not-equals" to-field="summaryData"/>
<if-compare-field field="parameters.templateDataResourceId" operator="not-equals" to-field="templateDataResourceId"/>
<if-compare-field field="parameters.statusId" operator="not-equals" to-field="statusId"/>
</or>
</condition>
<then>
<set-service-fields service-name="updateContent" map="parameters" to-map="updContent"/>
<set field="updContent.dataResourceId" from-field="parameters.templateDataResourceId"/>
<call-service service-name="updateContent" in-map-name="updContent"/>
<if-compare-field field="parameters.statusId" operator="not-equals" to-field="statusId">
<if-not-empty field="imageContent">
<set field="imageContent.status.Id" from-field="parameters.statusId"/>
<store-value value-field="imageContent"/>
</if-not-empty>
</if-compare-field>
</then>
</if>
<!-- new article text -->
<if-empty field="articleText">
<if-not-empty field="parameters.articleData">
<set field="ownerContentId" from-field="parameters.blogContentId"/>
<set field="contentAssocTypeId" value="SUB_CONTENT"/>
<set field="contentIdFrom" from-field="contentId"/>
<set field="createText.dataResourceTypeId" value="ELECTRONIC_TEXT"/>
<set field="createText.contentPurposeTypeId" value="ARTICLE"/>
<set field="createText.dataTemplateTypeId" value="NONE"/>
<set field="createText.mapKey" value="ARTICLE"/>
<set field="createText.ownerContentId" from-field="ownerContentId"/>
<set field="createText.contentName" from-field="parameters.contentName"/>
<set field="createText.description" from-field="parameters.description"/>
<set field="createText.statusId" from-field="parameters.statusId"/>
<set field="createText.contentAssocTypeId" from-field="contentAssocTypeId"/>
<set field="createText.textData" from-field="parameters.articleData"/>
<set field="createText.contentIdFrom" from-field="contentIdFrom"/>
<set field="createText.partyId" from-field="userLogin.partyId"/>
<call-service service-name="createTextContent" in-map-name="createText"/>
</if-not-empty>
</if-empty>
<!-- update article text -->
<if-not-empty field="articleText">
<if-compare-field field="parameters.articleData" operator="not-equals" to-field="articleData">
<set field="articleText.textData" from-field="parameters.articleData"/>
<store-value value-field="articleText"/>
</if-compare-field>
</if-not-empty>
<!-- create summary text -->
<if-empty field="summaryData">
<if-not-empty field="parameters.summaryData">
<!-- create the summary data -->
<set field="ownerContentId" from-field="parameters.blogContentId"/>
<set field="contentAssocTypeId" value="SUB_CONTENT"/>
<set field="contentIdFrom" from-field="contentId"/>
<set field="createSummary.dataResourceTypeId" value="ELECTRONIC_TEXT"/>
<set field="createSummary.contentPurposeTypeId" value="ARTICLE"/>
<set field="createSummary.dataTemplateTypeId" value="NONE"/>
<set field="createSummary.mapKey" value="SUMMARY"/>
<set field="createSummary.ownerContentId" from-field="ownerContentId"/>
<set field="createSummary.contentName" from-field="parameters.contentName"/>
<set field="createSummary.description" from-field="parameters.description"/>
<set field="createSummary.statusId" from-field="parameters.statusId"/>
<set field="createSummary.contentAssocTypeId" from-field="contentAssocTypeId"/>
<set field="createSummary.textData" from-field="parameters.summaryData"/>
<set field="createSummary.contentIdFrom" from-field="contentIdFrom"/>
<set field="createSummary.partyId" from-field="userLogin.partyId"/>
<call-service service-name="createTextContent" in-map-name="createSummary"/>
</if-not-empty>
</if-empty>
<!-- update summary text -->
<if-not-empty field="summaryData">
<if-compare-field field="parameters.summaryData" operator="not-equals" to-field="summaryData">
<set field="summaryText.textData" from-field="parameters.summaryData"/>
<store-value value-field="summaryText"/>
</if-compare-field>
</if-not-empty>
<if-not-empty field="parameters._uploadedFile_fileName">
<if-not-empty field="imageContent">
<entity-and entity-name="ContentAssoc" list="oldAssocs" filter-by-date="true">
<field-map field-name="contentId" from-field="contentId"/>
<field-map field-name="contentIdTo" from-field="imageContent.contentId"/>
<field-map field-name="mapKey" value="IMAGE"/>
</entity-and>
<first-from-list list="oldAssocs" entry="oldAssoc"/>
<now-timestamp field="oldAssoc.thruDate"/>
<store-value value-field="oldAssoc"/>
</if-not-empty>
<!-- upload a picture -->
<set field="createImage.dataResourceTypeId" value="LOCAL_FILE"/>
<set field="createImage.dataTemplateTypeId" value="NONE"/>
<set field="createImage.mapKey" value="IMAGE"/>
<set field="createImage.ownerContentId" from-field="parameters.contentId"/>
<set field="createImage.contentName" from-field="parameters.contentName" default-value="${contentName}"/>
<set field="createImage.description" from-field="parameters.description" default-value="${description}"/>
<set field="createImage.statusId" from-field="parameters.statusId" default-value="${statusId}"/>
<set field="createImage.contentAssocTypeId" value="SUB_CONTENT"/>
<set field="createImage.contentIdFrom" from-field="parameters.contentId"/>
<set field="createImage.partyId" from-field="userLogin.partyId"/>
<set field="createImage.isPublic" value="Y"/>
<set field="createImage.uploadedFile" from-field="parameters.uploadedFile"/>
<set field="createImage._uploadedFile_fileName" from-field="parameters._uploadedFile_fileName"/>
<set field="createImage._uploadedFile_contentType" from-field="parameters._uploadedFile_contentType"/>
<call-service service-name="createContentFromUploadedFile" in-map-name="createImage"/>
</if-not-empty>
<field-to-result field="parameters.contentId" result-name="contentId"/>
<field-to-result field="parameters.blogContentId" result-name="blogContentId"/>
</simple-method>
<simple-method method-name="getOwnedOrPublishedBlogEntries" short-description="Get blog entries that the user owns or are published">
<entity-condition entity-name="ContentAssocViewTo" use-cache="false" list="unfilteredList">
<condition-list combine="and">
<condition-expr field-name="contentIdStart" operator="equals" from-field="parameters.contentId"/>
<condition-expr field-name="caContentAssocTypeId" operator="equals" value="PUBLISH_LINK"/>
</condition-list>
<order-by field-name="caFromDate DESC"/>
</entity-condition>
<filter-list-by-date list="unfilteredList" to-list="blogItems"/>
<set field="blogList[]"/>
<iterate list="blogItems" entry="blogItem">
<set-service-fields service-name="genericContentPermission" map="blogItem" to-map="mapIn"/>
<set field="mapIn.ownerContentId" from-field="parameters.contentId"/>
<set field="mapIn.mainAction" value="VIEW"/>
<call-service service-name="genericContentPermission" in-map-name="mapIn">
<result-to-field result-name="hasPermission" field="hasPermission"/>
</call-service>
<if-compare field="hasPermission" operator="equals" value="true" type="Boolean">
<set field="blogList[]" from-field="blogItem"/>
<else>
<set field="mapIn.mainAction" value="UPDATE"/>
<call-service service-name="genericContentPermission" in-map-name="mapIn">
<result-to-field result-name="hasPermission" field="hasPermission"/>
</call-service>
<if-compare field="hasPermission" operator="equals" value="true" type="Boolean">
<set field="blogList[]" from-field="blogItem"/>
</if-compare>
</else>
</if-compare>
</iterate>
<field-to-result field="blogList" result-name="blogList"/>
<field-to-result field="parameters.blogContentId" result-name="blogContentId"/>
</simple-method>
<simple-method method-name="getBlogEntry" short-description="Get all the info for a blog article">
<if-empty field="parameters.contentId">
<field-to-result field="parameters.blogContentId" result-name="blogContentId"/>
<return/>
</if-empty>
<entity-one entity-name="Content" value-field="content"/>
<get-related value-field="content" relation-name="FromContentAssoc" list="rawAssocs"/>
<filter-list-by-date list="rawAssocs" to-list="assocs"/>
<iterate list="assocs" entry="assoc">
<if-compare field="assoc.mapKey" value="ARTICLE" operator="equals">
<get-related-one value-field="assoc" relation-name="ToContent" to-value-field="mainContent"/>
<get-related-one value-field="mainContent" relation-name="DataResource" to-value-field="dataResource"/>
<get-related-one value-field="dataResource" relation-name="ElectronicText" to-value-field="articleText"/>
</if-compare>
<if-compare field="assoc.mapKey" value="SUMMARY" operator="equals">
<get-related-one value-field="assoc" relation-name="ToContent" to-value-field="summaryContent"/>
<get-related-one value-field="summaryContent" relation-name="DataResource" to-value-field="dataResource"/>
<get-related-one value-field="dataResource" relation-name="ElectronicText" to-value-field="summaryText"/>
</if-compare>
<if-compare field="assoc.mapKey" value="IMAGE" operator="equals">
<get-related-one value-field="assoc" relation-name="ToContent" to-value-field="imageContent"/>
</if-compare>
</iterate>
<if-empty field="showNoResult">
<field-to-result field="content.contentId" result-name="contentId"/>
<field-to-result field="content.contentName" result-name="contentName"/>
<field-to-result field="content.description" result-name="description"/>
<field-to-result field="content.statusId" result-name="statusId"/>
<if-not-empty field="imageContent">
<field-to-result field="content.dataResourceId" result-name="templateDataResourceId"/>
</if-not-empty>
<field-to-result field="articleText.textData" result-name="articleData"/>
<field-to-result field="summaryText.textData" result-name="summaryData"/>
<field-to-result field="imageContent.contentId" result-name="imageContentId"/>
<field-to-result field="mainContent.contentId" result-name="articleContentId"/>
<field-to-result field="summaryContent.contentId" result-name="summaryContentId"/>
<field-to-result field="parameters.blogContentId" result-name="blogContentId"/>
<else>
<set from-field="content.contentId" field="contentId"/>
<set from-field="content.contentName" field="contentName"/>
<set from-field="content.description" field="description"/>
<set from-field="content.statusId" field="statusId"/>
<set from-field="content.dataResourceId" field="templateDataResourceId"/>
<set from-field="articleText.textData" field="articleData"/>
<set from-field="summaryText.textData" field="summaryData"/>
<set from-field="imageContent.dataResourceId" field="imageDataResourceId"/>
</else>
</if-empty>
</simple-method>
</simple-methods>
+29 -23
View File
@@ -559,20 +559,27 @@
<attribute name="fieldValue0" type="String" mode="IN" optional="true"/>
</service>
<service name="resequence" auth="true" engine="java" validate="true" transaction-timeout="7200"
location="org.apache.ofbiz.content.ContentManagementServices" invoke="resequence">
<service name="resequence" auth="true" engine="group">
<deprecated use-instead="resequenceContentAssocChildren" since="release22.01"/>
<group>
<invoke name="resequenceContentAssocChildren"/>
</group>
</service>
<service name="resequenceContentAssocChildren" auth="true" engine="java" transaction-timeout="7200"
location="org.apache.ofbiz.content.ContentManagementServices" invoke="resequence">
<description>Reorder sequence numbers in ContentAssoc entities for a given parent id</description>
<attribute mode="IN" name="contentIdTo" optional="false" type="String">
<attribute mode="IN" name="contentId" optional="false" type="String">
<type-validate>
<fail-property resource="ContentErrorUiLabels" property="ContentRequiredFieldMissingContentIdTo"/>
<fail-property resource="ContentErrorUiLabels" property="ContentRequiredFieldMissingContentId"/>
</type-validate>
</attribute>
<attribute mode="IN" name="seqInc" optional="true" type="Integer"/>
<attribute mode="IN" name="seqInc" optional="true" type="Integer" default-value="10"/>
<attribute mode="IN" name="typeList" optional="true" type="List"/>
<attribute mode="IN" name="contentId" optional="true" type="String"/>
<attribute mode="IN" name="contentIdTo" optional="true" type="String"/>
<attribute mode="IN" name="contentAssocTypeId" optional="true" type="String"/>
<attribute mode="IN" name="dir" optional="true" type="String"/>
</service>
<service name="changeLeafToNode" validate="true" auth="true" engine="java" transaction-timeout="7200"
location="org.apache.ofbiz.content.ContentManagementServices" invoke="changeLeafToNode">
<description>Moves dataResource to separate content associated with current content so that node can have only children, no content of its own</description>
@@ -818,8 +825,8 @@
</service>
<!-- blog services -->
<service name="createBlogEntry" engine="simple" auth="true"
location="component://content/minilang/blog/BlogServices.xml" invoke="createBlogEntry">
<service name="createBlogEntry" engine="groovy" auth="true"
location="component://content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy" invoke="createBlogEntry">
<description>Creates content records for a blog entry</description>
<required-permissions join-type="AND">
<check-permission permission="CONTENTMGR" action="_CREATE"/>
@@ -838,8 +845,8 @@
<attribute name="articleData" type="String" mode="IN" optional="true" allow-html="safe"/>
<attribute name="summaryData" type="String" mode="IN" optional="true" allow-html="safe"/>
</service>
<service name="updateBlogEntry" engine="simple" auth="true"
location="component://content/minilang/blog/BlogServices.xml" invoke="updateBlogEntry">
<service name="updateBlogEntry" engine="groovy" auth="true"
location="component://content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy" invoke="updateBlogEntry">
<description>Updates content records for a blog entry</description>
<required-permissions join-type="AND">
<check-permission permission="CONTENTMGR" action="_UPDATE"/>
@@ -862,8 +869,8 @@
<attribute name="articleData" type="String" mode="IN" optional="true" allow-html="safe"/>
<attribute name="summaryData" type="String" mode="IN" optional="true" allow-html="safe"/>
</service>
<service name="getBlogEntry" engine="simple" auth="true"
location="component://content/minilang/blog/BlogServices.xml" invoke="getBlogEntry">
<service name="getBlogEntry" engine="groovy" auth="true"
location="component://content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy" invoke="getBlogEntry">
<description>Retrieves content records for a blog entry</description>
<attribute name="blogContentId" type="String" mode="INOUT" optional="false">
<type-validate>
@@ -875,25 +882,24 @@
<attribute name="statusId" type="String" mode="OUT" optional="true"/>
<attribute name="description" type="String" mode="OUT" optional="true"/>
<attribute name="templateDataResourceId" type="String" mode="OUT" optional="true"/>
<attribute name="summaryData" type="String" mode="OUT" optional="true"/>
<attribute name="articleData" type="String" mode="OUT" optional="true"/>
<attribute name="imageContentId" type="String" mode="OUT" optional="true"/>
<attribute name="imageDataResourceId" type="String" mode="IN" optional="true"/>
<attribute name="articleData" type="String" mode="OUT" optional="true"/>
<attribute name="articleContentId" type="String" mode="OUT" optional="true"/>
<attribute name="articleDataResourceId" type="String" mode="OUT" optional="true"/>
<attribute name="summaryData" type="String" mode="OUT" optional="true"/>
<attribute name="summaryContentId" type="String" mode="OUT" optional="true"/>
<attribute name="summaryDataResourceId" type="String" mode="OUT" optional="true"/>
</service>
<service name="getOwnedOrPublishedBlogEntries" engine="simple" location="component://content/minilang/blog/BlogServices.xml" invoke="getOwnedOrPublishedBlogEntries"
auth="true" transaction-timeout="7200">
<attribute type="String" mode="IN" name="contentId" optional="false">
<service name="getOwnedOrPublishedBlogEntries" engine="groovy" auth="true" transaction-timeout="7200"
location="component://content/src/main/groovy/org/apache/ofbiz/content/BlogServices.groovy" invoke="getOwnedOrPublishedBlogEntries">
<attribute name="contentId" type="String" mode="IN" >
<type-validate>
<fail-property resource="ContentErrorUiLabels" property="ContentRequiredFieldMissingContentId"/>
</type-validate>
</attribute>
<attribute mode="IN" name="userLogin" optional="false" type="org.apache.ofbiz.entity.GenericValue">
<type-validate>
<fail-property resource="ContentErrorUiLabels" property="ContentRequiredFieldMissingUserLogin"/>
</type-validate>
</attribute>
<attribute mode="OUT" name="blogList" optional="true" type="List"/>
<attribute name="blogContentId" type="String" mode="OUT" optional="true"/>
<attribute name="blogList" type="List" mode="OUT" optional="true"/>
</service>
<!-- blog RSS services -->
@@ -0,0 +1,273 @@
/*******************************************************************************
* 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.
*******************************************************************************/
package org.apache.ofbiz.content
import org.apache.ofbiz.base.util.UtilDateTime
import org.apache.ofbiz.entity.GenericValue
import org.apache.ofbiz.entity.condition.EntityCondition
import org.apache.ofbiz.entity.condition.EntityConditionBuilder
def createBlogEntry() {
String ownerContentId = parameters.blogContentId
String contentIdFrom = parameters.blogContentId
parameters.statusId = parameters.statusId ?: "CTNT_INITIAL_DRAFT"
parameters.templateDataResourceId = parameters.templateDataResourceId ?: "BLOG_TPL_TOPLEFT"
if (!parameters.contentName) {
return error(label("ContentUiLabels", "ContentArticleNameIsMissing"))
}
Map serviceResult = run service: "createContent",
with: [dataResourceId : parameters.templateDataResourceId,
contentAssocTypeId: "PUBLISH_LINK",
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentIdFrom : contentIdFrom,
partyId : userLogin.partyId,
ownerContentId : ownerContentId,
dataTemplateTypeId: "SCREEN_COMBINED",
mapKey : "MAIN"]
contentIdFrom = serviceResult.contentId
if (parameters._uploadedFile_fileName) {
run service: "createContentFromUploadedFile",
with: [
dataResourceTypeId : "LOCAL_FILE",
dataTemplateTypeId : "NONE",
mapKey : "IMAGE",
ownerContentId : ownerContentId,
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentAssocTypeId : "SUB_CONTENT",
contentIdFrom : contentIdFrom,
partyId : userLogin.partyId,
isPublic : "Y",
uploadedFile : parameters.uploadedFile,
_uploadedFile_fileName : parameters._uploadedFile_fileName,
_uploadedFile_contentType: parameters._uploadedFile_contentType]
}
if (parameters.articleData) {
run service: "createTextContent",
with: [
dataResourceTypeId : "ELECTRONIC_TEXT",
contentPurposeTypeId: "ARTICLE",
dataTemplateTypeId : "NONE",
mapKey : "MAIN",
ownerContentId : ownerContentId,
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentAssocTypeId : "SUB_CONTENT",
textData : parameters.articleData,
contentIdFrom : contentIdFrom,
partyId : userLogin.partyId,
mapKey : "ARTICLE"]
}
if (parameters.summaryData) {
run service: "createTextContent",
with: [
dataResourceTypeId: "ELECTRONIC_TEXT",
dataTemplateTypeId: "NONE",
mapKey : "SUMMARY",
ownerContentId : ownerContentId,
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentAssocTypeId: "SUB_CONTENT",
textData : parameters.summaryData,
contentIdFrom : contentIdFrom,
partyId : userLogin.partyId]
}
return success([blogContentId: ownerContentId, contentId: contentIdFrom])
}
/**
* Get all the info for a blog article
*/
def getBlogEntry() {
if (!parameters.contentId) {
return success([blogContentId: parameters.blogContentId])
}
GenericValue content = from("Content").where(parameters).cache().queryOne()
GenericValue mainContent, articleText, dataResource, summaryContent, summaryText, imageContent
from("ContentAssoc")
.where(contentId: content.contentId)
.filterByDate()
.cache()
.queryList()
.each {
switch (it.mapKey) {
case "ARTICLE":
mainContent = it.getRelatedOne("ToContent", true)
dataResource = mainContent.getRelatedOne("DataResource", true)
articleText = dataResource.getRelatedOne("ElectronicText", true)
break
case "SUMMARY":
summaryContent = it.getRelatedOne("ToContent", true)
dataResource = summaryContent.getRelatedOne("DataResource", true)
summaryText = dataResource.getRelatedOne("ElectronicText", true)
break
case "IMAGE":
imageContent = it.getRelatedOne("ToContent", true)
break
}
}
Map resultMap = [blogContentId: parameters.blogContentId,
contentId : content.contentId,
contentName : content.contentName,
description : content.description,
statusId : content.statusId]
if (imageContent) {
resultMap.templateDataResourceId = content.dataResourceId
resultMap.imageContentId = imageContent.contentId
resultMap.imageDataResourceId = imageContent.dataResourceId
}
if (mainContent) {
resultMap.articleData = articleText.textData
resultMap.articleContentId = mainContent.contentId
resultMap.articleDataResourceId = mainContent.dataResourceId
}
if (summaryContent) {
resultMap.summaryData = summaryText.textData
resultMap.summaryContentId = summaryContent.contentId
resultMap.summaryDataResourceId = summaryContent.dataResourceId
}
return success(resultMap)
}
/**
* Update a existing Blog Entry
*/
def updateBlogEntry() {
Map blog = run service: "getBlogEntry", with: parameters
if (['contentName', 'description', 'summaryData', 'templateDataResourceId', 'statusId']
.stream().anyMatch { blog[it] != parameters[it] }) {
run service: "updateContent", with: [* : parameters,
dataResourceId: parameters.templateDataResourceId]
if (parameters.statusId != blog.statusId
&& blog.imageContentId) {
delegator.storeByCondition("Content", [statusId: parameters.statusId],
EntityCondition.makeCondition("contentId", blog.imageContentId))
}
}
if (!blog.articleText && parameters.articleData) {
run service: "createTextContent",
with: [
dataResourceTypeId : "ELECTRONIC_TEXT",
contentPurposeTypeId: "ARTICLE",
dataTemplateTypeId : "NONE",
mapKey : "MAIN",
ownerContentId : parameters.blogContentId,
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentAssocTypeId : "SUB_CONTENT",
textData : parameters.articleData,
contentIdFrom : blog.contentId,
partyId : userLogin.partyId,
mapKey : "ARTICLE"]
}
if (blog.articleData && parameters.articleData != blog.articleData) {
run service: 'updateElectronicText', with: [dataResourceId: blog.articleDataResourceId,
textData : parameters.articleData]
}
if (!blog.summaryData && parameters.summaryData) {
run service: "createTextContent",
with: [
dataResourceTypeId: "ELECTRONIC_TEXT",
dataTemplateTypeId: "NONE",
mapKey : "SUMMARY",
ownerContentId : parameters.blogContentId,
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentAssocTypeId: "SUB_CONTENT",
textData : parameters.summaryData,
contentIdFrom : blog.contentId,
partyId : userLogin.partyId]
}
if (blog.summaryData && parameters.summaryData != blog.summaryData) {
run service: 'updateElectronicText', with: [dataResourceId: blog.summaryDataResourceId,
textData : parameters.summaryData]
}
if (parameters._uploadedFile_fileName) {
if (blog.imageContentId) {
EntityCondition condition = new EntityConditionBuilder().AND() {
EQUALS(contentId: blog.contentId)
EQUALS(contentIdTo: blog.imageContentId)
EQUALS(mapKey: "IMAGE")
EQUALS(thruDate: null)
}
delegator.storeByCondition("ContentAssoc", [thruDate: UtilDateTime.nowTimestamp()], condition)
}
run service: "createContentFromUploadedFile",
with: [
isPublic : "Y",
dataTemplateTypeId : "NONE",
mapKey : "IMAGE",
dataResourceTypeId : "LOCAL_FILE",
contentAssocTypeId : "SUB_CONTENT",
ownerContentId : parameters.blogContentId,
contentName : parameters.contentName,
description : parameters.description,
statusId : parameters.statusId,
contentIdFrom : blog.contentId,
partyId : userLogin.partyId,
uploadedFile : parameters.uploadedFile,
_uploadedFile_fileName : parameters._uploadedFile_fileName,
_uploadedFile_contentType: parameters._uploadedFile_contentType]
}
return success([blogContentId: parameters.blogContentId, contentId: blog.contentId])
}
/**
* Get blog entries that the user owns or are published
* @return
*/
def getOwnedOrPublishedBlogEntries() {
List blogList = []
from("ContentAssocViewTo")
.where(contentIdStart: parameters.contentId,
caContentAssocTypeId: "PUBLISH_LINK")
.orderBy("-caFromDate")
.filterByDate()
.cache()
.queryList()
.each {
Map serviceResult = run service: "genericContentPermission",
with: [* : it.getAllFields(),
ownerContentId: parameters.contentId,
mainAction : "VIEW"]
if (!serviceResult.hasPermission) {
serviceResult = run service: "genericContentPermission",
with: [* : it.getAllFields(),
ownerContentId: parameters.contentId,
mainAction : "UPDATE"]
}
if (serviceResult.hasPermission) {
blogList << it
}
}
return success([blogList : blogList,
blogContentId: parameters.blogContentId])
}
@@ -23,6 +23,7 @@ import java.io.IOException;
import java.math.BigDecimal;
import java.nio.ByteBuffer;
import java.sql.Timestamp;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.LinkedHashSet;
@@ -50,6 +51,7 @@ import org.apache.ofbiz.entity.condition.EntityOperator;
import org.apache.ofbiz.entity.model.ModelUtil;
import org.apache.ofbiz.entity.util.EntityQuery;
import org.apache.ofbiz.entity.util.EntityUtil;
import org.apache.ofbiz.security.SecuredUpload;
import org.apache.ofbiz.security.Security;
import org.apache.ofbiz.service.DispatchContext;
import org.apache.ofbiz.service.GenericServiceException;
@@ -146,6 +148,20 @@ public class ContentManagementServices {
Map<String, Object> context = UtilMisc.makeMapWritable(rcontext);
Locale locale = (Locale) context.get("locale");
// Check if a webshell is not uploaded
String textData = (String) context.get("textData");
if (UtilValidate.isNotEmpty(textData)) {
try {
if (!SecuredUpload.isValidText(textData, Collections.emptyList())) {
Debug.logError("================== Not saved for security reason ==================", MODULE);
return ServiceUtil.returnError("================== Not saved for security reason ==================");
}
} catch (IOException e) {
Debug.logError("================== Not saved for security reason ==================", MODULE);
return ServiceUtil.returnError("================== Not saved for security reason ==================");
}
}
// Knowing why a request fails permission check is one of the more difficult
// aspects of content management. Setting "displayFailCond" to true will
// put an html table in result.errorMessage that will show what tests were performed
@@ -176,7 +192,7 @@ public class ContentManagementServices {
if (Debug.infoOn()) {
Debug.logInfo("in persist... contentPurposeList(0):" + contentPurposeList, MODULE);
Debug.logInfo("in persist... textData(0):" + context.get("textData"), MODULE);
Debug.logInfo("in persist... textData(0):" + textData, MODULE);
}
GenericValue content = delegator.makeValue("Content");
@@ -835,15 +851,23 @@ public class ContentManagementServices {
return results;
}
/**
* Reorder sequence numbers in ContentAssoc entities for a given parent id
* if variable dir contains the string up or down, realize for the given contentIdTo switch
* with the previous or the next
* @param dctx
* @param context
* @return
* @throws GenericServiceException
*/
public static Map<String, Object> resequence(DispatchContext dctx, Map<String, ? extends Object> context) throws GenericServiceException {
Map<String, Object> result = new HashMap<>();
Delegator delegator = dctx.getDelegator();
String contentIdTo = (String) context.get("contentIdTo");
Integer seqInc = (Integer) context.get("seqInc");
if (seqInc == null) {
seqInc = 100;
}
int seqIncrement = seqInc;
String contentId = (String) context.get("contentId");
int seqStep = (Integer) context.get("seqInc");
// Resolve the association type to use for resolve content's child
List<String> typeList = UtilGenerics.cast(context.get("typeList"));
if (typeList == null) {
typeList = new LinkedList<>();
@@ -855,60 +879,45 @@ public class ContentManagementServices {
if (UtilValidate.isEmpty(typeList)) {
typeList = UtilMisc.toList("PUBLISH_LINK", "SUB_CONTENT");
}
EntityCondition conditionType = EntityCondition.makeCondition("contentAssocTypeId", EntityOperator.IN, typeList);
EntityCondition conditionMain = EntityCondition.makeCondition(UtilMisc.toList(EntityCondition.makeCondition("contentIdTo",
EntityOperator.EQUALS, contentIdTo), conditionType), EntityOperator.AND);
// Resolve all content assoc to resequence from the content
try {
List<GenericValue> listAll = EntityQuery.use(delegator).from("ContentAssoc")
.where(conditionMain)
List<GenericValue> contentAssocs = EntityQuery.use(delegator).from("ContentAssoc")
.where(List.of(
EntityCondition.makeCondition("contentId", contentId),
EntityCondition.makeCondition("contentAssocTypeId", EntityOperator.IN, typeList)))
.orderBy("sequenceNum", "fromDate", "createdDate")
.filterByDate().queryList();
String contentId = (String) context.get("contentId");
.filterByDate()
.queryList();
String contentIdTo = (String) context.get("contentIdTo");
String dir = (String) context.get("dir");
int seqNum = seqIncrement;
String thisContentId = null;
for (int i = 0; i < listAll.size(); i++) {
GenericValue contentAssoc = listAll.get(i);
if (UtilValidate.isNotEmpty(contentId) && UtilValidate.isNotEmpty(dir)) {
// move targeted entry up or down
thisContentId = contentAssoc.getString("contentId");
if (contentId.equals(thisContentId)) {
if (dir.startsWith("up")) {
if (i > 0) {
// Swap with previous entry
try {
GenericValue prevValue = listAll.get(i - 1);
Long prevSeqNum = (Long) prevValue.get("sequenceNum");
prevValue.put("sequenceNum", (long) seqNum);
prevValue.store();
contentAssoc.put("sequenceNum", prevSeqNum);
contentAssoc.store();
} catch (GenericEntityException e) {
return ServiceUtil.returnError(e.toString());
}
}
} else {
if (i < listAll.size()) {
// Swap with next entry
GenericValue nextValue = listAll.get(i + 1);
nextValue.put("sequenceNum", (long) seqNum);
nextValue.store();
seqNum += seqIncrement;
contentAssoc.put("sequenceNum", (long) seqNum);
contentAssoc.store();
i++; // skip next one
}
}
} else {
contentAssoc.put("sequenceNum", (long) seqNum);
contentAssoc.store();
}
} else {
contentAssoc.put("sequenceNum", (long) seqNum);
contentAssoc.store();
int seqNum = seqStep;
boolean switchSequence = UtilValidate.isNotEmpty(contentIdTo) && UtilValidate.isNotEmpty(dir);
boolean switchModeUp = switchSequence && dir.startsWith("up");
int changePosition = -1;
// update the sequence for all element and check if we need switch two element
for (int i = 0; i < contentAssocs.size(); i++) {
boolean stopLimit = ((i <= 0 && switchModeUp) || (i + 1 >= contentAssocs.size() && !switchModeUp));
GenericValue contentAssoc = contentAssocs.get(i);
contentAssoc.put("sequenceNum", (long) seqNum);
seqNum += seqStep;
if (switchSequence
&& contentIdTo.equals(contentAssoc.getString("contentIdTo"))
&& !stopLimit) {
changePosition = i;
}
seqNum += seqIncrement;
}
// We need to switch, do it
if (changePosition >= 0) {
GenericValue currentContent = contentAssocs.get(changePosition);
GenericValue destinationContent = contentAssocs.get(changePosition + (switchModeUp ? -1 : +1));
long switchSeqNum = currentContent.getLong("sequenceNum");
currentContent.put("sequenceNum", destinationContent.getLong("sequenceNum"));
destinationContent.put("sequenceNum", switchSeqNum);
}
delegator.storeAll(contentAssocs);
} catch (GenericEntityException e) {
Debug.logError(e, MODULE);
return ServiceUtil.returnError(e.toString());
@@ -1594,6 +1603,9 @@ public class ContentManagementServices {
File file = new File(objectInfo);
if (file.isFile()) {
try {
// Check if a webshell is not uploaded
// This should now be useless after the add of SecuredUpload::isValidFile in GroovyBaseScript for createAnonFile service.
// But I prefer to keep it anyway, it's hard to test all cases, better safe than sorry
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(objectInfo, "All", delegator)) {
errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
}
@@ -21,6 +21,7 @@ package org.apache.ofbiz.content.data;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.Collections;
import java.util.Locale;
import java.util.Map;
@@ -41,6 +42,7 @@ import org.apache.ofbiz.entity.GenericEntityException;
import org.apache.ofbiz.entity.GenericValue;
import org.apache.ofbiz.entity.util.EntityQuery;
import org.apache.ofbiz.entity.util.EntityUtilProperties;
import org.apache.ofbiz.security.SecuredUpload;
import org.apache.ofbiz.service.GenericServiceException;
import org.apache.ofbiz.service.LocalDispatcher;
import org.apache.ofbiz.service.ServiceUtil;
@@ -83,22 +85,16 @@ public class DataEvents {
String permissionService = EntityUtilProperties.getPropertyValue("content", "stream.permission.service",
"genericContentPermission", delegator);
// @formatter:off (prevent unwanted formatting in Eclipse)
// For OFBIZ-11840. It's counterintuitive to return success but it makes sense if you thing about it. It simply returns a blank screen.
// To illustrate, only few payloads, onLoad related, are handled because it works everytime.
// It could be improved by checking for all payloads.
// As listed at https://portswigger.net/web-security/cross-site-scripting/cheat-sheet, at 2020-11-11 there are 8979 of them.
// So a way could be to read all of them and test...
// @formatter:on
if (contentId.toLowerCase().contains("<svg")
|| contentId.toLowerCase().contains("<body")
|| contentId.toLowerCase().contains("<iframe")
|| contentId.toLowerCase().contains("<object")
|| contentId.toLowerCase().contains("<embed")
|| contentId.toLowerCase().contains("<a href='javas")
|| contentId.toLowerCase().contains("<a href=\"javas")
|| contentId.toLowerCase().contains("<script")) {
// For OFBIZ-11840, checks if a webshell is not uploaded
// It's counterintuitive to return success but it makes sense if you thing about it.
// It simply returns a blank screen.
try {
if (!SecuredUpload.isValidText(contentId, Collections.emptyList())) {
Debug.logError("================== Not saved for security reason ==================", MODULE);
return "success";
}
} catch (IOException e) {
Debug.logError("================== Not saved for security reason ==================", MODULE);
return "success";
}
@@ -411,7 +411,6 @@ public class DataResourceWorker implements org.apache.ofbiz.widget.content.DataR
public static String getMimeTypeWithByteBuffer(java.nio.ByteBuffer buffer) throws IOException {
byte[] b = buffer.array();
Tika tika = new Tika();
return tika.detect(b);
}
@@ -49,6 +49,7 @@ import org.apache.ofbiz.entity.Delegator;
import org.apache.ofbiz.entity.GenericEntityException;
import org.apache.ofbiz.entity.GenericValue;
import org.apache.ofbiz.entity.util.EntityQuery;
import org.apache.ofbiz.security.SecuredUpload;
import org.apache.ofbiz.service.DispatchContext;
import org.apache.ofbiz.service.GenericServiceException;
import org.apache.ofbiz.service.ModelService;
@@ -195,7 +196,30 @@ public class DataServices {
return createFileMethod(dctx, context);
}
public static Map<String, Object> createFileNoPerm(DispatchContext dctx, Map<String, ? extends Object> rcontext) {
public static Map<String, Object> createFileNoPerm(DispatchContext dctx, Map<String, ? extends Object> rcontext) throws IOException,
ImageReadException {
String originalFileName = (String) rcontext.get("dataResourceName");
String fileNameAndPath = (String) rcontext.get("objectInfo");
Delegator delegator = dctx.getDelegator();
Locale locale = (Locale) rcontext.get("locale");
File file = new File(fileNameAndPath);
if (!originalFileName.isEmpty()) {
// Check the file name
if (!SecuredUpload.isValidFileName(originalFileName, delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
return ServiceUtil.returnError(errorMessage);
}
// TODO we could verify the file type (here "All") with dataResourceTypeId. Anyway it's done with isValidFile()
// We would just have a better error message
if (file.exists()) {
// Check if a webshell is not uploaded
if (!SecuredUpload.isValidFile(fileNameAndPath, "All", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
return ServiceUtil.returnError(errorMessage);
}
}
}
Map<String, Object> context = UtilMisc.makeMapWritable(rcontext);
context.put("skipPermissionCheck", "true");
return createFileMethod(dctx, context);
@@ -254,7 +278,9 @@ public class DataServices {
if (UtilValidate.isNotEmpty(textData)) {
try (OutputStreamWriter out = new OutputStreamWriter(new FileOutputStream(file), StandardCharsets.UTF_8);) {
out.write(textData);
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(file.getAbsolutePath(), "Text", delegator)) {
// Check if a webshell is not uploaded
// TODO I believe the call below to SecuredUpload::isValidFile is now useless because of the same in createFileNoPerm
if (!SecuredUpload.isValidFile(file.getAbsolutePath(), "Text", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedTextFileFormats", locale);
return ServiceUtil.returnError(errorMessage);
}
@@ -265,10 +291,11 @@ public class DataServices {
}
} else if (binData != null) {
try {
// Check if a webshell is not uploaded
Path tempFile = Files.createTempFile(null, null);
Files.write(tempFile, binData.array(), StandardOpenOption.APPEND);
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(tempFile.toString(), "All", delegator)) {
// Check if a webshell is not uploaded
// TODO I believe the call below to SecuredUpload::isValidFile is now useless because of the same in createFileNoPerm
if (!SecuredUpload.isValidFile(tempFile.toString(), "All", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
return ServiceUtil.returnError(errorMessage);
}
@@ -460,7 +487,9 @@ public class DataServices {
if (UtilValidate.isNotEmpty(textData)) {
try (OutputStreamWriter out = new OutputStreamWriter(new FileOutputStream(file), StandardCharsets.UTF_8);) {
out.write(textData);
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(file.getAbsolutePath(), "Text", delegator)) {
// Check if a webshell is not uploaded
// TODO I believe the call below to SecuredUpload::isValidFile is now useless because of the same in createFileNoPerm
if (!SecuredUpload.isValidFile(file.getAbsolutePath(), "Text", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedTextFileFormats", locale);
return ServiceUtil.returnError(errorMessage);
}
@@ -472,9 +501,10 @@ public class DataServices {
} else if (binData != null) {
try {
// Check if a webshell is not uploaded
// TODO I believe the call below to SecuredUpload::isValidFile is now useless because of the same in createFileNoPerm
Path tempFile = Files.createTempFile(null, null);
Files.write(tempFile, binData.array(), StandardOpenOption.APPEND);
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(tempFile.toString(), "Image", delegator)) {
if (!SecuredUpload.isValidFile(tempFile.toString(), "Image", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
return ServiceUtil.returnError(errorMessage);
}
@@ -647,7 +677,8 @@ public class DataServices {
try (FileOutputStream out = new FileOutputStream(file);) {
out.write(imageData);
// Check if a webshell is not uploaded
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(file.getAbsolutePath(), "All", delegator)) {
// TODO I believe the call below to SecuredUpload::isValidFile is now useless because of the same in createFileNoPerm
if (!SecuredUpload.isValidFile(file.getAbsolutePath(), "All", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
return ServiceUtil.returnError(errorMessage);
}
@@ -706,7 +737,8 @@ public class DataServices {
try (FileOutputStream out = new FileOutputStream(file);) {
out.write(imageData);
// Check if a webshell is not uploaded
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(file.getAbsolutePath(), "All", delegator)) {
// TODO I believe the call below to SecuredUpload::isValidFile is now useless because of the same in createFileNoPerm
if (!SecuredUpload.isValidFile(file.getAbsolutePath(), "All", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
return ServiceUtil.returnError(errorMessage);
}
@@ -0,0 +1,50 @@
/*******************************************************************************
* 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.
*******************************************************************************/
package org.apache.ofbiz.content.ftp;
import java.util.ArrayList;
import org.apache.sshd.client.ClientBuilder;
import org.apache.sshd.client.SshClient;
import org.apache.sshd.client.config.keys.ClientIdentityLoader;
import org.apache.sshd.common.NamedFactory;
import org.apache.sshd.common.kex.BuiltinDHFactories;
import org.apache.sshd.common.signature.BuiltinSignatures;
public abstract class SshClientHelper {
private static SshClient client = null;
public static SshClient getSshClient() {
if (client == null) {
client = SshClient.setUpDefaultClient();
client.setClientIdentityLoader(ClientIdentityLoader.DEFAULT);
client.setKeyExchangeFactories(NamedFactory.setUpTransformedFactories(
false,
BuiltinDHFactories.VALUES,
ClientBuilder.DH2KEX));
client.setSignatureFactories(new ArrayList<>(BuiltinSignatures.VALUES));
}
if (!client.isStarted()) {
client.start();
}
return client;
}
}
@@ -28,7 +28,8 @@ import org.apache.commons.io.IOUtils;
import org.apache.ofbiz.base.util.UtilValidate;
import org.apache.sshd.client.SshClient;
import org.apache.sshd.client.session.ClientSession;
import org.apache.sshd.client.subsystem.sftp.SftpClient;
import org.apache.sshd.sftp.client.SftpClient;
import org.apache.sshd.sftp.client.SftpClientFactory;
/**
* Basic client to copy files to an ssh ftp server
@@ -37,12 +38,12 @@ public class SshFtpClient implements FtpClientInterface {
private static final String MODULE = SshFtpClient.class.getName();
private SshClient client;
private final SshClient client;
private SftpClient sftp;
private ClientSession session;
public SshFtpClient() {
client = SshClient.setUpDefaultClient();
client.start();
client = SshClientHelper.getSshClient();
}
@Override
@@ -50,11 +51,10 @@ public class SshFtpClient implements FtpClientInterface {
if (port == null) port = 22L;
if (timeout == null) timeout = 10000L;
if (sftp != null) return;
ClientSession session = client.connect(username, hostname, port.intValue()).verify(timeout.intValue()).getSession();
session = client.connect(username, hostname, port.intValue()).verify(timeout.intValue()).getSession();
session.addPasswordIdentity(password);
session.auth().verify(timeout.intValue());
sftp = session.createSftpClient();
session.auth().verify();
sftp = SftpClientFactory.instance().createSftpClient(session).singleSessionInstance();
}
@Override
@@ -83,10 +83,8 @@ public class SshFtpClient implements FtpClientInterface {
}
@Override
public void closeConnection() {
if (sftp != null) {
client.stop();
sftp = null;
}
public void closeConnection() throws IOException {
if (sftp != null) sftp.close();
if (session != null) session.close();
}
}
@@ -1937,7 +1937,7 @@ under the License.
<view-map name="EditAddContent" type="screen" page="component://content/widget/cms/CMSScreens.xml#EditAddContent"/>
<view-map name="EditAddSubContent" type="screen" page="component://content/widget/cms/CMSScreens.xml#EditAddSubContent"/>
<view-map name="ViewBinaryDataResource" page="" type="simplecontent"/>
<view-map name="ViewSimpleContent" page="" type="simplecontent"/>
<!-- lookup content component -->
@@ -299,9 +299,10 @@ under the License.
</sub-hyperlink>
</display-entity>
</field>
<field name="contentAssocTypeId"><display-entity entity-name="ContentAssocType"></display-entity></field>
<field name="contentAssocTypeId"><display-entity entity-name="ContentAssocType"/></field>
<field name="mapKey"><display/></field>
<field name="fromDate"><display description="${groovy:fromDate.toString().substring(0,10)}"/></field>
<field name="sequenceNum"><display/></field>
<field name="fromDate"><display type="date"/></field>
<field name="deleteLink" title=" " widget-style="buttontext">
<hyperlink description="${uiLabelMap.CommonDelete}" target="removeContentAssoc" also-hidden="false">
<parameter param-name="contentId"/>
@@ -311,7 +312,7 @@ under the License.
</hyperlink>
</field>
<field name="thruDate"><date-time/></field>
<field name="updateButton" title="${uiLabelMap.CommonUpdate}" widget-style="buttontext">
<field name="updateButton" widget-style="buttontext">
<submit button-type="text-link"/>
</field>
</form>
@@ -330,9 +331,10 @@ under the License.
</display-entity>
</field>
<field name="contentIdTo"><hidden/></field>
<field name="contentAssocTypeId"><display-entity entity-name="ContentAssocType"></display-entity></field>
<field name="contentAssocTypeId"><display-entity entity-name="ContentAssocType"/></field>
<field name="mapKey"><display/></field>
<field name="fromDate"><display description="${groovy:fromDate.toString().substring(0,10)}"/></field>
<field name="sequenceNum"><display/></field>
<field name="fromDate"><display type="date"/></field>
<field name="deleteLink" title=" " widget-style="buttontext">
<hyperlink description="${uiLabelMap.CommonDelete}" target="removeContentAssoc" also-hidden="false">
<parameter param-name="contentId"/>
@@ -342,7 +344,7 @@ under the License.
</hyperlink>
</field>
<field name="thruDate"><date-time/></field>
<field name="updateButton" title="${uiLabelMap.CommonUpdate}" widget-style="buttontext">
<field name="updateButton" widget-style="buttontext">
<submit button-type="text-link"/>
</field>
</form>
@@ -1609,5 +1609,9 @@ under the License.
<InventoryItem facilityId="WebStoreWarehouse" locationSeqId="TLTLTLUL01" datetimeReceived="2008-08-01 08:00:00.000"
inventoryItemId="9030" inventoryItemTypeId="NON_SERIAL_INV_ITEM" productId="MAT_B_COST" ownerPartyId="Company" currencyUomId="USD" unitCost="7.0"/>
<InventoryItemDetail inventoryItemId="9030" inventoryItemDetailSeqId="0001" effectiveDate="2001-05-13 12:00:00.0" availableToPromiseDiff="20" quantityOnHandDiff="20" accountingQuantityDiff="20"/>
<!-- defaut template screen use for Company -->
<CustomScreen customScreenId="DEFAULT_INV_TPL" customScreenTypeId="CST_INVOICE_TPL" customScreenName="DefaultInvoicePDF" customScreenLocation="component://accounting/widget/AccountingPrintScreens.xml"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="InvTplInvoice" partyId="Company" fromDate="2001-05-13 00:00:00" invoiceTypeId="INVOICE" customScreenId="DEFAULT_INV_TPL"/>
</entity-engine-xml>
@@ -218,4 +218,9 @@ under the License.
<!-- Demo WebSiteContactList -->
<WebSiteContactList webSiteId="WebStore" contactListId="9000" fromDate="2011-08-16 17:15:20.0"/>
<WebSiteContactList webSiteId="WebStore" contactListId="9010" fromDate="2011-08-16 17:15:20.0"/>
<SalesForecast currencyUomId="USD" forecastAmount="1000000.00" internalPartyId="SALES" organizationPartyId="Company" salesForecastId="1000"/>
<SalesForecastDetail amount="100000.00" productId="WG-9943" salesForecastDetailId="00001" salesForecastId="1000"/>
<SalesForecast currencyUomId="EUR" forecastAmount="20000.00" internalPartyId="DemoRepAll" organizationPartyId="EuroCustomer" salesForecastId="2000"/>
<SalesForecastDetail amount="20000.00" productCategoryId="SERV-001" salesForecastDetailId="00001" salesForecastId="2000"/>
</entity-engine-xml>
@@ -2600,5 +2600,15 @@ under the License.
<AgreementTerm agreementId="AGR_SALES" agreementItemSeqId="00001" agreementTermId="9000" description="Sales test agreement" termDays="30" termTypeId="FIN_PAYMENT_FIXDAY"/>
<!-- An AgreementProductAppls aris related to an AgreementItem. AgreementProductAppls are optional. If a product id and a price are specified the price will override the ProductPrice if the agreement is selected in the order -->
<AgreementProductAppl agreementId="AGR_SALES" agreementItemSeqId="00001" price="10.000" productId="GZ-1000"/>
<CustomScreen customScreenId="DEFAULT_ORD_TPL" customScreenTypeId="CST_ORDER_TPL" customScreenName="DefaultOrderPDF" customScreenLocation="component://order/widget/ordermgr/OrderPrintScreens.xml"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="OrdTplSales" partyId="Company" fromDate="2001-05-13 00:00:00" orderTypeId="SALES_ORDER" customScreenId="DEFAULT_ORD_TPL"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="OrdTplPurchase" partyId="Company" fromDate="2001-05-13 00:00:00" orderTypeId="PURCHASE_ORDER" customScreenId="DEFAULT_ORD_TPL"/>
<CustomScreen customScreenId="DEFAULT_QUOTE_TPL" customScreenTypeId="CST_QUOTE_TPL" customScreenName="DefaultQuotePDF" customScreenLocation="component://order/widget/ordermgr/QuoteScreens.xml"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="QuoTplOther" partyId="Company" fromDate="2001-05-13 00:00:00" quoteTypeId="OTHER_QUOTE" customScreenId="DEFAULT_QUOTE_TPL"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="QuoTplProposal" partyId="Company" fromDate="2001-05-13 00:00:00" quoteTypeId="PROPOSAL" customScreenId="DEFAULT_QUOTE_TPL"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="QuoTplProduct" partyId="Company" fromDate="2001-05-13 00:00:00" quoteTypeId="PRODUCT_QUOTE" customScreenId="DEFAULT_QUOTE_TPL"/>
<PartyPrefDocTypeTpl partyPrefDocTypeTplId="QuoTplPurchase" partyId="Company" fromDate="2001-05-13 00:00:00" quoteTypeId="PURCHASE_QUOTE" customScreenId="DEFAULT_QUOTE_TPL"/>
</entity-engine-xml>
@@ -856,7 +856,7 @@
<value xml:lang="zh-TW">技能等級</value>
</property>
<property key="FormFieldTitle_skillTypeId">
<value xml:lang="de">Fähigkeit Typ ID</value>
<value xml:lang="de">Fähigkeit Typ ID</value>
<value xml:lang="en">Skill Type ID</value>
<value xml:lang="es">Id tipo de habilidad</value>
<value xml:lang="fr">Compétence</value>
@@ -882,7 +882,7 @@
<value xml:lang="zh-TW">技能掌握日期</value>
</property>
<property key="FormFieldTitle_temporaryFlag">
<value xml:lang="de">temporäres Kennzeichen</value>
<value xml:lang="de">temporäres Kennzeichen</value>
<value xml:lang="en">Temporary Flag</value>
<value xml:lang="es">Indicador Principal</value>
<value xml:lang="fr">Balise temporaire</value>
@@ -895,7 +895,7 @@
<value xml:lang="zh-TW">是否為臨時</value>
</property>
<property key="FormFieldTitle_terminationReasonId">
<value xml:lang="de">Nummer des Kündigungsgrundes</value>
<value xml:lang="de">Nummer des Kündigungsgrundes</value>
<value xml:lang="en">Termination Reason ID</value>
<value xml:lang="es">Id de razón de finiquito</value>
<value xml:lang="fr">Motif de la fin de contrat</value>
@@ -908,7 +908,7 @@
<value xml:lang="zh-TW">雇佣終止原因識別</value>
</property>
<property key="FormFieldTitle_terminationTypeId">
<value xml:lang="de">Kündigungsart ID</value>
<value xml:lang="de">Kündigungsart ID</value>
<value xml:lang="en">Termination Type ID</value>
<value xml:lang="es">Id tipo de finiquito</value>
<value xml:lang="fr">Type de fin de contrat</value>
@@ -921,7 +921,7 @@
<value xml:lang="zh-TW">雇佣終止類型識別</value>
</property>
<property key="FormFieldTitle_title">
<value xml:lang="de">Titel</value>
<value xml:lang="de">Titel</value>
<value xml:lang="en">Title</value>
<value xml:lang="es">Título</value>
<value xml:lang="fr">Titre</value>
@@ -931,7 +931,7 @@
<value xml:lang="zh-TW">標題</value>
</property>
<property key="FormFieldTitle_trainingClassTypeId">
<value xml:lang="de">Nummer der Schulungsklasse</value>
<value xml:lang="de">Nummer der Schulungsklasse</value>
<value xml:lang="en">Training Class Type ID</value>
<value xml:lang="es">ID de tipo de clase de capacitación</value>
<value xml:lang="fr">Type de formation</value>
@@ -943,7 +943,7 @@
<value xml:lang="zh-TW">教育訓練課程類型識別</value>
</property>
<property key="FormFieldTitle_trainingRequestId">
<value xml:lang="de">Anfragenummer der Schulung</value>
<value xml:lang="de">Anfragenummer der Schulung</value>
<value xml:lang="en">Training Request ID</value>
<value xml:lang="es">ID de solicitud de capacitación</value>
<value xml:lang="fr">Approbation</value>
@@ -953,7 +953,7 @@
<value xml:lang="zh-TW">教育訓練請求標識</value>
</property>
<property key="FormFieldTitle_unemploymentClaimDate">
<value xml:lang="de">Datum des Arbeitslosenanspruches</value>
<value xml:lang="de">Datum des Arbeitslosenanspruches</value>
<value xml:lang="en">Unemployment Claim Date</value>
<value xml:lang="es">Fecha de reclamación por desempleo</value>
<value xml:lang="fr">Date de demande du chômage</value>
@@ -966,7 +966,7 @@
<value xml:lang="zh-TW">解除雇佣聲明日期</value>
</property>
<property key="FormFieldTitle_unemploymentClaimId">
<value xml:lang="de">Nummer Arbeitslosenanspruch</value>
<value xml:lang="de">Nummer Arbeitslosenanspruch</value>
<value xml:lang="en">Unemployment Claim ID</value>
<value xml:lang="es">ID de reclamo de desempleo</value>
<value xml:lang="fr">Date de demande du chômage</value>
@@ -979,7 +979,7 @@
<value xml:lang="zh-TW">解除雇佣聲明識別</value>
</property>
<property key="FormFieldTitle_verifStatusId">
<value xml:lang="de">Nummer des Überprüfungsstatus</value>
<value xml:lang="de">Nummer des Überprüfungsstatus</value>
<value xml:lang="en">Verif Status ID</value>
<value xml:lang="es">Id estado de verificación</value>
<value xml:lang="fr">Verifié</value>
@@ -1004,7 +1004,7 @@
<value xml:lang="zh-TW">工作經驗(年)</value>
</property>
<property key="HumanHolidayName">
<value xml:lang="de">Name des Feiertages</value>
<value xml:lang="de">Name des Feiertages</value>
<value xml:lang="en">Holiday Name</value>
<value xml:lang="es">Nombre del día de festivo</value>
<value xml:lang="ja">休日名</value>
@@ -1013,7 +1013,7 @@
<value xml:lang="zh-TW">假日名稱</value>
</property>
<property key="HumanResAddEmplLeave">
<value xml:lang="de">einfügen Urlaubsantrag</value>
<value xml:lang="de">einfügen Urlaubsantrag</value>
<value xml:lang="en">Add Employee Leave</value>
<value xml:lang="es">Agregar permiso de Empleado</value>
<value xml:lang="fr">Ajouter le congé</value>
@@ -1025,7 +1025,7 @@
<value xml:lang="zh-TW">新建員工請假</value>
</property>
<property key="HumanResAddEmplLeaveReasonType">
<value xml:lang="de">einfügen Urlaubsgrund Typ</value>
<value xml:lang="de">einfügen Urlaubsgrund Typ</value>
<value xml:lang="en">Add Employee Leave Reason</value>
<value xml:lang="es">Añadir rason de permiso</value>
<value xml:lang="fr">Ajouter un type de congé</value>
@@ -1036,7 +1036,7 @@
<value xml:lang="zh-TW">增加員工離職原因</value>
</property>
<property key="HumanResAddEmplLeaveType">
<value xml:lang="de">einfügen Urlaub Typ</value>
<value xml:lang="de">einfügen Urlaub Typ</value>
<value xml:lang="en">Add EmplLeave Types</value>
<value xml:lang="es">Agregar Tipo de permiso</value>
<value xml:lang="fr">Ajouter un type de congé</value>
@@ -1048,7 +1048,7 @@
<value xml:lang="zh-TW">新建員工請假類型</value>
</property>
<property key="HumanResAddEmplPositionFulfillment">
<value xml:lang="de">einfügen Erfüllung der Arbeitsposition</value>
<value xml:lang="de">einfügen Erfüllung der Arbeitsposition</value>
<value xml:lang="en">Add Position Fulfillment</value>
<value xml:lang="es">Añadir cumplimiento de cargo</value>
<value xml:lang="fr">Ajouter l'acquisition de position</value>
@@ -1060,7 +1060,7 @@
<value xml:lang="zh-TW">新建屬於該職位員工</value>
</property>
<property key="HumanResAddEmplPositionResponsibility">
<value xml:lang="de">einfügen einer Verantwortung durch eine Arbeitsposition</value>
<value xml:lang="de">einfügen einer Verantwortung durch eine Arbeitsposition</value>
<value xml:lang="en">Add Position Responsibility</value>
<value xml:lang="es">Añadir Cargo Responsabilidad</value>
<value xml:lang="fr">Ajouter la responsabilité de la position</value>
@@ -1072,7 +1072,7 @@
<value xml:lang="zh-TW">新建職位職責</value>
</property>
<property key="HumanResAddJobInterviewType">
<value xml:lang="de">einfügen Bewerbungsgespäch</value>
<value xml:lang="de">einfügen Bewerbungsgespäch</value>
<value xml:lang="en">Add Job Interview Type</value>
<value xml:lang="es">Añadir tipo de entrevista de trabajo</value>
<value xml:lang="fr">Ajouter un type d'entretien</value>
@@ -1083,7 +1083,7 @@
<value xml:lang="zh-TW">增加工作面試類型</value>
</property>
<property key="HumanResAddPartyBenefit">
<value xml:lang="de">einfügen Akteur Vorteil</value>
<value xml:lang="de">einfügen Akteur Vorteil</value>
<value xml:lang="en">Add Party Benefit</value>
<value xml:lang="es">Agregar beneficios de Participante</value>
<value xml:lang="fr">Ajouter l'avantage</value>
@@ -1095,7 +1095,7 @@
<value xml:lang="zh-TW">新建團體福利</value>
</property>
<property key="HumanResAddPartyQual">
<value xml:lang="de">einfügen Akteurqualifikation</value>
<value xml:lang="de">einfügen Akteurqualifikation</value>
<value xml:lang="en">Add Party Qualification</value>
<value xml:lang="es">Agregar calificación de participante</value>
<value xml:lang="fr">Ajouter la qualification</value>
@@ -1107,7 +1107,7 @@
<value xml:lang="zh-TW">增加團體資格</value>
</property>
<property key="HumanResAddPartySkill">
<value xml:lang="de">einfügen Akteurfähigkeit</value>
<value xml:lang="de">einfügen Akteurfähigkeit</value>
<value xml:lang="en">Add Party Skill</value>
<value xml:lang="es">Añadir habilidad del participante</value>
<value xml:lang="fr">Ajoutez la compétence</value>
@@ -1119,7 +1119,7 @@
<value xml:lang="zh-TW">增加團體技能</value>
</property>
<property key="HumanResAddPayrollPreference">
<value xml:lang="de">einfügen einer Abrechnungspräferenz</value>
<value xml:lang="de">einfügen einer Abrechnungspräferenz</value>
<value xml:lang="en">Add Payroll Preference</value>
<value xml:lang="es">Agregar preferencia de nómina</value>
<value xml:lang="fr">Ajouter la préférence de registre du personnel</value>
@@ -1131,7 +1131,7 @@
<value xml:lang="zh-TW">新建薪水支付方式</value>
</property>
<property key="HumanResAddPerfNote">
<value xml:lang="de">einfügen Leistungsnotiz</value>
<value xml:lang="de">einfügen Leistungsnotiz</value>
<value xml:lang="en">Add Performance Note</value>
<value xml:lang="es">Añadir nota de rendimiento</value>
<value xml:lang="fr">Ajouter la note de performance</value>
@@ -1143,7 +1143,7 @@
<value xml:lang="zh-TW">新建績效注釋</value>
</property>
<property key="HumanResAddPerfReviewItems">
<value xml:lang="de">einfügen einer Leistungsbewertung</value>
<value xml:lang="de">einfügen einer Leistungsbewertung</value>
<value xml:lang="en">Add PerfReview Items</value>
<value xml:lang="es">Agregar artículos de PerfReview</value>
<value xml:lang="fr">Ajouter des lignes d'évaluation de performance</value>
@@ -1155,7 +1155,7 @@
<value xml:lang="zh-TW">新建績效評定細項</value>
</property>
<property key="HumanResAddReportedToEmplPositionReportingStruct">
<value xml:lang="de">einfügen einer Arbeitspositionsreportstruktur [erstattet Bericht an ${parameters.emplPositionId}]</value>
<value xml:lang="de">einfügen einer Arbeitspositionsreportstruktur [erstattet Bericht an ${parameters.emplPositionId}]</value>
<value xml:lang="en">Add Empl Position Reporting Struct [Reported To ${parameters.emplPositionId}]</value>
<value xml:lang="es">Añadir estructura de informes de cargo de empleado [Reportar a ${parameters.emplPositionId}]</value>
<value xml:lang="fr">Ajouter le compte-rendu de position [en rapport avec ${parameters.emplPositionId}</value>
@@ -1167,7 +1167,7 @@
<value xml:lang="zh-TW">新建員工職位級別結構 [上級為 ${parameters.emplPositionId}]</value>
</property>
<property key="HumanResAddReportsToEmplPositionReportingStruct">
<value xml:lang="de">einfügen einer Arbeitspositionsreportstruktur [${parameters.emplPositionId} erstattet Bericht an]</value>
<value xml:lang="de">einfügen einer Arbeitspositionsreportstruktur [${parameters.emplPositionId} erstattet Bericht an]</value>
<value xml:lang="en">Add Empl Position Reporting Struct [${parameters.emplPositionId} Reports To]</value>
<value xml:lang="es">Añadir estructura de informes de cargo de empleado [${parameters.emplPositionId} Reportes a]</value>
<value xml:lang="fr">Ajouter le compte-rendu de position [${parameters.emplPositionId} qui se rapporte à]</value>
@@ -1690,7 +1690,7 @@
<value xml:lang="de">Stellenkürzel</value>
<value xml:lang="en">EmployeePosition ID</value>
<value xml:lang="es">Identificador del cargo del empleado</value>
<value xml:lang="fr">Position d'employé</value>
<value xml:lang="fr">Poste</value>
<value xml:lang="it">Codice Posizione Impiegato</value>
<value xml:lang="ja">従業員職位ID</value>
<value xml:lang="pt-BR">Id da posição do empregado</value>
@@ -1703,7 +1703,7 @@
<value xml:lang="de">Stellen Typ ID</value>
<value xml:lang="en">EmployeePosition Type ID</value>
<value xml:lang="es">Identificador del cargo del empleado</value>
<value xml:lang="fr">Type de position d'employé</value>
<value xml:lang="fr">Type de poste</value>
<value xml:lang="it">Codice Tipo Posizione Impiegato</value>
<value xml:lang="ja">従業員職位種類ID</value>
<value xml:lang="pt-BR">Id de tipo de posição do empregado</value>
@@ -2136,7 +2136,7 @@
<value xml:lang="zh-TW">離職請求新建成功</value>
</property>
<property key="HumanResLeaveStatus">
<value xml:lang="de">Urlaubsstatus</value>
<value xml:lang="de">Urlaubsstatus</value>
<value xml:lang="en">Leave</value>
<value xml:lang="es">Evento</value>
<value xml:lang="ja">休職</value>
@@ -2146,7 +2146,7 @@
<value xml:lang="zh-TW">離職</value>
</property>
<property key="HumanResListEmployments">
<value xml:lang="de">Liste der Anstellungen</value>
<value xml:lang="de">Liste der Anstellungen</value>
<value xml:lang="en">List Employment</value>
<value xml:lang="es">Lista de empleados</value>
<value xml:lang="fr">Liste d'emplois</value>
@@ -2159,7 +2159,7 @@
<value xml:lang="zh-TW">雇佣列表</value>
</property>
<property key="HumanResListPartyBenefits">
<value xml:lang="de">Liste Akteurvorteile</value>
<value xml:lang="de">Liste Akteurvorteile</value>
<value xml:lang="en">List Party Benefits</value>
<value xml:lang="es">List de Beneficios de Participante</value>
<value xml:lang="fr">Liste d'avantages de l'acteur</value>
@@ -2172,7 +2172,7 @@
<value xml:lang="zh-TW">團體福利清單</value>
</property>
<property key="HumanResListPayHistories">
<value xml:lang="de">Liste der Zahlhistorie</value>
<value xml:lang="de">Liste der Zahlhistorie</value>
<value xml:lang="en">List Pay Histories</value>
<value xml:lang="es">Lista de historial de pago</value>
<value xml:lang="fr">Liste d'historique de salaires</value>
@@ -2185,7 +2185,7 @@
<value xml:lang="zh-TW">薪水歷史清單</value>
</property>
<property key="HumanResListPayrollPreferences">
<value xml:lang="de">Liste der Lohnzahlungspräferenzen</value>
<value xml:lang="de">Liste der Lohnzahlungspräferenzen</value>
<value xml:lang="en">List Payroll Preferences</value>
<value xml:lang="es">Lista de preferencias de nómina</value>
<value xml:lang="fr">Liste des préférences de registre du personnel</value>
@@ -2198,7 +2198,7 @@
<value xml:lang="zh-TW">薪水支付方式清單</value>
</property>
<property key="HumanResListSkillTypes">
<value xml:lang="de">Liste der Fähigkeiten</value>
<value xml:lang="de">Liste der Fähigkeiten</value>
<value xml:lang="en">List Skill Types</value>
<value xml:lang="es">Lista de tipos de habilidades</value>
<value xml:lang="fr">Liste de types de compétence</value>
@@ -2211,7 +2211,7 @@
<value xml:lang="zh-TW">技能類型清單</value>
</property>
<property key="HumanResListValidResponsibility">
<value xml:lang="de">Liste der gültigen Zuständigkeiten</value>
<value xml:lang="de">Liste der gültigen Zuständigkeiten</value>
<value xml:lang="en">List Valid Responsibility</value>
<value xml:lang="es">Lista de validadeción de responsabilidades</value>
<value xml:lang="fr">Liste de responsabilité valide</value>
@@ -2224,7 +2224,7 @@
<value xml:lang="zh-TW">有效責任清單</value>
</property>
<property key="HumanResLookupAgreement">
<value xml:lang="de">ersuchte Vereinbarung</value>
<value xml:lang="de">ersuchte Vereinbarung</value>
<value xml:lang="en">Lookup Agreement</value>
<value xml:lang="es">Búsqueda de contrato</value>
<value xml:lang="fr">Consultation d'accord</value>
@@ -2236,7 +2236,7 @@
<value xml:lang="zh-TW">查詢合約</value>
</property>
<property key="HumanResLookupAgreementEmploymentAppl">
<value xml:lang="de">Beratung bzgl des Arbeitsvertrages</value>
<value xml:lang="de">Beratung bzgl des Arbeitsvertrages</value>
<value xml:lang="en">Lookup AgreementEmploymentAppl</value>
<value xml:lang="es">Busqueda AgreementEmploymentAppl</value>
<value xml:lang="fr">Consultation d'accord sur demande d'emploi</value>
@@ -2248,7 +2248,7 @@
<value xml:lang="zh-TW">查詢雇佣合約</value>
</property>
<property key="HumanResLookupAgreementId">
<value xml:lang="de">Beratungsnummer des Vertrages</value>
<value xml:lang="de">Beratungsnummer des Vertrages</value>
<value xml:lang="en">Lookup AgreementId</value>
<value xml:lang="es">Id Contrato de busqueda</value>
<value xml:lang="fr">Consultation d'accord</value>
@@ -2260,7 +2260,7 @@
<value xml:lang="zh-TW">查詢合約識別</value>
</property>
<property key="HumanResLookupAgreementItemSeqId">
<value xml:lang="de">Beratungsindex des Vertrages</value>
<value xml:lang="de">Beratungsindex des Vertrages</value>
<value xml:lang="en">Lookup AgreementItemSeqId</value>
<value xml:lang="es">Ver AgreementItemSeqId</value>
<value xml:lang="fr">Consultation de ligne séq. d'accord</value>
@@ -2272,7 +2272,7 @@
<value xml:lang="zh-TW">查詢合約細項序號</value>
</property>
<property key="HumanResLookupApplicationId">
<value xml:lang="de">Einsicht der Bewerbungnummer</value>
<value xml:lang="de">Einsicht der Bewerbungnummer</value>
<value xml:lang="en">Lookup ApplicationId</value>
<value xml:lang="es">Ver solicitud Id</value>
<value xml:lang="es-CL">ver solicitud Id</value>
@@ -2285,7 +2285,7 @@
<value xml:lang="zh-TW">查詢應聘求職識別</value>
</property>
<property key="HumanResLookupBudgetByName">
<value xml:lang="de">Einsicht Budget nach Name </value>
<value xml:lang="de">Einsicht Budget nach Name </value>
<value xml:lang="en">Lookup Budget by Name</value>
<value xml:lang="es">Ver presupuesto por nombre</value>
<value xml:lang="fr">Consultation de budget par nom</value>
@@ -2298,7 +2298,7 @@
<value xml:lang="zh-TW">按名稱查詢預算</value>
</property>
<property key="HumanResLookupBudgetItemByName">
<value xml:lang="de">Einsicht Budgetobjekt nach Name</value>
<value xml:lang="de">Einsicht Budgetobjekt nach Name</value>
<value xml:lang="en">Lookup Budget Item by Name</value>
<value xml:lang="es">Ver un Item presupuesto por nombre</value>
<value xml:lang="es-CL">ver un Item presupuesto por nombre</value>
@@ -2312,7 +2312,7 @@
<value xml:lang="zh-TW">按名稱查詢預算細項</value>
</property>
<property key="HumanResLookupEmploymentApp">
<value xml:lang="de"></value>
<value xml:lang="de"></value>
<value xml:lang="en">Lookup EmploymentApp</value>
<value xml:lang="es">Busqueda EmploymentApp</value>
<value xml:lang="fr">Consultation des demandes d'emploi</value>
@@ -2510,7 +2510,7 @@
<value xml:lang="zh-TW">人力資源管理系統</value>
</property>
<property key="HumanResMyLeaves">
<value xml:lang="de">Mein Urlaub</value>
<value xml:lang="de">Mein Urlaub</value>
<value xml:lang="en">My Leaves</value>
<value xml:lang="es">Mis salidas</value>
<value xml:lang="fr">Mes congés</value>
@@ -2571,7 +2571,7 @@
<value xml:lang="de">Stelle anlegen</value>
<value xml:lang="en">New Employee Position</value>
<value xml:lang="es">Nuevo cargo de empleado</value>
<value xml:lang="fr">Nouvelle position d'employé</value>
<value xml:lang="fr">Nouveau poste</value>
<value xml:lang="it">Nuova Posizione Impiegato</value>
<value xml:lang="ja">新規従業員職位</value>
<value xml:lang="pt-BR">Nova posição de empregado</value>
@@ -2584,7 +2584,7 @@
<value xml:lang="de">Neue Stellenvorraussetzung</value>
<value xml:lang="en">New Employee Position Fulfillment</value>
<value xml:lang="es">Nuevo cumplimiento de cargo</value>
<value xml:lang="fr">Nouveau pourvoiement de position d'employé</value>
<value xml:lang="fr">Nouvelle offre d'emploi</value>
<value xml:lang="it">Nuova Posizione Impiegato Adempimento</value>
<value xml:lang="ja">新規従業員職位遂行</value>
<value xml:lang="pt-BR">Novo Preenchimento de posição de empregado</value>
@@ -2665,7 +2665,7 @@
<value xml:lang="zh-TW">新建工作單</value>
</property>
<property key="HumanResNewLeave">
<value xml:lang="de">Neu Urlaub</value>
<value xml:lang="de">Neu Urlaub</value>
<value xml:lang="en">New Leave</value>
<value xml:lang="es">Nuevo Evento</value>
<value xml:lang="fr">Nouveau congé</value>
@@ -3097,7 +3097,7 @@
<value xml:lang="de">Stellenkriterien</value>
<value xml:lang="en">Fulfillments</value>
<value xml:lang="es">Cumplimientos</value>
<value xml:lang="fr">"Pourvoiements"</value>
<value xml:lang="fr">Offres de postes</value>
<value xml:lang="it">Adempimento</value>
<value xml:lang="ja">遂行</value>
<value xml:lang="pt-BR">Execuções</value>
@@ -3128,7 +3128,7 @@
<value xml:lang="zh-TW">招聘</value>
</property>
<property key="HumanResRelocation">
<value xml:lang="de">Standortwechsel</value>
<value xml:lang="de">Standortwechsel</value>
<value xml:lang="en">Relocation</value>
<value xml:lang="es">Reubicación</value>
<value xml:lang="ja">配置転換</value>
@@ -3237,6 +3237,11 @@
<value xml:lang="zh">技能类型编号</value>
<value xml:lang="zh-TW">技能類型識別</value>
</property>
<property key="HumanResSkill">
<value xml:lang="de">Fähigkeit</value>
<value xml:lang="en">Skill</value>
<value xml:lang="nl">Vaardigheid</value>
</property>
<property key="HumanResSkills">
<value xml:lang="de">Fähigkeiten</value>
<value xml:lang="en">Skills</value>
@@ -3244,6 +3249,7 @@
<value xml:lang="fr">Compétences</value>
<value xml:lang="it">Abilità</value>
<value xml:lang="ja">スキル</value>
<value xml:lang="nl">Vaardigheden</value>
<value xml:lang="pt-BR">Habilidades</value>
<value xml:lang="vi">Kỹ năng</value>
<value xml:lang="zh">技能管理</value>
@@ -3459,7 +3465,7 @@
<value xml:lang="zh-TW">編輯面試</value>
</property>
<property key="PageTitleEditJobInterviewType">
<value xml:lang="de">Bearbeitung Typ des Bewerbungsgespräches</value>
<value xml:lang="de">Bearbeitung Typ des Bewerbungsgespräches</value>
<value xml:lang="en">Edit Job Interview Type</value>
<value xml:lang="es">Editar tipo de entrevista de trabajo</value>
<value xml:lang="fr">Modifier les types d'entretiens</value>
@@ -3566,7 +3572,7 @@
<value xml:lang="zh-TW">尋找核准</value>
</property>
<property key="PageTitleFindInternalJobPosting">
<value xml:lang="de">Suchmaske interne Stellenausschreibung</value>
<value xml:lang="de">Suchmaske interne Stellenausschreibung</value>
<value xml:lang="en">Find Internal Job Posting</value>
<value xml:lang="es">Buscar publicaciones internas de trabajo</value>
<value xml:lang="fr">Rechercher des offres d'emploi internes</value>
@@ -3599,7 +3605,7 @@
<value xml:lang="zh-TW">尋找工作單</value>
</property>
<property key="PageTitleFindRelocationDetails">
<value xml:lang="de">Suchmaske Standortwechsel</value>
<value xml:lang="de">Suchmaske Standortwechsel</value>
<value xml:lang="en">Find Relocation Details</value>
<value xml:lang="es">Buscar detalles de reubicaión</value>
<value xml:lang="ja">配置転換詳細を検索</value>
@@ -3669,7 +3675,7 @@
<value xml:lang="de">Übersicht Stellenvorraussetzungen</value>
<value xml:lang="en">List EmplPosition Fulfillments</value>
<value xml:lang="es">Lista de cumplimientos de cargo</value>
<value xml:lang="fr">Liste des "pourvoiements" de position</value>
<value xml:lang="fr">Liste des offres de postes</value>
<value xml:lang="it">Lista Posizione Impiegato Adempimenti</value>
<value xml:lang="ja">従業員職位遂行一覧</value>
<value xml:lang="pt-BR">Listar preenchimento de posições de empregado</value>
@@ -175,7 +175,9 @@ under the License.
<widgets>
<decorator-screen name="EmployeeDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<include-form name="ListEmployeeSkills" location="component://humanres/widget/forms/EmployeeForms.xml"/>
<screenlet>
<include-grid name="ListEmployeeSkills" location="component://humanres/widget/forms/EmployeeForms.xml"/>
</screenlet>
<screenlet id="AddPartySkillPanel" title="${uiLabelMap.HumanResAddPartySkill}" collapsible="true">
<include-form name="AddEmployeeSkills" location="component://humanres/widget/forms/EmployeeForms.xml"/>
</screenlet>
@@ -198,6 +200,9 @@ under the License.
<widgets>
<decorator-screen name="EmployeeDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<screenlet>
<include-grid name="ListEmployeeQualification" location="component://humanres/widget/forms/EmployeeForms.xml"/>
</screenlet>
<include-form name="ListEmployeeQualification" location="component://humanres/widget/forms/EmployeeForms.xml"/>
<screenlet id="AddPartyQualPanel" title="${uiLabelMap.HumanResAddPartyQual}" collapsible="true">
<include-form name="AddEmployeeQualification" location="component://humanres/widget/forms/EmployeeForms.xml"/>
@@ -297,7 +302,9 @@ under the License.
<widgets>
<decorator-screen name="EmployeeDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<include-form name="ListEmplLeaves" location="component://humanres/widget/forms/EmployeeForms.xml"/>
<screenlet>
<include-form name="ListEmplLeaves" location="component://humanres/widget/forms/EmployeeForms.xml"/>
</screenlet>
<screenlet id="AddEmplLeavePanel" title="${uiLabelMap.HumanResAddEmplLeave}" collapsible="true">
<include-form name="AddEmplLeave" location="component://humanres/widget/forms/EmployeeForms.xml"/>
</screenlet>
@@ -318,17 +325,15 @@ under the License.
</widgets>
</section>
</screen>
<screen name="trainingsList">
<section>
<widgets>
<screenlet title="${uiLabelMap.HumanResTrainings}">
<include-form name="SimpleListTrainingStatus" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
<include-grid name="SimpleListTrainingStatus" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
</screenlet>
</widgets>
</section>
</screen>
<screen name="PayrollHistory">
<section>
<actions>
@@ -348,13 +353,14 @@ under the License.
<widgets>
<decorator-screen name="EmployeeDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<include-form name="PayrollHistoryList" location="component://humanres/widget/forms/EmployeeForms.xml"/>
<screenlet>
<include-grid name="PayrollHistoryList" location="component://humanres/widget/forms/EmployeeForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
</widgets>
</section>
</screen>
<screen name="MyLeaveList">
<section>
<actions>
@@ -374,7 +380,7 @@ under the License.
</actions>
<widgets>
<screenlet title="${uiLabelMap.HumanResMyTrainings}">
<include-form name="ListEmplTrainings" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
<include-grid name="ListEmplTrainings" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
</screenlet>
</widgets>
</section>
@@ -35,7 +35,7 @@
<menu-item name="GlobalHRSettings" title="${uiLabelMap.HumanResGlobalHRSettings}" selected-style="selected"><link target="globalHRSettings"/></menu-item>
</menu>
<menu name="MainActionMenu" menu-container-style="button-bar button-style-2" default-selected-style="selected">
<menu-item name="NewEmployee" title="${uiLabelMap.CommonNew} ${uiLabelMap.Employee}">
<menu-item name="NewEmployee" title="${uiLabelMap.HumanResNewEmployee}">
<condition>
<or>
<if-has-permission permission="HUMANRES" action="_CREATE"/>
@@ -43,7 +43,7 @@
</condition>
<link target="NewEmployee"/>
</menu-item>
<menu-item name="NewPosition" title="${uiLabelMap.CommonNew} ${uiLabelMap.Position}">
<menu-item name="NewPosition" title="${uiLabelMap.HumanResNewEmplPosition}">
<condition>
<or>
<if-has-permission permission="HUMANRES" action="_CREATE"/>
@@ -51,7 +51,7 @@
</condition>
<link target="EditEmplPosition"/>
</menu-item>
<menu-item name="NewFulfilmennt" title="${uiLabelMap.CommonNew} ${uiLabelMap.Fulfilmnent}">
<menu-item name="NewFulfilmennt" title="${uiLabelMap.HumanResNewEmplPositionFulfillment}">
<condition>
<or>
<if-has-permission permission="HUMANRES" action="_CREATE"/>
@@ -59,7 +59,7 @@
</condition>
<link target="EditEmplPositionFulfillments"/>
</menu-item>
<menu-item name="NewPerformanceReview" title="${uiLabelMap.CommonNew} ${uiLabelMap.CommonReview}">
<menu-item name="NewPerformanceReview" title="${uiLabelMap.HumanResNewPartyReview}">
<condition>
<or>
<if-has-permission permission="HUMANRES" action="_CREATE"/>
@@ -67,7 +67,7 @@
</condition>
<link target="EditPerfReview"/>
</menu-item>
<menu-item name="NewLeave" title="${uiLabelMap.CommonNew} ${uiLabelMap.HumanResEmplLeave}">
<menu-item name="NewLeave" title="${uiLabelMap.HumanResAddEmplLeave}">
<condition>
<or>
<if-has-permission permission="HUMANRES" action="_CREATE"/>
@@ -46,7 +46,7 @@
<include-form name="FindPerfReviews" location="component://humanres/widget/forms/PerfReviewForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListPerfReviews" location="component://humanres/widget/forms/PerfReviewForms.xml"/>
<include-grid name="ListPerfReviews" location="component://humanres/widget/forms/PerfReviewForms.xml"/>
</decorator-section>
</decorator-screen>
</decorator-section>
@@ -93,10 +93,12 @@
<widgets>
<decorator-screen name="CommonPerfReviewDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<include-form name="ListPerfReviewItems" location="component://humanres/widget/forms/PerfReviewForms.xml"/>
<screenlet id="AddPerfReviewItemPanel" title="${uiLabelMap.HumanResAddPerfReviewItems}" collapsible="true">
<include-form name="AddPerfReviewItem" location="component://humanres/widget/forms/PerfReviewForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.CommonItems}">
<include-grid name="ListPerfReviewItems" location="component://humanres/widget/forms/PerfReviewForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
</widgets>
@@ -160,7 +160,7 @@
</container>
<container style="righthalf">
<label style="h1" text="${uiLabelMap.WorkEffortParticipants}"/>
<include-form name="ListTrainingParticipants" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
<include-grid name="ListTrainingParticipants" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
<section>
<condition>
<and>
@@ -208,7 +208,7 @@
<include-form name="FindTrainingApprovals" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListTrainingApprovals" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
<include-grid name="ListTrainingApprovals" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
</decorator-section>
</decorator-screen>
</decorator-section>
@@ -255,7 +255,7 @@
<include-form name="FindTrainingStatus" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListTrainingStatus" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
<include-grid name="ListTrainingStatus" location="component://humanres/widget/forms/PersonTrainingForms.xml"/>
</decorator-section>
</decorator-screen>
</decorator-section>
@@ -20,7 +20,7 @@ under the License.
<screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://ofbiz.apache.org/Widget-Screen" xsi:schemaLocation="http://ofbiz.apache.org/Widget-Screen http://ofbiz.apache.org/dtds/widget-screen.xsd">
<screen name="FindJobRequisitions">
<section>
<section>
<actions>
<set field="titleProperty" value="PageTitleFindJobRequisition"/>
<set field="tabButtonItem" value="JobRequisition"/>
@@ -54,7 +54,7 @@ under the License.
<include-form name="FindJobRequisitions" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListJobRequisitions" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
<include-grid name="ListJobRequisitions" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -124,7 +124,7 @@ under the License.
<include-form name="FindInternalJobPosting" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListInternalJobPosting" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
<include-grid name="ListInternalJobPosting" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -187,7 +187,7 @@ under the License.
<include-form name="FindJobInterview" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListInterview" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
<include-grid name="ListInterview" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -249,7 +249,7 @@ under the License.
<include-form name="FindApprovals" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListApprovals" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
<include-grid name="ListApprovals" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -302,7 +302,7 @@ under the License.
<include-form name="FindRelocation" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListRelocation" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
<include-grid name="ListRelocation" location="component://humanres/widget/forms/RecruitmentForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -80,7 +80,7 @@
<field name="skillLevel"><text/></field>
<field name="submitButton" title="${uiLabelMap.CommonCreate}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListEmployeeSkills" type="list" list-name="listIt" use-row-submit="true" separate-columns="true" target="updateEmployeeSkill" paginate-target="findPartySkills"
<grid name="ListEmployeeSkills" list-name="listIt" use-row-submit="true" separate-columns="true" target="updateEmployeeSkill" paginate-target="findPartySkills"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<entity-condition entity-name="PartySkill">
@@ -89,7 +89,7 @@
</entity-condition>
</actions>
<auto-fields-service default-field-type="hidden" service-name="updatePartySkill"/>
<field name="skillTypeId">
<field name="skillTypeId" title="${uiLabelMap.CommonType}">
<display-entity entity-name="SkillType"/>
</field>
<field name="yearsExperience"><text/></field>
@@ -102,7 +102,7 @@
</hyperlink>
</field>
<field name="submitButton" title="${uiLabelMap.CommonUpdate}"><submit button-type="button"/></field>
</form>
</grid>
<form name="AddEmployeeQualification" type="single" target="createEmployeeQualification">
<auto-fields-service service-name="createPartyQual"/>
<field name="partyId"><hidden/></field>
@@ -131,7 +131,7 @@
</field>
<field name="submitButton" title="${uiLabelMap.CommonCreate}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListEmployeeQualification" type="list" list-name="listIt" use-row-submit="true" separate-columns="true" target="updateEmployeeQualification" paginate-target="FindPartyQuals"
<grid name="ListEmployeeQualification" list-name="listIt" use-row-submit="true" separate-columns="true" target="updateEmployeeQualification" paginate-target="FindPartyQuals"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<entity-condition entity-name="PartyQual">
@@ -141,11 +141,11 @@
</actions>
<auto-fields-service service-name="updatePartyQual"/>
<field name="partyId"><hidden/></field>
<field name="partyQualTypeId"><display-entity entity-name="PartyQualType"/></field>
<field name="fromDate"><display/></field>
<field name="qualificationDesc"><text/></field>
<field name="partyQualTypeId" title="${uiLabelMap.CommonType}"><display-entity entity-name="PartyQualType"/></field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display/></field>
<field name="qualificationDesc" title="${uiLabelMap.CommonDescription}"><text/></field>
<field name="title"><text/></field>
<field name="statusId">
<field name="statusId" title="${uiLabelMap.CommonStatus}">
<drop-down allow-empty="true">
<entity-options key-field-name="statusId" entity-name="StatusItem">
<entity-constraint name="statusTypeId" operator="equals" value="PARTY_INV_STATUS"/>
@@ -170,7 +170,7 @@
</hyperlink>
</field>
<field name="submitButton" title="${uiLabelMap.CommonSubmit}" widget-style="smallSubmit"><submit/></field>
</form>
</grid>
<form name="AddEmployeeTraining" type="single" target="createEmployeeTraining">
<field name="partyId"><hidden/></field>
<field name="trainingClassTypeId" required-field="true">
@@ -203,7 +203,7 @@
<field name="approverPartyId" required-field="true"><lookup target-form-name="LookupPartyName"/></field>
<field name="submitButton" title="${uiLabelMap.CommonCreate}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListEmplLeaves" type="list" list-name="listIt" separate-columns="true" target="updateEmplLeave" paginate-target="FindEmplLeaves"
<grid name="ListEmplLeaves" list-name="listIt" separate-columns="true" target="updateEmplLeave" paginate-target="FindEmplLeaves"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<entity-condition entity-name="EmplLeave">
@@ -216,10 +216,10 @@
<field name="approverPartyId"><lookup target-form-name="LookupPartyName"/></field>
<field name="leaveStatus"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="emplLeaveReasonTypeId"><display/></field>
<field name="leaveTypeId"><display-entity entity-name="EmplLeaveType"/></field>
<field name="fromDate"></field>
<field name="leaveTypeId" title="${uiLabelMap.CommonType}"><display-entity entity-name="EmplLeaveType"/></field>
<field name="fromDate" title="${uiLabelMap.CommonGrom}"></field>
<field name="submitButton" title="${uiLabelMap.CommonUpdate}"><submit button-type="button"/></field>
</form>
</grid>
<form name="CurrentEmploymentData" default-map-name="employmentData" type="single">
<field name="company" entry-name="employment.partyIdFrom">
<display-entity entity-name="PartyNameView" key-field-name="partyId" description="${groupName} ">
@@ -237,12 +237,12 @@
<display type="currency" currency="${employmentData.emplPositionRateAmount.rateCurrencyUomId}"/>
</field>
</form>
<form name="PayrollHistoryList" type="list" list-name="payroll" extends="ListInvoices" extends-resource="component://accounting/widget/InvoiceForms.xml" paginate-target="PayrollHistory">
<grid name="PayrollHistoryList" list-name="payroll" extends="ListInvoices" extends-resource="component://accounting/widget/InvoiceForms.xml" paginate-target="PayrollHistory">
<field name="invoiceId" widget-style="buttontext" sort-field="true">
<hyperlink description="${invoiceId}" target="/accounting/control/invoiceOverview" target-type="inter-app">
<parameter param-name="invoiceId"/>
</hyperlink>
</field>
</form>
</grid>
</forms>
@@ -32,7 +32,7 @@ under the License.
<field name="emplPositionId" title="${uiLabelMap.FormFieldTitle_emplPositionId}"><lookup target-form-name="LookupEmplPosition"/></field>
<field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListPerfReviews" type="list" title="" separate-columns="true" default-entity-name="PerfReview" list-name="listIt" paginate-target="FindPerfReviews" paginate="true"
<grid name="ListPerfReviews" list-name="listIt" separate-columns="true" default-entity-name="PerfReview" paginate-target="FindPerfReviews" paginate="true"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -65,7 +65,7 @@ under the License.
</field>
<field name="fromDate"><display type="date"/></field>
<field name="thruDate"><display type="date"/></field>
</form>
</grid>
<form name="EditPerfReview" type="single" target="updatePerfReview" title="" default-map-name="perfReview"
header-row-style="header-row" default-table-style="basic-table">
<alt-target use-when="perfReview==null" target="createPerfReview"/>
@@ -87,7 +87,7 @@ under the License.
<field name="submitButton" use-when="perfReview==null" title="${uiLabelMap.CommonCreate}" widget-style="smallSubmit"><submit button-type="button"/></field>
<field name="submitButton" use-when="perfReview!=null" title="${uiLabelMap.CommonUpdate}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListPerfReviewItems" type="list" target="updatePerfReviewItem" title="updatePerfReviewItem" paginate-target="findPerfReviewItems"
<grid name="ListPerfReviewItems" target="updatePerfReviewItem" title="updatePerfReviewItem" paginate-target="findPerfReviewItems"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<entity-condition entity-name="PerfReviewItem">
@@ -109,7 +109,7 @@ under the License.
<parameter param-name="perfReviewItemSeqId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="AddPerfReviewItem" type="single" target="createPerfReviewItem" title=""
header-row-style="header-row" default-table-style="basic-table">
<auto-fields-service service-name="createPerfReviewItem"/>
@@ -63,7 +63,8 @@ under the License.
<field name="roleTypeId"> <hidden value="CAL_ATTENDEE"/></field>
<field name="add" title="${uiLabelMap.CommonAdd}"><submit/></field>
</form>
<form name="ListTrainingParticipants" list-name="listIt" title="" type="list" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<grid name="ListTrainingParticipants" list-name="listIt"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
<field-map field-name="inputFields" from-field="parameters"/>
@@ -80,10 +81,10 @@ under the License.
</sub-hyperlink>
</display-entity>
</field>
<field name="approvalStatus"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="approvalStatus" title="${uiLabelMap.CommonStatus}"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="trainingRequestId" widget-style="buttontext"><display/></field>
<field name="trainingClassTypeId"><display-entity entity-name="TrainingClassType"/></field>
</form>
</grid>
<form name="FindTrainingApprovals" target="FindTrainingApprovals" title="" type="single" default-title-style="tableheadtext" default-widget-style="inputBox">
<auto-fields-entity entity-name="PersonTraining" default-field-type="find"/>
<field name="partyId" title="${uiLabelMap.FormFieldTitle_employeePartyId}"><lookup target-form-name="LookupPartyName"/></field>
@@ -99,7 +100,8 @@ under the License.
<field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
<field name="submitButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListTrainingApprovals" type="list" list-name="listIt" target="updateTrainingStatus" title="" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<grid name="ListTrainingApprovals" list-name="listIt" target="updateTrainingStatus"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
<field-map field-name="inputFields" from-field="parameters"/>
@@ -133,9 +135,9 @@ under the License.
<parameter param-name="fromDate"/>
</hyperlink>
</field>
<field name="approvalStatus"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="approvalStatus" title="${uiLabelMap.CommonStatus}"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="trainingClassTypeId"><display-entity entity-name="TrainingClassType"/></field>
</form>
</grid>
<form name="EditTrainingApprovals" type="single" target="updateTrainingStatus" default-map-name="personTraining">
<auto-fields-service service-name="updateTrainingStatus" default-field-type="display"/>
<field name="partyId" title="${uiLabelMap.FormFieldTitle_employeePartyId}"/>
@@ -169,7 +171,8 @@ under the License.
<field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
<field name="submitButton" title="${uiLabelMap.CommonSearch}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListTrainingStatus" list-name="listIt" title="" type="list" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<grid name="ListTrainingStatus" list-name="listIt"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
<field-map field-name="inputFields" from-field="parameters"/>
@@ -193,13 +196,13 @@ under the License.
</sub-hyperlink>
</display-entity>
</field>
<field name="trainingRequestId" widget-style="buttontext"/>
<field name="trainingRequestId" title="${uiLabelMap.CommmonRequest}" widget-style="buttontext"/>
<field name="trainingClassTypeId" title="${uiLabelMap.HumanResTrainingClassType}"/>
<field name="approvalStatus"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="approvalStatus" title="${uiLabelMap.CommonStatus}"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="trainingClassTypeId"><display-entity entity-name="TrainingClassType"/></field>
</form>
<form name="SimpleListTrainingStatus" list-name="listIt" title="" type="list" odd-row-style="alternate-row" default-table-style="basic-table">
</grid>
<grid name="SimpleListTrainingStatus" list-name="listIt"
odd-row-style="alternate-row" default-table-style="basic-table">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
<field-map field-name="inputFields" from-field="parameters"/>
@@ -209,17 +212,16 @@ under the License.
<field-map field-name="viewSize" from-field="viewSize"/>
</service>
</actions>
<field name="fromDate"><display type="date-time"/></field>
<field name="thruDate"><display type="date-time"/></field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display type="date-time"/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}"><display type="date-time"/></field>
<field name="trainingClassTypeId" title="${uiLabelMap.HumanResTrainingClassType}"/>
<field name="approvalStatus"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="approvalStatus" title="${uiLabelMap.CommonStatus}"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="trainingClassTypeId"><display-entity entity-name="TrainingClassType"/></field>
<field name="approverId" widget-style="buttontext">
<display-entity entity-name="PartyNameView" key-field-name="partyId" description="${firstName} ${middleName} ${lastName} ${groupName}"/>
</field>
</form>
<form name="ListEmplTrainings" type="list" list-name="listIt" separate-columns="true" target="updateEmplLeave" paginate-target="FindEmplLeaves"
</grid>
<grid name="ListEmplTrainings" list-name="listIt" target="updateEmplLeave" paginate-target="FindEmplLeaves" separate-columns="true"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<entity-condition entity-name="PersonTraining">
@@ -234,9 +236,9 @@ under the License.
<field name="approverId">
<display-entity entity-name="PartyNameView" key-field-name="partyId" description="${firstName} ${middleName} ${lastName} ${groupName}"/>
</field>
<field name="trainingRequestId"/>
<field name="trainingRequestId" title="${CommonRequest}"/>
<field name="trainingClassTypeId" title="${uiLabelMap.HumanResTrainingClassType}"/>
<field name="approvalStatus"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="approvalStatus" title="${CommonStatus}"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="trainingClassTypeId"><display-entity entity-name="TrainingClassType"/></field>
</form>
</grid>
</forms>
@@ -59,8 +59,8 @@ under the License.
<field name="qualification"><hidden/></field>
<field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListJobRequisitions" list-name="listIt" type="list" odd-row-style="alternate-row" header-row-style="header-row-2"
paginate-target="FindJobRequisitions" default-table-style="basic-table hover-bar">
<grid name="ListJobRequisitions" list-name="listIt" paginate-target="FindJobRequisitions"
default-table-style="basic-table hover-bar" odd-row-style="alternate-row" header-row-style="header-row-2">
<actions>
<set field="entityName" value="JobRequisition"/>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -70,19 +70,19 @@ under the License.
<field-map field-name="viewSize" from-field="viewSize"/>
</service>
</actions>
<field name="jobRequisitionId" widget-style="buttontext" use-when="hasAdminPermission">
<field name="jobRequisitionId" title="${uiLabelMap.CommonId}" widget-style="buttontext" use-when="hasAdminPermission">
<hyperlink description="${jobRequisitionId}" target="EditJobRequisition">
<parameter param-name="jobRequisitionId"/>
</hyperlink>
</field>
<field name="jobRequisitionId" use-when="!hasAdminPermission"><display/></field>
<field name="jobRequisitionId" title="${uiLabelMap.CommonId}" use-when="!hasAdminPermission"><display/></field>
<field name="skillTypeId">
<display-entity entity-name="SkillType"/>
</field>
<field name="jobPostingTypeEnumId"><display/></field>
<field name="examTypeEnumId"><display/></field>
<field name="qualification"><display/></field>
<field name="jobLocation"><display/></field>
<field name="jobLocation" title="${uiLabelMap.CommonLocation}"><display/></field>
<field name="experienceYears"><display/></field>
<field name="experienceMonths"><display/></field>
<field name="applyLink" title="${uiLabelMap.CommonApply}" widget-style="buttontext">
@@ -95,7 +95,7 @@ under the License.
<parameter param-name="jobRequisitionId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="EditJobRequisition" type="single" target="updateJobRequisition" default-map-name="jobRequisition">
<alt-target use-when="jobRequisition==null" target="createJobRequisition"/>
<field name="jobRequisitionId" use-when="jobRequisition==null"><ignored/></field>
@@ -161,8 +161,8 @@ under the License.
<field name="referredByPartyId"><hidden/></field>
<field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListInternalJobPosting" list-name="listIt" type="list" odd-row-style="alternate-row" header-row-style="header-row-2"
paginate-target="FindInternalJobPosting" default-table-style="basic-table hover-bar">
<grid name="ListInternalJobPosting" list-name="listIt" paginate-target="FindInternalJobPosting"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<set field="entityName" value="EmploymentApp"/>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -177,16 +177,14 @@ under the License.
<hyperlink description="${applicationId}" target="EditInternalJobPosting">
<parameter param-name="applicationId"/>
</hyperlink>
</field>
</field>
<field name="approverPartyId">
<display-entity entity-name="PartyNameView" description="${firstName} ${lastName}" key-field-name="partyId">
<sub-hyperlink target="/partymgr/control/viewprofile" target-type="inter-app" description="${approverPartyId}" link-style="buttontext">
<parameter param-name="partyId" from-field="approverPartyId"/>
</sub-hyperlink>
</display-entity>
</field>
</field>
<field name="applyingPartyId">
<display-entity entity-name="PartyNameView" description="${firstName} ${lastName}" key-field-name="partyId">
<sub-hyperlink target="/partymgr/control/viewprofile" target-type="inter-app" description="${applyingPartyId}" link-style="buttontext">
@@ -194,7 +192,6 @@ under the License.
</sub-hyperlink>
</display-entity>
</field>
<field name="statusId" title="${uiLabelMap.HumanResIJPStatus}"><display/></field>
<field name="jobRequisitionId" widget-style="buttontext">
<hyperlink description="${jobRequisitionId}" target="EditJobRequisition">
@@ -209,7 +206,7 @@ under the License.
<field name="emplPositionId"><hidden/></field>
<field name="employmentAppSourceTypeId"><hidden/></field>
<field name="referredByPartyId"><hidden/></field>
</form>
</grid>
<form name="EditInternalJobPosting" type="single" target="updateInternalJobPosting">
<alt-target use-when="employmentApp==null" target="createInternalJobPosting"/>
<auto-fields-service service-name="updateInternalJobPosting" map-name="employmentApp"/>
@@ -254,7 +251,8 @@ under the License.
</field>
<field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListInterview" type="list" list-name="listIt" paginate-target="FindJobInterview" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<grid name="ListInterview" list-name="listIt" paginate-target="FindJobInterview"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<set field="entityName" value="JobInterview"/>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -289,7 +287,7 @@ under the License.
<parameter param-name="jobInterviewId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="EditJobInterview" type="single" target="updateJobInterview">
<actions>
<entity-one entity-name="JobInterview" value-field="JobInterview"/>
@@ -345,7 +343,7 @@ under the License.
<field name="jobRequisitionId"><lookup target-form-name="LookupJobRequisition"/></field>
<field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListApprovals" list-name="listIt" type="list" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<grid name="ListApprovals" list-name="listIt" odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<actions>
<set field="entityName" value="EmploymentApp"/>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -363,7 +361,7 @@ under the License.
</sub-hyperlink>
</display-entity>
</field>
<field name="approverPartyId" field-name="partyId">
<field name="approverPartyId">
<display-entity entity-name="PartyNameView" description="${firstName} ${lastName}">
<sub-hyperlink target="/partymgr/control/viewprofile" target-type="inter-app" description="${approverPartyId}" link-style="buttontext">
<parameter param-name="partyId" from-field="approverPartyId"/>
@@ -378,7 +376,7 @@ under the License.
<field name="emplPositionId"><hidden/></field>
<field name="employmentAppSourceTypeId"><hidden/></field>
<field name="referredByPartyId"><hidden/></field>
</form>
</grid>
<form name="EditApprovalStatus" type="single" target="updateApprovalStatus" default-map-name="employmentApp">
<auto-fields-service service-name="updateApprovalStatus" map-name="employmentApp"/>
<field name="applicationId"><display/></field>
@@ -417,7 +415,7 @@ under the License.
<field name="noConditionFind"><hidden value="Y"/><!-- if this isn't there then with all fields empty no query will be done --></field>
<field name="searchButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ListRelocation" list-name="listIt" type="list" odd-row-style="alternate-row" header-row-style="header-row-2"
<grid name="ListRelocation" list-name="listIt" odd-row-style="alternate-row" header-row-style="header-row-2"
default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -446,7 +444,7 @@ under the License.
</field>
<field name="internalOrganisation"><display/></field>
<field name="reportingDate"><display/></field>
<field name="location">
<field name="location" title="${uiLabelMap.CommonLocation}">
<display description="${groovy:
import org.apache.ofbiz.entity.GenericValue;
import org.apache.ofbiz.base.util.UtilMisc;
@@ -457,5 +455,5 @@ under the License.
return city;
}"/>
</field>
</form>
</grid>
</forms>
@@ -3830,7 +3830,7 @@
<value xml:lang="de">Geschätzte Ausführungszeit einer Einheit für Produktionsauftrag ist falsch formatiert</value>
<value xml:lang="en">Production Run Estimated Unit Run Time field is not formatted correctly</value>
<value xml:lang="es">El formato usado para indicar la Tiempo estimado unitario no es correcto</value>
<value xml:lang="fr">Le champ Temps de production estimé de l'ordre de fabrication n'est pas formatté correctement</value>
<value xml:lang="fr">Le champ temps de production estimé de l'ordre de fabrication n'est pas formatté correctement</value>
<value xml:lang="it">Ordine di Produzione campo Tempo stimato esecuzione non è formattato correttamente</value>
<value xml:lang="zh">生产运行预计单位运行时间数据项格式不正确</value>
</property>
@@ -3838,7 +3838,7 @@
<value xml:lang="de">Geschätzte Rüstzeit für Produktionsauftrag ist falsch formatiert</value>
<value xml:lang="en">Production Run Estimated Setup Time field is not formatted correctly</value>
<value xml:lang="es">El formato usado para indicar la Tiempo estimado de preparación no es correcto</value>
<value xml:lang="fr">Le champ Temps d'installation estimé de l'ordre de fabrication n'est pas formatté correctement</value>
<value xml:lang="fr">Le champ temps d'installation estimé de l'ordre de fabrication n'est pas formatté correctement</value>
<value xml:lang="it">Ordine di Produzione campo Tempo stimato configur non è formattato correttamente</value>
<value xml:lang="zh">生产运行预计建立时间数据项格式不正确</value>
</property>
@@ -6018,4 +6018,4 @@
<value xml:lang="zh">链接到生产运行</value>
<value xml:lang="zh-TW">連結生產運行</value>
</property>
</resource>
</resource>
@@ -70,7 +70,7 @@ function lookupInventory() {
<td width='20%' align='right' class="label">${uiLabelMap.CommonFromDate}</td>
<td width='5%'>&nbsp;</td>
<td>
<@htmlTemplate.renderDateTimeField name="eventDate" event="" action="" className="" alert="" title="Format: yyyy-MM-dd HH:mm:ss.SSS" value="${requestParameters.eventDate!nowTimestamp}" size="25" maxlength="30" id="fromDate_2" dateType="date" shortDateInput=false timeDropdownParamName="" defaultDateTimeString="" localizedIconTitle="" timeDropdown="" timeHourName="" classString="" hour1="" hour2="" timeMinutesName="" minutes="" isTwelveHour="" ampmName="" amSelected="" pmSelected="" compositeType="" formName=""/>
<@htmlTemplate.renderDateTimeField name="eventDate" event="" action="" className="" alert="" title="Format: yyyy-MM-dd HH:mm:ss.SSS" value="" size="25" maxlength="30" id="fromDate_2" dateType="date" shortDateInput=false timeDropdownParamName="" defaultDateTimeString="" localizedIconTitle="" timeDropdown="" timeHourName="" classString="" hour1="" hour2="" timeMinutesName="" minutes="" isTwelveHour="" ampmName="" amSelected="" pmSelected="" compositeType="" formName=""/>
</td>
</tr>
<tr>
@@ -123,7 +123,7 @@ under the License.
</condition>
<widgets>
<screenlet title="${uiLabelMap.ManufacturingPrecedingProductionRun}">
<include-form name="MandatoryWorkEfforts" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="MandatoryWorkEfforts" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</widgets>
</section>
@@ -133,24 +133,24 @@ under the License.
</condition>
<widgets>
<screenlet title="${uiLabelMap.ManufacturingSucceedingProductionRun}">
<include-form name="DependentWorkEfforts" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="DependentWorkEfforts" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</widgets>
</section>
<screenlet title="${uiLabelMap.ManufacturingOrderItems}">
<include-form name="ListProductionRunOrderItems" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunOrderItems" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingListOfProductionRunRoutingTasks}">
<include-form name="ViewListProductionRunRoutingTasks" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ViewListProductionRunRoutingTasks" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingMaterials}">
<include-form name="ListProductionRunComponents" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunComponents" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingListOfProductionRunFixedAssets}">
<include-form name="ListProductionRunTaskFixedAssets" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunTaskFixedAssets" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingListOfProductionRunNotes}">
<include-form name="ListProductionRunNotes" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunNotes" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
@@ -219,7 +219,7 @@ under the License.
</widgets>
</section>
<screenlet title="${uiLabelMap.ManufacturingInventoryItemsProduced}">
<include-form name="ListProductionRunInventoryItems" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunInventoryItems" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<section>
<condition>
@@ -245,7 +245,7 @@ under the License.
<include-form name="ListProductionRunOrderItems" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingListOfProductionRunRoutingTasks}">
<include-form name="ListProductionRunDeclRoutingTasks" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunDeclRoutingTasks" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<section>
<condition>
@@ -253,7 +253,7 @@ under the License.
</condition>
<widgets>
<screenlet title="${uiLabelMap.ManufacturingMaterials}">
<include-form name="ListProductionRunComponents" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunComponents" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</widgets>
</section>
@@ -271,14 +271,13 @@ under the License.
<section>
<condition><not><if-empty field="prunInventoryProduced"/></not></condition>
<widgets>
<include-form name="ProductionRunTaskInventoryProducedList" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ProductionRunTaskInventoryProducedList" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</widgets>
</section>
</container>
</widgets>
</section>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingMaterialsRequiredByRunningTask}">
<include-form name="ListIssueProductionRunDeclComponents" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
@@ -286,7 +285,7 @@ under the License.
<include-form name="ListReturnProductionRunDeclComponents" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.ManufacturingListOfProductionRunFixedAssets}">
<include-form name="ListProductionRunTaskFixedAssets" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunTaskFixedAssets" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
@@ -423,7 +422,7 @@ under the License.
</actions>
<widgets>
<screenlet>
<include-form name="ProductionRunPartyAssocs" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ProductionRunPartyAssocs" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</widgets>
</section>
@@ -439,7 +438,7 @@ under the License.
</actions>
<widgets>
<screenlet>
<include-form name="ProductionRunTaskPartyAssocs" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ProductionRunTaskPartyAssocs" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
</widgets>
</section>
@@ -471,7 +470,7 @@ under the License.
<screenlet id="EditProductionRunRoutingTaskPanel" title="${uiLabelMap.ManufacturingProductionRunTasks}" collapsible="true">
<include-form name="EditProductionRunRoutingTask" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<include-form name="ListProductionRunRoutingTasks" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunRoutingTasks" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -625,7 +624,7 @@ under the License.
<set field="taskCosts" value="${groovy: request.getAttribute('taskCosts');}"/>
</actions>
<widgets>
<include-form name="ProductionRunTaskCosts" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ProductionRunTaskCosts" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</widgets>
</section>
</screen>
@@ -648,7 +647,7 @@ under the License.
<decorator-section name="body">
<section>
<widgets>
<include-form name="ListProductionRunContent" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListProductionRunContent" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<screenlet title="Import Content From Product ${delivProductId}">
<include-form name="FindDelivProductContent" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-form name="ListDelivProductContent" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
@@ -715,7 +714,7 @@ under the License.
<include-form name="FindProductionRun" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListFindProductionRun" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListFindProductionRun" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -747,7 +746,7 @@ under the License.
<decorator-screen name="CommonManufacturingDecorator" location="${parameters.commonManufacturingDecoratorLocation}">
<decorator-section name="body">
<screenlet title="${uiLabelMap.ManufacturingWorkWithShipmentPlans}">
<include-form name="ListShipmentPlans" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListShipmentPlans" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<section>
<condition>
@@ -755,7 +754,7 @@ under the License.
</condition>
<widgets>
<screenlet title="${uiLabelMap.FormFieldTitle_shipmentId} ${shipment.shipmentId}">
<include-form name="ListShipmentPlan" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
<include-grid name="ListShipmentPlan" location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
</screenlet>
<section>
<condition>
@@ -116,7 +116,7 @@ under the License.
</condition>
<link target="CreateProductionRun"/>
</menu-item>
<menu-item name="NewRouting" title="${uiLabelMap.CommonNew} ${uiLabelMap.ManufacturingRouting}">
<menu-item name="NewRouting" title="${uiLabelMap.ManufacturingNewRouting}">
<condition>
<or>
<if-has-permission permission="MANUFACTURING" action="_CREATE"/>
@@ -124,7 +124,7 @@ under the License.
</condition>
<link target="EditRouting"/>
</menu-item>
<menu-item name="NewRoutingTask" title="${uiLabelMap.CommonNew} ${uiLabelMap.ManufacturingRoutingTask}">
<menu-item name="NewRoutingTask" title="${uiLabelMap.ManufacturingNewRoutingTask}">
<condition>
<or>
<if-has-permission permission="MANUFACTURING" action="_CREATE"/>
@@ -80,7 +80,7 @@ under the License.
</field>
<field name="productId" title="${uiLabelMap.ProductProductId}"><lookup target-form-name="LookupProduct"/></field>
<field name="workEffortName" title="${uiLabelMap.ManufacturingProductionRunName}"><text-find/></field>
<field name="estimatedStartDate" title="${uiLabelMap.ManufacturingStartDate}"><date-find default-value="${nowTimestamp}"/></field>
<field name="estimatedStartDate" title="${uiLabelMap.ManufacturingStartDate}"><date-find/></field>
<field name="facilityId" title="${uiLabelMap.ProductFacilityId}">
<drop-down allow-empty="true">
<entity-options entity-name="Facility" key-field-name="facilityId" description="${facilityName} [${facilityId}]">
@@ -91,7 +91,7 @@ under the License.
<field name="submitButton" title="${uiLabelMap.CommonFind}"><submit/></field>
</form>
<form name="ListFindProductionRun" list-name="listIt" title="" type="list" paginate-target="FindProductionRun"
<grid name="ListFindProductionRun" list-name="listIt" paginate-target="FindProductionRun"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
@@ -123,8 +123,7 @@ under the License.
<field name="estimatedStartDate" title="${uiLabelMap.ManufacturingStartDate}"><display/></field>
<field name="description" title="${uiLabelMap.CommonDescription}"><display/></field>
<field name="facilityId" title="${uiLabelMap.ProductFacilityId}"><display/></field>
</form>
</grid>
<form name="UpdateProductionRun" type="single" target="updateProductionRun" title="" default-map-name="productionRunData"
header-row-style="header-row" default-table-style="basic-table">
<field name="productionRunId"><hidden/></field>
@@ -151,7 +150,7 @@ under the License.
<field name="description"><text/></field>
<field name="submitButton" title="${uiLabelMap.CommonUpdate}"><submit/></field>
</form>
<form name="ListProductionRunOrderItems" type="list" target="EditProductionRun" title="" list-name="orderItems"
<grid name="ListProductionRunOrderItems" list-name="orderItems" target="EditProductionRun"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="orderId" widget-style="buttontext">
<hyperlink description="${orderId}/${orderItemSeqId}" target="/ordermgr/control/orderview" also-hidden="false" target-type="inter-app">
@@ -168,8 +167,8 @@ under the License.
<field name="estimatedShipDate"><display/></field>
<field name="estimatedDeliveryDate"><display/></field>
-->
</form>
<form name="ListProductionRunInventoryItems" type="list" title="" list-name="inventoryItems"
</grid>
<grid name="ListProductionRunInventoryItems" list-name="inventoryItems"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<row-actions>
<entity-one entity-name="InventoryItem" value-field="inventoryItem"/>
@@ -189,9 +188,8 @@ under the License.
<field name="unitCost" map-name="inventoryItem"><display/></field>
<field name="quantity" entry-name="quantityOnHandDiff"><display/></field>
<field name="datetimeReceived" map-name="inventoryItem"><display/></field>
</form>
<form name="ViewListProductionRunRoutingTasks" type="list" title="" list-name="productionRunRoutingTasks"
</grid>
<grid name="ViewListProductionRunRoutingTasks" list-name="productionRunRoutingTasks"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<row-actions>
<set field="estimatedTotalMilliSeconds" value="${groovy:estimatedMilliSeconds * quantity}" type="BigDecimal"/>
@@ -205,8 +203,8 @@ under the License.
<field name="estimatedSetupMillis" title="${uiLabelMap.ManufacturingTaskEstimatedSetupMillis}" ><display/></field>
<!--<field name="estimatedMilliSeconds" title="${uiLabelMap.ManufacturingTaskEstimatedMilliSeconds}" ><display/></field>-->
<field name="estimatedTotalMilliSeconds" title="${uiLabelMap.ManufacturingTaskEstimatedTotalMilliSeconds}" ><display/></field>
</form>
<form name="ListProductionRunRoutingTasks" type="list" target="ProductionRunTasks" title="" list-name="productionRunRoutingTasks"
</grid>
<grid name="ListProductionRunRoutingTasks" list-name="productionRunRoutingTasks" target="ProductionRunTasks"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<row-actions>
<set field="estimatedTotalMilliSeconds" value="${groovy:estimatedMilliSeconds * quantity}" type="BigDecimal"/>
@@ -238,9 +236,8 @@ under the License.
<parameter param-name="productionRunId" from-field="workEffortParentId"/>
</hyperlink>
</field>
</form>
<form name="ListProductionRunComponents" type="list" target="EditProductionRun" title="" list-name="productionRunComponents"
</grid>
<grid name="ListProductionRunComponents" list-name="productionRunComponents" target="EditProductionRun"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<row-actions>
<entity-one entity-name="Product" value-field="product" use-cache="true"/>
@@ -253,8 +250,7 @@ under the License.
</field>
<field name="estimatedQuantity" title="${uiLabelMap.ManufacturingQuantity}"><display/></field>
<field name="quantityUomId" map-name="product" title="${uiLabelMap.CommonUom}"><display-entity entity-name="Uom" key-field-name="uomId" description="${abbreviation}"/></field>
</form>
</grid>
<form name="EditProductionRunRoutingTask" type="single" target="updateProductionRunRoutingTask" title="" default-map-name="productionRunTask"
header-row-style="header-row" default-table-style="basic-table">
<alt-target use-when="productionRunTask==null" target="addProductionRunRoutingTask"/>
@@ -367,8 +363,7 @@ under the License.
<field name="_rowSubmit"><hidden value="Y"/></field>
<field name="submitButton" title="${uiLabelMap.CommonSubmit}"><submit/></field>
</form>
<form name="ListProductionRunDeclRoutingTasks" type="list" target="ProductionRunDeclaration" title="" list-name="productionRunRoutingTasks"
<grid name="ListProductionRunDeclRoutingTasks" list-name="productionRunRoutingTasks" target="ProductionRunDeclaration"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="actionForm"><hidden value="EditRoutingTask"/></field>
<field name="productionRunId"><hidden value="${workEffortParentId}"/></field>
@@ -417,7 +412,7 @@ under the License.
<parameter param-name="productionRunId" from-field="workEffortParentId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="ListIssueProductionRunDeclComponents" type="multi" target="issueProductionRunTaskComponents?productionRunId=${productionRunId}" title="" list-name="productionRunComponentsDataReadyForIssuance"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
@@ -522,14 +517,14 @@ under the License.
<field name="lotId" title="${uiLabelMap.ProductLotId}"><text /></field>
<field name="submitButton" title="${uiLabelMap.CommonAdd}"><submit button-type="button"/></field>
</form>
<form name="ProductionRunTaskInventoryProducedList" type="list" title="" list-name="prunInventoryProduced"
<grid name="ProductionRunTaskInventoryProducedList" list-name="prunInventoryProduced"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="inventoryItemId" title="${uiLabelMap.ProductInventoryItem}" widget-style="buttontext">
<hyperlink target="/facility/control/EditInventoryItem" description="${inventoryItemId}" also-hidden="false" target-type="inter-app">
<parameter param-name="inventoryItemId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="FindDelivProductContent" type="single" target="ProductionRunContent">
<field name="productionRunId"><hidden/></field>
<field name="productId" entry-name="delivProductId"><hidden/></field>
@@ -538,7 +533,7 @@ under the License.
<field name="roleTypeId"><hidden value="CONTENT_USER"/></field>
<field name="submitButton" title="${uiLabelMap.CommonFind}"><submit button-type="button"/></field>
</form>
<form name="ListProductionRunContent" type="list" title="" list-name="productionRunContents">
<grid name="ListProductionRunContent" list-name="productionRunContents">
<actions>
<entity-and entity-name="WorkEffortContentAndInfo" list="productionRunContents">
<field-map field-name="workEffortId" from-field="productionRunId"/>
@@ -574,7 +569,7 @@ under the License.
<parameter param-name="productionRunId" from-field="productionRunId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="ListDelivProductContent" type="multi" use-row-submit="true" target="createProductionRunContents?productionRunId=${productionRunId}" title="" list-name="delivProductContentsForLocaleAndUser">
<field name="productionRunId"><hidden/></field>
<field name="workEffortId" entry-name="productionRunId"><hidden/></field>
@@ -630,7 +625,7 @@ under the License.
</hyperlink>
</field>
</form>
<form name="ListProductionRunTaskFixedAssets" type="list" title="" list-name="productionRunFixedAssetsData"
<grid name="ListProductionRunTaskFixedAssets" list-name="productionRunFixedAssetsData"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<auto-fields-entity entity-name="WorkEffortFixedAssetAssign" default-field-type="display"/>
<field name="workEffortId">
@@ -642,8 +637,8 @@ under the License.
<field name="statusId">
<display-entity entity-name="StatusItem"/>
</field>
</form>
<form name="ListProductionRunNotes" type="list" title="" list-name="productionRunNoteData"
</grid>
<grid name="ListProductionRunNotes" list-name="productionRunNoteData"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<auto-fields-entity entity-name="WorkEffortNoteAndData" default-field-type="display"/>
<field name="workEffortId"><hidden/></field>
@@ -651,7 +646,7 @@ under the License.
<field name="noteId"><hidden/></field>
<field name="noteParty"><hidden/></field>
<field name="noteDateTime"><hidden/></field>
</form>
</grid>
<form name="EditProductionRunTaskFixedAsset" type="single" target="EditProductionRun" title="" default-map-name="fixedAssetData"
header-row-style="header-row" default-table-style="basic-table">
<alt-target use-when="declarationScreen.equals(&quot;Y&quot;)" target="ProductionRunDeclaration"/>
@@ -725,12 +720,7 @@ under the License.
</field>
<field name="submitButton" title="${uiLabelMap.CommonAdd}"><submit/></field>
</form>
<!-- ******************* -->
<!-- Shipment Plan Forms -->
<!-- ******************* -->
<!-- List for Shipment Plan -->
<form name="ListShipmentPlan" type="list" target="" title="" list-name="shipmentPlan"
<grid name="ListShipmentPlan" list-name="shipmentPlan"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="orderId" widget-style="buttontext">
<hyperlink description="${orderId}" target="/ordermgr/control/orderview" target-type="inter-app">
@@ -739,17 +729,11 @@ under the License.
</field>
<field name="orderItemSeqId" title="${uiLabelMap.ProductOrderItem}"><display/></field>
<field name="productId" title="${uiLabelMap.ProductProductId}"><display/></field>
<!-- quantity planned in this shipment -->
<field name="quantity" title="${uiLabelMap.ProductQuantity}"><display/></field>
<!-- quantity issued in this shipment -->
<field name="issuedQuantity"><display/></field>
<!-- total ordered quantity -->
<field name="totOrderedQuantity"><display/></field>
<!-- total not available quantity -->
<field name="notAvailableQuantity" title="${uiLabelMap.ProductNotAvailable}"><display/></field>
<!-- total planned quantity not issued -->
<field name="totPlannedQuantity"><display/></field>
<!-- total issued quantity -->
<field name="totIssuedQuantity"><display/></field>
<field name="productionRunId" widget-style="buttontext">
<hyperlink description="${productionRunId}" target="ShowProductionRun" also-hidden="false">
@@ -759,9 +743,8 @@ under the License.
<field name="productionRunStatusId"><display-entity entity-name="StatusItem" key-field-name="statusId"/></field>
<field name="productionRunEstimatedCompletionDate"><display/></field>
<field name="productionRunQuantityProduced"><display/></field>
</form>
<form name="ListShipmentPlans" type="list" target="" title="" list-name="shipmentPlans"
</grid>
<grid name="ListShipmentPlans" list-name="shipmentPlans"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar" header-row-style="header-row-2">
<field name="shipmentId" widget-style="buttontext" sort-field="true">
<hyperlink description="${shipmentId}" target="/facility/control/ViewShipment" target-type="inter-app">
@@ -777,7 +760,7 @@ under the License.
<parameter param-name="shipmentId"/>
</hyperlink>
</field>
</form>
</grid>
<form name="SelectMrpName" type="single" target="ManufacturingReports" title=""
header-row-style="header-row" default-table-style="basic-table">
<field name="mrpName" title="${uiLabelMap.ManufacturingMrpName}"><text size="20"/></field>
@@ -805,7 +788,7 @@ under the License.
</field>
<field name="submitButton" title="${uiLabelMap.CommonSubmit}"><submit/></field>
</form>
<form name="MandatoryWorkEfforts" type="list" target="" title="" list-name="mandatoryWorkEfforts"
<grid name="MandatoryWorkEfforts" list-name="mandatoryWorkEfforts"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="workEffortIdFrom" title=" " widget-style="buttontext">
<hyperlink description="${workEffortIdFrom}" target="ShowProductionRun" also-hidden="false" link-type="anchor">
@@ -842,8 +825,8 @@ under the License.
<parameter param-name="productionRunId"/>
</hyperlink>
</field>
</form>
<form name="DependentWorkEfforts" type="list" target="" title="" list-name="dependentWorkEfforts"
</grid>
<grid name="DependentWorkEfforts" list-name="dependentWorkEfforts"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="workEffortIdTo" title=" " widget-style="buttontext">
<hyperlink description="${workEffortIdTo}" target="ShowProductionRun" also-hidden="false" link-type="anchor">
@@ -880,8 +863,8 @@ under the License.
<parameter param-name="productionRunId"/>
</hyperlink>
</field>
</form>
<form name="ProductionRunTaskCosts" type="list" target="" title="" list-name="taskCosts"
</grid>
<grid name="ProductionRunTaskCosts" list-name="taskCosts"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<auto-fields-entity entity-name="CostComponent" default-field-type="display"/>
<field name="workEffortId"><hidden/></field>
@@ -895,7 +878,7 @@ under the License.
<field name="costComponentCalcId">
<display-entity entity-name="CostComponentCalc"/>
</field>
</form>
</grid>
<form name="AddProductionRunComponent" type="single" target="addProductionRunComponent" title=""
header-row-style="header-row" default-table-style="basic-table">
<auto-fields-service service-name="addProductionRunComponent"/>
@@ -913,16 +896,14 @@ under the License.
</field>
<field name="submitButton" title="${uiLabelMap.CommonAdd}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ProductionRunPartyAssocs" type="list" title="" list-name="productionRunParties"
<grid name="ProductionRunPartyAssocs" list-name="productionRunParties"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="workEffortId"><hidden/></field>
<field name="productionRunId"><hidden/></field>
<field name="partyId">
<display-entity entity-name="PartyNameView" description="${personalTitle} ${firstName} ${middleName} ${lastName} ${suffix} ${groupName}" also-hidden="true" cache="false">
<display-entity entity-name="PartyNameView"
description="${personalTitle} ${firstName} ${middleName} ${lastName} ${suffix} ${groupName}"
also-hidden="true" cache="false">
</display-entity>
</field>
<field name="roleTypeId" title="${uiLabelMap.CommonRole}">
@@ -930,16 +911,17 @@ under the License.
</field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}"><display/></field>
</form>
<form name="ProductionRunTaskPartyAssocs" type="list" title="" list-name="productionRunTaskParties"
</grid>
<grid name="ProductionRunTaskPartyAssocs" list-name="productionRunTaskParties"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<field name="productionRunId"><hidden/></field>
<field name="workEffortId" title="${uiLabelMap.ManufacturingTaskName}">
<display-entity entity-name="WorkEffort" description="${workEffortName} - [${workEffortId}]"/>
</field>
<field name="partyId">
<display-entity entity-name="PartyNameView" description="${personalTitle} ${firstName} ${middleName} ${lastName} ${suffix} ${groupName}" also-hidden="true" cache="false">
<display-entity entity-name="PartyNameView"
description="${personalTitle} ${firstName} ${middleName} ${lastName} ${suffix} ${groupName}"
also-hidden="true" cache="false">
</display-entity>
</field>
<field name="roleTypeId" title="${uiLabelMap.CommonRole}">
@@ -950,9 +932,7 @@ under the License.
</field>
<field name="fromDate" title="${uiLabelMap.CommonFrom}"><display/></field>
<field name="thruDate" title="${uiLabelMap.CommonThru}"><display/></field>
</form>
</grid>
<form name="ProductionRunTaskComponents" type="list" target="updateProductionRunComponent" paginate-target="ProductionRunComponents" title="" list-name="records"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<row-actions>
@@ -36,15 +36,10 @@ under the License.
<not><if-empty field="routing"/></not>
</condition>
<widgets>
<label style="h1">${uiLabelMap.CommonRouting}: ${routing.workEffortId}</label>
<include-menu name="RoutingTabBar" location="component://manufacturing/widget/manufacturing/ManufacturingMenus.xml"/>
<container style="button-bar">
<link target="EditRouting" text="${uiLabelMap.ManufacturingNewRouting}" style="buttontext create"/>
</container>
</widgets>
</section>
<container>
<label style="h1">[${uiLabelMap.CommonId} ${routing.workEffortId}] ${routing.workEffortName}</label>
</container>
<decorator-section-include name="body"/>
</widgets>
</section>
@@ -69,15 +64,10 @@ under the License.
<not><if-empty field="routingTask"/></not>
</condition>
<widgets>
<label style="h1">${uiLabelMap.WorkEffortTask}: ${routingTask.workEffortId}</label>
<include-menu name="RoutingTaskTabBar" location="component://manufacturing/widget/manufacturing/ManufacturingMenus.xml"/>
<container style="button-bar">
<link target="EditRoutingTask" text="${uiLabelMap.ManufacturingNewRoutingTask}" style="buttontext create"/>
</container>
</widgets>
</section>
<container>
<label style="h1">[${uiLabelMap.CommonId} ${routingTask.workEffortId}] ${routingTask.workEffortName}</label>
</container>
<decorator-section-include name="body"/>
</widgets>
</section>
@@ -86,7 +76,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="FindRouting">
<section>
<actions>
@@ -97,7 +86,6 @@ under the License.
<set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer"/>
<set field="viewSizeDefaultValue" value="${groovy: modelTheme.getDefaultViewSize()}" type="Integer"/>
<set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="${viewSizeDefaultValue}"/>
<set field="asm_multipleSelectForm" value="FindRoutings"/>
<set field="asm_formSize" value="700"/>
<set field="asm_multipleSelect" value="FindRoutings_currentStatusId"/>
@@ -112,11 +100,6 @@ under the License.
<section>
<widgets>
<decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml">
<decorator-section name="menu-bar">
<container style="button-bar">
<link target="EditRouting" text="${uiLabelMap.ManufacturingNewRouting}" style="buttontext create"/>
</container>
</decorator-section>
<decorator-section name="search-options">
<include-form name="FindRoutings" location="component://manufacturing/widget/manufacturing/RoutingTaskForms.xml"/>
</decorator-section>
@@ -138,7 +121,6 @@ under the License.
<set field="headerItem" value="routing"/>
<set field="tabButtonItem" value="editRouting"/>
<set field="helpAnchor" value="_create_edit_routing"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<entity-one entity-name="WorkEffort" value-field="routing"/>
</actions>
@@ -160,7 +142,6 @@ under the License.
<set field="tabButtonItem" value="routingTask"/>
<set field="headerItem" value="routingTask"/>
<set field="helpAnchor" value="_routing_task"/>
<set field="requestParameters.workEffortTypeId" to-scope="screen" default-value="ROU_TASK"/>
<set field="requestParameters.currentStatusId" to-scope="screen" default-value="ROU_ACTIVE"/>
</actions>
@@ -170,11 +151,6 @@ under the License.
<section>
<widgets>
<decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml">
<decorator-section name="menu-bar">
<container style="button-bar">
<link target="EditRoutingTask" text="${uiLabelMap.ManufacturingNewRoutingTask}" style="buttontext create"/>
</container>
</decorator-section>
<decorator-section name="search-options">
<include-form name="FindRoutingTasks" location="component://manufacturing/widget/manufacturing/RoutingTaskForms.xml"/>
</decorator-section>
@@ -196,7 +172,6 @@ under the License.
<set field="headerItem" value="routingTask"/>
<set field="tabButtonItem" value="editRoutingTask"/>
<set field="helpAnchor" value="_create_edit_route_task"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<entity-one entity-name="WorkEffort" value-field="routingTask"/>
</actions>
@@ -204,9 +179,6 @@ under the License.
<decorator-screen name="CommonRoutingTaskDecorator">
<decorator-section name="body">
<screenlet title="${groovy: workEffortId ? uiLabelMap.PageTitleEditRoutingTask : uiLabelMap.ManufacturingNewRoutingTask}">
<container style="button-bar">
<link target="EditRoutingTask" text="${uiLabelMap.ManufacturingNewRoutingTask}" style="buttontext create"/>
</container>
<include-form name="EditRoutingTask" location="component://manufacturing/widget/manufacturing/RoutingTaskForms.xml"/>
</screenlet>
</decorator-section>
@@ -221,7 +193,6 @@ under the License.
<set field="headerItem" value="routingTask"/>
<set field="tabButtonItem" value="editRoutingTaskCosts"/>
<set field="helpAnchor" value="_create_edit_route_task_cost"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<entity-one entity-name="WorkEffort" value-field="routingTask"/>
<entity-and entity-name="WorkEffortCostCalc" list="allCosts">
@@ -246,7 +217,6 @@ under the License.
<set field="titleProperty" value="PageTitleListRoutingTaskRoutings"/>
<set field="headerItem" value="routingTask"/>
<set field="tabButtonItem" value="listRoutingTaskRoutings"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<entity-one entity-name="WorkEffort" value-field="routingTask"/>
<entity-and entity-name="WorkEffortAssoc" list="allRoutings">
@@ -271,7 +241,6 @@ under the License.
<set field="headerItem" value="routingTask"/>
<set field="tabButtonItem" value="listRoutingTaskProducts"/>
<set field="helpAnchor" value="_routing_task_deliverable_products"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<entity-one entity-name="WorkEffort" value-field="routingTask"/>
<entity-and entity-name="WorkEffortGoodStandard" list="allProducts">
@@ -300,7 +269,6 @@ under the License.
<set field="headerItem" value="routingTask"/>
<set field="tabButtonItem" value="listRoutingTaskProducts"/>
<set field="helpAnchor" value="_create_edit_deliverable_products"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<entity-and entity-name="WorkEffortGoodStandard" list="allRoutingProductLinks">
<field-map field-name="workEffortId" from-field="workEffortId"/>
@@ -326,7 +294,6 @@ under the License.
<set field="tabButtonItem" value="routingTaskAssoc"/>
<set field="headerItem" value="routing"/>
<set field="helpAnchor" value="_create_edit_route_associated_task"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<set field="workEffortAssocTypeId" value="ROUTING_COMPONENT"/>
<entity-and entity-name="WorkEffortAssocView" list="allRoutingTasks">
@@ -360,7 +327,6 @@ under the License.
<!--<set field="labelTitleProperty" value="ProductProductBom"/>-->
<set field="headerItem" value="routing"/>
<set field="helpAnchor" value="_create_edit_routing_associated_product_link"/>
<set field="workEffortGoodStdTypeId" value="ROU_PROD_TEMPLATE"/>
<set field="workEffortId" from-field="parameters.workEffortId"/>
<!--<entity-one entity-name="Agreement" value-field="agreement" auto-field-map="true"/>-->
@@ -27,7 +27,7 @@ under the License.
<menu-item name="Reports" title="${uiLabelMap.MarketingReports}"><link target="MarketingReport"/></menu-item>
</menu>
<menu name="MainActionMenu" menu-container-style="button-bar button-style-2" default-selected-style="selected">
<menu-item name="NewCampaign" title="${uiLabelMap.CommonNew} ${uiLabelMap.MarketingCampaign}">
<menu-item name="NewCampaign" title="${uiLabelMap.MarketingCampaignCreate}">
<condition>
<or>
<if-has-permission permission="MARKETING" action="_CREATE"/>
@@ -43,8 +43,16 @@ under the License.
</condition>
<link target="EditContactList"/>
</menu-item>
<menu-item name="NewTrackingCode" title="${uiLabelMap.MarketingTrackingCodeCreate}">
<condition>
<or>
<if-has-permission permission="MARKETING" action="_CREATE"/>
</or>
</condition>
<link target="EditTrackingCode">
</link>
</menu-item>
</menu>
<menu name="MarketingShortcutAppBar" title="${uiLabelMap.MarketingManager}">
<menu-item name="DataSource" title="${uiLabelMap.DataSource}"><link target="/marketing/control/FindDataSource" url-mode="inter-app"/></menu-item>
<menu-item name="Campaign" title="${uiLabelMap.MarketingCampaign}"><link target="/marketing/control/FindMarketingCampaign" url-mode="inter-app"/></menu-item>
@@ -90,11 +90,6 @@ under the License.
</condition>
<widgets>
<screenlet title="${uiLabelMap.PageTitleEditTrackingCode}">
<container>
<link text="${uiLabelMap.MarketingTrackingCodeCreate}" target="/EditTrackingCode" style="buttontext">
<parameter param-name="DONE_PAGE" from-field="donePage"/>
</link>
</container>
<include-form name="EditTrackingCode" location="component://marketing/widget/TrackingCodeForms.xml"/>
</screenlet>
</widgets>
@@ -247,7 +242,7 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ListTrackingCodeVisits">
<section>
<actions>
+7 -12
View File
@@ -2094,6 +2094,7 @@
</property>
<property key="OrderAllocationPlan">
<value xml:lang="en">Allocation Plan</value>
<value xml:lang="fr">Plan d'allocation</value>
<value xml:lang="nl">Allocatieplan</value>
</property>
<property key="OrderAllocationPlanNotFound">
@@ -3563,16 +3564,6 @@
<value xml:lang="zh-CN">新建报价项</value>
<value xml:lang="zh-TW">新建報價細項</value>
</property>
<property key="OrderCreateOrderQuoteNote">
<value xml:lang="ar">خلق ملاحظة عرض سعر جديدة</value>
<value xml:lang="de">Neue Anmerkung zu Angebot erstellen</value>
<value xml:lang="de-CH">Neue Anmerkung zu Offerte erstellen</value>
<value xml:lang="en">Create New Quote Note</value>
<value xml:lang="fr">Créer une nouvelle note de devis</value>
<value xml:lang="nl">Nieuwe notitie bij offerte aanmaken</value>
<value xml:lang="zh">新建询价便笺</value>
<value xml:lang="zh-TW">新建詢價便箋</value>
</property>
<property key="OrderCreateOrderQuoteRole">
<value xml:lang="ar">خلق دور عرض سعر جديد</value>
<value xml:lang="de">Neue Angebotsrolle erstellen</value>
@@ -8896,7 +8887,7 @@
<value xml:lang="de-CH">Offertbericht</value>
<value xml:lang="en">Quote Report</value>
<value xml:lang="es">Informe del presupuesto</value>
<value xml:lang="fr">Report du devis</value>
<value xml:lang="fr">Etat du devis</value>
<value xml:lang="it">Stampe Preventivo</value>
<value xml:lang="ja">見積レポート</value>
<value xml:lang="nl">Offerte-rapport</value>
@@ -12771,7 +12762,7 @@
<value xml:lang="zh">退货类型历史记录</value>
<value xml:lang="zh-TW">退貨類型歷史</value>
</property>
<property key="OrderReviewOrder">
<value xml:lang="ar">مراجعة أمر البيع\الشراء</value>
<value xml:lang="de">Auftrag prüfen</value>
@@ -16318,4 +16309,8 @@
<value xml:lang="en">Lookup Return Header</value>
<value xml:lang="nl">Retouren zoeken/vinden</value>
</property>
<property key="ItemAddedSuccessfully">
<value xml:lang="en">Item ${productId} added successfully</value>
<value xml:lang="it">Articolo ${productId} aggiunto con successo</value>
</property>
</resource>
@@ -47,9 +47,10 @@ def getNextOrderId() {
customMethodName = 'orderSequence_enforced'
}
String orderIdTemp
if (customMethodName) {
Map customMethodMap = [*: parameters]
Map result = run service: customMethodName, with: customMethodMap
parameters.partyAcctgPreference = partyAcctgPreference
Map result = run service: customMethodName, with: parameters
orderIdTemp = result.orderId
} else {
logInfo 'In getNextOrderId sequence by Standard'
@@ -68,10 +69,7 @@ def getNextOrderId() {
if (partyAcctgPreference) orderId += partyAcctgPreference.orderIdPrefix ?: ""
orderId += orderIdTemp.toString()
Map result = success()
result.orderId = orderId
return result
return success([orderId: orderId])
}
/**
@@ -695,6 +695,8 @@ public class ShoppingCartEvents {
if (cart.viewCartOnAdd()) {
return "viewcart";
}
request.setAttribute("_EVENT_MESSAGE_", UtilProperties.getMessage("OrderUiLabels", "ItemAddedSuccessfully",
UtilMisc.toMap("productId", productId), UtilHttp.getLocale(request)));
return "success";
}
@@ -49,7 +49,7 @@ under the License.
</select>
</div>
<div>
<input type="file" name="uploadedFile" class="required" size="25" accept=".png,.gif,.jpg,.jpeg,.tiff,.tif"/>
<input type="file" name="uploadedFile" class="required" size="25"/>
</div>
<div>
<button type="submit">
@@ -69,7 +69,7 @@ under the License.
<td class="label">${uiLabelMap.OrderPrice}</td>
<td>
<input type="text" size="6" name="basePrice" value="${requestParameters.price!}"/>
<label><input type="checkbox" name="overridePrice" value="Y"/>&nbsp;${uiLabelMap.OrderOverridePrice}</label>
<label><input type="checkbox" name="overridePrice" value="Y"/>${uiLabelMap.OrderOverridePrice}</label>
</td>
</tr>
<tr>
+24 -17
View File
@@ -101,10 +101,12 @@ under the License.
<td align="right" class="label">${uiLabelMap.CommonType}</td>
<td nowrap="nowrap">
<div>
<label><input type="checkbox" name="view_SALES_ORDER" value="Y" <#if state.hasType('view_SALES_ORDER')>checked="checked"</#if>/>
${descr_SALES_ORDER}</label>
<label><input type="checkbox" name="view_PURCHASE_ORDER" value="Y" <#if state.hasType('view_PURCHASE_ORDER')>checked="checked"</#if>/>
${descr_PURCHASE_ORDER}</label>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<label><input type="checkbox" name="view_SALES_ORDER" value="Y"
<#if state.hasType('view_SALES_ORDER')>checked="checked"</#if>/>${descr_SALES_ORDER}</label>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<label><input type="checkbox" name="view_PURCHASE_ORDER" value="Y"
<#if state.hasType('view_PURCHASE_ORDER')>checked="checked"</#if>/>${descr_PURCHASE_ORDER}</label>
</div>
</td>
</tr>
@@ -113,13 +115,13 @@ under the License.
<td nowrap="nowrap">
<div>
<label>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<input type="checkbox" name="filterInventoryProblems" value="Y"
<#if state.hasFilter('filterInventoryProblems')>checked="checked"</#if>/>
${uiLabelMap.OrderFilterInventoryProblems}</label>
<#if state.hasFilter('filterInventoryProblems')>checked="checked"</#if>/>${uiLabelMap.OrderFilterInventoryProblems}</label>
<label>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<input type="checkbox" name="filterAuthProblems" value="Y"
<#if state.hasFilter('filterAuthProblems')>checked="checked"</#if>/>
${uiLabelMap.OrderFilterAuthProblems}</label>
<#if state.hasFilter('filterAuthProblems')>checked="checked"</#if>/>${uiLabelMap.OrderFilterAuthProblems}</label>
</div>
</td>
</tr>
@@ -127,16 +129,21 @@ under the License.
<td align="right" class="label">${uiLabelMap.CommonFilter} (${uiLabelMap.OrderFilterPOs})</td>
<td nowrap="nowrap">
<div>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<label>
<input type="checkbox" name="filterPartiallyReceivedPOs" value="Y"
<#if state.hasFilter('filterPartiallyReceivedPOs')>checked="checked"</#if>/>
${uiLabelMap.OrderFilterPartiallyReceivedPOs}</label>
<label><input type="checkbox" name="filterPOsOpenPastTheirETA" value="Y"
<#if state.hasFilter('filterPOsOpenPastTheirETA')>checked="checked"</#if>/>
${uiLabelMap.OrderFilterPOsOpenPastTheirETA}</label>
<label><input type="checkbox" name="filterPOsWithRejectedItems" value="Y"
<#if state.hasFilter('filterPOsWithRejectedItems')>checked="checked"</#if>/>
${uiLabelMap.OrderFilterPOsWithRejectedItems}</label>
<input type="checkbox" name="filterPartiallyReceivedPOs" value="Y"
<#if state.hasFilter('filterPartiallyReceivedPOs')>checked="checked"</#if>/>${uiLabelMap.OrderFilterPartiallyReceivedPOs}
</label>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<label>
<input type="checkbox" name="filterPOsOpenPastTheirETA" value="Y"
<#if state.hasFilter('filterPOsOpenPastTheirETA')>checked="checked"</#if>/>${uiLabelMap.OrderFilterPOsOpenPastTheirETA}
</label>
<#-- !if the linebreak was performed after the tag, it would be misinterpreted as a blank! -->
<label>
<input type="checkbox" name="filterPOsWithRejectedItems" value="Y"
<#if state.hasFilter('filterPOsWithRejectedItems')>checked="checked"</#if>/>${uiLabelMap.OrderFilterPOsWithRejectedItems}
</label>
</div>
</td>
</tr>
@@ -238,10 +238,29 @@ under the License.
<widgets>
<decorator-screen name="CommonRequestDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<screenlet id="EditRequestRolePanel" title="${uiLabelMap.PageTitleEditRequestRoles}" collapsible="true">
<include-form name="EditRequestRole" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
</screenlet>
<include-form name="ListRequestRoles" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
<section>
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
</and>
</condition>
<widgets>
<screenlet id="EditRequestRolePanel" title="${uiLabelMap.PageTitleEditRequestRoles}" collapsible="true">
<include-form name="EditRequestRole" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
</screenlet>
<screenlet id="RequestRoles">
<include-form name="ListRequestRoles" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
<screenlet id="RequestRoles">
<include-form name="ViewRequestRoles" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
</screenlet>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
@@ -268,9 +287,6 @@ under the License.
<decorator-screen name="CommonRequestDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<screenlet title="${uiLabelMap.PageTitleRequestItems}">
<link target="requestitem" text="${uiLabelMap.OrderNewRequestItem}" style="buttontext">
<parameter param-name="custRequestId"/>
</link>
<include-form name="ListRequestItems" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
</screenlet>
</decorator-section>
@@ -296,11 +312,6 @@ under the License.
<decorator-screen name="CommonRequestDecorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="body">
<screenlet title="${uiLabelMap.CommonId}:${custRequestItem.custRequestItemSeqId} ${custRequestItem.description}">
<container>
<link target="requestitem" text="${uiLabelMap.OrderNewRequestItem}" style="buttontext">
<parameter param-name="custRequestId"/>
</link>
</container>
<include-form name="EditCustRequestItem" location="component://order/widget/ordermgr/CustRequestForms.xml"/>
<platform-specific>
<html><html-template location="component://order/template/request/CopyRequestItem.ftl"/></html>
@@ -24,7 +24,7 @@ under the License.
<field name="requirementId"><text-find/></field>
<field name="partyId" title="${uiLabelMap.PartySupplier}"><lookup target-form-name="LookupPartyName"/></field>
<field name="productId" title="${uiLabelMap.ProductProductId}"><lookup target-form-name="LookupProduct"/></field>
<field name="requirementByDate"><date-find type="date"/></field>
<field name="requiredByDate"><date-find type="date"/></field>
<field name="submitButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="RequirementsList" type="multi" use-row-submit="true" target="addRequirementsToCart" title="" list-name="requirementsForSupplier"
+152 -33
View File
@@ -84,7 +84,7 @@ under the License.
</menu-item>
</menu>
<menu name="MainActionMenu" menu-container-style="button-bar button-style-2" default-selected-style="selected">
<menu-item name="NewOrder" title="${uiLabelMap.CommonNew} ${uiLabelMap.CommonOrder}">
<menu-item name="NewOrder" title="${uiLabelMap.OrderNewOrder}">
<condition>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
@@ -93,7 +93,7 @@ under the License.
</condition>
<link target="orderentry" link-type="anchor"/>
</menu-item>
<menu-item name="NewQuote" title="${uiLabelMap.CommonNew} ${uiLabelMap.CommonQuote}">
<menu-item name="NewQuote" title="${uiLabelMap.OrderNewQuote}">
<condition>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
@@ -101,7 +101,7 @@ under the License.
</condition>
<link target="EditQuote"/>
</menu-item>
<menu-item name="NewRequest" title="${uiLabelMap.CommonNew} ${uiLabelMap.CommonRequest}">
<menu-item name="NewRequest" title="${uiLabelMap.OrderNewRequest}">
<condition>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
@@ -109,7 +109,7 @@ under the License.
</condition>
<link target="request"/>
</menu-item>
<menu-item name="NewRequirement" title="${uiLabelMap.CommonNew} ${uiLabelMap.OrderRequirement}">
<menu-item name="NewRequirement" title="${uiLabelMap.OrderNewRequirement}">
<condition>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
@@ -311,14 +311,6 @@ under the License.
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="QuoteWorkEfforts" title="${uiLabelMap.CommonWorkEfforts}">
<condition>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</condition>
<link target="ListQuoteWorkEfforts">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="ListQuoteNotes" title="${uiLabelMap.CommonNotes}">
<condition>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
@@ -343,19 +335,130 @@ under the License.
<parameter param-name="quoteId" from-field="parameters.quoteId"/>
</link>
</menu-item>
<menu-item name="QuoteWorkEfforts" title="${uiLabelMap.WorkEffortWorkEfforts}">
<condition>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</condition>
<link target="ListQuoteWorkEfforts">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
</menu>
<menu name="QuoteSubTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml"
menu-container-style="button-bar button-style-2">
<menu-item name="EditQuote" title="${uiLabelMap.CommonEdit}">
<condition>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="EditQuote">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="quoteReport" title="${uiLabelMap.CommonPdf}">
<menu-item name="NewItem" title="${uiLabelMap.OrderCreateOrderQuoteItem}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="EditQuoteItem">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="NewAttribute" title="${uiLabelMap.OrderNewQuoteAttribute}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="EditQuoteAttribute">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="NewCoefficient" title="${uiLabelMap.CommonNew} ${uiLabelMap.OrderOrderQuoteCoefficients}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="EditQuoteCoefficient">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="NewNote" title="${uiLabelMap.OrderAddNote}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="createnewquotenote">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="NewRole" title="${uiLabelMap.CommonNew} ${uiLabelMap.CommonRole}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="EditQuoteRole">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="NewTerm" title="${uiLabelMap.OrderCreateOrderQuoteTerm}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="EditQuoteTerm">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="NewWorkEffort" title="${uiLabelMap.WorkEffortCreate}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<if-compare operator="equals" value="QUO_CREATED" field="quote.statusId"/>
</and>
</condition>
<link target="AddQuoteWorkEffort">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</menu-item>
<menu-item name="quoteReport" title="${uiLabelMap.CommonNew} ${uiLabelMap.OrderOrderQuoteReport}">
<link target="QuoteReport" target-window="_BLANK">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
@@ -379,26 +482,13 @@ under the License.
</link>
</menu-item>
</menu>
<menu name="RequestTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
<menu-item name="ViewRequest" title="${uiLabelMap.OrderRequestOverview}">
<menu-item name="ViewRequest" title="${uiLabelMap.CommonOverview}">
<link target="ViewRequest">
<parameter param-name="custRequestId" from-field="custRequest.custRequestId"/>
</link>
</menu-item>
<menu-item name="editRequest" title="${uiLabelMap.OrderRequest}">
<condition>
<and>
<not><if-empty field="custRequest"/></not>
<if-compare field="custRequest.statusId" operator="not-equals" value="CRQ_CANCELLED"/>
<if-compare field="custRequest.statusId" operator="not-equals" value="CRQ_COMPLETED"/>
</and>
</condition>
<link target="request">
<parameter param-name="custRequestId" from-field="custRequest.custRequestId"/>
</link>
</menu-item>
<menu-item name="requestroles" title="${uiLabelMap.OrderRequestRoles}">
<menu-item name="requestroles" title="${uiLabelMap.CommonRoles}">
<condition>
<and>
<not><if-empty field="custRequest"/></not>
@@ -410,7 +500,7 @@ under the License.
<parameter param-name="custRequestId" from-field="custRequest.custRequestId"/>
</link>
</menu-item>
<menu-item name="requestitems" title="${uiLabelMap.OrderRequestItems}">
<menu-item name="requestitems" title="${uiLabelMap.CommonItems}">
<condition>
<and>
<not><if-empty field="custRequest"/></not>
@@ -422,7 +512,7 @@ under the License.
<parameter param-name="custRequestId" from-field="custRequest.custRequestId"/>
</link>
</menu-item>
<menu-item name="custRequestContent" title="${uiLabelMap.OrderRequestContent}">
<menu-item name="custRequestContent" title="${uiLabelMap.CommonContent}">
<condition>
<and>
<not><if-empty field="custRequest"/></not>
@@ -435,9 +525,38 @@ under the License.
</link>
</menu-item>
</menu>
<menu name="RequestSubTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml"
menu-container-style="button-bar button-style-2">
<menu-item name="editRequest" title="${uiLabelMap.CommonEdit}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_UPDATE"/>
</or>
<not><if-empty field="custRequest"/></not>
<if-compare field="custRequest.statusId" operator="not-equals" value="CRQ_CANCELLED"/>
<if-compare field="custRequest.statusId" operator="not-equals" value="CRQ_COMPLETED"/>
</and>
</condition>
<link target="request">
<parameter param-name="custRequestId" from-field="custRequest.custRequestId"/>
</link>
</menu-item>
<menu-item name="NewRequestItem" title="${uiLabelMap.OrderNewRequestItem}">
<condition>
<and>
<or>
<if-has-permission permission="ORDERMGR" action="_CREATE"/>
</or>
<not><if-empty field="custRequest"/></not>
<if-compare field="custRequest.statusId" operator="not-equals" value="CRQ_CANCELLED"/>
<if-compare field="custRequest.statusId" operator="not-equals" value="CRQ_COMPLETED"/>
</and>
</condition>
<link target="requestitem">
<parameter param-name="custRequestId"/>
</link>
</menu-item>
<menu-item name="createQuoteFromRequest" title="${uiLabelMap.OrderCreateQuoteFromRequest}">
<condition>
<and>
@@ -25,6 +25,19 @@ under the License.
<!-- generate a PDF for the order, sharing the same groovy file as the HTML page for viewing the order -->
<screen name="OrderPDF">
<section>
<actions>
<set field="defaultTemplateLocation" value="component://order/widget/ordermgr/OrderPrintScreens.xml"/>
<set field="defaultTemplateName" value="DefaultOrderPDF"/>
<script location="component://commonext/groovyScripts/template/DocTypeTemplate.groovy"/>
</actions>
<widgets>
<include-screen name="${templateName}" location="${templateLocation}"/>
</widgets>
</section>
</screen>
<screen name="DefaultOrderPDF">
<section>
<actions>
<set field="titleProperty" value="OrderOrder" />
@@ -67,7 +67,7 @@ under the License.
<html><html-template multi-block="true" location="component://common-theme/template/includes/SetMultipleSelectJsList.ftl"/></html>
</platform-specific>
<include-form name="FindReturns" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-form name="ListReturns" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-grid name="ListReturns" location="component://order/widget/ordermgr/ReturnForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
@@ -168,7 +168,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="OrderReturnHistory">
<section>
<actions>
@@ -192,7 +191,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ReturnStatusHistory">
<section>
<actions>
@@ -209,7 +207,7 @@ under the License.
</condition>
<widgets>
<screenlet id="ReturnStatusHistoryPanel" title="${uiLabelMap.OrderOrderReturn} ${uiLabelMap.CommonStatusHistory}" collapsible="true">
<include-form name="ReturnStatusHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-grid name="ReturnStatusHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
@@ -221,7 +219,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ReturnTypeHistory">
<section>
<actions>
@@ -237,7 +234,7 @@ under the License.
</condition>
<widgets>
<screenlet id="ReturnTypeHistoryPanel" title="${uiLabelMap.OrderReturnTypeHistory}" collapsible="true">
<include-form name="ReturnTypeHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-grid name="ReturnTypeHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
@@ -249,7 +246,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ReturnReasonHistory">
<section>
<actions>
@@ -265,7 +261,7 @@ under the License.
</condition>
<widgets>
<screenlet id="ReturnReasonHistoryPanel" title="${uiLabelMap.OrderReturnReasonHistory}" collapsible="true">
<include-form name="ReturnReasonHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-grid name="ReturnReasonHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
@@ -277,7 +273,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ReturnQuantityHistory">
<section>
<actions>
@@ -293,7 +288,7 @@ under the License.
</condition>
<widgets>
<screenlet id="ReturnQuantityHistoryPanel" title="${uiLabelMap.OrderReturnQtyHistory}" collapsible="true">
<include-form name="ReturnAndReceivedQuantityHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-grid name="ReturnAndReceivedQuantityHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
@@ -305,7 +300,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ReceivedQuantityHistory">
<section>
<actions>
@@ -333,7 +327,6 @@ under the License.
</widgets>
</section>
</screen>
<screen name="ReturnPriceHistory">
<section>
<actions>
@@ -349,7 +342,7 @@ under the License.
</condition>
<widgets>
<screenlet id="ReturnPriceHistoryPanel" title="${uiLabelMap.OrderReturnPriceHistory}" collapsible="true">
<include-form name="ReturnPriceHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
<include-grid name="ReturnPriceHistory" location="component://order/widget/ordermgr/ReturnForms.xml"/>
</screenlet>
</widgets>
<fail-widgets>
@@ -42,9 +42,10 @@ under the License.
<not><if-empty field="quote"/></not>
</condition>
<widgets>
<label style="h1">${uiLabelMap.CommonQuote}:${quote.quoteId}</label>
<include-menu name="QuoteTabBar" location="component://order/widget/ordermgr/OrderMenus.xml"/>
<include-menu name="QuoteSubTabBar" location="component://order/widget/ordermgr/OrderMenus.xml"/>
<container style="page-title">
<label>${uiLabelMap[titleProperty]} [${uiLabelMap.CommonId}:${quote.quoteId}] ${quote.description}</label>
</container>
</widgets>
</section>
@@ -59,8 +60,6 @@ under the License.
</widgets>
</section>
</screen>
<!-- list all assets in a tabular format -->
<screen name="FindQuote">
<section>
<actions>
@@ -81,13 +80,17 @@ under the License.
<include-menu name="MainActionMenu" location="component://order/widget/ordermgr/OrderMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuotes}">
<platform-specific>
<html><html-template multi-block="true" location="component://common-theme/template/includes/SetMultipleSelectJsList.ftl"/></html>
</platform-specific>
<include-form name="FindQuotes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
<include-form name="ListQuotes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
<decorator-screen name="FindScreenDecorator" location="component://common/widget/CommonScreens.xml">
<decorator-section name="search-options">
<platform-specific>
<html><html-template multi-block="true" location="component://common-theme/template/includes/SetMultipleSelectJsList.ftl"/></html>
</platform-specific>
<include-form name="FindQuotes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</decorator-section>
<decorator-section name="search-results">
<include-form name="ListQuotes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</decorator-section>
</decorator-screen>
</decorator-section>
</decorator-screen>
</widgets>
@@ -98,7 +101,6 @@ under the License.
<actions>
<set field="titleProperty" value="OrderViewQuote"/>
<set field="tabButtonItem" value="ViewQuote"/>
<set field="showQuoteManagementLinks" value="Y"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<entity-one entity-name="Quote" value-field="quote"/>
@@ -107,7 +109,6 @@ under the License.
<get-related-one value-field="quote" relation-name="SalesChannelEnumeration" to-value-field="salesChannel"/>
<get-related-one value-field="quote" relation-name="Uom" to-value-field="currency"/>
<get-related-one value-field="quote" relation-name="ProductStore" to-value-field="store"/>
<set field="listOrderBy[]" value="quoteItemSeqId"/>
<get-related value-field="quote" relation-name="QuoteItem" list="quoteItems" order-by-list="listOrderBy"/>
<get-related value-field="quote" relation-name="QuoteAdjustment" list="quoteAdjustments"/>
@@ -121,9 +122,6 @@ under the License.
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<container>
<include-menu name="QuoteSubTabBar" location="component://order/widget/ordermgr/OrderMenus.xml"/>
</container>
<include-screen name="ViewQuoteTemplate"/>
<screenlet title="${uiLabelMap.OrderCopyQuote}">
<platform-specific>
@@ -145,11 +143,9 @@ under the License.
<get-related-one value-field="quote" relation-name="StatusItem" to-value-field="statusItem"/>
<get-related-one value-field="quote" relation-name="Uom" to-value-field="currency"/>
<get-related-one value-field="quote" relation-name="ProductStore" to-value-field="store"/>
<get-related value-field="quote" relation-name="QuoteItem" list="quoteItems"/>
<get-related value-field="quote" relation-name="QuoteAdjustment" list="quoteAdjustments"/>
<get-related value-field="quote" relation-name="QuoteRole" list="quoteRoles"/>
<property-map resource="OrderUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="AccountingUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="ProductUiLabels" map-name="uiLabelMap" global="true"/>
@@ -161,16 +157,28 @@ under the License.
</section>
</screen>
<!-- generate a PDF for the quote -->
<screen name="QuoteReport">
<section>
<actions>
<set field="defaultTemplateLocation" value="component://order/widget/ordermgr/QuoteScreens.xml"/>
<set field="defaultTemplateName" value="DefaultQuotePDF"/>
<script location="component://commonext/groovyScripts/template/DocTypeTemplate.groovy"/>
</actions>
<widgets>
<include-screen name="${templateName}" location="${templateLocation}"/>
</widgets>
</section>
</screen>
<screen name="DefaultQuotePDF">
<section>
<actions>
<set field="titleProperty" value="OrderOrderQuoteReport"/>
<property-map resource="OrderUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="AccountingUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="ProductUiLabels" map-name="uiLabelMap" global="true"/>
<property-map resource="CommonUiLabels" map-name="uiLabelMap" global="true"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<entity-one entity-name="Quote" value-field="quote"/>
<get-related-one value-field="quote" relation-name="QuoteType" to-value-field="quoteType"/>
@@ -179,11 +187,9 @@ under the License.
<get-related-one value-field="quote" relation-name="ProductStore" to-value-field="store"/>
<get-related-one value-field="quote" relation-name="Party" to-value-field="party"/>
<get-related value-field="quote" relation-name="QuoteTerm" list="quoteTerms"/>
<set field="listOrderBy[]" value="quoteItemSeqId"/>
<get-related value-field="quote" relation-name="QuoteItem" list="quoteItems" order-by-list="listOrderBy"/>
<get-related value-field="quote" relation-name="QuoteAdjustment" list="quoteAdjustments"/>
<script location="component://order/groovyScripts/quote/GetPartyAddress.groovy"/>
<!--
<get-related value-name="quote" relation-name="QuoteRole" list-name="quoteRoles"/>
@@ -229,27 +235,24 @@ under the License.
</widgets>
</section>
</screen>
<screen name="EditQuote">
<section>
<actions>
<set field="titleProperty" value="OrderOrderQuoteEdit"/>
<set field="headerItem" value="quote"/>
<set field="tabButtonItem" value="EditQuote"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<entity-one entity-name="Quote" value-field="quote"/>
<property-to-field field="defaultCurrencyUomId" resource="general" property="currency.uom.id.default" default="USD"/>
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${groovy: parameters.quoteId ? uiLabelMap.OrderOrderQuoteEdit : uiLabelMap.OrderNewQuote}">
<include-form name="EditQuote" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
<screenlet title="${uiLabelMap.PartyCreateNewPartyGroup}">
<include-form name="EditPartyGroup2" location="component://party/widget/partymgr/PartyForms.xml"/>
<include-form name="EditPartyGroupForNewQuote" location="component://party/widget/partymgr/PartyForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
@@ -261,22 +264,15 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteListRoles"/>
<set field="tabButtonItem" value="ListQuoteRoles"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-and entity-name="QuoteRole" list="quoteRoles">
<field-map field-name="quoteId" from-field="quote.quoteId"/>
</entity-and>
</actions>
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteListRoles}">
<container>
<link target="EditQuoteRole" text="${uiLabelMap.OrderCreateOrderQuoteRole}" style="buttontext">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<screenlet title="${uiLabelMap.CommonRoles}">
<include-form name="ListQuoteRoles" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -289,10 +285,8 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteEditRoles"/>
<set field="tabButtonItem" value="ListQuoteRoles"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<set field="quoteItemSeqId" from-field="parameters.quoteItemSeqId"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-one entity-name="QuoteRole" value-field="quoteRole"/>
</actions>
@@ -300,11 +294,6 @@ under the License.
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteEditRoles}">
<container>
<link target="EditQuoteRole" text="${uiLabelMap.OrderCreateOrderQuoteRole}" style="buttontext">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<include-form name="EditQuoteRole" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -317,7 +306,6 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteListItems"/>
<set field="tabButtonItem" value="ListQuoteItems"/>
<set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer"/>
<set field="viewSizeDefaultValue" value="${groovy: modelTheme.getDefaultViewSize()}" type="Integer"/>
<set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="${viewSizeDefaultValue}"/>
@@ -326,13 +314,11 @@ under the License.
<field-map field-name="quoteId" from-field="quote.quoteId"/>
<order-by field-name="quoteItemSeqId"/>
</entity-and>
</actions>
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<include-menu name="QuoteItemSubTabBar" location="component://order/widget/ordermgr/OrderMenus.xml"/>
<screenlet title="${uiLabelMap.OrderOrderQuoteListItems}">
<screenlet title="${uiLabelMap.CommonItems}">
<include-form name="ListQuoteItems" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -345,10 +331,8 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteEditItems"/>
<set field="tabButtonItem" value="ListQuoteItems"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<set field="quoteItemSeqId" from-field="parameters.quoteItemSeqId"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-one entity-name="QuoteItem" value-field="quoteItem"/>
<entity-and entity-name="QuoteTerm" list="quoteTerms">
@@ -359,26 +343,28 @@ under the License.
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<container>
<include-menu name="QuoteTermSubTabBar" location="component://order/widget/ordermgr/OrderMenus.xml"/>
</container>
<container style="lefthalf">
<screenlet title="${uiLabelMap.OrderOrderQuoteEditItems}" >
<section>
<condition>
<if-empty field="quoteItemSeqId"/>
</condition>
<widgets>
<screenlet title="${uiLabelMap.CommonItem}">
<include-form name="EditQuoteItem" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</container>
<container style="righthalf">
<section>
<condition>
<not><if-empty field="quoteItemSeqId"/></not>
</condition>
<widgets>
<screenlet title="${uiLabelMap.OrderOrderQuoteTermList}">
</widgets>
<fail-widgets>
<container style="lefthalf">
<screenlet title="${uiLabelMap.CommonItem}">
<include-form name="EditQuoteItem" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</container>
<container style="righthalf">
<screenlet title="${uiLabelMap.PartyTerms}">
<include-form name="ListQuoteTermItem" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</widgets>
</section>
</container>
</container>
</fail-widgets>
</section>
</decorator-section>
</decorator-screen>
</widgets>
@@ -389,7 +375,6 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteListAttributes"/>
<set field="tabButtonItem" value="ListQuoteAttributes"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-and entity-name="QuoteAttribute" list="quoteAttributes">
<field-map field-name="quoteId" from-field="quote.quoteId"/>
@@ -398,12 +383,7 @@ under the License.
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteListAttributes}">
<container style="basic-nav">
<link target="EditQuoteAttribute" text="${uiLabelMap.OrderCreateOrderQuoteAttribute}" style="buttontext">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<screenlet title="${uiLabelMap.CommonAttributes}">
<include-form name="ListQuoteAttributes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -416,22 +396,15 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteEditAttributes"/>
<set field="tabButtonItem" value="ListQuoteAttributes"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<set field="attrName" from-field="parameters.attrName"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-one entity-name="QuoteAttribute" value-field="quoteAttribute"/>
</actions>
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteEditAttributes}">
<container>
<link target="EditQuoteAttribute" text="${uiLabelMap.OrderCreateOrderQuoteAttribute}" style="buttontext">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<screenlet title="${uiLabelMap.CommonAttribute}">
<include-form name="EditQuoteAttribute" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -444,7 +417,6 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteListCoefficients"/>
<set field="tabButtonItem" value="ListQuoteCoefficients"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-and entity-name="QuoteCoefficient" list="quoteCoefficients">
<field-map field-name="quoteId" from-field="quote.quoteId"/>
@@ -454,11 +426,6 @@ under the License.
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteListCoefficients}">
<container style="basic-nav">
<link target="EditQuoteCoefficient" text="${uiLabelMap.OrderCreateOrderQuoteCoefficient}" style="buttontext">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<include-form name="ListQuoteCoefficients" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -471,22 +438,15 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteEditCoefficients"/>
<set field="tabButtonItem" value="ListQuoteCoefficients"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<set field="attrName" from-field="parameters.coeffName"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-one entity-name="QuoteCoefficient" value-field="quoteCoefficient"/>
</actions>
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteEditCoefficients}">
<container>
<link target="EditQuoteCoefficient" text="${uiLabelMap.OrderCreateOrderQuoteCoefficient}" style="buttontext">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<screenlet title="${uiLabelMap.CommonCoefficient}">
<include-form name="EditQuoteCoefficient" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
@@ -502,7 +462,6 @@ under the License.
<set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer"/>
<set field="viewSizeDefaultValue" value="${groovy: modelTheme.getDefaultViewSize()}" type="Integer"/>
<set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="${viewSizeDefaultValue}"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-and entity-name="QuoteItem" list="quoteItems">
<field-map field-name="quoteId" from-field="quote.quoteId"/>
@@ -514,7 +473,6 @@ under the License.
<field-map field-name="quoteId" from-field="quote.quoteId"/>
</entity-and>
<set from-field="quote.quoteId" field="quoteId"/>
<script location="component://order/groovyScripts/quote/ManageQuotePrices.groovy"/>
</actions>
<widgets>
@@ -544,7 +502,6 @@ under the License.
<set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer"/>
<set field="viewSizeDefaultValue" value="${groovy: modelTheme.getDefaultViewSize()}" type="Integer"/>
<set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="${viewSizeDefaultValue}"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-and entity-name="QuoteAdjustment" list="quoteAdjustments">
@@ -575,10 +532,8 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteEditAdjustments"/>
<set field="tabButtonItem" value="ListQuoteAdjustments"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<set field="quoteAdjustmentId" from-field="parameters.quoteAdjustmentId"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-one entity-name="QuoteAdjustment" value-field="quoteAdjustment"/>
</actions>
@@ -606,7 +561,6 @@ under the License.
<set field="viewIndex" from-field="parameters.VIEW_INDEX" type="Integer"/>
<set field="viewSizeDefaultValue" value="${groovy: modelTheme.getDefaultViewSize()}" type="Integer"/>
<set field="viewSize" from-field="parameters.VIEW_SIZE" type="Integer" default-value="${viewSizeDefaultValue}"/>
<entity-one entity-name="Quote" value-field="quote" auto-field-map="true"/>
<entity-and entity-name="QuoteItem" list="quoteItems">
<field-map field-name="quoteId" from-field="quote.quoteId"/>
@@ -618,7 +572,6 @@ under the License.
<field-map field-name="quoteId" from-field="quote.quoteId"/>
</entity-and>
<set from-field="quote.quoteId" field="quoteId"/>
<script location="component://order/groovyScripts/quote/ViewQuoteProfit.groovy"/>
</actions>
<widgets>
@@ -640,7 +593,6 @@ under the License.
<actions>
<set field="titleProperty" value="OrderOrderQuoteEditReportMail"/>
<set field="tabButtonItem" value="ViewQuote"/>
<set field="quoteId" from-field="parameters.quoteId"/>
<entity-one entity-name="Quote" value-field="quote"/>
<get-related-one value-field="quote" relation-name="Party" to-value-field="party"/>
@@ -666,7 +618,7 @@ under the License.
<label text="${note}"/>
<include-screen name="ViewQuoteInfo"/>
<container style="clear"/>
<include-screen name="ViewQuoteItemInfo"/>
<include-screen name="ViewQuoteItemInfo"/>
</widgets>
<fail-widgets>
<label style="h3">${uiLabelMap.OrderNoQuoteFound}</label>
@@ -702,7 +654,7 @@ under the License.
<section>
<actions>
<entity-one entity-name="PartyNameView" value-field="toParty">
<field-map field-name="partyId" from-field="quote.partyId"/>
<field-map field-name="partyId" from-field="quote.partyId"/>
</entity-one>
</actions>
<widgets>
@@ -838,7 +790,6 @@ under the License.
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<include-menu name="QuoteTermSubTabBar" location="component://order/widget/ordermgr/OrderMenus.xml"/>
<screenlet title="${uiLabelMap.OrderOrderQuoteTermList}">
<include-form name="ListQuoteTerms" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
@@ -863,12 +814,9 @@ under the License.
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<container style="button-bar button-style-1">
<link target="createnewquotenote" text="${uiLabelMap.OrderCreateOrderQuoteNote}">
<parameter param-name="quoteId" from-field="quote.quoteId"/>
</link>
</container>
<include-form name="ListQuoteNotes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
<screenlet id="Notes" title="${uiLabelMap.CommonNotes}">
<include-form name="ListQuoteNotes" location="component://order/widget/ordermgr/QuoteForms.xml"/>
</screenlet>
</decorator-section>
</decorator-screen>
</widgets>
@@ -927,5 +875,4 @@ under the License.
</fail-widgets>
</section>
</screen>
</screens>
@@ -122,12 +122,7 @@ under the License.
<widgets>
<decorator-screen name="CommonQuoteDecorator">
<decorator-section name="body">
<screenlet title="${uiLabelMap.OrderOrderQuoteWorkEfforts}">
<container style="basic-nav">
<link target="AddQuoteWorkEffort" text="${uiLabelMap.OrderCreateQuoteWorkEffort}" style="buttontext">
<parameter param-name="quoteId"/>
</link>
</container>
<screenlet title="${uiLabelMap.WorkEffortWorkEfforts}">
<include-form name="ListQuoteWorkEfforts" location="component://order/widget/ordermgr/QuoteWorkEffortForms.xml"/>
</screenlet>
</decorator-section>
@@ -282,7 +282,7 @@ under the License.
</drop-down>
</field>
<field name="productId" title="${uiLabelMap.ProductProductId}"><lookup target-form-name="LookupProduct"/></field>
<field name="requirementByDate"><date-find type="date"/></field>
<field name="requiredByDate"><date-find type="date"/></field>
<field name="submitButton" title="${uiLabelMap.CommonFind}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<form name="ApprovedProductRequirementsList" type="list" title="" list-name="requirementsForSupplier" paginate-target="RequirementsForSupplier"
@@ -109,17 +109,6 @@ under the License.
<field use-when="returnHeader==null&amp;&amp;returnId==null" name="createdBy"><ignored/></field>
<field name="submitButton" title="${uiLabelMap.CommonSubmit}" widget-style="smallSubmit"><submit button-type="button"/></field>
</form>
<!-- UNUSED FORM
<form name="ReturnItems" type="multi" list-name="orderItems" target="createReturnItem"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<auto-fields-service service-name="createReturnItem"/>
<field name="itemDescription"><display/></field>
<field name="returnId"><hidden/></field>
<field name="orderId"><hidden/></field>
<field name="orderItemSeqId"><hidden/></field>
<field name="statusId"><ignored/></field>
</form>
-->
<form name="FindReturns" type="single" target="findreturn" title="" default-map-name="parameters"
header-row-style="header-row" default-table-style="basic-table">
<field name="returnHeaderTypeId">
@@ -149,9 +138,8 @@ under the License.
<submit button-type="button"/>
</field>
</form>
<form name="ListReturns" type="list" target="findreturn" title="" list-name="listIt"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar" paginate-target="findreturn">
<grid name="ListReturns" list-name="listIt" target="findreturn" paginate-target="findreturn"
odd-row-style="alternate-row" default-table-style="basic-table hover-bar">
<actions>
<service service-name="performFind" result-map="result" result-map-list="listIt">
<field-map field-name="inputFields" from-field="requestParameters"/>
@@ -184,25 +172,24 @@ under the License.
<field name="statusId" title="${uiLabelMap.CommonStatus}">
<display-entity entity-name="StatusItem" key-field-name="statusId"/>
</field>
</form>
<form name="ReturnStatusHistory" type="list" list-name="orderReturnStatusHistories"
</grid>
<grid name="ReturnStatusHistory" list-name="orderReturnStatusHistories"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<field name="returnId"><display/></field>
<field name="returnItemSeqId"><display/></field>
<field name="statusId"><display-entity entity-name="StatusItem"/></field>
<field name="statusDatetime" title="${uiLabelMap.CommonDate}"><display/></field>
<field name="changeByUserLoginId" title="${uiLabelMap.FormFieldTitle_modifiedByUserLoginId}"><display/></field>
</form>
<form name="ReturnAndReceivedQuantityHistory" type="list" list-name="orderReturnItemHistories"
</grid>
<grid name="ReturnAndReceivedQuantityHistory" list-name="orderReturnItemHistories"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<field name="returnId"><display description="${returnId}"/></field>
<field name="oldValueText"><display/></field>
<field name="newValueText"><display/></field>
<field name="changedDate" title="${uiLabelMap.CommonDate}"><display/></field>
<field name="changedByInfo" title="${uiLabelMap.FormFieldTitle_modifiedByUserLoginId}"><display/></field>
</form>
<form name="ReturnReasonHistory" type="list" list-name="orderReturnItemHistories"
</grid>
<grid name="ReturnReasonHistory" list-name="orderReturnItemHistories"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<field name="returnId"><display description="${returnId}"/></field>
<field name="oldValueText">
@@ -213,8 +200,8 @@ under the License.
</field>
<field name="changedDate" title="${uiLabelMap.CommonDate}"><display/></field>
<field name="changedByInfo" title="${uiLabelMap.FormFieldTitle_modifiedByUserLoginId}"><display/></field>
</form>
<form name="ReturnTypeHistory" type="list" list-name="orderReturnItemHistories"
</grid>
<grid name="ReturnTypeHistory" list-name="orderReturnItemHistories"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<field name="returnId"><display description="${returnId}"/></field>
<field name="oldValueText">
@@ -225,13 +212,13 @@ under the License.
</field>
<field name="changedDate" title="${uiLabelMap.CommonDate}"><display/></field>
<field name="changedByInfo" title="${uiLabelMap.FormFieldTitle_modifiedByUserLoginId}"><display/></field>
</form>
<form name="ReturnPriceHistory" type="list" list-name="orderReturnItemHistories"
</grid>
<grid name="ReturnPriceHistory" list-name="orderReturnItemHistories"
odd-row-style="alternate-row" header-row-style="header-row-2" default-table-style="basic-table hover-bar">
<field name="returnId"><display description="${returnId}"/></field>
<field name="oldValueText"><display type="currency"/></field>
<field name="newValueText"><display type="currency"/></field>
<field name="changedDate" title="${uiLabelMap.CommonDate}"><display/></field>
<field name="changedByInfo" title="${uiLabelMap.FormFieldTitle_modifiedByUserLoginId}"><display/></field>
</form>
</grid>
</forms>
@@ -68,6 +68,7 @@ under the License.
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
<section>
<condition>
<and>
@@ -29,6 +29,7 @@ under the License.
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
<section>
<condition>
<if-has-permission permission="PARTYMGR" action="_VIEW"/>
@@ -60,6 +60,7 @@ under the License.
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
<section>
<condition>
<if-service-permission service-name="partyBasePermissionCheck" main-action="VIEW"/>
@@ -295,15 +295,15 @@ under the License.
</drop-down>
</field>
<field name="submitButton" title="${uiLabelMap.CommonSave}"><submit button-type="button"/></field>
<field name="cancelLink" title=" " widget-style="smallSubmit">
<field name="cancelLink" use-when="partyGroup==null" title=" " widget-style="smallSubmit">
<hyperlink description="${uiLabelMap.CommonCancelDone}" target="backHome" also-hidden="false"/>
</field>
</form>
<form name="EditPartyGroup2" type="single" target="createPartyGroup" default-map-name="partyGroup"
<form name="EditPartyGroupForNewQuote" type="single" target="createPartyGroup" default-map-name="partyGroup" extends="EditPartyGroup"
header-row-style="header-row" default-table-style="basic-table">
<field name="groupName"><text size="6" maxlength="10"/></field>
<field name="submitButton" title="${uiLabelMap.CommonCreate}"><submit button-type="button"/></field>
<field name="cancelLink"><hidden/></field>
</form>
<form name="ViewPartyGroup" type="single" default-map-name="lookupGroup">
@@ -30,6 +30,7 @@ under the License.
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
<section>
<condition>
<and>
@@ -80,6 +81,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<section>
<condition>
@@ -118,6 +122,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<section>
<condition>
@@ -37,7 +37,28 @@
<menu-item name="partyinv" title="${uiLabelMap.PartyInvitation}"><link target="partyInvitation"/></menu-item>
<menu-item name="importexport" title="${uiLabelMap.CommonImportExport}"><link target="ImportExport"/></menu-item>
</menu>
<menu name="MainActionMenu" menu-container-style="button-bar button-style-2" default-selected-style="selected">
<menu-item name="newPerson" title="${uiLabelMap.PartyCreateNewPerson}">
<condition>
<or>
<if-has-permission permission="PARTYMGR" action="_CREATE"/>
</or>
</condition>
<link target="editperson">
<parameter param-name="create_new" value="Y"/>
</link>
</menu-item>
<menu-item name="newPartyGroup" title="${uiLabelMap.CommonNew} ${uiLabelMap.CommonGroup}">
<condition>
<or>
<if-has-permission permission="PARTYMGR" action="_CREATE"/>
</or>
</condition>
<link target="editpartygroup">
<parameter param-name="create_new" value="Y"/>
</link>
</menu-item>
</menu>
<menu name="PartyShortcutAppBar" title="${uiLabelMap.PartyManager}">
<menu-item name="find" title="${uiLabelMap.PartyParties}"><link target="/partymgr/control/findparty" url-mode="inter-app"/></menu-item>
<menu-item name="mycomm" title="${uiLabelMap.PartyMyCommunications}"><link target="/partymgr/control/MyCommunicationEvents" url-mode="inter-app"/></menu-item>
@@ -236,22 +257,6 @@
</menu-item>
</menu>
<menu name="CreateNewParty" menu-container-style="basic-nav">
<menu-item name="create-party-group" title="${uiLabelMap.PartyCreateNewPartyGroup}">
<condition>
<if-has-permission permission="PARTYMGR" action="_CREATE"/>
</condition>
<link target="editpartygroup">
<parameter param-name="create_new" value="Y"/>
</link>
</menu-item>
<menu-item name="create-person" title="${uiLabelMap.PartyCreateNewPerson}">
<condition>
<if-has-permission permission="PARTYMGR" action="_CREATE"/>
</condition>
<link target="editperson">
<parameter param-name="create_new" value="Y"/>
</link>
</menu-item>
<menu-item name="create-customer" title="${uiLabelMap.PartyCreateNewCustomer}">
<condition>
<if-has-permission permission="PARTYMGR" action="_CREATE"/>
@@ -41,6 +41,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<platform-specific><html><html-template multi-block="true" location="component://common-theme/template/includes/SetMultipleSelectJs.ftl"/></html></platform-specific>
<section>
@@ -637,7 +640,7 @@ under the License.
<screenlet id="AddUserLoginSecurityGroupsPanel" title="${uiLabelMap.AddUserLoginToSecurityGroup}" collapsible="true">
<include-form name="AddUserLoginSecurityGroup" location="component://common/widget/SecurityForms.xml"/>
</screenlet>
<include-form name="ListUserLoginSecurityGroups" location="component://common/widget/SecurityForms.xml"/>
<include-grid name="ListUserLoginSecurityGroups" location="component://common/widget/SecurityForms.xml"/>
</decorator-section>
</decorator-screen>
</widgets>
@@ -30,6 +30,9 @@ under the License.
</actions>
<widgets>
<decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}">
<decorator-section name="pre-body">
<include-menu name="MainActionMenu" location="component://party/widget/partymgr/PartyMenus.xml"/>
</decorator-section>
<decorator-section name="body">
<section>
<!-- do check for PARTYMGR, _VIEW permission -->
@@ -3533,7 +3533,7 @@
<value xml:lang="zh-TW">促銷包</value>
</property>
<property key="ProductType.description.MARKETING_PKG_AUTO">
<value xml:lang="de">Marketingpaket</value>
<value xml:lang="de">Marketingpaket: Automatisch produziert</value>
<value xml:lang="en">Marketing Package: Auto Manufactured</value>
<value xml:lang="es">Paquete de marketing</value>
<value xml:lang="es-CL">Paquete de Marketing: Auto Fabricado</value>
+23 -15
View File
@@ -9167,7 +9167,7 @@
<value xml:lang="es">"Identificación de la instalación de inventario requerida"</value>
<value xml:lang="zh">必须有库存场所标识</value>
</property>
<property key="lotIdFilledInAllowed">
<value xml:lang="de">Erlaubt</value>
<value xml:lang="en">Allowed</value>
@@ -11198,6 +11198,7 @@
<value xml:lang="zh-TW">尋找分類</value>
</property>
<property key="PageTitleFindCatalog">
<value xml:lang="de">Katalog suchen</value>
<value xml:lang="en">Find Catalog</value>
<value xml:lang="es">Buscar Catálogo</value>
<value xml:lang="fr">Recherche de catalogues</value>
@@ -11331,6 +11332,7 @@
<value xml:lang="zh-TW">尋找庫存細項標籤</value>
</property>
<property key="PageTitleFindProduct">
<value xml:lang="de">Produkt suchen</value>
<value xml:lang="en">Find Product</value>
<value xml:lang="es">Buscar Producto</value>
<value xml:lang="fr">Recherche d'articles</value>
@@ -13101,7 +13103,7 @@
</property>
<property key="ProductAddProductsUsingDefaultQuantities">
<value xml:lang="cs">Přidat výrobky této skupiny do košíku v přednastaveném možství</value>
<value xml:lang="de">Produkte dieser Produktgruppe in der vorgegebenen Menge in den Warenkorb legen</value>
<value xml:lang="de">Produkte dieser Produktkategorie in der vorgegebenen Menge in den Warenkorb legen</value>
<value xml:lang="en">Add Products in this Category to the Cart using Default Quantities</value>
<value xml:lang="en-GB">Add Products in this Category to the basket using default quantities</value>
<value xml:lang="es">Agregue los productos en esta categoría al carro usando cantidades predeterminadas</value>
@@ -13298,7 +13300,7 @@
</property>
<property key="ProductAdvancedSearchInCategory">
<value xml:lang="cs">Rozšířené hledání ve skupině výrobků</value>
<value xml:lang="de">Erweiterte Suche in der Produktgruppe</value>
<value xml:lang="de">Erweiterte Suche in der Produktkategorie</value>
<value xml:lang="en">Advanced Search in Category</value>
<value xml:lang="es">Búsqueda Avanzada en las Categorías</value>
<value xml:lang="fr">Recherche avancée dans la catégorie</value>
@@ -13875,7 +13877,7 @@
<value xml:lang="zh">关联</value>
<value xml:lang="zh-TW">結合</value>
</property>
<property key="ProductOrderReturnStatus">
<value xml:lang="de">Zurück Sendungsstatus</value>
<value xml:lang="en">Return Shipment Status</value>
@@ -14379,7 +14381,7 @@
</property>
<property key="ProductBrowseCategories">
<value xml:lang="cs">Výběr skupiny výrobků</value>
<value xml:lang="de">Produktgruppen durchsuchen</value>
<value xml:lang="de">Produktkategorien durchsuchen</value>
<value xml:lang="en">Browse Categories</value>
<value xml:lang="es">Hojear Categorías</value>
<value xml:lang="es-CL">Navegar Categorías</value>
@@ -14749,7 +14751,7 @@
<value xml:lang="de">Katalogname [ID]</value>
<value xml:lang="en">Catalog Name [Id]</value>
<value xml:lang="es">Nombre de Catálogo [Código]</value>
<value xml:lang="fr">Catalogue ; Nom ; [Réf.]</value>
<value xml:lang="fr">Nom de Catalogue [Réf.]</value>
<value xml:lang="it">Nome catalogo [Codice]</value>
<value xml:lang="ja">カタログ名称 [ID]</value>
<value xml:lang="nl">Catalogusnaam [ID]</value>
@@ -14866,7 +14868,7 @@
</property>
<property key="ProductCategory">
<value xml:lang="cs">Skupina výrobků</value>
<value xml:lang="de">Produktgruppe</value>
<value xml:lang="de">Kategorie</value>
<value xml:lang="en">Category</value>
<value xml:lang="es">Categoría</value>
<value xml:lang="fr">Catégorie</value>
@@ -14983,7 +14985,7 @@
</property>
<property key="ProductCategoryNotFoundForCategoryID">
<value xml:lang="cs">Skupina výrobků nenalezena</value>
<value xml:lang="de">Produktgruppe wurde nicht gefunden mit ID</value>
<value xml:lang="de">Kategorie wurde nicht gefunden mit ID</value>
<value xml:lang="en">Category not found for Category ID</value>
<value xml:lang="es">Categoría no encontrada por ID</value>
<value xml:lang="fr">Aucune catégorie pour cet réf.</value>
@@ -15000,11 +15002,11 @@
<value xml:lang="zh-TW">沒有找到分類識別</value>
</property>
<property key="ProductCategoryAttrAlreadyExists">
<value xml:lang="de">Eine Attribut mit diesem Namen existiert bereits für die Produktgruppe mit dieser ID.</value>
<value xml:lang="de">Eine Attribut mit diesem Namen existiert bereits für die Kategorie mit dieser ID.</value>
<value xml:lang="en">There already is an attribute with this name for a group with this ID.</value>
</property>
<property key="ProductCategoryAlreadyExists">
<value xml:lang="de">Eine Produktgruppe mit dieser ID existiert bereits.</value>
<value xml:lang="de">Eine Kategorie mit dieser ID existiert bereits.</value>
<value xml:lang="en">There already is a Category with this ID.</value>
</property>
<property key="ProductCategoryNoVariants">
@@ -15367,7 +15369,7 @@
</property>
<property key="ProductChooseQuickAddCategory">
<value xml:lang="cs">Výběr zrychleným zadáním produktové skupiny</value>
<value xml:lang="de">Auswahl einer Produktgruppe für Schnelleingabe</value>
<value xml:lang="de">Auswahl einer Produktkategorie für Schnelleingabe</value>
<value xml:lang="en">Choose QuickAdd Category</value>
<value xml:lang="es">Elegir la categoría Añadir-Rápido</value>
<value xml:lang="fr">Choisir une catégorie d'ajout-rapide</value>
@@ -20866,6 +20868,10 @@
<value xml:lang="zh">这个明细缺货</value>
<value xml:lang="zh-TW">這個細項缺貨</value>
</property>
<property key="ProductCannotReserveInventoryNotEnoughStock">
<value xml:lang="it">Impossibile riservare l'articolo ${parameters.productId}: quantità in stock non sufficiente nel deposito ${parameters.facilityId}. Quantità non riservata è ${parameters.quantityNotReserved}</value>
<value xml:lang="en">Cannot reserve product ${parameters.productId}: not enough quantity left in stock for facility ${parameters.facilityId}. Quantity not reserved is ${parameters.quantityNotReserved}</value>
</property>
<property key="ProductItemPrc">
<value xml:lang="de">Position Preis</value>
<value xml:lang="en">Item Prc</value>
@@ -23268,7 +23274,7 @@
</property>
<property key="ProductNoProductsInThisCategory">
<value xml:lang="cs">V této skupině nejsou žádné výrobky</value>
<value xml:lang="de">Es gibt keine Produkte in dieser Produktgruppe</value>
<value xml:lang="de">Es gibt keine Produkte in dieser Produktkategorie</value>
<value xml:lang="en">There are no products in this category</value>
<value xml:lang="es">No hay productos en esta categoría</value>
<value xml:lang="fr">Aucun article dans cette catégorie</value>
@@ -25739,6 +25745,8 @@
<value xml:lang="de">Produkt</value>
<value xml:lang="en">Product</value>
<value xml:lang="es">Producto</value>
<value xml:lang="es-CL">Producto</value>
<value xml:lang="es-MX">Producto</value>
<value xml:lang="fr">Article</value>
<value xml:lang="it">Prodotto</value>
<value xml:lang="ja">製品</value>
@@ -29046,7 +29054,7 @@
</property>
<property key="ProductSearchInCategory">
<value xml:lang="cs">Hledání ve skupině výrobků</value>
<value xml:lang="de">Suche in Produktgruppe</value>
<value xml:lang="de">Suche in Produktkategorie</value>
<value xml:lang="en">Search in Category</value>
<value xml:lang="es">Buscar en la Categoría</value>
<value xml:lang="fr">Rechercher dans la catégorie</value>
@@ -30954,7 +30962,7 @@
<value xml:lang="vi">Để kiểm soát cách nhìn và cảm quan và cửa hàng trực tuyến</value>
<value xml:lang="zh">用于控制一个网店的外观感受。</value>
<value xml:lang="zh-TW">用於控制一個網店的外觀感受.</value>
</property>
</property>
<property key="ProductStoresFor">
<value xml:lang="de">Läden für</value>
<value xml:lang="en">Stores For</value>
@@ -33245,4 +33253,4 @@
<value xml:lang="zh">使用购物车数量</value>
<value xml:lang="zh-TW">使用購物車數量</value>
</property>
</resource>
</resource>
@@ -21,8 +21,7 @@
# -- Image upload path on the server
#FIXME the image server path need to be move on runtime
image.server.path=${sys:getProperty('ofbiz.home')}/themes/common/images/webapp/images/${tenantId}
image.server.path=${sys:getProperty('ofbiz.home')}/themes/common-theme/images/webapp/images/${tenantId}
# -- The prefix to put on auto-generated image urls (can be relative or absolute, whatever you want)
image.url.prefix=/images/${tenantId}
@@ -37,8 +36,7 @@ all.product.category=CATALOG1
reactivate.product.from.receipt=Y
# Image upload path on the image management
#FIXME the image management path need to be move on runtime
image.management.path=${sys:getProperty('ofbiz.home')}/themes/common/webapp/images/products/management
image.management.path=${sys:getProperty('ofbiz.home')}/themes/common-theme/webapp/images/products/management
image.management.url=/images/products/management
image.management.nameofthumbnail=-100
image.management.autoApproveImage=Y
@@ -0,0 +1,48 @@
/*
* 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.
*/
package facility.storage
import org.apache.ofbiz.entity.GenericValue
/**
* Create a Facility Location
* @return
*/
def createFacilityLocation() {
GenericValue newEntity = makeValue("FacilityLocation", parameters)
String locationSeqId = "${parameters.areaId ?: ''}${parameters.aisleId ?: ''}${parameters.sectionId ?: ''}${parameters.levelId ?: ''}${parameters.positionId ?: ''}"
if (locationSeqId) {
int i = 1
String nextLocationSeqId = locationSeqId
while (from("FacilityLocation")
.where([locationSeqId: nextLocationSeqId,
facilityId: parameters.facilityId])
.queryOne()) {
nextLocationSeqId = "${locationSeqId}_${i++}"
}
locationSeqId = nextLocationSeqId
} else {
locationSeqId = delegator.getNextSeqId("FacilityLocation")
}
newEntity.locationSeqId = locationSeqId
newEntity.create()
return success(locationSeqId : newEntity.locationSeqId)
}
@@ -0,0 +1,44 @@
/*
* 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.
*/
package product.promo
import org.apache.ofbiz.entity.GenericValue
def createProductPromoCond() {
if (parameters.carrierShipmentMethod) {
parameters.otherValue = parameters.carrierShipmentMethod
}
GenericValue newEntity = makeValue("ProductPromoCond", parameters)
delegator.setNextSubSeqId(newEntity, "productPromoCondSeqId", 2, 1)
newEntity.create()
return success([productPromoCondSeqId: newEntity.productPromoCondSeqId])
}
def updateProductPromoCond() {
GenericValue lookedUpValue = from("ProductPromoCond").where(parameters).queryOne()
if (lookedUpValue) {
if (parameters.carrierShipmentMethod) {
parameters.otherValue = parameters.carrierShipmentMethod
}
lookedUpValue.setNonPKFields(parameters)
lookedUpValue.store()
return success()
}
return error(label("ServiceErrorUiLabels", "ServiceValueNotFound"))
}
@@ -176,6 +176,7 @@ def reserveStoreInventory() {
List productStoreFacilities = from("ProductStoreFacility")
.where(productStoreId: productStore.productStoreId)
.orderBy("sequenceNum")
.filterByDate()
.cache()
.queryList()
for (GenericValue productStoreFacility : productStoreFacilities) {
@@ -184,29 +185,28 @@ def reserveStoreInventory() {
// TODO: must entire quantity be available in one location?
// Right now the answer is yes, it only succeeds if one facility has sufficient inventory for the order.
Map callServiceMapIABF = [productId: parameters.productId, facilityId: productStoreFacility.facilityId]
logInfo("ProductStoreService:In productStoreFacilities loop: [" + parameters.facilityId + "]")
Map serviceResultIABF = run service: "getInventoryAvailableByFacility", with: callServiceMapIABF
BigDecimal availableToPromiseTotal = serviceResultIABF.availableToPromiseTotal
if (availableToPromiseTotal >= parameters.quantity) {
storeFound = productStoreFacility
}
}
}
// didn't find anything? Take the first facility from list
GenericValue defaultStoreFound
if (!storeFound) {
storeFound = productStoreFacilities.get(0)
defaultStoreFound = productStore.getRelatedOne("Facility", true)
}
facilityId = storeFound.facilityId ?: ""
facilityId = storeFound ? storeFound.facilityId : defaultStoreFound.facilityId
Map serviceResult = run service: "reserveProductInventoryByFacility", with: [*: parameters,
facilityId: facilityId,
requireInventory: requireInventory,
reserveOrderEnumId: productStore.reserveOrderEnumId]
quantityNotReserved = serviceResult.quantityNotReserved
logInfo("Inventory IS reserved in facility with id [${storeFound.facilityId}] for product id [${parameters.productId}]; desired quantity was ${parameters.quantity}")
logInfo("Inventory IS reserved in facility with id [${facilityId}] for product id [${parameters.productId}]; desired quantity was ${parameters.quantity}")
}
} else {
List productStoreFacilities = from("ProductStoreFacility").where(productStoreId: productStore.productStoreId, facilityId: facilityId).cache().orderBy("sequenceNum").queryList()
List productStoreFacilities = from("ProductStoreFacility").where(productStoreId: productStore.productStoreId, facilityId: facilityId).cache().orderBy("sequenceNum").filterByDate().queryList()
GenericValue facilityFound
for (GenericValue productStoreFacility : productStoreFacilities) {
// Search Product Store Facilities to insure the facility passed in is associated to the Product Store passed in
@@ -314,6 +314,7 @@ def isStoreInventoryAvailable() {
List productStoreFacilities = from("ProductStoreFacility")
.where(productStoreId: productStore.productStoreId)
.orderBy("sequenceNum")
.filterByDate()
.cache()
.queryList()
available = "N"
@@ -0,0 +1,119 @@
/*
* 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.
*/
import org.apache.ofbiz.entity.GenericValue
/**
* Create a Subscription
* @return
*/
def createSubscription() {
GenericValue newEntity = makeValue('Subscription')
String subscriptionId = parameters.subscriptionId ?: delegator.getNextSeqId('Subscription')
newEntity.subscriptionId = subscriptionId
// lookup the product subscription resource (if exists)
if (parameters.subscriptionResourceId && parameters.productId) {
GenericValue resource = from('ProductSubscriptionResource')
.where(subscriptionResourceId: parameters.subscriptionResourceId,
productId: parameters.productId )
.filterByDate()
.orderBy('-fromDate')
.queryFirst()
if (resource) {
newEntity.setNonPKFields(resource.getAllFields())
}
}
newEntity.setNonPKFields(parameters)
newEntity.create()
return success(subscriptionId: subscriptionId)
}
/**
* Check if a party has a subscription
* @return
*/
def isSubscribed() {
Map result = success()
Map serviceContext = [entityName: 'Subscription',
inputFields: parameters,
filterByDate: parameters.filterByDate ?: 'Y']
Map serviceResult = run service: 'performFindList', with: serviceContext
Boolean found = serviceResult.list
if (serviceResult.list) {
result.subscriptionId = serviceResult.list[0].subscriptionId
}
result.isSubscribed = found
return result
}
/**
* Get Subscription data
* @return
*/
def getSubscription() {
Map result = success()
GenericValue subscription = from('Subscription')
.where(parameters)
.queryOne()
result.subscriptionId = parameters.subscriptionId
if (subscription) result.subscription = subscription
return result
}
/**
* Create (when not exist) or update (when exist) a Subscription attribute
* @return
*/
def updateSubscriptionAttribute() {
GenericValue lookedUpValue = from('SubscriptionAttribute')
.where(parameters)
.queryOne()
if (lookedUpValue) {
lookedUpValue.setNonPKFields(parameters)
lookedUpValue.store()
} else {
GenericValue newEntity = makeValue('SubscriptionAttribute')
newEntity.setPKFields(parameters)
newEntity.setNonPKFields(parameters)
newEntity.create()
}
return success(subscriptionId: parameters.subscriptionId)
}
/**
* Subscription permission checking logic
* @return
*/
def subscriptionPermissionCheck() {
parameters.primaryPermission = "CATALOG"
Map result = run service: "genericBasePermissionCheck", with: parameters
// Backwards compatibility - check for non-existent CATALOG_READ permission
result.hasPermission = result.hasPermission ||
(parameters.mainAction == 'VIEW' &&
security.hasPermission('CATALOG_READ', userLogin))
return result
}
@@ -0,0 +1,31 @@
/*
* 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.
*/
package product.supplier
/**
* Get all supplier information for a product feature
*/
def getSupplierProductFeatures() {
return success([supplierProductFeatures: from('SupplierProductFeature')
.where(partyId: parameters.partyId,
productFeatureId: parameters.productFeatureId)
.cache()
.queryList()])
}
@@ -163,7 +163,14 @@ under the License.
-->
<if-compare field="parameters.quantityNotReserved" operator="not-equals" value="0" type="BigDecimal">
<if-compare field="parameters.requireInventory" operator="equals" value="Y">
<!-- use this else pattern to accomplish the anything but Y logic, ie if not specified default to inventory NOT required -->
<!-- if there is still quantity not reserved but ProductStore is configured to require inventory, we can
assume here that also reserveInventory is set to Y (reserveInventory is checked by caller services).
In such a scenario we return an error and avoid order creation.
-->
<add-error>
<fail-property resource="ProductUiLabels" property="ProductCannotReserveInventoryNotEnoughStock"/>
</add-error>
<check-errors/>
<else>
<if-not-empty field="lastNonSerInventoryItem">
<!-- subtract from quantityNotReserved from the availableToPromise of existing inventory item -->
@@ -1,47 +0,0 @@
<?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.
-->
<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://ofbiz.apache.org/Simple-Method" xsi:schemaLocation="http://ofbiz.apache.org/Simple-Method http://ofbiz.apache.org/dtds/simple-methods.xsd">
<!-- ProductPromoCond methods -->
<simple-method method-name="createProductPromoCond" short-description="Create an ProductPromoCond">
<make-value entity-name="ProductPromoCond" value-field="newEntity"/>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
<if-not-empty field="parameters.carrierShipmentMethod">
<set field="newEntity.otherValue" from-field="parameters.carrierShipmentMethod"/>
</if-not-empty>
<set-pk-fields map="parameters" value-field="newEntity"/>
<make-next-seq-id value-field="newEntity" seq-field-name="productPromoCondSeqId" numeric-padding="2"/>
<field-to-result field="newEntity.productPromoCondSeqId" result-name="productPromoCondSeqId"/>
<create-value value-field="newEntity"/>
</simple-method>
<simple-method method-name="updateProductPromoCond" short-description="Update an ProductPromoCond">
<make-value entity-name="ProductPromoCond" value-field="lookupPKMap"/>
<set-pk-fields map="parameters" value-field="lookupPKMap"/>
<find-by-primary-key entity-name="ProductPromoCond" map="lookupPKMap" value-field="lookedUpValue"/>
<set-nonpk-fields map="parameters" value-field="lookedUpValue"/>
<if-not-empty field="parameters.carrierShipmentMethod">
<set field="lookedUpValue.otherValue" from-field="parameters.carrierShipmentMethod"/>
</if-not-empty>
<store-value value-field="lookedUpValue"/>
</simple-method>
</simple-methods>
@@ -1,56 +0,0 @@
<?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.
-->
<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://ofbiz.apache.org/Simple-Method" xsi:schemaLocation="http://ofbiz.apache.org/Simple-Method http://ofbiz.apache.org/dtds/simple-methods.xsd">
<!-- Facility Location Services -->
<simple-method method-name="createFacilityLocation" short-description="Create a Facility Location">
<make-value entity-name="FacilityLocation" value-field="newEntity"/>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
<set field="newEntity.facilityId" from-field="parameters.facilityId"/>
<set field="locationSeqId" value="${parameters.areaId}${parameters.aisleId}${parameters.sectionId}${parameters.levelId}${parameters.positionId}"/>
<!-- check to see if it exists already, if so try a simple suffix, then give up and use a sequenced id -->
<if-not-empty field="locationSeqId">
<set field="checkLocationSeqIdMap.locationSeqId" from-field="locationSeqId"/>
<set field="checkLocationSeqIdMap.facilityId" from-field="parameters.facilityId"/>
<find-by-primary-key entity-name="FacilityLocation" map="checkLocationSeqIdMap" value-field="checkLocationSeqIdValue"/>
<if-not-empty field="checkLocationSeqIdValue">
<set field="locationSeqId" value="${locationSeqId}_2"/>
<set field="checkLocationSeqIdMap.locationSeqId" from-field="locationSeqId"/>
<set field="checkLocationSeqIdMap.facilityId" from-field="parameters.facilityId"/>
<find-by-primary-key entity-name="FacilityLocation" map="checkLocationSeqIdMap" value-field="checkLocationSeqIdValue"/>
<if-not-empty field="checkLocationSeqIdValue">
<set field="locationSeqId" value=""/>
</if-not-empty>
</if-not-empty>
</if-not-empty>
<if-empty field="locationSeqId">
<sequenced-id sequence-name="FacilityLocation" field="locationSeqId"/>
<to-string field="locationSeqId"/>
</if-empty>
<set field="newEntity.locationSeqId" from-field="locationSeqId"/>
<field-to-result field="locationSeqId" result-name="locationSeqId"/>
<create-value value-field="newEntity"/>
</simple-method>
</simple-methods>
@@ -1,117 +0,0 @@
<?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.
-->
<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://ofbiz.apache.org/Simple-Method" xsi:schemaLocation="http://ofbiz.apache.org/Simple-Method http://ofbiz.apache.org/dtds/simple-methods.xsd">
<simple-method method-name="createSubscription" short-description="Create a Subscription">
<make-value entity-name="Subscription" value-field="newEntity"/>
<if-empty field="parameters.subscriptionId">
<sequenced-id sequence-name="Subscription" field="newEntity.subscriptionId"/> <!-- get the next sequenced ID -->
<else>
<set field="newEntity.subscriptionId" from-field="parameters.subscriptionId"/>
</else>
</if-empty>
<field-to-result field="newEntity.subscriptionId" result-name="subscriptionId"/>
<!-- lookup the product subscription resource (if exists) -->
<if-not-empty field="parameters.subscriptionResourceId">
<if-not-empty field="parameters.productId">
<entity-and entity-name="ProductSubscriptionResource" list="resourceList" filter-by-date="true">
<field-map field-name="subscriptionResourceId" from-field="parameters.subscriptionResourceId"/>
<field-map field-name="productId" from-field="parameters.productId"/>
<order-by field-name="-fromDate"/>
</entity-and>
<first-from-list list="resourceList" entry="resource"/>
<if-not-empty field="resource">
<set-nonpk-fields map="resource" value-field="newEntity"/>
</if-not-empty>
</if-not-empty>
</if-not-empty>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
<create-value value-field="newEntity"/>
</simple-method>
<simple-method method-name="isSubscribed" short-description="check if a party has a subscription">
<set field="pfInput.inputFields" from-field="parameters"/>
<set field="pfInput.entityName" value="Subscription"/>
<set field="pfInput.filterByDate" from-field="parameters.filterByDate" default-value="Y"/>
<call-service service-name="performFindList" in-map-name="pfInput">
<result-to-field result-name="list" field="pfResultList"/>
</call-service>
<if-empty field="pfResultList">
<set field="found" value="false" type="Boolean"/>
<else>
<set field="found" value="true" type="Boolean"/>
<first-from-list list="pfResultList" entry="subscription"/>
<field-to-result field="subscription.subscriptionId" result-name="subscriptionId"/>
</else>
</if-empty>
<field-to-result field="found" result-name="isSubscribed"/>
</simple-method>
<simple-method method-name="getSubscription" short-description="Get Subscription data">
<entity-one entity-name="Subscription" value-field="subscription"/>
<field-to-result field="parameters.subscriptionId" result-name="subscriptionId"/>
<if-not-empty field="subscription">
<field-to-result field="subscription" result-name="subscription"/>
</if-not-empty>
</simple-method>
<simple-method method-name="updateSubscriptionAttribute" short-description="Create (when not exist) or update (when exist) a Subscription attribute">
<field-to-result field="parameters.subscriptionId" result-name="subscriptionId"/>
<entity-one entity-name="SubscriptionAttribute" value-field="lookedUpValue"/>
<if-empty field="lookedUpValue">
<make-value entity-name="SubscriptionAttribute" value-field="newEntity"/>
<set-pk-fields map="parameters" value-field="newEntity"/>
<set-nonpk-fields map="parameters" value-field="newEntity"/>
<create-value value-field="newEntity"/>
<else>
<set-nonpk-fields map="parameters" value-field="lookedUpValue"/>
<store-value value-field="lookedUpValue"/>
</else>
</if-empty>
</simple-method>
<!-- ============== Permission Checking Service ============= -->
<simple-method method-name="subscriptionPermissionCheck" short-description="Subscription permission checking logic">
<set field="primaryPermission" value="CATALOG"/>
<call-simple-method method-name="genericBasePermissionCheck" xml-resource="component://common/minilang/permission/CommonPermissionServices.xml"/>
<!-- Backwards compatibility - check for non-existent CATALOG_READ permission -->
<if>
<condition>
<and>
<if-compare field="hasPermission" value="false" operator="equals" type="Boolean"/>
<if-compare field="mainAction" value="VIEW" operator="equals"/>
</and>
</condition>
<then>
<if-has-permission permission="CATALOG_READ">
<set field="hasPermission" type="Boolean" value="true"/>
<field-to-result field="hasPermission"/>
</if-has-permission>
</then>
</if>
</simple-method>
</simple-methods>
@@ -1,31 +0,0 @@
<?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.
-->
<simple-methods xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://ofbiz.apache.org/Simple-Method" xsi:schemaLocation="http://ofbiz.apache.org/Simple-Method http://ofbiz.apache.org/dtds/simple-methods.xsd">
<simple-method method-name="getSupplierProductFeatures" short-description="Get all supplier information for a product feature" login-required="false">
<entity-and entity-name="SupplierProductFeature" list="supplierProductFeatures">
<field-map field-name="partyId" from-field="parameters.partyId"/>
<field-map field-name="productFeatureId" from-field="parameters.productFeatureId"/>
</entity-and>
<field-to-result field="supplierProductFeatures"/>
</simple-method>
</simple-methods>
+6 -6
View File
@@ -528,13 +528,13 @@ under the License.
</required-permissions>
<auto-attributes mode="IN" include="pk" optional="false"/>
</service>
<service name="getSupplierProductFeatures" engine="simple"
location="component://product/minilang/product/supplier/SupplierProductServices.xml" invoke="getSupplierProductFeatures">
<service name="getSupplierProductFeatures" engine="groovy" invoke="getSupplierProductFeatures"
location="component://product/groovyScripts/product/supplier/SupplierProductServices.groovy">
<description>Finds a list of SupplierProductFeature entities based on the productFeatureId.
If a partyId is given, only product feature information for that supplier party is returned.</description>
<attribute name="productFeatureId" type="String" mode="IN" optional="false"/>
<attribute name="productFeatureId" type="String" mode="IN"/>
<attribute name="partyId" type="String" mode="IN" optional="true"/>
<attribute name="supplierProductFeatures" type="java.util.List" mode="OUT" optional="false"/>
<attribute name="supplierProductFeatures" type="java.util.List" mode="OUT"/>
</service>
<service name="createProductMaint" default-entity-name="ProductMaint" engine="entity-auto" invoke="create" auth="true">
@@ -944,8 +944,8 @@ under the License.
</group>
</service>
<service name="updateContentSEOForCategory" engine="simple"
location="component://product/minilang/product/category/CategoryContentServices.xml" invoke="updateContentSEOForCategory" auth="true">
<service name="updateContentSEOForCategory" engine="groovy"
location="component://product/groovyScripts/product/category/CategoryContentServices.groovy" invoke="updateContentSEOForCategory" auth="true">
<description>Update SEO Content For Product Category</description>
<attribute name="productCategoryId" mode="IN" type="String" optional="false"/>
<attribute name="title" mode="IN" type="String" optional="true"/>
@@ -917,18 +917,17 @@ under the License.
<auto-attributes mode="IN" entity-name="FacilityAttribute" include="pk" optional="false"/>
</service>
<service name="createFacilityLocation" default-entity-name="FacilityLocation" engine="simple"
location="component://product/minilang/product/storage/StorageServices.xml" invoke="createFacilityLocation" auth="true">
<service name="createFacilityLocation" default-entity-name="FacilityLocation" engine="groovy" invoke="createFacilityLocation"
location="component://product/groovyScripts/facility/storage/StorageServices.groovy" auth="true">
<description>Create a Facility Location</description>
<permission-service service-name="facilityGenericPermission" main-action="CREATE"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="facilityId" type="String" mode="IN" optional="false">
<attribute name="facilityId" type="String" mode="IN">
<type-validate>
<fail-property resource="ProductErrorUiLabels" property="facility.facilityId"/>
</type-validate>
</attribute>
<attribute name="locationSeqId" type="String" mode="OUT" optional="false"/>
<attribute name="locationSeqId" type="String" mode="OUT"/>
</service>
<service name="updateFacilityLocation" default-entity-name="FacilityLocation" engine="entity-auto" invoke="update" auth="true">
<description>Update a Facility Location</description>
@@ -256,21 +256,21 @@ under the License.
<attribute name="codeLength" type="Integer" mode="IN" optional="true" default-value="8"/>
<attribute name="promoCodeLayout" type="String" mode="IN" optional="true" default-value="sequence"/>
</service>
<service name="createProductPromoCond" default-entity-name="ProductPromoCond" engine="simple"
location="component://product/minilang/product/promo/PromoServices.xml" invoke="createProductPromoCond" auth="true">
<service name="createProductPromoCond" default-entity-name="ProductPromoCond" engine="groovy" invoke="createProductPromoCond"
location="component://product/groovyScripts/product/promo/PromoServices.groovy" auth="true">
<description>Create a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="CREATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="pk" mode="IN"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="carrierShipmentMethod" type="String" mode="IN" optional="true"/>
<override name="productPromoCondSeqId" mode="OUT"/>
</service>
<service name="updateProductPromoCond" default-entity-name="ProductPromoCond" engine="simple"
location="component://product/minilang/product/promo/PromoServices.xml" invoke="updateProductPromoCond" auth="true">
<service name="updateProductPromoCond" default-entity-name="ProductPromoCond" engine="groovy" invoke="updateProductPromoCond"
location="component://product/groovyScripts/product/promo/PromoServices.groovy" auth="true">
<description>Update a ProductPromo</description>
<permission-service service-name="productPriceGenericPermission" main-action="UPDATE"/>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="pk" mode="IN"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<attribute name="carrierShipmentMethod" type="String" mode="IN" optional="true"/>
</service>
@@ -23,8 +23,8 @@ under the License.
<description>Product Component Services for subscriptions entity (subscription entity not ContentRoles)</description>
<vendor>OFBiz</vendor>
<service name="createSubscription" default-entity-name="Subscription" auth="true" engine="simple"
location="component://product/minilang/product/subscription/SubscriptionServices.xml" invoke="createSubscription">
<service name="createSubscription" default-entity-name="Subscription" auth="true" engine="groovy"
location="component://product/groovyScripts/product/subscription/SubscriptionServices.groovy" invoke="createSubscription">
<description>Create a Subscription Record</description>
<permission-service service-name="subscriptionPermissionCheck" main-action="CREATE"/>
<auto-attributes include="pk" mode="INOUT" optional="true"/>
@@ -37,8 +37,8 @@ under the License.
<auto-attributes include="nonpk" mode="IN" optional="true"/>
</service>
<service name="isSubscribed" default-entity-name="Subscription" auth="true" engine="simple"
location="component://product/minilang/product/subscription/SubscriptionServices.xml" invoke="isSubscribed">
<service name="isSubscribed" default-entity-name="Subscription" auth="true" engine="groovy"
location="component://product/groovyScripts/product/subscription/SubscriptionServices.groovy" invoke="isSubscribed">
<description>Check if a particular party has at this moment a subscription</description>
<permission-service service-name="subscriptionPermissionCheck" main-action="VIEW"/>
<auto-attributes include="all" mode="IN" optional="true"/>
@@ -48,8 +48,8 @@ under the License.
<override name="partyId" optional="false" mode="IN"/>
</service>
<service name="getSubscriptionEnt" default-entity-name="Subscription" auth="true" engine="simple"
location="component://product/minilang/product/subscription/SubscriptionServices.xml" invoke="getSubscription">
<service name="getSubscriptionEnt" default-entity-name="Subscription" auth="true" engine="groovy"
location="component://product/groovyScripts/product/subscription/SubscriptionServices.groovy" invoke="getSubscription">
<description>Retrieve a single Subscription Entity Record</description>
<permission-service service-name="subscriptionPermissionCheck" main-action="VIEW"/>
<auto-attributes include="pk" mode="INOUT" optional="false"/>
@@ -130,8 +130,8 @@ under the License.
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<auto-attributes include="pk" mode="INOUT" optional="false"/>
</service>
<service name="updateSubscriptionAttribute" default-entity-name="SubscriptionAttribute" auth="true" engine="simple"
location="component://product/minilang/product/subscription/SubscriptionServices.xml" invoke="updateSubscriptionAttribute">
<service name="updateSubscriptionAttribute" default-entity-name="SubscriptionAttribute" auth="true" engine="groovy"
location="component://product/groovyScripts/product/subscription/SubscriptionServices.groovy" invoke="updateSubscriptionAttribute">
<description>Create (when not exist) or update (when exist) a Subscription attribute</description>
<permission-service service-name="subscriptionPermissionCheck" main-action="UPDATE"/>
<attribute name="subscriptionId" type="String" mode="INOUT" optional="false">
@@ -162,8 +162,8 @@ under the License.
<auto-attributes include="pk" mode="IN" optional="false"/>
</service>
<service name="subscriptionPermissionCheck" engine="simple"
location="component://product/minilang/product/subscription/SubscriptionServices.xml" invoke="subscriptionPermissionCheck" auth="true">
<service name="subscriptionPermissionCheck" engine="groovy"
location="component://product/groovyScripts/product/subscription/SubscriptionServices.groovy" invoke="subscriptionPermissionCheck" auth="true">
<description>Subscription Permission Checking Logic</description>
<implements service="permissionInterface"/>
</service>
@@ -48,11 +48,12 @@ import org.apache.ofbiz.base.util.Debug;
import org.apache.ofbiz.base.util.StringUtil;
import org.apache.ofbiz.base.util.UtilHttp;
import org.apache.ofbiz.base.util.UtilValidate;
import org.apache.ofbiz.security.SecurityUtil;
import org.apache.ofbiz.webapp.SeoConfigUtil;
import org.apache.ofbiz.webapp.control.ConfigXMLReader;
import org.apache.ofbiz.webapp.control.ConfigXMLReader.ControllerConfig;
import org.apache.ofbiz.webapp.control.ControlFilter;
import org.apache.ofbiz.webapp.control.WebAppConfigurationException;
import org.apache.ofbiz.webapp.SeoConfigUtil;
import org.apache.oro.text.regex.Pattern;
import org.apache.oro.text.regex.Perl5Matcher;
@@ -115,6 +116,10 @@ public final class SeoContextFilter implements Filter {
uri = uri + "?" + queryString;
}
if (SecurityUtil.containsFreemarkerInterpolation(httpRequest, httpResponse, uri)) {
return;
}
boolean forwarded = forwardUri(httpResponse, uri);
if (forwarded) {
return;
@@ -224,6 +224,7 @@ public class ScaleImage {
try {
String fileToCheck = imageServerPath + "/" + newFileLocation + "." + imgExtension;
ImageIO.write(bufNewImg, imgExtension, new File(fileToCheck));
// Check if a webshell is not uploaded
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(fileToCheck, "Image", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedImageFormats", locale);
return ServiceUtil.returnError(errorMessage);
@@ -402,6 +403,7 @@ public class ScaleImage {
try {
String fileToCheck = imageServerPath + "/" + newFileLocation + "." + imgExtension;
ImageIO.write(bufNewImg, imgExtension, new File(fileToCheck));
// Check if a webshell is not uploaded
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(fileToCheck, "Image", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedImageFormats", locale);
return ServiceUtil.returnError(errorMessage);
@@ -290,7 +290,7 @@ public class FrameImage {
if (UtilValidate.isEmpty(imageName) || UtilValidate.isEmpty(imageData)) {
session.setAttribute("frameContentId", request.getParameter("frameExistContentId"));
session.setAttribute("frameDataResourceId", request.getParameter("frameExistDataResourceId"));
request.setAttribute("_ERROR_MESSAGE_", "There is no frame image, please select the image type *.PNG uploading.");
request.setAttribute("_ERROR_MESSAGE_", "There is no frame image, please select the image type *.PNG to upload.");
return "error";
}
if (!"image/png".equals(mimType)) {
@@ -320,6 +320,7 @@ public class FrameImage {
}
Path tmpFile = Files.createTempFile(null, null);
Files.write(tmpFile, imageData.array(), StandardOpenOption.APPEND);
// Check if a webshell is not uploaded
if (!org.apache.ofbiz.security.SecuredUpload.isValidFile(tmpFile.toString(), "Image", delegator)) {
String errorMessage = UtilProperties.getMessage("SecurityUiLabels", "SupportedFileFormatsIncludingSvg", locale);
request.setAttribute("_ERROR_MESSAGE_", errorMessage);

Some files were not shown because too many files have changed in this diff Show More