[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
r120 - in gnue-invoice: . forms schema
From: |
kilo |
Subject: |
r120 - in gnue-invoice: . forms schema |
Date: |
Fri, 19 Nov 2004 03:42:50 -0600 (CST) |
Author: kilo
Date: 2004-11-19 03:42:49 -0600 (Fri, 19 Nov 2004)
New Revision: 120
Modified:
gnue-invoice/forms/INV_Head.gfd
gnue-invoice/news
gnue-invoice/schema/invoice.gcd
gnue-invoice/todo
Log:
GNUe Invoice.
Changes due to correctly working dropdowns.
Modified: gnue-invoice/forms/INV_Head.gfd
===================================================================
--- gnue-invoice/forms/INV_Head.gfd 2004-11-18 09:17:05 UTC (rev 119)
+++ gnue-invoice/forms/INV_Head.gfd 2004-11-19 09:42:49 UTC (rev 120)
@@ -48,15 +48,11 @@
blkFreeHead.dateDue.set(dateDue)
</trigger>
- <trigger name="getItemPrice" type="NAMED">
- price = blkINV_Item.call("INV_itemPrice", {})
- blkFreeItem.itemPrice.set(price)
- </trigger>
-
<trigger name="calcItemPriceTotal" type="NAMED">
#Calculate and display the line's total value
- if (blkFreeItem.itemPrice is not None) and (blkINV_Item.fldInvQuantity is
not None):
- price = float(blkFreeItem.itemPrice.get())
+ if (blkINV_Item.fldInvProductPrice is not None) and
(blkINV_Item.fldInvQuantity is not None):
+ print blkINV_Item.fldInvProductPrice.get(),
blkINV_Item.fldInvQuantity.get()
+ price = float(blkINV_Item.fldInvProductPrice.get())
quantity = float(blkINV_Item.fldInvQuantity.get())
total = price * quantity
blkFreeItem.itemPriceTotal.set(total)
@@ -145,12 +141,13 @@
<field name="fldInvHead" field="INV_head" maxLength="32" />
<field name="fldInvProduct" field="INV_product"
fk_description="ITEM_shortName" fk_key="gnue_id"
- fk_source="dts_ITEM_Item" maxLength="32">
- <trigger type="POST-CHANGE" name="postchange" src="getItemPrice" />
- </field>
+ fk_source="dts_ITEM_Item" maxLength="32"/>
+ <field name="fldInvProductPrice" field="INV_product"
+ fk_description="ITEM_price" fk_key="gnue_id"
+ fk_source="dts_ITEM_Item" readonly="Y" />
<field name="fldInvQuantity" field="INV_quantity" maxLength="10"
typecast="number">
- <trigger type="POST-CHANGE" name="postchange" src="calcItemPriceTotal"
/>
+ <!--<trigger type="POST-CHANGE" name="postchange"
src="calcItemPriceTotal" />-->
</field>
<!--Count totals -->
@@ -167,7 +164,6 @@
Fields to display generated/computed invoice line data on the form
****************************************************************-->
<block name="blkFreeItem" rows="5">
- <field name="itemPrice" readonly="Y" typecast="number"/>
<field name="itemPriceTotal" readonly="Y" typecast="number"/>
<!--Setting generated and computed initial data-->
@@ -249,9 +245,9 @@
<entry name="entInvProduct" c:height="1" c:width="28" c:x="2" c:y="12"
block="blkINV_Item" field="fldInvProduct" style="dropdown" />
- <entry name="entItemPrice" c:height="1" c:width="6" c:x="31" c:y="12"
- block="blkFreeItem" field="itemPrice" style="label" />
- <entry name="entInvQuantity" c:height="1" c:width="5" c:x="38" c:y="12"
+ <entry name="entItemPrice" c:height="1" c:width="6" c:x="31" c:y="12"
+ block="blkINV_Item" field="fldInvProductPrice" style="label" />
+ <entry name="entInvQuantity" c:height="1" c:width="5" c:x="38" c:y="12"
block="blkINV_Item" field="fldInvQuantity"/>
<entry name="entItemPriceTotal" c:height="1" c:width="10" c:x="44"
c:y="12"
block="blkFreeItem" field="itemPriceTotal" style="label" />
Modified: gnue-invoice/news
===================================================================
--- gnue-invoice/news 2004-11-18 09:17:05 UTC (rev 119)
+++ gnue-invoice/news 2004-11-19 09:42:49 UTC (rev 120)
@@ -2,6 +2,10 @@
*************************
GNUe Invoice - Project CV
*************************
+New features / changes by 2004.11.19
+* Applied changes due to correctly working dropdowns at last committed
+ to GNUe. It simplified the main form a little bit.
+
New features / changes by 2004.11.16
* Modified the 'Edit...' button's width. It is 7 now. It always should
have been...
Modified: gnue-invoice/schema/invoice.gcd
===================================================================
--- gnue-invoice/schema/invoice.gcd 2004-11-18 09:17:05 UTC (rev 119)
+++ gnue-invoice/schema/invoice.gcd 2004-11-19 09:42:49 UTC (rev 120)
@@ -62,14 +62,6 @@
return gross
</property>
- <!--***********************
- Return price of the product
- ************************-->
- <procedure name="itemPrice" type="number(10,2)" >
- price = self.product.ITEM_price
- return price
- </procedure>
-
<!--****************************
Return price * quantity, or None
*****************************-->
@@ -144,10 +136,7 @@
each time so that grid form works OK.
*******************************************************-->
<property name="buyerName" type="string(35)" >
- if self.buyer is not None:
- return self.buyer.PARTY_name
- else:
- return ''
+ return self.buyer and self.buyer.PARTY_name or ''
</property>
<!--******************************************************
Modified: gnue-invoice/todo
===================================================================
--- gnue-invoice/todo 2004-11-18 09:17:05 UTC (rev 119)
+++ gnue-invoice/todo 2004-11-19 09:42:49 UTC (rev 120)
@@ -52,3 +52,11 @@
At startup the user should select the firm through AppServer filters.
Status: not started
+
+
+USE IMPORTS TO CLEAN UP SOURCE CODE
+===================================
+ Use import-trigger for form triggers that share the same code and store
+ trigger code in a separate file.
+
+ Status: not started, due to lack of documentation
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- r120 - in gnue-invoice: . forms schema,
kilo <=