You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2014/06/01 14:34:25 UTC

svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Author: jleroux
Date: Sun Jun  1 12:34:24 2014
New Revision: 1598977

URL: http://svn.apache.org/r1598977
Log:
A modified patch from Ankit Jain for "We should check that the thru date is not same or older than the from date" https://issues.apache.org/jira/browse/OFBIZ-3161

jleroux: 
I reused Ankit's patch as a basis for this commit
I added an i18n label
Added a way to use alert() in showErrorAlertLoadUiLabel for generalising when no contentarea is present
Replaced $ call by jQuery
Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get all cases (228 thruDate cases)
Still used only an alert, so it's only a warning, nothing coercive

There are other date couples like (estimatedStartDate, estimatedCompletionDate) and (actualStartDate, actualCompletionDate) but their values should not be enforced.
If ever someone wants to not let them free, then she just has to add the couples in FromThruDateCheck.js




Added:
    ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js   (with props)
Modified:
    ofbiz/trunk/framework/common/config/CommonUiLabels.xml
    ofbiz/trunk/framework/common/widget/CommonScreens.xml
    ofbiz/trunk/framework/images/webapp/images/selectall.js

Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
+++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1 12:34:24 2014
@@ -4457,6 +4457,10 @@
         <value xml:lang="zh-CN">起始日期 / 终止日期</value>
         <value xml:lang="zh-TW">開始日/結束日</value>
     </property>
+    <property key="CommonFromDateThruDateCheck">
+        <value xml:lang="en">Thru date can't be same or smaller than from date</value>
+        <value xml:lang="fr">La date de fin ne peut être égale ou plus récente que la date de début</value>
+    </property>
     <property key="CommonFromDateTime">
         <value xml:lang="ar">تاريخ  و وقت البدء</value>
         <value xml:lang="cs">Od data a času</value>

Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
==============================================================================
--- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
+++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1 12:34:24 2014
@@ -162,6 +162,7 @@ under the License.
                 <set field="layoutSettings.javaScripts[]" value="/images/miscAjaxFunctions.js" global="true" />
                 <set field="layoutSettings.javaScripts[]" value="/images/selectMultipleRelatedValues.js" global="true" />
                 <set field="layoutSettings.javaScripts[]" value="/images/util.js" global="true" />
+                <set field="layoutSettings.javaScripts[]" value="/images/date/FromThruDateCheck.js" global="true"/>                
                 <set field="visualThemeId" from-field="userPreferences.VISUAL_THEME" global="true" />
                 <service service-name="getVisualThemeResources">
                     <field-map field-name="visualThemeId" />

Added: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
==============================================================================
--- ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js (added)
+++ ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js Sun Jun  1 12:34:24 2014
@@ -0,0 +1,17 @@
+//this code needs modifications yet its specific.
+
+jQuery(document).ready( function() {
+  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
+  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
+});
+
+function checkDate() {
+  var a = jQuery("input[name*='fromDate']");
+  var b = jQuery("input[name*='thruDate']");
+
+  if(a.val() !="" && b.val() !="") {
+    if (a.val() >= b.val()) {
+      showErrorAlertLoadUiLabel("", "", "CommonUiLabels", "CommonFromDateThruDateCheck")
+    }
+  }
+}

Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
------------------------------------------------------------------------------
    svn:keywords = Date Rev Author URL Id

Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
==============================================================================
--- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
+++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun  1 12:34:24 2014
@@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
                 }
             }
         });
+    } else {
+      alert(labels[uiResource][0]);
     }
 }
 
@@ -985,4 +987,4 @@ function submitPagination(obj, url) {
             return true;
         }
     }
-}
\ No newline at end of file
+}



Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Jacques Le Roux <ja...@les7arts.com>.
Ha I see you mean the label only! Yes of course, I will fix that!

But what did you fix exactly? I see 9 occurrences in labels only in CommonThruDate...

Jacques

Le 01/06/2014 17:50, Adrian Crum a écrit :
> I fixed the misspelled word a while ago. It would be nice if we stopped deliberately committing improper spellings.
>
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
>
> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>> Right, and you know I did not invent this "word".
>>
>> I simply reused "thru " here to keep the subject focused.
>>
>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>> maybe you do?
>>
>> Jacques
>>
>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>> "Thru" is not an English word. The correct spelling is "Through".
>>>
>>> Adrian Crum
>>> Sandglass Software
>>> www.sandglass-software.com
>>>
>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>> Author: jleroux
>>>> Date: Sun Jun  1 12:34:24 2014
>>>> New Revision: 1598977
>>>>
>>>> URL: http://svn.apache.org/r1598977
>>>> Log:
>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>> date is not same or older than the from date"
>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>
>>>> jleroux:
>>>> I reused Ankit's patch as a basis for this commit
>>>> I added an i18n label
>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>> generalising when no contentarea is present
>>>> Replaced $ call by jQuery
>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>>> all cases (228 thruDate cases)
>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>
>>>> There are other date couples like (estimatedStartDate,
>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>> but their values should not be enforced.
>>>> If ever someone wants to not let them free, then she just has to add
>>>> the couples in FromThruDateCheck.js
>>>>
>>>>
>>>>
>>>>
>>>> Added:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> (with props)
>>>> Modified:
>>>>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>
>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>>> 12:34:24 2014
>>>> @@ -4457,6 +4457,10 @@
>>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>       </property>
>>>> +    <property key="CommonFromDateThruDateCheck">
>>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>>> from date</value>
>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>> plus récente que la date de début</value>
>>>> +    </property>
>>>>       <property key="CommonFromDateTime">
>>>>           <value xml:lang="ar">تاريخ  و وقت البدء</value>
>>>>           <value xml:lang="cs">Od data a času</value>
>>>>
>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>> 12:34:24 2014
>>>> @@ -162,6 +162,7 @@ under the License.
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/util.js" global="true" />
>>>> +                <set field="layoutSettings.javaScripts[]"
>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>                   <set field="visualThemeId"
>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>                   <service service-name="getVisualThemeResources">
>>>>                       <field-map field-name="visualThemeId" />
>>>>
>>>> Added:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>
>>>> ==============================================================================
>>>>
>>>> ---
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> (added)
>>>> +++
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> Sun Jun  1 12:34:24 2014
>>>> @@ -0,0 +1,17 @@
>>>> +//this code needs modifications yet its specific.
>>>> +
>>>> +jQuery(document).ready( function() {
>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>> +});
>>>> +
>>>> +function checkDate() {
>>>> +  var a = jQuery("input[name*='fromDate']");
>>>> +  var b = jQuery("input[name*='thruDate']");
>>>> +
>>>> +  if(a.val() !="" && b.val() !="") {
>>>> +    if (a.val() >= b.val()) {
>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>> "CommonFromDateThruDateCheck")
>>>> +    }
>>>> +  }
>>>> +}
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------
>>>>
>>>>      svn:eol-style = native
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------
>>>>
>>>>      svn:keywords = Date Rev Author URL Id
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------
>>>>
>>>>      svn:mime-type = text/plain
>>>>
>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>> 1 12:34:24 2014
>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>                   }
>>>>               }
>>>>           });
>>>> +    } else {
>>>> +      alert(labels[uiResource][0]);
>>>>       }
>>>>   }
>>>>
>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>               return true;
>>>>           }
>>>>       }
>>>> -}
>>>> \ No newline at end of file
>>>> +}
>>>>
>>>>
>>>
>>
>

-- 

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Jacques Le Roux <ja...@les7arts.com>.
Fixed the remaining ones in labels at revision: 1599110

Jacques

