|
|
@@ -27,6 +27,8 @@ import com.uas.search.b2b.model.MultiValue;
|
|
|
import com.uas.search.b2b.model.Sort;
|
|
|
import com.uas.search.b2b.util.SearchConstants;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.http.HttpStatus;
|
|
|
+import org.springframework.http.ResponseEntity;
|
|
|
import org.springframework.stereotype.Controller;
|
|
|
import org.springframework.ui.ModelMap;
|
|
|
import org.springframework.util.StringUtils;
|
|
|
@@ -503,7 +505,7 @@ public class SaleController {
|
|
|
* @return
|
|
|
*/
|
|
|
@RequestMapping(value = "/reply")
|
|
|
- public ModelMap replyOrderItem(String json) throws UnsupportedEncodingException {
|
|
|
+ public ResponseEntity<String> replyOrderItem(String json) throws UnsupportedEncodingException {
|
|
|
List<OrderReply> orderReplies = FlexJsonUtils.fromJsonArray(URLDecoder.decode(json, "utf-8"), OrderReply.class);
|
|
|
for (OrderReply orderReply : orderReplies) {
|
|
|
Long pdId = orderReply.getPdId();
|
|
|
@@ -515,7 +517,7 @@ public class SaleController {
|
|
|
logger.log("客户采购单", "App回复单个客户采购单明细", reply.replyDescription(), reply.getOrderItem().getOrder().getCode(),
|
|
|
item.getId());
|
|
|
}
|
|
|
- return new ModelMap("success", "true");
|
|
|
+ return new ResponseEntity<String>(HttpStatus.OK);
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
@@ -525,13 +527,13 @@ public class SaleController {
|
|
|
* @return
|
|
|
*/
|
|
|
@RequestMapping(value = "/items/reply", method = RequestMethod.POST)
|
|
|
- public ModelMap replyOrderItems(Long date, @RequestBody String idString) {
|
|
|
+ public ResponseEntity<String> replyOrderItems(Long date, @RequestBody String idString) {
|
|
|
List<PurchaseOrderReply> replies = purchaseOrderService.reply(idString.split(","), date);
|
|
|
for (PurchaseOrderReply reply : replies)
|
|
|
logger.log("客户采购单", "批量回复客户采购明细", reply.replyDescription(), reply.getOrderItem().getOrder().getCode(),
|
|
|
reply.getOrderItem().getId());
|
|
|
// purchaseOrderService.replyByBatch(idString, SystemSession.getUser().getUserName(), SystemSession.getUser().getIp(), SystemSession.getUser().getEnterprise().getUu(), SystemSession.getUser().getUserUU());
|
|
|
- return new ModelMap("success", "true");
|
|
|
+ return new ResponseEntity<String>(HttpStatus.OK);
|
|
|
}
|
|
|
|
|
|
/**
|