智慧保安后台管理-外网-验收版本
Administrator
2021-09-10 e105a89e83408e15e4527450362356c3d87234c5
装备,车辆字段新增
6 files modified
68 ■■■■■ changed files
src/main/java/org/springblade/modules/equipage/controller/CarController.java 8 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/equipage/controller/EquipageController.java 8 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/equipage/entity/Car.java 11 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/equipage/entity/Equipage.java 13 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/system/mapper/DeptMapper.xml 25 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/system/mapper/UserMapper.xml 3 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/equipage/controller/CarController.java
@@ -80,7 +80,7 @@
            //数据同步
            String s1 =
                "insert into sys_car(id,car_number,number_type,car_type,dept_id," +
                    "person_in_charge,brand,date_for_production,umweltsatz,mode,jurisdiction) " +
                    "person_in_charge,brand,date_for_production,umweltsatz,mode,jurisdiction,picture,driving_conditions) " +
                    "values(" + "'" + car.getId() + "'" + "," +
                    "'" + car.getCarNumber() + "'" + "," +
                    "'" + car.getNumberType() + "'" + "," +
@@ -91,7 +91,9 @@
                    "'" + new SimpleDateFormat("yyyy-MM-dd").format(car.getDateForProduction()) + "'" + "," +
                    "'" + car.getUmweltsatz() + "'" + "," +
                    "'" + car.getMode() + "'" + "," +
                    "'" +car.getJurisdiction() + "'" + ")";
                    "'" + car.getJurisdiction() + "'" + "," +
                    "'" + car.getPicture() + "'" + "," +
                    "'" +car.getDrivingConditions() + "'" + ")";
            FtpUtil.sqlFileUpload(s1);
        }else {
            //修改
@@ -108,6 +110,8 @@
                    ",umweltsatz = " + "'" + car.getUmweltsatz() + "'" +
                    ",mode = " + "'" + car.getMode() + "'" +
                    ",jurisdiction = " + "'" + car.getJurisdiction() + "'" +
                    ",picture = " + "'" + car.getPicture() + "'" +
                    ",driving_conditions = " + "'" + car.getDrivingConditions() + "'" +
                    " " +"where id = " + "'" + car.getId() + "'";
            FtpUtil.sqlFileUpload(s1);
        }
src/main/java/org/springblade/modules/equipage/controller/EquipageController.java
@@ -82,7 +82,7 @@
            //数据推送
            String s1 =
                "insert into sys_equipage(id,name,number,specifications,mode,dept_id,brand,date_for_production,jurisdiction,user_id,num) " +
                "insert into sys_equipage(id,name,number,specifications,mode,dept_id,brand,date_for_production,jurisdiction,user_id,num,purchase_time,type) " +
                    "values(" + "'" + equipage.getId() + "'" + "," +
                    "'" + equipage.getName() + "'" + "," +
                    "'" + equipage.getNumber() + "'" + "," +
@@ -93,7 +93,9 @@
                    "'" + new SimpleDateFormat("yyyy-MM-dd").format(equipage.getDateForProduction()) + "'" + "," +
                    "'" + equipage.getJurisdiction() + "'" + "," +
                    "'" + equipage.getUserId() + "'" + "," +
                    "'" +equipage.getNum() + "'" + ")";
                    "'" + equipage.getNum() + "'" + "," +
                    "'" + new SimpleDateFormat("yyyy-MM-dd").format(equipage.getPurchaseTime()) + "'" + "," +
                    "'" +equipage.getType() + "'" + ")";
            FtpUtil.sqlFileUpload(s1);
        }else {
            //修改
@@ -110,6 +112,8 @@
                    ",jurisdiction = " + "'" + equipage.getJurisdiction() + "'" +
                    ",user_id = " + "'" + equipage.getUserId() + "'" +
                    ",num = " + "'" + equipage.getNum() + "'" +
                    ",purchase_time = " + "'" + equipage.getPurchaseTime() + "'" +
                    ",type = " + "'" + equipage.getType() + "'" +
                    " " +"where id = " + "'" + equipage.getId() + "'";
            FtpUtil.sqlFileUpload(s1);
        }
src/main/java/org/springblade/modules/equipage/entity/Car.java
@@ -80,4 +80,15 @@
    private String mode;
    private String jurisdiction;
    /**
     * 图片
     */
    private String picture;
    /**
     * 行驶情况
     */
    @TableField("driving_conditions")
    private String drivingConditions;
}
src/main/java/org/springblade/modules/equipage/entity/Equipage.java
@@ -85,4 +85,17 @@
     */
    private Integer num;
    /**
     * 采购时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @TableField("purchase_time")
    private Integer purchaseTime;
    /**
     * 装备类型
     */
    private Integer type;
}
src/main/java/org/springblade/modules/system/mapper/DeptMapper.xml
@@ -103,7 +103,24 @@
        ORDER BY dept.sort
    </select>
    <!--查询保安公司列表,保安员管理-->
    <select id="securityLazyTree" resultMap="treeNodeResultMap" >
        (
        SELECT
        id,
        parent_id,
        dept_name AS title,
        id AS "value",
        id AS "key",
        0 AS "has_children"
        FROM
        blade_dept
        where is_deleted = 0
        and
        (id = 1413470343230877697 or id = 1425366663452196865 or id = 1418458374477549569 or id = 1420222768149966850)
        )
        union
        (
        SELECT
        DISTINCT
        dept.id,
@@ -127,13 +144,17 @@
        si.departmentid = dept.id
        WHERE
        1=1
        and dept_category = 1
        and si.stats != 4
        AND dept.is_deleted = 0
        and dept.id !=1420222961377357825
        and dept.parent_id!=1420222961377357825
        <if test="param1!=null and param1!='' and param1!='1123598813738675201'">
        and dept.parent_id!=1425365577303621633
        and dept.id != 1425365577303621633
        and dept.id != 1432625856013971457
        <if test="param1!=null and param1!='' and param1!='1372091709474910209'">
            and si.jurisdiction = #{param1}
        </if>
        )
    </select>
    <!--懒加载获取部门树形结构(按分类查询)-->
src/main/java/org/springblade/modules/system/mapper/UserMapper.xml
@@ -75,6 +75,9 @@
        br.id = bu.role_id
        where
        bu.is_deleted = 0
        and bd.parent_id!=1425365577303621633
        and bd.id != 1425365577303621633
        and bd.id != 1432625856013971457
        <if test="user.account!=null and user.account != ''">
            and bu.account like concat('%', #{user.account},'%')
        </if>