[ofbiz-framework] branch trunk updated: Improved: Added UI labels for success/error messages for humanres, marketing, order component. (OFBIZ-7696) Thanks Deepak Nigam for reporting and Sourabh Punyani for the patch.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch trunk updated: Improved: Added UI labels for success/error messages for humanres, marketing, order component. (OFBIZ-7696) Thanks Deepak Nigam for reporting and Sourabh Punyani for the patch.

surajk
This is an automated email from the ASF dual-hosted git repository.

surajk pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new a178b79  Improved: Added UI labels for success/error messages for humanres, marketing, order component. (OFBIZ-7696) Thanks Deepak Nigam for reporting and Sourabh Punyani for the patch.
a178b79 is described below

commit a178b791079abf1584186af7b51dedd2ebaf4200
Author: Suraj Khurana <[hidden email]>
AuthorDate: Sun May 24 13:03:03 2020 +0530

    Improved: Added UI labels for success/error messages for humanres, marketing, order component.
    (OFBIZ-7696)
    Thanks Deepak Nigam for reporting and Sourabh Punyani for the patch.
---
 applications/humanres/config/HumanResErrorUiLabels.xml       |  9 +++++++++
 applications/humanres/minilang/HumanResEvents.xml            |  6 +++---
 applications/marketing/config/MarketingUiLabels.xml          |  9 +++++++++
 .../minilang/marketing/contact/ContactListServices.xml       | 12 +++++++++---
 applications/order/config/OrderErrorUiLabels.xml             |  3 +++
 applications/order/minilang/order/OrderServices.xml          |  2 +-
 6 files changed, 34 insertions(+), 7 deletions(-)

diff --git a/applications/humanres/config/HumanResErrorUiLabels.xml b/applications/humanres/config/HumanResErrorUiLabels.xml
index f521936..7829a38 100644
--- a/applications/humanres/config/HumanResErrorUiLabels.xml
+++ b/applications/humanres/config/HumanResErrorUiLabels.xml
@@ -51,4 +51,13 @@
     <property key="HRRequiredFieldMissingTrainingClassTypeId">
         <value xml:lang="en">Required Field Missing : Training Class Type Id.</value>
     </property>
+    <property key="HumanResHolidayNameMissing">
+        <value xml:lang="en">The Holiday Name is missing.</value>
+    </property>
+    <property key="HumanResFromDateMissing">
+        <value xml:lang="en">The FromDate is missing</value>
+    </property>
+    <property key="HumanResFromDateAlreadyExist">
+        <value xml:lang="en">This FromDate : ${parameters.estimatedStartDate} already exist.</value>
+    </property>
 </resource>
\ No newline at end of file
diff --git a/applications/humanres/minilang/HumanResEvents.xml b/applications/humanres/minilang/HumanResEvents.xml
index 21ae3c9..6d6187e 100644
--- a/applications/humanres/minilang/HumanResEvents.xml
+++ b/applications/humanres/minilang/HumanResEvents.xml
@@ -57,13 +57,13 @@
     <simple-method method-name="createPublicHoliday" short-description="Create Public Holiday">
         <if-empty field="parameters.workEffortName">            
             <add-error>
-                <fail-message message="The Holiday Name is missing."/>
+                <fail-property resource="HumanResErrorUiLabels" property="HumanResHolidayNameMissing"/>
             </add-error>
             <check-errors/>
         </if-empty>    
         <if-empty field="parameters.estimatedStartDate">
             <add-error>
-                <fail-message message="The FromDate is missing"/>
+                <fail-property resource="HumanResErrorUiLabels" property="HumanResFromDateMissing"/>
             </add-error>
             <check-errors/>
         </if-empty>
@@ -82,7 +82,7 @@
             </call-service>
             <else>
                 <add-error>
-                    <fail-message message="This FromDate : ${parameters.estimatedStartDate} already exist."/>
+                    <fail-property resource="HumanResErrorUiLabels" property="HumanResFromDateAlreadyExist"/>
                 </add-error>
                 <check-errors/>
             </else>
diff --git a/applications/marketing/config/MarketingUiLabels.xml b/applications/marketing/config/MarketingUiLabels.xml
index db4c218..937c473 100644
--- a/applications/marketing/config/MarketingUiLabels.xml
+++ b/applications/marketing/config/MarketingUiLabels.xml
@@ -856,6 +856,15 @@
         <value xml:lang="de">Der bevorzugte Kontaktmechanismus für Party [${partyId}] konnte nicht gefunden werden</value>
         <value xml:lang="en">Could not find the preferred contact mechanism for party [${parameters.partyId}]</value>
     </property>
