优化提示信息
This commit is contained in:
parent
534aab8468
commit
5284a4b753
|
|
@ -6,6 +6,7 @@ import com.nflg.product.bomnew.pojo.entity.MaterialMainEntity;
|
||||||
import com.nflg.product.bomnew.pojo.vo.BaseMaterialVO;
|
import com.nflg.product.bomnew.pojo.vo.BaseMaterialVO;
|
||||||
import com.nflg.product.bomnew.pojo.vo.MaterialMateVO;
|
import com.nflg.product.bomnew.pojo.vo.MaterialMateVO;
|
||||||
import com.nflg.product.bomnew.pojo.vo.RolePostVo;
|
import com.nflg.product.bomnew.pojo.vo.RolePostVo;
|
||||||
|
import com.nflg.product.bomnew.pojo.vo.UserInfoVO;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
@ -58,4 +59,5 @@ public interface MaterialMainMapper extends BaseMapper<MaterialMainEntity> {
|
||||||
*/
|
*/
|
||||||
List<RolePostVo> getRolePostByUserId(@Param("userRowId") Long userRowId);
|
List<RolePostVo> getRolePostByUserId(@Param("userRowId") Long userRowId);
|
||||||
|
|
||||||
|
UserInfoVO getUserInfoByUserCode(@Param("userCode")String userCode);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
package com.nflg.product.bomnew.pojo.vo;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author 曹鹏飞
|
||||||
|
* @date 2024-03-15 10:48:27
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@ApiModel(value = "com-nflg-product-material-pojo-vo-UserInfoVO")
|
||||||
|
public class UserInfoVO {
|
||||||
|
|
||||||
|
private String userCode;
|
||||||
|
private String realName;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,21 @@
|
||||||
|
package com.nflg.product.bomnew.service;
|
||||||
|
|
||||||
|
import com.nflg.product.bomnew.pojo.vo.UserInfoVO;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author 曹鹏飞
|
||||||
|
* @date 2024-03-15 10:55:09
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class UserInfoService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
MaterialMainService materialMainService;
|
||||||
|
|
||||||
|
public UserInfoVO getUserInfo(String userCode){
|
||||||
|
return materialMainService.getBaseMapper().getUserInfoByUserCode(userCode);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -11,12 +11,10 @@ import com.nflg.product.bomnew.constant.OriginalSourceEnum;
|
||||||
import com.nflg.product.bomnew.constant.OriginalStatusEnum;
|
import com.nflg.product.bomnew.constant.OriginalStatusEnum;
|
||||||
import com.nflg.product.bomnew.mapper.master.MaterialMainMapper;
|
import com.nflg.product.bomnew.mapper.master.MaterialMainMapper;
|
||||||
import com.nflg.product.bomnew.pojo.entity.*;
|
import com.nflg.product.bomnew.pojo.entity.*;
|
||||||
import com.nflg.product.bomnew.pojo.vo.BaseMaterialVO;
|
import com.nflg.product.bomnew.pojo.vo.*;
|
||||||
import com.nflg.product.bomnew.pojo.vo.BomOriginalPlmBomVO;
|
|
||||||
import com.nflg.product.bomnew.pojo.vo.ImportOriginalBomVO;
|
|
||||||
import com.nflg.product.bomnew.pojo.vo.MaterialMateVO;
|
|
||||||
import com.nflg.product.bomnew.service.BomOriginalCadChildService;
|
import com.nflg.product.bomnew.service.BomOriginalCadChildService;
|
||||||
import com.nflg.product.bomnew.service.MaterialMainService;
|
import com.nflg.product.bomnew.service.MaterialMainService;
|
||||||
|
import com.nflg.product.bomnew.service.UserInfoService;
|
||||||
import com.nflg.product.bomnew.util.VUtils;
|
import com.nflg.product.bomnew.util.VUtils;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
|
|
||||||
|
|
@ -136,7 +134,8 @@ public class PlmBomToOriginalConvert extends BaseConvert {
|
||||||
// VUtils.isTure(true).throwMessage("图号:"+parent.getChartNo()+"此数据已创建BOM,请删除BOM重新导入");
|
// VUtils.isTure(true).throwMessage("图号:"+parent.getChartNo()+"此数据已创建BOM,请删除BOM重新导入");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
importErrorResult.add(new ImportOriginalBomVO( parent.getChartNo(),"此数据已被其他用户创建,请联系其他人处理"));
|
UserInfoVO userInfo =SpringUtil.getBean(UserInfoService.class).getUserInfo(ebom.getCreatedBy());
|
||||||
|
importErrorResult.add(new ImportOriginalBomVO( parent.getChartNo(),"此数据已被"+userInfo.getRealName()+"("+userInfo.getUserCode()+")创建,请联系TA处理"));
|
||||||
// VUtils.isTure(true).throwMessage("图号:"+parent.getChartNo()+"此数据已被其他用户创建,请联系其他人处理");
|
// VUtils.isTure(true).throwMessage("图号:"+parent.getChartNo()+"此数据已被其他用户创建,请联系其他人处理");
|
||||||
}
|
}
|
||||||
} else { //ebom为正式状态
|
} else { //ebom为正式状态
|
||||||
|
|
|
||||||
|
|
@ -188,4 +188,13 @@
|
||||||
AND rp.role_row_id=ru.role_row_id
|
AND rp.role_row_id=ru.role_row_id
|
||||||
AND ru.user_row_id= #{userRowId}
|
AND ru.user_row_id= #{userRowId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="getUserInfoByUserCode" resultType="com.nflg.product.bomnew.pojo.vo.UserInfoVO">
|
||||||
|
SELECT
|
||||||
|
u.user_code as userCode, u.real_name as realName
|
||||||
|
FROM
|
||||||
|
t_authority_user u
|
||||||
|
WHERE
|
||||||
|
u.user_code= #{userCode}
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue