数据隔离
This commit is contained in:
		
							parent
							
								
									3ef1f51584
								
							
						
					
					
						commit
						484c3b290f
					
				| 
						 | 
				
			
			@ -63,6 +63,9 @@ public class MaDevRm extends BaseEntity implements Serializable {
 | 
			
		|||
    @ApiModelProperty(value = "上传人")
 | 
			
		||||
    private String nickName;
 | 
			
		||||
 | 
			
		||||
    @ApiModelProperty(value = "上传人所属公司")
 | 
			
		||||
    private String rmCom;
 | 
			
		||||
 | 
			
		||||
    @ApiModelProperty(value = "维保次数")
 | 
			
		||||
    private Integer minNum;
 | 
			
		||||
    private Integer maxNum;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -761,6 +761,7 @@ public class DevInfoServiceImpl implements DevInfoService {
 | 
			
		|||
 | 
			
		||||
    @Override
 | 
			
		||||
    public List<DevInfoVo> getTagDevList(DevInfoVo devInfoVo) {
 | 
			
		||||
        devInfoVo.setOwnCo(SecurityUtils.getLoginUser().getSysUser().getCompanyId());
 | 
			
		||||
        return devInfoMapper.getTagDevList(devInfoVo);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -36,11 +36,12 @@ public class MaDevRmServiceImpl implements MaDevRmService {
 | 
			
		|||
    /**
 | 
			
		||||
     * 装备质检列表
 | 
			
		||||
     *
 | 
			
		||||
     * @param maDevQc
 | 
			
		||||
     * @param maDevRm
 | 
			
		||||
     * @return
 | 
			
		||||
     */
 | 
			
		||||
    @Override
 | 
			
		||||
    public List<MaDevRm> selectDevQcList(MaDevRm maDevRm) {
 | 
			
		||||
        maDevRm.setRmCom(SecurityUtils.getLoginUser().getSysUser().getCompanyId().toString());
 | 
			
		||||
        return maDevRmMapper.selectDevQcList(maDevRm);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -59,6 +60,7 @@ public class MaDevRmServiceImpl implements MaDevRmService {
 | 
			
		|||
        maDevRm.setRmCode(code);
 | 
			
		||||
        maDevRm.setCreateBy(String.valueOf(SecurityUtils.getUserId()));
 | 
			
		||||
        maDevRm.setCreateTime(DateUtils.getNowDate());
 | 
			
		||||
        maDevRm.setRmCom(SecurityUtils.getLoginUser().getSysUser().getCompanyId().toString());
 | 
			
		||||
        int result = maDevRmMapper.insertDevQc(maDevRm);
 | 
			
		||||
//        devInfoMapper.updateDevInfoIsQc(maDevRm);
 | 
			
		||||
        if (result > 0 && maDevRm.getId() != null) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -763,6 +763,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 | 
			
		|||
        WHERE
 | 
			
		||||
            d.is_active = 1
 | 
			
		||||
          AND d.ma_status !=0
 | 
			
		||||
          AND d.own_co = #{ownCo}
 | 
			
		||||
        <if test="code != null and code != ''">
 | 
			
		||||
          and d.code like concat('%',#{code},'%')
 | 
			
		||||
        </if>
 | 
			
		||||
| 
						 | 
				
			
			@ -776,7 +777,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 | 
			
		|||
          and dept.dept_name like concat('%',#{comName},'%')
 | 
			
		||||
        </if>
 | 
			
		||||
        <if test="startTime != null and startTime != '' and endTime != null and endTime != ''">
 | 
			
		||||
            and DATE_FORMAT(d.create_time,'%Y-%m-%d') between #{startTime} and #{endTime}
 | 
			
		||||
          and DATE_FORMAT(d.create_time,'%Y-%m-%d') between #{startTime} and #{endTime}
 | 
			
		||||
        </if>
 | 
			
		||||
    </select>
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -18,6 +18,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 | 
			
		|||
            <if test="rmTime != null">rm_time,</if>
 | 
			
		||||
            <if test="createBy != null">create_by,</if>
 | 
			
		||||
            <if test="createTime != null">create_time,</if>
 | 
			
		||||
            <if test="rmCom != null and rmCom != ''">rm_com,</if>
 | 
			
		||||
        </trim>
 | 
			
		||||
        <trim prefix="values (" suffix=")" suffixOverrides=",">
 | 
			
		||||
            <if test="maId != null">#{maId},</if>
 | 
			
		||||
| 
						 | 
				
			
			@ -26,6 +27,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 | 
			
		|||
            <if test="rmTime != null">#{rmTime},</if>
 | 
			
		||||
            <if test="createBy != null">#{createBy},</if>
 | 
			
		||||
            <if test="createTime != null">#{createTime},</if>
 | 
			
		||||
            <if test="rmCom != null and rmCom != ''">#{rmCom},</if>
 | 
			
		||||
        </trim>
 | 
			
		||||
    </insert>
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -73,6 +75,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 | 
			
		|||
            <if test="createStartTime != null and createStartTime != '' and createEndTime != null and createEndTime != ''">
 | 
			
		||||
                and DATE_FORMAT(m1.create_time,'%Y-%m-%d') between #{createStartTime} and #{createEndTime}
 | 
			
		||||
            </if>
 | 
			
		||||
            <if test="rmCom != null and rmCom != ''">
 | 
			
		||||
                and m1.rm_com = #{rmCom}
 | 
			
		||||
            </if>
 | 
			
		||||
        </where>
 | 
			
		||||
    </select>
 | 
			
		||||
    <select id="selectQcList" resultType="com.bonus.material.device.domain.MaDevRm">
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue