修改数据
This commit is contained in:
@ -238,8 +238,8 @@
|
||||
as themeName
|
||||
FROM cosco_blacklist cb
|
||||
where cb.del_flag = 'normal'
|
||||
<if test="orgId!=null">
|
||||
and cb.org_id = #{orgId}
|
||||
<if test="vo.orgId!=null">
|
||||
and cb.org_id = #{vo.orgId}
|
||||
</if>
|
||||
order by cb.create_time desc
|
||||
</select>
|
||||
|
@ -956,10 +956,9 @@
|
||||
</update>
|
||||
<select id="selectNameAndCategoryName" parameterType="string"
|
||||
resultType="com.chinaunicom.zyhy.ebtp.supplier.coscosupplier.vo.BaseCategoryNameVo">
|
||||
select csb.id, csb.name, GROUP_CONCAT(DISTINCT cc.category_name SEPARATOR ', ') AS categoryName
|
||||
select csb.id, csb.name, GROUP_CONCAT(DISTINCT casc.category_id SEPARATOR ', ') AS categoryIds
|
||||
from cosco_supplier_base csb
|
||||
left join cosco_access_supplier_category casc on csb.id = casc.supplier_id and casc.del_flag = 'normal'
|
||||
left join cosco_category cc on cc.id = casc.category_id
|
||||
left join cosco_access_supplier_category casc on csb.id = casc.supplier_id and casc.del_flag = 'normal'
|
||||
where csb.id = #{id}
|
||||
group by csb.id
|
||||
</select>
|
||||
@ -981,14 +980,12 @@
|
||||
END AS unifiedCode,
|
||||
GROUP_CONCAT(caw.dept_id) as dept_id,
|
||||
max(caw.update_time) AS admissionTime,
|
||||
GROUP_CONCAT(DISTINCT cc.category_name SEPARATOR ', ') AS categoryName,
|
||||
GROUP_CONCAT(DISTINCT cc.id SEPARATOR ', ') AS categoryIds
|
||||
GROUP_CONCAT(DISTINCT casc.category_id SEPARATOR ', ') AS categoryIds
|
||||
from
|
||||
cosco_access_supplier_category as casc
|
||||
join cosco_supplier_base as csb on casc.supplier_id = csb.id -- 供应商已准入品类
|
||||
left join cosco_access_supplier as cas on cas.supplier_id = csb.id
|
||||
left join cosco_access_work as caw on caw.id = cas.access_work_id and caw.apply_type=1 and caw.approve_status=1
|
||||
left join cosco_category as cc on casc.category_id = cc.id
|
||||
-- 黑名单排除
|
||||
WHERE NOT EXISTS (
|
||||
SELECT 1
|
||||
@ -1017,7 +1014,7 @@
|
||||
and cas.org_id = #{vo.orgId}
|
||||
</if>
|
||||
<if test="vo.categoryId!=null and vo.categoryId!=''">
|
||||
and cc.categoryId like concat('%',#{vo.categoryId},'%')
|
||||
and casc.categoryId like concat('%',#{vo.categoryId},'%')
|
||||
</if>
|
||||
|
||||
<if test="vo.librarySupplierIdList!=null and vo.librarySupplierIdList.size>0">
|
||||
@ -1051,16 +1048,15 @@
|
||||
ELSE NULL
|
||||
END AS unifiedCode,
|
||||
'准入部门' AS deptName,
|
||||
category_info.categoryName AS categoryName,
|
||||
category_info.categoryIds AS categoryIds,
|
||||
work_time.createTime AS createTime,
|
||||
latest_review.review_result AS themeName,
|
||||
latest_review.update_time AS evaluateTime
|
||||
FROM
|
||||
cosco_supplier_base csb
|
||||
LEFT JOIN (
|
||||
SELECT casc.supplier_id, GROUP_CONCAT(cc.category_name SEPARATOR ', ') AS categoryName
|
||||
SELECT casc.supplier_id, GROUP_CONCAT(casc.category_id SEPARATOR ', ') AS categoryIds
|
||||
FROM cosco_access_supplier_category casc
|
||||
JOIN cosco_category cc ON cc.id = casc.category_id
|
||||
GROUP BY casc.supplier_id
|
||||
) AS category_info ON category_info.supplier_id = csb.id
|
||||
LEFT JOIN (
|
||||
|
Reference in New Issue
Block a user