Le 01/06/2014 17:50, Adrian Crum a écrit :
> I fixed the misspelled word a while ago. It would be nice if we stopped deliberately committing improper spellings.
>
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
>
> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>> Right, and you know I did not invent this "word".
>>
>> I simply reused "thru " here to keep the subject focused.
>>
>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>> maybe you do?
>>
>> Jacques
>>
>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>> "Thru" is not an English word. The correct spelling is "Through".
>>>
>>> Adrian Crum
>>> Sandglass Software
>>> www.sandglass-software.com
>>>
>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>> Author: jleroux
>>>> Date: Sun Jun  1 12:34:24 2014
>>>> New Revision: 1598977
>>>>
>>>> URL: http://svn.apache.org/r1598977
>>>> Log:
>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>> date is not same or older than the from date"
>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>
>>>> jleroux:
>>>> I reused Ankit's patch as a basis for this commit
>>>> I added an i18n label
>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>> generalising when no contentarea is present
>>>> Replaced $ call by jQuery
>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>>> all cases (228 thruDate cases)
>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>
>>>> There are other date couples like (estimatedStartDate,
>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>> but their values should not be enforced.
>>>> If ever someone wants to not let them free, then she just has to add
>>>> the couples in FromThruDateCheck.js
>>>>
>>>>
>>>>
>>>>
>>>> Added:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> (with props)
>>>> Modified:
>>>>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>
>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>>> 12:34:24 2014
>>>> @@ -4457,6 +4457,10 @@
>>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>       </property>
>>>> +    <property key="CommonFromDateThruDateCheck">
>>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>>> from date</value>
>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>> plus récente que la date de début</value>
>>>> +    </property>
>>>>       <property key="CommonFromDateTime">
>>>>           <value xml:lang="ar">تاريخ  و وقت البدء</value>
>>>>           <value xml:lang="cs">Od data a času</value>
>>>>
>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>> 12:34:24 2014
>>>> @@ -162,6 +162,7 @@ under the License.
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/util.js" global="true" />
>>>> +                <set field="layoutSettings.javaScripts[]"
>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>                   <set field="visualThemeId"
>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>                   <service service-name="getVisualThemeResources">
>>>>                       <field-map field-name="visualThemeId" />
>>>>
>>>> Added:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>
>>>> ==============================================================================
>>>>
>>>> ---
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> (added)
>>>> +++
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> Sun Jun  1 12:34:24 2014
>>>> @@ -0,0 +1,17 @@
>>>> +//this code needs modifications yet its specific.
>>>> +
>>>> +jQuery(document).ready( function() {
>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>> +});
>>>> +
>>>> +function checkDate() {
>>>> +  var a = jQuery("input[name*='fromDate']");
>>>> +  var b = jQuery("input[name*='thruDate']");
>>>> +
>>>> +  if(a.val() !="" && b.val() !="") {
>>>> +    if (a.val() >= b.val()) {
>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>> "CommonFromDateThruDateCheck")
>>>> +    }
>>>> +  }
>>>> +}
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------
>>>>
>>>>      svn:eol-style = native
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------
>>>>
>>>>      svn:keywords = Date Rev Author URL Id
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------
>>>>
>>>>      svn:mime-type = text/plain
>>>>
>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>
>>>> ==============================================================================
>>>>
>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>> 1 12:34:24 2014
>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>                   }
>>>>               }
>>>>           });
>>>> +    } else {
>>>> +      alert(labels[uiResource][0]);
>>>>       }
>>>>   }
>>>>
>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>               return true;
>>>>           }
>>>>       }
>>>> -}
>>>> \ No newline at end of file
>>>> +}
>>>>
>>>>
>>>
>>
>

-- 

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Adrian Crum <ad...@sandglass-software.com>.
Thanks Jacques!

For anyone else: Just because a word appears in a dictionary, it doesn't 
mean it should appear in enterprise software. For example:

http://dictionary.reference.com/browse/fuck?s=t

Spend some time in the Usage section. Just because a word appears in the 
dictionary, it doesn't mean we should include it in our software.

As a native English speaker, I am trying to say this: "Thru" is not an 
acceptable English translation of the word "Through", therefore it 
should not appear in our label files.

I don't argue about label translations in French or Dutch - because 
neither language is native to me. I expect the same respect from 
non-English speaking locales regarding my English translations.

To be more specific: I have had clients laugh at the usage of the word 
"Thru" - because it is silly.

Adrian Crum
Sandglass Software
www.sandglass-software.com

