浏览代码

添加资产编号

5 年之前
父节点
当前提交
7b5072a07f

+ 20 - 4
pcbms/src/main/java/com/hssx/pcbms/controller/GoodsController.java

@@ -17,6 +17,8 @@ import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.ResponseBody;
 import org.springframework.web.multipart.MultipartFile;
 
+import javax.servlet.http.HttpServletResponse;
+
 /**
  * @author 吴涛涛
  * @since 2019-10-25
@@ -283,17 +285,31 @@ public class GoodsController {
         return msg;
     }
     /**
-     * 维护资产记录的excel导出
+     * 处置资产记录的excel导出
+     * 参数:
+     * id:资产id
+     *
+     * @return
+     */
+    @ApiOperation(value = "处置资产记录的excel导出", notes = "处置资产记录的excel导出方法")
+    @RequestMapping("/handelRecordExcel")
+    @ResponseBody
+    public HttpRespMsg handelRecordExcel(Goods goods,HttpServletResponse response) {
+        HttpRespMsg msg = goodsService.handelRecordExcel(goods,response);
+        return msg;
+    }
+    /**
+     * 保养资产记录的excel导出
      * 参数:
      * id:资产id
      *
      * @return
      */
-    @ApiOperation(value = "维护资产记录的excel导出", notes = "维护资产记录的excel导出方法")
+    @ApiOperation(value = "保养资产记录的excel导出", notes = "保养资产记录的excel导出方法")
     @RequestMapping("/isMaintainRecordExcel")
     @ResponseBody
