Преглед изворни кода

Merge branch 'master' of http://git.iamberry.com/hexiugang/iamberry-common-parent

wangxiaoming пре 7 година
родитељ
комит
3adf53e8fb

+ 9 - 0
watero-rst-core/src/main/java/com.iamberry.rst.core/cm/ComplaintQuestionInfo.java

@@ -24,6 +24,7 @@ public class ComplaintQuestionInfo implements Serializable {
     private Integer questionNotSolvedNum;//未解决总数
 
     private Integer complaintId; //问题分类id
+    private Integer complaintType;//咨询类型 1.售前 2.售后 3.其它
 
     public Integer getQuestionId() {
         return questionId;
@@ -112,4 +113,12 @@ public class ComplaintQuestionInfo implements Serializable {
     public void setComplaintId(Integer complaintId) {
         this.complaintId = complaintId;
     }
+
+    public Integer getComplaintType() {
+        return complaintType;
+    }
+
+    public void setComplaintType(Integer complaintType) {
+        this.complaintType = complaintType;
+    }
 }

+ 10 - 0
watero-rst-core/src/main/java/com.iamberry.rst.core/pts/PtsMachineStatistics.java

@@ -22,6 +22,8 @@ public class PtsMachineStatistics implements Serializable{
 
     private String nodeDes;//工序选项描述
 
+    private String produceId;//产品id
+
     public String getYear() {
         return year;
     }
@@ -93,4 +95,12 @@ public class PtsMachineStatistics implements Serializable{
     public void setNodeDes(String nodeDes) {
         this.nodeDes = nodeDes;
     }
+
+    public String getProduceId() {
+        return produceId;
+    }
+
+    public void setProduceId(String produceId) {
+        this.produceId = produceId;
+    }
 }

+ 3 - 0
watero-rst-service/src/main/java/com/iamberry/rst/service/cm/mapper/complaintQuestionInfoMapper.xml

@@ -61,6 +61,9 @@
       <if test="questionName !=null and questionName !=''">
         AND question_name like CONCAT('%',#{questionName},'%')
       </if>
+      <if test="complaintType != null">
+        AND tb_rst_complaint_type.complaint_consulting_type = #{complaintType}
+      </if>
       AND question_state = 1
     </where>
     ORDER BY question_create_time DESC

+ 4 - 0
watero-rst-service/src/main/java/com/iamberry/rst/service/pts/mapper/machineMapper.xml

@@ -291,6 +291,7 @@
             tb_rst_pts_machine
         where YEAR (machine_produced_time) = #{year}
         AND machine_produce_type = #{machineType}
+        AND machine_produce_id = #{produceId}
         GROUP BY
             YEAR (machine_produced_time),
             MONTH (machine_produced_time)
@@ -334,6 +335,8 @@
         DATE_SUB(CURDATE(), INTERVAL 7 DAY) &lt;= date(machine_produced_time)
         and
         machine_produce_type = #{machineType}
+        and
+        machine_produce_id = #{produceId}
         GROUP BY DAY(machine_produced_time)
         UNION
         SELECT DAY (DATE_SUB(CURDATE(), INTERVAL 7 DAY)) AS day,date_format(DATE_SUB(CURDATE(), INTERVAL 7 DAY) ,'%m.%d' )  AS date,'0' as num FROM tb_rst_pts_machine
@@ -367,6 +370,7 @@
         FROM
             tb_rst_pts_machine
         where machine_produce_type = #{machineType}
+        and machine_produce_id = #{produceId}
     </select>
 
     <!--根据工序id统计生成机器时选项被选择的次数-->

+ 1 - 1
watero-rst-web/src/main/java/com/iamberry/rst/controllers/pts/AdminMachineController.java

@@ -308,7 +308,6 @@ public class AdminMachineController {
         Produce produce = new Produce();
         if (produceId == null || produceId.equals("")) {
             produce = produceService.getProduceByOne();//默认为第一个产品
-
         } else {
             produce.setProduceId(Integer.valueOf(produceId));
             produce = produceService.getProduce(produce);
@@ -320,6 +319,7 @@ public class AdminMachineController {
         String year = String.valueOf(date.get(Calendar.YEAR));//年
         ptsMachineStatistics.setYear(year);
         ptsMachineStatistics.setMachineType(produce.getProduceType());
+        ptsMachineStatistics.setProduceId(String.valueOf(produce.getProduceId()));
         //查询1-12月每月生产机器数
         List<PtsMachineStatistics> ptsMachineStatisticsList = machineService.monthStatistics(ptsMachineStatistics);
         if (ptsMachineStatisticsList.size() > 0) {

+ 3 - 0
watero-rst-web/src/main/webapp/WEB-INF/views/cm/customer/add_customer.ftl

@@ -1284,11 +1284,13 @@
         var complaintId;
         var smallClassId;
         var questionName;
+        var customerCounselType;
         var questionId;
         if(type == "p"){
             complaintId = $("[name='complaintId']").val();
             smallClassId = $("[name='smallClassId']").val();
             questionName = $("[name='questionIdMsg']").val();
+            customerCounselType = $("[name='customerCounselType']:checked").val();
         }else if(type == "m"){
             questionId = complaint_questionId;
         }
@@ -1299,6 +1301,7 @@
                 complaintId : complaintId,
                 smallClassId : smallClassId,
                 questionName : questionName,
+                /*complaintType : customerCounselType,*/
                 questionId : questionId
             },
             url: "${path}/admin/complaintQuestion/list_complaintQuestion",

+ 12 - 6
watero-rst-web/src/main/webapp/WEB-INF/views/cm/customer/custome_detail.ftl

@@ -94,7 +94,7 @@
         </div>
         <div class="row cl">
             <label class="form-label col-1 col-sm-1">用户信息:</label>
-            <div class="formControls col-5 col-sm-5">
+            <div class="formControls col-5 col-sm-5" style="margin-top: 2px;">
                 <label id="customerName"></label>
                 <label id="customerTel"></label>
             </div>
@@ -165,7 +165,7 @@
                 </div>
 
             </div>
-            <div class="row cl">
+            <div class="row cl" id="sendMergeAddressDiv">
                 <label class="form-label col-1 col-sm-1">收货地址:</label>
                 <div class="formControls col-5 col-sm-5">
                     <label id="relationSendMergeAddress"></label>
@@ -181,7 +181,7 @@
         </div>
 
         <div class="row cl">
-            <label class="form-label col-1 col-sm-1">处理描述:</label>
+            <label class="form-label col-1 col-sm-1">客服备注:</label>
             <div class="formControls col-7 col-sm-7" id="describeHandleDesc" style="border: 1px solid #ddd;">
             </div>
         </div>
@@ -289,7 +289,7 @@
                     $('#customerCounselType').html(customerCounsel);
                     $('#typeName').html(customer.typeName);
                     $('#describeTitle').html(customer.describeTitle);
-                    $('#questionProfile').html(customer.questionProfile);
+                    $('#questionProfile').html(customer.describeHandleDesc);
                     $('#customerName').html(customer.customerName);
                     $('#customerTel').html(customer.customerTel);
                     var txtcustomerIsSolve = '';
@@ -299,8 +299,14 @@
                         case 3:txtcustomerIsSolve = '换新';break;
                         case 4:txtcustomerIsSolve = '维修';break;
                         case 5:txtcustomerIsSolve = '补发';break;
-                        case 6:txtcustomerIsSolve = '退货';break;
-                        case 7:txtcustomerIsSolve = '无理由退货';break;
+                        case 6:
+                            $('#sendMergeAddressDiv').hide();
+                            txtcustomerIsSolve = '退货';
+                            break;
+                        case 7:
+                            $('#sendMergeAddressDiv').hide();
+                            txtcustomerIsSolve = '无理由退货';
+                            break;
                     }
                     $('#customerIsSolve').html(txtcustomerIsSolve);
                     $('#companyName').html(convertUndefinedToEmpty(customer.companyName)+"-"+convertUndefinedToEmpty(customer.storeName));

+ 15 - 2
watero-rst-web/src/main/webapp/WEB-INF/views/cm/customer/order_list.ftl

@@ -144,6 +144,7 @@
                     <th width="80">订单金额</th>
                     <th width="80">购买产品</th>
                     <th width="80">购买日期</th>
+                    <th width="80">订单状态</th>
                     <th width="100">收货地址</th>
                     <th width="80">操作</th>
                 </tr>
@@ -151,7 +152,7 @@
                 <tbody id="orderAll">
 
                      <tr class="text-c">
-                         <td colspan="11">请输入搜索条件,搜索订单~
+                         <td colspan="12">请输入搜索条件,搜索订单~
                          </td>
                      </tr>
 
@@ -346,6 +347,17 @@
                                 productsHtml += '<span class="label label-success radius" title="'+ salesOrderItem[j].itemProductName +'*'+ salesOrderItem[j].itemNum +'">' + item + '</span>';
                         }
                         var time = formatDate(new Date(salesOrder.salesCreateTime),"yyyy-MM-dd");
+                        var orderStatus = null;
+                        if(salesOrder.salesOrderStatus == 1){
+                            orderStatus = "正常";
+                        }
+                        if(salesOrder.salesOrderStatus == 2){
+                            orderStatus = "换货";
+                        }
+                        if(salesOrder.salesOrderStatus == 3){
+                            orderStatus = "退货";
+                        }
+
                         html += '<tr class="text-c">' +
                                 ' <td>'+ convertUndefinedToEmpty(salesOrder.companyName) +'</td>' +
                                 ' <td>'+ convertUndefinedToEmpty(salesOrder.storeName) +'</td>' +
@@ -356,12 +368,13 @@
                                 ' <td>'+ salesOrder.salesAmount/100 +'</td>' +
                                 ' <td>'+ productsHtml +'</td>' +
                                 ' <td>'+ time +'</td>' +
+                                ' <td>'+ orderStatus +'</td>' +
                                 ' <td>'+ salesOrder.salesAddressInfo +'</td>' +
                                 ' <td><a style="" class="select-order" href="javascript:void(0);" title="选择订单" onclick="selectOrderInfo('+ salesOrder.salesId +')" >选择订单</a></td>' +
                                 ' </tr>';
                     }
                 }else{
-                    html = '<tr class="text-c"><td colspan="11">没有搜索到订单,请点击“添加订单”按钮,添加订单。</td></tr>';
+                    html = '<tr class="text-c"><td colspan="12">没有搜索到订单,请点击“添加订单”按钮,添加订单。</td></tr>';
                 }
                 $("#orderAll").html(html);
                 layer.close(index);