private int getLeadTime(string salesOrg, CustomerDataProperty cm, ZV04HNProperty zv) { switch (salesOrg) { // case "RO01": case "ZA01": case "TR01": case "RU01": case "UA01": case "GR01": case "CZ01": case "PL01": case "IT01": { return(zv.route != "" ? int.Parse(Strings.Right(zv.route, 2)) : 0); } case "ES01": { var switchExpr = zv.route; switch (switchExpr) { case "ES0011": { return(1); } case "ES0000": { return(2); } case "ES0002": { return(3); } case "ES0003": { return(4); } case "ESTN05": { return(5); } case "ESGC05": { return(5); } default: { return(0); } } } default: { return(cm.leadTime); } } }
public RddOutputBean(ZV04HNProperty zv, CustomerDataProperty cm, string id) { soldTo = zv.soldto; soldToName = zv.soldtoName; shipTo = zv.shipto; shipToName = zv.shiptoName; oldRdd = zv.reqDelDate; orderNumber = zv.order; docTyp = zv.docTyp; salesOrg = cm.salesOrg.ToUpper(); country = cm.country.ToLower(); isRddChangeAllowed = cm.changeRDDActionAllowed; isRouteCodeChangeAllowed = cm.changeRouteCodeActionAllowed; deliveryDay = cm.deliveryDay; loadingDate = zv.loadingDate; route = zv.route; caseFillRate = zv.FillRate; isOneDayLeadTimeAllowed = cm.oneDayLeadTimeAllowed; leadTime = getLeadTime(salesOrg, cm, zv); region = cm.region; this.id = id; }
private GenericDistressProperty getDistressProperty(ZV04IProperty zvi, ZV04HNProperty zvh, ZV04PProperty zvp, CustomerDataProperty cd, SwitchesProperty sd, RejectionsProperty rd, MM03Property mm, CriticalItemsDataProperty ci, SkuDataProperty sku) { return(new GenericDistressProperty( orderStatus: zvh.status, country: cd.country ?? "", plant: zvi.plant, material: zvi.material, order: zvi.order, item: zvi.item, materialDescription: zvi.materialDescription, soldTo: zvi.soldTo, soldToName: zvi.soldToName, shipTo: zvi.shipTo, shipToName: zvi.shipToName, rejReason: zvi.rejReason, afterReleaseRej: (zvi.rejReason != "" ? "" : rd.rejectionReasonCode) ?? "", possibleSwitch: sd.newSku, possibleSwitchDescription: sd.newSkuDescription, deliveryBlock: zvi.delBlock, atp: default,
private static DeliveryBlocksProperty getDelBlockProperty(string id, ZV04HNProperty zvh, CustomerDataProperty cd) { return(new DeliveryBlocksProperty( id: id, orderStatus: zvh.status, salesOrg: cd.salesOrg, country: cd.country, orderNumber: zvh.order, poNumber: zvh.pONumber, soldTo: zvh.soldto, soldToName: zvh.soldtoName, shipTo: zvh.shipto, shipToName: zvh.shiptoName, currentDeliveryBlock: zvh.delBlock, newDeliveryBlock: null, currentQty: zvh.confirmedQty, minQty: cd.minimumOrderCaseQuantity, currentVal: zvh.ordNetValue, minVal: cd.minimumOrderValue, reason: null, customerEmails: cd.belowMOQandMOVEmails, poDate: zvh.pODate, rdd: zvh.reqDelDate )); }
private static DeliveryBlocksProperty getDelBlockProperty(string salesOrg, string id, ZV04HNProperty zv, CustomerDataProperty cd) { return(new DeliveryBlocksProperty( id: id, orderStatus: zv.status, salesOrg: salesOrg, country: cd.country, orderNumber: zv.order, poNumber: zv.pONumber, soldTo: zv.soldto, soldToName: zv.soldtoName, shipTo: zv.shipto, shipToName: zv.shiptoName, currentDeliveryBlock: zv.delBlock, newDeliveryBlock: IDAConsts.DelBlocks.noBlock, currentQty: default,
private RejectionsProperty getRejectionsPropertyObjs(ZV04IProperty zv, RejectionsDataProperty rd, CustomerDataProperty cd, string id) { return(new RejectionsProperty( salesOrg: cd.salesOrg, country: cd.country, soldTo: zv.soldTo, rejectionForCustomer: rd.soldTo == 0 ? "All" : "Speciffic", isReplacePartialCut: (cd.replaceObsoletePartialCutsAllowed && zv.confirmedQty > 0 && rd.needOutOfStockToReject), isDuringRelease: (zv.confirmedQty > 0), shipTo: zv.shipTo, shipToName: zv.shipToName, orderNumber: zv.order, item: zv.item, sku: rd.sku, rejectionReasonCode: rd.rejectionReasonCode.ToUpper(), orderedQty: zv.orderQty, confirmedQty: zv.confirmedQty, skuUnitBarcode: rd.skuUnitBarcode, skuCaseBarcode: rd.skuCaseBarcode, skuATP: default,
private SwitchesProperty getSwitchPropertyObjs(ZV04IProperty zv, SwitchesDataProperty sd, CustomerDataProperty cd, string id) { return(new SwitchesProperty(salesOrg: cd.salesOrg, country: cd.country, soldTo: zv.soldTo, switchForCustomer: sd.soldTo == 0 ? "All" : "Speciffic", shipTo: zv.shipTo, order: zv.order, shipToName: zv.shipToName, item: zv.item, orderedQty: zv.orderQty, confirmedQty: zv.confirmedQty, oldSku: sd.oldSku, oldSkuDescription: sd.oldSkuDescription, oldSkuCaseBarcode: sd.oldSkuCaseBarcode, oldSkuUnitBarcode: sd.oldSkuUnitBarcode, oldSkuATP: default,