On 6/6/2014 12:25 AM, Jacques Le Roux wrote:
> I had the same reaction, but thru is not really academic and not much
> (if at all) British (though this is Collins, it's clearly mentioned at
> http://www.etymonline.com/index.php?term=through)
> So I did some changes at
> http://svn.apache.org/viewvc?view=revision&revision=r1599110
>
> Anyway, If we had only that to do...
>
> Jacques
>
> Le 06/06/2014 07:51, Hans Bakker a écrit :
>> have a look at: http://dictionary.reference.com/browse/thru
>>
>> regards,
>> Hans
>>
>> On 01/06/14 16:50, Adrian Crum wrote:
>>> I fixed the misspelled word a while ago. It would be nice if we
>>> stopped deliberately committing improper spellings.
>>>
>>> Adrian Crum
>>> Sandglass Software
>>> www.sandglass-software.com
>>>
>>> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>>>> Right, and you know I did not invent this "word".
>>>>
>>>> I simply reused "thru " here to keep the subject focused.
>>>>
>>>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>>>> maybe you do?
>>>>
>>>> Jacques
>>>>
>>>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>>>> "Thru" is not an English word. The correct spelling is "Through".
>>>>>
>>>>> Adrian Crum
>>>>> Sandglass Software
>>>>> www.sandglass-software.com
>>>>>
>>>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>>>> Author: jleroux
>>>>>> Date: Sun Jun  1 12:34:24 2014
>>>>>> New Revision: 1598977
>>>>>>
>>>>>> URL: http://svn.apache.org/r1598977
>>>>>> Log:
>>>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>>>> date is not same or older than the from date"
>>>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>>>
>>>>>> jleroux:
>>>>>> I reused Ankit's patch as a basis for this commit
>>>>>> I added an i18n label
>>>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>>>> generalising when no contentarea is present
>>>>>> Replaced $ call by jQuery
>>>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>>>>> all cases (228 thruDate cases)
>>>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>>>
>>>>>> There are other date couples like (estimatedStartDate,
>>>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>>>> but their values should not be enforced.
>>>>>> If ever someone wants to not let them free, then she just has to add
>>>>>> the couples in FromThruDateCheck.js
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Added:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> (with props)
>>>>>> Modified:
>>>>>> ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>> ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>
>>>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>
>>>>>>
>>>>>> ==============================================================================
>>>>>>
>>>>>>
>>>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>>>>> 12:34:24 2014
>>>>>> @@ -4457,6 +4457,10 @@
>>>>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>>>       </property>
>>>>>> +    <property key="CommonFromDateThruDateCheck">
>>>>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>>>>> from date</value>
>>>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>>>> plus récente que la date de début</value>
>>>>>> +    </property>
>>>>>>       <property key="CommonFromDateTime">
>>>>>>           <value xml:lang="ar">تاريخ  و وقت
>>>>>> البدء</value>
>>>>>>           <value xml:lang="cs">Od data a času</value>
>>>>>>
>>>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>
>>>>>>
>>>>>> ==============================================================================
>>>>>>
>>>>>>
>>>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>>>> 12:34:24 2014
>>>>>> @@ -162,6 +162,7 @@ under the License.
>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/util.js" global="true" />
>>>>>> +                <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>>>                   <set field="visualThemeId"
>>>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>>>                   <service service-name="getVisualThemeResources">
>>>>>>                       <field-map field-name="visualThemeId" />
>>>>>>
>>>>>> Added:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>>>
>>>>>>
>>>>>> ==============================================================================
>>>>>>
>>>>>>
>>>>>> ---
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> (added)
>>>>>> +++
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> Sun Jun  1 12:34:24 2014
>>>>>> @@ -0,0 +1,17 @@
>>>>>> +//this code needs modifications yet its specific.
>>>>>> +
>>>>>> +jQuery(document).ready( function() {
>>>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>>>> +});
>>>>>> +
>>>>>> +function checkDate() {
>>>>>> +  var a = jQuery("input[name*='fromDate']");
>>>>>> +  var b = jQuery("input[name*='thruDate']");
>>>>>> +
>>>>>> +  if(a.val() !="" && b.val() !="") {
>>>>>> +    if (a.val() >= b.val()) {
>>>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>>>> "CommonFromDateThruDateCheck")
>>>>>> +    }
>>>>>> +  }
>>>>>> +}
>>>>>>
>>>>>> Propchange:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> ------------------------------------------------------------------------------
>>>>>>
>>>>>>
>>>>>>      svn:eol-style = native
>>>>>>
>>>>>> Propchange:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> ------------------------------------------------------------------------------
>>>>>>
>>>>>>
>>>>>>      svn:keywords = Date Rev Author URL Id
>>>>>>
>>>>>> Propchange:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> ------------------------------------------------------------------------------
>>>>>>
>>>>>>
>>>>>>      svn:mime-type = text/plain
>>>>>>
>>>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>
>>>>>>
>>>>>> ==============================================================================
>>>>>>
>>>>>>
>>>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>> (original)
>>>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>>>> 1 12:34:24 2014
>>>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>>>                   }
>>>>>>               }
>>>>>>           });
>>>>>> +    } else {
>>>>>> +      alert(labels[uiResource][0]);
>>>>>>       }
>>>>>>   }
>>>>>>
>>>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>>>               return true;
>>>>>>           }
>>>>>>       }
>>>>>> -}
>>>>>> \ No newline at end of file
>>>>>> +}
>>>>>>
>>>>>>
>>>>>
>>>>
>>
>>
>

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Jacques Le Roux <ja...@les7arts.com>.
I had the same reaction, but thru is not really academic and not much (if at all) British (though this is Collins, it's clearly mentioned at 
http://www.etymonline.com/index.php?term=through)
So I did some changes at http://svn.apache.org/viewvc?view=revision&revision=r1599110

Anyway, If we had only that to do...

Jacques

Le 06/06/2014 07:51, Hans Bakker a écrit :
> have a look at: http://dictionary.reference.com/browse/thru
>
> regards,
> Hans
>
> On 01/06/14 16:50, Adrian Crum wrote:
>> I fixed the misspelled word a while ago. It would be nice if we stopped deliberately committing improper spellings.
>>
>> Adrian Crum
>> Sandglass Software
>> www.sandglass-software.com
>>
>> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>>> Right, and you know I did not invent this "word".
>>>
>>> I simply reused "thru " here to keep the subject focused.
>>>
>>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>>> maybe you do?
>>>
>>> Jacques
>>>
>>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>>> "Thru" is not an English word. The correct spelling is "Through".
>>>>
>>>> Adrian Crum
>>>> Sandglass Software
>>>> www.sandglass-software.com
>>>>
>>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>>> Author: jleroux
>>>>> Date: Sun Jun  1 12:34:24 2014
>>>>> New Revision: 1598977
>>>>>
>>>>> URL: http://svn.apache.org/r1598977
>>>>> Log:
>>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>>> date is not same or older than the from date"
>>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>>
>>>>> jleroux:
>>>>> I reused Ankit's patch as a basis for this commit
>>>>> I added an i18n label
>>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>>> generalising when no contentarea is present
>>>>> Replaced $ call by jQuery
>>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>>>> all cases (228 thruDate cases)
>>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>>
>>>>> There are other date couples like (estimatedStartDate,
>>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>>> but their values should not be enforced.
>>>>> If ever someone wants to not let them free, then she just has to add
>>>>> the couples in FromThruDateCheck.js
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> Added:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> (with props)
>>>>> Modified:
>>>>> ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>> ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>
>>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>>>> 12:34:24 2014
>>>>> @@ -4457,6 +4457,10 @@
>>>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>>       </property>
>>>>> +    <property key="CommonFromDateThruDateCheck">
>>>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>>>> from date</value>
>>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>>> plus récente que la date de début</value>
>>>>> +    </property>
>>>>>       <property key="CommonFromDateTime">
>>>>>           <value xml:lang="ar">تاريخ  و وقت البدء</value>
>>>>>           <value xml:lang="cs">Od data a času</value>
>>>>>
>>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>>> 12:34:24 2014
>>>>> @@ -162,6 +162,7 @@ under the License.
>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/util.js" global="true" />
>>>>> +                <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>>                   <set field="visualThemeId"
>>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>>                   <service service-name="getVisualThemeResources">
>>>>>                       <field-map field-name="visualThemeId" />
>>>>>
>>>>> Added:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>> ---
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> (added)
>>>>> +++
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> Sun Jun  1 12:34:24 2014
>>>>> @@ -0,0 +1,17 @@
>>>>> +//this code needs modifications yet its specific.
>>>>> +
>>>>> +jQuery(document).ready( function() {
>>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>>> +});
>>>>> +
>>>>> +function checkDate() {
>>>>> +  var a = jQuery("input[name*='fromDate']");
>>>>> +  var b = jQuery("input[name*='thruDate']");
>>>>> +
>>>>> +  if(a.val() !="" && b.val() !="") {
>>>>> +    if (a.val() >= b.val()) {
>>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>>> "CommonFromDateThruDateCheck")
>>>>> +    }
>>>>> +  }
>>>>> +}
>>>>>
>>>>> Propchange:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> ------------------------------------------------------------------------------
>>>>>
>>>>>      svn:eol-style = native
>>>>>
>>>>> Propchange:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> ------------------------------------------------------------------------------
>>>>>
>>>>>      svn:keywords = Date Rev Author URL Id
>>>>>
>>>>> Propchange:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> ------------------------------------------------------------------------------
>>>>>
>>>>>      svn:mime-type = text/plain
>>>>>
>>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>>> 1 12:34:24 2014
>>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>>                   }
>>>>>               }
>>>>>           });
>>>>> +    } else {
>>>>> +      alert(labels[uiResource][0]);
>>>>>       }
>>>>>   }
>>>>>
>>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>>               return true;
>>>>>           }
>>>>>       }
>>>>> -}
>>>>> \ No newline at end of file
>>>>> +}
>>>>>
>>>>>
>>>>
>>>
>
>

-- 

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Jacques Le Roux <ja...@les7arts.com>.
Sounds like you know some slang I don't :D

Jacques