+    <property key="MarketingContactListInvalidVerifyCode">
+        <value xml:lang="en">Invalid verify code for the ${contactList.contactListName}</value>
+    </property>
+    <property key="MarketingContactListAnotherEmailNotExist">
+        <value xml:lang="en">The email address (${parameters.email}) does not have the Other Email Address as contact purpose</value>
+    </property>
+    <property key="MarketingContactListPermissionError">
+        <value xml:lang="en">Security Error: to run sendContactListPartyVerifyEmail you must have the MARKETING_VIEW or MARKETING_ADMIN permissions</value>
+    </property>
     <property key="MarketingContactMechNotRightForContactList">
         <value xml:lang="de">Der bevorzugte Kontaktmechanismus [${preferredContactMechType.description}] ist vom falschen Typ für die Liste [${listContactMechType.description}].</value>
         <value xml:lang="en">The preferred contact mechanism [${preferredContactMechType.description}] was not of the right type for the list [${listContactMechType.description}].</value>
diff --git a/applications/marketing/minilang/marketing/contact/ContactListServices.xml b/applications/marketing/minilang/marketing/contact/ContactListServices.xml
index 5dac862..0bb7117 100644
--- a/applications/marketing/minilang/marketing/contact/ContactListServices.xml
+++ b/applications/marketing/minilang/marketing/contact/ContactListServices.xml
@@ -172,7 +172,9 @@ under the License.
             <set field="updateContactListPartyMap.baseLocation" from-field="parameters.baseLocation"/>
             <call-service service-name="updateContactListParty" in-map-name="updateContactListPartyMap"/>
             <else>
-                <add-error><fail-message message="Invalid verify code for the ${contactList.contactListName}"/></add-error>
+                <add-error>
+                    <fail-property resource="MarketingUiLabels.xml" property="MarketingContactListInvalidVerifyCode"/>
+                </add-error>
                 <check-errors/>
             </else>
         </if-not-empty>
@@ -226,7 +228,9 @@ under the License.
                     <set field="updateContactListPartyMap.baseLocation" from-field="parameters.baseLocation"/>
                     <call-service service-name="updateContactListParty" in-map-name="updateContactListPartyMap"/>
                     <else>
-                        <add-error><fail-message message="The email address (${parameters.email}) does not have the Other Email Address as contact purpose."/></add-error>
+                        <add-error>
+                            <fail-property resource="MarketingUiLabels.xml" property="MarketingContactListAnotherEmailNotExist"/>
+                        </add-error>
                         <check-errors/>
                     </else>
                 </if-not-empty>
@@ -545,7 +549,9 @@ under the License.
                     <not><if-has-permission permission="MARKETING" action="_VIEW"/></not>
                 </and>
             </condition>
-            <then><add-error><fail-message message="Security Error: to run sendContactListPartyVerifyEmail you must have the MARKETING_VIEW or MARKETING_ADMIN permissions."/></add-error></then>
+            <then><add-error>
+                <fail-property resource="MarketingUiLabels.xml" property="MarketingContactListPermissionError"/>
+            </add-error></then>
         </if>
         <check-errors/>
 
diff --git a/applications/order/config/OrderErrorUiLabels.xml b/applications/order/config/OrderErrorUiLabels.xml
index d093fef..941e334 100644
--- a/applications/order/config/OrderErrorUiLabels.xml
+++ b/applications/order/config/OrderErrorUiLabels.xml
@@ -4570,6 +4570,9 @@
         <value xml:lang="zh">服务没有执行</value>
         <value xml:lang="zh-TW">服務沒有執行</value>
     </property>
+    <property key="OrderServiceOrderItemShipGroupAssocNotExist">
+        <value xml:lang="en">The orderItemShipGroupAssoc qualified by orderId=${parameters.orderId} orderItemSeqId=${parameters.orderItemSeqId} shipGroupSeqId=${parameters.fromGroupIndex} does not exist</value>
+    </property>
     <property key="OrderSetCurrencyError">
         <value xml:lang="ar">حدد خطأ العملة : </value>
         <value xml:lang="de">Fehler beim Auswählen der Währung : </value>
diff --git a/applications/order/minilang/order/OrderServices.xml b/applications/order/minilang/order/OrderServices.xml
index f318825..6906b73 100644
--- a/applications/order/minilang/order/OrderServices.xml
+++ b/applications/order/minilang/order/OrderServices.xml
@@ -1300,7 +1300,7 @@ under the License.
         </entity-one>
         <if-empty field="orderItemShipGroupAssoc">
             <add-error>
-                <fail-message message="The orderItemShipGroupAssoc qualified by orderId=${parameters.orderId} orderItemSeqId=${parameters.orderItemSeqId} shipGroupSeqId=${parameters.fromGroupIndex} does not exist"/>
+                <fail-property resource="OrderErrorUiLabels" property="OrderServiceOrderItemShipGroupAssocNotExist"/>
             </add-error>
         </if-empty>
         <check-errors/>