Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

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

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

Malin Nicolas
Hi adrian,

There is a risk to change " by ' when we change bsh by groovy
engine on flexible string ?
When I convert old customer specific code as you did, I replace also the
string " .

productMaintValue.getBigDecimal('intervalQuantity') is really more readable than productMaintValue.getBigDecimal("intervalQuantity")

Just to be sure that I didn't to take a wrong way.

Cheers,
Nicolas

Le 05/04/2013 00:01, [hidden email] a écrit :
> -            <set field="nextIntervalQty" value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
> +            <set field="nextIntervalQty" value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>


--
Nicolas MALIN
Consultant
Tél : 06.17.66.40.06
Site projet : http://www.neogia.org/
-------
Société LibrenBerry
Tél : 02.48.02.56.12
Site : http://www.librenberry.net/

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

Adrian Crum-3
We will see if anyone reports a problem. I ran unit tests after the
replacement (the unit tests used the bsh: scriptlets a lot) and there
were no errors reported.

-Adrian

On 4/5/2013 7:59 AM, Nicolas Malin wrote:

> Hi adrian,
>
> There is a risk to change &quot; by ' when we change bsh by groovy
> engine on flexible string ?
> When I convert old customer specific code as you did, I replace also
> the string &quot; .
>
> productMaintValue.getBigDecimal('intervalQuantity') is really more
> readable than
> productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;)
>
> Just to be sure that I didn't to take a wrong way.
>
> Cheers,
> Nicolas
>
> Le 05/04/2013 00:01, [hidden email] a écrit :
>> -            <set field="nextIntervalQty"
>> value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}"
>> type="BigDecimal"/>
>> +            <set field="nextIntervalQty"
>> value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}"
>> type="BigDecimal"/>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

Jacopo Cappellato-4
Adrian,

I think that Nicolas was proposing to replace &quot; with ' to increase readability: this was not possible with Beanshell but it is now possible after we switch to groovy.

Jacopo



On Apr 5, 2013, at 9:26 AM, Adrian Crum <[hidden email]> wrote:

> We will see if anyone reports a problem. I ran unit tests after the replacement (the unit tests used the bsh: scriptlets a lot) and there were no errors reported.
>
> -Adrian
>
> On 4/5/2013 7:59 AM, Nicolas Malin wrote:
>> Hi adrian,
>>
>> There is a risk to change &quot; by ' when we change bsh by groovy engine on flexible string ?
>> When I convert old customer specific code as you did, I replace also the string &quot; .
>>
>> productMaintValue.getBigDecimal('intervalQuantity') is really more readable than productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;)
>>
>> Just to be sure that I didn't to take a wrong way.
>>
>> Cheers,
>> Nicolas
>>
>> Le 05/04/2013 00:01, [hidden email] a écrit :
>>> -            <set field="nextIntervalQty" value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>> +            <set field="nextIntervalQty" value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>
>>
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

Adrian Crum-3
Oh! Thanks for the clarification.

-Adrian

On 4/5/2013 8:45 AM, Jacopo Cappellato wrote:

> Adrian,
>
> I think that Nicolas was proposing to replace &quot; with ' to increase readability: this was not possible with Beanshell but it is now possible after we switch to groovy.
>
> Jacopo
>
>
>
> On Apr 5, 2013, at 9:26 AM, Adrian Crum <[hidden email]> wrote:
>
>> We will see if anyone reports a problem. I ran unit tests after the replacement (the unit tests used the bsh: scriptlets a lot) and there were no errors reported.
>>
>> -Adrian
>>
>> On 4/5/2013 7:59 AM, Nicolas Malin wrote:
>>> Hi adrian,
>>>
>>> There is a risk to change &quot; by ' when we change bsh by groovy engine on flexible string ?
>>> When I convert old customer specific code as you did, I replace also the string &quot; .
>>>
>>> productMaintValue.getBigDecimal('intervalQuantity') is really more readable than productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;)
>>>
>>> Just to be sure that I didn't to take a wrong way.
>>>
>>> Cheers,
>>> Nicolas
>>>
>>> Le 05/04/2013 00:01, [hidden email] a écrit :
>>>> -            <set field="nextIntervalQty" value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>> +            <set field="nextIntervalQty" value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

Jacopo Cappellato-4
I think we should complete the migration from bsh scripts: to groovy: scripts and then we could remove the Beanshell specific code and jars from the trunk.
What do you think?

Jacopo

On Apr 5, 2013, at 10:11 AM, Adrian Crum <[hidden email]> wrote:

> Oh! Thanks for the clarification.
>
> -Adrian
>
> On 4/5/2013 8:45 AM, Jacopo Cappellato wrote:
>> Adrian,
>>
>> I think that Nicolas was proposing to replace &quot; with ' to increase readability: this was not possible with Beanshell but it is now possible after we switch to groovy.
>>
>> Jacopo
>>
>>
>>
>> On Apr 5, 2013, at 9:26 AM, Adrian Crum <[hidden email]> wrote:
>>
>>> We will see if anyone reports a problem. I ran unit tests after the replacement (the unit tests used the bsh: scriptlets a lot) and there were no errors reported.
>>>
>>> -Adrian
>>>
>>> On 4/5/2013 7:59 AM, Nicolas Malin wrote:
>>>> Hi adrian,
>>>>
>>>> There is a risk to change &quot; by ' when we change bsh by groovy engine on flexible string ?
>>>> When I convert old customer specific code as you did, I replace also the string &quot; .
>>>>
>>>> productMaintValue.getBigDecimal('intervalQuantity') is really more readable than productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;)
>>>>
>>>> Just to be sure that I didn't to take a wrong way.
>>>>
>>>> Cheers,
>>>> Nicolas
>>>>
>>>> Le 05/04/2013 00:01, [hidden email] a écrit :
>>>>> -            <set field="nextIntervalQty" value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>>> +            <set field="nextIntervalQty" value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>>
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr...