Le 06/06/2014 10:09, Adrian Crum a écrit :
> Hans,
>
> You are Dutch. I am an American. I understand English better than you. My clients laugh when they see the word "Thru".
>
> So,
>
> http://www.urbandictionary.com/define.php?term=back%20the%20fuck%20up
>
> http://www.urbandictionary.com/define.php?term=Pull+your+head+out+of+your+ass
>
> and learn ENGLISH.
>
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
>
> On 6/6/2014 12:51 AM, Hans Bakker wrote:
>> is it so difficult for you to admit that you are wrong?
>> didn't you started this discussion?
>>
>> On 06/06/14 08:12, Adrian Crum wrote:
>>> Seriously? Are we arguing against correct spelling?
>>>
>>> Why not replace all "Hello" labels with "Yo! What's up?"
>>>
>>>
>>> Adrian Crum
>>> Sandglass Software
>>> www.sandglass-software.com
>>>
>>> On 6/5/2014 10:51 PM, Hans Bakker wrote:
>>>> have a look at: http://dictionary.reference.com/browse/thru
>>>>
>>>> regards,
>>>> Hans
>>>>
>>>> On 01/06/14 16:50, Adrian Crum wrote:
>>>>> I fixed the misspelled word a while ago. It would be nice if we
>>>>> stopped deliberately committing improper spellings.
>>>>>
>>>>> Adrian Crum
>>>>> Sandglass Software
>>>>> www.sandglass-software.com
>>>>>
>>>>> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>>>>>> Right, and you know I did not invent this "word".
>>>>>>
>>>>>> I simply reused "thru " here to keep the subject focused.
>>>>>>
>>>>>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>>>>>> maybe you do?
>>>>>>
>>>>>> Jacques
>>>>>>
>>>>>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>>>>>> "Thru" is not an English word. The correct spelling is "Through".
>>>>>>>
>>>>>>> Adrian Crum
>>>>>>> Sandglass Software
>>>>>>> www.sandglass-software.com
>>>>>>>
>>>>>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>>>>>> Author: jleroux
>>>>>>>> Date: Sun Jun  1 12:34:24 2014
>>>>>>>> New Revision: 1598977
>>>>>>>>
>>>>>>>> URL: http://svn.apache.org/r1598977
>>>>>>>> Log:
>>>>>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>>>>>> date is not same or older than the from date"
>>>>>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>>>>>
>>>>>>>> jleroux:
>>>>>>>> I reused Ankit's patch as a basis for this commit
>>>>>>>> I added an i18n label
>>>>>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>>>>>> generalising when no contentarea is present
>>>>>>>> Replaced $ call by jQuery
>>>>>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to
>>>>>>>> get
>>>>>>>> all cases (228 thruDate cases)
>>>>>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>>>>>
>>>>>>>> There are other date couples like (estimatedStartDate,
>>>>>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>>>>>> but their values should not be enforced.
>>>>>>>> If ever someone wants to not let them free, then she just has to add
>>>>>>>> the couples in FromThruDateCheck.js
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Added:
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> (with props)
>>>>>>>> Modified:
>>>>>>>> ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>>> ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>>>
>>>>>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>>> URL:
>>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ==============================================================================
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>>> (original)
>>>>>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun
>>>>>>>> Jun  1
>>>>>>>> 12:34:24 2014
>>>>>>>> @@ -4457,6 +4457,10 @@
>>>>>>>>           <value xml:lang="zh-CN">起始日期 /
>>>>>>>> 终止日期</value>
>>>>>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>>>>>       </property>
>>>>>>>> +    <property key="CommonFromDateThruDateCheck">
>>>>>>>> +        <value xml:lang="en">Thru date can't be same or smaller
>>>>>>>> than
>>>>>>>> from date</value>
>>>>>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>>>>>> plus récente que la date de début</value>
>>>>>>>> +    </property>
>>>>>>>>       <property key="CommonFromDateTime">
>>>>>>>>           <value xml:lang="ar">تاريخ  و وقت
>>>>>>>> البدء</value>
>>>>>>>>           <value xml:lang="cs">Od data a času</value>
>>>>>>>>
>>>>>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>>>> URL:
>>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ==============================================================================
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>>>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>>>>>> 12:34:24 2014
>>>>>>>> @@ -162,6 +162,7 @@ under the License.
>>>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>>>> value="/images/util.js" global="true" />
>>>>>>>> +                <set field="layoutSettings.javaScripts[]"
>>>>>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>>>>>                   <set field="visualThemeId"
>>>>>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>>>>>                   <service service-name="getVisualThemeResources">
>>>>>>>>                       <field-map field-name="visualThemeId" />
>>>>>>>>
>>>>>>>> Added:
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> URL:
>>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ==============================================================================
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ---
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> (added)
>>>>>>>> +++
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> Sun Jun  1 12:34:24 2014
>>>>>>>> @@ -0,0 +1,17 @@
>>>>>>>> +//this code needs modifications yet its specific.
>>>>>>>> +
>>>>>>>> +jQuery(document).ready( function() {
>>>>>>>> + jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>>>>>> + jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>>>>>> +});
>>>>>>>> +
>>>>>>>> +function checkDate() {
>>>>>>>> +  var a = jQuery("input[name*='fromDate']");
>>>>>>>> +  var b = jQuery("input[name*='thruDate']");
>>>>>>>> +
>>>>>>>> +  if(a.val() !="" && b.val() !="") {
>>>>>>>> +    if (a.val() >= b.val()) {
>>>>>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>>>>>> "CommonFromDateThruDateCheck")
>>>>>>>> +    }
>>>>>>>> +  }
>>>>>>>> +}
>>>>>>>>
>>>>>>>> Propchange:
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>      svn:eol-style = native
>>>>>>>>
>>>>>>>> Propchange:
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>      svn:keywords = Date Rev Author URL Id
>>>>>>>>
>>>>>>>> Propchange:
>>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>      svn:mime-type = text/plain
>>>>>>>>
>>>>>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>>> URL:
>>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> ==============================================================================
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>>> (original)
>>>>>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>>>>>> 1 12:34:24 2014
>>>>>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>>>>>                   }
>>>>>>>>               }
>>>>>>>>           });
>>>>>>>> +    } else {
>>>>>>>> +      alert(labels[uiResource][0]);
>>>>>>>>       }
>>>>>>>>   }
>>>>>>>>
>>>>>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>>>>>               return true;
>>>>>>>>           }
>>>>>>>>       }
>>>>>>>> -}
>>>>>>>> \ No newline at end of file
>>>>>>>> +}
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>
>>>>
>>
>

-- 

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Adrian Crum <ad...@sandglass-software.com>.
Hans,

You are Dutch. I am an American. I understand English better than you. 
My clients laugh when they see the word "Thru".

So,

http://www.urbandictionary.com/define.php?term=back%20the%20fuck%20up

http://www.urbandictionary.com/define.php?term=Pull+your+head+out+of+your+ass

and learn ENGLISH.

Adrian Crum
Sandglass Software
www.sandglass-software.com

On 6/6/2014 12:51 AM, Hans Bakker wrote:
> is it so difficult for you to admit that you are wrong?
> didn't you started this discussion?
>
> On 06/06/14 08:12, Adrian Crum wrote:
>> Seriously? Are we arguing against correct spelling?
>>
>> Why not replace all "Hello" labels with "Yo! What's up?"
>>
>>
>> Adrian Crum
>> Sandglass Software
>> www.sandglass-software.com
>>
>> On 6/5/2014 10:51 PM, Hans Bakker wrote:
>>> have a look at: http://dictionary.reference.com/browse/thru
>>>
>>> regards,
>>> Hans
>>>
>>> On 01/06/14 16:50, Adrian Crum wrote:
>>>> I fixed the misspelled word a while ago. It would be nice if we
>>>> stopped deliberately committing improper spellings.
>>>>
>>>> Adrian Crum
>>>> Sandglass Software
>>>> www.sandglass-software.com
>>>>
>>>> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>>>>> Right, and you know I did not invent this "word".
>>>>>
>>>>> I simply reused "thru " here to keep the subject focused.
>>>>>
>>>>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>>>>> maybe you do?
>>>>>
>>>>> Jacques
>>>>>
>>>>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>>>>> "Thru" is not an English word. The correct spelling is "Through".
>>>>>>
>>>>>> Adrian Crum
>>>>>> Sandglass Software
>>>>>> www.sandglass-software.com
>>>>>>
>>>>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>>>>> Author: jleroux
>>>>>>> Date: Sun Jun  1 12:34:24 2014
>>>>>>> New Revision: 1598977
>>>>>>>
>>>>>>> URL: http://svn.apache.org/r1598977
>>>>>>> Log:
>>>>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>>>>> date is not same or older than the from date"
>>>>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>>>>
>>>>>>> jleroux:
>>>>>>> I reused Ankit's patch as a basis for this commit
>>>>>>> I added an i18n label
>>>>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>>>>> generalising when no contentarea is present
>>>>>>> Replaced $ call by jQuery
>>>>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to
>>>>>>> get
>>>>>>> all cases (228 thruDate cases)
>>>>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>>>>
>>>>>>> There are other date couples like (estimatedStartDate,
>>>>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>>>>> but their values should not be enforced.
>>>>>>> If ever someone wants to not let them free, then she just has to add
>>>>>>> the couples in FromThruDateCheck.js
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Added:
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> (with props)
>>>>>>> Modified:
>>>>>>> ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>> ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>>> ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>>
>>>>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>> URL:
>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ==============================================================================
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>>> (original)
>>>>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun
>>>>>>> Jun  1
>>>>>>> 12:34:24 2014
>>>>>>> @@ -4457,6 +4457,10 @@
>>>>>>>           <value xml:lang="zh-CN">起始日期 /
>>>>>>> 终止日期</value>
>>>>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>>>>       </property>
>>>>>>> +    <property key="CommonFromDateThruDateCheck">
>>>>>>> +        <value xml:lang="en">Thru date can't be same or smaller
>>>>>>> than
>>>>>>> from date</value>
>>>>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>>>>> plus récente que la date de début</value>
>>>>>>> +    </property>
>>>>>>>       <property key="CommonFromDateTime">
>>>>>>>           <value xml:lang="ar">تاريخ  و وقت
>>>>>>> البدء</value>
>>>>>>>           <value xml:lang="cs">Od data a času</value>
>>>>>>>
>>>>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>>> URL:
>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ==============================================================================
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>>>>> 12:34:24 2014
>>>>>>> @@ -162,6 +162,7 @@ under the License.
>>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>>> value="/images/util.js" global="true" />
>>>>>>> +                <set field="layoutSettings.javaScripts[]"
>>>>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>>>>                   <set field="visualThemeId"
>>>>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>>>>                   <service service-name="getVisualThemeResources">
>>>>>>>                       <field-map field-name="visualThemeId" />
>>>>>>>
>>>>>>> Added:
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> URL:
>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ==============================================================================
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ---
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> (added)
>>>>>>> +++
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> Sun Jun  1 12:34:24 2014
>>>>>>> @@ -0,0 +1,17 @@
>>>>>>> +//this code needs modifications yet its specific.
>>>>>>> +
>>>>>>> +jQuery(document).ready( function() {
>>>>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>>>>> +});
>>>>>>> +
>>>>>>> +function checkDate() {
>>>>>>> +  var a = jQuery("input[name*='fromDate']");
>>>>>>> +  var b = jQuery("input[name*='thruDate']");
>>>>>>> +
>>>>>>> +  if(a.val() !="" && b.val() !="") {
>>>>>>> +    if (a.val() >= b.val()) {
>>>>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>>>>> "CommonFromDateThruDateCheck")
>>>>>>> +    }
>>>>>>> +  }
>>>>>>> +}
>>>>>>>
>>>>>>> Propchange:
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> ------------------------------------------------------------------------------
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      svn:eol-style = native
>>>>>>>
>>>>>>> Propchange:
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> ------------------------------------------------------------------------------
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      svn:keywords = Date Rev Author URL Id
>>>>>>>
>>>>>>> Propchange:
>>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>>> ------------------------------------------------------------------------------
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>      svn:mime-type = text/plain
>>>>>>>
>>>>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>> URL:
>>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ==============================================================================
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>> (original)
>>>>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>>>>> 1 12:34:24 2014
>>>>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>>>>                   }
>>>>>>>               }
>>>>>>>           });
>>>>>>> +    } else {
>>>>>>> +      alert(labels[uiResource][0]);
>>>>>>>       }
>>>>>>>   }
>>>>>>>
>>>>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>>>>               return true;
>>>>>>>           }
>>>>>>>       }
>>>>>>> -}
>>>>>>> \ No newline at end of file
>>>>>>> +}
>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>
>

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Hans Bakker <ma...@antwebsystems.com>.
is it so difficult for you to admit that you are wrong?
didn't you started this discussion?

