void crear_calidad(ProdJournalRoute ProdJournalRoute )
{
InventQualityOrderTable InventQualityOrderTable;
ProdTable ProdTable;
//ProdJournalRoute ProdJournalRoute;
FormDataSource fds;
NumberSequenceCode NumberSequenceCode;
NumberSeq NumberSeq;
TubOperPruebas TubOperPruebas;
NumberSeqFormHandler NumberSeqFormHandler;//=NumberSeqFormHandler::construct();
Args args;
FormRun formRun;
;
ttsbegin;
NumberSeq=NumberSeq::newGetNum( NumberSeqReference::findReference(typeId2ExtendedTypeId(typeid(InventQualityOrderId))));
ProdTable=ProdJournalRoute.prodTable();
InventQualityOrderTable.initValue();
InventQualityOrderTable.initFromProdTable(ProdTable);
InventQualityOrderTable.initFromReferenceBuffer(ProdJournalRoute.prodRoute());
InventQualityOrderTable.QualityOrderId=NumberSeq.num();
InventQualityOrderTable.Qty=ProdJournalRoute.QtyGood;
TubOperPruebas =TubOperPruebas::find(InventQualityOrderTable.RouteOprId);
if(!TubOperPruebas)
{
throw(InventQualityOrderTable.RouteOprId+" no encuentra grupo de test");
}
InventQualityOrderTable.TestGroupId=TubOperPruebas.TestGroupId;
InventQualityOrderTable.insert();
ttscommit;
/////////////////////abrir pantalla/////////////7
args = new Args();
args.name(formStr("InventQualityOrderTable")); //form SysBoxForm is used to show the message
formRun = classFactory.formRunClass(args); //creating a FormRun object
args.record(InventQualityOrderTable); // as argument is optional
formRun.init();
formRun.run();
formRun.wait(); //waiting for user action
///////////////////////////////////////
}
No hay comentarios:
Publicar un comentario