JSK 物资厂家权限改造

This commit is contained in:
jiask 2026-01-09 10:48:02 +08:00
parent 000de8eafc
commit a9983a15c6
2 changed files with 10 additions and 0 deletions

View File

@ -8,6 +8,7 @@ import com.bonus.common.core.utils.DateUtils;
import com.bonus.common.core.web.domain.AjaxResult;
import com.bonus.common.biz.domain.BmFileInfo;
import com.bonus.material.basic.mapper.BmFileInfoMapper;
import com.bonus.material.ma.service.ITypeService;
import com.bonus.system.api.RemoteFileService;
import org.springframework.stereotype.Service;
import com.bonus.material.ma.mapper.SupplierInfoMapper;
@ -35,6 +36,8 @@ public class SupplierInfoServiceImpl implements ISupplierInfoService {
@Resource
private BmFileInfoMapper bmFileInfoMapper;
@Resource
private ITypeService iTypeService;
/**
* 查询物资厂家管理
*
@ -60,6 +63,8 @@ public class SupplierInfoServiceImpl implements ISupplierInfoService {
*/
@Override
public List<SupplierInfo> selectSupplierInfoList(SupplierInfo supplierInfo) {
Long companyId=iTypeService.getUserDeptId();
supplierInfo.setCompanyId(companyId+"");
return supplierInfoMapper.selectSupplierInfoList(supplierInfo);
}
@ -73,6 +78,8 @@ public class SupplierInfoServiceImpl implements ISupplierInfoService {
public AjaxResult insertSupplierInfo(SupplierInfo supplierInfo) {
try {
supplierInfo.setCreateTime(DateUtils.getNowDate());
long companyId=iTypeService.getUserDeptId();
supplierInfo.setCompanyId(companyId+"");
int insertedSupplierInfoResult = supplierInfoMapper.insertSupplierInfo(supplierInfo);
if (insertedSupplierInfoResult > 0) {
if (CollectionUtils.isEmpty(supplierInfo.getBmFileInfos())) {

View File

@ -34,6 +34,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="supplier != null and supplier != ''">
and supplier like concat('%',#{supplier},'%')
</if>
<if test="companyId != null and companyId != ''">
and company_id=#{companyId}
</if>
<if test="keyWord != null and keyWord != ''">
and supplier like concat('%',#{keyWord},'%')
</if>