On 06/06/14 08:12, Adrian Crum wrote:
> Seriously? Are we arguing against correct spelling?
>
> Why not replace all "Hello" labels with "Yo! What's up?"
>
>
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
>
> On 6/5/2014 10:51 PM, Hans Bakker wrote:
>> have a look at: http://dictionary.reference.com/browse/thru
>>
>> regards,
>> Hans
>>
>> On 01/06/14 16:50, Adrian Crum wrote:
>>> I fixed the misspelled word a while ago. It would be nice if we
>>> stopped deliberately committing improper spellings.
>>>
>>> Adrian Crum
>>> Sandglass Software
>>> www.sandglass-software.com
>>>
>>> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>>>> Right, and you know I did not invent this "word".
>>>>
>>>> I simply reused "thru " here to keep the subject focused.
>>>>
>>>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>>>> maybe you do?
>>>>
>>>> Jacques
>>>>
>>>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>>>> "Thru" is not an English word. The correct spelling is "Through".
>>>>>
>>>>> Adrian Crum
>>>>> Sandglass Software
>>>>> www.sandglass-software.com
>>>>>
>>>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>>>> Author: jleroux
>>>>>> Date: Sun Jun  1 12:34:24 2014
>>>>>> New Revision: 1598977
>>>>>>
>>>>>> URL: http://svn.apache.org/r1598977
>>>>>> Log:
>>>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>>>> date is not same or older than the from date"
>>>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>>>
>>>>>> jleroux:
>>>>>> I reused Ankit's patch as a basis for this commit
>>>>>> I added an i18n label
>>>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>>>> generalising when no contentarea is present
>>>>>> Replaced $ call by jQuery
>>>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to 
>>>>>> get
>>>>>> all cases (228 thruDate cases)
>>>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>>>
>>>>>> There are other date couples like (estimatedStartDate,
>>>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>>>> but their values should not be enforced.
>>>>>> If ever someone wants to not let them free, then she just has to add
>>>>>> the couples in FromThruDateCheck.js
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Added:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> (with props)
>>>>>> Modified:
>>>>>> ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>> ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>> ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>>
>>>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff 
>>>>>>
>>>>>>
>>>>>>
>>>>>> ============================================================================== 
>>>>>>
>>>>>>
>>>>>>
>>>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml 
>>>>>> (original)
>>>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun 
>>>>>> Jun  1
>>>>>> 12:34:24 2014
>>>>>> @@ -4457,6 +4457,10 @@
>>>>>>           <value xml:lang="zh-CN">起始日期 / 
>>>>>> 终止日期</value>
>>>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>>>       </property>
>>>>>> +    <property key="CommonFromDateThruDateCheck">
>>>>>> +        <value xml:lang="en">Thru date can't be same or smaller 
>>>>>> than
>>>>>> from date</value>
>>>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>>>> plus récente que la date de début</value>
>>>>>> +    </property>
>>>>>>       <property key="CommonFromDateTime">
>>>>>>           <value xml:lang="ar">تاريخ  و وقت
>>>>>> البدء</value>
>>>>>>           <value xml:lang="cs">Od data a času</value>
>>>>>>
>>>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff 
>>>>>>
>>>>>>
>>>>>>
>>>>>> ============================================================================== 
>>>>>>
>>>>>>
>>>>>>
>>>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>>>> 12:34:24 2014
>>>>>> @@ -162,6 +162,7 @@ under the License.
>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/util.js" global="true" />
>>>>>> +                <set field="layoutSettings.javaScripts[]"
>>>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>>>                   <set field="visualThemeId"
>>>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>>>                   <service service-name="getVisualThemeResources">
>>>>>>                       <field-map field-name="visualThemeId" />
>>>>>>
>>>>>> Added:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto 
>>>>>>
>>>>>>
>>>>>>
>>>>>> ============================================================================== 
>>>>>>
>>>>>>
>>>>>>
>>>>>> ---
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> (added)
>>>>>> +++
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> Sun Jun  1 12:34:24 2014
>>>>>> @@ -0,0 +1,17 @@
>>>>>> +//this code needs modifications yet its specific.
>>>>>> +
>>>>>> +jQuery(document).ready( function() {
>>>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>>>> +});
>>>>>> +
>>>>>> +function checkDate() {
>>>>>> +  var a = jQuery("input[name*='fromDate']");
>>>>>> +  var b = jQuery("input[name*='thruDate']");
>>>>>> +
>>>>>> +  if(a.val() !="" && b.val() !="") {
>>>>>> +    if (a.val() >= b.val()) {
>>>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>>>> "CommonFromDateThruDateCheck")
>>>>>> +    }
>>>>>> +  }
>>>>>> +}
>>>>>>
>>>>>> Propchange:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> ------------------------------------------------------------------------------ 
>>>>>>
>>>>>>
>>>>>>
>>>>>>      svn:eol-style = native
>>>>>>
>>>>>> Propchange:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> ------------------------------------------------------------------------------ 
>>>>>>
>>>>>>
>>>>>>
>>>>>>      svn:keywords = Date Rev Author URL Id
>>>>>>
>>>>>> Propchange:
>>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>>> ------------------------------------------------------------------------------ 
>>>>>>
>>>>>>
>>>>>>
>>>>>>      svn:mime-type = text/plain
>>>>>>
>>>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>> URL:
>>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff 
>>>>>>
>>>>>>
>>>>>>
>>>>>> ============================================================================== 
>>>>>>
>>>>>>
>>>>>>
>>>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js 
>>>>>> (original)
>>>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>>>> 1 12:34:24 2014
>>>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>>>                   }
>>>>>>               }
>>>>>>           });
>>>>>> +    } else {
>>>>>> +      alert(labels[uiResource][0]);
>>>>>>       }
>>>>>>   }
>>>>>>
>>>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>>>               return true;
>>>>>>           }
>>>>>>       }
>>>>>> -}
>>>>>> \ No newline at end of file
>>>>>> +}
>>>>>>
>>>>>>
>>>>>
>>>>
>>


Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Adrian Crum <ad...@sandglass-software.com>.
Seriously? Are we arguing against correct spelling?

