|
@@ -94,6 +94,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="filingUrl" column="filing_url" />
|
|
<result property="filingUrl" column="filing_url" />
|
|
|
<result property="permStatus" column="perm_status" />
|
|
<result property="permStatus" column="perm_status" />
|
|
|
<result property="hasErpInfo" column="has_erp_info" />
|
|
<result property="hasErpInfo" column="has_erp_info" />
|
|
|
|
|
+ <result property="pharmacyCode" column="pharmacy_code" />
|
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
|
|
<sql id="selectFsStoreVo">
|
|
<sql id="selectFsStoreVo">
|
|
@@ -113,7 +114,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
is_drug_license_permanent,is_medical_device2_expiry_permanent,is_medical_device3_expiry_permanent,is_food_license_expiry_permanent,is_medical_license_expiry_permanent,
|
|
is_drug_license_permanent,is_medical_device2_expiry_permanent,is_medical_device3_expiry_permanent,is_food_license_expiry_permanent,is_medical_license_expiry_permanent,
|
|
|
title_Name_one,title_Name_two,title_Name_three,settlement_agreement_file_name,quality_assurance_agreement_fileName,other_special_qualification_fileName,
|
|
title_Name_one,title_Name_two,title_Name_three,settlement_agreement_file_name,quality_assurance_agreement_fileName,other_special_qualification_fileName,
|
|
|
is_effective_permanent1,is_effective_permanent2,is_effective_permanent3,medical_device2_business_scope,medical_device3_business_scope,drug_license_business_scope
|
|
is_effective_permanent1,is_effective_permanent2,is_effective_permanent3,medical_device2_business_scope,medical_device3_business_scope,drug_license_business_scope
|
|
|
- ,food_license_business_scope,drug_scope_has_frozen,report_url,filing_url,perm_status,has_erp_info
|
|
|
|
|
|
|
+ ,food_license_business_scope,drug_scope_has_frozen,report_url,filing_url,perm_status,has_erp_info,pharmacy_code
|
|
|
from fs_store_scrm
|
|
from fs_store_scrm
|
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
|
@@ -130,6 +131,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="storeSeq != null and storeSeq != ''"> and store_seq like concat('%', #{storeSeq}, '%')</if>
|
|
<if test="storeSeq != null and storeSeq != ''"> and store_seq like concat('%', #{storeSeq}, '%')</if>
|
|
|
<if test="merchantId != null and merchantId != ''"> and merchant_id like concat('%', #{merchantId}, '%')</if>
|
|
<if test="merchantId != null and merchantId != ''"> and merchant_id like concat('%', #{merchantId}, '%')</if>
|
|
|
<if test="hasErpInfo != null"> and ifnull(has_erp_info, 0) = #{hasErpInfo}</if>
|
|
<if test="hasErpInfo != null"> and ifnull(has_erp_info, 0) = #{hasErpInfo}</if>
|
|
|
|
|
+ <if test="pharmacyCodeFilter != null">
|
|
|
|
|
+ <choose>
|
|
|
|
|
+ <when test="pharmacyCodeFilter == 1"> and pharmacy_code is not null and pharmacy_code != ''</when>
|
|
|
|
|
+ <when test="pharmacyCodeFilter == 0"> and (pharmacy_code is null or pharmacy_code = '')</when>
|
|
|
|
|
+ </choose>
|
|
|
|
|
+ </if>
|
|
|
</where>
|
|
</where>
|
|
|
order by store_id desc
|
|
order by store_id desc
|
|
|
</select>
|
|
</select>
|
|
@@ -242,6 +249,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="reportUrl !=null ">report_url, </if>
|
|
<if test="reportUrl !=null ">report_url, </if>
|
|
|
<if test="filingUrl !=null ">filing_url, </if>
|
|
<if test="filingUrl !=null ">filing_url, </if>
|
|
|
<if test="permStatus !=null ">report_url, </if>
|
|
<if test="permStatus !=null ">report_url, </if>
|
|
|
|
|
+ <if test="pharmacyCode !=null and pharmacyCode != ''">pharmacy_code,</if>
|
|
|
</trim>
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="cityIds != null">#{cityIds},</if>
|
|
<if test="cityIds != null">#{cityIds},</if>
|
|
@@ -344,6 +352,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="reportUrl !=null ">#{reportUrl}, </if>
|
|
<if test="reportUrl !=null ">#{reportUrl}, </if>
|
|
|
<if test="filingUrl !=null ">#{filingUrl}, </if>
|
|
<if test="filingUrl !=null ">#{filingUrl}, </if>
|
|
|
<if test="permStatus !=null ">#{permStatus}, </if>
|
|
<if test="permStatus !=null ">#{permStatus}, </if>
|
|
|
|
|
+ <if test="pharmacyCode !=null and pharmacyCode != ''">#{pharmacyCode},</if>
|
|
|
</trim>
|
|
</trim>
|
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
|
@@ -450,6 +459,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="filingUrl !=null ">filing_url = #{filingUrl}, </if>
|
|
<if test="filingUrl !=null ">filing_url = #{filingUrl}, </if>
|
|
|
<if test="permStatus !=null ">perm_status = #{permStatus}, </if>
|
|
<if test="permStatus !=null ">perm_status = #{permStatus}, </if>
|
|
|
<if test="hasErpInfo !=null ">has_erp_info = #{hasErpInfo}, </if>
|
|
<if test="hasErpInfo !=null ">has_erp_info = #{hasErpInfo}, </if>
|
|
|
|
|
+ <if test="pharmacyCode !=null and pharmacyCode != ''">pharmacy_code = #{pharmacyCode},</if>
|
|
|
<if test="medicalDevice2 !=null and medicalDevice2 != ''">medical_device2 = #{medicalDevice2} ,</if>
|
|
<if test="medicalDevice2 !=null and medicalDevice2 != ''">medical_device2 = #{medicalDevice2} ,</if>
|
|
|
<if test="medicalDevice2BusinessScope !=null and medicalDevice2BusinessScope != ''">medical_device2_business_scope = #{medicalDevice2BusinessScope} ,</if>
|
|
<if test="medicalDevice2BusinessScope !=null and medicalDevice2BusinessScope != ''">medical_device2_business_scope = #{medicalDevice2BusinessScope} ,</if>
|
|
|
<if test="medicalDevice2Code !=null and medicalDevice2Code != ''">medical_device2_code = #{medicalDevice2Code} ,</if>
|
|
<if test="medicalDevice2Code !=null and medicalDevice2Code != ''">medical_device2_code = #{medicalDevice2Code} ,</if>
|
|
@@ -464,6 +474,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="foodLicenseExpiryStart !=null">food_license_expiry_start = #{foodLicenseExpiryStart} ,</if>
|
|
<if test="foodLicenseExpiryStart !=null">food_license_expiry_start = #{foodLicenseExpiryStart} ,</if>
|
|
|
<if test="foodLicenseExpiryEnd !=null">food_license_expiry_end = #{foodLicenseExpiryEnd} ,</if>
|
|
<if test="foodLicenseExpiryEnd !=null">food_license_expiry_end = #{foodLicenseExpiryEnd} ,</if>
|
|
|
<if test="hasErpInfo !=null">has_erp_info = #{hasErpInfo} ,</if>
|
|
<if test="hasErpInfo !=null">has_erp_info = #{hasErpInfo} ,</if>
|
|
|
|
|
+ <if test="pharmacyCode !=null and pharmacyCode != ''">pharmacy_code = #{pharmacyCode} ,</if>
|
|
|
</trim>
|
|
</trim>
|
|
|
where store_id = #{storeId}
|
|
where store_id = #{storeId}
|
|
|
</update>
|
|
</update>
|
|
@@ -877,7 +888,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<select id="selecStorePageList" resultType="com.fs.hisStore.domain.FsStoreScrm">
|
|
<select id="selecStorePageList" resultType="com.fs.hisStore.domain.FsStoreScrm">
|
|
|
SELECT
|
|
SELECT
|
|
|
store_id,full_name,delivery_type,send_phone, brokerage_rate,refund_phone,refund_address,refund_consignee,
|
|
store_id,full_name,delivery_type,send_phone, brokerage_rate,refund_phone,refund_address,refund_consignee,
|
|
|
- city_ids, store_name, descs, brokerage_type,logo_url, address, lng, lat,
|
|
|
|
|
|
|
+ city_ids, store_name, descs, brokerage_type,logo_url, address, lng, lat,pharmacy_code,
|
|
|
CASE
|
|
CASE
|
|
|
WHEN phone IS NOT NULL AND phone != '' THEN CONCAT(LEFT(phone, 3), '****', RIGHT(phone, 4))
|
|
WHEN phone IS NOT NULL AND phone != '' THEN CONCAT(LEFT(phone, 3), '****', RIGHT(phone, 4))
|
|
|
ELSE phone
|
|
ELSE phone
|
|
@@ -909,6 +920,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="account != null and account != ''"> and account like concat('%', #{account}, '%')</if>
|
|
<if test="account != null and account != ''"> and account like concat('%', #{account}, '%')</if>
|
|
|
<if test="queryStoreId != null "> or store_id = #{queryStoreId}</if>
|
|
<if test="queryStoreId != null "> or store_id = #{queryStoreId}</if>
|
|
|
<if test="hasErpInfo != null "> and has_erp_info = #{hasErpInfo}</if>
|
|
<if test="hasErpInfo != null "> and has_erp_info = #{hasErpInfo}</if>
|
|
|
|
|
+ <if test="pharmacyCodeFilter != null ">
|
|
|
|
|
+ <if test="pharmacyCodeFilter == 1">
|
|
|
|
|
+ AND pharmacy_code IS NOT NULL
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test="pharmacyCodeFilter == 0">
|
|
|
|
|
+ AND pharmacy_code IS NULL
|
|
|
|
|
+ </if>
|
|
|
|
|
+ </if>
|
|
|
<if test="daysDiffMax != null">
|
|
<if test="daysDiffMax != null">
|
|
|
<!-- 判断剩余天数范围 -->
|
|
<!-- 判断剩余天数范围 -->
|
|
|
<if test="daysDiffMax == 0">
|
|
<if test="daysDiffMax == 0">
|
|
@@ -1090,4 +1109,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<update id="updatePassword">
|
|
<update id="updatePassword">
|
|
|
update fs_store_scrm set password = #{password} where store_id = #{storeId}
|
|
update fs_store_scrm set password = #{password} where store_id = #{storeId}
|
|
|
</update>
|
|
</update>
|
|
|
|
|
+
|
|
|
|
|
+ <update id="updatePharmacyCode">
|
|
|
|
|
+ update fs_store_scrm set pharmacy_code = #{pharmacyCode} where store_id = #{storeId}
|
|
|
|
|
+ </update>
|
|
|
</mapper>
|
|
</mapper>
|