1 |
<?xml version="1.0" encoding="ISO-8859-1"?> |
<?xml version="1.0" encoding="ISO-8859-1"?> |
|
<!DOCTYPE form SYSTEM "gnue-forms.dtd"> |
|
2 |
<form width="107" height="24" title="Remito para Clientes"> |
<form width="107" height="24" title="Remito para Clientes"> |
3 |
<neb:Block> |
<neb:Block> |
4 |
use PAPO; |
use PAPO; |
174 |
<datasource name="priceDataSource" database="papo" table="_price_data" /> |
<datasource name="priceDataSource" database="papo" table="_price_data" /> |
175 |
|
|
176 |
<!-- Origen de datos que contiene el encabezado del remito --> |
<!-- Origen de datos que contiene el encabezado del remito --> |
|
|
|
177 |
<datasource database="papo" name="ownDocumentDataSource" table="own_document" |
<datasource database="papo" name="ownDocumentDataSource" table="own_document" |
178 |
order_by="date" /> |
order_by="date" /> |
|
<!--nebulized--> |
|
|
<!-- Origen de datos que contiene el número del próximo remito --> |
|
|
<!-- <datasource name="ownPosDocumentDataSource" database="papo" --> |
|
|
<!-- table="own_pos_document, _own_pos_document_data" historytable="_own_pos_document_data"> --> |
|
|
<!-- <condition> --> |
|
|
<!-- <and> --> |
|
|
<!-- <eq> --> |
|
|
<!-- <cfield name="own_pos_document.id"/> --> |
|
|
<!-- <cfield name="_own_pos_document_data._table"/> --> |
|
|
<!-- </eq> --> |
|
|
<!-- <null> --> |
|
|
<!-- <cfield name="_own_pos_document_data._end_t"/> --> |
|
|
<!-- </null> --> |
|
|
<!-- </and> --> |
|
|
<!-- </condition> --> |
|
|
<!-- </datasource> --> |
|
179 |
|
|
180 |
<!-- Origen de datos que contiene los items del remito --> |
<!-- Origen de datos que contiene los items del remito --> |
181 |
|
<datasource name="ownItemDataSource" database="papo" detaillink="own_item.own_document" |
182 |
<datasource name="ownItemDataSource" database="papo" detaillink="own_item.own_document" |
master="ownDocumentDataSource" masterlink="id" |
183 |
master="ownDocumentDataSource" masterlink="id" |
table="own_item, own_product_item, own_item_tax"> |
184 |
table="own_item, own_product_item"> |
<condition> |
185 |
<condition> |
<eq> |
186 |
<eq> |
<cfield name="own_item.id"/> |
187 |
<cfield name="own_item.id"/> |
<cfield name="own_product_item.own_item"/> |
188 |
<cfield name="own_product_item.own_item"/> |
</eq> |
189 |
</eq> |
<eq> |
190 |
|
<cfield name="own_item.id"/> |
191 |
|
<cfield name="own_item_tax.own_item"/> |
192 |
|
</eq> |
193 |
</condition> |
</condition> |
194 |
</datasource> |
</datasource> |
195 |
|
|
200 |
<trigger name="prodCallFormTrigger" type="NAMED"><![CDATA[ |
<trigger name="prodCallFormTrigger" type="NAMED"><![CDATA[ |
201 |
runForm('product.gfd') |
runForm('product.gfd') |
202 |
]]></trigger> |
]]></trigger> |
203 |
<!--nebulized--> |
|
204 |
<!-- <trigger name="searchNextDespatchNoteNumber" type="NAMED"><![CDATA[ --> |
<neb:Sub neb:src="wait.nebc"/> |
|
<!-- import gnue.common.GConditions as GConditions --> |
|
|
|
|
|
<!-- condDespatchNoteNumber = GConditions.GCondition() --> |
|
|
|
|
|
<!-- tmpAnd = GConditions.GCand(condDespatchNoteNumber) --> |
|
|
<!-- eq = GConditions.GCeq(tmpAnd) --> |
|
|
<!-- GConditions.GCField(eq,"_own_pos_document_data.document_type") --> |
|
|
<!-- GConditions.GCConst(eq,str(ownDocumentBlock.typeEntry)) --> |
|
|
|
|
|
<!-- ownPosDocumentDataSource.createResultSet(condDespatchNoteNumber) --> |
|
|
|
|
|
<!-- ]]></trigger> --> |
|
|
<!--/nebulized--> |
|
|
|
|
|
<trigger name="startWaitingModeTrigger" type="NAMED"><![CDATA[ |
|
|
setStatusText("Procesando ...") |
|
|
try: |
|
|
# gnue version <= 0.4 |
|
|
from gnue.forms.GFEvent import GFEvent |
|
|
except ImportError: |
|
|
# gnue version >= 0.5 |
|
|
from gnue.common.events.Event import Event as GFEvent |
|
|
|
|
|
# busy clock |
|
|
self._object.dispatchEvent(GFEvent('beginWAIT')) |
|
|
]]></trigger> |
|
|
|
|
|
<trigger name="endWaitingModeTrigger" type="NAMED"><![CDATA[ |
|
|
try: |
|
|
# gnue version <= 0.4 |
|
|
from gnue.forms.GFEvent import GFEvent |
|
|
except ImportError: |
|
|
# gnue version >= 0.5 |
|
|
from gnue.common.events.Event import Event as GFEvent |
|
|
|
|
|
self._object.dispatchEvent(GFEvent('endWAIT')) |
|
|
setStatusText("Listo") |
|
|
]]></trigger> |
|
205 |
|
|
206 |
<trigger name="printTrigger" type="NAMED"><![CDATA[ |
<trigger name="printTrigger" type="NAMED"><![CDATA[ |
207 |
import hack |
import hack |
219 |
|
|
220 |
<trigger name="commitTrigger" type="NAMED"> |
<trigger name="commitTrigger" type="NAMED"> |
221 |
|
|
222 |
|
callTrigger('startWaitingModeTrigger') |
223 |
ownDocumentBlock.numberEntry = str(ownPosDocumentBlock.documentNumberEntry) |
ownDocumentBlock.numberEntry = str(ownPosDocumentBlock.documentNumberEntry) |
224 |
ownDocumentBlock.ownPosEntityIdEntry = str(ownPosBlock.ownPosEntityIdEntry) |
ownDocumentBlock.ownPosEntityIdEntry = str(ownPosBlock.ownPosEntityIdEntry) |
225 |
ownDocumentBlock.dateEntry = str(tmpBlock.tmpDateEntry ) |
ownDocumentBlock.dateEntry = str(tmpBlock.tmpDateEntry ) |
239 |
|
|
240 |
commitConnection() |
commitConnection() |
241 |
print "comitted" |
print "comitted" |
242 |
|
callTrigger('endWaitingModeTrigger') |
243 |
except DBError, err: |
except DBError, err: |
244 |
print "rollback" |
print "rollback" |
245 |
rollbackConnection() |
rollbackConnection() |
250 |
message += "el número del remito" |
message += "el número del remito" |
251 |
elif postChangeAdvance == 2: |
elif postChangeAdvance == 2: |
252 |
message += "el stock" |
message += "el stock" |
253 |
|
callTrigger('endWaitingModeTrigger') |
254 |
genericBox(message+"\n"+str(err),['Aceptar']) |
genericBox(message+"\n"+str(err),['Aceptar']) |
|
|
|
|
|
|
255 |
</trigger> |
</trigger> |
256 |
|
|
257 |
<trigger name="rollbackTrigger" type="NAMED"> |
<trigger name="rollbackTrigger" type="NAMED"> |
258 |
tmpValuesDataSource.priceTypeId = None |
tmpValuesDataSource.priceTypeId = None |
259 |
|
|
260 |
clear() |
clear() |
261 |
|
|
262 |
tmpBlock.tmpDateEntry = ownDocumentDataSource.getTimeStamp() |
tmpBlock.tmpDateEntry = ownDocumentDataSource.getTimeStamp() |
263 |
callTrigger('searchNextDespatchNoteNumber') |
callTrigger('searchNextDespatchNoteNumber') |
264 |
#setFocus(ownDocumentBlock.clientCodeEntry) |
#setFocus(ownDocumentBlock.clientCodeEntry) |
265 |
</trigger> |
</trigger> |
266 |
<trigger name="startUp" type="On-Startup"> |
<trigger name="startUp" type="On-Startup"> |
267 |
tmpValuesDataSource.priceTypeId = None |
tmpValuesDataSource.priceTypeId = None |
268 |
tmpValuesDataSource.onSwitch = "0" |
tmpValuesDataSource.onSwitch = "0" |
269 |
ownOrganizationBlock.clear() |
ownOrganizationBlock.clear() |
270 |
ownOrganizationBlock.initQuery() |
ownOrganizationBlock.initQuery() |
271 |
ownOrganizationBlock.processQuery() |
ownOrganizationBlock.processQuery() |
272 |
tmpValuesDataSource.ownIVACond = str(ownOrganizationBlock.condIVAEntry) |
tmpValuesDataSource.ownIVACond = str(ownOrganizationBlock.condIVAEntry) |
273 |
tmpBlock.tmpDateEntry = ownDocumentDataSource.getTimeStamp() |
tmpBlock.tmpDateEntry = ownDocumentDataSource.getTimeStamp() |
274 |
callTrigger('searchNextDespatchNoteNumber') |
callTrigger('searchNextDespatchNoteNumber') |
275 |
</trigger> |
</trigger> |
276 |
|
|
277 |
<trigger name="quitTrigger" type="NAMED"> |
<trigger name="quitTrigger" type="NAMED"> |
278 |
callTrigger('rollbackTrigger') |
callTrigger('rollbackTrigger') |
279 |
ownDocumentBlock.clear() |
ownDocumentBlock.clear() |
280 |
exit() |
exit() |
281 |
</trigger> |
</trigger> |
282 |
|
|
283 |
<!-- Este trigger clacula el total del remito valorizado --> |
<!-- Este trigger clacula el total del remito valorizado --> |
451 |
searchNextDocumentNumber="searchNextDespatchNoteNumber" |
searchNextDocumentNumber="searchNextDespatchNoteNumber" |
452 |
ownStorehouseBlock ="ownStorehouseBlock" ownStorehouseIdEntry="ownStorehouseIdEntry" > |
ownStorehouseBlock ="ownStorehouseBlock" ownStorehouseIdEntry="ownStorehouseIdEntry" > |
453 |
</neb:Sub> |
</neb:Sub> |
|
<!-- stockByInvoice="stockByInvoice" --> |
|
|
|
|
|
<!-- # de remito --> |
|
|
<!-- <block name="ownPosDocumentBlock" datasource="ownPosDocumentDataSource"> --> |
|
|
<!-- <label name="dateLabel" text="Número de Remito:" --> |
|
|
<!-- x="32" y="1"/> --> |
|
|
<!-- <entry name="documentNumberEntry" field="_own_pos_document_data.number" style="label" --> |
|
|
<!-- x="55" y="1" width="15"/> --> |
|
|
<!-- <entry name="documentTypeEntry" field="_own_pos_document_data.document_type" hidden="" --> |
|
|
<!-- x="50" y="1" width="15"/> --> |
|
|
<!-- <entry name="own_posEntry" field="_own_pos_document_data.own_pos" hidden="" --> |
|
|
<!-- x="50" y="1" width="15"/> --> |
|
|
<!-- <entry name="documentPrintCommand" field="_own_pos_document_data.print_command" hidden="" --> |
|
|
<!-- x="50" y="1" width="15"/> --> |
|
|
<!-- </block> --> |
|
|
|
|
454 |
</box> |
</box> |
455 |
|
|
456 |
<!-- ******************************** --> |
<!-- ******************************** --> |
459 |
|
|
460 |
<!-- Datasource que sirve para la búsqueda del producto --> |
<!-- Datasource que sirve para la búsqueda del producto --> |
461 |
<datasource database="papo" name="priceTypeDataSource" table="_price_type_data"> |
<datasource database="papo" name="priceTypeDataSource" table="_price_type_data"> |
462 |
<condition> |
<condition> |
463 |
<null> |
<null> |
464 |
<cfield name="_price_type_data._end_t"/> |
<cfield name="_price_type_data._end_t"/> |
465 |
</null> |
</null> |
466 |
</condition> |
</condition> |
467 |
</datasource> |
</datasource> |
468 |
<!-- Bloque que sirve para la búsqueda del producto respetando lista de precios --> |
<!-- Bloque que sirve para la búsqueda del producto respetando lista de precios --> |
469 |
<block name="priceTypeBlock" datasource="priceTypeDataSource" transparentBlock=""> |
<block name="priceTypeBlock" datasource="priceTypeDataSource" transparentBlock=""> |
470 |
<entry name="priceTypeParentId" field="parent" x="1" |
<entry name="priceTypeParentId" field="parent" x="1" |
471 |
y="2" width="40" hidden=""/> |
y="2" width="40" hidden=""/> |
472 |
<entry name="priceTypeId" field="_table" x="40" y="2" width="10" hidden="" /> |
<entry name="priceTypeId" field="_table" x="40" y="2" width="10" hidden="" /> |
473 |
</block> |
</block> |
474 |
<!-- Datasource que sirve para almacenar el resultado de la búsqueda --> |
<!-- Datasource que sirve para almacenar el resultado de la búsqueda --> |
479 |
<condition> |
<condition> |
480 |
<and> |
<and> |
481 |
<null> |
<null> |
482 |
<cfield name="_product_code_type_data._end_t"/> |
<cfield name="_product_code_type_data._end_t"/> |
483 |
</null> |
</null> |
484 |
<null> |
<null> |
485 |
<cfield name="_product_code_data._end_t"/> |
<cfield name="_product_code_data._end_t"/> |
486 |
</null> |
</null> |
487 |
<null> |
<null> |
488 |
<cfield name="_product_data._end_t"/> |
<cfield name="_product_data._end_t"/> |
489 |
</null> |
</null> |
490 |
<null> |
<null> |
491 |
<cfield name="_product_tax_data._end_t"/> |
|
492 |
|
<cfield name="_product_tax_data._end_t"/> |
493 |
</null> |
</null> |
494 |
<null> |
<null> |
495 |
<cfield name="_price_data._end_t"/> |
<cfield name="_price_data._end_t"/> |
678 |
<entry field="own_item.own_document" name="ownDocumentEntry" hidden="" x="1" y="1"/> |
<entry field="own_item.own_document" name="ownDocumentEntry" hidden="" x="1" y="1"/> |
679 |
|
|
680 |
<label name="qtyLbl" text="Cantidad" x="45" y="10"/> |
<label name="qtyLbl" text="Cantidad" x="45" y="10"/> |
|
<!-- mdione's bookmark --> |
|
681 |
<entry field="own_product_item.qty" name="qtyEntry" rows="10" typecast="number" displaymask="%0.3f" width="11" x="45" y="11"> |
<entry field="own_product_item.qty" name="qtyEntry" rows="10" typecast="number" displaymask="%0.3f" width="11" x="45" y="11"> |
682 |
<trigger name="qtyEntryPreFocusout" type="PRE-FOCUSOUT" src="totalCalcTrigger" /> |
<trigger name="qtyEntryPreFocusout" type="PRE-FOCUSOUT" src="totalCalcTrigger" /> |
683 |
</entry> |
</entry> |
684 |
|
|
685 |
<label name="priceLbl" text="Precio" x="56" y="10"/> |
<label name="priceLbl" text="Precio" x="56" y="10"/> |
687 |
<trigger name="unitPriceEntryPreFocusout" type="PRE-FOCUSOUT" src="totalCalcTrigger" /> |
<trigger name="unitPriceEntryPreFocusout" type="PRE-FOCUSOUT" src="totalCalcTrigger" /> |
688 |
</entry> |
</entry> |
689 |
<entry x="1" y="14" readonly="" field="own_product_item.price" name="priceEntry" width="10" rows="5" hidden=""/> |
<entry x="1" y="14" readonly="" field="own_product_item.price" name="priceEntry" width="10" rows="5" hidden=""/> |
690 |
<entry x="1" y="14" readonly="" field="own_item_tax.tax" name="taxTypeEntry" width="10" rows="5" default="1" hidden="" typecast="number" displaymask="%0.2f"/> |
<entry x="1" y="14" readonly="" field="own_item_tax.tax" name="taxTypeEntry" width="10" rows="5" default="1" hidden="" typecast="number"/> |
691 |
<entry x="1" y="14" readonly="" field="own_item_tax.amount" name="taxAmountEntry" width="10" rows="5" hidden="" typecast="number" displaymask="%0.2f"/> |
<entry x="1" y="14" readonly="" field="own_item_tax.amount" name="taxAmountEntry" width="10" rows="5" hidden="" typecast="number"/> |
|
|
|
692 |
|
|
693 |
<label name="ivaLbl" text="IVA" x="66" y="10"/> |
<label name="ivaLbl" text="IVA" x="66" y="10"/> |
694 |
<entry name="ivaEntry" displaymask="%0.0f" |
<entry name="ivaEntry" displaymask="%0.0f" |