Why not replace all "Hello" labels with "Yo! What's up?"


Adrian Crum
Sandglass Software
www.sandglass-software.com

On 6/5/2014 10:51 PM, Hans Bakker wrote:
> have a look at: http://dictionary.reference.com/browse/thru
>
> regards,
> Hans
>
> On 01/06/14 16:50, Adrian Crum wrote:
>> I fixed the misspelled word a while ago. It would be nice if we
>> stopped deliberately committing improper spellings.
>>
>> Adrian Crum
>> Sandglass Software
>> www.sandglass-software.com
>>
>> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>>> Right, and you know I did not invent this "word".
>>>
>>> I simply reused "thru " here to keep the subject focused.
>>>
>>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>>> maybe you do?
>>>
>>> Jacques
>>>
>>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>>> "Thru" is not an English word. The correct spelling is "Through".
>>>>
>>>> Adrian Crum
>>>> Sandglass Software
>>>> www.sandglass-software.com
>>>>
>>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>>> Author: jleroux
>>>>> Date: Sun Jun  1 12:34:24 2014
>>>>> New Revision: 1598977
>>>>>
>>>>> URL: http://svn.apache.org/r1598977
>>>>> Log:
>>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>>> date is not same or older than the from date"
>>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>>
>>>>> jleroux:
>>>>> I reused Ankit's patch as a basis for this commit
>>>>> I added an i18n label
>>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>>> generalising when no contentarea is present
>>>>> Replaced $ call by jQuery
>>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>>>> all cases (228 thruDate cases)
>>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>>
>>>>> There are other date couples like (estimatedStartDate,
>>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>>> but their values should not be enforced.
>>>>> If ever someone wants to not let them free, then she just has to add
>>>>> the couples in FromThruDateCheck.js
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> Added:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> (with props)
>>>>> Modified:
>>>>>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>>
>>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>>
>>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>>>> 12:34:24 2014
>>>>> @@ -4457,6 +4457,10 @@
>>>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>>       </property>
>>>>> +    <property key="CommonFromDateThruDateCheck">
>>>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>>>> from date</value>
>>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>>> plus récente que la date de début</value>
>>>>> +    </property>
>>>>>       <property key="CommonFromDateTime">
>>>>>           <value xml:lang="ar">تاريخ  و وقت
>>>>> البدء</value>
>>>>>           <value xml:lang="cs">Od data a času</value>
>>>>>
>>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>>
>>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>>> 12:34:24 2014
>>>>> @@ -162,6 +162,7 @@ under the License.
>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>>                   <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/util.js" global="true" />
>>>>> +                <set field="layoutSettings.javaScripts[]"
>>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>>                   <set field="visualThemeId"
>>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>>                   <service service-name="getVisualThemeResources">
>>>>>                       <field-map field-name="visualThemeId" />
>>>>>
>>>>> Added:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>>>
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>>
>>>>> ---
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> (added)
>>>>> +++
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> Sun Jun  1 12:34:24 2014
>>>>> @@ -0,0 +1,17 @@
>>>>> +//this code needs modifications yet its specific.
>>>>> +
>>>>> +jQuery(document).ready( function() {
>>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>>> +});
>>>>> +
>>>>> +function checkDate() {
>>>>> +  var a = jQuery("input[name*='fromDate']");
>>>>> +  var b = jQuery("input[name*='thruDate']");
>>>>> +
>>>>> +  if(a.val() !="" && b.val() !="") {
>>>>> +    if (a.val() >= b.val()) {
>>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>>> "CommonFromDateThruDateCheck")
>>>>> +    }
>>>>> +  }
>>>>> +}
>>>>>
>>>>> Propchange:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> ------------------------------------------------------------------------------
>>>>>
>>>>>
>>>>>      svn:eol-style = native
>>>>>
>>>>> Propchange:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> ------------------------------------------------------------------------------
>>>>>
>>>>>
>>>>>      svn:keywords = Date Rev Author URL Id
>>>>>
>>>>> Propchange:
>>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>>> ------------------------------------------------------------------------------
>>>>>
>>>>>
>>>>>      svn:mime-type = text/plain
>>>>>
>>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>> URL:
>>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>>>
>>>>>
>>>>> ==============================================================================
>>>>>
>>>>>
>>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>>> 1 12:34:24 2014
>>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>>                   }
>>>>>               }
>>>>>           });
>>>>> +    } else {
>>>>> +      alert(labels[uiResource][0]);
>>>>>       }
>>>>>   }
>>>>>
>>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>>               return true;
>>>>>           }
>>>>>       }
>>>>> -}
>>>>> \ No newline at end of file
>>>>> +}
>>>>>
>>>>>
>>>>
>>>
>

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Hans Bakker <ma...@antwebsystems.com>.
have a look at: http://dictionary.reference.com/browse/thru

regards,
Hans

On 01/06/14 16:50, Adrian Crum wrote:
> I fixed the misspelled word a while ago. It would be nice if we 
> stopped deliberately committing improper spellings.
>
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
>
> On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
>> Right, and you know I did not invent this "word".
>>
>> I simply reused "thru " here to keep the subject focused.
>>
>> I don't clearly remember David's (Or Andy's?) explanation behind it,
>> maybe you do?
>>
>> Jacques
>>
>> Le 01/06/2014 17:22, Adrian Crum a écrit :
>>> "Thru" is not an English word. The correct spelling is "Through".
>>>
>>> Adrian Crum
>>> Sandglass Software
>>> www.sandglass-software.com
>>>
>>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>>> Author: jleroux
>>>> Date: Sun Jun  1 12:34:24 2014
>>>> New Revision: 1598977
>>>>
>>>> URL: http://svn.apache.org/r1598977
>>>> Log:
>>>> A modified patch from Ankit Jain for "We should check that the thru
>>>> date is not same or older than the from date"
>>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>>
>>>> jleroux:
>>>> I reused Ankit's patch as a basis for this commit
>>>> I added an i18n label
>>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>>> generalising when no contentarea is present
>>>> Replaced $ call by jQuery
>>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>>> all cases (228 thruDate cases)
>>>> Still used only an alert, so it's only a warning, nothing coercive
>>>>
>>>> There are other date couples like (estimatedStartDate,
>>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>>> but their values should not be enforced.
>>>> If ever someone wants to not let them free, then she just has to add
>>>> the couples in FromThruDateCheck.js
>>>>
>>>>
>>>>
>>>>
>>>> Added:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> (with props)
>>>> Modified:
>>>>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>>
>>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff 
>>>>
>>>>
>>>> ============================================================================== 
>>>>
>>>>
>>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>>> 12:34:24 2014
>>>> @@ -4457,6 +4457,10 @@
>>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>>       </property>
>>>> +    <property key="CommonFromDateThruDateCheck">
>>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>>> from date</value>
>>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>>> plus récente que la date de début</value>
>>>> +    </property>
>>>>       <property key="CommonFromDateTime">
>>>>           <value xml:lang="ar">تاريخ  و وقت 
>>>> البدء</value>
>>>>           <value xml:lang="cs">Od data a času</value>
>>>>
>>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff 
>>>>
>>>>
>>>> ============================================================================== 
>>>>
>>>>
>>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>>> 12:34:24 2014
>>>> @@ -162,6 +162,7 @@ under the License.
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>>                   <set field="layoutSettings.javaScripts[]"
>>>> value="/images/util.js" global="true" />
>>>> +                <set field="layoutSettings.javaScripts[]"
>>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>>                   <set field="visualThemeId"
>>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>>                   <service service-name="getVisualThemeResources">
>>>>                       <field-map field-name="visualThemeId" />
>>>>
>>>> Added:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto 
>>>>
>>>>
>>>> ============================================================================== 
>>>>
>>>>
>>>> ---
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> (added)
>>>> +++
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> Sun Jun  1 12:34:24 2014
>>>> @@ -0,0 +1,17 @@
>>>> +//this code needs modifications yet its specific.
>>>> +
>>>> +jQuery(document).ready( function() {
>>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>>> +});
>>>> +
>>>> +function checkDate() {
>>>> +  var a = jQuery("input[name*='fromDate']");
>>>> +  var b = jQuery("input[name*='thruDate']");
>>>> +
>>>> +  if(a.val() !="" && b.val() !="") {
>>>> +    if (a.val() >= b.val()) {
>>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>>> "CommonFromDateThruDateCheck")
>>>> +    }
>>>> +  }
>>>> +}
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------ 
>>>>
>>>>
>>>>      svn:eol-style = native
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------ 
>>>>
>>>>
>>>>      svn:keywords = Date Rev Author URL Id
>>>>
>>>> Propchange:
>>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>>> ------------------------------------------------------------------------------ 
>>>>
>>>>
>>>>      svn:mime-type = text/plain
>>>>
>>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>> URL:
>>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff 
>>>>
>>>>
>>>> ============================================================================== 
>>>>
>>>>
>>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>>> 1 12:34:24 2014
>>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>>                   }
>>>>               }
>>>>           });
>>>> +    } else {
>>>> +      alert(labels[uiResource][0]);
>>>>       }
>>>>   }
>>>>
>>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>>               return true;
>>>>           }
>>>>       }
>>>> -}
>>>> \ No newline at end of file
>>>> +}
>>>>
>>>>
>>>
>>


Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Adrian Crum <ad...@sandglass-software.com>.
I fixed the misspelled word a while ago. It would be nice if we stopped 
deliberately committing improper spellings.

