Commit 376680f5750ace2e5704af0f4b64b8ae8b59eb2b

Authored by weiliwhereareyou@163.com
1 parent 5e1cef84

初始化工程-接口定义

mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/Order.java
@@ -2,6 +2,7 @@ package com.diligrp.mobsite.getway.domain.protocol; @@ -2,6 +2,7 @@ package com.diligrp.mobsite.getway.domain.protocol;
2 2
3 import com.diligrp.mobsite.getway.domain.protocol.order.model.MarketInfo; 3 import com.diligrp.mobsite.getway.domain.protocol.order.model.MarketInfo;
4 import com.diligrp.mobsite.getway.domain.protocol.order.model.OrderSumInfo; 4 import com.diligrp.mobsite.getway.domain.protocol.order.model.OrderSumInfo;
  5 +import io.swagger.annotations.ApiModelProperty;
5 6
6 import java.io.Serializable; 7 import java.io.Serializable;
7 import java.util.List; 8 import java.util.List;
@@ -26,51 +27,62 @@ public class Order extends OrderSumInfo implements Serializable{ @@ -26,51 +27,62 @@ public class Order extends OrderSumInfo implements Serializable{
26 */ 27 */
27 public static final int IS_COMMENTED_NO = 0; 28 public static final int IS_COMMENTED_NO = 0;
28 29
  30 +
29 /** 31 /**
30 - * 订单状态:(10待付款,20待备货,30备货中,40待提货,50已提货,60已过期,70已取消,80已申请退款,90已退款,100提货超时) 32 + * 订单状态:(10待接单,15已接单待付款,20待自提,25待送货,30接单已过期,35支付超时,40已拒绝,45已取消,50已完成)
31 */ 33 */
  34 + @ApiModelProperty(value = "订单状态:(10待接单,15已接单待付款,20待自提,25待送货,30接单已过期,35支付超时,40已拒绝,45已取消,50已完成) ")
32 private Integer orderState; 35 private Integer orderState;
33 36
34 /** 37 /**
35 * 订单状态名称 38 * 订单状态名称
36 */ 39 */
  40 + @ApiModelProperty(value = "订单状态名称")
37 private String stateName; 41 private String stateName;
38 42
39 /** 43 /**
40 * 支付方式 44 * 支付方式
41 */ 45 */
  46 + @ApiModelProperty(value = "支付方式:10-在线支付,20-线下支付")
42 private Integer payType; 47 private Integer payType;
43 /** 48 /**
44 * 总金额 49 * 总金额
45 */ 50 */
46 - private Long totalAmount; 51 + @ApiModelProperty(value = "商品总金额")
  52 + private Long totalAmount;
47 /** 53 /**
48 * 应付金额 54 * 应付金额
49 */ 55 */
  56 + @ApiModelProperty(value = "实际支付金额")
50 private Long realPayAmount; 57 private Long realPayAmount;
51 /** 58 /**
52 * 优惠金额 59 * 优惠金额
53 */ 60 */
  61 + @ApiModelProperty(value = "优惠金额")
54 private Long discountAmount; 62 private Long discountAmount;
55 /** 63 /**
56 * 邮费 64 * 邮费
57 */ 65 */
  66 + @ApiModelProperty(value = "运费")
58 private Long postage; 67 private Long postage;
59 /** 68 /**
60 * 提交订单时间 69 * 提交订单时间
61 */ 70 */
62 private Long submitTime; 71 private Long submitTime;
63 /** 72 /**
64 - * 订单提交日期格式化,后期需要去掉 73 + * 订单提交日期
65 */ 74 */
  75 + @ApiModelProperty(value = "订单提交时间")
66 private String submitDate; 76 private String submitDate;
67 /** 77 /**
68 * 订单详情页最上面 78 * 订单详情页最上面
69 */ 79 */
70 - private String orderDescription; 80 + @ApiModelProperty(value = "订单详情状态描述")
  81 + private String orderDesc;
71 /** 82 /**
72 * 是否评论 83 * 是否评论
73 */ 84 */
  85 + @ApiModelProperty(value = "是否评论")
74 private Integer isCommented; 86 private Integer isCommented;
75 /** 87 /**
76 * 卖家id 88 * 卖家id
@@ -196,505 +208,20 @@ public class Order extends OrderSumInfo implements Serializable{ @@ -196,505 +208,20 @@ public class Order extends OrderSumInfo implements Serializable{
196 private String shopSendAddress; 208 private String shopSendAddress;
197 209
198 210
199 - public String getSellerName() {  
200 - return sellerName;  
201 - }  
202 -  
203 - public void setSellerName(String sellerName) {  
204 - this.sellerName = sellerName;  
205 - }  
206 -  
207 - public String getSellerMobile() {  
208 - return sellerMobile;  
209 - }  
210 -  
211 - public void setSellerMobile(String sellerMobile) {  
212 - this.sellerMobile = sellerMobile;  
213 - }  
214 -  
215 - public String getShopSendAddress() {  
216 - return shopSendAddress;  
217 - }  
218 -  
219 - public void setShopSendAddress(String shopSendAddress) {  
220 - this.shopSendAddress = shopSendAddress;  
221 - }  
222 -  
223 - /**  
224 - * 订单商品总总量  
225 - */  
226 - private Long orderWeight;  
227 -  
228 - public Integer getDelayedPickupNum() {  
229 - return delayedPickupNum;  
230 - }  
231 -  
232 - public void setDelayedPickupNum(Integer delayedPickupNum) {  
233 - this.delayedPickupNum = delayedPickupNum;  
234 - }  
235 -  
236 - /**  
237 - * get value of Order.realPayAmount  
238 - *  
239 - * @return the realPayAmount  
240 - * @createTime 2014年9月1日 下午6:04:58  
241 - * @author zhangshirui  
242 - */  
243 - public Long getRealPayAmount() {  
244 - return realPayAmount;  
245 - }  
246 -  
247 - /**  
248 - * set value of Order.realPayAmount  
249 - *  
250 - * @param realPayAmount  
251 - * the realPayAmount to set  
252 - * @createTime 2014年9月1日 下午6:04:58  
253 - * @author zhangshirui  
254 - */  
255 - public void setRealPayAmount(Long realPayAmount) {  
256 - this.realPayAmount = realPayAmount;  
257 - }  
258 -  
259 - /**  
260 - * get value of Order.stateName  
261 - *  
262 - * @return the stateName  
263 - * @createTime 2014年9月3日 下午6:23:05  
264 - * @author zhangshirui  
265 - */  
266 - public String getStateName() {  
267 - return stateName;  
268 - }  
269 -  
270 - /**  
271 - * set value of Order.stateName  
272 - *  
273 - * @param stateName  
274 - * the stateName to set  
275 - * @createTime 2014年9月3日 下午6:23:05  
276 - * @author zhangshirui  
277 - */  
278 - public void setStateName(String stateName) {  
279 - this.stateName = stateName;  
280 - }  
281 -  
282 - /**  
283 - * @return the orderProducts  
284 - */  
285 - public List<OrderProduct> getOrderProducts() {  
286 - return orderProducts;  
287 - }  
288 -  
289 - /**  
290 - * @param orderProducts  
291 - * the orderProducts to set  
292 - */  
293 - public void setOrderProducts(List<OrderProduct> orderProducts) {  
294 - this.orderProducts = orderProducts;  
295 - }  
296 -  
297 - /**  
298 - * get value of Order.orderState  
299 - *  
300 - * @return the orderState  
301 - * @createTime 2014年10月13日 下午5:41:01  
302 - * @author zhangshirui  
303 - */  
304 - public Integer getOrderState() {  
305 - return orderState;  
306 - }  
307 -  
308 - /**  
309 - * set value of Order.orderState  
310 - *  
311 - * @param orderState  
312 - * the orderState to set  
313 - * @createTime 2014年10月13日 下午5:41:01  
314 - * @author zhangshirui  
315 - */  
316 - public void setOrderState(Integer orderState) {  
317 - this.orderState = orderState;  
318 - }  
319 -  
320 - /**  
321 - * get value of Order.shopName  
322 - *  
323 - * @return the shopName  
324 - * @createTime 2014年10月14日 下午4:42:05  
325 - * @author zhangshirui  
326 - */  
327 - public String getShopName() {  
328 - return shopName;  
329 - }  
330 -  
331 - /**  
332 - * set value of Order.shopName  
333 - *  
334 - * @param shopName  
335 - * the shopName to set  
336 - * @createTime 2014年10月14日 下午4:42:05  
337 - * @author zhangshirui  
338 - */  
339 - public void setShopName(String shopName) {  
340 - this.shopName = shopName;  
341 - }  
342 -  
343 - /**  
344 - * get value of Order.sellerId  
345 - *  
346 - * @return the sellerId  
347 - * @createTime 2014年10月14日 下午4:50:56  
348 - * @author zhangshirui  
349 - */  
350 - public Long getSellerId() {  
351 - return sellerId;  
352 - }  
353 -  
354 - /**  
355 - * set value of Order.sellerId  
356 - *  
357 - * @param sellerId  
358 - * the sellerId to set  
359 - * @createTime 2014年10月14日 下午4:50:56  
360 - * @author zhangshirui  
361 - */  
362 - public void setSellerId(Long sellerId) {  
363 - this.sellerId = sellerId;  
364 - }  
365 -  
366 - /**  
367 - * get value of Order.tradeCode  
368 - *  
369 - * @return the tradeCode  
370 - * @createTime 2014年10月15日 上午9:20:44  
371 - * @author zhangshirui  
372 - */  
373 - public String getTradeCode() {  
374 - return tradeCode;  
375 - }  
376 -  
377 - /**  
378 - * set value of Order.tradeCode  
379 - *  
380 - * @param tradeCode  
381 - * the tradeCode to set  
382 - * @createTime 2014年10月15日 上午9:20:44  
383 - * @author zhangshirui  
384 - */  
385 - public void setTradeCode(String tradeCode) {  
386 - this.tradeCode = tradeCode;  
387 - }  
388 -  
389 - /**  
390 - * get value of Order.payType  
391 - *  
392 - * @return the payType  
393 - * @createTime 2014年10月15日 上午10:43:45  
394 - * @author zhangshirui  
395 - */  
396 - public Integer getPayType() {  
397 - return payType;  
398 - }  
399 -  
400 - /**  
401 - * set value of Order.payType  
402 - *  
403 - * @param payType  
404 - * the payType to set  
405 - * @createTime 2014年10月15日 上午10:43:45  
406 - * @author zhangshirui  
407 - */  
408 - public void setPayType(Integer payType) {  
409 - this.payType = payType;  
410 - }  
411 -  
412 - /**  
413 - * get value of Order.orderDescription  
414 - *  
415 - * @return the orderDescription  
416 - * @createTime 2014年10月15日 下午5:59:18  
417 - * @author zhangshirui  
418 - */  
419 - public String getOrderDescription() {  
420 - return orderDescription;  
421 - }  
422 -  
423 - /**  
424 - * set value of Order.orderDescription  
425 - *  
426 - * @param orderDescription  
427 - * the orderDescription to set  
428 - * @createTime 2014年10月15日 下午5:59:18  
429 - * @author zhangshirui  
430 - */  
431 - public void setOrderDescription(String orderDescription) {  
432 - this.orderDescription = orderDescription;  
433 - }  
434 211
435 /** 212 /**
436 - * get value of Order.isCommented  
437 - *  
438 - * @return the isCommented  
439 - * @createTime 2014年10月16日 上午11:03:19  
440 - * @author zhangshirui 213 + * 物流信息
441 */ 214 */
442 - public Integer getIsCommented() {  
443 - return isCommented;  
444 - } 215 + // private LogisticsInfo logisticsInfo;
445 216
446 - /**  
447 - * set value of Order.isCommented  
448 - *  
449 - * @param isCommented  
450 - * the isCommented to set  
451 - * @createTime 2014年10月16日 上午11:03:19  
452 - * @author zhangshirui  
453 - */  
454 - public void setIsCommented(Integer isCommented) {  
455 - this.isCommented = isCommented;  
456 - }  
457 217
458 - /**  
459 - * get value of Order.refundId  
460 - *  
461 - * @return the refundId  
462 - * @createTime 2014年10月22日 上午11:38:05  
463 - * @author zhangshirui  
464 - */  
465 - public Long getRefundId() {  
466 - return refundId;  
467 - }  
468 -  
469 - /**  
470 - * set value of Order.refundId  
471 - *  
472 - * @param refundId  
473 - * the refundId to set  
474 - * @createTime 2014年10月22日 上午11:38:05  
475 - * @author zhangshirui  
476 - */  
477 - public void setRefundId(Long refundId) {  
478 - this.refundId = refundId;  
479 - }  
480 -  
481 - /**  
482 - * get value of Order.contactMobile  
483 - *  
484 - * @return the contactMobile  
485 - * @createTime 2014年10月31日 下午5:23:55  
486 - * @author zhangshirui  
487 - */  
488 - public String getContactMobile() {  
489 - return contactMobile;  
490 - } 218 + /** 是否允许申请退款:1可以 0不可以 */
  219 + private Integer refundFlag;
491 220
492 /** 221 /**
493 - * set value of Order.contactMobile  
494 - *  
495 - * @param contactMobile  
496 - * the contactMobile to set  
497 - * @createTime 2014年10月31日 下午5:23:55  
498 - * @author zhangshirui 222 + * 退款单id,退款申请中时有值
499 */ 223 */
500 - public void setContactMobile(String contactMobile) {  
501 - this.contactMobile = contactMobile;  
502 - }  
503 -  
504 - public Long getShopId() {  
505 - return shopId;  
506 - }  
507 -  
508 - public void setShopId(Long shopId) {  
509 - this.shopId = shopId;  
510 - }  
511 -  
512 - public Integer getDeliveryType() {  
513 - return deliveryType;  
514 - }  
515 -  
516 - public void setDeliveryType(Integer deliveryType) {  
517 - this.deliveryType = deliveryType;  
518 - }  
519 -  
520 - public Long getDiscountAmount() {  
521 - return discountAmount;  
522 - }  
523 -  
524 - public void setDiscountAmount(Long discountAmount) {  
525 - this.discountAmount = discountAmount;  
526 - }  
527 -  
528 - public Long getPostage() {  
529 - return postage;  
530 - }  
531 -  
532 - public void setPostage(Long postage) {  
533 - this.postage = postage;  
534 - }  
535 -  
536 - public ConsigneeInfo getConsigneeInfo() {  
537 - return consigneeInfo;  
538 - }  
539 -  
540 - public void setConsigneeInfo(ConsigneeInfo consigneeInfo) {  
541 - this.consigneeInfo = consigneeInfo;  
542 - }  
543 -  
544 - public String getPickUserMsg() {  
545 - return pickUserMsg;  
546 - }  
547 -  
548 - public void setPickUserMsg(String pickUserMsg) {  
549 - this.pickUserMsg = pickUserMsg;  
550 - }  
551 -  
552 - public String getPickAddress() {  
553 - return pickAddress;  
554 - }  
555 -  
556 - public void setPickAddress(String pickAddress) {  
557 - this.pickAddress = pickAddress;  
558 - }  
559 -  
560 - public MarketInfo getMarketInfo() {  
561 - return marketInfo;  
562 - }  
563 -  
564 - public void setMarketInfo(MarketInfo marketInfo) {  
565 - this.marketInfo = marketInfo;  
566 - }  
567 -  
568 - public String getDeliveryName() {  
569 - return deliveryName;  
570 - }  
571 -  
572 - public void setDeliveryName(String deliveryName) {  
573 - this.deliveryName = deliveryName;  
574 - }  
575 -  
576 -  
577 - public Long getTotalAmount() {  
578 - return totalAmount;  
579 - }  
580 -  
581 -  
582 - public void setTotalAmount(Long totalAmount) {  
583 - this.totalAmount = totalAmount;  
584 - }  
585 -  
586 -  
587 - public Float getRemainPickTime() {  
588 - return remainPickTime;  
589 - }  
590 -  
591 -  
592 - public void setRemainPickTime(Float remainPickTime) {  
593 - this.remainPickTime = remainPickTime;  
594 - }  
595 -  
596 - public String getPickDate() {  
597 - return pickDate;  
598 - }  
599 -  
600 - public void setPickDate(String pickDate) {  
601 - this.pickDate = pickDate;  
602 - }  
603 -  
604 - public Long getPickupEndTime() {  
605 - return pickupEndTime;  
606 - }  
607 -  
608 -  
609 - public void setPickupEndTime(Long pickupEndTime) {  
610 - this.pickupEndTime = pickupEndTime;  
611 - }  
612 -  
613 - public String getDeliveryVerCode() {  
614 - return deliveryVerCode;  
615 - }  
616 -  
617 - public void setDeliveryVerCode(String deliveryVerCode) {  
618 - this.deliveryVerCode = deliveryVerCode;  
619 - }  
620 -  
621 - public Long getSubmitTime() {  
622 - return submitTime;  
623 - }  
624 -  
625 - public void setSubmitTime(Long submitTime) {  
626 - this.submitTime = submitTime;  
627 - }  
628 -  
629 - public String getLogisticsRemarks() {  
630 - return logisticsRemarks;  
631 - }  
632 -  
633 - public void setLogisticsRemarks(String logisticsRemarks) {  
634 - this.logisticsRemarks = logisticsRemarks;  
635 - }  
636 -  
637 - public String getSubmitDate() {  
638 - return submitDate;  
639 - }  
640 -  
641 - public void setSubmitDate(String submitDate) {  
642 - this.submitDate = submitDate;  
643 - }  
644 -  
645 - public Long getShopLocationProvinceId() {  
646 - return shopLocationProvinceId;  
647 - }  
648 -  
649 - public void setShopLocationProvinceId(Long shopLocationProvinceId) {  
650 - this.shopLocationProvinceId = shopLocationProvinceId;  
651 - }  
652 -  
653 - public String getShopLocationProvinceName() {  
654 - return shopLocationProvinceName;  
655 - }  
656 -  
657 - public void setShopLocationProvinceName(String shopLocationProvinceName) {  
658 - this.shopLocationProvinceName = shopLocationProvinceName;  
659 - }  
660 -  
661 - public Long getShopLocationCityId() {  
662 - return shopLocationCityId;  
663 - }  
664 -  
665 - public void setShopLocationCityId(Long shopLocationCityId) {  
666 - this.shopLocationCityId = shopLocationCityId;  
667 - }  
668 -  
669 - public String getShopLocationCityName() {  
670 - return shopLocationCityName;  
671 - }  
672 -  
673 - public void setShopLocationCityName(String shopLocationCityName) {  
674 - this.shopLocationCityName = shopLocationCityName;  
675 - }  
676 -  
677 - public Long getShopLocationRegionId() {  
678 - return shopLocationRegionId;  
679 - }  
680 -  
681 - public void setShopLocationRegionId(Long shopLocationRegionId) {  
682 - this.shopLocationRegionId = shopLocationRegionId;  
683 - }  
684 -  
685 - public String getShopLocationRegionName() {  
686 - return shopLocationRegionName;  
687 - }  
688 -  
689 - public void setShopLocationRegionName(String shopLocationRegionName) {  
690 - this.shopLocationRegionName = shopLocationRegionName;  
691 - } 224 + private Long reOrderId;
692 225
693 - public Long getOrderWeight() {  
694 - return orderWeight;  
695 - }  
696 226
697 - public void setOrderWeight(Long orderWeight) {  
698 - this.orderWeight = orderWeight;  
699 - }  
700 } 227 }
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/order/GetOrderResp.java
@@ -19,9 +19,9 @@ public class GetOrderResp extends BaseResp { @@ -19,9 +19,9 @@ public class GetOrderResp extends BaseResp {
19 /** 19 /**
20 * 订单详情 20 * 订单详情
21 */ 21 */
22 - private OrderDetail order; 22 + private Order order;
23 23
24 - public OrderDetail getOrder() { 24 + public Order getOrder() {
25 return order; 25 return order;
26 } 26 }
27 27
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/order/SearchOrderReq.java
1 package com.diligrp.mobsite.getway.domain.protocol.order; 1 package com.diligrp.mobsite.getway.domain.protocol.order;
2 2
3 -import java.util.List;  
4 -  
5 import com.diligrp.mobsite.getway.domain.base.BaseListReq; 3 import com.diligrp.mobsite.getway.domain.base.BaseListReq;
  4 +import io.swagger.annotations.ApiModelProperty;
  5 +
  6 +import java.util.List;
6 7
7 8
8 /** 9 /**
@@ -25,35 +26,21 @@ public class SearchOrderReq extends BaseListReq { @@ -25,35 +26,21 @@ public class SearchOrderReq extends BaseListReq {
25 * 卖家:2 26 * 卖家:2
26 */ 27 */
27 public static final int USER_TYPE_SELLER = 2; 28 public static final int USER_TYPE_SELLER = 2;
28 - /**  
29 - * 是否能挂物流订单  
30 - * 是  
31 - */  
32 - public static final int IS_LOGISTICS_RELATIVE_YES = 1;  
33 - /**  
34 - * 是否能挂物流订单  
35 - * 否  
36 - */  
37 - public static final int IS_LOGISTICS_RELATIVE_NO = 2; 29 +
38 30
39 /** 31 /**
40 * 订单状态 32 * 订单状态
41 */ 33 */
  34 + @ApiModelProperty(value = "订单状态:(10待接单,15已接单待付款,20待自提,25待送货,30接单已过期,35支付超时,40已拒绝,45已取消,50已完成) ")
42 private Integer orderState; 35 private Integer orderState;
43 /** 36 /**
44 * 支付类型 37 * 支付类型
45 */ 38 */
  39 + @ApiModelProperty(value = "支付方式:10-在线支付,20-线下支付")
46 private List<Integer> payType; 40 private List<Integer> payType;
47 - /**  
48 - * 是否已经评论  
49 - */  
50 - private Integer isCommented;;  
51 41
52 - /**  
53 - * 是否能挂物流订单 ,1可以 2不可以  
54 - */  
55 - private Integer isLogisticsRealtive = IS_LOGISTICS_RELATIVE_NO;  
56 - 42 +
  43 +
57 /** 44 /**
58 * get value of SearchOrderReq.orderState 45 * get value of SearchOrderReq.orderState
59 * @return the orderState 46 * @return the orderState
@@ -97,22 +84,5 @@ public class SearchOrderReq extends BaseListReq { @@ -97,22 +84,5 @@ public class SearchOrderReq extends BaseListReq {
97 } 84 }
98 85
99 86
100 -  
101 - public Integer getIsCommented() {  
102 - return isCommented;  
103 - }  
104 -  
105 -  
106 -  
107 - public void setIsCommented(Integer isCommented) {  
108 - this.isCommented = isCommented;  
109 - }  
110 -  
111 - public Integer getIsLogisticsRealtive() {  
112 - return isLogisticsRealtive;  
113 - }  
114 87
115 - public void setIsLogisticsRealtive(Integer isLogisticsRealtive) {  
116 - this.isLogisticsRealtive = isLogisticsRealtive;  
117 - }  
118 } 88 }
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/order/SearchOrderResp.java
1 package com.diligrp.mobsite.getway.domain.protocol.order; 1 package com.diligrp.mobsite.getway.domain.protocol.order;
2 2
3 import com.diligrp.mobsite.getway.domain.base.BaseListResp; 3 import com.diligrp.mobsite.getway.domain.base.BaseListResp;
4 -import com.diligrp.mobsite.getway.domain.protocol.order.model.OrderDetail; 4 +import com.diligrp.mobsite.getway.domain.protocol.Order;
5 5
6 import java.util.List; 6 import java.util.List;
7 7
@@ -21,14 +21,14 @@ public class SearchOrderResp extends BaseListResp { @@ -21,14 +21,14 @@ public class SearchOrderResp extends BaseListResp {
21 /** 21 /**
22 * 订单列表 22 * 订单列表
23 */ 23 */
24 - private List<OrderDetail> orders; 24 + private List<Order> orders;
25 25
26 26
27 - public List<OrderDetail> getOrders() { 27 + public List<Order> getOrders() {
28 return orders; 28 return orders;
29 } 29 }
30 30
31 - public void setOrders(List<OrderDetail> orders) { 31 + public void setOrders(List<Order> orders) {
32 this.orders = orders; 32 this.orders = orders;
33 } 33 }
34 34
mobsite-getway-domain/src/main/java/com/diligrp/mobsite/getway/domain/protocol/order/model/OrderDetail.java
@@ -12,142 +12,9 @@ import com.diligrp.mobsite.getway.domain.protocol.Order; @@ -12,142 +12,9 @@ import com.diligrp.mobsite.getway.domain.protocol.Order;
12 */ 12 */
13 public class OrderDetail extends Order{ 13 public class OrderDetail extends Order{
14 14
15 - /**  
16 - * 退款次数  
17 - */  
18 - private Integer refundNum;  
19 -  
20 - /**  
21 - * 订单日志  
22 - */  
23 - //private List<OrderLog> orderLogs;  
24 -  
25 - /**  
26 - * 物流信息  
27 - */  
28 - private LogisticsInfo logisticsInfo;  
29 -  
30 - /**  
31 - * 代购信息  
32 - */  
33 -// private PurchaseInfo purchaseInfo;  
34 -  
35 - /**  
36 - * 平台手续费  
37 - */  
38 - private Long brokerage;  
39 -  
40 - /** 理赔申请中的ID*/  
41 - private Long claimsApplyId;  
42 -  
43 - /**是否允许理赔*/  
44 - private Integer claimsFlag;  
45 -  
46 - /**  
47 - * 理赔信息  
48 - */  
49 - private ClaimsInfoVO ClaimsInfo;  
50 -  
51 - /** 是否允许申请退款:1可以 0不可以 */  
52 - private Integer refundFlag;  
53 -  
54 - /**  
55 - * 退款单id,退款申请中时有值  
56 - */  
57 - private Long reOrderId;  
58 -  
59 - /**  
60 - * 退款信息  
61 - */  
62 - private RemitInfo remitInfo;  
63 -  
64 -  
65 - public RemitInfo getRemitInfo() {  
66 - return remitInfo;  
67 - }  
68 -  
69 - public void setRemitInfo(RemitInfo remitInfo) {  
70 - this.remitInfo = remitInfo;  
71 - }  
72 -  
73 - public Long getReOrderId() {  
74 - return reOrderId;  
75 - }  
76 -  
77 - public void setReOrderId(Long reOrderId) {  
78 - this.reOrderId = reOrderId;  
79 - }  
80 -  
81 - public Integer getRefundFlag() {  
82 - return refundFlag;  
83 - }  
84 -  
85 - public void setRefundFlag(Integer refundFlag) {  
86 - this.refundFlag = refundFlag;  
87 - }  
88 -  
89 - public ClaimsInfoVO getClaimsInfo() {  
90 - return ClaimsInfo;  
91 - }  
92 -  
93 - public void setClaimsInfo(ClaimsInfoVO claimsInfo) {  
94 - ClaimsInfo = claimsInfo;  
95 - }  
96 -  
97 -  
98 - public Long getClaimsApplyId() {  
99 - return claimsApplyId;  
100 - }  
101 -  
102 - public void setClaimsApplyId(Long claimsApplyId) {  
103 - this.claimsApplyId = claimsApplyId;  
104 - }  
105 -  
106 - public Integer isClaimsFlag() {  
107 - return claimsFlag;  
108 - }  
109 -  
110 - public void setClaimsFlag(Integer claimsFlag) {  
111 - this.claimsFlag = claimsFlag;  
112 - }  
113 -  
114 - public Long getBrokerage() {  
115 - return brokerage;  
116 - }  
117 -  
118 - public void setBrokerage(Long brokerage) {  
119 - this.brokerage = brokerage;  
120 - }  
121 -  
122 - //public PurchaseInfo getPurchaseInfo() {  
123 - // return purchaseInfo;  
124 - //}  
125 - //  
126 - //public void setPurchaseInfo(PurchaseInfo purchaseInfo) {  
127 - // this.purchaseInfo = purchaseInfo;  
128 - //}  
129 15
130 - public LogisticsInfo getLogisticsInfo() {  
131 - return logisticsInfo;  
132 - }  
133 16
134 - public void setLogisticsInfo(LogisticsInfo logisticsInfo) {  
135 - this.logisticsInfo = logisticsInfo;  
136 - }  
137 17
138 - //public List<OrderLog> getOrderLogs() {  
139 - // return orderLogs;  
140 - //}  
141 - //  
142 - //public void setOrderLogs(List<OrderLog> orderLogs) {  
143 - // this.orderLogs = orderLogs;  
144 - //}  
145 18
146 - public Integer getRefundNum() {  
147 - return refundNum;  
148 - }  
149 19
150 - public void setRefundNum(Integer refundNum) {  
151 - this.refundNum = refundNum;  
152 - }  
153 } 20 }
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/buyer/MessageRPC.java 0 → 100644
  1 +package com.diligrp.mobsite.getway.rpc.buyer;
  2 +
  3 +/**
  4 + * <B>Description</B> <br />
  5 + * <B>Copyright</B> Copyright (c) 2015 www.diligrp.com All rights reserved. <br />
  6 + * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />
  7 + * <B>Company</B> 地利集团
  8 + * @createTime 2015年6月25日 下午5:03:31
  9 + * @author zhangshirui
  10 + */
  11 +public interface MessageRPC {
  12 +
  13 + /**
  14 + * 调用消息中心,发送短信
  15 + * @return
  16 + * @createTime 2015年6月25日 下午5:17:43
  17 + * @author zhangshirui
  18 + */
  19 + void sendSMS(String mobile, String content);
  20 +
  21 + /**
  22 + * 新的短信运营,只适用于注册
  23 + * @param mobile
  24 + * @param content
  25 + * @param dicCode
  26 + * @createTime 2015年8月28日 下午2:16:00
  27 + * @author zhangshirui
  28 + */
  29 + void sendSMSMsg(String mobile, String content, String dicCode);
  30 +
  31 +}
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/buyer/OrderRPC.java
1 -//package com.diligrp.mobsite.getway.rpc.buyer;  
2 -//  
3 -//import com.diligrp.mobsite.getway.domain.protocol.ProductAppraise;  
4 -//import com.diligrp.mobsite.getway.domain.protocol.order.SubmitRefundAppealReq;  
5 -//import com.diligrp.orders.client.domain.input.*;  
6 -//import com.diligrp.orders.client.domain.output.*;  
7 -//import com.diligrp.orders.publics.enums.OpUserRole;  
8 -//  
9 -//import java.util.Date;  
10 -//import java.util.List;  
11 -//  
12 -//  
13 -///**  
14 -// * <B>Description</B> 订单 <br />  
15 -// * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br />  
16 -// * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />  
17 -// * <B>Company</B> 地利集团  
18 -// * @createTime 2014年9月1日 下午6:30:54  
19 -// * @author zhangshirui  
20 -// */  
21 -//public interface OrderRPC {  
22 -//  
23 -// /**  
24 -// * 获取订单列表  
25 -// * @param input  
26 -// * @param userId  
27 -// * @return  
28 -// * @createTime 2014年9月2日 下午2:36:47  
29 -// * @author zhangshirui  
30 -// */  
31 -// PageOutput<List<OrderDetailInfo>> getOrders(GetOrderListInput input, Long userId);  
32 -//  
33 -// /**  
34 -// * 根据id查询订单详情  
35 -// * @param orderId  
36 -// * @param userId  
37 -// * @createTime 2014年9月3日 上午11:08:03  
38 -// * @author zhangshirui  
39 -// * @return  
40 -// */  
41 -// OrderDetailInfo getOrderById(Long orderId, Long userId);  
42 -//  
43 -// /**  
44 -// * 取消订单  
45 -// * @param orderId  
46 -// * @param reason  
47 -// * @param userId  
48 -// * @return  
49 -// * @createTime 2014年9月3日 上午11:27:08  
50 -// * @author zhangshirui  
51 -// */  
52 -// Integer cancelOrder(Long orderId, String reason, Long userId);  
53 -//  
54 -// Integer cancelRefund(Long reOrderId, Long userId);  
55 -//  
56 -// Integer cancelClaims(Long id, Long userId);  
57 -// /**  
58 -// * 提交订单  
59 -// * @param inputList  
60 -// * @param userId  
61 -// * @return  
62 -// * @createTime 2014年9月3日 下午4:14:32  
63 -// * @author zhangshirui  
64 -// */  
65 -// //@Deprecated  
66 -// //List<OrderInfo> submitOrder(List<OrderSubmitInput> inputList, Long userId);  
67 -//  
68 -// /**  
69 -// * 提交代购订单  
70 -// * @param submitOrderInput  
71 -// * @param userId  
72 -// * @return  
73 -// * @createTime 2015年12月11日 下午4:14:32  
74 -// * @author duanyugen  
75 -// */  
76 -// public List<OrderInfo> submitOrderNew(SubmitOrderInput submitOrderInput, Long userId);  
77 -//  
78 -// /**  
79 -// * 申请退款  
80 -// * @param input  
81 -// * @param userId  
82 -// * @return  
83 -// * @createTime 2014年9月3日 下午4:39:15  
84 -// * @author zhangshirui  
85 -// */  
86 -// Long applyRefund(SumbitRefundInput input, Long userId);  
87 -//  
88 -// /**  
89 -// * 确认提货  
90 -// * @param orderId  
91 -// * @param userId  
92 -// * @return  
93 -// * @createTime 2014年9月3日 下午4:46:26  
94 -// * @author zhangshirui  
95 -// */  
96 -// Integer confirmPickUp(Long orderId, String paytoken, Long userId);  
97 -//  
98 -// /**  
99 -// * 根据订单id查询描述信息  
100 -// * @param orderId  
101 -// * @param type  
102 -// * @param userId  
103 -// * @return  
104 -// * @createTime 2014年10月15日 下午6:09:24  
105 -// * @author zhangshirui  
106 -// */  
107 -// OrderDescriptionInfo getOrderDescById(Long orderId, Integer type, Long userId);  
108 -//  
109 -// /**  
110 -// *  
111 -// * @param input  
112 -// * @return  
113 -// * @createTime 2014年10月21日 下午5:20:09  
114 -// * @author zhangshirui  
115 -// */  
116 -// PageOutput<List<RefundInfo>> getRefundOrders(GetRefundListInput input);  
117 -//  
118 -// /**  
119 -// * 根据退款id查询退款订单信息  
120 -// * @param refundId  
121 -// * @param userId  
122 -// * @return  
123 -// * @createTime 2014年10月21日 下午8:33:02  
124 -// * @author zhangshirui  
125 -// */  
126 -// RefundInfo getRefundDetail(Long refundId, Long userId);  
127 -//  
128 -//  
129 -// /**  
130 -// * 发布商品评价  
131 -// * @param productAppraises  
132 -// * @param userId  
133 -// */  
134 -// void addComment(List<ProductAppraise> productAppraises, Long orderId, Long userId);  
135 -//  
136 -// /**  
137 -// * 延期提货  
138 -// * @return  
139 -// * @createTime 2015年4月7日 下午2:45:06  
140 -// * @author zhangshirui  
141 -// */  
142 -// Date delayPickUp(Long orderId, Integer days, Long userId);  
143 -//  
144 -// /**  
145 -// * 获取订单  
146 -// * @param input  
147 -// * @createTime 2015年4月7日 下午2:49:54  
148 -// * @author zhangshirui  
149 -// */  
150 -// List<StatisticsOrderAmount> getOrderSumInfo(StatisticsOrderAmountInput input);  
151 -//  
152 -// /**  
153 -// * 获取延期提货信息  
154 -// * @param orderId  
155 -// * @param userId  
156 -// * @param role  
157 -// * @return  
158 -// */  
159 -// DelayPaymentInfo getDelayPaymentInfo(Long orderId, Long userId,  
160 -// Long role);  
161 -//  
162 -// /**  
163 -// * 提交退款申诉  
164 -// * @param req  
165 -// * @createTime 2015年6月12日 下午1:05:11  
166 -// * @author zhangshirui  
167 -// */  
168 -// void submitRefundAppeal(SubmitRefundAppealReq req);  
169 -//  
170 -// /**  
171 -// * 获取订单日志信息  
172 -// * @param input  
173 -// * @return  
174 -// * @createTime 2015年6月23日 下午3:22:14  
175 -// * @author zhangshirui  
176 -// */  
177 -// List<OrderTraceInfo> getOrderLogs(GetOrderInfoInput input);  
178 -//  
179 -// /**  
180 -// * 修改物流及验收备注  
181 -// * @param orderId  
182 -// * @param logisticsRemarks  
183 -// * @param userId  
184 -// */  
185 -// void modifyOrderLogisticsRemarks(Long orderId, String logisticsRemarks, Long userId);  
186 -// /**  
187 -// * 根据物流单id获取订单列表  
188 -// * @param input  
189 -// * @param userId  
190 -// * @return  
191 -// * @createTime 2014年9月2日 下午2:36:47  
192 -// * @author duanyugen  
193 -// */  
194 -// BaseOutput<LogisticsRelatedOrders> getOrdersByLogisticId(GetOrdersByLogisticsInput input, Long userId);  
195 -//  
196 -// /**  
197 -// * 一键收货  
198 -// * @param input  
199 -// * @return  
200 -// * @createTime 2014年9月2日 下午2:36:47  
201 -// * @author weili  
202 -// */  
203 -// Integer aKeyReceiptGoods(List<ConfirmDeliveryInput> input, Long userId);  
204 -// /**  
205 -// * 线下付款  
206 -// * @param input  
207 -// * @return  
208 -// * @createTime 2014年9月2日 下午2:36:47  
209 -// * @author weili  
210 -// */  
211 -// Integer payoffline(ModifyOrderRemitsRemarksInput input, Long userId);  
212 -// /**  
213 -// * 申请理赔  
214 -// * @param input  
215 -// * @return  
216 -// * @createTime 2014年9月2日 下午2:36:47  
217 -// * @author weili  
218 -// */  
219 -// public Long applyCompensate(SubmitClaimsInput input, Long userId);  
220 -//  
221 -// /**  
222 -// * 理赔申诉  
223 -// * @param input  
224 -// * @return  
225 -// * @createTime 2014年9月2日 下午2:36:47  
226 -// * @author weili  
227 -// */  
228 -// public Long compensateAppeal(SubmitClaimsAppealInput input, Long userId);  
229 -//  
230 -// /**  
231 -// * 确认理赔  
232 -// * @param input  
233 -// * @return  
234 -// * @createTime 2014年9月2日 下午2:36:47  
235 -// * @author weili  
236 -// */  
237 -// public Integer affirmClaimsApply(AuditClaimsInput input, Long userId);  
238 -//  
239 -// public PageOutput<List<ClaimsInfo>> getClaimsList(GetClaimsListInput input, Long userId);  
240 -//  
241 -// public ClaimsInfo getClaimsDetail(Long claimsApplyId, Long userId, OpUserRole opUserRole);  
242 -//  
243 -//  
244 -//} 1 +package com.diligrp.mobsite.getway.rpc.buyer;
  2 +
  3 +import com.b2c.orders.domain.client.dto.request.OrderListRequestDto;
  4 +import com.b2c.orders.domain.client.dto.response.OrderListResponseDto;
  5 +import com.diligrp.mobsite.getway.domain.protocol.ProductAppraise;
  6 +import com.diligrp.titan.sdk.output.PageOutput;
  7 +
  8 +import java.util.List;
  9 +
  10 +
  11 +/**
  12 + * <B>Description</B> 订单 <br />
  13 + * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br />
  14 + * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />
  15 + * <B>Company</B> 地利集团
  16 + * @createTime 2014年9月1日 下午6:30:54
  17 + * @author zhangshirui
  18 + */
  19 +public interface OrderRPC {
  20 +
  21 + /**
  22 + * 获取订单列表
  23 + * @param input
  24 + * @param userId
  25 + * @return
  26 + * @createTime 2014年9月2日 下午2:36:47
  27 + * @author zhangshirui
  28 + */
  29 + PageOutput<List<OrderListResponseDto>> getOrders(OrderListRequestDto input, Long userId);
  30 +
  31 + /**
  32 + * 根据id查询订单详情
  33 + * @param orderId
  34 + * @param userId
  35 + * @createTime 2014年9月3日 上午11:08:03
  36 + * @author zhangshirui
  37 + * @return
  38 + */
  39 + OrderListResponseDto getOrderById(Long orderId, Long userId);
  40 +
  41 + /**
  42 + * 取消订单
  43 + * @param orderId
  44 + * @param reason
  45 + * @param userId
  46 + * @return
  47 + * @createTime 2014年9月3日 上午11:27:08
  48 + * @author zhangshirui
  49 + */
  50 + Integer cancelOrder(Long orderId, String reason, Long userId);
  51 +
  52 +
  53 + /**
  54 + * 确认提货
  55 + * @param orderId
  56 + * @param userId
  57 + * @return
  58 + * @createTime 2014年9月3日 下午4:46:26
  59 + * @author zhangshirui
  60 + */
  61 + Integer confirmPickUp(Long orderId, String paytoken, Long userId);
  62 +
  63 +
  64 +
  65 +
  66 + /**
  67 + * 发布商品评价
  68 + * @param productAppraises
  69 + * @param userId
  70 + */
  71 + void addComment(List<ProductAppraise> productAppraises, Long orderId, Long userId);
  72 +
  73 +
  74 +
  75 +
  76 +}
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/buyer/impl/MessageRPCImpl.java 0 → 100644
  1 +package com.diligrp.mobsite.getway.rpc.buyer.impl;
  2 +
  3 +import com.diligrp.messageCenter.sdk.MessageProducerClient;
  4 +import com.diligrp.messageCenter.sdk.domain.sms.SMSType;
  5 +import com.diligrp.mobsite.getway.domain.except.ServiceException;
  6 +import com.diligrp.mobsite.getway.rpc.buyer.MessageRPC;
  7 +import org.slf4j.Logger;
  8 +import org.slf4j.LoggerFactory;
  9 +import org.springframework.beans.factory.annotation.Autowired;
  10 +import org.springframework.stereotype.Service;
  11 +
  12 +import java.util.HashMap;
  13 +import java.util.Map;
  14 +
  15 +/**
  16 + * <B>Description</B> <br />
  17 + * <B>Copyright</B> Copyright (c) 2015 www.diligrp.com All rights reserved. <br />
  18 + * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />
  19 + * <B>Company</B> 地利集团
  20 + * @createTime 2015年6月25日 下午5:04:39
  21 + * @author zhangshirui
  22 + */
  23 +@Service
  24 +public class MessageRPCImpl implements MessageRPC {
  25 +
  26 + private static final Logger logger = LoggerFactory.getLogger(MessageRPCImpl.class);
  27 +
  28 + @Autowired
  29 + private MessageProducerClient messageProducerClient;
  30 +
  31 + @Override
  32 + public void sendSMS(String mobile,String content) {
  33 +
  34 + try {
  35 + messageProducerClient.smsProducer().produce(new String[]{mobile}, content, 0L);
  36 + } catch (Exception e) {
  37 + logger.error("调用消息中心接口失败:msg={}",e.getMessage());
  38 + throw new ServiceException();
  39 + }
  40 + logger.info("发送短信成功:mobile={},content={}",mobile,content);
  41 +
  42 + }
  43 +
  44 + @Override
  45 + public void sendSMSMsg(String mobile,String content,String dicCode) {
  46 +
  47 + try {
  48 + Map<String, String> parameters = new HashMap<>();
  49 + parameters.put("1", content);
  50 + messageProducerClient.smsProducer().produce(new String[]{mobile}, dicCode, parameters, SMSType.VERIFY_CODE);
  51 +
  52 + } catch (Exception e) {
  53 + logger.error("调用消息中心接口失败:msg={}",e.getMessage());
  54 + throw new ServiceException();
  55 + }
  56 + logger.info("发送短信成功:mobile={},content={}",mobile,content);
  57 +
  58 + }
  59 +
  60 +}
mobsite-getway-rpc/src/main/java/com/diligrp/mobsite/getway/rpc/buyer/impl/OrderRPCImpl.java
1 -//package com.diligrp.mobsite.getway.rpc.buyer.impl;  
2 -//  
3 -//import com.alibaba.fastjson.JSON;  
4 -//import com.diligrp.mobsite.getway.domain.common.ErrorMessage;  
5 -//import com.diligrp.mobsite.getway.domain.common.ResultCode;  
6 -//import com.diligrp.mobsite.getway.domain.common.enums.OrderUserType;  
7 -//import com.diligrp.mobsite.getway.domain.except.ServiceException;  
8 -//import com.diligrp.mobsite.getway.domain.protocol.ProductAppraise;  
9 -//import com.diligrp.mobsite.getway.domain.protocol.order.SubmitRefundAppealReq;  
10 -//import com.diligrp.mobsite.getway.rpc.buyer.OrderRPC;  
11 -//import com.diligrp.orders.client.OrderClient;  
12 -//import com.diligrp.orders.client.domain.input.*;  
13 -//import com.diligrp.orders.client.domain.output.*;  
14 -//import com.diligrp.orders.client.service.OrderService;  
15 -//import com.diligrp.orders.publics.enums.OpUserRole;  
16 -//import com.diligrp.website.util.redis.RedisUtil;  
17 -//import com.diligrp.website.util.security.Validator;  
18 -//import org.slf4j.Logger;  
19 -//import org.slf4j.LoggerFactory;  
20 -//import org.springframework.stereotype.Service;  
21 -//  
22 -//import javax.annotation.Resource;  
23 -//import java.util.ArrayList;  
24 -//import java.util.Date;  
25 -//import java.util.List;  
26 -//  
27 -//  
28 -///**  
29 -// * <B>Description</B> 订单rpc <br />  
30 -// * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br />  
31 -// * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />  
32 -// * <B>Company</B> 地利集团  
33 -// *  
34 -// * @author zhangshirui  
35 -// * @createTime 2014年9月1日 下午6:31:13  
36 -// */  
37 -//@Service("orderRPC")  
38 -//public class OrderRPCImpl implements OrderRPC {  
39 -//  
40 -// public static final long ORDER_USER_TYPE_BUYER = 10L;  
41 -// public static final long ORDER_USER_TYPE_SELLER = 20L;  
42 -//  
43 -// private static final Logger logger = LoggerFactory.getLogger(OrderRPCImpl.class);  
44 -//  
45 -// //@Resource  
46 -// //private OrderClient orderClient;  
47 -// @Resource  
48 -// private RedisUtil redisUtil;  
49 -//  
50 -//  
51 -// @Override  
52 -// public PageOutput<List<OrderDetailInfo>> getOrders(GetOrderListInput input, Long userId) {  
53 -// return null;  
54 -// }  
55 -//  
56 -// @Override  
57 -// public OrderDetailInfo getOrderById(Long orderId, Long userId) {  
58 -// return null;  
59 -// }  
60 -//  
61 -// @Override  
62 -// public Integer cancelOrder(Long orderId, String reason, Long userId) {  
63 -// return null;  
64 -// }  
65 -//  
66 -// @Override  
67 -// public Integer cancelRefund(Long reOrderId, Long userId) {  
68 -// return null;  
69 -// }  
70 -//  
71 -// @Override  
72 -// public Integer cancelClaims(Long id, Long userId) {  
73 -// return null;  
74 -// }  
75 -//  
76 -// @Override  
77 -// public List<OrderInfo> submitOrderNew(SubmitOrderInput submitOrderInput, Long userId) {  
78 -// return null;  
79 -// }  
80 -//  
81 -// @Override  
82 -// public Long applyRefund(SumbitRefundInput input, Long userId) {  
83 -// return null;  
84 -// }  
85 -//  
86 -// @Override  
87 -// public Integer confirmPickUp(Long orderId, String paytoken, Long userId) {  
88 -// return null;  
89 -// }  
90 -//  
91 -// @Override  
92 -// public OrderDescriptionInfo getOrderDescById(Long orderId, Integer type, Long userId) {  
93 -// return null;  
94 -// }  
95 -//  
96 -// @Override  
97 -// public PageOutput<List<RefundInfo>> getRefundOrders(GetRefundListInput input) {  
98 -// return null;  
99 -// }  
100 -//  
101 -// @Override  
102 -// public RefundInfo getRefundDetail(Long refundId, Long userId) {  
103 -// return null;  
104 -// }  
105 -//  
106 -// @Override  
107 -// public void addComment(List<ProductAppraise> productAppraises, Long orderId, Long userId) {  
108 -//  
109 -// }  
110 -//  
111 -// @Override  
112 -// public Date delayPickUp(Long orderId, Integer days, Long userId) {  
113 -// return null;  
114 -// }  
115 -//  
116 -// @Override  
117 -// public List<StatisticsOrderAmount> getOrderSumInfo(StatisticsOrderAmountInput input) {  
118 -// return null;  
119 -// }  
120 -//  
121 -// @Override  
122 -// public DelayPaymentInfo getDelayPaymentInfo(Long orderId, Long userId, Long role) {  
123 -// return null;  
124 -// }  
125 -//  
126 -// @Override  
127 -// public void submitRefundAppeal(SubmitRefundAppealReq req) {  
128 -//  
129 -// }  
130 -//  
131 -// @Override  
132 -// public List<OrderTraceInfo> getOrderLogs(GetOrderInfoInput input) {  
133 -// return null;  
134 -// }  
135 -//  
136 -// @Override  
137 -// public void modifyOrderLogisticsRemarks(Long orderId, String logisticsRemarks, Long userId) {  
138 -//  
139 -// }  
140 -//  
141 -// @Override  
142 -// public BaseOutput<LogisticsRelatedOrders> getOrdersByLogisticId(GetOrdersByLogisticsInput input, Long userId) {  
143 -// return null;  
144 -// }  
145 -//  
146 -// @Override  
147 -// public Integer aKeyReceiptGoods(List<ConfirmDeliveryInput> input, Long userId) {  
148 -// return null;  
149 -// }  
150 -//  
151 -// @Override  
152 -// public Integer payoffline(ModifyOrderRemitsRemarksInput input, Long userId) {  
153 -// return null;  
154 -// }  
155 -//  
156 -// @Override  
157 -// public Long applyCompensate(SubmitClaimsInput input, Long userId) {  
158 -// return null;  
159 -// }  
160 -//  
161 -// @Override  
162 -// public Long compensateAppeal(SubmitClaimsAppealInput input, Long userId) {  
163 -// return null;  
164 -// }  
165 -//  
166 -// @Override  
167 -// public Integer affirmClaimsApply(AuditClaimsInput input, Long userId) {  
168 -// return null;  
169 -// }  
170 -//  
171 -// @Override  
172 -// public PageOutput<List<ClaimsInfo>> getClaimsList(GetClaimsListInput input, Long userId) {  
173 -// return null;  
174 -// }  
175 -//  
176 -// @Override  
177 -// public ClaimsInfo getClaimsDetail(Long claimsApplyId, Long userId, OpUserRole opUserRole) {  
178 -// return null;  
179 -// }  
180 -//} 1 +package com.diligrp.mobsite.getway.rpc.buyer.impl;
  2 +
  3 +import com.b2c.orders.domain.client.dto.request.OrderListRequestDto;
  4 +import com.b2c.orders.domain.client.dto.response.OrderListResponseDto;
  5 +import com.diligrp.mobsite.getway.domain.protocol.ProductAppraise;
  6 +import com.diligrp.mobsite.getway.rpc.buyer.OrderRPC;
  7 +import com.diligrp.titan.sdk.output.PageOutput;
  8 +import org.slf4j.Logger;
  9 +import org.slf4j.LoggerFactory;
  10 +import org.springframework.stereotype.Service;
  11 +
  12 +import java.util.List;
  13 +
  14 +
  15 +/**
  16 + * <B>Description</B> 订单rpc <br />
  17 + * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br />
  18 + * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />
  19 + * <B>Company</B> 地利集团
  20 + *
  21 + * @author zhangshirui
  22 + * @createTime 2014年9月1日 下午6:31:13
  23 + */
  24 +@Service("orderRPC")
  25 +public class OrderRPCImpl implements OrderRPC {
  26 +
  27 + public static final long ORDER_USER_TYPE_BUYER = 10L;
  28 + public static final long ORDER_USER_TYPE_SELLER = 20L;
  29 +
  30 + private static final Logger logger = LoggerFactory.getLogger(OrderRPCImpl.class);
  31 +
  32 +
  33 + @Override
  34 + public PageOutput<List<OrderListResponseDto>> getOrders(OrderListRequestDto input, Long userId) {
  35 + return null;
  36 + }
  37 +
  38 + @Override
  39 + public OrderListResponseDto getOrderById(Long orderId, Long userId) {
  40 + return null;
  41 + }
  42 +
  43 + @Override
  44 + public Integer cancelOrder(Long orderId, String reason, Long userId) {
  45 + return null;
  46 + }
  47 +
  48 + @Override
  49 + public Integer confirmPickUp(Long orderId, String paytoken, Long userId) {
  50 + return null;
  51 + }
  52 +
  53 + @Override
  54 + public void addComment(List<ProductAppraise> productAppraises, Long orderId, Long userId) {
  55 +
  56 + }
  57 +}
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/user/OrderService.java
@@ -22,15 +22,6 @@ public interface OrderService { @@ -22,15 +22,6 @@ public interface OrderService {
22 */ 22 */
23 SearchOrderResp getOrders(SearchOrderReq req); 23 SearchOrderResp getOrders(SearchOrderReq req);
24 24
25 - /**  
26 - * 提交订单  
27 - * @param req  
28 - * @return  
29 - * @createTime 2014年9月1日 下午6:18:33  
30 - * @author zhangshirui  
31 - */  
32 - //@Deprecated  
33 - //SubmitOrderResp submitOrder(SubmitOrderReq req);  
34 25
35 /** 26 /**
36 * 提交订单 27 * 提交订单
@@ -53,34 +44,6 @@ public interface OrderService { @@ -53,34 +44,6 @@ public interface OrderService {
53 44
54 45
55 /** 46 /**
56 - * 取消退款  
57 - * @param req  
58 - * @return  
59 - * @createTime 2016年9月1日 下午6:18:29  
60 - * @author zhangshirui  
61 - */  
62 - CancelRefundResp cancelRefund(CancelRefundReq req);  
63 -  
64 -  
65 - /**  
66 - * 取消理赔  
67 - * @param req  
68 - * @return  
69 - * @createTime 2016年9月1日 下午6:18:29  
70 - * @author zhangshirui  
71 - */  
72 - CancelClaimsResp cancelClaims(CancelClaimsReq req);  
73 -  
74 - /**  
75 - * 退款  
76 - * @param req  
77 - * @return  
78 - * @createTime 2014年9月1日 下午6:18:08  
79 - * @author zhangshirui  
80 - */  
81 - OrderRefundResp applyRefund(OrderRefundReq req);  
82 -  
83 - /**  
84 * 提货 47 * 提货
85 * @param req 48 * @param req
86 * @return 49 * @return
@@ -107,41 +70,7 @@ public interface OrderService { @@ -107,41 +70,7 @@ public interface OrderService {
107 */ 70 */
108 SendTradeCodeResp sendTradeCode(SendTradeCodeReq req); 71 SendTradeCodeResp sendTradeCode(SendTradeCodeReq req);
109 72
110 - /**  
111 - * 获取退款原因  
112 - * @param req  
113 - * @return  
114 - * @createTime 2014年10月21日 下午3:00:43  
115 - * @author zhangshirui  
116 - */  
117 - GetRefundReasonResp getRefundReason(GetRefundReasonReq req);  
118 -  
119 - /**  
120 - * 获取取消订单原因  
121 - * @param req  
122 - * @return  
123 - * @createTime 2014年10月21日 下午3:26:58  
124 - * @author zhangshirui  
125 - */  
126 - GetCancelOrderReasonResp getCancelReason(GetCancelOrderReasonReq req);  
127 -  
128 - /**  
129 - * 获取申请退款的订单列表  
130 - * @param req  
131 - * @return  
132 - * @createTime 2014年10月21日 下午4:12:42  
133 - * @author zhangshirui  
134 - */  
135 - GetRefundOrderListResp getRefundOrders(GetRefundOrderListReq req);  
136 73
137 - /**  
138 - * 获取申请退款的订单详情  
139 - * @param req  
140 - * @return  
141 - * @createTime 2014年10月21日 下午4:40:17  
142 - * @author zhangshirui  
143 - */  
144 - GetRefundDetailResp getRefundDetail(GetRefundDetailReq req);  
145 74
146 /** 75 /**
147 * 发布商品评价 76 * 发布商品评价
@@ -150,79 +79,5 @@ public interface OrderService { @@ -150,79 +79,5 @@ public interface OrderService {
150 */ 79 */
151 AppraiseGoodsResp publishProductAppraise(AppraiseGoodsReq req); 80 AppraiseGoodsResp publishProductAppraise(AppraiseGoodsReq req);
152 81
153 - /**  
154 - * 获取订单统计数据  
155 - *  
156 - * @param req  
157 - * @return  
158 - * @createTime 2015年3月16日 下午4:12:12  
159 - * @author zhangshirui  
160 - */  
161 - GetOrderSumInfoResp getOrderSumInfo(GetOrderSumInfoReq req);  
162 -  
163 - /**  
164 - * 延时提货  
165 - * @param req  
166 - * @return  
167 - * @createTime 2015年4月7日 下午2:43:26  
168 - * @author zhangshirui  
169 - */  
170 - DelayPickUpResp delayPickUp(DelayPickUpReq req);  
171 -  
172 - /**  
173 - * 获取协议信息  
174 - * @param req  
175 - * @return  
176 - * @createTime 2015年4月27日 下午3:48:33  
177 - * @author zhangshirui  
178 - * @param dirPath  
179 - */  
180 - GetAgreementResp getAgreement(GetAgreementReq req, String dirPath);  
181 -  
182 - /**  
183 - * 提交退款申诉  
184 - * @param req  
185 - * @return  
186 - * @createTime 2015年6月12日 下午1:03:33  
187 - * @author zhangshirui  
188 - */  
189 - SubmitRefundAppealResp submitRefundAppeal(SubmitRefundAppealReq req);  
190 -  
191 - /**  
192 - * 提交现场交易订单  
193 - * @param req  
194 - * @return  
195 - * @createTime 2015年7月10日 下午6:40:36  
196 - * @author zhangshirui  
197 - */  
198 -// SubmitSpotOrderResp submitSpotOrder(SubmitSpotOrderReq req);  
199 -  
200 -  
201 -  
202 -  
203 - /**  
204 - * 一键收货  
205 - * @param req  
206 - * @return  
207 - * @createTime 2014年9月1日 下午6:18:36  
208 - * @author weili  
209 - */  
210 - AKeyReceiptGoodsResp aKeyReceiptGoods(AKeyReceiptGoodsReq req);  
211 -  
212 - PayofflineResp payoffline(PayofflineReq req);  
213 -  
214 - ApplyCompensateResp applyCompensate(ApplyCompensateReq req);  
215 -  
216 - CompensateAppealResp compensateAppeal(CompensateAppealReq req);  
217 -  
218 - GetClaimsRequiresResp getClaimsRequires(GetClaimsRequiresReq req);  
219 -  
220 - GetClaimsReasonsResp getClaimsReasons(GetClaimsReasonsReq req);  
221 -  
222 - AffirmClaimsResp affirmClaims(AffirmClaimsReq req);  
223 -  
224 -  
225 - GetClaimsDetailResp getClaimsDetail(GetClaimsDetailReq req);  
226 82
227 - GetClaimsListResp getClaimsList(GetClaimsListReq req);  
228 } 83 }
mobsite-getway-service/src/main/java/com/diligrp/mobsite/getway/service/buyer/user/impl/OrderServiceImpl.java
@@ -2,8 +2,17 @@ package com.diligrp.mobsite.getway.service.buyer.user.impl; @@ -2,8 +2,17 @@ package com.diligrp.mobsite.getway.service.buyer.user.impl;
2 2
3 3
4 import com.diligrp.mobsite.getway.domain.protocol.order.*; 4 import com.diligrp.mobsite.getway.domain.protocol.order.*;
  5 +import com.diligrp.mobsite.getway.rpc.buyer.*;
  6 +import com.diligrp.mobsite.getway.rpc.seller.SellerOrderRPC;
  7 +import com.diligrp.mobsite.getway.rpc.seller.SellerShopRPC;
5 import com.diligrp.mobsite.getway.service.buyer.user.OrderService; 8 import com.diligrp.mobsite.getway.service.buyer.user.OrderService;
  9 +import com.diligrp.website.util.redis.RedisUtil;
  10 +import com.diligrp.website.web.interfaces.WebsiteClient;
  11 +import com.yqyw.filter.client.KeyWordsClient;
6 import org.apache.log4j.Logger; 12 import org.apache.log4j.Logger;
  13 +import org.springframework.beans.factory.annotation.Autowired;
  14 +
  15 +import javax.annotation.Resource;
7 16
8 17
9 /** 18 /**
@@ -18,19 +27,50 @@ import org.apache.log4j.Logger; @@ -18,19 +27,50 @@ import org.apache.log4j.Logger;
18 @org.springframework.stereotype.Service("orderService") 27 @org.springframework.stereotype.Service("orderService")
19 public class OrderServiceImpl implements OrderService { 28 public class OrderServiceImpl implements OrderService {
20 29
21 -  
22 - /* 30 + @Resource
  31 + private OrderRPC orderRPC;
  32 + @Resource
  33 + private UserRPC userRPC;
  34 + @Resource
  35 + private GoodsRPC goodsRPC;
  36 + @Autowired
  37 + private MessageRPC messageRPC;
  38 + //@Resource
  39 + //private ServiceRPC serviceRPC;
  40 + @Resource
  41 + private MarketRPC marketRPC;
  42 + @Resource
  43 + private ConfigRPC configRPC;
  44 + @Resource
  45 + private RedisUtil redisUtil;
  46 +
  47 + @Resource
  48 + private ShopRPC shopRPC;
  49 + @Resource
  50 + private SellerShopRPC sellerShopRPC;
  51 +
  52 + @Resource
  53 + private SellerOrderRPC sellerOrderRPC;
  54 +
  55 +
  56 + @Resource
  57 + private KeyWordsClient keyWordsClient;
  58 +
  59 + @Autowired
  60 + private WebsiteClient websiteClient;
  61 +
  62 + /*
23 * 订单查询类型:简单查询-1 63 * 订单查询类型:简单查询-1
24 * 订单查询类型:详细查询-2 64 * 订单查询类型:详细查询-2
25 */ 65 */
26 - public static final int SEARCH_TYPE_SIMPLE = 1;  
27 - public static final int SEARCH_TYPE_DETAIL = 2;  
28 - /*成功标志*/  
29 - public static final int SUCCESS_FLAG = 1;  
30 -  
31 - private static final int DELAY_PICKUP_DAYS = 3;  
32 -  
33 - private static Logger log = Logger.getLogger(OrderServiceImpl.class); 66 + public static final int SEARCH_TYPE_SIMPLE = 1;
  67 + public static final int SEARCH_TYPE_DETAIL = 2;
  68 + /*成功标志*/
  69 + public static final int SUCCESS_FLAG = 1;
  70 +
  71 + private static final int DELAY_PICKUP_DAYS = 3;
  72 +
  73 + private static Logger log = Logger.getLogger(OrderServiceImpl.class);
34 74
35 75
36 @Override 76 @Override
@@ -49,21 +89,6 @@ public class OrderServiceImpl implements OrderService { @@ -49,21 +89,6 @@ public class OrderServiceImpl implements OrderService {
49 } 89 }
50 90
51 @Override 91 @Override
52 - public CancelRefundResp cancelRefund(CancelRefundReq req) {  
53 - return null;  
54 - }  
55 -  
56 - @Override  
57 - public CancelClaimsResp cancelClaims(CancelClaimsReq req) {  
58 - return null;  
59 - }  
60 -  
61 - @Override  
62 - public OrderRefundResp applyRefund(OrderRefundReq req) {  
63 - return null;  
64 - }  
65 -  
66 - @Override  
67 public ConfirmPickUpResp confirmPickUp(ConfirmPickUpReq req) { 92 public ConfirmPickUpResp confirmPickUp(ConfirmPickUpReq req) {
68 return null; 93 return null;
69 } 94 }
@@ -79,92 +104,7 @@ public class OrderServiceImpl implements OrderService { @@ -79,92 +104,7 @@ public class OrderServiceImpl implements OrderService {
79 } 104 }
80 105
81 @Override 106 @Override
82 - public GetRefundReasonResp getRefundReason(GetRefundReasonReq req) {  
83 - return null;  
84 - }  
85 -  
86 - @Override  
87 - public GetCancelOrderReasonResp getCancelReason(GetCancelOrderReasonReq req) {  
88 - return null;  
89 - }  
90 -  
91 - @Override  
92 - public GetRefundOrderListResp getRefundOrders(GetRefundOrderListReq req) {  
93 - return null;  
94 - }  
95 -  
96 - @Override  
97 - public GetRefundDetailResp getRefundDetail(GetRefundDetailReq req) {  
98 - return null;  
99 - }  
100 -  
101 - @Override  
102 public AppraiseGoodsResp publishProductAppraise(AppraiseGoodsReq req) { 107 public AppraiseGoodsResp publishProductAppraise(AppraiseGoodsReq req) {
103 return null; 108 return null;
104 } 109 }
105 -  
106 - @Override  
107 - public GetOrderSumInfoResp getOrderSumInfo(GetOrderSumInfoReq req) {  
108 - return null;  
109 - }  
110 -  
111 - @Override  
112 - public DelayPickUpResp delayPickUp(DelayPickUpReq req) {  
113 - return null;  
114 - }  
115 -  
116 - @Override  
117 - public GetAgreementResp getAgreement(GetAgreementReq req, String dirPath) {  
118 - return null;  
119 - }  
120 -  
121 - @Override  
122 - public SubmitRefundAppealResp submitRefundAppeal(SubmitRefundAppealReq req) {  
123 - return null;  
124 - }  
125 -  
126 - @Override  
127 - public AKeyReceiptGoodsResp aKeyReceiptGoods(AKeyReceiptGoodsReq req) {  
128 - return null;  
129 - }  
130 -  
131 - @Override  
132 - public PayofflineResp payoffline(PayofflineReq req) {  
133 - return null;  
134 - }  
135 -  
136 - @Override  
137 - public ApplyCompensateResp applyCompensate(ApplyCompensateReq req) {  
138 - return null;  
139 - }  
140 -  
141 - @Override  
142 - public CompensateAppealResp compensateAppeal(CompensateAppealReq req) {  
143 - return null;  
144 - }  
145 -  
146 - @Override  
147 - public GetClaimsRequiresResp getClaimsRequires(GetClaimsRequiresReq req) {  
148 - return null;  
149 - }  
150 -  
151 - @Override  
152 - public GetClaimsReasonsResp getClaimsReasons(GetClaimsReasonsReq req) {  
153 - return null;  
154 - }  
155 -  
156 - @Override  
157 - public AffirmClaimsResp affirmClaims(AffirmClaimsReq req) {  
158 - return null;  
159 - }  
160 -  
161 - @Override  
162 - public GetClaimsDetailResp getClaimsDetail(GetClaimsDetailReq req) {  
163 - return null;  
164 - }  
165 -  
166 - @Override  
167 - public GetClaimsListResp getClaimsList(GetClaimsListReq req) {  
168 - return null;  
169 - }  
170 } 110 }
mobsite-getway-web/src/main/java/com/diligrp/mobsite/getway/web/api/buyer/user/OrderController.java
1 -//package com.diligrp.mobsite.getway.web.api.buyer.user;  
2 -//  
3 -//import com.diligrp.mobsite.getway.domain.common.Constant;  
4 -//import com.diligrp.mobsite.getway.domain.except.ServiceException;  
5 -//import com.diligrp.mobsite.getway.domain.protocol.common.LogResp;  
6 -//import com.diligrp.mobsite.getway.domain.protocol.order.*;  
7 -//import com.diligrp.mobsite.getway.service.buyer.user.OrderService;  
8 -//import com.diligrp.mobsite.getway.web.api.base.BaseApiController;  
9 -//import com.diligrp.mobsite.getway.web.utils.BeanValidator;  
10 -//import com.diligrp.mobsite.getway.web.utils.DiligrpEndpoint;  
11 -//import org.apache.log4j.Logger;  
12 -//import org.springframework.stereotype.Controller;  
13 -//import org.springframework.web.bind.annotation.RequestMapping;  
14 -//import org.springframework.web.bind.annotation.ResponseBody;  
15 -//  
16 -//import javax.annotation.Resource;  
17 -//import javax.servlet.http.HttpServletRequest;  
18 -//  
19 -//  
20 -///**  
21 -// * <B>Description</B> 订单操作 <br />  
22 -// * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br />  
23 -// * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />  
24 -// * <B>Company</B> 地利集团  
25 -// * @createTime 2014年9月1日 下午2:30:41  
26 -// * @author zhangshirui  
27 -// */  
28 -//@Controller  
29 -//@RequestMapping("/mobsiteApp/order/")  
30 -//public class OrderController extends BaseApiController {  
31 -//  
32 -// @Resource  
33 -// private OrderService orderService;  
34 -//  
35 -// private static Logger log = Logger.getLogger(OrderController.class);  
36 -//  
37 -// /**  
38 -// * 获取订单列表  
39 -// *  
40 -// * 请求协议体:SearchOrderReq  
41 -// * 返回协议体:SearchOrderResp  
42 -// *  
43 -// * @createTime 2014年9月1日 下午5:32:02  
44 -// * @author zhangshirui  
45 -// * @return  
46 -// */  
47 -// @RequestMapping("getOrders")  
48 -// @ResponseBody  
49 -// @DiligrpEndpoint(group = "订单信息",req=SearchOrderReq.class, resp=SearchOrderResp.class,desc="获取订单列表")  
50 -// public void getOrders(){  
51 -//  
52 -// SearchOrderReq req = super.getRequest(SearchOrderReq.class);  
53 -// try {  
54 -// SearchOrderResp resp = orderService.getOrders(req);  
55 -// super.sendSuccessResp(resp);  
56 -// }catch (ServiceException e) {  
57 -// log.error("获取订单列表出现业务异常", e);  
58 -// super.sendError(e.getCode(), e.getMessage());  
59 -// }catch (Exception e) {  
60 -// log.error("获取订单列表失败", e);  
61 -// super.sendError(e.getMessage());  
62 -// }  
63 -// }  
64 -//  
65 -// /**  
66 -// * 根据订单id查询订单  
67 -// *  
68 -// * 请求协议体:GetOrderReq  
69 -// * 返回协议体:GetOrderResp  
70 -// *  
71 -// * @createTime 2014年9月1日 下午6:39:10  
72 -// * @author zhangshirui  
73 -// */  
74 -// @RequestMapping("getOrderById")  
75 -// @ResponseBody  
76 -// @DiligrpEndpoint(group = "订单信息",req=GetOrderReq.class, resp=GetOrderResp.class,desc="根据订单id查询订单详情")  
77 -// public void getOrderById(){  
78 -//  
79 -// GetOrderReq req = super.getRequest(GetOrderReq.class);  
80 -// try {  
81 -// GetOrderResp resp = orderService.getOrderById(req);  
82 -// super.sendSuccessResp(resp);  
83 -// }catch (ServiceException e) {  
84 -// log.error("获取订单详情出现业务异常", e);  
85 -// super.sendError(e.getCode(), e.getMessage());  
86 -// } catch (Exception e) {  
87 -// log.error("获取订单详情失败", e);  
88 -// super.sendError(e.getMessage());  
89 -// }  
90 -// }  
91 -//  
92 -// /**  
93 -// * 提交订单  
94 -// *  
95 -// * 请求协议体:SubmitOrderReq  
96 -// * 返回协议体:SubmitOrderResp  
97 -// *  
98 -// * @createTime 2014年9月1日 下午6:05:23  
99 -// * @author zhangshirui  
100 -// */  
101 -// //@Deprecated//20160119后版本删除  
102 -// //@RequestMapping("submitOrder")  
103 -// //@ResponseBody  
104 -// //@DiligrpEndpoint(group = "订单信息",req=SubmitOrderReq.class, resp=SubmitOrderResp.class,desc="提交订单")  
105 -// //public void submitOrder(HttpServletRequest request){  
106 -// //  
107 -// // SubmitOrderReq req = super.getRequest(SubmitOrderReq.class);  
108 -// // try {  
109 -// // SubmitOrderResp resp = orderService.submitOrder(req);  
110 -// // try {  
111 -// // LogResp logResp = resp.getLogResp();  
112 -// // log.info(String.format("提交订单:[ 设备id<%s>用户名<%s>用户id<%s>店铺id<%s>ip<%s>订单id<%s>商品id<%s> ]"  
113 -// // , req.getDeviceId(), logResp.getUserName(), logResp.getUserId(), logResp.getShopId(), request.getRemoteAddr(), logResp.getOrderId(), logResp.getProductId()));  
114 -// // } catch (Exception e) {  
115 -// // log.error("记录下单日志出错!");  
116 -// // }  
117 -// // super.sendSuccessResp(resp);  
118 -// // } catch (ServiceException e) {  
119 -// // log.error("提交订单出现业务异常", e);  
120 -// // super.sendError(e.getCode(), e.getMessage());  
121 -// // } catch (Exception e) {  
122 -// // log.error("提交订单失败", e);  
123 -// // super.sendError(e.getMessage());  
124 -// // }  
125 -// //}  
126 -//  
127 -// /**  
128 -// * 提交订单  
129 -// *  
130 -// * 请求协议体:SubmitOrderReq  
131 -// * 返回协议体:SubmitOrderResp  
132 -// *  
133 -// * @createTime 2014年9月1日 下午6:05:23  
134 -// * @author zhangshirui  
135 -// */  
136 -// @RequestMapping("submitOrderNew")  
137 -// @ResponseBody  
138 -// @DiligrpEndpoint(group = "订单信息",req=SubmitOrderReq.class, resp=SubmitOrderResp.class,desc="提交订单")  
139 -// public void submitOrderNew(HttpServletRequest request){  
140 -//  
141 -// SubmitOrderReq req = super.getRequest(SubmitOrderReq.class);  
142 -// try {  
143 -// BeanValidator.validator(req);  
144 -// SubmitOrderResp resp = orderService.submitOrderNew(req);  
145 -// try {  
146 -// LogResp logResp = resp.getLogResp();  
147 -// log.info(String.format("提交订单:[ 设备id<%s>用户名<%s>用户id<%s>店铺id<%s>ip<%s>订单id<%s>商品id<%s> ]"  
148 -// , req.getDeviceId(), logResp.getUserName(), logResp.getUserId(), logResp.getShopId(), request.getRemoteAddr(), logResp.getOrderId(), logResp.getProductId()));  
149 -// }catch (Exception e) {  
150 -// log.error("记录下单日志出错!");  
151 -// }  
152 -// super.sendSuccessResp(resp);  
153 -// } catch (ServiceException e) {  
154 -// log.error("提交订单出现业务异常", e);  
155 -// super.sendError(e.getCode(), e.getMessage());  
156 -// } catch (Exception e) {  
157 -// log.error("提交订单失败", e);  
158 -// super.sendError(e.getMessage());  
159 -// }  
160 -// }  
161 -//  
162 -// /**  
163 -// * 线下付款  
164 -// *  
165 -// * 请求协议体:PayofflineReq  
166 -// * 返回协议体:PayofflineResp  
167 -// *  
168 -// * @createTime 2014年9月1日 下午6:05:23  
169 -// * @author zhangshirui  
170 -// */  
171 -// @RequestMapping("payoffline")  
172 -// @ResponseBody  
173 -// public void payoffline(){  
174 -// PayofflineReq req = super.getRequest(PayofflineReq.class);  
175 -// try {  
176 -// BeanValidator.validator(req);  
177 -// PayofflineResp resp = orderService.payoffline(req);  
178 -// super.sendSuccessResp(resp);  
179 -// } catch (ServiceException e) {  
180 -// log.error("录入线下付款信息出现业务异常", e);  
181 -// super.sendError(e.getCode(), e.getMessage());  
182 -// } catch (Exception e) {  
183 -// log.error("录入线下付款信息失败", e);  
184 -// super.sendError(e.getMessage());  
185 -// }  
186 -// }  
187 -//  
188 -//  
189 -//  
190 -//  
191 -// /**  
192 -// * 取消订单  
193 -// *  
194 -// * 请求协议体:CancelOrderReq  
195 -// * 返回协议体:CancelOrderResp  
196 -// *  
197 -// * @createTime 2014年9月1日 下午6:08:06  
198 -// * @author zhangshirui  
199 -// */  
200 -// @RequestMapping("cancelOrder")  
201 -// @ResponseBody  
202 -// @DiligrpEndpoint(group = "订单信息",req=CancelOrderReq.class, resp=CancelOrderResp.class,desc="取消订单")  
203 -// public void cancelOrder(){  
204 -//  
205 -// CancelOrderReq req = super.getRequest(CancelOrderReq.class);  
206 -// try {  
207 -// CancelOrderResp resp = orderService.cancelOrder(req);  
208 -// super.sendSuccessResp(resp);  
209 -// } catch (ServiceException e) {  
210 -// log.error("取消订单出现业务异常", e);  
211 -// super.sendError(e.getCode(), e.getMessage());  
212 -// } catch (Exception e) {  
213 -// log.error("取消订单失败", e);  
214 -// super.sendError(e.getMessage());  
215 -// }  
216 -// }  
217 -//  
218 -// /**  
219 -// * 申请退款  
220 -// *  
221 -// * 请求协议体:OrderRefundReq  
222 -// * 返回协议体:OrderRefundResp  
223 -// *  
224 -// * @createTime 2014年9月1日 下午6:14:12  
225 -// * @author zhangshirui  
226 -// */  
227 -// @RequestMapping("applyRefund")  
228 -// @ResponseBody  
229 -// @DiligrpEndpoint(group = "订单信息",req=OrderRefundReq.class, resp=OrderRefundResp.class,desc="申请退款")  
230 -// public void applyRefund(){  
231 -//  
232 -// OrderRefundReq req = super.getRequest(OrderRefundReq.class);  
233 -// try {  
234 -// OrderRefundResp resp = orderService.applyRefund(req);  
235 -// super.sendSuccessResp(resp);  
236 -// } catch (ServiceException e) {  
237 -// log.error("申请退款出现业务异常", e);  
238 -// super.sendError(e.getCode(), e.getMessage());  
239 -// } catch (Exception e) {  
240 -// log.error("申请退款失败", e);  
241 -// super.sendError(e.getMessage());  
242 -// }  
243 -// }  
244 -//  
245 -// /**  
246 -// * 获取申请的退款订单列表  
247 -// *  
248 -// * 请求协议体:GetRefundOrderListReq  
249 -// * 返回协议体:GetRefundOrderListResp  
250 -// *  
251 -// * @createTime 2014年10月21日 下午2:31:29  
252 -// * @author zhangshirui  
253 -// */  
254 -// @RequestMapping("getRefundOrders")  
255 -// @ResponseBody  
256 -// @DiligrpEndpoint(group = "订单信息",req=GetRefundOrderListReq.class, resp=GetRefundOrderListResp.class,desc="获取申请的退款订单列表")  
257 -// public void getRefundOrders(){  
258 -// GetRefundOrderListReq req = getRequest(GetRefundOrderListReq.class);  
259 -// try {  
260 -// GetRefundOrderListResp resp = orderService.getRefundOrders(req);  
261 -// super.sendSuccessResp(resp);  
262 -// } catch (ServiceException e) {  
263 -// log.error("获取申请的退款订单列表出现业务异常", e);  
264 -// super.sendError(e.getCode(), e.getMessage());  
265 -// } catch (Exception e) {  
266 -// log.error("获取申请的退款订单列表失败", e);  
267 -// super.sendError(e.getMessage());  
268 -// }  
269 -// }  
270 -//  
271 -// /**  
272 -// * 根据订单id查询,退款详情  
273 -// *  
274 -// * 请求协议体:GetRefundDetailReq  
275 -// * 返回协议体:GetRefundDetailResp  
276 -// *  
277 -// * @createTime 2014年9月4日 下午3:09:41  
278 -// * @author zhangshirui  
279 -// */  
280 -// @RequestMapping("getRefundDetail")  
281 -// @ResponseBody  
282 -// @DiligrpEndpoint(group = "订单信息",req=GetRefundDetailReq.class, resp=GetRefundDetailResp.class,desc="根据订单id查询,退款详情")  
283 -// public void getRefundDetail(){  
284 -// GetRefundDetailReq req = getRequest(GetRefundDetailReq.class);  
285 -// try {  
286 -// GetRefundDetailResp resp = orderService.getRefundDetail(req);  
287 -// super.sendSuccessResp(resp);  
288 -// } catch (ServiceException e) {  
289 -// log.error("发送交易识别码出现业务异常", e);  
290 -// super.sendError(e.getCode(), e.getMessage());  
291 -// } catch (Exception e) {  
292 -// log.error("发送交易识别码", e);  
293 -// super.sendError(e.getMessage());  
294 -// }  
295 -// }  
296 -//  
297 -// /**  
298 -// * 确认提货  
299 -// *  
300 -// * 请求协议体:ConfirmPickUpReq  
301 -// * 返回协议体:ConfirmPickUpResp  
302 -// *  
303 -// * @createTime 2014年9月1日 下午6:16:05  
304 -// * @author zhangshirui  
305 -// */  
306 -// @RequestMapping("confirmPickUp")  
307 -// @ResponseBody  
308 -// @DiligrpEndpoint(group = "订单信息",req=ConfirmPickUpReq.class, resp=ConfirmPickUpResp.class,desc="提货完成")  
309 -// public void confirmPickUp(){  
310 -// ConfirmPickUpReq req = super.getRequest(ConfirmPickUpReq.class);  
311 -// try {  
312 -// ConfirmPickUpResp resp = orderService.confirmPickUp(req);  
313 -// super.sendSuccessResp(resp);  
314 -// } catch (ServiceException e) {  
315 -// log.error("确认提货出现业务异常", e);  
316 -// super.sendError(e.getCode(), e.getMessage());  
317 -// } catch (Exception e) {  
318 -// log.error("确认提货失败", e);  
319 -// super.sendError(e.getMessage());  
320 -// }  
321 -// }  
322 -//  
323 -// /**  
324 -// * 评价商品  
325 -// *  
326 -// * 请求协议体:AppraiseGoodsReq  
327 -// * 返回协议体:AppraiseGoodsResp  
328 -// *  
329 -// * @createTime 2014年9月1日 下午6:20:35  
330 -// * @author zhangshirui  
331 -// */  
332 -// @RequestMapping("publishProductAppraise")  
333 -// @ResponseBody  
334 -// @DiligrpEndpoint(group = "订单信息",req=AppraiseGoodsReq.class, resp=AppraiseGoodsResp.class,desc="评价商品")  
335 -// public void publishProductAppraise(){  
336 -// AppraiseGoodsReq req = super.getRequest(AppraiseGoodsReq.class);  
337 -// try {  
338 -// BeanValidator.validator(req);  
339 -// AppraiseGoodsResp resp = orderService.publishProductAppraise(req);  
340 -// super.sendSuccessResp(resp);  
341 -// } catch (ServiceException e) {  
342 -// log.error("评价商品出现业务异常", e);  
343 -// super.sendError(e.getCode(), e.getMessage());  
344 -// } catch (Exception e) {  
345 -// log.error("评价商品失败", e);  
346 -// super.sendError(e.getMessage());  
347 -// }  
348 -// }  
349 -//  
350 -// /**  
351 -// * 发送交易识别码  
352 -// *  
353 -// * 请求协议体:SendTradeCodeReq  
354 -// * 返回协议体:SendTradeCodeResp  
355 -// *  
356 -// * @createTime 2014年9月4日 下午2:33:46  
357 -// * @author zhangshirui  
358 -// */  
359 -// @RequestMapping("sendTradeCode")  
360 -// @ResponseBody  
361 -// @DiligrpEndpoint(group = "订单信息",req=SendTradeCodeReq.class, resp=SendTradeCodeResp.class,desc="发送交易识别码")  
362 -// public void sendTradeCode(){  
363 -// SendTradeCodeReq req = super.getRequest(SendTradeCodeReq.class);  
364 -// try {  
365 -// SendTradeCodeResp resp = orderService.sendTradeCode(req);  
366 -// super.sendSuccessResp(resp);  
367 -// } catch (ServiceException e) {  
368 -// log.error("发送交易识别码出现业务异常", e);  
369 -// super.sendError(e.getCode(), e.getMessage());  
370 -// } catch (Exception e) {  
371 -// log.error("发送交易识别码失败", e);  
372 -// super.sendError(e.getMessage());  
373 -// }  
374 -// }  
375 -//  
376 -//  
377 -// /**  
378 -// * 获取退款原因  
379 -// *  
380 -// * GetRefundReasonReq  
381 -// * GetRefundReasonResp  
382 -// *  
383 -// * @createTime 2014年9月4日 下午3:03:26  
384 -// * @author zhangshirui  
385 -// */  
386 -// @RequestMapping("getRefundReason")  
387 -// @ResponseBody  
388 -// @DiligrpEndpoint(group = "订单信息",req=GetRefundReasonReq.class, resp=GetRefundReasonResp.class,desc="获取退款原因数据字典")  
389 -// public void getRefundReason(){  
390 -//  
391 -// GetRefundReasonReq req = getRequest(GetRefundReasonReq.class);  
392 -// try {  
393 -// GetRefundReasonResp resp = orderService.getRefundReason(req);  
394 -// super.sendSuccessResp(resp);  
395 -// } catch (ServiceException e) {  
396 -// log.error("获取退款原因出现业务异常", e);  
397 -// super.sendError(e.getCode(), e.getMessage());  
398 -// } catch (Exception e) {  
399 -// log.error("获取退款原因失败", e);  
400 -// super.sendError(e.getMessage());  
401 -// }  
402 -//  
403 -// }  
404 -//  
405 -// /**  
406 -// * 获取取消退款原因  
407 -// *  
408 -// * GetCancelOrderReasonReq  
409 -// * GetCancelOrderReasonResp  
410 -// *  
411 -// * @createTime 2014年9月4日 下午3:03:26  
412 -// * @author zhangshirui  
413 -// */  
414 -// @RequestMapping("getCancelReason")  
415 -// @ResponseBody  
416 -// @DiligrpEndpoint(group = "订单信息",req=GetCancelOrderReasonReq.class, resp=GetCancelOrderReasonResp.class,desc="获取取消退款原因数据字典")  
417 -// public void getCancelReason(){  
418 -//  
419 -// GetCancelOrderReasonReq req = getRequest(GetCancelOrderReasonReq.class);  
420 -// try {  
421 -// GetCancelOrderReasonResp resp = orderService.getCancelReason(req);  
422 -// super.sendSuccessResp(resp);  
423 -// } catch (ServiceException e) {  
424 -// log.error("获取取消退款原因出现业务异常", e);  
425 -// super.sendError(e.getCode(), e.getMessage());  
426 -// } catch (Exception e) {  
427 -// log.error("获取取消退款原因", e);  
428 -// super.sendError(e.getMessage());  
429 -// }  
430 -//  
431 -// }  
432 -//  
433 -// /**  
434 -// * 取消退款  
435 -// *  
436 -// * 请求协议体:CancelOrderReq  
437 -// * 返回协议体:CancelOrderResp  
438 -// *  
439 -// * @createTime 2014年9月1日 下午6:08:06  
440 -// * @author zhangshirui  
441 -// */  
442 -// @RequestMapping("cancelRefund")  
443 -// @ResponseBody  
444 -// public void cancelRefund(){  
445 -//  
446 -// CancelRefundReq req = super.getRequest(CancelRefundReq.class);  
447 -// try {  
448 -// CancelRefundResp resp = orderService.cancelRefund(req);  
449 -// super.sendSuccessResp(resp);  
450 -// } catch (ServiceException e) {  
451 -// log.error("取消退款出现业务异常", e);  
452 -// super.sendError(e.getCode(), e.getMessage());  
453 -// } catch (Exception e) {  
454 -// log.error("取消退款失败", e);  
455 -// super.sendError(e.getMessage());  
456 -// }  
457 -// }  
458 -//  
459 -//  
460 -// /**  
461 -// * 取消理赔  
462 -// *  
463 -// * 请求协议体:CancelOrderReq  
464 -// * 返回协议体:CancelOrderResp  
465 -// *  
466 -// * @createTime 2014年9月1日 下午6:08:06  
467 -// * @author zhangshirui  
468 -// */  
469 -// @RequestMapping("cancelClaims")  
470 -// @ResponseBody  
471 -// public void cancelClaims(){  
472 -//  
473 -// CancelClaimsReq req = super.getRequest(CancelClaimsReq.class);  
474 -// try {  
475 -// CancelClaimsResp resp = orderService.cancelClaims(req);  
476 -// super.sendSuccessResp(resp);  
477 -// } catch (ServiceException e) {  
478 -// log.error("取消退款出现业务异常", e);  
479 -// super.sendError(e.getCode(), e.getMessage());  
480 -// } catch (Exception e) {  
481 -// log.error("取消退款失败", e);  
482 -// super.sendError(e.getMessage());  
483 -// }  
484 -// }  
485 -//  
486 -// /**  
487 -// * 获取订单统计数据  
488 -// *  
489 -// * @createTime 2015年3月16日 下午3:58:35  
490 -// * @author zhangshirui  
491 -// */  
492 -// @RequestMapping("getOrderSumInfo")  
493 -// @ResponseBody  
494 -// public void getOrderSumInfo(){  
495 -// GetOrderSumInfoReq req = getRequest(GetOrderSumInfoReq.class);  
496 -// try {  
497 -// GetOrderSumInfoResp resp = orderService.getOrderSumInfo(req);  
498 -// super.sendSuccessResp(resp);  
499 -// } catch (ServiceException e) {  
500 -// log.error("获取订单统计数据出现业务异常", e);  
501 -// super.sendError(e.getCode(), e.getMessage());  
502 -// } catch (Exception e) {  
503 -// log.error("获取订单统计数据", e);  
504 -// super.sendError(e.getMessage());  
505 -// }  
506 -// }  
507 -//  
508 -// /**  
509 -// * 延期提货  
510 -// *  
511 -// * @createTime 2015年3月16日 下午3:58:35  
512 -// * @author zhangshirui  
513 -// */  
514 -// @RequestMapping("delayPickUp")  
515 -// @ResponseBody  
516 -// public void delayPickUp(){  
517 -// DelayPickUpReq req = getRequest(DelayPickUpReq.class);  
518 -// try {  
519 -// DelayPickUpResp resp = orderService.delayPickUp(req);  
520 -// super.sendSuccessResp(resp);  
521 -// } catch (ServiceException e) {  
522 -// log.error("订单延期提货异常", e);  
523 -// super.sendError(e.getCode(), e.getMessage());  
524 -// } catch (Exception e) {  
525 -// log.error("订单延期提货异常", e);  
526 -// super.sendError(e.getMessage());  
527 -// }  
528 -// }  
529 -//  
530 -// /**  
531 -// * 获取协议  
532 -// *  
533 -// * @createTime 2015年3月16日 下午3:58:35  
534 -// * @author zhangshirui  
535 -// */  
536 -// @RequestMapping("getAgreement")  
537 -// @ResponseBody  
538 -// public void getAgreement(HttpServletRequest request){  
539 -// GetAgreementReq req = getRequest(GetAgreementReq.class);  
540 -// try {  
541 -// String dirPath= request.getSession().getServletContext().getRealPath(Constant.ORDER_AGREEMENT_URL);  
542 -// GetAgreementResp resp = orderService.getAgreement(req, dirPath);  
543 -// super.sendSuccessResp(resp);  
544 -// } catch (ServiceException e) {  
545 -// log.error("获取协议异常", e);  
546 -// super.sendError(e.getCode(), e.getMessage());  
547 -// } catch (Exception e) {  
548 -// log.error("获取协议异常", e);  
549 -// super.sendError(e.getMessage());  
550 -// }  
551 -// }  
552 -//  
553 -// /**  
554 -// * 提交退款申诉  
555 -// *  
556 -// * @createTime 2015年3月16日 下午3:58:35  
557 -// * @author zhangshirui  
558 -// */  
559 -// @RequestMapping("submitRefundAppeal")  
560 -// @ResponseBody  
561 -// public void submitRefundAppeal(){  
562 -// SubmitRefundAppealReq req = getRequest(SubmitRefundAppealReq.class);  
563 -// try {  
564 -// SubmitRefundAppealResp resp = orderService.submitRefundAppeal(req);  
565 -// super.sendSuccessResp(resp);  
566 -// } catch (ServiceException e) {  
567 -// log.error("提交退款申诉", e);  
568 -// super.sendError(e.getCode(), e.getMessage());  
569 -// } catch (Exception e) {  
570 -// log.error("提交退款申诉", e);  
571 -// super.sendError(e.getMessage());  
572 -// }  
573 -//  
574 -// }  
575 -//  
576 -// /**  
577 -// * 提交现场交易订单  
578 -// *  
579 -// * @createTime 2015年3月16日 下午3:58:35  
580 -// * @author zhangshirui  
581 -// */  
582 -// //@RequestMapping("submitSpotOrder")  
583 -// //@ResponseBody  
584 -// //public void submitSpotOrder(HttpServletRequest request){  
585 -// // SubmitSpotOrderReq req = getRequest(SubmitSpotOrderReq.class);  
586 -// // try {  
587 -// // SubmitSpotOrderResp resp = orderService.submitSpotOrder(req);  
588 -// // try {  
589 -// // LogResp logResp = resp.getLogResp();  
590 -// // log.info(String.format("提交现场交易订单:[ 设备id<%s>用户名<%s>用户id<%s>店铺id<%s>ip<%s>订单id<%s>商品id<%s> ]"  
591 -// // , req.getDeviceId(), logResp.getUserName(), logResp.getUserId(), logResp.getShopId(), request.getRemoteAddr(), logResp.getOrderId(), logResp.getProductId()));  
592 -// // } catch (Exception e){  
593 -// // log.error("记录下单日志出错!");  
594 -// // }  
595 -// // super.sendSuccessResp(resp);  
596 -// // } catch (ServiceException e) {  
597 -// // log.error("提交现场交易订单", e);  
598 -// // super.sendError(e.getCode(), e.getMessage());  
599 -// // } catch (Exception e) {  
600 -// // log.error("提交现场交易订单", e);  
601 -// // super.sendError(e.getMessage());  
602 -// // }  
603 -// //}  
604 -//  
605 -// ///**  
606 -// // * 修改订单物及验收备注  
607 -// // * @createTime 2015年8月1日 下午6:16:05  
608 -// // * @author wujiaqiang  
609 -// // */  
610 -// //@RequestMapping("modifyOrderLogisticsRemarks")  
611 -// //@ResponseBody  
612 -// //public void modifyOrderLogisticsRemarks() {  
613 -// // ModifyOrderLogisticsRemarksReq req = super.getRequest(ModifyOrderLogisticsRemarksReq.class);  
614 -// // try {  
615 -// // ModifyOrderLogisticsRemarksResp resp = orderService.modifyOrderLogisticsRemarks(req);  
616 -// // super.sendSuccessResp(resp);  
617 -// // } catch (ServiceException e) {  
618 -// // log.error("修改订单物及验收备注", e);  
619 -// // super.sendError(e.getCode(), e.getMessage());  
620 -// // } catch (Exception e) {  
621 -// // log.error("修改订单物及验收备注", e);  
622 -// // super.sendError(e.getMessage());  
623 -// // }  
624 -// //}  
625 -//  
626 -// /**  
627 -// *  
628 -// *  
629 -// * @createTime 2014年9月1日 下午5:32:02  
630 -// * @author duanyugen  
631 -// * @return  
632 -// */  
633 -// //@RequestMapping("getOrdersByLogId")  
634 -// //@ResponseBody  
635 -// //@DiligrpEndpoint(group = "订单信息",req=SearchOrdersByLogisticsIdReq.class, resp=SearchOrderResp.class,desc="获取订单列表")  
636 -// //public void getOrdersByLogId(){  
637 -// //  
638 -// // SearchOrdersByLogisticsIdReq req = super.getRequest(SearchOrdersByLogisticsIdReq.class);  
639 -// // try {  
640 -// // SearchOrderResp resp = orderService.getOrdersByLogisticsId(req);  
641 -// // super.sendSuccessResp(resp);  
642 -// // }catch (ServiceException e) {  
643 -// // log.error("获取订单列表出现业务异常", e);  
644 -// // super.sendError(e.getCode(), e.getMessage());  
645 -// // }catch (Exception e) {  
646 -// // log.error("获取订单列表失败", e);  
647 -// // super.sendError(e.getMessage());  
648 -// // }  
649 -// //}  
650 -//  
651 -//  
652 -// /**  
653 -// * 一键收货  
654 -// *  
655 -// * @createTime 2014年9月1日 下午5:32:02  
656 -// * @author weili  
657 -// * @return  
658 -// */  
659 -// @RequestMapping("aKeyReceiptGoods")  
660 -// @ResponseBody  
661 -// @DiligrpEndpoint(group = "一键收货",req=AKeyReceiptGoodsReq.class, resp=AKeyReceiptGoodsResp.class,desc="一键收货")  
662 -// public void aKeyReceiptGoods(){  
663 -//  
664 -// AKeyReceiptGoodsReq req = super.getRequest(AKeyReceiptGoodsReq.class);  
665 -// try {  
666 -// AKeyReceiptGoodsResp resp = orderService.aKeyReceiptGoods(req);  
667 -// super.sendSuccessResp(resp);  
668 -// }catch (ServiceException e) {  
669 -// log.error("一键收货出现业务异常", e);  
670 -// super.sendError(e.getCode(), e.getMessage());  
671 -// }catch (Exception e) {  
672 -// log.error("一键收货失败", e);  
673 -// super.sendError(e.getMessage());  
674 -// }  
675 -// }  
676 -//  
677 -//  
678 -// /**  
679 -// * 申请理赔  
680 -// *  
681 -// * 请求协议体:ApplyCompensateReq  
682 -// * 返回协议体:ApplyCompensateResp  
683 -// *  
684 -// * @createTime 2016年9月19日 下午6:14:12  
685 -// * @author 韦力  
686 -// */  
687 -// @RequestMapping("applyCompensate")  
688 -// @ResponseBody  
689 -// public void applyCompensate(){  
690 -//  
691 -// ApplyCompensateReq req = super.getRequest(ApplyCompensateReq.class);  
692 -// try {  
693 -// ApplyCompensateResp resp = orderService.applyCompensate(req);  
694 -// super.sendSuccessResp(resp);  
695 -// } catch (ServiceException e) {  
696 -// log.error("申请理赔出现业务异常", e);  
697 -// super.sendError(e.getCode(), e.getMessage());  
698 -// } catch (Exception e) {  
699 -// log.error("申请理赔失败", e);  
700 -// super.sendError(e.getMessage());  
701 -// }  
702 -// }  
703 -//  
704 -// /**  
705 -// * 理赔申诉  
706 -// *  
707 -// * 请求协议体:CompensateAppealReq  
708 -// * 返回协议体:CompensateAppealResp  
709 -// *  
710 -// * @createTime 2016年9月19日 下午6:14:12  
711 -// * @author weili  
712 -// */  
713 -// @RequestMapping("compensateAppeal")  
714 -// @ResponseBody  
715 -// public void compensateAppeal(){  
716 -// CompensateAppealReq req = super.getRequest(CompensateAppealReq.class);  
717 -// try {  
718 -// CompensateAppealResp resp = orderService.compensateAppeal(req);  
719 -// super.sendSuccessResp(resp);  
720 -// } catch (ServiceException e) {  
721 -// log.error("理赔申诉出现业务异常", e);  
722 -// super.sendError(e.getCode(), e.getMessage());  
723 -// } catch (Exception e) {  
724 -// log.error("理赔申诉失败", e);  
725 -// super.sendError(e.getMessage());  
726 -// }  
727 -// }  
728 -//  
729 -// /**  
730 -// * 获取理赔列表  
731 -// *  
732 -// * 请求协议体:GetClaimsListReq  
733 -// * 返回协议体:GetClaimsListResp  
734 -// * @createTime 2016年9月19日 下午6:14:12  
735 -// * @author weili  
736 -// */  
737 -// @RequestMapping("getClaimsList")  
738 -// @ResponseBody  
739 -// public void getClaimsList(){  
740 -// GetClaimsListReq req = super.getRequest(GetClaimsListReq.class);  
741 -// try {  
742 -// GetClaimsListResp resp = orderService.getClaimsList(req);  
743 -// super.sendSuccessResp(resp);  
744 -// } catch (ServiceException e) {  
745 -// log.error("理赔申诉出现业务异常", e);  
746 -// super.sendError(e.getCode(), e.getMessage());  
747 -// } catch (Exception e) {  
748 -// log.error("理赔申诉失败", e);  
749 -// super.sendError(e.getMessage());  
750 -// }  
751 -// }  
752 -//  
753 -// /**  
754 -// * 获取理赔详情  
755 -// *  
756 -// * 请求协议体:GetClaimsDetailReq  
757 -// * 返回协议体:GetClaimsDetailResp  
758 -// * @createTime 2016年9月19日 下午6:14:12  
759 -// * @author weili  
760 -// */  
761 -// @RequestMapping("getClaimsDetail")  
762 -// @ResponseBody  
763 -// public void getClaimsDetail(){  
764 -// GetClaimsDetailReq req = super.getRequest(GetClaimsDetailReq.class);  
765 -// try {  
766 -// GetClaimsDetailResp resp = orderService.getClaimsDetail(req);  
767 -// super.sendSuccessResp(resp);  
768 -// } catch (ServiceException e) {  
769 -// log.error("理赔申诉出现业务异常", e);  
770 -// super.sendError(e.getCode(), e.getMessage());  
771 -// } catch (Exception e) {  
772 -// log.error("理赔申诉失败", e);  
773 -// super.sendError(e.getMessage());  
774 -// }  
775 -// }  
776 -//  
777 -// /**  
778 -// * 确认理赔  
779 -// *  
780 -// * 请求协议体:AffirmClaimsReq  
781 -// * 返回协议体:AffirmClaimsResp  
782 -// * @createTime 2016年9月19日 下午6:14:12  
783 -// * @author weili  
784 -// */  
785 -// @RequestMapping("affirmClaims")  
786 -// @ResponseBody  
787 -// public void affirmClaims(){  
788 -// AffirmClaimsReq req = super.getRequest(AffirmClaimsReq.class);  
789 -// try {  
790 -// AffirmClaimsResp resp = orderService.affirmClaims(req);  
791 -// super.sendSuccessResp(resp);  
792 -// } catch (ServiceException e) {  
793 -// log.error("理赔申诉出现业务异常", e);  
794 -// super.sendError(e.getCode(), e.getMessage());  
795 -// } catch (Exception e) {  
796 -// log.error("理赔申诉失败", e);  
797 -// super.sendError(e.getMessage());  
798 -// }  
799 -// }  
800 -//  
801 -// /**  
802 -// * 获取理赔原因(数据字典)  
803 -// *  
804 -// * 请求协议体:GetClaimsDetailReq  
805 -// * 返回协议体:GetClaimsDetailResp  
806 -// * @createTime 2016年9月19日 下午6:14:12  
807 -// * @author weili  
808 -// */  
809 -// @RequestMapping("getClaimsReasons")  
810 -// @ResponseBody  
811 -// public void getClaimsReasons(){  
812 -// GetClaimsReasonsReq req = super.getRequest(GetClaimsReasonsReq.class);  
813 -// try {  
814 -// GetClaimsReasonsResp resp = orderService.getClaimsReasons(req);  
815 -// super.sendSuccessResp(resp);  
816 -// } catch (ServiceException e) {  
817 -// log.error("理赔申诉出现业务异常", e);  
818 -// super.sendError(e.getCode(), e.getMessage());  
819 -// } catch (Exception e) {  
820 -// log.error("理赔申诉失败", e);  
821 -// super.sendError(e.getMessage());  
822 -// }  
823 -// }  
824 -//  
825 -// /**  
826 -// * 获取理赔要求(数据字典)  
827 -// *  
828 -// * 请求协议体:GetClaimsDetailReq  
829 -// * 返回协议体:GetClaimsDetailResp  
830 -// * @createTime 2016年9月19日 下午6:14:12  
831 -// * @author weili  
832 -// */  
833 -// @RequestMapping("getClaimsRequires")  
834 -// @ResponseBody  
835 -// public void getClaimsRequires(){  
836 -// GetClaimsRequiresReq req = super.getRequest(GetClaimsRequiresReq.class);  
837 -// try {  
838 -// GetClaimsRequiresResp resp = orderService.getClaimsRequires(req);  
839 -// super.sendSuccessResp(resp);  
840 -// } catch (ServiceException e) {  
841 -// log.error("理赔申诉出现业务异常", e);  
842 -// super.sendError(e.getCode(), e.getMessage());  
843 -// } catch (Exception e) {  
844 -// log.error("理赔申诉失败", e);  
845 -// super.sendError(e.getMessage());  
846 -// }  
847 -// }  
848 -//} 1 +package com.diligrp.mobsite.getway.web.api.buyer.user;
  2 +
  3 +import com.diligrp.mobsite.getway.domain.except.ServiceException;
  4 +import com.diligrp.mobsite.getway.domain.protocol.common.LogResp;
  5 +import com.diligrp.mobsite.getway.domain.protocol.order.*;
  6 +import com.diligrp.mobsite.getway.service.buyer.user.OrderService;
  7 +import com.diligrp.mobsite.getway.web.api.base.BaseApiController;
  8 +import com.diligrp.mobsite.getway.web.utils.BeanValidator;
  9 +import com.diligrp.mobsite.getway.web.utils.DiligrpEndpoint;
  10 +import io.swagger.annotations.ApiOperation;
  11 +import org.apache.log4j.Logger;
  12 +import org.springframework.stereotype.Controller;
  13 +import org.springframework.web.bind.annotation.ModelAttribute;
  14 +import org.springframework.web.bind.annotation.RequestMapping;
  15 +import org.springframework.web.bind.annotation.RequestMethod;
  16 +import org.springframework.web.bind.annotation.ResponseBody;
  17 +
  18 +import javax.annotation.Resource;
  19 +import javax.servlet.http.HttpServletRequest;
  20 +
  21 +
  22 +/**
  23 + * <B>Description</B> 订单操作 <br />
  24 + * <B>Copyright</B> Copyright (c) 2014 www.diligrp.com All rights reserved. <br />
  25 + * 本软件源代码版权归地利集团,未经许可不得任意复制与传播.<br />
  26 + * <B>Company</B> 地利集团
  27 + * @createTime 2014年9月1日 下午2:30:41
  28 + * @author zhangshirui
  29 + */
  30 +@Controller
  31 +@RequestMapping("/mobsiteApp/order/")
  32 +public class OrderController extends BaseApiController {
  33 +
  34 + @Resource
  35 + private OrderService orderService;
  36 +
  37 + private static Logger log = Logger.getLogger(OrderController.class);
  38 +
  39 + /**
  40 + * 获取订单列表
  41 + *
  42 + * 请求协议体:SearchOrderReq
  43 + * 返回协议体:SearchOrderResp
  44 + *
  45 + * @createTime 2014年9月1日 下午5:32:02
  46 + * @author zhangshirui
  47 + * @return
  48 + */
  49 + @ApiOperation(value = "获取订单列表", httpMethod = "POST",response = SearchOrderResp.class)
  50 + @RequestMapping(value = "/getOrders",method = RequestMethod.POST)
  51 + @ResponseBody
  52 + public void getOrders(@ModelAttribute SearchOrderReq temp){
  53 +
  54 + SearchOrderReq req = super.getRequest(SearchOrderReq.class);
  55 + try {
  56 + SearchOrderResp resp = orderService.getOrders(req);
  57 + super.sendSuccessResp(resp);
  58 + }catch (ServiceException e) {
  59 + log.error("获取订单列表出现业务异常", e);
  60 + super.sendError(e.getCode(), e.getMessage());
  61 + }catch (Exception e) {
  62 + log.error("获取订单列表失败", e);
  63 + super.sendError(e.getMessage());
  64 + }
  65 + }
  66 +
  67 + /**
  68 + * 根据订单id查询订单
  69 + *
  70 + * 请求协议体:GetOrderReq
  71 + * 返回协议体:GetOrderResp
  72 + *
  73 + * @createTime 2014年9月1日 下午6:39:10
  74 + * @author zhangshirui
  75 + */
  76 + @RequestMapping("getOrderById")
  77 + @ResponseBody
  78 + @DiligrpEndpoint(group = "订单信息",req=GetOrderReq.class, resp=GetOrderResp.class,desc="根据订单id查询订单详情")
  79 + public void getOrderById(){
  80 +
  81 + GetOrderReq req = super.getRequest(GetOrderReq.class);
  82 + try {
  83 + GetOrderResp resp = orderService.getOrderById(req);
  84 + super.sendSuccessResp(resp);
  85 + }catch (ServiceException e) {
  86 + log.error("获取订单详情出现业务异常", e);
  87 + super.sendError(e.getCode(), e.getMessage());
  88 + } catch (Exception e) {
  89 + log.error("获取订单详情失败", e);
  90 + super.sendError(e.getMessage());
  91 + }
  92 + }
  93 +
  94 +
  95 + /**
  96 + * 提交订单
  97 + *
  98 + * 请求协议体:SubmitOrderReq
  99 + * 返回协议体:SubmitOrderResp
  100 + *
  101 + * @createTime 2014年9月1日 下午6:05:23
  102 + * @author zhangshirui
  103 + */
  104 + @RequestMapping("submitOrderNew")
  105 + @ResponseBody
  106 + @DiligrpEndpoint(group = "订单信息",req=SubmitOrderReq.class, resp=SubmitOrderResp.class,desc="提交订单")
  107 + public void submitOrderNew(HttpServletRequest request){
  108 +
  109 + SubmitOrderReq req = super.getRequest(SubmitOrderReq.class);
  110 + try {
  111 + BeanValidator.validator(req);
  112 + SubmitOrderResp resp = orderService.submitOrderNew(req);
  113 + try {
  114 + LogResp logResp = resp.getLogResp();
  115 + log.info(String.format("提交订单:[ 设备id<%s>用户名<%s>用户id<%s>店铺id<%s>ip<%s>订单id<%s>商品id<%s> ]"
  116 + , req.getDeviceId(), logResp.getUserName(), logResp.getUserId(), logResp.getShopId(), request.getRemoteAddr(), logResp.getOrderId(), logResp.getProductId()));
  117 + }catch (Exception e) {
  118 + log.error("记录下单日志出错!");
  119 + }
  120 + super.sendSuccessResp(resp);
  121 + } catch (ServiceException e) {
  122 + log.error("提交订单出现业务异常", e);
  123 + super.sendError(e.getCode(), e.getMessage());
  124 + } catch (Exception e) {
  125 + log.error("提交订单失败", e);
  126 + super.sendError(e.getMessage());
  127 + }
  128 + }
  129 +
  130 + ///**
  131 + // * 线下付款
  132 + // *
  133 + // * 请求协议体:PayofflineReq
  134 + // * 返回协议体:PayofflineResp
  135 + // *
  136 + // * @createTime 2014年9月1日 下午6:05:23
  137 + // * @author zhangshirui
  138 + // */
  139 + //@RequestMapping("payoffline")
  140 + //@ResponseBody
  141 + //public void payoffline(){
  142 + // PayofflineReq req = super.getRequest(PayofflineReq.class);
  143 + // try {
  144 + // BeanValidator.validator(req);
  145 + // PayofflineResp resp = orderService.payoffline(req);
  146 + // super.sendSuccessResp(resp);
  147 + // } catch (ServiceException e) {
  148 + // log.error("录入线下付款信息出现业务异常", e);
  149 + // super.sendError(e.getCode(), e.getMessage());
  150 + // } catch (Exception e) {
  151 + // log.error("录入线下付款信息失败", e);
  152 + // super.sendError(e.getMessage());
  153 + // }
  154 + //}
  155 +
  156 +
  157 +
  158 +
  159 + /**
  160 + * 取消订单
  161 + *
  162 + * 请求协议体:CancelOrderReq
  163 + * 返回协议体:CancelOrderResp
  164 + *
  165 + * @createTime 2014年9月1日 下午6:08:06
  166 + * @author zhangshirui
  167 + */
  168 + @RequestMapping("cancelOrder")
  169 + @ResponseBody
  170 + @DiligrpEndpoint(group = "订单信息",req=CancelOrderReq.class, resp=CancelOrderResp.class,desc="取消订单")
  171 + public void cancelOrder(){
  172 +
  173 + CancelOrderReq req = super.getRequest(CancelOrderReq.class);
  174 + try {
  175 + CancelOrderResp resp = orderService.cancelOrder(req);
  176 + super.sendSuccessResp(resp);
  177 + } catch (ServiceException e) {
  178 + log.error("取消订单出现业务异常", e);
  179 + super.sendError(e.getCode(), e.getMessage());
  180 + } catch (Exception e) {
  181 + log.error("取消订单失败", e);
  182 + super.sendError(e.getMessage());
  183 + }
  184 + }
  185 +
  186 +
  187 + /**
  188 + * 确认提货
  189 + *
  190 + * 请求协议体:ConfirmPickUpReq
  191 + * 返回协议体:ConfirmPickUpResp
  192 + *
  193 + * @createTime 2014年9月1日 下午6:16:05
  194 + * @author zhangshirui
  195 + */
  196 + @RequestMapping("confirmPickUp")
  197 + @ResponseBody
  198 + @DiligrpEndpoint(group = "订单信息",req=ConfirmPickUpReq.class, resp=ConfirmPickUpResp.class,desc="提货完成")
  199 + public void confirmPickUp(){
  200 + ConfirmPickUpReq req = super.getRequest(ConfirmPickUpReq.class);
  201 + try {
  202 + ConfirmPickUpResp resp = orderService.confirmPickUp(req);
  203 + super.sendSuccessResp(resp);
  204 + } catch (ServiceException e) {
  205 + log.error("确认提货出现业务异常", e);
  206 + super.sendError(e.getCode(), e.getMessage());
  207 + } catch (Exception e) {
  208 + log.error("确认提货失败", e);
  209 + super.sendError(e.getMessage());
  210 + }
  211 + }
  212 +
  213 + /**
  214 + * 评价商品
  215 + *
  216 + * 请求协议体:AppraiseGoodsReq
  217 + * 返回协议体:AppraiseGoodsResp
  218 + *
  219 + * @createTime 2014年9月1日 下午6:20:35
  220 + * @author zhangshirui
  221 + */
  222 + @RequestMapping("publishProductAppraise")
  223 + @ResponseBody
  224 + @DiligrpEndpoint(group = "订单信息",req=AppraiseGoodsReq.class, resp=AppraiseGoodsResp.class,desc="评价商品")
  225 + public void publishProductAppraise(){
  226 + AppraiseGoodsReq req = super.getRequest(AppraiseGoodsReq.class);
  227 + try {
  228 + BeanValidator.validator(req);
  229 + AppraiseGoodsResp resp = orderService.publishProductAppraise(req);
  230 + super.sendSuccessResp(resp);
  231 + } catch (ServiceException e) {
  232 + log.error("评价商品出现业务异常", e);
  233 + super.sendError(e.getCode(), e.getMessage());
  234 + } catch (Exception e) {
  235 + log.error("评价商品失败", e);
  236 + super.sendError(e.getMessage());
  237 + }
  238 + }
  239 +
  240 + ///**
  241 + // * 发送交易识别码
  242 + // *
  243 + // * 请求协议体:SendTradeCodeReq
  244 + // * 返回协议体:SendTradeCodeResp
  245 + // *
  246 + // * @createTime 2014年9月4日 下午2:33:46
  247 + // * @author zhangshirui
  248 + // */
  249 + //@RequestMapping("sendTradeCode")
  250 + //@ResponseBody
  251 + //@DiligrpEndpoint(group = "订单信息",req=SendTradeCodeReq.class, resp=SendTradeCodeResp.class,desc="发送交易识别码")
  252 + //public void sendTradeCode(){
  253 + // SendTradeCodeReq req = super.getRequest(SendTradeCodeReq.class);
  254 + // try {
  255 + // SendTradeCodeResp resp = orderService.sendTradeCode(req);
  256 + // super.sendSuccessResp(resp);
  257 + // } catch (ServiceException e) {
  258 + // log.error("发送交易识别码出现业务异常", e);
  259 + // super.sendError(e.getCode(), e.getMessage());
  260 + // } catch (Exception e) {
  261 + // log.error("发送交易识别码失败", e);
  262 + // super.sendError(e.getMessage());
  263 + // }
  264 + //}
  265 +
  266 +
  267 +}