Browse Source

[feat]售后管理:

售后客诉通知
修改客诉通知列表展示的数据来源,展示客诉通知详情中的数据
dev
liuxiaoxu 6 months ago
parent
commit
5e6a136bc6
  1. 4
      ruoyi-admin/src/main/java/com/ruoyi/aftersales/controller/AftersalesComplaintNoticeController.java
  2. 43
      ruoyi-admin/src/main/resources/mapper/aftersales/AftersalesComplaintNoticeDetailMapper.xml
  3. 37
      ruoyi-admin/src/main/resources/templates/aftersales/complaintNotice/add.html

4
ruoyi-admin/src/main/java/com/ruoyi/aftersales/controller/AftersalesComplaintNoticeController.java

@ -54,10 +54,10 @@ public class AftersalesComplaintNoticeController extends BaseController
@RequiresPermissions("aftersales:complaintNotice:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(AftersalesComplaintNotice aftersalesComplaintNotice)
public TableDataInfo list(AftersalesComplaintNoticeDetail complaintNoticeDetail)
{
startPage();
List<AftersalesComplaintNotice> list = aftersalesComplaintNoticeService.selectAftersalesComplaintNoticeList(aftersalesComplaintNotice);
List<AftersalesComplaintNoticeDetail> list = complaintNoticeDetailService.selectAftersalesComplaintNoticeDetailList(complaintNoticeDetail);
return getDataTable(list);
}

43
ruoyi-admin/src/main/resources/mapper/aftersales/AftersalesComplaintNoticeDetailMapper.xml

@ -40,43 +40,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<sql id="selectAftersalesComplaintNoticeDetailVo">
select complaint_notice_detail_id, complaint_notice_code, make_no, user_id, delivery_goods_num, emergency_degree, complaint_problem, closing_procedures, adverse_report_url, customer_id, customer_name, device_model_code, device_model_name, sn_code, device_running_number, material_no, material_name, material_type, material_photoUrl, material_brand, material_unit, material_describe, material_process_method, shipped_goods_sum, material_sum, enterprise_sum, create_by, create_time, update_by, update_time, remark from aftersales_complaint_notice_detail
<where>
<if test="complaintNoticeCode != null and complaintNoticeCode != ''"> and complaint_notice_code = #{complaintNoticeCode}</if>
<if test="makeNo != null and makeNo != ''"> and make_no = #{makeNo}</if>
<if test="emergencyDegree != null and emergencyDegree != ''"> and emergency_degree = #{emergencyDegree}</if>
<if test="closingProcedures != null and closingProcedures != ''"> and closing_procedures = #{closingProcedures}</if>
<if test="materialNo != null and materialNo != ''"> and material_no = #{materialNo}</if>
<if test="materialName != null and materialName != ''"> and material_name like concat('%', #{materialName}, '%')</if>
<if test="params.beginCreateTime != null and params.beginCreateTime != '' and params.endCreateTime != null and params.endCreateTime != ''"> and create_time between #{params.beginCreateTime} and #{params.endCreateTime}</if>
</where>
</sql>
<select id="selectAftersalesComplaintNoticeDetailList" parameterType="AftersalesComplaintNoticeDetail"
resultMap="AftersalesComplaintNoticeDetailResult">
select acnd.complaint_notice_detail_id,
acnd.complaint_notice_code,
acnd.make_no,
acnd.user_id,
acnd.delivery_goods_num,
acnd.emergency_degree,
acnd.complaint_problem,
acnd.closing_procedures,
acnd.adverse_report_url,
acnd.customer_id,
acnd.customer_name,
acnd.device_model_code,
acnd.device_model_name,
acnd.sn_code,
acnd.device_running_number,
acnd.material_no,
acnd.material_name,
acnd.material_type,
acnd.material_photoUrl,
acnd.material_brand,
acnd.material_unit,
acnd.material_describe,
acnd.material_process_method,
acnd.shipped_goods_sum,
acnd.material_sum,
acnd.enterprise_sum,
acnd.create_by,
acnd.create_time,
acnd.update_by,
acnd.update_time,
acnd.remark
from aftersales_complaint_notice_detail acnd
left join sys_makeorder_bom smb on smb.make_no = acnd.make_no
<include refid="selectAftersalesComplaintNoticeDetailVo"/>
</select>
<select id="selectAftersalesComplaintNoticeDetailById" parameterType="Long" resultMap="AftersalesComplaintNoticeDetailResult">

37
ruoyi-admin/src/main/resources/templates/aftersales/complaintNotice/add.html

@ -64,7 +64,6 @@
<!--用于可以修改列表字段的插件-->
<th:block th:include="include :: bootstrap-table-editable-js" />
<script th:inline="javascript">
var aftersalesDatas = [[${@dict.getType('aftersales_emergency_degree')}]];
var removeFlag = [[${@permission.hasPermi('aftersales:complaintNotice:remove')}]];
var prefix = ctx + "aftersales/complaintNotice"
@ -297,24 +296,24 @@
// }
// },
{
field: 'emergencyDegree',
title: '紧急程度',
// 使用formatter处理显示值
formatter: function(value, row, index) {
var dictItem = aftersalesDatas.find(function(dict) {
return dict.dictValue === value;
});
return dictItem ? dictItem.dictLabel : '';
},
// 编辑时的配置
editor: {
type: 'select',
options: aftersalesDatas.map(function(item) {
return {value: item.dictValue, text: item.dictLabel};
})
}
},
// {
// field: 'emergencyDegree',
// title: '紧急程度',
// // 使用formatter处理显示值
// formatter: function(value, row, index) {
// var dictItem = aftersalesDatas.find(function(dict) {
// return dict.dictValue === value;
// });
// return dictItem ? dictItem.dictLabel : '';
// },
// // 编辑时的配置
// editor: {
// type: 'select',
// options: aftersalesDatas.map(function(item) {
// return {value: item.dictValue, text: item.dictLabel};
// })
// }
// },
{

Loading…
Cancel
Save