| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.core.common.constant.factory.PageFactory; |
| | | import com.stylefeng.guns.core.base.tips.SuccessTip; |
| | | import com.stylefeng.guns.core.shiro.ShiroKit; |
| | | import com.stylefeng.guns.core.util.SinataUtil; |
| | | import com.stylefeng.guns.modular.system.model.TProblem; |
| | | import com.stylefeng.guns.modular.system.model.TSystemNotice; |
| | | import com.stylefeng.guns.modular.system.service.ITSystemNoticeService; |
| | | import com.stylefeng.guns.modular.system.util.PushMinistryOfTransportUtil; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import com.stylefeng.guns.core.shiro.ShiroUser; |
| | | import com.stylefeng.guns.modular.system.model.TDriver; |
| | | import org.apache.shiro.subject.Subject; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | |
| | | import com.stylefeng.guns.modular.system.model.TComplaint; |
| | | import com.stylefeng.guns.modular.system.service.ITComplaintService; |
| | | |
| | | import java.io.UnsupportedEncodingException; |
| | | import java.net.URLDecoder; |
| | | import java.util.Date; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * 投诉列表控制器 |
| | | * 控制器 |
| | | * |
| | | * @author fengshuonan |
| | | * @Date 2020-06-09 17:31:24 |
| | | * @Date 2023-03-02 10:14:46 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tComplaint") |
| | |
| | | @Autowired |
| | | private ITComplaintService tComplaintService; |
| | | |
| | | @Autowired |
| | | private ITSystemNoticeService tSystemNoticeService; |
| | | |
| | | @Autowired |
| | | private PushMinistryOfTransportUtil pushMinistryOfTransportUtil; |
| | | |
| | | @Value("${pushMinistryOfTransport}") |
| | | private boolean pushMinistryOfTransport; |
| | | |
| | | |
| | | |
| | | /** |
| | | * 跳转到投诉列表首页 |
| | | * 跳转到首页 |
| | | */ |
| | | @RequestMapping("") |
| | | public String index() { |
| | |
| | | } |
| | | |
| | | /** |
| | | * 跳转到查看详情 |
| | | * 跳转到添加 |
| | | */ |
| | | @RequestMapping("/lookDetail/{id}/{type}") |
| | | public String lookDetail(@PathVariable Integer id, @PathVariable Integer type, Model model) { |
| | | TComplaint tComplaint = tComplaintService.selectById(id); |
| | | String str = ""; |
| | | if (1 == type){ |
| | | str = tComplaint.getReason(); |
| | | }else if (2 == type){ |
| | | str = tComplaint.getDescription(); |
| | | }else if (3 == type){ |
| | | str = tComplaint.getHandleResult(); |
| | | } |
| | | model.addAttribute("str",str); |
| | | return "/system/tComplaint/lookDetail.html"; |
| | | @RequestMapping("/tComplaint_add") |
| | | public String tComplaintAdd() { |
| | | return PREFIX + "tComplaint_add.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到立即处理页面 |
| | | * 跳转到修改 |
| | | */ |
| | | @RequestMapping("/tComplaint_immediately/{tComplaintId}") |
| | | @RequestMapping("/tComplaint_update/{tComplaintId}") |
| | | public String tComplaintUpdate(@PathVariable Integer tComplaintId, Model model) { |
| | | TComplaint tComplaint = tComplaintService.selectById(tComplaintId); |
| | | model.addAttribute("item",tComplaint); |
| | | LogObjectHolder.me().set(tComplaint); |
| | | return PREFIX + "tComplaint_edit.html"; |
| | | } |
| | | /** |
| | | * 跳转到投诉处理 |
| | | */ |
| | | @RequestMapping("/immediatelyAudit") |
| | | public String immediatelyAudit(Integer tComplaintId,Model model) { |
| | | model.addAttribute("tComplaintId",tComplaintId); |
| | | return PREFIX + "tComplaint_immediately.html"; |
| | | return PREFIX + "tComplaintAudit.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到查看详情 |
| | | * 审核 |
| | | */ |
| | | @RequestMapping("/lookDetail/{str}") |
| | | public String lookDetail(@PathVariable String str, Model model) { |
| | | System.out.println(str); |
| | | model.addAttribute("str",str); |
| | | return PREFIX + "lookDetail.html"; |
| | | } |
| | | |
| | | /** |
| | | * 获取投诉列表列表 |
| | | */ |
| | | @RequestMapping(value = "/list") |
| | | @RequestMapping(value = "/audit") |
| | | @ResponseBody |
| | | public Object list(String insertTime, |
| | | String userName, |
| | | String userPhone, |
| | | String driverPhone, |
| | | Integer isHandle) { |
| | | String beginTime = null; |
| | | String endTime = null; |
| | | if (SinataUtil.isNotEmpty(insertTime)){ |
| | | String[] timeArray = insertTime.split(" - "); |
| | | beginTime = timeArray[0]; |
| | | endTime = timeArray[1]; |
| | | } |
| | | Page<Map<String, Object>> page = new PageFactory<Map<String, Object>>().defaultPage(); |
| | | page.setRecords(tComplaintService.getComplaintList(page,ShiroKit.getUser().getRoleType(),ShiroKit.getUser().getObjectId(),beginTime,endTime,userName,userPhone,driverPhone,isHandle)); |
| | | return super.packForBT(page); |
| | | } |
| | | |
| | | /** |
| | | * 删除投诉列表 |
| | | */ |
| | | @RequestMapping(value = "/immediately") |
| | | @ResponseBody |
| | | public Object immediately(@RequestParam Integer id,@RequestParam String handleResult) { |
| | | TComplaint tComplaint = tComplaintService.selectById(id); |
| | | if(SinataUtil.isNotEmpty(tComplaint)){ |
| | | tComplaint.setHandleResult(handleResult); |
| | | tComplaint.setHandleUserId(ShiroKit.getUser().getId()); |
| | | tComplaint.setIsHandle(1); |
| | | tComplaint.setHandleTime(new Date()); |
| | | tComplaintService.updateById(tComplaint); |
| | | |
| | | //增加系统消息 |
| | | TSystemNotice notice = new TSystemNotice(); |
| | | notice.setType(2); |
| | | notice.setUserType(1); |
| | | notice.setContent("投诉处理结果:【"+handleResult+"】。"); |
| | | notice.setUserId(tComplaint.getUserId()); |
| | | notice.setInsertTime(new Date()); |
| | | notice.setRead(1); |
| | | tSystemNoticeService.insert(notice); |
| | | |
| | | new Thread(new Runnable() { |
| | | @Override |
| | | public void run() { |
| | | if(pushMinistryOfTransport){//上传数据 |
| | | pushMinistryOfTransportUtil.ratedPassengerComplaint(tComplaint.getId()); |
| | | } |
| | | } |
| | | }).start(); |
| | | } |
| | | public Object audit(Integer tComplaintId,String notes) { |
| | | TComplaint tComplaint = tComplaintService.selectById(tComplaintId); |
| | | tComplaint.setNotes(notes); |
| | | tComplaint.setState(2); |
| | | // 审核用户id |
| | | Subject subject = ShiroKit.getSubject(); |
| | | ShiroUser shiroUser = (ShiroUser)subject.getPrincipal(); |
| | | tComplaint.setAuditId(shiroUser.getId()); |
| | | tComplaint.setAuditPersonName(shiroUser.getName()); |
| | | tComplaint.setAuditTime(new Date()); |
| | | tComplaintService.updateById(tComplaint); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 删除投诉 |
| | | * 获取列表 |
| | | */ |
| | | @RequestMapping(value = "/list") |
| | | @ResponseBody |
| | | public Object list(String createTime,String userName,String userPhone,String driverPhone,Integer state) { |
| | | return tComplaintService.getPageList(createTime,userName,userPhone,driverPhone,state); |
| | | } |
| | | |
| | | /** |
| | | * 获取列表 |
| | | */ |
| | | @RequestMapping(value = "/list-back") |
| | | @ResponseBody |
| | | public Object listBack(String condition) { |
| | | return tComplaintService.selectList(null); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @RequestMapping(value = "/add") |
| | | @ResponseBody |
| | | public Object add(TComplaint tComplaint) { |
| | | tComplaintService.insert(tComplaint); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @RequestMapping(value = "/delete") |
| | | @ResponseBody |
| | | public Object delete(Integer tComplaintId) { |
| | | public Object delete(@RequestParam Integer tComplaintId) { |
| | | tComplaintService.deleteById(tComplaintId); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 修改投诉列表 |
| | | * 修改 |
| | | */ |
| | | @RequestMapping(value = "/update") |
| | | @ResponseBody |
| | |
| | | } |
| | | |
| | | /** |
| | | * 投诉列表详情 |
| | | * 详情 |
| | | */ |
| | | @RequestMapping(value = "/detail/{tComplaintId}") |
| | | @ResponseBody |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.ResponseBody; |
| | | import org.springframework.ui.Model; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import com.stylefeng.guns.core.log.LogObjectHolder; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import com.stylefeng.guns.modular.system.model.TSystemConfig; |
| | | import com.stylefeng.guns.modular.system.service.ITSystemConfigService; |
| | | |
| | | /** |
| | | * 控制器 |
| | | * |
| | | * @author fengshuonan |
| | | * @Date 2023-03-02 17:09:55 |
| | | */ |
| | | @Controller |
| | | @RequestMapping("/tSystemConfig") |
| | | public class TSystemConfigController extends BaseController { |
| | | |
| | | private String PREFIX = "/system/tSystemConfig/"; |
| | | |
| | | @Autowired |
| | | private ITSystemConfigService tSystemConfigService; |
| | | |
| | | /** |
| | | * 跳转到首页 |
| | | */ |
| | | @RequestMapping("") |
| | | public String index() { |
| | | return PREFIX + "tSystemConfig.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到添加 |
| | | */ |
| | | @RequestMapping("/tSystemConfig_add") |
| | | public String tSystemConfigAdd() { |
| | | return PREFIX + "tSystemConfig_add.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到修改 |
| | | */ |
| | | @RequestMapping("/tSystemConfig_update/{tSystemConfigId}") |
| | | public String tSystemConfigUpdate(@PathVariable Integer tSystemConfigId, Model model) { |
| | | TSystemConfig tSystemConfig = tSystemConfigService.selectById(tSystemConfigId); |
| | | model.addAttribute("item",tSystemConfig); |
| | | LogObjectHolder.me().set(tSystemConfig); |
| | | return PREFIX + "tSystemConfig_edit.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到派单规则 |
| | | */ |
| | | @RequestMapping("/dispatchRules") |
| | | public String dispatchRules(Model model) { |
| | | TSystemConfig tSystemConfig = tSystemConfigService.selectOne(new EntityWrapper<TSystemConfig>().eq("type", 1) |
| | | .last("LIMIT 1")); |
| | | JSONObject jsonObject = JSONObject.parseObject(tSystemConfig.getContent()); |
| | | model.addAttribute("num1",jsonObject.getInteger("num1")); |
| | | model.addAttribute("num2",jsonObject.getInteger("num2")); |
| | | model.addAttribute("num3",jsonObject.getInteger("num3")); |
| | | model.addAttribute("num4",jsonObject.getInteger("num4")); |
| | | model.addAttribute("num5",jsonObject.getInteger("num5")); |
| | | return PREFIX + "tSystemConfigDispatchRules.html"; |
| | | } |
| | | |
| | | /** |
| | | * 跳转到佣金分成规则 |
| | | */ |
| | | @RequestMapping("/commissionShareRules") |
| | | public String commissionShareRules(Model model) { |
| | | TSystemConfig tSystemConfig = tSystemConfigService.selectOne(new EntityWrapper<TSystemConfig>().eq("type", 2) |
| | | .last("LIMIT 1")); |
| | | JSONObject jsonObject = JSONObject.parseObject(tSystemConfig.getContent()); |
| | | model.addAttribute("num1",jsonObject.getInteger("num1")); |
| | | model.addAttribute("num2",jsonObject.getInteger("num2")); |
| | | model.addAttribute("num3",jsonObject.getInteger("num3")); |
| | | model.addAttribute("num4",jsonObject.getInteger("num4")); |
| | | model.addAttribute("num5",jsonObject.getInteger("num5")); |
| | | model.addAttribute("num6",jsonObject.getInteger("num6")); |
| | | model.addAttribute("num7",jsonObject.getInteger("num7")); |
| | | return PREFIX + "tSystemConfigCommissionShareRules.html"; |
| | | } |
| | | |
| | | /** |
| | | * 获取列表 |
| | | */ |
| | | @RequestMapping(value = "/systemConfigSubmit") |
| | | @ResponseBody |
| | | public Object systemConfigSubmit(Integer type,String content) { |
| | | |
| | | TSystemConfig tSystemConfig = tSystemConfigService.selectOne(new EntityWrapper<TSystemConfig>().eq("type", type) |
| | | .last("LIMIT 1")); |
| | | |
| | | tSystemConfig.setContent(content); |
| | | |
| | | return tSystemConfigService.updateById(tSystemConfig); |
| | | } |
| | | /** |
| | | * 获取列表 |
| | | */ |
| | | @RequestMapping(value = "/list") |
| | | @ResponseBody |
| | | public Object list(String condition) { |
| | | return tSystemConfigService.selectList(null); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @RequestMapping(value = "/add") |
| | | @ResponseBody |
| | | public Object add(TSystemConfig tSystemConfig) { |
| | | tSystemConfigService.insert(tSystemConfig); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @RequestMapping(value = "/delete") |
| | | @ResponseBody |
| | | public Object delete(@RequestParam Integer tSystemConfigId) { |
| | | tSystemConfigService.deleteById(tSystemConfigId); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @RequestMapping(value = "/update") |
| | | @ResponseBody |
| | | public Object update(TSystemConfig tSystemConfig) { |
| | | tSystemConfigService.updateById(tSystemConfig); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 详情 |
| | | */ |
| | | @RequestMapping(value = "/detail/{tSystemConfigId}") |
| | | @ResponseBody |
| | | public Object detail(@PathVariable("tSystemConfigId") Integer tSystemConfigId) { |
| | | return tSystemConfigService.selectById(tSystemConfigId); |
| | | } |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.controller.resp; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TAgent; |
| | | import com.stylefeng.guns.modular.system.model.TComplaint; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | |
| | | import java.math.BigDecimal; |
| | | |
| | | public class TComplaintResp extends TComplaint { |
| | | |
| | | @ApiModelProperty(value = "投诉人名称") |
| | | private String userName; |
| | | |
| | | @ApiModelProperty(value = "投诉人电话") |
| | | private String userPhone; |
| | | |
| | | @ApiModelProperty(value = "司机电话") |
| | | private String driverPhone; |
| | | |
| | | public String getUserName() { |
| | | return userName; |
| | | } |
| | | |
| | | public void setUserName(String userName) { |
| | | this.userName = userName; |
| | | } |
| | | |
| | | public String getUserPhone() { |
| | | return userPhone; |
| | | } |
| | | |
| | | public void setUserPhone(String userPhone) { |
| | | this.userPhone = userPhone; |
| | | } |
| | | |
| | | public String getDriverPhone() { |
| | | return driverPhone; |
| | | } |
| | | |
| | | public void setDriverPhone(String driverPhone) { |
| | | this.driverPhone = driverPhone; |
| | | } |
| | | } |
| | |
| | | |
| | | private Map<String, Integer> loginFailures = new HashMap<>(); |
| | | |
| | | private List<String> ips = Arrays.asList("127.0.0.1"); |
| | | private List<String> ips = Arrays.asList("127.0.0.1","192.168.0.247"); |
| | | |
| | | |
| | | |
| | |
| | | package com.stylefeng.guns.modular.system.dao; |
| | | |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TComplaintResp; |
| | | import com.stylefeng.guns.modular.system.model.TComplaint; |
| | | import com.baomidou.mybatisplus.mapper.BaseMapper; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * 投诉管理 Mapper 接口 |
| | | * 投诉 Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author 吕雪 |
| | | * @since 2020-06-09 |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | @Mapper |
| | | public interface TComplaintMapper extends BaseMapper<TComplaint> { |
| | | |
| | | /** |
| | | * 根据条件查询投诉列表 |
| | | *获取列表 |
| | | * @param startTime |
| | | * @param endTime |
| | | * @param userName |
| | | * @param userPhone |
| | | * @param driverPhone |
| | | * @param state |
| | | * @return |
| | | */ |
| | | List<Map<String,Object>> getComplaintList(@Param("page") Page<Map<String, Object>> page, |
| | | @Param("roleType") Integer roleType, |
| | | @Param("nowUserId") Integer nowUserId, |
| | | @Param("beginTime") String beginTime, |
| | | @Param("endTime") String endTime, |
| | | @Param("userName") String userName, |
| | | @Param("userPhone") String userPhone, |
| | | @Param("driverPhone") String driverPhone, |
| | | @Param("isHandle") Integer isHandle); |
| | | List<TComplaintResp> getPageList(@Param("startTime") String startTime,@Param("endTime") String endTime, @Param("userName")String userName, |
| | | @Param("userPhone")String userPhone, @Param("driverPhone")String driverPhone, @Param("state")Integer state); |
| | | |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.dao; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TSystemConfig; |
| | | import com.baomidou.mybatisplus.mapper.BaseMapper; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统配置 Mapper 接口 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | public interface TSystemConfigMapper extends BaseMapper<TSystemConfig> { |
| | | |
| | | } |
| | |
| | | <resultMap id="BaseResultMap" type="com.stylefeng.guns.modular.system.model.TComplaint"> |
| | | <id column="id" property="id" /> |
| | | <result column="userId" property="userId" /> |
| | | <result column="reason" property="reason" /> |
| | | <result column="driverId" property="driverId" /> |
| | | <result column="description" property="description" /> |
| | | <result column="isHandle" property="isHandle" /> |
| | | <result column="insert_time" property="insertTime" /> |
| | | <result column="handleResult" property="handleResult" /> |
| | | <result column="handleUserId" property="handleUserId" /> |
| | | <result column="reason" property="reason" /> |
| | | <result column="notes" property="notes" /> |
| | | <result column="state" property="state" /> |
| | | <result column="status" property="status" /> |
| | | <result column="createTime" property="createTime" /> |
| | | <result column="auditId" property="auditId" /> |
| | | <result column="auditPersonName" property="auditPersonName" /> |
| | | <result column="auditTime" property="auditTime" /> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id, userId, reason, driverId, description, isHandle, insert_time, handleResult, handleUserId |
| | | id, userId, driverId, reason, notes, state, status, createTime,auditId,auditPersonName,auditTime |
| | | </sql> |
| | | |
| | | <!--根据条件查询投诉列表--> |
| | | <select id="getComplaintList" resultType="map" parameterType="com.baomidou.mybatisplus.plugins.Page"> |
| | | SELECT * FROM (SELECT di.companyId,di.franchiseeId,ui.nickName as userName,ui.phone as userPhone,di.`name` as driverName,di.phone as driverPhone,si.`name` as handleUserName,cc.* FROM t_complaint as cc |
| | | LEFT JOIN (select * from t_user where flag != 3) as ui on ui.id = cc.userId |
| | | LEFT JOIN (select * from t_driver where flag != 3) as di on di.id = cc.driverId |
| | | LEFT JOIN sys_user as si on si.id = cc.handleUserId |
| | | ) as o |
| | | <select id="getPageList" resultType="com.stylefeng.guns.modular.system.controller.resp.TComplaintResp"> |
| | | select c.id, c.userId, c.driverId, c.reason, c.notes, c.state, c.status, c.createTime,c.auditId,c.auditPersonName,c.auditTime, |
| | | au.nickname AS userName,au.phone AS userPhone,d.phone AS driverPhone |
| | | from t_complaint c |
| | | left join t_app_user au on c.userId = au.id |
| | | left join t_driver d on c.driverId = d.id |
| | | <where> |
| | | 1 = 1 |
| | | <if test="beginTime != null and beginTime != '' and endTime != null and endTime != ''"> |
| | | AND (o.insert_time between CONCAT(#{beginTime},' 00:00:00') and CONCAT(#{endTime},' 23:59:59')) |
| | | <if test="startTime != null and startTime != '' and endTime != null and endTime != ''"> |
| | | AND c.createTime between #{startTime} and #{endTime} |
| | | </if> |
| | | <if test="userName != null and userName != ''"> |
| | | and o.userName LIKE CONCAT('%',#{userName},'%') |
| | | AND au.nickname LIKE concat('%',#{userName},'%') |
| | | </if> |
| | | <if test="userPhone != null and userPhone != ''"> |
| | | and o.userPhone LIKE CONCAT('%',#{userPhone},'%') |
| | | AND au.phone LIKE concat('%',#{userPhone},'%') |
| | | </if> |
| | | <if test="driverPhone != null and driverPhone != ''"> |
| | | and o.driverPhone LIKE CONCAT('%',#{driverPhone},'%') |
| | | AND d.phone LIKE concat('%',#{driverPhone},'%') |
| | | </if> |
| | | <if test="isHandle != null and isHandle != '' and isHandle == 2"> |
| | | and o.isHandle = 0 |
| | | </if> |
| | | <if test="isHandle != null and isHandle != '' and isHandle == 1"> |
| | | and o.isHandle = 1 |
| | | </if> |
| | | <if test="roleType != null and roleType != '' and roleType == 2"> |
| | | and o.companyId = #{nowUserId} and (o.franchiseeId = 0 or o.franchiseeId is null) |
| | | </if> |
| | | <if test="roleType != null and roleType != '' and roleType == 3"> |
| | | and o.franchiseeId = #{nowUserId} |
| | | <if test="state != null"> |
| | | AND c.state = #{state} |
| | | </if> |
| | | </where> |
| | | order by o.id desc |
| | | ORDER BY c.state |
| | | </select> |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.stylefeng.guns.modular.system.dao.TSystemConfigMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.stylefeng.guns.modular.system.model.TSystemConfig"> |
| | | <id column="id" property="id" /> |
| | | <result column="type" property="type" /> |
| | | <result column="content" property="content" /> |
| | | </resultMap> |
| | | |
| | | <!-- 通用查询结果列 --> |
| | | <sql id="Base_Column_List"> |
| | | id, type, content |
| | | </sql> |
| | | |
| | | </mapper> |
| | |
| | | import com.baomidou.mybatisplus.enums.IdType; |
| | | import java.util.Date; |
| | | import com.baomidou.mybatisplus.annotations.TableId; |
| | | import com.baomidou.mybatisplus.annotations.TableField; |
| | | import com.baomidou.mybatisplus.activerecord.Model; |
| | | import com.baomidou.mybatisplus.annotations.TableName; |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * 投诉管理 |
| | | * 投诉 |
| | | * </p> |
| | | * |
| | | * @author 吕雪 |
| | | * @since 2020-06-09 |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | @TableName("t_complaint") |
| | | public class TComplaint extends Model<TComplaint> { |
| | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 用户Id |
| | | * 用户id |
| | | */ |
| | | private Integer userId; |
| | | /** |
| | | * 投诉司机id |
| | | */ |
| | | private Integer driverId; |
| | | /** |
| | | * 投诉原因 |
| | | */ |
| | | private String reason; |
| | | /** |
| | | * 被投诉人Id |
| | | * 注释 |
| | | */ |
| | | private Long driverId; |
| | | private String notes; |
| | | /** |
| | | * 描述 |
| | | * 处理状态(1=待处理,2=已处理) |
| | | */ |
| | | private String description; |
| | | private Integer state; |
| | | /** |
| | | * 是否处理(0:未处理,1:已处理) |
| | | * 状态(1=正常,2=冻结,3=删除) |
| | | */ |
| | | private Integer isHandle; |
| | | private Integer status; |
| | | /** |
| | | * 投诉时间 |
| | | * 添加时间 |
| | | */ |
| | | @TableField("insert_time") |
| | | private Date insertTime; |
| | | /** |
| | | * 处理结果 |
| | | */ |
| | | private String handleResult; |
| | | private Date createTime; |
| | | /** |
| | | * 处理人id |
| | | */ |
| | | private Integer handleUserId; |
| | | private Integer auditId; |
| | | /** |
| | | * 处理人名称 |
| | | */ |
| | | private String auditPersonName; |
| | | /** |
| | | * 处理时间 |
| | | */ |
| | | private Date handleTime; |
| | | private Date auditTime; |
| | | |
| | | public Date getHandleTime() { |
| | | return handleTime; |
| | | public Date getAuditTime() { |
| | | return auditTime; |
| | | } |
| | | |
| | | public void setHandleTime(Date handleTime) { |
| | | this.handleTime = handleTime; |
| | | public void setAuditTime(Date auditTime) { |
| | | this.auditTime = auditTime; |
| | | } |
| | | |
| | | public Integer getAuditId() { |
| | | return auditId; |
| | | } |
| | | |
| | | public void setAuditId(Integer auditId) { |
| | | this.auditId = auditId; |
| | | } |
| | | |
| | | public String getAuditPersonName() { |
| | | return auditPersonName; |
| | | } |
| | | |
| | | public void setAuditPersonName(String auditPersonName) { |
| | | this.auditPersonName = auditPersonName; |
| | | } |
| | | |
| | | public Integer getId() { |
| | |
| | | this.userId = userId; |
| | | } |
| | | |
| | | public Integer getDriverId() { |
| | | return driverId; |
| | | } |
| | | |
| | | public void setDriverId(Integer driverId) { |
| | | this.driverId = driverId; |
| | | } |
| | | |
| | | public String getReason() { |
| | | return reason; |
| | | } |
| | |
| | | this.reason = reason; |
| | | } |
| | | |
| | | public Long getDriverId() { |
| | | return driverId; |
| | | public String getNotes() { |
| | | return notes; |
| | | } |
| | | |
| | | public void setDriverId(Long driverId) { |
| | | this.driverId = driverId; |
| | | public void setNotes(String notes) { |
| | | this.notes = notes; |
| | | } |
| | | |
| | | public String getDescription() { |
| | | return description; |
| | | public Integer getState() { |
| | | return state; |
| | | } |
| | | |
| | | public void setDescription(String description) { |
| | | this.description = description; |
| | | public void setState(Integer state) { |
| | | this.state = state; |
| | | } |
| | | |
| | | public Integer getIsHandle() { |
| | | return isHandle; |
| | | public Integer getStatus() { |
| | | return status; |
| | | } |
| | | |
| | | public void setIsHandle(Integer isHandle) { |
| | | this.isHandle = isHandle; |
| | | public void setStatus(Integer status) { |
| | | this.status = status; |
| | | } |
| | | |
| | | public Date getInsertTime() { |
| | | return insertTime; |
| | | public Date getCreateTime() { |
| | | return createTime; |
| | | } |
| | | |
| | | public void setInsertTime(Date insertTime) { |
| | | this.insertTime = insertTime; |
| | | } |
| | | |
| | | public String getHandleResult() { |
| | | return handleResult; |
| | | } |
| | | |
| | | public void setHandleResult(String handleResult) { |
| | | this.handleResult = handleResult; |
| | | } |
| | | |
| | | public Integer getHandleUserId() { |
| | | return handleUserId; |
| | | } |
| | | |
| | | public void setHandleUserId(Integer handleUserId) { |
| | | this.handleUserId = handleUserId; |
| | | public void setCreateTime(Date createTime) { |
| | | this.createTime = createTime; |
| | | } |
| | | |
| | | @Override |
| | |
| | | return "TComplaint{" + |
| | | "id=" + id + |
| | | ", userId=" + userId + |
| | | ", reason=" + reason + |
| | | ", driverId=" + driverId + |
| | | ", description=" + description + |
| | | ", isHandle=" + isHandle + |
| | | ", insertTime=" + insertTime + |
| | | ", handleResult=" + handleResult + |
| | | ", handleUserId=" + handleUserId + |
| | | ", reason=" + reason + |
| | | ", notes=" + notes + |
| | | ", state=" + state + |
| | | ", status=" + status + |
| | | ", createTime=" + createTime + |
| | | "}"; |
| | | } |
| | | } |
| | |
| | | @TableField("coupon_count") |
| | | private Integer couponCount; |
| | | |
| | | @ApiModelProperty(value = "剩余数量") |
| | | @TableField("remaining_quantity") |
| | | private Integer remainingQuantity; |
| | | |
| | | public Integer getRemainingQuantity() { |
| | | return remainingQuantity; |
| | | } |
| | | |
| | | public void setRemainingQuantity(Integer remainingQuantity) { |
| | | this.remainingQuantity = remainingQuantity; |
| | | } |
| | | |
| | | public Integer getCouponCount() { |
| | | return couponCount; |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.model; |
| | | |
| | | import com.baomidou.mybatisplus.enums.IdType; |
| | | import com.baomidou.mybatisplus.annotations.TableId; |
| | | import com.baomidou.mybatisplus.activerecord.Model; |
| | | import com.baomidou.mybatisplus.annotations.TableName; |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统配置 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | @TableName("t_system_config") |
| | | public class TSystemConfig extends Model<TSystemConfig> { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 主键 |
| | | */ |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 类型(1=派单规则,2=佣金分成规则,3=抽成规则,4=积分规则,5=价格规则,6=余额规则,7=客服管理) |
| | | */ |
| | | private Integer type; |
| | | /** |
| | | * 内容 |
| | | */ |
| | | private String content; |
| | | |
| | | |
| | | public Integer getId() { |
| | | return id; |
| | | } |
| | | |
| | | public void setId(Integer id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public Integer getType() { |
| | | return type; |
| | | } |
| | | |
| | | public void setType(Integer type) { |
| | | this.type = type; |
| | | } |
| | | |
| | | public String getContent() { |
| | | return content; |
| | | } |
| | | |
| | | public void setContent(String content) { |
| | | this.content = content; |
| | | } |
| | | |
| | | @Override |
| | | protected Serializable pkVal() { |
| | | return this.id; |
| | | } |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "TSystemConfig{" + |
| | | "id=" + id + |
| | | ", type=" + type + |
| | | ", content=" + content + |
| | | "}"; |
| | | } |
| | | } |
| | |
| | | package com.stylefeng.guns.modular.system.service; |
| | | |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TComplaintResp; |
| | | import com.stylefeng.guns.modular.system.model.TComplaint; |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * 投诉管理 服务类 |
| | | * 投诉 服务类 |
| | | * </p> |
| | | * |
| | | * @author 吕雪 |
| | | * @since 2020-06-09 |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | public interface ITComplaintService extends IService<TComplaint> { |
| | | |
| | | /** |
| | | * 根据条件查询投诉列表 |
| | | * 获取列表 |
| | | * @param createTime |
| | | * @param userName |
| | | * @param userPhone |
| | | * @param driverPhone |
| | | * @param state |
| | | * @return |
| | | */ |
| | | List<Map<String,Object>> getComplaintList(@Param("page") Page<Map<String, Object>> page, |
| | | @Param("roleType") Integer roleType, |
| | | @Param("nowUserId") Integer nowUserId, |
| | | @Param("beginTime") String beginTime, |
| | | @Param("endTime") String endTime, |
| | | @Param("userName") String userName, |
| | | @Param("userPhone") String userPhone, |
| | | @Param("driverPhone") String driverPhone, |
| | | @Param("isHandle") Integer isHandle); |
| | | List<TComplaintResp> getPageList(String createTime, String userName, String userPhone, String driverPhone, Integer state); |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.service; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TSystemConfig; |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统配置 服务类 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | public interface ITSystemConfigService extends IService<TSystemConfig> { |
| | | |
| | | } |
| | |
| | | package com.stylefeng.guns.modular.system.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TComplaintResp; |
| | | import com.stylefeng.guns.modular.system.dao.TAppUserMapper; |
| | | import com.stylefeng.guns.modular.system.dao.TDriverMapper; |
| | | import com.stylefeng.guns.modular.system.model.TComplaint; |
| | | import com.stylefeng.guns.modular.system.dao.TComplaintMapper; |
| | | import com.stylefeng.guns.modular.system.service.ITComplaintService; |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.util.StringUtils; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * 投诉管理 服务实现类 |
| | | * 投诉 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author 吕雪 |
| | | * @since 2020-06-09 |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | @Service |
| | | public class TComplaintServiceImpl extends ServiceImpl<TComplaintMapper, TComplaint> implements ITComplaintService { |
| | | |
| | | @Autowired |
| | | private TComplaintMapper tComplaintMapper; |
| | | |
| | | @Override |
| | | public List<Map<String, Object>> getComplaintList(Page<Map<String, Object>> page, Integer roleType, Integer nowUserId, String beginTime, String endTime, String userName, String userPhone, String driverPhone, Integer isHandle) { |
| | | return this.baseMapper.getComplaintList(page, roleType, nowUserId, beginTime, endTime, userName, userPhone, driverPhone, isHandle); |
| | | public List<TComplaintResp> getPageList(String createTime, String userName, String userPhone, String driverPhone, Integer state) { |
| | | String startTime = null; |
| | | String endTime = null; |
| | | // 开始,结束时间 |
| | | if(StringUtils.hasLength(createTime)){ |
| | | String[] split = createTime.split(" - "); |
| | | startTime = split[0]; |
| | | endTime = split[1]; |
| | | } |
| | | return tComplaintMapper.getPageList(startTime,endTime,userName,userPhone,driverPhone,state); |
| | | } |
| | | } |
New file |
| | |
| | | package com.stylefeng.guns.modular.system.service.impl; |
| | | |
| | | import com.stylefeng.guns.modular.system.model.TSystemConfig; |
| | | import com.stylefeng.guns.modular.system.dao.TSystemConfigMapper; |
| | | import com.stylefeng.guns.modular.system.service.ITSystemConfigService; |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * 系统配置 服务实现类 |
| | | * </p> |
| | | * |
| | | * @author stylefeng |
| | | * @since 2023-03-02 |
| | | */ |
| | | @Service |
| | | public class TSystemConfigServiceImpl extends ServiceImpl<TSystemConfigMapper, TSystemConfig> implements ITSystemConfigService { |
| | | |
| | | } |
| | |
| | | * 乘客投诉信息 |
| | | * @param id |
| | | */ |
| | | public void ratedPassengerComplaint(Integer id){ |
| | | /*public void ratedPassengerComplaint(Integer id){ |
| | | TComplaint tComplaint = complaintService.selectById(id); |
| | | JSONObject jsonObject = new JSONObject(); |
| | | jsonObject.put("OrderId", "");//订单号 |
| | |
| | | map.put("ratedPassengerComplaint", jsonObject.toJSONString()); |
| | | String result = HttpRequestUtil.postRequest(PushURL.ministry_of_transport_data + "/ratedPassengerComplaint", map); |
| | | System.out.println("乘客投诉信息:" + result); |
| | | } |
| | | }*/ |
| | | |
| | | |
| | | /** |
| | |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>投诉列表管理</h5> |
| | | <h5>管理</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | <div class="row"> |
| | | <div class="col-sm-3"> |
| | | <#TimeCon id="insertTime" name="投诉时间" isTime="false"/> |
| | | <div class="col-sm-2"> |
| | | <#TimeCon id="createTime" name="投诉时间" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="userName" name="投诉人昵称" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <#NameCon id="userPhone" name="投诉人电话" /> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="userPhone" name="投诉人手机号" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <#NameCon id="driverPhone" name="投诉司机电话" /> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="driverPhone" name="司机手机号" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <#SelectCon id="isHandle" name="状态" > |
| | | <option value="">全部</option> |
| | | <option value="2">未处理</option> |
| | | <option value="1">已处理</option> |
| | | </#SelectCon> |
| | | <div class="col-sm-2"> |
| | | <select class="input-group" id="state" style="width: 180px;height: 33px" name="state"> |
| | | <option value="">选择状态</option> |
| | | <option value="1">待处理</option> |
| | | <option value="2">已处理</option> |
| | | </select> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <div class="col-sm-2"> |
| | | <#button name="搜索" icon="fa-search" clickFun="TComplaint.search()"/> |
| | | <#button name="重置" icon="fa-trash" clickFun="TComplaint.resetSearch()" space="true"/> |
| | | </div> |
| | | <div class="col-sm-12"> |
| | | <#button name="立即处理" icon="" clickFun="TComplaint.immediatelyAudit()"/> |
| | | @if(shiro.hasPermission("/tComplaint/delete")){ |
| | | <#button name="删除" icon="fa-remove" clickFun="TComplaint.delete()" space="true"/> |
| | | @} |
| | | </div> |
| | | </div> |
| | | <div class="hidden-xs" id="TComplaintTableToolbar" role="group"> |
| | | @if(shiro.hasPermission("/tComplaint/immediately")){ |
| | | <#button name="立即处理" icon="fa-edit" clickFun="TComplaint.immediately()"/> |
| | | <!--<div class="hidden-xs" id="TComplaintTableToolbar" role="group"> |
| | | @if(shiro.hasPermission("/tComplaint/add")){ |
| | | <#button name="添加" icon="fa-plus" clickFun="TComplaint.openAddTComplaint()"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tComplaint/update")){ |
| | | <#button name="修改" icon="fa-edit" clickFun="TComplaint.openTComplaintDetail()" space="true"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tComplaint/delete")){ |
| | | <#button name="删除记录" icon="fa-remove" clickFun="TComplaint.delete()" space="true"/> |
| | | <#button name="删除" icon="fa-remove" clickFun="TComplaint.delete()" space="true"/> |
| | | @} |
| | | </div> |
| | | </div>--> |
| | | <#table id="TComplaintTable"/> |
| | | </div> |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tComplaint/tComplaint.js"></script> |
| | | <script> |
| | | <script type="text/javascript"> |
| | | laydate.render({ |
| | | elem: '#insertTime' |
| | | ,range: true |
| | | elem: '#createTime', |
| | | type: 'date', |
| | | range: true |
| | | }); |
| | | </script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | <input hidden id="tComplaintId" value="${tComplaintId}"> |
| | | <div class="col-lg-3"> |
| | | 备注:<textarea id="notes" placeholder="请输入备注" style="width: 681px; height: 249px;"></textarea> |
| | | </div> |
| | | <div class="hidden-xs" id="TAppUserTableToolbar" role="group" style="margin-left:300px"> |
| | | <#button name="取消" icon="fa-plus" clickFun="TComplaintInfoDlg.close()" /> |
| | | <#button name="提交" icon="fa-plus" clickFun="TComplaint.audit()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tComplaint/tComplaint.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tComplaint/tComplaint_info.js"></script> |
| | | @} |
| | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" underline="true"/> |
| | | <#input id="userId" name="用户Id" underline="true"/> |
| | | <#input id="reason" name="投诉原因" underline="true"/> |
| | | <#input id="driverId" name="被投诉人Id" underline="true"/> |
| | | <#input id="description" name="描述"/> |
| | | <#input id="userId" name="用户id" underline="true"/> |
| | | <#input id="driverId" name="投诉司机id" underline="true"/> |
| | | <#input id="reason" name="投诉原因"/> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="isHandle" name="是否处理(0:未处理,1:已处理)" underline="true"/> |
| | | <#input id="insertTime" name="投诉时间" underline="true"/> |
| | | <#input id="handleResult" name="处理结果" underline="true"/> |
| | | <#input id="handleUserId" name="处理人id" underline="true"/> |
| | | <#input id="notes" name="注释" underline="true"/> |
| | | <#input id="state" name="处理状态(1=待处理,2=已处理)" underline="true"/> |
| | | <#input id="status" name="状态(1=正常,2=冻结,3=删除)" underline="true"/> |
| | | <#input id="createTime" name="添加时间" underline="true"/> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" value="${item.id}" underline="true"/> |
| | | <#input id="userId" name="用户Id" value="${item.userId}" underline="true"/> |
| | | <#input id="reason" name="投诉原因" value="${item.reason}" underline="true"/> |
| | | <#input id="driverId" name="被投诉人Id" value="${item.driverId}" underline="true"/> |
| | | <#input id="description" name="描述" value="${item.description}" /> |
| | | <#input id="userId" name="用户id" value="${item.userId}" underline="true"/> |
| | | <#input id="driverId" name="投诉司机id" value="${item.driverId}" underline="true"/> |
| | | <#input id="reason" name="投诉原因" value="${item.reason}" /> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="isHandle" name="是否处理(0:未处理,1:已处理)" value="${item.isHandle}" underline="true"/> |
| | | <#input id="insertTime" name="投诉时间" value="${item.insertTime}" underline="true"/> |
| | | <#input id="handleResult" name="处理结果" value="${item.handleResult}" underline="true"/> |
| | | <#input id="handleUserId" name="处理人id" value="${item.handleUserId}" /> |
| | | <#input id="notes" name="注释" value="${item.notes}" underline="true"/> |
| | | <#input id="state" name="处理状态(1=待处理,2=已处理)" value="${item.state}" underline="true"/> |
| | | <#input id="status" name="状态(1=正常,2=冻结,3=删除)" value="${item.status}" underline="true"/> |
| | | <#input id="createTime" name="添加时间" value="${item.createTime}" /> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | <option value="1">通用券</option> |
| | | </select> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <div class="col-sm-2"> |
| | | <#button name="搜索" icon="fa-search" clickFun="TCoupon.search()"/> |
| | | <#button name="重置" icon="fa-trash" clickFun="TCoupon.resetSearch()" space="true"/> |
| | | </div> |
| | | </div> |
| | | <div class="hidden-xs" id="TCouponTableToolbar" role="group"> |
| | |
| | | |
| | | <div class="col-sm-12"> |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">优惠券数量:</label> |
| | | <label class="col-sm-3 control-label">优惠券限制数量:</label> |
| | | <div class="col-sm-6"> |
| | | <input class="form-control" id="couponCount" name="couponCount" type="text" required> |
| | | <input class="form-control" id="couponCount" name="couponCount" type="number" required> |
| | | </div> |
| | | </div> |
| | | <div class="hr-line-dashed"></div> |
| | |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">条件金额:订单满</label> |
| | | <div class="col-sm-6"> |
| | | <input class="form-control" id="couponConditionalAmount" name="couponConditionalAmount" type="text" required> |
| | | <input class="form-control" id="couponConditionalAmount" name="couponConditionalAmount" type="number" required> |
| | | </div> |
| | | <label class="col-sm-2 control-label">可使用</label> |
| | | </div> |
| | |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">优惠金额:</label> |
| | | <div class="col-sm-6"> |
| | | <input class="form-control" id="couponPreferentialAmount" name="couponPreferentialAmount" type="text" required> |
| | | <input class="form-control" id="couponPreferentialAmount" name="couponPreferentialAmount" type="number" required> |
| | | </div> |
| | | </div> |
| | | <div class="hr-line-dashed"></div> |
| | |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">有效期:</label> |
| | | <div class="col-sm-6"> |
| | | <input class="form-control" id="couponValidity" name="couponValidity" type="text" required> |
| | | <input class="form-control" id="couponValidity" name="couponValidity" type="number" required> |
| | | </div> |
| | | <label class="col-sm-1 control-label">天</label> |
| | | </div> |
| | |
| | | |
| | | <div class="col-sm-12"> |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">优惠券总量:</label> |
| | | <div class="col-sm-6"> |
| | | <input class="form-control" id="remainingQuantity" name="remainingQuantity" type="number" required> |
| | | </div> |
| | | </div> |
| | | <div class="hr-line-dashed"></div> |
| | | </div> |
| | | |
| | | <div class="col-sm-12"> |
| | | <div class="form-group"> |
| | | <label class="col-sm-3 control-label">赠送数量:</label> |
| | | <div class="col-sm-6"> |
| | | <input class="form-control" id="couponSendQuantity" name="couponSendQuantity" type="text"> |
| | | <input class="form-control" id="couponSendQuantity" name="couponSendQuantity" type="number"> |
| | | </div> |
| | | <label class="col-sm-1 control-label">张</label> |
| | | </div> |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>管理</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | <div class="row"> |
| | | <div class="col-sm-3"> |
| | | <#NameCon id="condition" name="名称" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <#button name="搜索" icon="fa-search" clickFun="TSystemConfig.search()"/> |
| | | </div> |
| | | </div> |
| | | <div class="hidden-xs" id="TSystemConfigTableToolbar" role="group"> |
| | | @if(shiro.hasPermission("/tSystemConfig/add")){ |
| | | <#button name="添加" icon="fa-plus" clickFun="TSystemConfig.openAddTSystemConfig()"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tSystemConfig/update")){ |
| | | <#button name="修改" icon="fa-edit" clickFun="TSystemConfig.openTSystemConfigDetail()" space="true"/> |
| | | @} |
| | | @if(shiro.hasPermission("/tSystemConfig/delete")){ |
| | | <#button name="删除" icon="fa-remove" clickFun="TSystemConfig.delete()" space="true"/> |
| | | @} |
| | | </div> |
| | | <#table id="TSystemConfigTable"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>佣金</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >佣金分成规则:</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >司机邀请1名用户,下单后完成订单后获得</label> |
| | | <input class="control-label" id="num1" name="num1" value="${num1}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单</label> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >司机A邀请1名司机B,完成有效单后获得</label> |
| | | <input class="control-label" id="num2" name="num2" value="${num2}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单</label> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-4 control-label form-group" > |
| | | <label class="control-label" >司机B邀请1名司机C,完成有效单后B获得</label> |
| | | <input class="control-label" id="num3" name="num3" value="${num3}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单+' '+司机A获得</label> |
| | | <input class="control-label" id="num4" name="num4" value="${num4}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单</label> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-5 control-label form-group" > |
| | | <label class="control-label" >司机C邀请1名司机D,完成有效单后C获得</label> |
| | | <input class="control-label" id="num5" name="num5" value="${num5}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单+' '+司机B获得</label> |
| | | <input class="control-label" id="num6" name="num6" value="${num6}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单+' '+司机A获得</label> |
| | | <input class="control-label" id="num7" name="num7" value="${num7}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >元/单</label> |
| | | </div> |
| | | </div> |
| | | |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10" style="text-align: center"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TSystemConfig.commissionShareRules()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="row"> |
| | | <div class="col-sm-12"> |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-title"> |
| | | <h5>派单规则</h5> |
| | | </div> |
| | | <div class="ibox-content"> |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12"> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >派单设置:</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label" >派单距离第一轮</label> |
| | | <input class="control-label" id="num1" name="num1" value="${num1}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >米</label> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label" >派单距离第二轮</label> |
| | | <input class="control-label" id="num2" name="num2" value="${num2}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >米</label> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label" >派单距离第三轮</label> |
| | | <input class="control-label" id="num3" name="num3" value="${num3}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >米</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >接单设置:</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label" >接单时间</label> |
| | | <input class="control-label" id="num4" name="num4" value="${num4}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >秒</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >改派设置:</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: right" > |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label" >改派后暂停接单</label> |
| | | <input class="control-label" id="num5" name="num5" value="${num5}" type="number" style="height: 30px;width: 80px"> |
| | | <label class="control-label" >分钟</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10" style="text-align: center"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TSystemConfig.dispatchRulesSubmit()"/> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig.js"></script> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal"> |
| | | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" underline="true"/> |
| | | <#input id="type" name="类型(1=派单规则,2=佣金分成规则,3=抽成规则,4=积分规则,5=价格规则,6=余额规则,7=客服管理)"/> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="content" name="内容" underline="true"/> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TSystemConfigInfoDlg.addSubmit()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TSystemConfigInfoDlg.close()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig_info.js"></script> |
| | | @} |
New file |
| | |
| | | @layout("/common/_container.html"){ |
| | | <div class="ibox float-e-margins"> |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal"> |
| | | |
| | | <div class="row"> |
| | | <div class="col-sm-6 b-r"> |
| | | <#input id="id" name="主键" value="${item.id}" underline="true"/> |
| | | <#input id="type" name="类型(1=派单规则,2=佣金分成规则,3=抽成规则,4=积分规则,5=价格规则,6=余额规则,7=客服管理)" value="${item.type}" /> |
| | | </div> |
| | | |
| | | <div class="col-sm-6"> |
| | | <#input id="content" name="内容" value="${item.content}" /> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="row btn-group-m-t"> |
| | | <div class="col-sm-10"> |
| | | <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="TSystemConfigInfoDlg.editSubmit()"/> |
| | | <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="TSystemConfigInfoDlg.close()"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <script src="${ctxPath}/static/modular/system/tSystemConfig/tSystemConfig_info.js"></script> |
| | | @} |
| | |
| | | <div class="ibox-content"> |
| | | <div class="form-horizontal" id="youTuiInfoForm"> |
| | | |
| | | <div class="row" style="text-align: left"> |
| | | <div class="col-sm-12"> |
| | | <div class="row"> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <input hidden id="areaId" value="areaId"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="text-align: center"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >优推名称:</label> |
| | | <input id="name" name="name" type="text" placeholder="最多20个字" maxlength="20" style="height: 30px" required> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" style="flex: auto" > |
| | | <div class="initialLevel col-sm-12"> |
| | | <div class="initialLevel col-sm-6" style="width: 55%"> |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >优推类型:</label> |
| | | <input id="number" name="number" type="number" placeholder="请输入0以上的数字" min="0" style="height: 30px" required> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <div class="initialLevel col-sm-12"> |
| | | <div class="initialLevel col-sm-6" style="width: 51%" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >兑换条件:</label> |
| | | <input id="integral" name="integral" type="number" max="9999" placeholder="最多4位数" style="height: 30px" required> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <div class="initialLevel col-sm-12"> |
| | | <div class="initialLevel col-sm-6" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >优推距离:</label> |
| | | <input id="distance" name="distance" type="number" placeholder="最多2000米" max="2000" style="height: 30px" required> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <div class="initialLevel col-sm-12"> |
| | | <div class="initialLevel col-sm-6"> |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >有效期:</label> |
| | | <input id="effectiveTime" name="effectiveTime" maxlength="4" placeholder="最多4位数" type="number" style="height: 30px" required> |
| | |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <div class="initialLevel col-sm-6" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >服务内容:</label> |
| | | <textarea id="serviceContent" name="serviceContent" placeholder="请输入" style="height: 80px" required></textarea> |
| | |
| | | /** |
| | | * 投诉列表管理初始化 |
| | | * 管理初始化 |
| | | */ |
| | | var TComplaint = { |
| | | id: "TComplaintTable", //表格id |
| | |
| | | TComplaint.initColumn = function () { |
| | | return [ |
| | | {field: 'selectItem', radio: true}, |
| | | {title: '主键ID', field: 'id', visible: false, align: 'center', valign: 'middle'}, |
| | | {title: '投诉时间', field: 'insert_time', visible: true, align: 'center', valign: 'middle',width:'10%', |
| | | {title: '主键', field: 'id', visible: false, align: 'center', valign: 'middle'}, |
| | | {title: '用户id', field: 'userId', visible: false, align: 'center', valign: 'middle'}, |
| | | {title: '投诉司机id', field: 'driverId', visible: false, align: 'center', valign: 'middle'}, |
| | | {title: '投诉时间', field: 'createTime', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '投诉人昵称', field: 'userName', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '投诉人电话', field: 'userPhone', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '投诉原因', field: 'reason', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '备注', field: 'notes', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '处理状态', field: 'state', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.insert_time != '' && row.insert_time != null) { |
| | | var time = row.insert_time.replace(" ",'<br>'); |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.insert_time + '" onfocus="TUser.tooltip()">' + time + '</p>'] |
| | | if (row.state === 1){ |
| | | return '<span>待处理</span>' |
| | | }else if (row.state === 2){ |
| | | return '<span>已处理</span>' |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '投诉人昵称', field: 'userName', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.userName != '' && row.userName != null) { |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.userName + '" onfocus="TUser.tooltip()">' + row.userName + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '投诉人<br/>电话', field: 'userPhone', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.userPhone != '' && row.userPhone != null) { |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.userPhone + '" onfocus="TUser.tooltip()">' + row.userPhone + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '投诉司机<br/>电话', field: 'driverPhone', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.driverPhone != '' && row.driverPhone != null) { |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.driverPhone + '" onfocus="TUser.tooltip()">' + row.driverPhone + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '投诉<br/>原因', field: 'reason', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.reason != '' && row.reason != null) { |
| | | var str = row.reason; |
| | | if (str.length > 20){ |
| | | str = str.substring(0,20)+'...<br><button class="btn btn-outline btn-primary" onclick="TComplaint.buttonClick(' + row.id+','+ 1+ ')">查看更多</button>'; |
| | | } |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.reason + '" onfocus="TUser.tooltip()">' + str + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '描述', field: 'description', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.description != '' && row.description != null) { |
| | | var str = row.description; |
| | | if (str.length > 20){ |
| | | str = str.substring(0,20)+'...<br><button class="btn btn-outline btn-primary" onclick="TComplaint.buttonClick(' + row.id+','+ 2+ ')">查看更多</button>'; |
| | | } |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.description + '" onfocus="TUser.tooltip()">' + str + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '备注', field: 'handleResult', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.handleResult != '' && row.handleResult != null) { |
| | | var str = row.handleResult; |
| | | if (str.length > 20){ |
| | | str = str.substring(0,20)+'...<br><button class="btn btn-outline btn-primary" onclick="TComplaint.buttonClick(' + row.id+','+ 3+ ')">查看更多</button>'; |
| | | } |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.handleResult + '" onfocus="TUser.tooltip()">' + str + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '状态', field: 'isHandle', visible: true, align: 'center', valign: 'middle',width:'10%', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.isHandle != '' && row.isHandle != null) { |
| | | if (row.isHandle == 1){ |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="已处理" onfocus="TUser.tooltip()">已处理</p>'] |
| | | } |
| | | }else{ |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color: red;" title="未处理" onfocus="TUser.tooltip()">未处理</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '处理时间', field: 'handleTime', visible: true, align: 'center', valign: 'middle',width:'10%', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.handleTime != '' && row.handleTime != null) { |
| | | var time = row.handleTime.replace(" ",'<br>'); |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.handleTime + '" onfocus="TUser.tooltip()">' + time + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | }, |
| | | {title: '处理人', field: 'handleUserName', visible: true, align: 'center', valign: 'middle',width:'10%', |
| | | formatter: function (value, row) { |
| | | var btn = ""; |
| | | if(row.handleUserName != '' && row.handleUserName != null) { |
| | | btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.handleUserName + '" onfocus="TUser.tooltip()">' + row.handleUserName + '</p>'] |
| | | } |
| | | return btn; |
| | | } |
| | | } |
| | | {title: '处理时间', field: 'auditTime', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '处理人', field: 'auditPersonName', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '状态(1=正常,2=冻结,3=删除)', field: 'status', visible: false, align: 'center', valign: 'middle'} |
| | | ]; |
| | | }; |
| | | |
| | | /** |
| | | * 查看更多按钮 |
| | | * @param con |
| | | */ |
| | | TComplaint.buttonClick = function (id,type) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '查看详情', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tComplaint/lookDetail/'+id+"/"+type |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * 检查是否选中 |
| | |
| | | }; |
| | | |
| | | /** |
| | | * 立即处理 |
| | | * 点击添加 |
| | | */ |
| | | TComplaint.immediately = function(){ |
| | | TComplaint.openAddTComplaint = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '添加', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tComplaint/tComplaint_add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 打开查看详情 |
| | | */ |
| | | TComplaint.openTComplaintDetail = function () { |
| | | if (this.check()) { |
| | | if (TComplaint.seItem.isHandle == 1) { |
| | | swal("处理失败", "【未处理】状态下才能执行此操作", "warning"); |
| | | return; |
| | | } |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '立即处理', |
| | | title: '详情', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tComplaint/tComplaint_immediately/' + TComplaint.seItem.id |
| | | content: Feng.ctxPath + '/tComplaint/tComplaint_update/' + TComplaint.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 删除投诉列表 |
| | | * 删除 |
| | | */ |
| | | TComplaint.delete = function () { |
| | | if (this.check()) { |
| | | if (TComplaint.seItem.isHandle != 1) { |
| | | swal("删除失败", "【已处理】状态下才能执行此操作", "warning"); |
| | | return; |
| | | } |
| | | swal({ |
| | | title: "您是否确认删除该投诉记录?", |
| | | text: "请谨慎操作,删除后数据无法恢复!", |
| | | type: "warning", |
| | | showCancelButton: true, |
| | | confirmButtonColor: "#DD6B55", |
| | | confirmButtonText: "删除", |
| | | closeOnConfirm: false |
| | | }, function () { |
| | | var ajax = new $ax(Feng.ctxPath + "/tComplaint/delete", function (data) { |
| | | swal("删除成功", "您已经删除了该投诉记录。", "success"); |
| | | TComplaint.table.refresh(); |
| | | }, function (data) { |
| | | swal("删除失败", data.responseJSON.message + "!", "warning"); |
| | | }); |
| | | ajax.set("tComplaintId", TComplaint.seItem.id); |
| | | ajax.start(); |
| | | var ajax = new $ax(Feng.ctxPath + "/tComplaint/delete", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TComplaint.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("删除失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("tComplaintId",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 查询投诉列表列表 |
| | | * 立即处理页面跳转 |
| | | */ |
| | | TComplaint.immediatelyAudit = function () { |
| | | if (this.check()) { |
| | | if(2 == TComplaint.seItem.state){ |
| | | Feng.error("该数据已处理!"); |
| | | return; |
| | | } |
| | | |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '投诉处理', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tComplaint/immediatelyAudit?tComplaintId=' + TComplaint.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 提交审核 |
| | | */ |
| | | TComplaint.audit = function () { |
| | | var ajax = new $ax(Feng.ctxPath + "/tComplaint/audit", function (data) { |
| | | Feng.success("修改成功!"); |
| | | TComplaintInfoDlg.close(); |
| | | parent.TComplaint.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("修改失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("tComplaintId",$("#tComplaintId").val()); |
| | | ajax.set("notes",$("#notes").val()); |
| | | ajax.start(); |
| | | }; |
| | | |
| | | /** |
| | | * 查询列表 |
| | | */ |
| | | TComplaint.search = function () { |
| | | var queryData = {}; |
| | | queryData['insertTime'] = $("#insertTime").val(); |
| | | queryData['createTime'] = $("#createTime").val(); |
| | | queryData['userName'] = $("#userName").val(); |
| | | queryData['userPhone'] = $("#userPhone").val(); |
| | | queryData['driverPhone'] = $("#driverPhone").val(); |
| | | queryData['isHandle'] = $("#isHandle").val(); |
| | | queryData['state'] = $("#state").val(); |
| | | TComplaint.table.refresh({query: queryData}); |
| | | }; |
| | | |
| | | TComplaint.resetSearch = function () { |
| | | $("#insertTime").val(""); |
| | | $("#userName").val(""); |
| | | $("#userPhone").val(""); |
| | | $("#driverPhone").val(""); |
| | | $("#isHandle").val(""); |
| | | /** |
| | | * 重置 |
| | | */ |
| | | TComplaint.resetSearch = function (){ |
| | | $("#createTime").val(''); |
| | | $("#userName").val(''); |
| | | $("#userPhone").val(''); |
| | | $("#driverPhone").val(''); |
| | | $("#state").val(''); |
| | | TComplaint.search(); |
| | | }; |
| | | } |
| | | |
| | | $(function () { |
| | | var defaultColunms = TComplaint.initColumn(); |
| | | var table = new BSTable(TComplaint.id, "/tComplaint/list", defaultColunms); |
| | | table.setPaginationType("server"); |
| | | table.setPaginationType("client"); |
| | | TComplaint.table = table.init(); |
| | | }); |
| | |
| | | /** |
| | | * 初始化投诉列表详情对话框 |
| | | * 初始化详情对话框 |
| | | */ |
| | | var TComplaintInfoDlg = { |
| | | tComplaintInfoData : {}, |
| | | validateFields: { |
| | | handleResult: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '备注不能为空' |
| | | }/*, |
| | | regexp: { |
| | | regexp: /^.{1,500}$/, |
| | | message: '备注不能超过500个长度' |
| | | }*/ |
| | | } |
| | | }, |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 验证数据是否为空 |
| | | */ |
| | | TComplaintInfoDlg.validate = function () { |
| | | $('#complaintFormInfo').data("bootstrapValidator").resetForm(); |
| | | $('#complaintFormInfo').bootstrapValidator('validate'); |
| | | return $("#complaintFormInfo").data('bootstrapValidator').isValid(); |
| | | tComplaintInfoData : {} |
| | | }; |
| | | |
| | | /** |
| | |
| | | this |
| | | .set('id') |
| | | .set('userId') |
| | | .set('reason') |
| | | .set('driverId') |
| | | .set('description') |
| | | .set('isHandle') |
| | | .set('insertTime') |
| | | .set('handleResult') |
| | | .set('handleUserId'); |
| | | .set('reason') |
| | | .set('notes') |
| | | .set('state') |
| | | .set('status') |
| | | .set('createTime'); |
| | | } |
| | | |
| | | /** |
| | | * 立即处理 |
| | | * 提交添加 |
| | | */ |
| | | TComplaintInfoDlg.immediately = function() { |
| | | TComplaintInfoDlg.addSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | if(!this.validate()){ |
| | | return ; |
| | | } |
| | | var handleResult = $("#handleResult").val(); |
| | | if (handleResult.length > 500){ |
| | | Feng.info("备注不能超过500个字"); |
| | | return; |
| | | } |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tComplaint/immediately", function(data){ |
| | | Feng.success("处理成功!"); |
| | | var ajax = new $ax(Feng.ctxPath + "/tComplaint/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TComplaint.table.refresh(); |
| | | TComplaintInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("处理失败!" + data.responseJSON.message + "!"); |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("id",$("#id").val()); |
| | | ajax.set("handleResult",$("#handleResult").val()); |
| | | ajax.set(this.tComplaintInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 提交修改 |
| | | */ |
| | | TComplaintInfoDlg.editSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tComplaint/update", function(data){ |
| | | Feng.success("修改成功!"); |
| | | window.parent.TComplaint.table.refresh(); |
| | | TComplaintInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("修改失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tComplaintInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | $(function() { |
| | | Feng.initValidator("complaintFormInfo", TComplaintInfoDlg.validateFields); |
| | | |
| | | }); |
| | |
| | | }, |
| | | {title: '条件金额', field: 'couponConditionalAmount', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '优惠金额', field: 'couponPreferentialAmount', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '数量', field: 'couponCount', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '数量', field: 'couponCount', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | | if (row.couponCount === 0){ |
| | | return '<span>无限制</span>' |
| | | }else{ |
| | | return row.couponCount |
| | | } |
| | | } |
| | | }, |
| | | {title: '有效期', field: 'couponValidity', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '状态', field: 'couponState', visible: true, align: 'center', valign: 'middle', |
| | | formatter: function (value, row) { |
| | |
| | | TCoupon.table.refresh({query: queryData}); |
| | | }; |
| | | |
| | | /** |
| | | * 重置 |
| | | */ |
| | | TCoupon.resetSearch = function (){ |
| | | $("#couponType").val(''); |
| | | $("#couponServiceType").val(''); |
| | | $("#createTime").val(''); |
| | | TCoupon.search(); |
| | | } |
| | | |
| | | $(function () { |
| | | var defaultColunms = TCoupon.initColumn(); |
| | | var table = new BSTable(TCoupon.id, "/tCoupon/list", defaultColunms); |
| | |
| | | } |
| | | } |
| | | }, |
| | | remainingQuantity: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '优惠券总量不能为空' |
| | | } |
| | | } |
| | | }, |
| | | } |
| | | }; |
| | | |
| | |
| | | TCouponInfoDlg.collectData = function() { |
| | | this |
| | | .set('id') |
| | | .set('createtime') |
| | | .set('createTime') |
| | | .set('couponType') |
| | | .set('couponServiceType') |
| | | .set('couponCount') |
| | |
| | | .set('couponPreferentialAmount') |
| | | .set('couponValidity') |
| | | .set('couponSendQuantity') |
| | | .set('remainingQuantity') |
| | | .set('couponName'); |
| | | } |
| | | |
New file |
| | |
| | | /** |
| | | * 管理初始化 |
| | | */ |
| | | var TSystemConfig = { |
| | | id: "TSystemConfigTable", //表格id |
| | | seItem: null, //选中的条目 |
| | | table: null, |
| | | layerIndex: -1 |
| | | }; |
| | | |
| | | /** |
| | | * 初始化表格的列 |
| | | */ |
| | | TSystemConfig.initColumn = function () { |
| | | return [ |
| | | {field: 'selectItem', radio: true}, |
| | | {title: '主键', field: 'id', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '类型(1=派单规则,2=佣金分成规则,3=抽成规则,4=积分规则,5=价格规则,6=余额规则,7=客服管理)', field: 'type', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '内容', field: 'content', visible: true, align: 'center', valign: 'middle'} |
| | | ]; |
| | | }; |
| | | |
| | | /** |
| | | * 检查是否选中 |
| | | */ |
| | | TSystemConfig.check = function () { |
| | | var selected = $('#' + this.id).bootstrapTable('getSelections'); |
| | | if(selected.length == 0){ |
| | | Feng.info("请先选中表格中的某一记录!"); |
| | | return false; |
| | | }else{ |
| | | TSystemConfig.seItem = selected[0]; |
| | | return true; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 点击添加 |
| | | */ |
| | | TSystemConfig.openAddTSystemConfig = function () { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '添加', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tSystemConfig/tSystemConfig_add' |
| | | }); |
| | | this.layerIndex = index; |
| | | }; |
| | | |
| | | /** |
| | | * 打开查看详情 |
| | | */ |
| | | TSystemConfig.openTSystemConfigDetail = function () { |
| | | if (this.check()) { |
| | | var index = layer.open({ |
| | | type: 2, |
| | | title: '详情', |
| | | area: ['800px', '420px'], //宽高 |
| | | fix: false, //不固定 |
| | | maxmin: true, |
| | | content: Feng.ctxPath + '/tSystemConfig/tSystemConfig_update/' + TSystemConfig.seItem.id |
| | | }); |
| | | this.layerIndex = index; |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | TSystemConfig.delete = function () { |
| | | if (this.check()) { |
| | | var ajax = new $ax(Feng.ctxPath + "/tSystemConfig/delete", function (data) { |
| | | Feng.success("删除成功!"); |
| | | TSystemConfig.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("删除失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set("tSystemConfigId",this.seItem.id); |
| | | ajax.start(); |
| | | } |
| | | }; |
| | | |
| | | /** |
| | | * 派单规则 |
| | | */ |
| | | TSystemConfig.dispatchRulesSubmit = function () { |
| | | var ajax = new $ax(Feng.ctxPath + "/tSystemConfig/systemConfigSubmit", function (data) { |
| | | Feng.success("保存成功!"); |
| | | TSystemConfig.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("保存失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | var reqData = {}; |
| | | reqData['num1'] = Number($("#num1").val()); |
| | | reqData['num2'] = Number($("#num2").val()); |
| | | reqData['num3'] = Number($("#num3").val()); |
| | | reqData['num4'] = Number($("#num4").val()); |
| | | reqData['num5'] = Number($("#num5").val()); |
| | | ajax.set("content",JSON.stringify(reqData)); |
| | | ajax.set("type",1); |
| | | ajax.start(); |
| | | }; |
| | | |
| | | /** |
| | | * 佣金分成规则 |
| | | */ |
| | | TSystemConfig.commissionShareRules = function () { |
| | | var ajax = new $ax(Feng.ctxPath + "/tSystemConfig/systemConfigSubmit", function (data) { |
| | | Feng.success("保存成功!"); |
| | | TSystemConfig.table.refresh(); |
| | | }, function (data) { |
| | | Feng.error("保存失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | var reqData = {}; |
| | | reqData['num1'] = Number($("#num1").val()); |
| | | reqData['num2'] = Number($("#num2").val()); |
| | | reqData['num3'] = Number($("#num3").val()); |
| | | reqData['num4'] = Number($("#num4").val()); |
| | | reqData['num5'] = Number($("#num5").val()); |
| | | reqData['num6'] = Number($("#num6").val()); |
| | | reqData['num7'] = Number($("#num7").val()); |
| | | ajax.set("content",JSON.stringify(reqData)); |
| | | ajax.set("type",1); |
| | | ajax.start(); |
| | | }; |
| | | |
| | | /** |
| | | * 查询列表 |
| | | */ |
| | | TSystemConfig.search = function () { |
| | | var queryData = {}; |
| | | queryData['condition'] = $("#condition").val(); |
| | | TSystemConfig.table.refresh({query: queryData}); |
| | | }; |
| | | |
| | | $(function () { |
| | | var defaultColunms = TSystemConfig.initColumn(); |
| | | var table = new BSTable(TSystemConfig.id, "/tSystemConfig/list", defaultColunms); |
| | | table.setPaginationType("client"); |
| | | TSystemConfig.table = table.init(); |
| | | }); |
New file |
| | |
| | | /** |
| | | * 初始化详情对话框 |
| | | */ |
| | | var TSystemConfigInfoDlg = { |
| | | tSystemConfigInfoData : {} |
| | | }; |
| | | |
| | | /** |
| | | * 清除数据 |
| | | */ |
| | | TSystemConfigInfoDlg.clearData = function() { |
| | | this.tSystemConfigInfoData = {}; |
| | | } |
| | | |
| | | /** |
| | | * 设置对话框中的数据 |
| | | * |
| | | * @param key 数据的名称 |
| | | * @param val 数据的具体值 |
| | | */ |
| | | TSystemConfigInfoDlg.set = function(key, val) { |
| | | this.tSystemConfigInfoData[key] = (typeof val == "undefined") ? $("#" + key).val() : val; |
| | | return this; |
| | | } |
| | | |
| | | /** |
| | | * 设置对话框中的数据 |
| | | * |
| | | * @param key 数据的名称 |
| | | * @param val 数据的具体值 |
| | | */ |
| | | TSystemConfigInfoDlg.get = function(key) { |
| | | return $("#" + key).val(); |
| | | } |
| | | |
| | | /** |
| | | * 关闭此对话框 |
| | | */ |
| | | TSystemConfigInfoDlg.close = function() { |
| | | parent.layer.close(window.parent.TSystemConfig.layerIndex); |
| | | } |
| | | |
| | | /** |
| | | * 收集数据 |
| | | */ |
| | | TSystemConfigInfoDlg.collectData = function() { |
| | | this |
| | | .set('id') |
| | | .set('type') |
| | | .set('content'); |
| | | } |
| | | |
| | | /** |
| | | * 提交添加 |
| | | */ |
| | | TSystemConfigInfoDlg.addSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tSystemConfig/add", function(data){ |
| | | Feng.success("添加成功!"); |
| | | window.parent.TSystemConfig.table.refresh(); |
| | | TSystemConfigInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("添加失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tSystemConfigInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | /** |
| | | * 提交修改 |
| | | */ |
| | | TSystemConfigInfoDlg.editSubmit = function() { |
| | | |
| | | this.clearData(); |
| | | this.collectData(); |
| | | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tSystemConfig/update", function(data){ |
| | | Feng.success("修改成功!"); |
| | | window.parent.TSystemConfig.table.refresh(); |
| | | TSystemConfigInfoDlg.close(); |
| | | },function(data){ |
| | | Feng.error("修改失败!" + data.responseJSON.message + "!"); |
| | | }); |
| | | ajax.set(this.tSystemConfigInfoData); |
| | | ajax.start(); |
| | | } |
| | | |
| | | $(function() { |
| | | |
| | | }); |