共商
This commit is contained in:
@ -4,8 +4,10 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
|
import com.chinaunicom.mall.ebtp.common.base.entity.BaseResponse;
|
||||||
|
import com.chinaunicom.zyhy.ebtp.supplier.base.dto.CoscoSupplierBaseDTO;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.service.ICoscoSupplierBaseService;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.service.ICoscoSupplierBaseService;
|
||||||
|
import com.chinaunicom.zyhy.ebtp.supplier.base.vo.SupplierAccessedOfMyOrgVO;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import io.swagger.annotations.ApiParam;
|
import io.swagger.annotations.ApiParam;
|
||||||
@ -100,4 +102,11 @@ public class CoscoSupplierBaseController {
|
|||||||
|
|
||||||
return BaseResponse.success(coscoSupplierBaseService.page(page, queryWrapper));
|
return BaseResponse.success(coscoSupplierBaseService.page(page, queryWrapper));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation("查询ToAgency分页数据")
|
||||||
|
@PostMapping("/getToAgencyPage")
|
||||||
|
public BaseResponse<IPage<CoscoSupplierBaseDTO>> getProviderToAgencyPage(@RequestBody @Valid SupplierAccessedOfMyOrgVO coscoSupplierBase) {
|
||||||
|
|
||||||
|
return BaseResponse.success(coscoSupplierBaseService.getAccessedOfMyOrgPage(coscoSupplierBase));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -6,6 +6,7 @@ import com.chinaunicom.zyhy.ebtp.supplier.base.dto.CoscoSupplierBaseDTO;
|
|||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.vo.SupplierAccessedOfMyOrgVO;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.vo.SupplierAccessedOfMyOrgVO;
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 中远海运供应商基本信息Mapper接口
|
* 中远海运供应商基本信息Mapper接口
|
||||||
@ -14,6 +15,6 @@ import org.apache.ibatis.annotations.Mapper;
|
|||||||
*/
|
*/
|
||||||
@Mapper
|
@Mapper
|
||||||
public interface CoscoSupplierBaseMapper extends BaseMapper<CoscoSupplierBase> {
|
public interface CoscoSupplierBaseMapper extends BaseMapper<CoscoSupplierBase> {
|
||||||
IPage<CoscoSupplierBaseDTO> getAccessedOfMyOrgPage(IPage<CoscoSupplierBaseDTO> page, SupplierAccessedOfMyOrgVO coscoSupplierBase);
|
IPage<CoscoSupplierBaseDTO> getAccessedOfMyOrgPage(IPage<CoscoSupplierBaseDTO> page,@Param("coscoSupplierBase") SupplierAccessedOfMyOrgVO coscoSupplierBase);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -29,11 +29,16 @@ public class CoscoSupplierBaseDTO implements Serializable {
|
|||||||
@ApiModelProperty(value = "主键ID")
|
@ApiModelProperty(value = "主键ID")
|
||||||
private String id;
|
private String id;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 身份类型
|
* 企业名称
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty(value = "身份类型")
|
@ApiModelProperty(value = "企业名称")
|
||||||
private String type;
|
private String name;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 供应商分类 -- 字典code
|
* 供应商分类 -- 字典code
|
||||||
@ -48,236 +53,29 @@ public class CoscoSupplierBaseDTO implements Serializable {
|
|||||||
private String kindName;
|
private String kindName;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 营业执照附件
|
* 商品类型
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty(value = "营业执照附件")
|
private String goodsTypeName;
|
||||||
private String licenceAccessory;
|
|
||||||
|
|
||||||
/**
|
private String goodsTypeCode;
|
||||||
* 营业执照有效期
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "营业执照有效期")
|
|
||||||
private String licenceDate;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 企业名称
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "企业名称")
|
|
||||||
private String name;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 英文名称
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "英文名称")
|
|
||||||
private String engName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 统一社会信用代码
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "统一社会信用代码")
|
|
||||||
private String socialCreditCode;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 经营范围
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "经营范围")
|
|
||||||
private String range;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册地址
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "注册地址")
|
|
||||||
private String regAddress;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 办公地址
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "办公地址")
|
|
||||||
private String workAddress;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 母公司出资人信息
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "母公司出资人信息")
|
|
||||||
private String parentCompanyInvestor;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 企业法定代表人
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "企业法定代表人")
|
|
||||||
private String legalPerson;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 身份证
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "身份证")
|
|
||||||
private String idCard;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 企业性质
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "企业性质")
|
|
||||||
private String nature;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 注册资本
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "注册资本")
|
|
||||||
private BigDecimal capital;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商类型 -- 字典
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "供应商类型 -- 字典")
|
|
||||||
private String categoryTypeCode;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商类型 --字典名称
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "供应商类型 --字典名称")
|
|
||||||
private String categoryTypeName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 联系人姓名
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "联系人姓名")
|
|
||||||
private String contactsName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 联系人手机
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "联系人手机")
|
|
||||||
private String contactsPhone;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 联系人身份类别
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "联系人身份类别")
|
|
||||||
private String contactsType;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 联系人邮箱
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "联系人邮箱")
|
|
||||||
private String contactsEmail;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 固定电话
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "固定电话")
|
|
||||||
private String telephone;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 境外企业- 国家地区
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "境外企业- 国家地区")
|
|
||||||
private String nation;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 境外企业-增值税号VAT
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "境外企业-增值税号VAT")
|
|
||||||
private String vat;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 境外企业-境外纳税人ID号
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "境外企业-境外纳税人ID号")
|
|
||||||
private String taxpayerId;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 境外企业-币种
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "境外企业-币种")
|
|
||||||
private String currency;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商反商业贿赂承诺书
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "供应商反商业贿赂承诺书")
|
|
||||||
private String commitment;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 其他附件
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "其他附件")
|
|
||||||
private String accessory;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 姓名-- 个人
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "姓名-- 个人")
|
|
||||||
private String personName;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 联系电话-- 个人
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "联系电话-- 个人")
|
|
||||||
private String personPhone;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 开户行-- 个人
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "开户行-- 个人")
|
|
||||||
private String personBank;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 银行账号-- 个人
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "银行账号-- 个人")
|
|
||||||
private String personAccount;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 相关证照文件id
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "相关证照文件id")
|
|
||||||
private String licence;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 供应商状态 是否合格
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "供应商状态 是否合格")
|
|
||||||
private Integer status;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 审批状态
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "审批状态")
|
|
||||||
private Integer approveStatus;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 备注
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "备注")
|
|
||||||
private String remark;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 是否在黑名单
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "是否在黑名单")
|
|
||||||
private Integer inBlacklist;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 是否第一次登录
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "是否第一次登录")
|
|
||||||
private Integer firstLogin;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 是否是-退出供应商
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "是否是-退出供应商")
|
|
||||||
private Integer exit;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 是否是代理商
|
* 是否是代理商
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty(value = "是否是代理商")
|
@ApiModelProperty(value = "是否是代理商,状态(页面显示未合作与失效状态供应商)")
|
||||||
private Integer agent;
|
private Integer agent;
|
||||||
|
|
||||||
/**
|
|
||||||
* sap_code 约束付款编码
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "sap_code 约束付款编码")
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
private String sapCode;
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||||
|
private LocalDateTime accessTime;//准入时间
|
||||||
|
|
||||||
|
private String accessUser;//准入人
|
||||||
}
|
}
|
||||||
|
@ -1,7 +1,10 @@
|
|||||||
package com.chinaunicom.zyhy.ebtp.supplier.base.service;
|
package com.chinaunicom.zyhy.ebtp.supplier.base.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.chinaunicom.zyhy.ebtp.supplier.base.dto.CoscoSupplierBaseDTO;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
||||||
|
import com.chinaunicom.zyhy.ebtp.supplier.base.vo.SupplierAccessedOfMyOrgVO;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 中远海运供应商基本信息Service接口
|
* 中远海运供应商基本信息Service接口
|
||||||
@ -9,4 +12,6 @@ import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
|||||||
* @date 2024-01-29
|
* @date 2024-01-29
|
||||||
*/
|
*/
|
||||||
public interface ICoscoSupplierBaseService extends IService<CoscoSupplierBase> {
|
public interface ICoscoSupplierBaseService extends IService<CoscoSupplierBase> {
|
||||||
|
IPage<CoscoSupplierBaseDTO> getAccessedOfMyOrgPage(SupplierAccessedOfMyOrgVO coscoSupplierBase);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,11 +1,19 @@
|
|||||||
package com.chinaunicom.zyhy.ebtp.supplier.base.service.impl;
|
package com.chinaunicom.zyhy.ebtp.supplier.base.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.chinaunicom.mall.ebtp.common.base.entity.BaseCacheUser;
|
||||||
|
import com.chinaunicom.mall.ebtp.common.base.service.IBaseCacheUserService;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.dao.CoscoSupplierBaseMapper;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.dao.CoscoSupplierBaseMapper;
|
||||||
|
import com.chinaunicom.zyhy.ebtp.supplier.base.dto.CoscoSupplierBaseDTO;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.entity.CoscoSupplierBase;
|
||||||
import com.chinaunicom.zyhy.ebtp.supplier.base.service.ICoscoSupplierBaseService;
|
import com.chinaunicom.zyhy.ebtp.supplier.base.service.ICoscoSupplierBaseService;
|
||||||
|
import com.chinaunicom.zyhy.ebtp.supplier.base.vo.SupplierAccessedOfMyOrgVO;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 中远海运供应商基本信息Service实现类
|
* 中远海运供应商基本信息Service实现类
|
||||||
* @author Craft
|
* @author Craft
|
||||||
@ -13,4 +21,19 @@ import org.springframework.stereotype.Service;
|
|||||||
*/
|
*/
|
||||||
@Service
|
@Service
|
||||||
public class CoscoSupplierBaseServiceImpl extends ServiceImpl<CoscoSupplierBaseMapper, CoscoSupplierBase> implements ICoscoSupplierBaseService {
|
public class CoscoSupplierBaseServiceImpl extends ServiceImpl<CoscoSupplierBaseMapper, CoscoSupplierBase> implements ICoscoSupplierBaseService {
|
||||||
|
@Resource
|
||||||
|
private CoscoSupplierBaseMapper coscoSupplierBaseMapper;
|
||||||
|
@Resource
|
||||||
|
private IBaseCacheUserService cacheUserService;
|
||||||
|
@Override
|
||||||
|
public IPage<CoscoSupplierBaseDTO> getAccessedOfMyOrgPage( SupplierAccessedOfMyOrgVO coscoSupplierBase) {
|
||||||
|
|
||||||
|
IPage<CoscoSupplierBaseDTO> page= new Page<>(coscoSupplierBase.getPageNo(),coscoSupplierBase.getPageSize());
|
||||||
|
BaseCacheUser cacheUser = cacheUserService.getCacheUser();
|
||||||
|
if((cacheUser!=null)&&(cacheUser.getDeptId()!=null)){
|
||||||
|
coscoSupplierBase.setDeptId(cacheUser.getDeptId());
|
||||||
|
}
|
||||||
|
|
||||||
|
return coscoSupplierBaseMapper.getAccessedOfMyOrgPage(page,coscoSupplierBase);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -29,51 +29,33 @@ public class SupplierAccessedOfMyOrgVO extends BasePageRequest {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 供应商分类 -- 字典code
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "供应商分类 -- 字典code")
|
||||||
|
private String kindCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 供应商分类 -- 字典名称
|
||||||
|
*/
|
||||||
|
@ApiModelProperty(value = "供应商分类 -- 字典名称")
|
||||||
|
private String kindName;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 品类 -- 字典
|
* 商品类型
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty(value = "品类code")
|
private String goodsTypeName;
|
||||||
private String categoryTypeCode;
|
|
||||||
|
|
||||||
/**
|
private String goodsTypeCode;
|
||||||
* 品类名称
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "品类名称")
|
|
||||||
private String categoryTypeName;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
private String deptId="1";//准入部门
|
||||||
* 供应商状态 是否合格
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "供应商状态 是否合格")
|
|
||||||
private Integer status;
|
|
||||||
|
|
||||||
/**
|
private LocalDateTime accessTime;//准入时间
|
||||||
* 审批状态
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "审批状态")
|
|
||||||
private Integer approveStatus;
|
|
||||||
|
|
||||||
|
private LocalDateTime accessTimeEnd;
|
||||||
|
|
||||||
/**
|
|
||||||
* 是否是代理商
|
|
||||||
*/
|
|
||||||
@ApiModelProperty(value = "是否是代理商")
|
|
||||||
private Integer agent;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 境内/境外
|
|
||||||
*/
|
|
||||||
private String supplierType;
|
|
||||||
|
|
||||||
|
|
||||||
private String deptId;//准入部门
|
|
||||||
|
|
||||||
private LocalDateTime endTime;//准入时间
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -89,21 +89,61 @@
|
|||||||
from cosco_supplier_base
|
from cosco_supplier_base
|
||||||
where social_credit_code = #{socialCreditCode}
|
where social_credit_code = #{socialCreditCode}
|
||||||
</select>
|
</select>
|
||||||
|
<!-- 通用查询结果列 -->
|
||||||
|
<sql id="agency_to_select_List">
|
||||||
|
id, type, kind_code, kind_name, licence_accessory, licence_date, name, eng_name, social_credit_code,
|
||||||
|
range, reg_address, work_address, parent_company_investor, legal_person, id_card, nature, capital,
|
||||||
|
category_type_code, category_type_name, contacts_name, contacts_phone, contacts_type, contacts_email,
|
||||||
|
telephone, nation, vat, taxpayer_id, currency, commitment, accessory, person_name, person_phone,
|
||||||
|
person_bank, person_account, licence, status, approve_status, create_by, create_time, update_by,
|
||||||
|
update_time, remark, in_blacklist, first_login, exit, agent, sap_code
|
||||||
|
</sql>
|
||||||
|
|
||||||
<select id="getAccessedOfMyOrgPage"
|
<select id="getAccessedOfMyOrgPage"
|
||||||
resultType="com.chinaunicom.zyhy.ebtp.supplier.base.dto.CoscoSupplierBaseDTO">
|
resultType="com.chinaunicom.zyhy.ebtp.supplier.base.dto.CoscoSupplierBaseDTO">
|
||||||
select
|
|
||||||
<include refid="Base_Column_List"/>
|
SELECT
|
||||||
from cosco_supplier_base
|
base.id, base.name,base.agent,
|
||||||
where status = 1
|
base.kind_code, base.kind_name,
|
||||||
<if test="name != null and name != ''">
|
wk.end_time access_time,au.user_name access_user,(
|
||||||
AND name like concat('%', #{name}, '%')
|
SELECT GROUP_CONCAT(sca.access_category_name SEPARATOR ',') goods_type_name
|
||||||
|
FROM cosco_access_supplier_category sca
|
||||||
|
WHERE sca.access_suppler_id=base.id
|
||||||
|
) goods_type_name
|
||||||
|
FROM cosco_supplier_base base,cosco_access_supplier accs, cosco_access_work wk,cosco_access_user au
|
||||||
|
WHERE
|
||||||
|
base.id=accs.supplier_id AND accs.access_work_id=wk.id AND wk.id=au.access_id
|
||||||
|
AND base.agent!=1
|
||||||
|
AND base.status='1'
|
||||||
|
AND wk.dept_id=#{coscoSupplierBase.deptId}
|
||||||
|
<if test="coscoSupplierBase.name != null and coscoSupplierBase.name != ''">
|
||||||
|
AND base.name like concat('%', #{coscoSupplierBase.name}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="categoryTypeCode != null and categoryTypeCode != ''">
|
<if test="coscoSupplierBase.kindCode != null and coscoSupplierBase.kindCode != ''">
|
||||||
AND category_type_code = #{categoryTypeCode}
|
AND base.kind_code=#{coscoSupplierBase.kindCode}
|
||||||
</if>
|
</if>
|
||||||
<if test="agent != null">
|
<if test="coscoSupplierBase.accessTime!=null and oscoSupplierBase.accessTimeEnd!=null ">
|
||||||
AND agent = #{agent}
|
AND wk.end_time between #{coscoSupplierBase.accessTime} and #{coscoSupplierBase.accessTimeEnd}
|
||||||
</if>
|
</if>
|
||||||
|
<!-- <if test="coscoSupplierBase.goodsTypeCode != null and coscoSupplierBase.goodsTypeCode != ''">-->
|
||||||
|
<!-- AND (-->
|
||||||
|
<!-- SELECT COUNT(casc.id)-->
|
||||||
|
<!-- FROM cosco_access_supplier_category casc-->
|
||||||
|
<!-- WHERE casc.access_suppler_id=base.id AND casc.access_category_id=#{coscoSupplierBase.goodsTypeCode}-->
|
||||||
|
<!-- )>0-->
|
||||||
|
<!-- </if>-->
|
||||||
|
<if test="coscoSupplierBase.goodsTypeName != null and coscoSupplierBase.goodsTypeName != ''">
|
||||||
|
AND (
|
||||||
|
SELECT COUNT(casc.id)
|
||||||
|
FROM cosco_access_supplier_category casc
|
||||||
|
WHERE casc.access_suppler_id=base.id AND casc.access_category_name like concat('%', #{coscoSupplierBase.goodsTypeName}, '%')
|
||||||
|
)>0
|
||||||
|
</if>
|
||||||
|
|
||||||
|
ORDER BY base.create_time DESC
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
Reference in New Issue
Block a user