TFumigationAfterMapper.xml 35 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
  3. <mapper namespace="com.chinaitop.depot.fumigation.mapper.TFumigationAfterMapper" >
  4. <resultMap id="BaseResultMap" type="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
  5. <id column="id" property="id" jdbcType="VARCHAR" />
  6. <result column="house_id" property="houseId" jdbcType="INTEGER" />
  7. <result column="fumigation_id" property="fumigationId" jdbcType="VARCHAR" />
  8. <result column="residue_collection_time" property="residueCollectionTime" jdbcType="VARCHAR" />
  9. <result column="number_operations_collected" property="numberOperationsCollected" jdbcType="VARCHAR" />
  10. <result column="residue_collection_method" property="residueCollectionMethod" jdbcType="VARCHAR" />
  11. <result column="collect_job_approver" property="collectJobApprover" jdbcType="VARCHAR" />
  12. <result column="residue_treatment_measures" property="residueTreatmentMeasures" jdbcType="VARCHAR" />
  13. <result column="number_residue_treatment" property="numberResidueTreatment" jdbcType="VARCHAR" />
  14. <result column="residue_disposal_approver" property="residueDisposalApprover" jdbcType="VARCHAR" />
  15. <result column="detection_live_worms" property="detectionLiveWorms" jdbcType="VARCHAR" />
  16. <result column="population_density" property="populationDensity" jdbcType="VARCHAR" />
  17. <result column="sampling_culture_temperature" property="samplingCultureTemperature" jdbcType="VARCHAR" />
  18. <result column="sampling_culture_humidity" property="samplingCultureHumidity" jdbcType="VARCHAR" />
  19. <result column="sampling_culture_half_months" property="samplingCultureHalfMonths" jdbcType="VARCHAR" />
  20. <result column="sampling_culture_month_survival" property="samplingCultureMonthSurvival" jdbcType="INTEGER" />
  21. <result column="sampling_culture_month_half" property="samplingCultureMonthHalf" jdbcType="VARCHAR" />
  22. <result column="kill_insect_rate" property="killInsectRate" jdbcType="VARCHAR" />
  23. <result column="check_insect_cage_time" property="checkInsectCageTime" jdbcType="TIMESTAMP" />
  24. <result column="insect_cage_kill_rate" property="insectCageKillRate" jdbcType="VARCHAR" />
  25. <result column="effect_analysis" property="effectAnalysis" jdbcType="VARCHAR" />
  26. <result column="creater" property="creater" jdbcType="INTEGER" />
  27. <result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
  28. <result column="update_time" property="updateTime" jdbcType="TIMESTAMP" />
  29. <result column="org_id" property="orgId" jdbcType="INTEGER" />
  30. <result column="delete_state" property="deleteState" jdbcType="VARCHAR" />
  31. <result column="updatetime" property="updatetime" jdbcType="TIMESTAMP" />
  32. <result column="czsjzysj" property="czsjzysj" jdbcType="TIMESTAMP" />
  33. <result column="czsjzyrs" property="czsjzyrs" jdbcType="INTEGER" />
  34. <result column="czsjff" property="czsjff" jdbcType="VARCHAR" />
  35. <result column="czsjzypzr" property="czsjzypzr" jdbcType="VARCHAR" />
  36. <result column="czclcs" property="czclcs" jdbcType="VARCHAR" />
  37. <result column="czclzyrs" property="czclzyrs" jdbcType="INTEGER" />
  38. <result column="czclpzr" property="czclpzr" jdbcType="VARCHAR" />
  39. <result column="xzhhcjcqk" property="xzhhcjcqk" jdbcType="VARCHAR" />
  40. <result column="xzhckmd" property="xzhckmd" jdbcType="INTEGER" />
  41. <result column="pyswthhcs" property="pyswthhcs" jdbcType="INTEGER" />
  42. <result column="pysswthhcs" property="pysswthhcs" jdbcType="INTEGER" />
  43. <result column="xzxgpj" property="xzxgpj" jdbcType="VARCHAR" />
  44. <result column="record_id" property="recordId" jdbcType="VARCHAR" />
  45. </resultMap>
  46. <sql id="Example_Where_Clause" >
  47. <where >
  48. <foreach collection="oredCriteria" item="criteria" separator="or" >
  49. <if test="criteria.valid" >
  50. <trim prefix="(" suffix=")" prefixOverrides="and" >
  51. <foreach collection="criteria.criteria" item="criterion" >
  52. <choose >
  53. <when test="criterion.noValue" >
  54. and ${criterion.condition}
  55. </when>
  56. <when test="criterion.singleValue" >
  57. and ${criterion.condition} #{criterion.value}
  58. </when>
  59. <when test="criterion.betweenValue" >
  60. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  61. </when>
  62. <when test="criterion.listValue" >
  63. and ${criterion.condition}
  64. <foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
  65. #{listItem}
  66. </foreach>
  67. </when>
  68. </choose>
  69. </foreach>
  70. </trim>
  71. </if>
  72. </foreach>
  73. </where>
  74. </sql>
  75. <sql id="Update_By_Example_Where_Clause" >
  76. <where >
  77. <foreach collection="example.oredCriteria" item="criteria" separator="or" >
  78. <if test="criteria.valid" >
  79. <trim prefix="(" suffix=")" prefixOverrides="and" >
  80. <foreach collection="criteria.criteria" item="criterion" >
  81. <choose >
  82. <when test="criterion.noValue" >
  83. and ${criterion.condition}
  84. </when>
  85. <when test="criterion.singleValue" >
  86. and ${criterion.condition} #{criterion.value}
  87. </when>
  88. <when test="criterion.betweenValue" >
  89. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  90. </when>
  91. <when test="criterion.listValue" >
  92. and ${criterion.condition}
  93. <foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
  94. #{listItem}
  95. </foreach>
  96. </when>
  97. </choose>
  98. </foreach>
  99. </trim>
  100. </if>
  101. </foreach>
  102. </where>
  103. </sql>
  104. <sql id="Base_Column_List" >
  105. id, house_id, fumigation_id, residue_collection_time, number_operations_collected,
  106. residue_collection_method, collect_job_approver, residue_treatment_measures, number_residue_treatment,
  107. residue_disposal_approver, detection_live_worms, population_density, sampling_culture_temperature,
  108. sampling_culture_humidity, sampling_culture_half_months, sampling_culture_month_survival,
  109. sampling_culture_month_half, kill_insect_rate, check_insect_cage_time, insect_cage_kill_rate,
  110. effect_analysis, creater, create_time, update_time, org_id, delete_state, updatetime,
  111. czsjzysj, czsjzyrs, czsjff, czsjzypzr, czclcs, czclzyrs, czclpzr, xzhhcjcqk, xzhckmd,
  112. pyswthhcs, pysswthhcs, xzxgpj,record_id
  113. </sql>
  114. <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" >
  115. select
  116. <if test="distinct" >
  117. distinct
  118. </if>
  119. <include refid="Base_Column_List" />
  120. from t_fumigation_after
  121. <if test="_parameter != null" >
  122. <include refid="Example_Where_Clause" />
  123. </if>
  124. <if test="orderByClause != null" >
  125. order by ${orderByClause}
  126. </if>
  127. </select>
  128. <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
  129. select
  130. <include refid="Base_Column_List" />
  131. from t_fumigation_after
  132. where id = #{id,jdbcType=VARCHAR}
  133. </select>
  134. <delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
  135. delete from t_fumigation_after
  136. where id = #{id,jdbcType=VARCHAR}
  137. </delete>
  138. <delete id="deleteByExample" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" >
  139. delete from t_fumigation_after
  140. <if test="_parameter != null" >
  141. <include refid="Example_Where_Clause" />
  142. </if>
  143. </delete>
  144. <insert id="insert" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
  145. insert into t_fumigation_after (id, house_id, fumigation_id,
  146. residue_collection_time, number_operations_collected,
  147. residue_collection_method, collect_job_approver,
  148. residue_treatment_measures, number_residue_treatment,
  149. residue_disposal_approver, detection_live_worms,
  150. population_density, sampling_culture_temperature,
  151. sampling_culture_humidity, sampling_culture_half_months,
  152. sampling_culture_month_survival, sampling_culture_month_half,
  153. kill_insect_rate, check_insect_cage_time,
  154. insect_cage_kill_rate, effect_analysis, creater,
  155. create_time, update_time, org_id,
  156. delete_state, updatetime, czsjzysj,
  157. czsjzyrs, czsjff, czsjzypzr,
  158. czclcs, czclzyrs, czclpzr,
  159. xzhhcjcqk, xzhckmd, pyswthhcs,
  160. pysswthhcs, xzxgpj,record_id)
  161. values (#{id,jdbcType=VARCHAR}, #{houseId,jdbcType=INTEGER}, #{fumigationId,jdbcType=VARCHAR},
  162. #{residueCollectionTime,jdbcType=VARCHAR}, #{numberOperationsCollected,jdbcType=VARCHAR},
  163. #{residueCollectionMethod,jdbcType=VARCHAR}, #{collectJobApprover,jdbcType=VARCHAR},
  164. #{residueTreatmentMeasures,jdbcType=VARCHAR}, #{numberResidueTreatment,jdbcType=VARCHAR},
  165. #{residueDisposalApprover,jdbcType=VARCHAR}, #{detectionLiveWorms,jdbcType=VARCHAR},
  166. #{populationDensity,jdbcType=VARCHAR}, #{samplingCultureTemperature,jdbcType=VARCHAR},
  167. #{samplingCultureHumidity,jdbcType=VARCHAR}, #{samplingCultureHalfMonths,jdbcType=VARCHAR},
  168. #{samplingCultureMonthSurvival,jdbcType=INTEGER}, #{samplingCultureMonthHalf,jdbcType=VARCHAR},
  169. #{killInsectRate,jdbcType=VARCHAR}, #{checkInsectCageTime,jdbcType=TIMESTAMP},
  170. #{insectCageKillRate,jdbcType=VARCHAR}, #{effectAnalysis,jdbcType=VARCHAR}, #{creater,jdbcType=INTEGER},
  171. #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{orgId,jdbcType=INTEGER},
  172. #{deleteState,jdbcType=VARCHAR}, #{updatetime,jdbcType=TIMESTAMP}, #{czsjzysj,jdbcType=TIMESTAMP},
  173. #{czsjzyrs,jdbcType=INTEGER}, #{czsjff,jdbcType=VARCHAR}, #{czsjzypzr,jdbcType=VARCHAR},
  174. #{czclcs,jdbcType=VARCHAR}, #{czclzyrs,jdbcType=INTEGER}, #{czclpzr,jdbcType=VARCHAR},
  175. #{xzhhcjcqk,jdbcType=VARCHAR}, #{xzhckmd,jdbcType=INTEGER}, #{pyswthhcs,jdbcType=INTEGER},
  176. #{pysswthhcs,jdbcType=INTEGER}, #{xzxgpj,jdbcType=VARCHAR},#{recordId,jdbcType=VARCHAR})
  177. </insert>
  178. <insert id="insertSelective" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
  179. insert into t_fumigation_after
  180. <trim prefix="(" suffix=")" suffixOverrides="," >
  181. <if test="id != null" >
  182. id,
  183. </if>
  184. <if test="houseId != null" >
  185. house_id,
  186. </if>
  187. <if test="fumigationId != null" >
  188. fumigation_id,
  189. </if>
  190. <if test="residueCollectionTime != null" >
  191. residue_collection_time,
  192. </if>
  193. <if test="numberOperationsCollected != null" >
  194. number_operations_collected,
  195. </if>
  196. <if test="residueCollectionMethod != null" >
  197. residue_collection_method,
  198. </if>
  199. <if test="collectJobApprover != null" >
  200. collect_job_approver,
  201. </if>
  202. <if test="residueTreatmentMeasures != null" >
  203. residue_treatment_measures,
  204. </if>
  205. <if test="numberResidueTreatment != null" >
  206. number_residue_treatment,
  207. </if>
  208. <if test="residueDisposalApprover != null" >
  209. residue_disposal_approver,
  210. </if>
  211. <if test="detectionLiveWorms != null" >
  212. detection_live_worms,
  213. </if>
  214. <if test="populationDensity != null" >
  215. population_density,
  216. </if>
  217. <if test="samplingCultureTemperature != null" >
  218. sampling_culture_temperature,
  219. </if>
  220. <if test="samplingCultureHumidity != null" >
  221. sampling_culture_humidity,
  222. </if>
  223. <if test="samplingCultureHalfMonths != null" >
  224. sampling_culture_half_months,
  225. </if>
  226. <if test="samplingCultureMonthSurvival != null" >
  227. sampling_culture_month_survival,
  228. </if>
  229. <if test="samplingCultureMonthHalf != null" >
  230. sampling_culture_month_half,
  231. </if>
  232. <if test="killInsectRate != null" >
  233. kill_insect_rate,
  234. </if>
  235. <if test="checkInsectCageTime != null" >
  236. check_insect_cage_time,
  237. </if>
  238. <if test="insectCageKillRate != null" >
  239. insect_cage_kill_rate,
  240. </if>
  241. <if test="effectAnalysis != null" >
  242. effect_analysis,
  243. </if>
  244. <if test="creater != null" >
  245. creater,
  246. </if>
  247. <if test="createTime != null" >
  248. create_time,
  249. </if>
  250. <if test="updateTime != null" >
  251. update_time,
  252. </if>
  253. <if test="orgId != null" >
  254. org_id,
  255. </if>
  256. <if test="deleteState != null" >
  257. delete_state,
  258. </if>
  259. <if test="updatetime != null" >
  260. updatetime,
  261. </if>
  262. <if test="czsjzysj != null" >
  263. czsjzysj,
  264. </if>
  265. <if test="czsjzyrs != null" >
  266. czsjzyrs,
  267. </if>
  268. <if test="czsjff != null" >
  269. czsjff,
  270. </if>
  271. <if test="czsjzypzr != null" >
  272. czsjzypzr,
  273. </if>
  274. <if test="czclcs != null" >
  275. czclcs,
  276. </if>
  277. <if test="czclzyrs != null" >
  278. czclzyrs,
  279. </if>
  280. <if test="czclpzr != null" >
  281. czclpzr,
  282. </if>
  283. <if test="xzhhcjcqk != null" >
  284. xzhhcjcqk,
  285. </if>
  286. <if test="xzhckmd != null" >
  287. xzhckmd,
  288. </if>
  289. <if test="pyswthhcs != null" >
  290. pyswthhcs,
  291. </if>
  292. <if test="pysswthhcs != null" >
  293. pysswthhcs,
  294. </if>
  295. <if test="xzxgpj != null" >
  296. xzxgpj,
  297. </if>
  298. </trim>
  299. <trim prefix="values (" suffix=")" suffixOverrides="," >
  300. <if test="id != null" >
  301. #{id,jdbcType=VARCHAR},
  302. </if>
  303. <if test="houseId != null" >
  304. #{houseId,jdbcType=INTEGER},
  305. </if>
  306. <if test="fumigationId != null" >
  307. #{fumigationId,jdbcType=VARCHAR},
  308. </if>
  309. <if test="residueCollectionTime != null" >
  310. #{residueCollectionTime,jdbcType=VARCHAR},
  311. </if>
  312. <if test="numberOperationsCollected != null" >
  313. #{numberOperationsCollected,jdbcType=VARCHAR},
  314. </if>
  315. <if test="residueCollectionMethod != null" >
  316. #{residueCollectionMethod,jdbcType=VARCHAR},
  317. </if>
  318. <if test="collectJobApprover != null" >
  319. #{collectJobApprover,jdbcType=VARCHAR},
  320. </if>
  321. <if test="residueTreatmentMeasures != null" >
  322. #{residueTreatmentMeasures,jdbcType=VARCHAR},
  323. </if>
  324. <if test="numberResidueTreatment != null" >
  325. #{numberResidueTreatment,jdbcType=VARCHAR},
  326. </if>
  327. <if test="residueDisposalApprover != null" >
  328. #{residueDisposalApprover,jdbcType=VARCHAR},
  329. </if>
  330. <if test="detectionLiveWorms != null" >
  331. #{detectionLiveWorms,jdbcType=VARCHAR},
  332. </if>
  333. <if test="populationDensity != null" >
  334. #{populationDensity,jdbcType=VARCHAR},
  335. </if>
  336. <if test="samplingCultureTemperature != null" >
  337. #{samplingCultureTemperature,jdbcType=VARCHAR},
  338. </if>
  339. <if test="samplingCultureHumidity != null" >
  340. #{samplingCultureHumidity,jdbcType=VARCHAR},
  341. </if>
  342. <if test="samplingCultureHalfMonths != null" >
  343. #{samplingCultureHalfMonths,jdbcType=VARCHAR},
  344. </if>
  345. <if test="samplingCultureMonthSurvival != null" >
  346. #{samplingCultureMonthSurvival,jdbcType=INTEGER},
  347. </if>
  348. <if test="samplingCultureMonthHalf != null" >
  349. #{samplingCultureMonthHalf,jdbcType=VARCHAR},
  350. </if>
  351. <if test="killInsectRate != null" >
  352. #{killInsectRate,jdbcType=VARCHAR},
  353. </if>
  354. <if test="checkInsectCageTime != null" >
  355. #{checkInsectCageTime,jdbcType=TIMESTAMP},
  356. </if>
  357. <if test="insectCageKillRate != null" >
  358. #{insectCageKillRate,jdbcType=VARCHAR},
  359. </if>
  360. <if test="effectAnalysis != null" >
  361. #{effectAnalysis,jdbcType=VARCHAR},
  362. </if>
  363. <if test="creater != null" >
  364. #{creater,jdbcType=INTEGER},
  365. </if>
  366. <if test="createTime != null" >
  367. #{createTime,jdbcType=TIMESTAMP},
  368. </if>
  369. <if test="updateTime != null" >
  370. #{updateTime,jdbcType=TIMESTAMP},
  371. </if>
  372. <if test="orgId != null" >
  373. #{orgId,jdbcType=INTEGER},
  374. </if>
  375. <if test="deleteState != null" >
  376. #{deleteState,jdbcType=VARCHAR},
  377. </if>
  378. <if test="updatetime != null" >
  379. #{updatetime,jdbcType=TIMESTAMP},
  380. </if>
  381. <if test="czsjzysj != null" >
  382. #{czsjzysj,jdbcType=TIMESTAMP},
  383. </if>
  384. <if test="czsjzyrs != null" >
  385. #{czsjzyrs,jdbcType=INTEGER},
  386. </if>
  387. <if test="czsjff != null" >
  388. #{czsjff,jdbcType=VARCHAR},
  389. </if>
  390. <if test="czsjzypzr != null" >
  391. #{czsjzypzr,jdbcType=VARCHAR},
  392. </if>
  393. <if test="czclcs != null" >
  394. #{czclcs,jdbcType=VARCHAR},
  395. </if>
  396. <if test="czclzyrs != null" >
  397. #{czclzyrs,jdbcType=INTEGER},
  398. </if>
  399. <if test="czclpzr != null" >
  400. #{czclpzr,jdbcType=VARCHAR},
  401. </if>
  402. <if test="xzhhcjcqk != null" >
  403. #{xzhhcjcqk,jdbcType=VARCHAR},
  404. </if>
  405. <if test="xzhckmd != null" >
  406. #{xzhckmd,jdbcType=INTEGER},
  407. </if>
  408. <if test="pyswthhcs != null" >
  409. #{pyswthhcs,jdbcType=INTEGER},
  410. </if>
  411. <if test="pysswthhcs != null" >
  412. #{pysswthhcs,jdbcType=INTEGER},
  413. </if>
  414. <if test="xzxgpj != null" >
  415. #{xzxgpj,jdbcType=VARCHAR},
  416. </if>
  417. </trim>
  418. </insert>
  419. <select id="countByExample" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfterExample" resultType="java.lang.Integer" >
  420. select count(*) from t_fumigation_after
  421. <if test="_parameter != null" >
  422. <include refid="Example_Where_Clause" />
  423. </if>
  424. </select>
  425. <update id="updateByExampleSelective" parameterType="map" >
  426. update t_fumigation_after
  427. <set >
  428. <if test="record.id != null" >
  429. id = #{record.id,jdbcType=VARCHAR},
  430. </if>
  431. <if test="record.houseId != null" >
  432. house_id = #{record.houseId,jdbcType=INTEGER},
  433. </if>
  434. <if test="record.fumigationId != null" >
  435. fumigation_id = #{record.fumigationId,jdbcType=VARCHAR},
  436. </if>
  437. <if test="record.residueCollectionTime != null" >
  438. residue_collection_time = #{record.residueCollectionTime,jdbcType=VARCHAR},
  439. </if>
  440. <if test="record.numberOperationsCollected != null" >
  441. number_operations_collected = #{record.numberOperationsCollected,jdbcType=VARCHAR},
  442. </if>
  443. <if test="record.residueCollectionMethod != null" >
  444. residue_collection_method = #{record.residueCollectionMethod,jdbcType=VARCHAR},
  445. </if>
  446. <if test="record.collectJobApprover != null" >
  447. collect_job_approver = #{record.collectJobApprover,jdbcType=VARCHAR},
  448. </if>
  449. <if test="record.residueTreatmentMeasures != null" >
  450. residue_treatment_measures = #{record.residueTreatmentMeasures,jdbcType=VARCHAR},
  451. </if>
  452. <if test="record.numberResidueTreatment != null" >
  453. number_residue_treatment = #{record.numberResidueTreatment,jdbcType=VARCHAR},
  454. </if>
  455. <if test="record.residueDisposalApprover != null" >
  456. residue_disposal_approver = #{record.residueDisposalApprover,jdbcType=VARCHAR},
  457. </if>
  458. <if test="record.detectionLiveWorms != null" >
  459. detection_live_worms = #{record.detectionLiveWorms,jdbcType=VARCHAR},
  460. </if>
  461. <if test="record.populationDensity != null" >
  462. population_density = #{record.populationDensity,jdbcType=VARCHAR},
  463. </if>
  464. <if test="record.samplingCultureTemperature != null" >
  465. sampling_culture_temperature = #{record.samplingCultureTemperature,jdbcType=VARCHAR},
  466. </if>
  467. <if test="record.samplingCultureHumidity != null" >
  468. sampling_culture_humidity = #{record.samplingCultureHumidity,jdbcType=VARCHAR},
  469. </if>
  470. <if test="record.samplingCultureHalfMonths != null" >
  471. sampling_culture_half_months = #{record.samplingCultureHalfMonths,jdbcType=VARCHAR},
  472. </if>
  473. <if test="record.samplingCultureMonthSurvival != null" >
  474. sampling_culture_month_survival = #{record.samplingCultureMonthSurvival,jdbcType=INTEGER},
  475. </if>
  476. <if test="record.samplingCultureMonthHalf != null" >
  477. sampling_culture_month_half = #{record.samplingCultureMonthHalf,jdbcType=VARCHAR},
  478. </if>
  479. <if test="record.killInsectRate != null" >
  480. kill_insect_rate = #{record.killInsectRate,jdbcType=VARCHAR},
  481. </if>
  482. <if test="record.checkInsectCageTime != null" >
  483. check_insect_cage_time = #{record.checkInsectCageTime,jdbcType=TIMESTAMP},
  484. </if>
  485. <if test="record.insectCageKillRate != null" >
  486. insect_cage_kill_rate = #{record.insectCageKillRate,jdbcType=VARCHAR},
  487. </if>
  488. <if test="record.effectAnalysis != null" >
  489. effect_analysis = #{record.effectAnalysis,jdbcType=VARCHAR},
  490. </if>
  491. <if test="record.creater != null" >
  492. creater = #{record.creater,jdbcType=INTEGER},
  493. </if>
  494. <if test="record.createTime != null" >
  495. create_time = #{record.createTime,jdbcType=TIMESTAMP},
  496. </if>
  497. <if test="record.updateTime != null" >
  498. update_time = #{record.updateTime,jdbcType=TIMESTAMP},
  499. </if>
  500. <if test="record.orgId != null" >
  501. org_id = #{record.orgId,jdbcType=INTEGER},
  502. </if>
  503. <if test="record.deleteState != null" >
  504. delete_state = #{record.deleteState,jdbcType=VARCHAR},
  505. </if>
  506. <if test="record.updatetime != null" >
  507. updatetime = #{record.updatetime,jdbcType=TIMESTAMP},
  508. </if>
  509. <if test="record.czsjzysj != null" >
  510. czsjzysj = #{record.czsjzysj,jdbcType=TIMESTAMP},
  511. </if>
  512. <if test="record.czsjzyrs != null" >
  513. czsjzyrs = #{record.czsjzyrs,jdbcType=INTEGER},
  514. </if>
  515. <if test="record.czsjff != null" >
  516. czsjff = #{record.czsjff,jdbcType=VARCHAR},
  517. </if>
  518. <if test="record.czsjzypzr != null" >
  519. czsjzypzr = #{record.czsjzypzr,jdbcType=VARCHAR},
  520. </if>
  521. <if test="record.czclcs != null" >
  522. czclcs = #{record.czclcs,jdbcType=VARCHAR},
  523. </if>
  524. <if test="record.czclzyrs != null" >
  525. czclzyrs = #{record.czclzyrs,jdbcType=INTEGER},
  526. </if>
  527. <if test="record.czclpzr != null" >
  528. czclpzr = #{record.czclpzr,jdbcType=VARCHAR},
  529. </if>
  530. <if test="record.xzhhcjcqk != null" >
  531. xzhhcjcqk = #{record.xzhhcjcqk,jdbcType=VARCHAR},
  532. </if>
  533. <if test="record.xzhckmd != null" >
  534. xzhckmd = #{record.xzhckmd,jdbcType=INTEGER},
  535. </if>
  536. <if test="record.pyswthhcs != null" >
  537. pyswthhcs = #{record.pyswthhcs,jdbcType=INTEGER},
  538. </if>
  539. <if test="record.pysswthhcs != null" >
  540. pysswthhcs = #{record.pysswthhcs,jdbcType=INTEGER},
  541. </if>
  542. <if test="record.xzxgpj != null" >
  543. xzxgpj = #{record.xzxgpj,jdbcType=VARCHAR},
  544. </if>
  545. </set>
  546. <if test="_parameter != null" >
  547. <include refid="Update_By_Example_Where_Clause" />
  548. </if>
  549. </update>
  550. <update id="updateByExample" parameterType="map" >
  551. update t_fumigation_after
  552. set id = #{record.id,jdbcType=VARCHAR},
  553. house_id = #{record.houseId,jdbcType=INTEGER},
  554. fumigation_id = #{record.fumigationId,jdbcType=VARCHAR},
  555. residue_collection_time = #{record.residueCollectionTime,jdbcType=VARCHAR},
  556. number_operations_collected = #{record.numberOperationsCollected,jdbcType=VARCHAR},
  557. residue_collection_method = #{record.residueCollectionMethod,jdbcType=VARCHAR},
  558. collect_job_approver = #{record.collectJobApprover,jdbcType=VARCHAR},
  559. residue_treatment_measures = #{record.residueTreatmentMeasures,jdbcType=VARCHAR},
  560. number_residue_treatment = #{record.numberResidueTreatment,jdbcType=VARCHAR},
  561. residue_disposal_approver = #{record.residueDisposalApprover,jdbcType=VARCHAR},
  562. detection_live_worms = #{record.detectionLiveWorms,jdbcType=VARCHAR},
  563. population_density = #{record.populationDensity,jdbcType=VARCHAR},
  564. sampling_culture_temperature = #{record.samplingCultureTemperature,jdbcType=VARCHAR},
  565. sampling_culture_humidity = #{record.samplingCultureHumidity,jdbcType=VARCHAR},
  566. sampling_culture_half_months = #{record.samplingCultureHalfMonths,jdbcType=VARCHAR},
  567. sampling_culture_month_survival = #{record.samplingCultureMonthSurvival,jdbcType=INTEGER},
  568. sampling_culture_month_half = #{record.samplingCultureMonthHalf,jdbcType=VARCHAR},
  569. kill_insect_rate = #{record.killInsectRate,jdbcType=VARCHAR},
  570. check_insect_cage_time = #{record.checkInsectCageTime,jdbcType=TIMESTAMP},
  571. insect_cage_kill_rate = #{record.insectCageKillRate,jdbcType=VARCHAR},
  572. effect_analysis = #{record.effectAnalysis,jdbcType=VARCHAR},
  573. creater = #{record.creater,jdbcType=INTEGER},
  574. create_time = #{record.createTime,jdbcType=TIMESTAMP},
  575. update_time = #{record.updateTime,jdbcType=TIMESTAMP},
  576. org_id = #{record.orgId,jdbcType=INTEGER},
  577. delete_state = #{record.deleteState,jdbcType=VARCHAR},
  578. updatetime = #{record.updatetime,jdbcType=TIMESTAMP},
  579. czsjzysj = #{record.czsjzysj,jdbcType=TIMESTAMP},
  580. czsjzyrs = #{record.czsjzyrs,jdbcType=INTEGER},
  581. czsjff = #{record.czsjff,jdbcType=VARCHAR},
  582. czsjzypzr = #{record.czsjzypzr,jdbcType=VARCHAR},
  583. czclcs = #{record.czclcs,jdbcType=VARCHAR},
  584. czclzyrs = #{record.czclzyrs,jdbcType=INTEGER},
  585. czclpzr = #{record.czclpzr,jdbcType=VARCHAR},
  586. xzhhcjcqk = #{record.xzhhcjcqk,jdbcType=VARCHAR},
  587. xzhckmd = #{record.xzhckmd,jdbcType=INTEGER},
  588. pyswthhcs = #{record.pyswthhcs,jdbcType=INTEGER},
  589. pysswthhcs = #{record.pysswthhcs,jdbcType=INTEGER},
  590. xzxgpj = #{record.xzxgpj,jdbcType=VARCHAR}
  591. <if test="_parameter != null" >
  592. <include refid="Update_By_Example_Where_Clause" />
  593. </if>
  594. </update>
  595. <update id="updateByPrimaryKeySelective" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
  596. update t_fumigation_after
  597. <set >
  598. <if test="houseId != null" >
  599. house_id = #{houseId,jdbcType=INTEGER},
  600. </if>
  601. <if test="fumigationId != null" >
  602. fumigation_id = #{fumigationId,jdbcType=VARCHAR},
  603. </if>
  604. <if test="residueCollectionTime != null" >
  605. residue_collection_time = #{residueCollectionTime,jdbcType=VARCHAR},
  606. </if>
  607. <if test="numberOperationsCollected != null" >
  608. number_operations_collected = #{numberOperationsCollected,jdbcType=VARCHAR},
  609. </if>
  610. <if test="residueCollectionMethod != null" >
  611. residue_collection_method = #{residueCollectionMethod,jdbcType=VARCHAR},
  612. </if>
  613. <if test="collectJobApprover != null" >
  614. collect_job_approver = #{collectJobApprover,jdbcType=VARCHAR},
  615. </if>
  616. <if test="residueTreatmentMeasures != null" >
  617. residue_treatment_measures = #{residueTreatmentMeasures,jdbcType=VARCHAR},
  618. </if>
  619. <if test="numberResidueTreatment != null" >
  620. number_residue_treatment = #{numberResidueTreatment,jdbcType=VARCHAR},
  621. </if>
  622. <if test="residueDisposalApprover != null" >
  623. residue_disposal_approver = #{residueDisposalApprover,jdbcType=VARCHAR},
  624. </if>
  625. <if test="detectionLiveWorms != null" >
  626. detection_live_worms = #{detectionLiveWorms,jdbcType=VARCHAR},
  627. </if>
  628. <if test="populationDensity != null" >
  629. population_density = #{populationDensity,jdbcType=VARCHAR},
  630. </if>
  631. <if test="samplingCultureTemperature != null" >
  632. sampling_culture_temperature = #{samplingCultureTemperature,jdbcType=VARCHAR},
  633. </if>
  634. <if test="samplingCultureHumidity != null" >
  635. sampling_culture_humidity = #{samplingCultureHumidity,jdbcType=VARCHAR},
  636. </if>
  637. <if test="samplingCultureHalfMonths != null" >
  638. sampling_culture_half_months = #{samplingCultureHalfMonths,jdbcType=VARCHAR},
  639. </if>
  640. <if test="samplingCultureMonthSurvival != null" >
  641. sampling_culture_month_survival = #{samplingCultureMonthSurvival,jdbcType=INTEGER},
  642. </if>
  643. <if test="samplingCultureMonthHalf != null" >
  644. sampling_culture_month_half = #{samplingCultureMonthHalf,jdbcType=VARCHAR},
  645. </if>
  646. <if test="killInsectRate != null" >
  647. kill_insect_rate = #{killInsectRate,jdbcType=VARCHAR},
  648. </if>
  649. <if test="checkInsectCageTime != null" >
  650. check_insect_cage_time = #{checkInsectCageTime,jdbcType=TIMESTAMP},
  651. </if>
  652. <if test="insectCageKillRate != null" >
  653. insect_cage_kill_rate = #{insectCageKillRate,jdbcType=VARCHAR},
  654. </if>
  655. <if test="effectAnalysis != null" >
  656. effect_analysis = #{effectAnalysis,jdbcType=VARCHAR},
  657. </if>
  658. <if test="creater != null" >
  659. creater = #{creater,jdbcType=INTEGER},
  660. </if>
  661. <if test="createTime != null" >
  662. create_time = #{createTime,jdbcType=TIMESTAMP},
  663. </if>
  664. <if test="updateTime != null" >
  665. update_time = #{updateTime,jdbcType=TIMESTAMP},
  666. </if>
  667. <if test="orgId != null" >
  668. org_id = #{orgId,jdbcType=INTEGER},
  669. </if>
  670. <if test="deleteState != null" >
  671. delete_state = #{deleteState,jdbcType=VARCHAR},
  672. </if>
  673. <if test="updatetime != null" >
  674. updatetime = #{updatetime,jdbcType=TIMESTAMP},
  675. </if>
  676. <if test="czsjzysj != null" >
  677. czsjzysj = #{czsjzysj,jdbcType=TIMESTAMP},
  678. </if>
  679. <if test="czsjzyrs != null" >
  680. czsjzyrs = #{czsjzyrs,jdbcType=INTEGER},
  681. </if>
  682. <if test="czsjff != null" >
  683. czsjff = #{czsjff,jdbcType=VARCHAR},
  684. </if>
  685. <if test="czsjzypzr != null" >
  686. czsjzypzr = #{czsjzypzr,jdbcType=VARCHAR},
  687. </if>
  688. <if test="czclcs != null" >
  689. czclcs = #{czclcs,jdbcType=VARCHAR},
  690. </if>
  691. <if test="czclzyrs != null" >
  692. czclzyrs = #{czclzyrs,jdbcType=INTEGER},
  693. </if>
  694. <if test="czclpzr != null" >
  695. czclpzr = #{czclpzr,jdbcType=VARCHAR},
  696. </if>
  697. <if test="xzhhcjcqk != null" >
  698. xzhhcjcqk = #{xzhhcjcqk,jdbcType=VARCHAR},
  699. </if>
  700. <if test="xzhckmd != null" >
  701. xzhckmd = #{xzhckmd,jdbcType=INTEGER},
  702. </if>
  703. <if test="pyswthhcs != null" >
  704. pyswthhcs = #{pyswthhcs,jdbcType=INTEGER},
  705. </if>
  706. <if test="pysswthhcs != null" >
  707. pysswthhcs = #{pysswthhcs,jdbcType=INTEGER},
  708. </if>
  709. <if test="xzxgpj != null" >
  710. xzxgpj = #{xzxgpj,jdbcType=VARCHAR},
  711. </if>
  712. </set>
  713. where id = #{id,jdbcType=VARCHAR}
  714. </update>
  715. <update id="updateByPrimaryKey" parameterType="com.chinaitop.depot.fumigation.model.TFumigationAfter" >
  716. update t_fumigation_after
  717. set house_id = #{houseId,jdbcType=INTEGER},
  718. fumigation_id = #{fumigationId,jdbcType=VARCHAR},
  719. residue_collection_time = #{residueCollectionTime,jdbcType=VARCHAR},
  720. number_operations_collected = #{numberOperationsCollected,jdbcType=VARCHAR},
  721. residue_collection_method = #{residueCollectionMethod,jdbcType=VARCHAR},
  722. collect_job_approver = #{collectJobApprover,jdbcType=VARCHAR},
  723. residue_treatment_measures = #{residueTreatmentMeasures,jdbcType=VARCHAR},
  724. number_residue_treatment = #{numberResidueTreatment,jdbcType=VARCHAR},
  725. residue_disposal_approver = #{residueDisposalApprover,jdbcType=VARCHAR},
  726. detection_live_worms = #{detectionLiveWorms,jdbcType=VARCHAR},
  727. population_density = #{populationDensity,jdbcType=VARCHAR},
  728. sampling_culture_temperature = #{samplingCultureTemperature,jdbcType=VARCHAR},
  729. sampling_culture_humidity = #{samplingCultureHumidity,jdbcType=VARCHAR},
  730. sampling_culture_half_months = #{samplingCultureHalfMonths,jdbcType=VARCHAR},
  731. sampling_culture_month_survival = #{samplingCultureMonthSurvival,jdbcType=INTEGER},
  732. sampling_culture_month_half = #{samplingCultureMonthHalf,jdbcType=VARCHAR},
  733. kill_insect_rate = #{killInsectRate,jdbcType=VARCHAR},
  734. check_insect_cage_time = #{checkInsectCageTime,jdbcType=TIMESTAMP},
  735. insect_cage_kill_rate = #{insectCageKillRate,jdbcType=VARCHAR},
  736. effect_analysis = #{effectAnalysis,jdbcType=VARCHAR},
  737. creater = #{creater,jdbcType=INTEGER},
  738. create_time = #{createTime,jdbcType=TIMESTAMP},
  739. update_time = #{updateTime,jdbcType=TIMESTAMP},
  740. org_id = #{orgId,jdbcType=INTEGER},
  741. delete_state = #{deleteState,jdbcType=VARCHAR},
  742. updatetime = #{updatetime,jdbcType=TIMESTAMP},
  743. czsjzysj = #{czsjzysj,jdbcType=TIMESTAMP},
  744. czsjzyrs = #{czsjzyrs,jdbcType=INTEGER},
  745. czsjff = #{czsjff,jdbcType=VARCHAR},
  746. czsjzypzr = #{czsjzypzr,jdbcType=VARCHAR},
  747. czclcs = #{czclcs,jdbcType=VARCHAR},
  748. czclzyrs = #{czclzyrs,jdbcType=INTEGER},
  749. czclpzr = #{czclpzr,jdbcType=VARCHAR},
  750. xzhhcjcqk = #{xzhhcjcqk,jdbcType=VARCHAR},
  751. xzhckmd = #{xzhckmd,jdbcType=INTEGER},
  752. pyswthhcs = #{pyswthhcs,jdbcType=INTEGER},
  753. pysswthhcs = #{pysswthhcs,jdbcType=INTEGER},
  754. xzxgpj = #{xzxgpj,jdbcType=VARCHAR}
  755. where id = #{id,jdbcType=VARCHAR}
  756. </update>
  757. <select id="getFumigationAfterList" parameterType="java.util.Map" resultType="java.util.HashMap">
  758. SELECT
  759. af.id,
  760. record.xzzydh fumigationId,
  761. record.house_id houseId,
  762. record.xzfs fumigationType,
  763. record.yjmc drugName,
  764. af.creater,
  765. af.create_time createTime,
  766. record.id recordId
  767. FROM
  768. t_fumigation_after af
  769. INNER JOIN t_fumigation_forrecord record ON af.record_id = record.id
  770. WHERE af.delete_state = 1 AND af.org_id = #{orgId,jdbcType=INTEGER}
  771. <if test="houseId != null" >
  772. AND record.house_id = #{houseId,jdbcType=INTEGER}
  773. </if>
  774. <if test="createTime != null">
  775. AND af.create_time &lt;= #{createTime}
  776. </if>
  777. </select>
  778. <select id="selectHomeWorkQueryList" parameterType="java.util.Map" resultType="java.util.HashMap">
  779. SELECT
  780. 1 AS planType,
  781. process.id,
  782. record.id AS fumigationId,
  783. record.house_id AS houseId,
  784. process.create_time AS createTime,
  785. process.creater,
  786. record.cgxzfs AS fumigationType,
  787. record.yjmc AS drugName
  788. FROM
  789. t_fumigation_process process
  790. INNER JOIN t_fumigation_forrecord record ON process.record_id = record.id
  791. /*INNER JOIN t_fumigation_plan plan ON plan.id = process.fumigation_id
  792. INNER JOIN t_fumigation_pesticide pes ON pes.fumigation_id = plan.id*/
  793. WHERE process.delete_state = 1 AND process.org_id = #{orgId,jdbcType=INTEGER}
  794. <if test="houseId != null" >
  795. AND plan.house_id = #{houseId,jdbcType=INTEGER}
  796. </if>
  797. UNION ALL
  798. SELECT
  799. 2 AS planType,
  800. af.id,
  801. plan.id AS fumigationId,
  802. plan.house_id AS houseId,
  803. af.create_time AS createTime,
  804. af.creater,
  805. plan.fumigation_type AS fumigationType,
  806. pes.drug_name AS drugName
  807. FROM
  808. t_fumigation_after af
  809. INNER JOIN t_fumigation_plan plan ON plan.id = af.fumigation_id
  810. INNER JOIN t_fumigation_pesticide pes ON pes.fumigation_id = plan.id
  811. WHERE af.delete_state = 1 AND af.org_id = #{orgId,jdbcType=INTEGER}
  812. <if test="houseId != null" >
  813. AND plan.house_id = #{houseId,jdbcType=INTEGER}
  814. </if>
  815. </select>
  816. </mapper>