|
|
@@ -107,10 +107,18 @@
|
|
107
|
107
|
</select>
|
|
108
|
108
|
<select id="findById" resultType="Map" resultMap="BaseResultMap">
|
|
109
|
109
|
SELECT
|
|
110
|
|
- A.dwmc,A.id unitInfoId, A.dwdm,A.fddbr,A.dwlx,A.zcdz,A.cfs,A.ygs,A.DICT_LABEL,bgqa.*
|
|
|
110
|
+ A.dwmc,A.id unitInfoId, A.dwdm,A.fddbr,A.dwlx,A.zcdz,A.cfs,A.ygs,A.DICT_LABEL,bgqa.apply_status,bgqa.apply_type,
|
|
|
111
|
+ bse.certified_storekeeper_count ,bse.certified_inspector_count ,bse.warehouse_facility_situation ,
|
|
|
112
|
+ bse.full_time_staff_count ,bse.storage_expire_time ,bse.attachment attachment
|
|
111
|
113
|
FROM
|
|
112
|
114
|
province_all.biz_sqr_enterprise_apply bgqa
|
|
113
|
|
- left join(select bui.id,bui.dwmc,bui.dwdm,bui.fddbr,bui.dwlx,bui.zcdz,bui.cfs,bui.ygs,dict.DICT_LABEL from province_all.biz_unit_info bui left join province_all.dev_dict dict on bui.dwlx = dict.id where bui.id =#{unitInfoId,jdbcType=VARCHAR})A on bgqa.unit_info_id = A.id
|
|
|
115
|
+ left join province_all.biz_sqr_enterprise bse on bgqa.sqr_enterprise_id =bse.id
|
|
|
116
|
+ left join(select bui.id,bui.dwmc,bui.dwdm,bui.fddbr,bui.dwlx,bui.zcdz,bui.cfs,bui.ygs,dict.DICT_LABEL from province_all.biz_unit_info bui left join province_all.dev_dict dict on bui.dwlx = dict.id
|
|
|
117
|
+ <if test="unitInfoId != null and unitInfoId != ''">
|
|
|
118
|
+ where bui.id =#{unitInfoId,jdbcType=VARCHAR}
|
|
|
119
|
+ </if>
|
|
|
120
|
+
|
|
|
121
|
+ )A on bgqa.unit_info_id = A.id
|
|
114
|
122
|
where bgqa.id=#{id,jdbcType=INTEGER} and bgqa.apply_type=#{applyType,jdbcType=INTEGER}
|
|
115
|
123
|
|
|
116
|
124
|
</select>
|