Adrian Crum
Sandglass Software
www.sandglass-software.com

On 6/1/2014 8:40 AM, Jacques Le Roux wrote:
> Right, and you know I did not invent this "word".
>
> I simply reused "thru " here to keep the subject focused.
>
> I don't clearly remember David's (Or Andy's?) explanation behind it,
> maybe you do?
>
> Jacques
>
> Le 01/06/2014 17:22, Adrian Crum a écrit :
>> "Thru" is not an English word. The correct spelling is "Through".
>>
>> Adrian Crum
>> Sandglass Software
>> www.sandglass-software.com
>>
>> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>>> Author: jleroux
>>> Date: Sun Jun  1 12:34:24 2014
>>> New Revision: 1598977
>>>
>>> URL: http://svn.apache.org/r1598977
>>> Log:
>>> A modified patch from Ankit Jain for "We should check that the thru
>>> date is not same or older than the from date"
>>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>>
>>> jleroux:
>>> I reused Ankit's patch as a basis for this commit
>>> I added an i18n label
>>> Added a way to use alert() in showErrorAlertLoadUiLabel for
>>> generalising when no contentarea is present
>>> Replaced $ call by jQuery
>>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get
>>> all cases (228 thruDate cases)
>>> Still used only an alert, so it's only a warning, nothing coercive
>>>
>>> There are other date couples like (estimatedStartDate,
>>> estimatedCompletionDate) and (actualStartDate, actualCompletionDate)
>>> but their values should not be enforced.
>>> If ever someone wants to not let them free, then she just has to add
>>> the couples in FromThruDateCheck.js
>>>
>>>
>>>
>>>
>>> Added:
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> (with props)
>>> Modified:
>>>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>>>
>>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>> URL:
>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>
>>> ==============================================================================
>>>
>>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1
>>> 12:34:24 2014
>>> @@ -4457,6 +4457,10 @@
>>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>>       </property>
>>> +    <property key="CommonFromDateThruDateCheck">
>>> +        <value xml:lang="en">Thru date can't be same or smaller than
>>> from date</value>
>>> +        <value xml:lang="fr">La date de fin ne peut être égale ou
>>> plus récente que la date de début</value>
>>> +    </property>
>>>       <property key="CommonFromDateTime">
>>>           <value xml:lang="ar">تاريخ  و وقت البدء</value>
>>>           <value xml:lang="cs">Od data a času</value>
>>>
>>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>> URL:
>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>
>>> ==============================================================================
>>>
>>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1
>>> 12:34:24 2014
>>> @@ -162,6 +162,7 @@ under the License.
>>>                   <set field="layoutSettings.javaScripts[]"
>>> value="/images/miscAjaxFunctions.js" global="true" />
>>>                   <set field="layoutSettings.javaScripts[]"
>>> value="/images/selectMultipleRelatedValues.js" global="true" />
>>>                   <set field="layoutSettings.javaScripts[]"
>>> value="/images/util.js" global="true" />
>>> +                <set field="layoutSettings.javaScripts[]"
>>> value="/images/date/FromThruDateCheck.js" global="true"/>
>>>                   <set field="visualThemeId"
>>> from-field="userPreferences.VISUAL_THEME" global="true" />
>>>                   <service service-name="getVisualThemeResources">
>>>                       <field-map field-name="visualThemeId" />
>>>
>>> Added:
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> URL:
>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>>>
>>> ==============================================================================
>>>
>>> ---
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> (added)
>>> +++
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> Sun Jun  1 12:34:24 2014
>>> @@ -0,0 +1,17 @@
>>> +//this code needs modifications yet its specific.
>>> +
>>> +jQuery(document).ready( function() {
>>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>>> +});
>>> +
>>> +function checkDate() {
>>> +  var a = jQuery("input[name*='fromDate']");
>>> +  var b = jQuery("input[name*='thruDate']");
>>> +
>>> +  if(a.val() !="" && b.val() !="") {
>>> +    if (a.val() >= b.val()) {
>>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels",
>>> "CommonFromDateThruDateCheck")
>>> +    }
>>> +  }
>>> +}
>>>
>>> Propchange:
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> ------------------------------------------------------------------------------
>>>
>>>      svn:eol-style = native
>>>
>>> Propchange:
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> ------------------------------------------------------------------------------
>>>
>>>      svn:keywords = Date Rev Author URL Id
>>>
>>> Propchange:
>>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>>> ------------------------------------------------------------------------------
>>>
>>>      svn:mime-type = text/plain
>>>
>>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>>> URL:
>>> http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>>>
>>> ==============================================================================
>>>
>>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun
>>> 1 12:34:24 2014
>>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>>                   }
>>>               }
>>>           });
>>> +    } else {
>>> +      alert(labels[uiResource][0]);
>>>       }
>>>   }
>>>
>>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>>               return true;
>>>           }
>>>       }
>>> -}
>>> \ No newline at end of file
>>> +}
>>>
>>>
>>
>

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Jacques Le Roux <ja...@les7arts.com>.
Right, and you know I did not invent this "word".

I simply reused "thru " here to keep the subject focused.