-    public HttpRespMsg isMaintainRecordExcel(Goods goods) {
-        HttpRespMsg msg = goodsService.isMaintainRecordExcel(goods);
+    public HttpRespMsg isMaintainExcel(Goods goods,HttpServletResponse response) {
+        HttpRespMsg msg = goodsService.isMaintainExcel(goods,response);
         return msg;
     }
 

+ 0 - 21
pcbms/src/main/java/com/hssx/pcbms/controller/MaintainRecordController.java

@@ -1,21 +0,0 @@
-package com.hssx.pcbms.controller;
-
-
-import org.springframework.web.bind.annotation.RequestMapping;
-
-import org.springframework.web.bind.annotation.RestController;
-
-/**
- * <p>
- *  前端控制器
- * </p>
- *
- * @author 吴涛涛
- * @since 2019-11-01
- */
-@RestController
-@RequestMapping("/maintain-record")
-public class MaintainRecordController {
-
-}
-

+ 1 - 0
pcbms/src/main/java/com/hssx/pcbms/entity/GoodsNo.java

@@ -55,6 +55,7 @@ public class GoodsNo extends Model<GoodsNo> {
      * 创建日期
      */
     @TableField("indate")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     private LocalDateTime indate;
 
     /**

+ 16 - 1
pcbms/src/main/java/com/hssx/pcbms/entity/MaintainRecord.java

@@ -15,7 +15,7 @@ import java.io.Serializable;
  * </p>
  *
  * @author 吴涛涛
- * @since 2019-11-01
+ * @since 2019-11-05
  */
 public class MaintainRecord extends Model<MaintainRecord> {
 
@@ -39,6 +39,12 @@ public class MaintainRecord extends Model<MaintainRecord> {
     @TableField("goods_no_id")
     private Integer goodsNoId;
 
+    /**
+     * 型号
+     */
+    @TableField("model_no")
+    private String modelNo;
+
     /**
      * 维护人姓名
      */
@@ -95,6 +101,14 @@ public class MaintainRecord extends Model<MaintainRecord> {
         this.goodsNoId = goodsNoId;
     }
 
+    public String getModelNo() {
+        return modelNo;
+    }
+
+    public void setModelNo(String modelNo) {
+        this.modelNo = modelNo;
+    }
+
     public String getOperator() {
         return operator;
     }
@@ -146,6 +160,7 @@ public class MaintainRecord extends Model<MaintainRecord> {
         "id=" + id +
         ", goodsId=" + goodsId +
         ", goodsNoId=" + goodsNoId +
+        ", modelNo=" + modelNo +
         ", operator=" + operator +
         ", operatorPhone=" + operatorPhone +
         ", company=" + company +

+ 19 - 1
pcbms/src/main/java/com/hssx/pcbms/entity/OperateRecord.java

@@ -5,6 +5,8 @@ import com.baomidou.mybatisplus.extension.activerecord.Model;
 import com.baomidou.mybatisplus.annotation.TableId;
 import java.time.LocalDateTime;
 import com.baomidou.mybatisplus.annotation.TableField;
+import com.fasterxml.jackson.annotation.JsonFormat;
+
 import java.io.Serializable;
 
 /**
@@ -13,7 +15,7 @@ import java.io.Serializable;
  * </p>
  *
  * @author 吴涛涛
- * @since 2019-10-30
+ * @since 2019-11-05
  */
 public class OperateRecord extends Model<OperateRecord> {
 
@@ -25,6 +27,12 @@ public class OperateRecord extends Model<OperateRecord> {
     @TableId(value = "id", type = IdType.AUTO)
     private Integer id;
 
+    /**
+     * 型号
+     */
+    @TableField("model_no")
+    private String modelNo;
+
     /**
      * 操作人id
      */
@@ -41,6 +49,7 @@ public class OperateRecord extends Model<OperateRecord> {
      * 操作时间
      */
     @TableField("indate")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
     private LocalDateTime indate;
 
     /**
@@ -76,6 +85,14 @@ public class OperateRecord extends Model<OperateRecord> {
         this.id = id;
     }
 
+    public String getModelNo() {
+        return modelNo;
+    }
+
+    public void setModelNo(String modelNo) {
+        this.modelNo = modelNo;
+    }
+
     public Integer getUserId() {
         return userId;
     }
@@ -141,6 +158,7 @@ public class OperateRecord extends Model<OperateRecord> {
     public String toString() {
         return "OperateRecord{" +
         "id=" + id +
+        ", modelNo=" + modelNo +
         ", userId=" + userId +
         ", userName=" + userName +
         ", indate=" + indate +

+ 121 - 1
pcbms/src/main/java/com/hssx/pcbms/entity/User.java

@@ -15,7 +15,7 @@ import java.io.Serializable;
  * </p>
  *
  * @author 吴涛涛
- * @since 2019-10-25
+ * @since 2019-11-05
  */
 public class User extends Model<User> {
 
@@ -76,6 +76,54 @@ public class User extends Model<User> {
     @TableField("role_name")
     private String roleName;
 
+    /**
+     * 邮箱
+     */
+    @TableField("email")
+    private String email;
+
+    /**
+     * 性别 1:男 2:女
+     */
+    @TableField("sex")
+    private Integer sex;
+
+    /**
+     * 生日
+     */
+    @TableField("birthday")
+    private String birthday;
+
+    /**
+     * 联系电话
+     */
+    @TableField("office_phone")
+    private String officePhone;
+
+    /**
+     * 职级
+     */
+    @TableField("job_title")
+    private String jobTitle;
+
+    /**
+     * 登录名
+     */
+    @TableField("login_name")
+    private String loginName;
+
+    /**
+     * 工作性质:0:正式 1:临时
+     */
+    @TableField("xing_zhi")
+    private Integer xingZhi;
+
+    /**
+     * 用户 KEY 编号
+     */
+    @TableField("key_code")
+    private String keyCode;
+
 
     public Integer getId() {
         return id;
@@ -149,6 +197,70 @@ public class User extends Model<User> {
         this.roleName = roleName;
     }
 
+    public String getEmail() {
+        return email;
+    }
+
+    public void setEmail(String email) {
+        this.email = email;
+    }
+
+    public Integer getSex() {
+        return sex;
+    }
+
+    public void setSex(Integer sex) {
+        this.sex = sex;
+    }
+
+    public String getBirthday() {
+        return birthday;
+    }
+
+    public void setBirthday(String birthday) {
+        this.birthday = birthday;
+    }
+
+    public String getOfficePhone() {
+        return officePhone;
+    }
+
+    public void setOfficePhone(String officePhone) {
+        this.officePhone = officePhone;
+    }
+
+    public String getJobTitle() {
+        return jobTitle;
+    }
+
+    public void setJobTitle(String jobTitle) {
+        this.jobTitle = jobTitle;
+    }
+
+    public String getLoginName() {
+        return loginName;
+    }
+
+    public void setLoginName(String loginName) {
+        this.loginName = loginName;
+    }
+
+    public Integer getXingZhi() {
+        return xingZhi;
+    }
+
+    public void setXingZhi(Integer xingZhi) {
+        this.xingZhi = xingZhi;
+    }
+
+    public String getKeyCode() {
+        return keyCode;
+    }
+
+    public void setKeyCode(String keyCode) {
+        this.keyCode = keyCode;
+    }
+
     @Override
     protected Serializable pkVal() {
         return this.id;
@@ -166,6 +278,14 @@ public class User extends Model<User> {
         ", indate=" + indate +
         ", password=" + password +
         ", roleName=" + roleName +
+        ", email=" + email +
+        ", sex=" + sex +
+        ", birthday=" + birthday +
+        ", officePhone=" + officePhone +
+        ", jobTitle=" + jobTitle +
+        ", loginName=" + loginName +
+        ", xingZhi=" + xingZhi +
+        ", keyCode=" + keyCode +
         "}";
     }
 }

+ 5 - 1
pcbms/src/main/java/com/hssx/pcbms/service/GoodsService.java

@@ -10,6 +10,8 @@ import com.hssx.pcbms.util.HttpRespMsg;
 import com.hssx.pcbms.util.PageUtil;
 import org.springframework.web.multipart.MultipartFile;
 
+import javax.servlet.http.HttpServletResponse;
+
 /**
  * <p>
  *  服务类
@@ -50,5 +52,7 @@ public interface GoodsService extends IService<Goods> {
 
     HttpRespMsg myList(PageUtil page, String keyName, Integer uid);
 
-    HttpRespMsg isMaintainRecordExcel(Goods goods);
+    HttpRespMsg handelRecordExcel(Goods goods,HttpServletResponse response);
+
+    HttpRespMsg isMaintainExcel(Goods goods, HttpServletResponse response);
 }

+ 55 - 28
pcbms/src/main/java/com/hssx/pcbms/service/impl/GoodsServiceImpl.java

@@ -15,10 +15,8 @@ import com.hssx.pcbms.service.GoodsService;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.hssx.pcbms.service.MaintainRecordService;
 import com.hssx.pcbms.service.OperateRecordService;
-import com.hssx.pcbms.util.HttpRespMsg;
-import com.hssx.pcbms.util.ListUtil;
-import com.hssx.pcbms.util.PageUtil;
-import com.hssx.pcbms.util.UploadFileToFileNameUtil;
+import com.hssx.pcbms.util.*;
+import com.sun.deploy.net.HttpResponse;
 import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.stereotype.Service;
@@ -26,9 +24,11 @@ import org.springframework.util.CollectionUtils;
 import org.springframework.web.multipart.MultipartFile;
 
 import javax.annotation.Resource;
+import javax.servlet.http.HttpServletResponse;
 import java.text.SimpleDateFormat;
 import java.time.format.DateTimeFormatter;
 import java.util.ArrayList;
+import java.util.Date;
 import java.util.List;
 
 /**
@@ -148,9 +148,8 @@ public class GoodsServiceImpl extends ServiceImpl<GoodsMapper, Goods> implements
         String nowState = "";
         if (no.getState() == 0) {
             oldState = "未用";
-        } else if (no.getState() == 1)
+        } else if (no.getState() == 1){
             oldState = "在用";
-        {
             User usering = userMapper.selectById(no.getUserId());
             oldState = oldState + ("(" + usering.getName() + "/" + usering.getPhone() + ")");
         }
@@ -170,6 +169,7 @@ public class GoodsServiceImpl extends ServiceImpl<GoodsMapper, Goods> implements
         operateRecord.setGoodState(goodsNo.getState());
         operateRecord.setUserId(currentUserId);
         operateRecord.setUserName(user.getName());
+        operateRecord.setModelNo(no.getModelNo());
         operateRecordMapper.insert(operateRecord);
         return msg;
     }
@@ -323,9 +323,9 @@ public class GoodsServiceImpl extends ServiceImpl<GoodsMapper, Goods> implements
     }
 
     @Override
-    public HttpRespMsg isMaintainRecordExcel(Goods goods) {
+    public HttpRespMsg handelRecordExcel(Goods goods, HttpServletResponse response) {
         HttpRespMsg msg = new HttpRespMsg();
-        List<MaintainRecordVO> recordList = maintainRecordMapper.getRecordList(goods);
+        List<OperateRecordVO> recordList = operateRecordMapper.selectCondition(goods);
         List<List<String>> list = new ArrayList<List<String>>();
         //标题
         List<String> titleList = new ArrayList<String>();
@@ -337,33 +337,60 @@ public class GoodsServiceImpl extends ServiceImpl<GoodsMapper, Goods> implements
         SimpleDateFormat dateSdf1 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
         SimpleDateFormat dateSdf = new SimpleDateFormat("yyyy-MM-dd");
         SimpleDateFormat dateSdf2 = new SimpleDateFormat("yyyy年MM月dd+HH时mm分ss秒");
-        for (MaintainRecordVO dynamic : recordList) {
+        for (OperateRecordVO dynamic : recordList) {
             List<String> rowList = new ArrayList<String>();
             //资产编号
-//            rowList.add(dynamic.getFileName());
-//            //操作者名字
-//            rowList.add(dynamic.getOperatorName());
-//            //文件类型
-//            if (dynamic.getBelongType() == 0) {
-//                rowList.add("模具文档");
-//            } else if (dynamic.getBelongType() == 1) {
-//                rowList.add("零件文档");
-//            } else if (dynamic.getBelongType() == 2) {
-//                rowList.add("试模验收");
-//            } else if (dynamic.getBelongType() == 3) {
-//                rowList.add("保养方案");
-//            } else if (dynamic.getBelongType() == 4) {
-//                rowList.add("模具更新");
-//            } else if (dynamic.getBelongType() == 5) {
-//                rowList.add("模具报废");
-//            }
-            //下载时间
+            rowList.add(dynamic.getModelNo());
+            //处置人
+            rowList.add(dynamic.getUserName());
+            //处置时间
+            rowList.add(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss").format(dynamic.getIndate()));
+            //操作内容
+            rowList.add(dynamic.getContent());
+            list.add(rowList);
+        }
+        Goods newGoods = goodsMapper.selectById(goods.getId());
+        String fileUrl = ExcelUtil.exportGeneralExcelByTitleAndList(response, newGoods.getName()+dateSdf2.format(new Date()), list, path);
+        msg.data = fileUrl;
+        return msg;
+    }
 
+    @Override
+    public HttpRespMsg isMaintainExcel(Goods goods, HttpServletResponse response) {
+        HttpRespMsg msg = new HttpRespMsg();
+        List<MaintainRecordVO> recordList = maintainRecordMapper.getRecordList(goods);
+        List<List<String>> list = new ArrayList<List<String>>();
+        //标题
+        List<String> titleList = new ArrayList<String>();
+        titleList.add("资产编号");
+        titleList.add("维护人");
+        titleList.add("维护人号码");
+        titleList.add("维护公司");
+        titleList.add("维护公司电话");
+        titleList.add("操作日期");
+        list.add(titleList);
+        SimpleDateFormat dateSdf2 = new SimpleDateFormat("yyyy年MM月dd+HH时mm分ss秒");
+        for (MaintainRecordVO dynamic : recordList) {
+            List<String> rowList = new ArrayList<String>();
+            //资产编号
+            rowList.add(dynamic.getModelNo());
+            //维护人
+            rowList.add(dynamic.getOperator());
+            //维护人号码
+            rowList.add(dynamic.getOperatorPhone());
+            //维护公司
+            rowList.add(dynamic.getCompany());
+            //维护公司电话
+            rowList.add(dynamic.getCompanyPhone());
+            //操作日期
             rowList.add(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss").format(dynamic.getIndate())
             );
             list.add(rowList);
         }
-        return null;
+        Goods newGoods = goodsMapper.selectById(goods.getId());
+        String fileUrl = ExcelUtil.exportGeneralExcelByTitleAndList(response, newGoods.getName()+dateSdf2.format(new Date()), list, path);
+        msg.data = fileUrl;
+        return msg;
     }
 
     public static void main(String[] args) {

+ 1 - 1
pcbms/src/main/java/com/hssx/pcbms/util/CodeGenerator.java

@@ -204,7 +204,7 @@ public class CodeGenerator {
         //若想要生成的实体类继承某个Controller,则可打开下面注释。写上需要继承的Controller的位置即可
 //        strategy.setSuperControllerClass("com.baomidou.ant.common.BaseController");
         //此处user是表名,多个英文逗号分割
-        strategy.setInclude("goods");
+        strategy.setInclude("maintain_record");
 //        strategy.setExclude();//数据库表全生成
 //        strategy.setInclude(scanner("user").split(","));//表名,多个英文逗号分割
         strategy.setControllerMappingHyphenStyle(true);

+ 5 - 3
pcbms/src/main/java/com/hssx/pcbms/util/ExcelUtil.java

@@ -9,6 +9,7 @@ import org.apache.poi.ss.usermodel.HorizontalAlignment;
 import javax.servlet.http.HttpServletResponse;
 import java.io.File;
 import java.io.FileOutputStream;
+import java.io.OutputStream;
 import java.net.URLEncoder;
 import java.util.List;
 
@@ -129,14 +130,14 @@ public class ExcelUtil {
                     start++;
                 }
             }
-//            OutputStream os = response.getOutputStream();//在线下载
+            OutputStream os = response.getOutputStream();//在线下载
             File dir = null;
             dir = new File(downloadPath);
             // D://cloud/upload 文件上传后所存储的位置,部署到服务器上时配置服务器地址即可
             if (!dir.exists()) {
                 dir.mkdirs();
             }
-            FileOutputStream os = new FileOutputStream(downloadPath+fileName);//保存到本地
+//            FileOutputStream os = new FileOutputStream(downloadPath+fileName);//保存到本地
             workBook.write(os);
             os.flush();
             os.close();
@@ -144,6 +145,7 @@ public class ExcelUtil {
             System.out.println(result);
             e.printStackTrace();
         }
-        return "/upload/"+fileName;
+//        return "/upload/"+fileName;
+        return "";
     }
 }

+ 19 - 18
pcbms/src/main/resources/mapper/MaintainRecordMapper.xml

@@ -4,15 +4,17 @@
 
     <!-- 通用查询映射结果 -->
     <resultMap id="BaseResultMap" type="com.hssx.pcbms.entity.MaintainRecord">
-        <id column="id" property="id"/>
-        <result column="goods_id" property="goodsId"/>
-        <result column="goods_no_id" property="goodsNoId"/>
-        <result column="operator" property="operator"/>
-        <result column="operator_phone" property="operatorPhone"/>
-        <result column="company" property="company"/>
-        <result column="company_phone" property="companyPhone"/>
-        <result column="indate" property="indate"/>
+        <id column="id" property="id" />
+        <result column="goods_id" property="goodsId" />
+        <result column="goods_no_id" property="goodsNoId" />
+        <result column="model_no" property="modelNo" />
+        <result column="operator" property="operator" />
+        <result column="operator_phone" property="operatorPhone" />
+        <result column="company" property="company" />
+        <result column="company_phone" property="companyPhone" />
+        <result column="indate" property="indate" />
     </resultMap>
+
     <resultMap id="BaseResultMapVO" type="com.hssx.pcbms.entity.vo.MaintainRecordVO">
         <id column="id" property="id"/>
         <result column="goods_id" property="goodsId"/>
@@ -27,17 +29,16 @@
 
     <!-- 通用查询结果列 -->
     <sql id="Base_Column_List">
-        id, goods_id, goods_no_id, operator, operator_phone, company, company_phone, indate
+        id, goods_id, goods_no_id, model_no, operator, operator_phone, company, company_phone, indate
     </sql>
 
     <select id="getRecordList" resultMap="BaseResultMapVO">
-        select
-            mr.id, mr.goods_id, mr.goods_no_id, mr.operator, mr.operator_phone, mr.company, mr.company_phone, mr.indate,gn.model_no
-        from
-            maintain_record mr
-        left join goods_no gn
-        on mr.goods_no_id = gn.id
-        where gn.goods_id = #{goods.id,jdbcType=INTEGER}
-        order by mr.indate desc
-    </select>
+    select
+        mr.id, mr.goods_id, mr.goods_no_id, mr.operator, mr.operator_phone, mr.company, mr.company_phone, mr.indate,mr.model_no
+    from
+        maintain_record mr
+    where gn.goods_id = #{goods.id,jdbcType=INTEGER}
+    order by mr.indate desc
+</select>
+
 </mapper>

+ 26 - 26
pcbms/src/main/resources/mapper/OperateRecordMapper.xml

@@ -5,6 +5,7 @@
     <!-- 通用查询映射结果 -->
     <resultMap id="BaseResultMap" type="com.hssx.pcbms.entity.OperateRecord">
         <id column="id" property="id" />
+        <result column="model_no" property="modelNo" />
         <result column="user_id" property="userId" />
         <result column="user_name" property="userName" />
         <result column="indate" property="indate" />
@@ -13,35 +14,34 @@
         <result column="good_no_id" property="goodNoId" />
         <result column="good_state" property="goodState" />
     </resultMap>
-    <resultMap id="BaseResultMapVO" type="com.hssx.pcbms.entity.vo.OperateRecordVO">
-            <result column="model_no" property="modelNo" />
-            <result column="oid" property="id" />
-            <result column="uid" property="userId" />
-            <result column="user_name" property="userName" />
-            <result column="oindate" property="indate" />
-            <result column="content" property="content" />
-            <result column="good_id" property="goodId" />
-            <result column="good_no_id" property="goodNoId" />
-            <result column="good_state" property="goodState" />
-    </resultMap>
-
-
 
     <!-- 通用查询结果列 -->
     <sql id="Base_Column_List">
-        id, user_id, user_name, indate, content, good_id, good_no_id, good_state
+        id, model_no, user_id, user_name, indate, content, good_id, good_no_id, good_state
     </sql>
+
+    <resultMap id="BaseResultMapVO" type="com.hssx.pcbms.entity.vo.OperateRecordVO">
+        <result column="model_no" property="modelNo" />
+        <result column="oid" property="id" />
+        <result column="uid" property="userId" />
+        <result column="user_name" property="userName" />
+        <result column="oindate" property="indate" />
+        <result column="content" property="content" />
+        <result column="good_id" property="goodId" />
+        <result column="good_no_id" property="goodNoId" />
+        <result column="good_state" property="goodState" />
+    </resultMap>
+
     <select id="selectCondition" resultMap="BaseResultMapVO">
-        select
-            go.model_no, go.state,
-            ore.id oid, ore.user_id uid, ore.user_name, ore.indate oindate,
-            ore.content, ore.good_id, ore.good_no_id, ore.good_state
-        from
-            operate_record ore
-        left join
-            goods_no go
-        on ore.good_no_id = go.id
-        where
-            go.goods_id = #{goods.id}
-    </select>
+    select
+        ore.model_no,
+        ore.id oid, ore.user_id uid, ore.user_name, ore.indate oindate,
+        ore.content, ore.good_id, ore.good_no_id, ore.good_state
+    from
+        operate_record ore
+    where
+        go.goods_id = #{goods.id}
+    order by ore.indate desc
+</select>
+
 </mapper>

+ 14 - 8
pcbms/src/main/resources/mapper/UserMapper.xml

@@ -13,8 +13,21 @@
         <result column="indate" property="indate" />
         <result column="password" property="password" />
         <result column="role_name" property="roleName" />
+        <result column="email" property="email" />
+        <result column="sex" property="sex" />
+        <result column="birthday" property="birthday" />
+        <result column="office_phone" property="officePhone" />
+        <result column="job_title" property="jobTitle" />
+        <result column="login_name" property="loginName" />
+        <result column="xing_zhi" property="xingZhi" />
+        <result column="key_code" property="keyCode" />
     </resultMap>
 
+    <!-- 通用查询结果列 -->
+    <sql id="Base_Column_List">
+        id, head_url, name, phone, dept_id, is_pass, indate, password, role_name, email, sex, birthday, office_phone, job_title, login_name, xing_zhi, key_code
+    </sql>
+
     <resultMap id="BaseResultMapVO" type="com.hssx.pcbms.entity.vo.UserVO">
         <id column="id" property="id" />
         <result column="head_url" property="headUrl" />
@@ -29,15 +42,9 @@
         </collection>
     </resultMap>
 
-    <!-- 通用查询结果列 -->
-    <sql id="Base_Column_List">
-        id, head_url, name, phone, dept_id, is_pass, indate, password, role_name
-    </sql>
-
     <select id="selectUserRolesAndPermisssuons" resultMap="BaseResultMapVO">
         select
-            u.id, u.head_url, u.name, u.phone, u.dept_id, u.is_pass, u.indate,u.role_name,
-            p.permission_name,p.describe
+            u.id, u.head_url, u.name, u.phone, u.dept_id, u.is_pass, u.indate,u.role_name
         from
             user u
         left join user_permission up
@@ -46,5 +53,4 @@
         on p.id = up.permission_id
         where u.id = #{user.id,jdbcType=INTEGER}
     </select>
-
 </mapper>