puzhibing
2023-08-22 d1a6b40e384caccf4134a61f43437b5c1fba7f45
修改bug
12个文件已修改
13个文件已添加
811 ■■■■ 已修改文件
ManagementIGOTravel/guns-admin/pom.xml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/general/SettlementAllocationController.java 95 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/SettlementAllocationMapper.java 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/SettlementRecordMapper.java 29 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/SettlementAllocationMapper.xml 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/SettlementRecordMapper.xml 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/model/SettlementAllocation.java 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/model/SettlementRecord.java 70 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/ISettlementAllocationService.java 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/ISettlementRecordService.java 27 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/SettlementAllocationServiceImpl.java 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/SettlementRecordServiceImpl.java 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/util/EmailUtil.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/resources/application.yml 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/settlementAllocation/settlementAllocation.html 70 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_add.html 43 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_edit.html 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_immediately.html 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_look.html 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tUser/tUser_userDetail.html 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/settlementAllocation/settlementAllocation.js 125 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tDriver/tDriver.js 62 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tDriver/yesDriver.js 26 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tReportLoss/tReportLoss.js 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tUser/tUser.js 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ManagementIGOTravel/guns-admin/pom.xml
@@ -211,6 +211,10 @@
            <artifactId>CheckoutEncryption</artifactId>
            <version>0.0.1</version>
        </dependency>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
        </dependency>
    </dependencies>
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/controller/general/SettlementAllocationController.java
New file
@@ -0,0 +1,95 @@
package com.stylefeng.guns.modular.system.controller.general;
import com.alibaba.fastjson.JSON;
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.modular.system.model.SettlementAllocation;
import com.stylefeng.guns.modular.system.service.ISettlementAllocationService;
import com.stylefeng.guns.modular.system.service.ISettlementRecordService;
import com.stylefeng.guns.modular.system.util.ResultUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.List;
import java.util.Map;
/**
 * @author zhibing.pu
 * @Date 2023/8/14 16:16
 */