I don't clearly remember David's (Or Andy's?) explanation behind it, maybe you do?

Jacques

Le 01/06/2014 17:22, Adrian Crum a écrit :
> "Thru" is not an English word. The correct spelling is "Through".
>
> Adrian Crum
> Sandglass Software
> www.sandglass-software.com
>
> On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
>> Author: jleroux
>> Date: Sun Jun  1 12:34:24 2014
>> New Revision: 1598977
>>
>> URL: http://svn.apache.org/r1598977
>> Log:
>> A modified patch from Ankit Jain for "We should check that the thru date is not same or older than the from date" 
>> https://issues.apache.org/jira/browse/OFBIZ-3161
>>
>> jleroux:
>> I reused Ankit's patch as a basis for this commit
>> I added an i18n label
>> Added a way to use alert() in showErrorAlertLoadUiLabel for generalising when no contentarea is present
>> Replaced $ call by jQuery
>> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get all cases (228 thruDate cases)
>> Still used only an alert, so it's only a warning, nothing coercive
>>
>> There are other date couples like (estimatedStartDate, estimatedCompletionDate) and (actualStartDate, actualCompletionDate) but their values should 
>> not be enforced.
>> If ever someone wants to not let them free, then she just has to add the couples in FromThruDateCheck.js
>>
>>
>>
>>
>> Added:
>> ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js (with props)
>> Modified:
>>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>>
>> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>> ==============================================================================
>> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
>> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1 12:34:24 2014
>> @@ -4457,6 +4457,10 @@
>>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>>           <value xml:lang="zh-TW">開始日/結束日</value>
>>       </property>
>> +    <property key="CommonFromDateThruDateCheck">
>> +        <value xml:lang="en">Thru date can't be same or smaller than from date</value>
>> +        <value xml:lang="fr">La date de fin ne peut être égale ou plus récente que la date de début</value>
>> +    </property>
>>       <property key="CommonFromDateTime">
>>           <value xml:lang="ar">تاريخ  و وقت البدء</value>
>>           <value xml:lang="cs">Od data a času</value>
>>
>> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
>> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
>> ==============================================================================
>> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
>> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1 12:34:24 2014
>> @@ -162,6 +162,7 @@ under the License.
>>                   <set field="layoutSettings.javaScripts[]" value="/images/miscAjaxFunctions.js" global="true" />
>>                   <set field="layoutSettings.javaScripts[]" value="/images/selectMultipleRelatedValues.js" global="true" />
>>                   <set field="layoutSettings.javaScripts[]" value="/images/util.js" global="true" />
>> +                <set field="layoutSettings.javaScripts[]" value="/images/date/FromThruDateCheck.js" global="true"/>
>>                   <set field="visualThemeId" from-field="userPreferences.VISUAL_THEME" global="true" />
>>                   <service service-name="getVisualThemeResources">
>>                       <field-map field-name="visualThemeId" />
>>
>> Added: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
>> ==============================================================================
>> --- ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js (added)
>> +++ ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js Sun Jun  1 12:34:24 2014
>> @@ -0,0 +1,17 @@
>> +//this code needs modifications yet its specific.
>> +
>> +jQuery(document).ready( function() {
>> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
>> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
>> +});
>> +
>> +function checkDate() {
>> +  var a = jQuery("input[name*='fromDate']");
>> +  var b = jQuery("input[name*='thruDate']");
>> +
>> +  if(a.val() !="" && b.val() !="") {
>> +    if (a.val() >= b.val()) {
>> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels", "CommonFromDateThruDateCheck")
>> +    }
>> +  }
>> +}
>>
>> Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>> ------------------------------------------------------------------------------
>>      svn:eol-style = native
>>
>> Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>> ------------------------------------------------------------------------------
>>      svn:keywords = Date Rev Author URL Id
>>
>> Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
>> ------------------------------------------------------------------------------
>>      svn:mime-type = text/plain
>>
>> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
>> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
>> ==============================================================================
>> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
>> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun  1 12:34:24 2014
>> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>>                   }
>>               }
>>           });
>> +    } else {
>> +      alert(labels[uiResource][0]);
>>       }
>>   }
>>
>> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>>               return true;
>>           }
>>       }
>> -}
>> \ No newline at end of file
>> +}
>>
>>
>

-- 

Re: svn commit: r1598977 - in /ofbiz/trunk/framework: common/config/CommonUiLabels.xml common/widget/CommonScreens.xml images/webapp/images/date/FromThruDateCheck.js images/webapp/images/selectall.js

Posted by Adrian Crum <ad...@sandglass-software.com>.
"Thru" is not an English word. The correct spelling is "Through".

Adrian Crum
Sandglass Software
www.sandglass-software.com

On 6/1/2014 5:34 AM, jleroux@apache.org wrote:
> Author: jleroux
> Date: Sun Jun  1 12:34:24 2014
> New Revision: 1598977
>
> URL: http://svn.apache.org/r1598977
> Log:
> A modified patch from Ankit Jain for "We should check that the thru date is not same or older than the from date" https://issues.apache.org/jira/browse/OFBIZ-3161
>
> jleroux:
> I reused Ankit's patch as a basis for this commit
> I added an i18n label
> Added a way to use alert() in showErrorAlertLoadUiLabel for generalising when no contentarea is present
> Replaced $ call by jQuery
> Used the <<name*='fromDate'>> and <<name*='thruDate'>> filters to get all cases (228 thruDate cases)
> Still used only an alert, so it's only a warning, nothing coercive
>
> There are other date couples like (estimatedStartDate, estimatedCompletionDate) and (actualStartDate, actualCompletionDate) but their values should not be enforced.
> If ever someone wants to not let them free, then she just has to add the couples in FromThruDateCheck.js
>
>
>
>
> Added:
>      ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js   (with props)
> Modified:
>      ofbiz/trunk/framework/common/config/CommonUiLabels.xml
>      ofbiz/trunk/framework/common/widget/CommonScreens.xml
>      ofbiz/trunk/framework/images/webapp/images/selectall.js
>
> Modified: ofbiz/trunk/framework/common/config/CommonUiLabels.xml
> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/config/CommonUiLabels.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
> ==============================================================================
> --- ofbiz/trunk/framework/common/config/CommonUiLabels.xml (original)
> +++ ofbiz/trunk/framework/common/config/CommonUiLabels.xml Sun Jun  1 12:34:24 2014
> @@ -4457,6 +4457,10 @@
>           <value xml:lang="zh-CN">起始日期 / 终止日期</value>
>           <value xml:lang="zh-TW">開始日/結束日</value>
>       </property>
> +    <property key="CommonFromDateThruDateCheck">
> +        <value xml:lang="en">Thru date can't be same or smaller than from date</value>
> +        <value xml:lang="fr">La date de fin ne peut être égale ou plus récente que la date de début</value>
> +    </property>
>       <property key="CommonFromDateTime">
>           <value xml:lang="ar">تاريخ  و وقت البدء</value>
>           <value xml:lang="cs">Od data a času</value>
>
> Modified: ofbiz/trunk/framework/common/widget/CommonScreens.xml
> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/common/widget/CommonScreens.xml?rev=1598977&r1=1598976&r2=1598977&view=diff
> ==============================================================================
> --- ofbiz/trunk/framework/common/widget/CommonScreens.xml (original)
> +++ ofbiz/trunk/framework/common/widget/CommonScreens.xml Sun Jun  1 12:34:24 2014
> @@ -162,6 +162,7 @@ under the License.
>                   <set field="layoutSettings.javaScripts[]" value="/images/miscAjaxFunctions.js" global="true" />
>                   <set field="layoutSettings.javaScripts[]" value="/images/selectMultipleRelatedValues.js" global="true" />
>                   <set field="layoutSettings.javaScripts[]" value="/images/util.js" global="true" />
> +                <set field="layoutSettings.javaScripts[]" value="/images/date/FromThruDateCheck.js" global="true"/>
>                   <set field="visualThemeId" from-field="userPreferences.VISUAL_THEME" global="true" />
>                   <service service-name="getVisualThemeResources">
>                       <field-map field-name="visualThemeId" />
>
> Added: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js?rev=1598977&view=auto
> ==============================================================================
> --- ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js (added)
> +++ ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js Sun Jun  1 12:34:24 2014
> @@ -0,0 +1,17 @@
> +//this code needs modifications yet its specific.
> +
> +jQuery(document).ready( function() {
> +  jQuery("input[name*='fromDate']").bind('focusout', checkDate);
> +  jQuery("input[name*='thruDate']").bind('focusout', checkDate);
> +});
> +
> +function checkDate() {
> +  var a = jQuery("input[name*='fromDate']");
> +  var b = jQuery("input[name*='thruDate']");
> +
> +  if(a.val() !="" && b.val() !="") {
> +    if (a.val() >= b.val()) {
> +      showErrorAlertLoadUiLabel("", "", "CommonUiLabels", "CommonFromDateThruDateCheck")
> +    }
> +  }
> +}
>
> Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
> ------------------------------------------------------------------------------
>      svn:eol-style = native
>
> Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
> ------------------------------------------------------------------------------
>      svn:keywords = Date Rev Author URL Id
>
> Propchange: ofbiz/trunk/framework/images/webapp/images/date/FromThruDateCheck.js
> ------------------------------------------------------------------------------
>      svn:mime-type = text/plain
>
> Modified: ofbiz/trunk/framework/images/webapp/images/selectall.js
> URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/images/webapp/images/selectall.js?rev=1598977&r1=1598976&r2=1598977&view=diff
> ==============================================================================
> --- ofbiz/trunk/framework/images/webapp/images/selectall.js (original)
> +++ ofbiz/trunk/framework/images/webapp/images/selectall.js Sun Jun  1 12:34:24 2014
> @@ -915,6 +915,8 @@ function showErrorAlertLoadUiLabel(errBo
>                   }
>               }
>           });
> +    } else {
> +      alert(labels[uiResource][0]);
>       }
>   }
>
> @@ -985,4 +987,4 @@ function submitPagination(obj, url) {
>               return true;
>           }
>       }
> -}
> \ No newline at end of file
> +}
>
>