From bartek w erp5.pl Sat May 31 12:33:14 2008 From: bartek w erp5.pl (bartek) Date: Sat, 31 May 2008 12:33:14 +0200 Subject: [Erp5-poland] [Erp5-report] r21252 - in /erp5/trunk/products/ERP5/bootstrap/erp5_core: CategoryTemplateIt... In-Reply-To: <20080530150732.DB4063D985@nexedi.com> References: <20080530150732.DB4063D985@nexedi.com> Message-ID: <4841296A.7070109@erp5.pl> No, no - czyżby "problem osełki" doczekał się rozwiązania?? B. nobody w svn.erp5.org wrote: > Author: jm > Date: Fri May 30 17:07:32 2008 > New Revision: 21252 > > URL: http://svn.erp5.org?rev=21252&view=rev > Log: > * Add support for unit conversion: > * resources are described using Measure objects > * stock can be queried in any unit > * movements perform unit conversion > > * See following wiki articles: > * HowToUseMeasures > * TechnicalNotesOnUnitConversion > > Added: > erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view/my_quantity.xml > Modified: > erp5/trunk/products/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/quantity_unit.xml > erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view.xml > erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Resource_zGetInventoryList.xml > erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision > > Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/quantity_unit.xml > URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/quantity_unit.xml?rev=21252&r1=21251&r2=21252&view=diff > ============================================================================== > --- erp5/trunk/products/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/quantity_unit.xml (original) > +++ erp5/trunk/products/ERP5/bootstrap/erp5_core/CategoryTemplateItem/portal_categories/quantity_unit.xml Fri May 30 17:07:32 2008 > @@ -45,9 +45,9 @@ > > > delivery > - resource > order > parent > + resource > > > > > Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view.xml > URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view.xml?rev=21252&r1=21251&r2=21252&view=diff > ============================================================================== > --- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view.xml (original) > +++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view.xml Fri May 30 17:07:32 2008 > @@ -121,6 +121,7 @@ > my_codification > my_int_index > my_translated_validation_state_title > + my_quantity > > > > > Added: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view/my_quantity.xml > URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view/my_quantity.xml?rev=21252&view=auto > ============================================================================== > --- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view/my_quantity.xml (added) > +++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Category_view/my_quantity.xml Fri May 30 17:07:32 2008 > @@ -1,0 +1,163 @@ > + > + > + > + > + > + > + > + > + > + > + > + > + _owner > + > + > + > + > + > + delegated_list > + > + > + display_width > + precision > + enabled > + > + > + > + > + id > + my_quantity > + > + > + message_values > + > + > + > + external_validator_failed > + The input failed the external validator. > + > + > + > + > + > + overrides > + > + > + > + field_id > + > + > + > + form_id > + > + > + > + target > + > + > + > + > + > + > + tales > + > + > + > + display_width > + > + AAAAAAAAAAI= > + > + > + > + enabled > + > + AAAAAAAAAAM= > + > + > + > + field_id > + > + > + > + form_id > + > + > + > + precision > + > + > + > + target > + > + > + > + > + > + > + values > + > + > + > + display_width > + 20 > + > + > + enabled > + 1 > + > + > + field_id > + my_quantity > + > + > + form_id > + Base_viewFieldLibrary > + > + > + precision > + 15 > + > + > + target > + Click to edit the target > + > + > + > + > + > + > + > + > + > + > + > + > + > + > + > + > + > + _text > + python: max(15,int(field.getTemplateField().get_value(\'display_width\'))) > + > + > + > + > + > + > + > + > + > + > + > + > + > + > + _text > + python: (lambda x: x.getPortalType() == \'Base Category\' and x.getId() == \'quantity_unit\')(here.getParent().getParent()) > + > + > + > + > + > > Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Resource_zGetInventoryList.xml > URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Resource_zGetInventoryList.xml?rev=21252&r1=21251&r2=21252&view=diff > ============================================================================== > --- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Resource_zGetInventoryList.xml (original) > +++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Resource_zGetInventoryList.xml Fri May 30 17:07:32 2008 > @@ -114,6 +114,12 @@ > > > precision > + > + > + > + > + > + quantity_unit > > > > @@ -189,6 +195,7 @@ > precision > inventory_list > statistic > +quantity_unit > stock_table_id > > > @@ -196,6 +203,12 @@ > > > > + > + > + > + _owner > + > + > > > > @@ -223,6 +236,7 @@ > precision\r\n > inventory_list\r\n > statistic\r\n > +quantity_unit\r\n > stock_table_id=stock > > > @@ -267,10 +281,18 @@ > \n > SUM(ROUND(.quantity, )) AS inventory,\n > SUM(ROUND(.quantity, )) AS total_quantity,\n > +\n > + SUM(ROUND(.quantity * measure.quantity, ))\n > + / AS converted_quantity,\n > +\n > SUM(ROUND(.total_price, )) AS total_price\n > \n > SUM(.quantity) AS inventory,\n > SUM(.quantity) AS total_quantity,\n > +\n > + ROUND(SUM(.quantity * measure.quantity)\n > + / , 12) AS converted_quantity,\n > +\n > SUM(.total_price) AS total_price\n > \n > \n > @@ -340,6 +362,12 @@ > \n > AND \n > \n > +\n > +\n > + AND concat(.variation_text,\'\\n\') REGEXP measure.variation\n > +\n > +\n > +\n > \n > GROUP BY\n > \n > @@ -392,10 +420,18 @@ > \n > SUM(ROUND(.quantity, )) AS inventory,\n > SUM(ROUND(.quantity, )) AS total_quantity,\n > +\n > + SUM(ROUND(.quantity * measure.quantity, ))\n > + / AS converted_quantity,\n > +\n > SUM(ROUND(.total_price, )) AS total_price\n > \n > SUM(.quantity) AS inventory,\n > SUM(.quantity) AS total_quantity,\n > +\n > + ROUND(SUM(.quantity * measure.quantity)\n > + / , 12) AS converted_quantity,\n > +\n > SUM(.total_price) AS total_price\n > \n > \n > @@ -465,6 +501,12 @@ > \n > AND \n > \n > +\n > +\n > + AND concat(.variation_text,\'\\n\') REGEXP measure.variation\n > +\n > +\n > +\n > \n > GROUP BY\n > \n > > Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision > URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision?rev=21252&r1=21251&r2=21252&view=diff > ============================================================================== > --- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision (original) > +++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision Fri May 30 17:07:32 2008 > @@ -1,1 +1,1 @@ > -825 > +826 > > _______________________________________________ > Erp5-report mailing list > Erp5-report w erp5.org > http://mail.nexedi.com/mailman/listinfo/erp5-report >