| Line 40... |
Line 40... |
| 40 |
|
40 |
|
| 41 |
@Controller
|
41 |
@Controller
|
| 42 |
@Transactional(rollbackFor = Throwable.class)
|
42 |
@Transactional(rollbackFor = Throwable.class)
|
| 43 |
public class SupplierController {
|
43 |
public class SupplierController {
|
| 44 |
|
44 |
|
| 45 |
@Autowired
|
45 |
@Autowired
|
| 46 |
private SupplierRepository supplierRepository;
|
46 |
private SupplierRepository supplierRepository;
|
| 47 |
|
47 |
|
| 48 |
@Autowired
|
48 |
@Autowired
|
| 49 |
private MVCResponseSender mvcResponseSender;
|
49 |
private MVCResponseSender mvcResponseSender;
|
| 50 |
@Autowired
|
- |
|
| 51 |
private WarehouseRepository warehouseRepository;
|
- |
|
| 52 |
|
50 |
|
| 53 |
@Autowired
|
- |
|
| 54 |
private SellerRepository sellerRepository;
|
- |
|
| 55 |
|
51 |
|
| 56 |
@Autowired
|
52 |
@Autowired
|
| 57 |
private WarehouseService warehouseService;
|
53 |
private SellerRepository sellerRepository;
|
| 58 |
|
54 |
|
| 59 |
@Autowired
|
55 |
@Autowired
|
| 60 |
private SellerWarehouseRepository sellerWarehouseRepository;
|
56 |
private WarehouseService warehouseService;
|
| 61 |
|
57 |
|
| 62 |
@Autowired
|
58 |
@Autowired
|
| 63 |
private VendorRepository vendorRepository;
|
59 |
private SellerWarehouseRepository sellerWarehouseRepository;
|
| 64 |
|
60 |
|
| 65 |
@Autowired
|
61 |
@Autowired
|
| 66 |
private WareHouseAddressMappingRepository wareHouseAddressMappingRepository;
|
62 |
private VendorRepository vendorRepository;
|
| 67 |
|
63 |
|
| 68 |
@Autowired
|
64 |
@Autowired
|
| 69 |
private WareHouseAddressMasterRepository WareHouseAddressMasterRepository;
|
65 |
private WareHouseAddressMappingRepository wareHouseAddressMappingRepository;
|
| 70 |
|
66 |
|
| 71 |
@Autowired
|
67 |
@Autowired
|
| 72 |
private StateRepository stateRepository;
|
68 |
private WareHouseAddressMasterRepository WareHouseAddressMasterRepository;
|
| 73 |
|
69 |
|
| - |
|
70 |
@Autowired
|
| 74 |
private static final Logger LOGGER = LogManager.getLogger(SupplierController.class);
|
71 |
private StateRepository stateRepository;
|
| 75 |
|
72 |
|
| 76 |
@RequestMapping(value = "/getAllSupplier", method = RequestMethod.GET)
|
73 |
private static final Logger LOGGER = LogManager.getLogger(SupplierController.class);
|
| 77 |
public String getShowSupplier(HttpServletRequest request, Model model) throws Exception {
|
- |
|
| 78 |
|
74 |
|
| 79 |
List<Supplier> supplierAcvtives = supplierRepository.selectByStatus(true);
|
75 |
@RequestMapping(value = "/getAllSupplier", method = RequestMethod.GET)
|
| - |
|
76 |
public String getShowSupplier(HttpServletRequest request, Model model) throws Exception {
|
| 80 |
|
77 |
|
| 81 |
List<SellerWarehouse> sellerWarehouses = supplierRepository.selectAll();
|
78 |
List<Supplier> supplierAcvtives = supplierRepository.selectByStatus(true);
|
| 82 |
List<Integer> sellerwarehouseIds = sellerWarehouses.stream().map(x -> x.getWarehouseId())
|
- |
|
| 83 |
.collect(Collectors.toList());
|
- |
|
| 84 |
LOGGER.info("sellerWarehouses" + sellerWarehouses);
|
- |
|
| 85 |
Map<Integer, WarehouseIdPrefixModel> warehouseIdAndState = new HashMap<>();
|
- |
|
| 86 |
|
79 |
|
| - |
|
80 |
List<SellerWarehouse> sellerWarehouses = sellerWarehouseRepository.selectAll();
|
| - |
|
81 |
List<Integer> sellerwarehouseIds = sellerWarehouses.stream().map(x -> x.getWarehouseId()).collect(Collectors.toList());
|
| 87 |
for (SellerWarehouse sw : sellerWarehouses) {
|
82 |
LOGGER.info("sellerWarehouses" + sellerWarehouses);
|
| - |
|
83 |
Map<Integer, WarehouseIdPrefixModel> warehouseIdAndState = new HashMap<>();
|
| 88 |
|
84 |
|
| 89 |
WarehouseAddressMapping warehouseAddressMapping = wareHouseAddressMappingRepository
|
- |
|
| 90 |
.selectByWarehouseId(sw.getWarehouseId());
|
85 |
for (SellerWarehouse sw : sellerWarehouses) {
|
| 91 |
LOGGER.info("warehouseAddressMapping" + warehouseAddressMapping);
|
- |
|
| 92 |
if (warehouseAddressMapping != null) {
|
- |
|
| 93 |
WarehouseAddressMaster WarehouseAddressMaster = WareHouseAddressMasterRepository
|
- |
|
| 94 |
.selectById(warehouseAddressMapping.getAddressId());
|
- |
|
| 95 |
LOGGER.info("warehouseAddressMappingAddreesId" + warehouseAddressMapping.getAddressId());
|
- |
|
| 96 |
LOGGER.info("WarehouseAddressMaster" + WarehouseAddressMaster);
|
- |
|
| 97 |
State state = stateRepository.selectById(WarehouseAddressMaster.getStateId());
|
- |
|
| 98 |
WarehouseIdPrefixModel wp = new WarehouseIdPrefixModel();
|
- |
|
| 99 |
wp.setPrefix(sw.getPrefix());
|
- |
|
| 100 |
wp.setStateName(state.getName());
|
- |
|
| 101 |
warehouseIdAndState.put(sw.getWarehouseId(), wp);
|
- |
|
| 102 |
LOGGER.info("state" + state);
|
- |
|
| 103 |
}
|
- |
|
| 104 |
}
|
- |
|
| 105 |
LOGGER.info("warehouseIdAndState" + warehouseIdAndState);
|
- |
|
| 106 |
model.addAttribute("warehouseIdAndState", warehouseIdAndState);
|
- |
|
| 107 |
|
86 |
|
| - |
|
87 |
WarehouseAddressMapping warehouseAddressMapping = wareHouseAddressMappingRepository.selectByWarehouseId(sw.getWarehouseId());
|
| - |
|
88 |
LOGGER.info("warehouseAddressMapping" + warehouseAddressMapping);
|
| - |
|
89 |
if (warehouseAddressMapping != null) {
|
| - |
|
90 |
WarehouseAddressMaster WarehouseAddressMaster = WareHouseAddressMasterRepository.selectById(warehouseAddressMapping.getAddressId());
|
| - |
|
91 |
LOGGER.info("warehouseAddressMappingAddreesId" + warehouseAddressMapping.getAddressId());
|
| - |
|
92 |
LOGGER.info("WarehouseAddressMaster" + WarehouseAddressMaster);
|
| 108 |
List<State> state = supplierRepository.selectByIdStateMaster();
|
93 |
State state = stateRepository.selectById(WarehouseAddressMaster.getStateId());
|
| - |
|
94 |
WarehouseIdPrefixModel wp = new WarehouseIdPrefixModel();
|
| - |
|
95 |
wp.setPrefix(sw.getPrefix());
|
| - |
|
96 |
wp.setStateName(state.getName());
|
| - |
|
97 |
warehouseIdAndState.put(sw.getWarehouseId(), wp);
|
| - |
|
98 |
LOGGER.info("state" + state);
|
| - |
|
99 |
}
|
| - |
|
100 |
}
|
| - |
|
101 |
LOGGER.info("warehouseIdAndState" + warehouseIdAndState);
|
| - |
|
102 |
model.addAttribute("warehouseIdAndState", warehouseIdAndState);
|
| 109 |
|
103 |
|
| 110 |
model.addAttribute("suppliers", supplierAcvtives);
|
104 |
List<State> state = stateRepository.selectAll();
|
| 111 |
model.addAttribute("state", state);
|
- |
|
| 112 |
|
105 |
|
| 113 |
return "supplier";
|
106 |
model.addAttribute("suppliers", supplierAcvtives);
|
| - |
|
107 |
model.addAttribute("state", state);
|
| 114 |
|
108 |
|
| 115 |
}
|
- |
|
| - |
|
109 |
return "supplier";
|
| 116 |
|
110 |
|
| 117 |
@RequestMapping(value = "/getAllInActiveSupplier", method = RequestMethod.GET)
|
- |
|
| 118 |
public String getShowInActiveSupplier(HttpServletRequest request, Model model) throws Exception {
|
- |
|
| - |
|
111 |
}
|
| 119 |
|
112 |
|
| 120 |
List<Supplier> supplierInactives = supplierRepository.selectByStatus(false);
|
113 |
@RequestMapping(value = "/getAllInActiveSupplier", method = RequestMethod.GET)
|
| - |
|
114 |
public String getShowInActiveSupplier(HttpServletRequest request, Model model) throws Exception {
|
| 121 |
|
115 |
|
| 122 |
model.addAttribute("supplierInactives", supplierInactives);
|
116 |
List<Supplier> supplierInactives = supplierRepository.selectByStatus(false);
|
| 123 |
|
117 |
|
| 124 |
LOGGER.info("supplierInactives" + supplierInactives);
|
118 |
model.addAttribute("supplierInactives", supplierInactives);
|
| 125 |
|
119 |
|
| 126 |
return "supplier-in-active";
|
120 |
LOGGER.info("supplierInactives" + supplierInactives);
|
| 127 |
|
121 |
|
| 128 |
}
|
- |
|
| - |
|
122 |
return "supplier-in-active";
|
| 129 |
|
123 |
|
| 130 |
@RequestMapping(value = "/getCreateNewSupplier", method = RequestMethod.GET)
|
- |
|
| 131 |
public String getCreateNewSupplier(HttpServletRequest request, Model model) throws Exception {
|
- |
|
| - |
|
124 |
}
|
| 132 |
|
125 |
|
| 133 |
List<SellerWarehouse> sellerWarehouses = supplierRepository.selectAll();
|
126 |
@RequestMapping(value = "/getCreateNewSupplier", method = RequestMethod.GET)
|
| 134 |
List<Integer> sellerwarehouseIds = sellerWarehouses.stream().map(x -> x.getWarehouseId())
|
127 |
public String getCreateNewSupplier(HttpServletRequest request, Model model) throws Exception {
|
| 135 |
.collect(Collectors.toList());
|
- |
|
| 136 |
LOGGER.info("sellerWarehouses" + sellerWarehouses);
|
- |
|
| 137 |
Map<Integer, WarehouseIdPrefixModel> warehouseIdAndState = new HashMap<>();
|
- |
|
| 138 |
|
128 |
|
| - |
|
129 |
List<SellerWarehouse> sellerWarehouses = sellerWarehouseRepository.selectAll();
|
| - |
|
130 |
List<Integer> sellerwarehouseIds = sellerWarehouses.stream().map(x -> x.getWarehouseId()).collect(Collectors.toList());
|
| 139 |
for (SellerWarehouse sw : sellerWarehouses) {
|
131 |
LOGGER.info("sellerWarehouses" + sellerWarehouses);
|
| - |
|
132 |
Map<Integer, WarehouseIdPrefixModel> warehouseIdAndState = new HashMap<>();
|
| 140 |
|
133 |
|
| 141 |
WarehouseAddressMapping warehouseAddressMapping = wareHouseAddressMappingRepository
|
- |
|
| 142 |
.selectByWarehouseId(sw.getWarehouseId());
|
134 |
for (SellerWarehouse sw : sellerWarehouses) {
|
| 143 |
LOGGER.info("warehouseAddressMapping" + warehouseAddressMapping);
|
- |
|
| 144 |
if (warehouseAddressMapping != null) {
|
- |
|
| 145 |
WarehouseAddressMaster WarehouseAddressMaster = WareHouseAddressMasterRepository
|
- |
|
| 146 |
.selectById(warehouseAddressMapping.getAddressId());
|
- |
|
| 147 |
LOGGER.info("warehouseAddressMappingAddreesId" + warehouseAddressMapping.getAddressId());
|
- |
|
| 148 |
LOGGER.info("WarehouseAddressMaster" + WarehouseAddressMaster);
|
- |
|
| 149 |
State state = stateRepository.selectById(WarehouseAddressMaster.getStateId());
|
- |
|
| 150 |
WarehouseIdPrefixModel wp = new WarehouseIdPrefixModel();
|
- |
|
| 151 |
wp.setPrefix(sw.getPrefix());
|
- |
|
| 152 |
wp.setStateName(state.getName());
|
- |
|
| 153 |
warehouseIdAndState.put(sw.getWarehouseId(), wp);
|
- |
|
| 154 |
LOGGER.info("state" + state);
|
- |
|
| 155 |
}
|
- |
|
| 156 |
}
|
- |
|
| 157 |
LOGGER.info("warehouseIdAndState" + warehouseIdAndState);
|
- |
|
| 158 |
model.addAttribute("warehouseIdAndState", warehouseIdAndState);
|
- |
|
| 159 |
|
135 |
|
| - |
|
136 |
WarehouseAddressMapping warehouseAddressMapping = wareHouseAddressMappingRepository.selectByWarehouseId(sw.getWarehouseId());
|
| - |
|
137 |
LOGGER.info("warehouseAddressMapping" + warehouseAddressMapping);
|
| - |
|
138 |
if (warehouseAddressMapping != null) {
|
| - |
|
139 |
WarehouseAddressMaster WarehouseAddressMaster = WareHouseAddressMasterRepository.selectById(warehouseAddressMapping.getAddressId());
|
| - |
|
140 |
LOGGER.info("warehouseAddressMappingAddreesId" + warehouseAddressMapping.getAddressId());
|
| - |
|
141 |
LOGGER.info("WarehouseAddressMaster" + WarehouseAddressMaster);
|
| 160 |
List<State> state = supplierRepository.selectByIdStateMaster();
|
142 |
State state = stateRepository.selectById(WarehouseAddressMaster.getStateId());
|
| - |
|
143 |
WarehouseIdPrefixModel wp = new WarehouseIdPrefixModel();
|
| - |
|
144 |
wp.setPrefix(sw.getPrefix());
|
| - |
|
145 |
wp.setStateName(state.getName());
|
| - |
|
146 |
warehouseIdAndState.put(sw.getWarehouseId(), wp);
|
| - |
|
147 |
LOGGER.info("state" + state);
|
| - |
|
148 |
}
|
| - |
|
149 |
}
|
| - |
|
150 |
LOGGER.info("warehouseIdAndState" + warehouseIdAndState);
|
| - |
|
151 |
model.addAttribute("warehouseIdAndState", warehouseIdAndState);
|
| 161 |
|
152 |
|
| 162 |
model.addAttribute("state", state);
|
153 |
List<State> state = stateRepository.selectAll();
|
| 163 |
|
154 |
|
| 164 |
return "new-supplier";
|
155 |
model.addAttribute("state", state);
|
| 165 |
}
|
- |
|
| 166 |
|
156 |
|
| 167 |
@RequestMapping(value = "/setStatusInActive", method = RequestMethod.POST)
|
- |
|
| 168 |
public String setInActiveSupplier(HttpServletRequest request,
|
157 |
return "new-supplier";
|
| 169 |
@RequestParam(name = "id", required = true, defaultValue = "0") int id, Model model) throws Exception {
|
- |
|
| - |
|
158 |
}
|
| 170 |
|
159 |
|
| 171 |
Supplier supplier = supplierRepository.selectById(id);
|
160 |
@RequestMapping(value = "/setStatusInActive", method = RequestMethod.POST)
|
| - |
|
161 |
public String setInActiveSupplier(HttpServletRequest request, @RequestParam(name = "id", required = true, defaultValue = "0") int id, Model model) throws Exception {
|
| 172 |
|
162 |
|
| 173 |
supplier.setStatus(false);
|
163 |
Supplier supplier = supplierRepository.selectById(id);
|
| 174 |
|
164 |
|
| 175 |
model.addAttribute("response1", mvcResponseSender.createResponseString(true));
|
165 |
supplier.setStatus(false);
|
| 176 |
|
166 |
|
| 177 |
return "response";
|
167 |
model.addAttribute("response1", mvcResponseSender.createResponseString(true));
|
| 178 |
}
|
- |
|
| 179 |
|
168 |
|
| 180 |
@RequestMapping(value = "/setStatusActive", method = RequestMethod.POST)
|
- |
|
| 181 |
public String setActiveSupplier(HttpServletRequest request,
|
169 |
return "response";
|
| 182 |
@RequestParam(name = "id", required = true, defaultValue = "0") int id, Model model) throws Exception {
|
- |
|
| - |
|
170 |
}
|
| 183 |
|
171 |
|
| 184 |
Supplier supplier = supplierRepository.selectById(id);
|
172 |
@RequestMapping(value = "/setStatusActive", method = RequestMethod.POST)
|
| - |
|
173 |
public String setActiveSupplier(HttpServletRequest request, @RequestParam(name = "id", required = true, defaultValue = "0") int id, Model model) throws Exception {
|
| 185 |
|
174 |
|
| 186 |
supplier.setStatus(true);
|
175 |
Supplier supplier = supplierRepository.selectById(id);
|
| 187 |
|
176 |
|
| 188 |
model.addAttribute("response1", mvcResponseSender.createResponseString(true));
|
177 |
supplier.setStatus(true);
|
| 189 |
|
178 |
|
| 190 |
return "response";
|
179 |
model.addAttribute("response1", mvcResponseSender.createResponseString(true));
|
| 191 |
|
180 |
|
| 192 |
}
|
- |
|
| - |
|
181 |
return "response";
|
| 193 |
|
182 |
|
| 194 |
@RequestMapping(value = "/submitNewSupplier", method = RequestMethod.POST)
|
- |
|
| 195 |
public String getCreateNewSupplier(HttpServletRequest request, @RequestBody CreateNewSupplier createNewSupplier,
|
- |
|
| 196 |
Model model) throws Exception {
|
183 |
}
|
| 197 |
|
184 |
|
| 198 |
Supplier supplier = new Supplier();
|
185 |
@RequestMapping(value = "/submitNewSupplier", method = RequestMethod.POST)
|
| - |
|
186 |
public String getCreateNewSupplier(HttpServletRequest request, @RequestBody CreateNewSupplier createNewSupplier, Model model) throws Exception {
|
| 199 |
|
187 |
|
| 200 |
supplier.setName(createNewSupplier.getName());
|
- |
|
| 201 |
supplier.setCommunicationAddress(createNewSupplier.getCommunicationAddress());
|
- |
|
| 202 |
supplier.setContactEmail(createNewSupplier.getContactEmail());
|
- |
|
| 203 |
supplier.setContactFax(createNewSupplier.getContactFax());
|
- |
|
| 204 |
supplier.setContactName(createNewSupplier.getContactPerson());
|
- |
|
| 205 |
supplier.setGstin(createNewSupplier.getGst());
|
- |
|
| 206 |
supplier.setHeadDesignation(createNewSupplier.getHeadDesign());
|
- |
|
| 207 |
supplier.setHeadEmail(createNewSupplier.getHeadEmail());
|
- |
|
| 208 |
supplier.setHeadName(createNewSupplier.getHeadName());
|
- |
|
| 209 |
supplier.setPan(createNewSupplier.getPan());
|
- |
|
| 210 |
supplier.setPhone(createNewSupplier.getPhone());
|
- |
|
| 211 |
supplier.setPoValidityLimit(createNewSupplier.getpOValidityLimit());
|
- |
|
| 212 |
supplier.setRegisteredAddress(createNewSupplier.getRegisteredAddress());
|
- |
|
| 213 |
supplier.setStateId(createNewSupplier.getState());
|
- |
|
| 214 |
supplierRepository.persist(supplier);
|
188 |
Supplier supplier = new Supplier();
|
| 215 |
|
189 |
|
| - |
|
190 |
supplier.setName(createNewSupplier.getName());
|
| - |
|
191 |
supplier.setCommunicationAddress(createNewSupplier.getCommunicationAddress());
|
| - |
|
192 |
supplier.setContactEmail(createNewSupplier.getContactEmail());
|
| - |
|
193 |
supplier.setContactFax(createNewSupplier.getContactFax());
|
| - |
|
194 |
supplier.setContactName(createNewSupplier.getContactPerson());
|
| 216 |
Vendor vendor = new Vendor();
|
195 |
supplier.setGstin(createNewSupplier.getGst());
|
| - |
|
196 |
supplier.setHeadDesignation(createNewSupplier.getHeadDesign());
|
| - |
|
197 |
supplier.setHeadEmail(createNewSupplier.getHeadEmail());
|
| 217 |
vendor.setName(supplier.getName());
|
198 |
supplier.setHeadName(createNewSupplier.getHeadName());
|
| 218 |
vendor.setId(supplier.getId());
|
199 |
supplier.setPan(createNewSupplier.getPan());
|
| 219 |
vendorRepository.persist(vendor);
|
200 |
supplier.setPhone(createNewSupplier.getPhone());
|
| - |
|
201 |
supplier.setPoValidityLimit(createNewSupplier.getpOValidityLimit());
|
| - |
|
202 |
supplier.setRegisteredAddress(createNewSupplier.getRegisteredAddress());
|
| 220 |
LOGGER.info("supplierId" + supplier.getId());
|
203 |
supplier.setStateId(createNewSupplier.getState());
|
| 221 |
LOGGER.info("vendorId" + vendor.getId());
|
204 |
supplierRepository.persist(supplier);
|
| 222 |
|
205 |
|
| - |
|
206 |
Vendor vendor = new Vendor();
|
| 223 |
List<WarehouseAddressMapping> warehouseAddressMappings = wareHouseAddressMappingRepository
|
207 |
vendor.setName(supplier.getName());
|
| 224 |
.selectAllByIds(createNewSupplier.getWarehouseId());
|
208 |
vendor.setId(supplier.getId());
|
| - |
|
209 |
vendorRepository.persist(vendor);
|
| - |
|
210 |
LOGGER.info("supplierId" + supplier.getId());
|
| 225 |
LOGGER.info("warehouseAddressMappings" + warehouseAddressMappings);
|
211 |
LOGGER.info("vendorId" + vendor.getId());
|
| 226 |
|
212 |
|
| 227 |
for (WarehouseAddressMapping wamp : warehouseAddressMappings) {
|
213 |
List<WarehouseAddressMapping> warehouseAddressMappings = wareHouseAddressMappingRepository.selectAllByIds(createNewSupplier.getWarehouseId());
|
| 228 |
List<SellerWarehouse> sellerWarehouse = sellerWarehouseRepository
|
- |
|
| 229 |
.selectBywarehouseId(wamp.getWarehouseId());
|
214 |
LOGGER.info("warehouseAddressMappings" + warehouseAddressMappings);
|
| 230 |
for (SellerWarehouse sw : sellerWarehouse) {
|
- |
|
| 231 |
Seller seller = sellerRepository.selectById(sw.getSellerId());
|
- |
|
| 232 |
|
215 |
|
| - |
|
216 |
for (WarehouseAddressMapping wamp : warehouseAddressMappings) {
|
| 233 |
WarehouseAddressMaster wam = WareHouseAddressMasterRepository.selectById(wamp.getAddressId());
|
217 |
List<SellerWarehouse> sellerWarehouse = sellerWarehouseRepository.selectBywarehouseId(wamp.getWarehouseId());
|
| - |
|
218 |
for (SellerWarehouse sw : sellerWarehouse) {
|
| - |
|
219 |
Seller seller = sellerRepository.selectById(sw.getSellerId());
|
| 234 |
|
220 |
|
| 235 |
// GOOD - WarehouseType.OURS, InventoryType.GOOD
|
- |
|
| 236 |
warehouseService.createVendorWarehouse(WarehouseType.OURS, InventoryType.GOOD, seller.getLabel(),
|
221 |
WarehouseAddressMaster wam = WareHouseAddressMasterRepository.selectById(wamp.getAddressId());
|
| 237 |
wamp.getWarehouseId(), wam, vendor.getId());
|
- |
|
| 238 |
|
222 |
|
| 239 |
// BAD - WarehouseType.OURS, InventoryType.BAD
|
223 |
// GOOD - WarehouseType.OURS, InventoryType.GOOD
|
| 240 |
warehouseService.createVendorWarehouse(WarehouseType.OURS, InventoryType.BAD, seller.getLabel(),
|
224 |
warehouseService.createVendorWarehouse(WarehouseType.OURS, InventoryType.GOOD, seller.getLabel(), wamp.getWarehouseId(), wam, vendor.getId());
|
| 241 |
wamp.getWarehouseId(), wam, vendor.getId());
|
- |
|
| 242 |
|
225 |
|
| 243 |
// VIRTUAL - WarehouseType.THIRD_PARTY, InventoryType.GOOD
|
226 |
// BAD - WarehouseType.OURS, InventoryType.BAD
|
| 244 |
warehouseService.createVendorWarehouse(WarehouseType.THIRD_PARTY, InventoryType.GOOD, seller.getLabel(),
|
227 |
warehouseService.createVendorWarehouse(WarehouseType.OURS, InventoryType.BAD, seller.getLabel(), wamp.getWarehouseId(), wam, vendor.getId());
|
| 245 |
wamp.getWarehouseId(), wam, 0);
|
- |
|
| 246 |
|
228 |
|
| 247 |
}
|
- |
|
| - |
|
229 |
// VIRTUAL - WarehouseType.THIRD_PARTY, InventoryType.GOOD
|
| - |
|
230 |
warehouseService.createVendorWarehouse(WarehouseType.THIRD_PARTY, InventoryType.GOOD, seller.getLabel(), wamp.getWarehouseId(), wam, 0);
|
| 248 |
|
231 |
|
| 249 |
}
|
232 |
}
|
| 250 |
|
233 |
|
| 251 |
return "new-supplier";
|
234 |
}
|
| 252 |
|
235 |
|
| - |
|
236 |
return "new-supplier";
|
| 253 |
}
|
237 |
|
| - |
|
238 |
}
|
| 254 |
}
|
239 |
}
|