|
@ -616,6 +616,12 @@ public class MedicineOrderService extends BaseJpaService<Mediicineorder, Mediici
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 出货后,更新订单出货单状态 1未出货,2已出货,3出货故障
|
|
|
|
* @param shipmentLogId
|
|
|
|
* @param status
|
|
|
|
* @return
|
|
|
|
*/
|
|
public JSONObject updateOrderOutStatus(String shipmentLogId, String status) {
|
|
public JSONObject updateOrderOutStatus(String shipmentLogId, String status) {
|
|
JSONObject result = new JSONObject();
|
|
JSONObject result = new JSONObject();
|
|
if (shipmentLogId == null || StringUtils.isEmpty(shipmentLogId)) {
|
|
if (shipmentLogId == null || StringUtils.isEmpty(shipmentLogId)) {
|
|
@ -648,7 +654,14 @@ public class MedicineOrderService extends BaseJpaService<Mediicineorder, Mediici
|
|
medicineShipmentLog.getLayerNo(),
|
|
medicineShipmentLog.getLayerNo(),
|
|
medicineShipmentLog.getWayerNo());
|
|
medicineShipmentLog.getWayerNo());
|
|
inventory.setQty(String.valueOf(Integer.parseInt(inventory.getQty()) - 1));
|
|
inventory.setQty(String.valueOf(Integer.parseInt(inventory.getQty()) - 1));
|
|
|
|
if (Integer.parseInt(inventory.getQty()) < Integer.parseInt(inventory.getNum())) {
|
|
|
|
Mediicinedevice mediicinedevice = deviceDao.findOne(inventory.getIdDevice());
|
|
|
|
//0缺货,1不缺货
|
|
|
|
mediicinedevice.setStatus("0");
|
|
|
|
deviceDao.save(mediicinedevice);
|
|
|
|
}
|
|
inventoryDao.save(inventory);
|
|
inventoryDao.save(inventory);
|
|
|
|
|
|
}
|
|
}
|
|
//查询更新订单信息start
|
|
//查询更新订单信息start
|
|
//订单id
|
|
//订单id
|