Adrian Crum-3
I think the only bsh: scriptlets left are in the screen widgets. Also, I
think the "use-when" attribute uses bsh. So I would need to take a look
at it.

But yes, this task should be completed. We've been talking about it for
years.

-Adrian

On 4/6/2013 9:18 AM, Jacopo Cappellato wrote:

> I think we should complete the migration from bsh scripts: to groovy: scripts and then we could remove the Beanshell specific code and jars from the trunk.
> What do you think?
>
> Jacopo
>
> On Apr 5, 2013, at 10:11 AM, Adrian Crum <[hidden email]> wrote:
>
>> Oh! Thanks for the clarification.
>>
>> -Adrian
>>
>> On 4/5/2013 8:45 AM, Jacopo Cappellato wrote:
>>> Adrian,
>>>
>>> I think that Nicolas was proposing to replace &quot; with ' to increase readability: this was not possible with Beanshell but it is now possible after we switch to groovy.
>>>
>>> Jacopo
>>>
>>>
>>>
>>> On Apr 5, 2013, at 9:26 AM, Adrian Crum <[hidden email]> wrote:
>>>
>>>> We will see if anyone reports a problem. I ran unit tests after the replacement (the unit tests used the bsh: scriptlets a lot) and there were no errors reported.
>>>>
>>>> -Adrian
>>>>
>>>> On 4/5/2013 7:59 AM, Nicolas Malin wrote:
>>>>> Hi adrian,
>>>>>
>>>>> There is a risk to change &quot; by ' when we change bsh by groovy engine on flexible string ?
>>>>> When I convert old customer specific code as you did, I replace also the string &quot; .
>>>>>
>>>>> productMaintValue.getBigDecimal('intervalQuantity') is really more readable than productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;)
>>>>>
>>>>> Just to be sure that I didn't to take a wrong way.
>>>>>
>>>>> Cheers,
>>>>> Nicolas
>>>>>
>>>>> Le 05/04/2013 00:01, [hidden email] a écrit :
>>>>>> -            <set field="nextIntervalQty" value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>>>> +            <set field="nextIntervalQty" value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1464779 - in /ofbiz/trunk: applications/accounting/script/org/ofbiz/accounting/fixedasset/ applications/accounting/script/org/ofbiz/accounting/invoice/ applications/accounting/script/org/ofbiz/accounting/ledger/ applications/accounting/scr

Jacques Le Roux
Administrator
In reply to this post by Jacopo Cappellato-4
+1, if we find enough time to do so

Jacques

From: "Jacopo Cappellato" <[hidden email]>

>I think we should complete the migration from bsh scripts: to groovy: scripts and then we could remove the Beanshell specific code and jars from the trunk.
> What do you think?
>
> Jacopo
>
> On Apr 5, 2013, at 10:11 AM, Adrian Crum <[hidden email]> wrote:
>
>> Oh! Thanks for the clarification.
>>
>> -Adrian
>>
>> On 4/5/2013 8:45 AM, Jacopo Cappellato wrote:
>>> Adrian,
>>>
>>> I think that Nicolas was proposing to replace &quot; with ' to increase readability: this was not possible with Beanshell but it is now possible after we switch to groovy.
>>>
>>> Jacopo
>>>
>>>
>>>
>>> On Apr 5, 2013, at 9:26 AM, Adrian Crum <[hidden email]> wrote:
>>>
>>>> We will see if anyone reports a problem. I ran unit tests after the replacement (the unit tests used the bsh: scriptlets a lot) and there were no errors reported.
>>>>
>>>> -Adrian
>>>>
>>>> On 4/5/2013 7:59 AM, Nicolas Malin wrote:
>>>>> Hi adrian,
>>>>>
>>>>> There is a risk to change &quot; by ' when we change bsh by groovy engine on flexible string ?
>>>>> When I convert old customer specific code as you did, I replace also the string &quot; .
>>>>>
>>>>> productMaintValue.getBigDecimal('intervalQuantity') is really more readable than productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;)
>>>>>
>>>>> Just to be sure that I didn't to take a wrong way.
>>>>>
>>>>> Cheers,
>>>>> Nicolas
>>>>>
>>>>> Le 05/04/2013 00:01, [hidden email] a écrit :
>>>>>> -            <set field="nextIntervalQty" value="${bsh:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>>>> +            <set field="nextIntervalQty" value="${groovy:maxIntervalQty.add(productMaintValue.getBigDecimal(&quot;intervalQuantity&quot;));}" type="BigDecimal"/>
>>>>>
>>
>
>