@Controller
@RequestMapping("/settlementAllocation")
public class SettlementAllocationController extends BaseController {
    private String PREFIX = "/system/settlementAllocation/";
    @Autowired
    private ISettlementAllocationService settlementAllocationService;
    @Autowired
    private ISettlementRecordService settlementRecordService;
    /**
     * 跳转到配置页
     * @return
     */
    @GetMapping("/showSettlementAllocation")
    public String showSettlementAllocation(Model model){
        SettlementAllocation settlementAllocation = settlementAllocationService.selectOne(null);
        if(null != settlementAllocation){
            model.addAttribute("item", JSON.parseObject(settlementAllocation.getContent()));
        }else{
            model.addAttribute("item", null);
        }
        return PREFIX + "settlementAllocation.html";
    }
    /**
     * 修改配置
     * @param json
     * @return
     */
    @ResponseBody
    @PostMapping("/setSettlementAllocation")
    public ResultUtil setSettlementAllocation(String json){
        SettlementAllocation settlementAllocation = settlementAllocationService.selectOne(null);
        if(null == settlementAllocation){
            settlementAllocation = new SettlementAllocation();
            settlementAllocation.setContent(json);
            settlementAllocationService.insert(settlementAllocation);
        }else{
            settlementAllocation.setContent(json);
            settlementAllocationService.updateById(settlementAllocation);
        }
        return ResultUtil.success();
    }
    /**
     * 获取结算记录列表
     * @param time
     * @param money
     * @param status
     * @param driverName
     * @return
     */
    @ResponseBody
    @PostMapping("/querySettlementRecordList")
    public Object querySettlementRecordList(String time, Double money, Integer status, String driverName){
        Page<Map<String, Object>> page = new PageFactory().defaultPage();
        List<Map<String, Object>> list = settlementRecordService.querySettlementRecordList(page, time, money, status, driverName);
        page.setRecords(list);
        return super.packForBT(page);
    }
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/SettlementAllocationMapper.java
New file
@@ -0,0 +1,11 @@
package com.stylefeng.guns.modular.system.dao;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.stylefeng.guns.modular.system.model.SettlementAllocation;
/**
 * @author zhibing.pu
 * @Date 2023/8/14 16:14
 */
public interface SettlementAllocationMapper extends BaseMapper<SettlementAllocation> {
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/SettlementRecordMapper.java
New file
@@ -0,0 +1,29 @@
package com.stylefeng.guns.modular.system.dao;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.stylefeng.guns.modular.system.model.SettlementRecord;
import org.apache.ibatis.annotations.Param;
import java.util.List;
import java.util.Map;
/**
 * @author zhibing.pu
 * @Date 2023/8/17 19:38
 */
public interface SettlementRecordMapper extends BaseMapper<SettlementRecord> {
    /**
     * 获取结算列表
     * @param page
     * @param money
     * @param status
     * @param driverName
     * @return
     */
    List<Map<String, Object>> querySettlementRecordList(Page<Map<String, Object>> page, @Param("startTime") String startTime,
                                                        @Param("endTime") String endTime, @Param("money") Double money,
                                                        @Param("status") Integer status, @Param("driverName") String driverName);
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/SettlementAllocationMapper.xml
New file
@@ -0,0 +1,10 @@
<?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.SettlementAllocationMapper">
    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.stylefeng.guns.modular.system.model.SettlementAllocation">
        <id column="id" property="id" />
        <result column="content" property="content" />
    </resultMap>
</mapper>
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/SettlementRecordMapper.xml
New file
@@ -0,0 +1,46 @@
<?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.SettlementRecordMapper">
    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.stylefeng.guns.modular.system.model.SettlementRecord">
        <id column="id" property="id"/>
        <result column="day" property="day"/>
        <result column="driverId" property="driverId"/>
        <result column="type" property="type"/>
        <result column="paymentStatus" property="paymentStatus"/>
        <result column="payMoney" property="payMoney"/>
        <result column="payType" property="payType"/>
        <result column="code" property="code"/>
        <result column="insertTime" property="insertTime"/>
    </resultMap>
    <select id="querySettlementRecordList" resultType="map">
        select
        a.id,
        DATE_FORMAT(a.`day`, '%Y-%m-%d') as `day`,
        a.payMoney,
        a.payType,
        a.paymentStatus,
        CONCAT(b.firstName, ' ', b.lastName) as driverName,
        DATE_FORMAT(a.payTime, '%Y-%m-%d %H:%i:%s') as payTime
        from t_settlement_record a
        left join t_driver b on (a.driverId = b.id)
        where 1 = 1
        <if test="null != startTime and '' != startTime and null != endTime and '' != endTime">
            and DATE_FORMAT(a.`day`, '%Y-%m-%d') between #{startTime} and #{endTime}
        </if>
        <if test="null != money">
            and a.payMoney = #{money}
        </if>
        <if test="null != status">
            and a.paymentStatus = #{status}
        </if>
        <if test="null != driverName">
            and CONCAT(b.firstName, ' ', b.lastName) like CONCAT('%', #{driverName}, '%')
        </if>
        order by a.insertTime desc
    </select>
</mapper>
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/model/SettlementAllocation.java
New file
@@ -0,0 +1,40 @@
package com.stylefeng.guns.modular.system.model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
/**
 * @author zhibing.pu
 * @Date 2023/8/14 16:12
 */
@TableName("t_settlement_allocation")
public class SettlementAllocation {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 配置json
     */
    @TableField("content")
    private String content;
    public Integer getId() {
        return id;
    }
    public void setId(Integer id) {
        this.id = id;
    }
    public String getContent() {
        return content;
    }
    public void setContent(String content) {
        this.content = content;
    }
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/model/SettlementRecord.java
New file
@@ -0,0 +1,70 @@
package com.stylefeng.guns.modular.system.model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import lombok.Data;
import java.util.Date;
/**
 * @author zhibing.pu
 * @Date 2023/8/17 9:13
 */
@Data
@TableName("t_settlement_record")
public class SettlementRecord {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 结算日期
     */
    @TableField("day")
    private Date day;
    /**
     * 司机id
     */
    @TableField("driverId")
    private Integer driverId;
    /**
     * 结算周期(1=日结算,2=周结算,3=月结算)
     */
    @TableField("type")
    private Integer type;
    /**
     * 支付状态(1=待支付,2=已支付)
     */
    @TableField("paymentStatus")
    private Integer paymentStatus;
    /**
     * 支付金额
     */
    @TableField("payMoney")
    private Double payMoney;
    /**
     * 支付方式(1=手机支付,2=银行卡支付,3=余额支付)
     */
    @TableField("payType")
    private Integer payType;
    /**
     * 支付时间
     */
    @TableField("payTime")
    private Date payTime;
    /**
     * 支付单号
     */
    @TableField("code")
    private String code;
    /**
     * 添加时间
     */
    @TableField("insertTime")
    private Date insertTime;
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/ISettlementAllocationService.java
New file
@@ -0,0 +1,11 @@
package com.stylefeng.guns.modular.system.service;
import com.baomidou.mybatisplus.service.IService;
import com.stylefeng.guns.modular.system.model.SettlementAllocation;
/**
 * @author zhibing.pu
 * @Date 2023/8/14 16:15
 */
public interface ISettlementAllocationService extends IService<SettlementAllocation> {
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/ISettlementRecordService.java
New file
@@ -0,0 +1,27 @@
package com.stylefeng.guns.modular.system.service;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.IService;
import com.stylefeng.guns.modular.system.model.SettlementRecord;
import java.util.List;
import java.util.Map;
/**
 * @author zhibing.pu
 * @Date 2023/8/17 19:39
 */
public interface ISettlementRecordService extends IService<SettlementRecord> {
    /**
     * 获取结算记录列表
     * @param page
     * @param time
     * @param money
     * @param status
     * @param driverName
     * @return
     */
    List<Map<String, Object>> querySettlementRecordList(Page<Map<String, Object>> page, String time, Double money, Integer status, String driverName);
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/SettlementAllocationServiceImpl.java
New file
@@ -0,0 +1,15 @@
package com.stylefeng.guns.modular.system.service.impl;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.stylefeng.guns.modular.system.dao.SettlementAllocationMapper;
import com.stylefeng.guns.modular.system.model.SettlementAllocation;
import com.stylefeng.guns.modular.system.service.ISettlementAllocationService;
import org.springframework.stereotype.Service;
/**
 * @author zhibing.pu
 * @Date 2023/8/14 16:15
 */
@Service
public class SettlementAllocationServiceImpl extends ServiceImpl<SettlementAllocationMapper, SettlementAllocation> implements ISettlementAllocationService {
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/SettlementRecordServiceImpl.java
New file
@@ -0,0 +1,41 @@
package com.stylefeng.guns.modular.system.service.impl;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.stylefeng.guns.core.util.ToolUtil;
import com.stylefeng.guns.modular.system.dao.SettlementRecordMapper;
import com.stylefeng.guns.modular.system.model.SettlementRecord;
import com.stylefeng.guns.modular.system.service.ISettlementRecordService;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map;
/**
 * @author zhibing.pu
 * @Date 2023/8/17 19:40
 */
@Service
public class SettlementRecordServiceImpl extends ServiceImpl<SettlementRecordMapper, SettlementRecord> implements ISettlementRecordService {
    /**
     * 获取结算列表
     * @param page
     * @param time
     * @param money
     * @param status
     * @param driverName
     * @return
     */
    @Override
    public List<Map<String, Object>> querySettlementRecordList(Page<Map<String, Object>> page, String time, Double money, Integer status, String driverName) {
        String startTime = "";
        String endTime = "";
        if(ToolUtil.isNotEmpty(time)){
            startTime = time.split(" - ")[0];
            endTime = time.split(" - ")[1];
        }
        return this.baseMapper.querySettlementRecordList(page, startTime, endTime, money, status, driverName);
    }
}
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/util/EmailUtil.java
@@ -51,8 +51,8 @@
        //选择ssl方式
        gmailssl(props);
        final String username = "southwindservice@gmail.com";// gmail 邮箱
        final String password = "ogsntijmguisoiuk";// Google应用专用密码
        final String username = "i-gotech@i-go.group";// gmail 邮箱
        final String password = "mhizkqkhuknbitps";// Google应用专用密码
        // 当做多商户的时候需要使用getInstance, 如果只是一个邮箱发送的话就用getDefaultInstance
        // Session.getDefaultInstance 会将username,password保存在session会话中
        // Session.getInstance 不进行保存
ManagementIGOTravel/guns-admin/src/main/resources/application.yml
@@ -107,15 +107,15 @@
  mail:
    host: smtp.gmail.com # 配置 smtp 服务器地址
    port: 465 # smtp 服务器的端口
    username: southwindservice@gmail.com # 配置邮箱用户名(你的邮箱地址)
    password: ogsntijmguisoiuk # 配置申请到的授权码(刚让复制的授权码)
    username: i-gotech@i-go.group # 配置邮箱用户名(你的邮箱地址)
    password: mhizkqkhuknbitps # 配置申请到的授权码(刚让复制的授权码)
    default-encoding: UTF-8 # 配置邮件编码
    properties:
      mail:
        smtp:
          socketFactoryClass: javax.net.ssl.SSLSocketFactory # 配饰 SSL 加密工厂
        debug: true
    from: southwindservice@gmail.com # 发送方邮件,配在yml中可方便更改
    from: i-gotech@i-go.group # 发送方邮件,配在yml中可方便更改
    template-path: /usr/local/nginx/html/mailbox/
---
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/settlementAllocation/settlementAllocation.html
New file
@@ -0,0 +1,70 @@
@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" style="padding: 20px;">
                            <#button name="修改" icon="fa-edit" clickFun="SettlementAllocation.setSettlementAllocation()"/>
                            <div class="form-group">
                                <input type="radio" name="type" value="3" ${null != item && item.type == '3' ? 'checked' : ''}> 每月&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                每月<input type="number" min="1" max="31" class="date" value="${null != item && item.type == '3' ? item.day : ''}" style="background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"/> 号可结算
                            </div>
                            <div class="form-group">
                                <input type="radio" name="type" value="2" ${null != item && item.type == '2' ? 'checked' : ''}> 每周&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                每周 <input type="number" min="1" max="7" class="date" value="${null != item && item.type == '2' ? item.day : ''}" style="background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"/> 可结算
                            </div>
                            <div class="form-group">
                                每天超过 <input type="number" min="1" max="31" id="maxPrice" value="${null != item ? item.maxPrice : ''}" style="background-color: #FFFFFF;background-image: none;border: 1px solid #e5e6e7;border-radius: 1px;color: inherit;padding: 6px 12px;"/> 必须结算
                            </div>
                        </div>
                        <div class="row">
                            <div class="col-sm-3">
                                <#NameCon id="time" name="结算日期" />
                            </div>
                            <div class="col-sm-2">
                                <#NameCon id="money" name="结算金额" />
                            </div>
                            <div class="col-sm-2">
                                <div class="input-group">
                                    <div class="input-group-btn">
                                        <button data-toggle="dropdown" class="btn btn-white dropdown-toggle" type="button">
                                            结算状态
                                        </button>
                                    </div>
                                    <select class="form-control" id="payStatus">
                                        <option value="">全部</option>
                                        <option value="1">未支付</option>
                                        <option value="2">已支付</option>
                                    </select>
                                </div>
                            </div>
                            <div class="col-sm-2">
                                <#NameCon id="userName" name="结算人" />
                            </div>
                            <div class="col-sm-2">
                                <#button name="搜索" icon="fa-search" clickFun="SettlementAllocation.search()"/>
                                <#button name="重置" icon="fa-trash" clickFun="SettlementAllocation.resetSearch()" space="true"/>
                            </div>
                        </div>
                        <div class="hidden-xs" id="SettlementAllocationTableToolbar" role="group">
                        </div>
                        <#table id="SettlementAllocationTable"/>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script src="${ctxPath}/static/modular/system/settlementAllocation/settlementAllocation.js"></script>
<script type="text/javascript">
    laydate.render({
        elem: '#time'
        ,range: true
    });
</script>
@}
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_add.html
@@ -46,26 +46,26 @@
                    <#avatar id="headImgUrl" name="头像:" />
                    <!--<#avatar id="faceImgUrl" name="人脸识别照片:" />-->
                    <!--<#input id="phone" name="手机号" />-->
                    <div class="form-group">
                        <label class="col-sm-3 control-label">性别:</label>
                        <div class="col-sm-9"  style="display: flex;align-items: center;">
                            <div class="radio radio-info radio-inline">
                                <input type="radio" id="sex1" value="1" name="sex" checked="" >
                                <label for="sex1"> 男 </label>
                            </div>
                            <div class="radio radio-success radio-inline">
                                <input type="radio" id="sex2" value="2" name="sex" >
                                <label for="sex2"> 女 </label>
                            </div>
                        </div>
                    </div>
                    <!--<div class="form-group">-->
                        <!--<label class="col-sm-3 control-label">性别:</label>-->
                        <!--<div class="col-sm-9"  style="display: flex;align-items: center;">-->
                            <!--<div class="radio radio-info radio-inline">-->
                                <!--<input type="radio" id="sex1" value="1" name="sex" checked="" >-->
                                <!--<label for="sex1"> 男 </label>-->
                            <!--</div>-->
                            <!--<div class="radio radio-success radio-inline">-->
                                <!--<input type="radio" id="sex2" value="2" name="sex" >-->
                                <!--<label for="sex2"> 女 </label>-->
                            <!--</div>-->
                        <!--</div>-->
                    <!--</div>-->
                    <#input id="birthday" name="出生日期"/>
                    <#input id="email" name="邮箱地址"  type="email"/>
                    <#input id="driveCard" name="驾驶证号码"/>
                    <!--<#input id="driveCard" name="驾驶证号码"/>-->
                    <#avatar id="driveCardImgUrl1" name="驾驶证正面照片:" />
                    <#avatar id="driveCardImgUrl2" name="驾驶证背面照片:" />
                    <#input id="driverAge" name="驾龄" />
                    <#input id="idCard" name="身份证号" />
                    <!--<#input id="idCard" name="身份证号" />-->
                    <#avatar id="idCardImgUrl1" name="身份证正面照片:" />
                    <#avatar id="idCardImgUrl2" name="身份证背面照片:" />
                    <#input id="driverAddress" name="居住地址" />
@@ -141,7 +141,18 @@
                    </div>
                </div>
                -->
                    <#input id="phoneOperator" name="手机号运营商" />
                    <#input id="" name="" />
                    <div class="form-group">
                        <label class="col-sm-3 control-label">手机号运营商</label>
                        <div class="col-sm-9">
                            <select class="form-control" id="phoneOperator" name="phoneOperator">
                                <option value="GH-MTN-B2C">MTN</option>
                                <option value="GH-TIGO-B2C">TIGO</option>
                                <option value="GH-VODAFONE-B2C">VODAFONE</option>
                                <option value="GH-AIRTEL-B2C">AIRTEL</option>
                            </select>
                        </div>
                    </div>
                    <#input id="phone" name="登录账号【手机号】" />
                    <#input id="password" name="密码" type="password"/>
                    <#input id="rePassword" name="确认密码" type="password"/>
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_edit.html
@@ -50,26 +50,26 @@
                    <#avatar id="headImgUrl" name="头像:" avatarImg="${item.headImgUrl}"/>
                    <!--<#avatar id="faceImgUrl" name="人脸识别照片:" avatarImg="${item.faceImgUrl}"/>-->
                    <!--<#input id="phone" name="手机号" value="${item.phone}"/>-->
                    <div class="form-group">
                        <label class="col-sm-3 control-label">性别:</label>
                        <div class="col-sm-9"  style="display: flex;align-items: center;">
                            <div class="radio radio-info radio-inline">
                                <input type="radio" id="sex1" value="1" name="sex" ${1 == item.sex ? 'checked=checked' : ''}  >
                                <label for="sex1"> 男 </label>
                            </div>
                            <div class="radio radio-success radio-inline">
                                <input type="radio" id="sex2" value="2" name="sex" ${2 == item.sex ? 'checked=checked' : ''} >
                                <label for="sex2"> 女 </label>
                            </div>
                        </div>
                    </div>
                    <!--<div class="form-group">-->
                        <!--<label class="col-sm-3 control-label">性别:</label>-->
                        <!--<div class="col-sm-9"  style="display: flex;align-items: center;">-->
                            <!--<div class="radio radio-info radio-inline">-->
                                <!--<input type="radio" id="sex1" value="1" name="sex" ${1 == item.sex ? 'checked=checked' : ''}  >-->
                                <!--<label for="sex1"> 男 </label>-->
                            <!--</div>-->
                            <!--<div class="radio radio-success radio-inline">-->
                                <!--<input type="radio" id="sex2" value="2" name="sex" ${2 == item.sex ? 'checked=checked' : ''} >-->
                                <!--<label for="sex2"> 女 </label>-->
                            <!--</div>-->
                        <!--</div>-->
                    <!--</div>-->
                    <#input id="birthday" name="出生日期" value="${item.birthday}"/>
                    <#input id="email" name="邮箱地址"  value="${item.email}" type="email"/>
                    <#input id="driveCard" name="驾驶证号码" value="${item.driveCard}"/>
                    <!--<#input id="driveCard" name="驾驶证号码" value="${item.driveCard}"/>-->
                    <#avatar id="driveCardImgUrl1" name="驾驶证正面照片:" avatarImg="${item.driveCardImgUrl1}"/>
                    <#avatar id="driveCardImgUrl2" name="驾驶证背面照片:" avatarImg="${item.driveCardImgUrl2}"/>
                    <#input id="driverAge" name="驾龄"  value="${item.driverAge}"/>
                    <#input id="idCard" name="身份证号" value="${item.idCard}"/>
                    <!--<#input id="idCard" name="身份证号" value="${item.idCard}"/>-->
                    <#avatar id="idCardImgUrl1" name="身份证正面照片:"  avatarImg="${item.idCardImgUrl1}"/>
                    <#avatar id="idCardImgUrl2" name="身份证背面照片:"  avatarImg="${item.idCardImgUrl2}"/>
                    <#input id="driverAddress" name="居住地址" value="${item.driverAddress}"/>
@@ -150,6 +150,17 @@
                    </div>
                    -->
                    <#input id="phoneOperator" name="手机号运营商" value="${item.phoneOperator}"/>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">手机号运营商</label>
                        <div class="col-sm-9">
                            <select class="form-control" id="phoneOperator" name="phoneOperator">
                                <option value="GH-MTN-B2C" ${item.phoneOperator == 'GH-MTN-B2C' ? 'selected' : ''}>MTN</option>
                                <option value="GH-TIGO-B2C" ${item.phoneOperator == 'GH-TIGO-B2C' ? 'selected' : ''}>TIGO</option>
                                <option value="GH-VODAFONE-B2C" ${item.phoneOperator == 'GH-VODAFONE-B2C' ? 'selected' : ''}>VODAFONE</option>
                                <option value="GH-AIRTEL-B2C" ${item.phoneOperator == 'GH-AIRTEL-B2C' ? 'selected' : ''}>AIRTEL</option>
                            </select>
                        </div>
                    </div>
                    <#input id="phone" name="登录账号【手机号】" value="${item.phone}"/>
                    <#input id="password" name="密码" type="password" />
                    <#input id="rePassword" name="确认密码" type="password"  />
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_immediately.html
@@ -9,9 +9,9 @@
                    <#label id="name" name="名" value="${item.firstName}"/>
                    <#label id="phoneOperator" name="手机号运营商" value="${item.phoneOperator}"/>
                    <#label id="phone" name="手机号" value="${item.phone}"/>
                    <#label id="sexStr" name="性别" value="${item.sexStr}"/>
                    <!--<#label id="sexStr" name="性别" value="${item.sexStr}"/>-->
                    <#label id="addTypeStr" name="司机来源" value="${item.addTypeStr}"/>
                    <#label id="driveCard" name="驾驶证号码" value="${item.driveCard}"/>
                    <!--<#label id="driveCard" name="驾驶证号码" value="${item.driveCard}"/>-->
                    <div class="form-group">
                        <label class="col-sm-3 control-label">驾驶证照片:</label>
                        <div class="col-sm-9">
@@ -31,7 +31,7 @@
                            </div>
                        </div>
                    </div>
                    <#label id="idCard" name="身份证号码" value="${item.idCard}"/>
                    <!--<#label id="idCard" name="身份证号码" value="${item.idCard}"/>-->
                    <div class="form-group">
                        <label class="col-sm-3 control-label">身份证正面照片:</label>
                        <div class="col-sm-9">
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tDriver/tDriver_look.html
@@ -9,9 +9,9 @@
                    <#label id="name" name="名" value="${item.firstName}"/>
                    <#label id="phoneOperator" name="手机号运营商" value="${item.phoneOperator}"/>
                    <#label id="phone" name="手机号" value="${item.phone}"/>
                    <#label id="sexStr" name="性别" value="${item.sexStr}"/>
                    <!--<#label id="sexStr" name="性别" value="${item.sexStr}"/>-->
                    <#label id="addTypeStr" name="司机来源" value="${item.addTypeStr}"/>
                    <#label id="driveCard" name="驾驶证号码" value="${item.driveCard}"/>
                    <!--<#label id="driveCard" name="驾驶证号码" value="${item.driveCard}"/>-->
                    <div class="form-group">
                        <label class="col-sm-3 control-label">驾驶证照片:</label>
                        <div class="col-sm-9">
@@ -31,7 +31,7 @@
                            </div>
                        </div>
                    </div>
                    <#label id="idCard" name="身份证号码" value="${item.idCard}"/>
                    <!--<#label id="idCard" name="身份证号码" value="${item.idCard}"/>-->
                    <div class="form-group">
                        <label class="col-sm-3 control-label">身份证正面照片:</label>
                        <div class="col-sm-9">
ManagementIGOTravel/guns-admin/src/main/webapp/WEB-INF/view/system/tUser/tUser_userDetail.html
@@ -18,6 +18,7 @@
                </div>
                <div class="col-sm-6">
                    <#label id="id" name="用户ID" value="${item.id}"/>
                    <#label id="email" name="email" value="${item.email}"/>
                    <#label id="companyName" name="注册地分公司" value="${item.companyName}"/>
                    <#label id="nickName" name="昵称" value="${item.nickName}"/>
                    <#label id="emergencyContactNumber" name="紧急联系人电话" value="${item.emergencyContactNumber}"/>
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/settlementAllocation/settlementAllocation.js
New file
@@ -0,0 +1,125 @@
/**
 * 司机单单返活动管理初始化
 */
var SettlementAllocation = {
    id: "SettlementAllocationTable",    //表格id
    seItem: null,        //选中的条目
    table: null,
    layerIndex: -1
};
/**
 * 初始化表格的列
 */
SettlementAllocation.initColumn = function () {
    return [
        {field: 'selectItem', radio: true},
        {title: '主键', field: 'id', visible: false, align: 'center', valign: 'middle'},
        {title: '结算日期', field: 'day', visible: true, align: 'center', valign: 'middle'},
        {title: '结算金额', field: 'payMoney', visible: true, align: 'center', valign: 'middle'},
        {title: '结算方式', field: 'payType', visible: true, align: 'center', valign: 'middle',
            formatter:function (value, row) {
                if(1 == value){
                    return "手机支付";
                }
                if(2 == value){
                    return "银行卡支付";
                }
                if(3 == value){
                    return "余额支付";
                }
            }
        },
        {title: '结算状态', field: 'paymentStatus', visible: true, align: 'center', valign: 'middle',
            formatter:function (value, row) {
                if(1 == value){
                    return "未支付";
                }
                if(2 == value){
                    return "支付成功";
                }
            }
        },
        {title: '结算人', field: 'driverName', visible: true, align: 'center', valign: 'middle'}
    ];
};
/**
 * 检查是否选中
 */
SettlementAllocation.check = function (type) {
    var selected = $('#' + this.id).bootstrapTable('getSelections');
    if(selected.length == 0){
        Feng.info("请先选中表格中的某一记录!");
        return false;
    }
};
/**
 * 删除司机单单返活动
 */
SettlementAllocation.setSettlementAllocation = function () {
    let type = $('input[name="type"]:checked')[0];
    if(typeof type == "undefined"){
        Feng.error("请选择结算周期");
        return
    }
    let day = $($(type).siblings('.date')[0]).val();
    if('' == day || null == day){
        Feng.error("请输入有效的结算日期")
        return
    }
    let maxPrice = $('#maxPrice').val();
    if('' == maxPrice || null == maxPrice){
        Feng.error("请输入每日结算金额")
        return
    }
    let json = {
        type: $(type).val(),
        day: day,
        maxPrice: maxPrice
    }
    var ajax = new $ax(Feng.ctxPath + "/settlementAllocation/setSettlementAllocation", function (data) {
        if(data.code == 200){
            Feng.success("配置成功!");
        }else{
            Feng.error(data.msg);
        }
    }, function (data) {
        Feng.error("配置失败!" + data.responseJSON.message + "!");
    });
    ajax.set("json", JSON.stringify(json));
    ajax.start();
};
/**
 * 查询司机单单返活动列表
 */
SettlementAllocation.search = function () {
    var queryData = {};
    queryData['time'] = $('#time').val();
    queryData['money'] = $('#money').val();
    queryData['status'] = $('#payStatus').val();
    queryData['driverName'] = $("#userName").val();
    SettlementAllocation.table.refresh({query: queryData});
};
SettlementAllocation.resetSearch = function () {
    $("#time").val("");
    $("#money").val("");
    $("#payStatus").val("");
    $("#userName").val("");
    SettlementAllocation.search();
};
$(function () {
    var defaultColunms = SettlementAllocation.initColumn();
    var table = new BSTable(SettlementAllocation.id, "/settlementAllocation/querySettlementRecordList", defaultColunms);
    table.setPaginationType("server");
    SettlementAllocation.table = table.init();
});
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tDriver/tDriver.js
@@ -111,19 +111,19 @@
                return btn;
            }
        },
        {title: '性别', field: 'sex', visible: true, align: 'center', valign: 'middle',
            formatter: function (value, row) {
                var btn = "";
                if(row.sex != '' && row.sex != null) {
                    if (row.sex == 1) {
                        btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="男" onfocus="TUser.tooltip()">男</p>']
                    }else if (row.sex == 2){
                        btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="女" onfocus="TUser.tooltip()">女</p>']
                    }
                }
                return btn;
            }
        },
        // {title: '性别', field: 'sex', visible: true, align: 'center', valign: 'middle',
        //     formatter: function (value, row) {
        //         var btn = "";
        //         if(row.sex != '' && row.sex != null) {
        //             if (row.sex == 1) {
        //                 btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="男" onfocus="TUser.tooltip()">男</p>']
        //             }else if (row.sex == 2){
        //                 btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="女" onfocus="TUser.tooltip()">女</p>']
        //             }
        //         }
        //         return btn;
        //     }
        // },
        {title: '出生日期', field: 'birthday', visible: true, align: 'center', valign: 'middle',width:'3%',
            formatter: function (value, row) {
                var btn = "";
@@ -135,15 +135,15 @@
                return btn;
            }
        },
        {title: '驾驶证号码', field: 'driveCard', visible: true, align: 'center', valign: 'middle',
            formatter: function (value, row) {
                var btn = "";
                if(row.driveCard != '' && row.driveCard != null) {
                    btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.driveCard + '" onfocus="TUser.tooltip()">' + row.driveCard + '</p>']
                }
                return btn;
            }
        },
        // {title: '驾驶证号码', field: 'driveCard', visible: true, align: 'center', valign: 'middle',
        //     formatter: function (value, row) {
        //         var btn = "";
        //         if(row.driveCard != '' && row.driveCard != null) {
        //             btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.driveCard + '" onfocus="TUser.tooltip()">' + row.driveCard + '</p>']
        //         }
        //         return btn;
        //     }
        // },
        {title: '驾龄', field: 'driverAge', visible: true, align: 'center', valign: 'middle',
            formatter: function (value, row) {
                var btn = "";
@@ -155,15 +155,15 @@
                return btn;
            }
        },
        {title: '身份证号码', field: 'idCard', visible: true, align: 'center', valign: 'middle',
            formatter: function (value, row) {
                var btn = "";
                if(row.idCard != '' && row.idCard != null) {
                    btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.idCard + '" onfocus="TUser.tooltip()">' + row.idCard + '</p>']
                }
                return btn;
            }
        },
        // {title: '身份证号码', field: 'idCard', visible: true, align: 'center', valign: 'middle',
        //     formatter: function (value, row) {
        //         var btn = "";
        //         if(row.idCard != '' && row.idCard != null) {
        //             btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.idCard + '" onfocus="TUser.tooltip()">' + row.idCard + '</p>']
        //         }
        //         return btn;
        //     }
        // },
        {title: '服务模式', field: 'serverStr', visible: true, align: 'center', valign: 'middle',
            formatter: function (value, row) {
                var btn = "";
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tDriver/yesDriver.js
@@ -72,19 +72,19 @@
                return btn;
            }
        },
        {title: '性别', field: 'sex', visible: true, align: 'center', valign: 'middle',width:'3%',
            formatter: function (value, row) {
                var btn = "";
                if(row.sex != '' && row.sex != null) {
                    if (row.sex == 1) {
                        btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="男" onfocus="TUser.tooltip()">男</p>']
                    }else if (row.sex == 2){
                        btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="女" onfocus="TUser.tooltip()">女</p>']
                    }
                }
                return btn;
            }
        },
        // {title: '性别', field: 'sex', visible: true, align: 'center', valign: 'middle',width:'3%',
        //     formatter: function (value, row) {
        //         var btn = "";
        //         if(row.sex != '' && row.sex != null) {
        //             if (row.sex == 1) {
        //                 btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="男" onfocus="TUser.tooltip()">男</p>']
        //             }else if (row.sex == 2){
        //                 btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="女" onfocus="TUser.tooltip()">女</p>']
        //             }
        //         }
        //         return btn;
        //     }
        // },
        {title: '出生日期', field: 'birthday', visible: true, align: 'center', valign: 'middle',width:'3%',
            formatter: function (value, row) {
                var btn = "";
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tReportLoss/tReportLoss.js
@@ -20,7 +20,18 @@
            {title: '联系方式', field: 'phone', visible: true, align: 'center', valign: 'middle'},
            {title: '司机车牌号', field: 'carNumber', visible: true, align: 'center', valign: 'middle'},
           {title: '内容', field: 'remark', visible: true, align: 'center', valign: 'middle'},
        {title: '图片', field: 'image', visible: true, align: 'center', valign: 'middle'},
        {title: '图片', field: 'image', visible: true, align: 'center', valign: 'middle',
            formatter:function(data){
                if(typeof data != "undefined"){
                    let imgs = data.split(",");
                    let htmlStr = '';
                    for (let i = 0; i < imgs.length; i++) {
                        htmlStr += '<img src="' + imgs[i] + '" style="height: 100px;" onclick="lookBigImg(\'' + imgs[i] + '\')"/>&nbsp;&nbsp;&nbsp;&nbsp;'
                    }
                    return htmlStr;
                }
            }
        },
        {title: '状态', field: 'status', visible: true, align: 'center', valign: 'middle',
            formatter:function(data){
                if(data==1){
ManagementIGOTravel/guns-admin/src/main/webapp/static/modular/system/tUser/tUser.js
@@ -69,6 +69,15 @@
                return btn;
            }
        },
        {title: '邮箱', field: 'email', visible: true, align: 'center', valign: 'middle',width:'8%',
            formatter: function (value, row) {
                var btn = "";
                if(row.email != '' && row.email != null) {
                    btn = ['<p class="toolTip" style="overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="' + row.email + '" onfocus="TUser.tooltip()">' + row.email + '</p>']
                }
                return btn;
            }
        },
        {title: '紧急联系人<br/>姓名', field: 'emergencyContact', visible: true, align: 'center', valign: 'middle',width:'8%',
            formatter: function (value, row) {
                var btn = "";