![]() |
#10 |
Участник
|
Цитата:
X++: ... while (mEnum.moveNext()) { receipt = mEnum.currentValue(); inventTransKey = inventCostItemDim::keyAdjust2String(receipt.inventTransId,receipt.inventTransIdReturn,receipt.voucher); financialOpenQty = mapInventTransIdQty.lookup(inventTransKey); // dyol 17.08.2009 OK000754 --> //sortReceiptKey = InventCostItemDim::qtyRecId2String(mapInventTransIdQty.lookup(inventTransKey) / mapInventTransIdTotal.lookup(inventTransKey)*exp10(9), receipt.recId); sortReceiptKey = InventCostItemDim::qtyRecId2String_OK(mapInventTransIdQty.lookup(inventTransKey) / mapInventTransIdTotal.lookup(inventTransKey)*exp10(9), receipt.recId, receipt.DateFinancial); // dyol 17.08.2009 OK000754 <-- mapSortedReceipt.insert(sortReceiptKey,receipt); mapInventTransIdQty.insert(inventTransKey, financialOpenQty+receipt.financialOpenQty()); } ... X++: // dyol 17.08.2009 OK000754 --> static str qtyRecId2String_OK(Real _qty, Recid _recId, TransDate _transDate) { str qtyStr; str recIdStr; str key; qtyStr = int2str(trunc(_qty)); recIdStr = int2str(abs(_recId)); if (_recId < 0) key = strrep('0',20-strlen(qtyStr))+qtyStr + date2str(_transDate, 321, 2, 0, 2, 0, 4) + '#-' + strrep('0',15-strlen(recIdStr))+recIdStr; else key = strrep('0',20-strlen(qtyStr))+qtyStr + date2str(_transDate, 321, 2, 0, 2, 0, 4) + '#0' + strrep('0',15-strlen(recIdStr))+recIdStr; return key; } // dyol 17.08.2009 OK000754 <-- Последний раз редактировалось Bega; 28.11.2011 в 11:33. |
|
|
За это сообщение автора поблагодарили: DreamCreator (2). |