RecordMedicineApproveBranchMainNewDao.xml 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804
  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="cn.ourwill.module.house.dao.new_dao.RecordMedicineApproveBranchMainNewDao" >
  4. <resultMap type="cn.ourwill.module.house.entity.new_entity.RecordMedicineApproveBranchMainNew" id="baseMap" >
  5. <id column="id" property="id" />
  6. <result column="grain_id" property="grainId" />
  7. <result column="apply_date" property="applyDate" />
  8. <result column="approve_date" property="approveDate" />
  9. <result column="approve_number" property="approveNumber" />
  10. <result column="approve_statement" property="approveStatement" />
  11. <result column="chief" property="chief" />
  12. <result column="general_manager" property="generalManager" />
  13. <result column="grain_name" property="grainName" />
  14. <result column="history_number" property="historyNumber" />
  15. <result column="c_id" property="cId" />
  16. <result column="c_time" property="cTime" />
  17. <result column="u_id" property="uId" />
  18. <result column="u_time" property="uTime" />
  19. <result column="uuid" property="uuid" />
  20. <result column="lister" property="lister" />
  21. <result column="plan_in_number" property="planInNumber" />
  22. <result column="total_number" property="totalNumber" />
  23. <result column="unit_code1" property="unitCode1" />
  24. <result column="unit_code2" property="unitCode2" />
  25. <result column="vice_general_manager" property="viceGeneralManager" />
  26. <result column="medicine_name" property="medicineName" />
  27. <result column="medicine_id" property="medicineId" />
  28. <result column="adjust" property="adjust" />
  29. <result column="grain_dosage" property="grainDosage" />
  30. <result column="grain_num" property="grainNum" />
  31. <result column="grain_type" property="grainType" />
  32. <result column="grain_volume" property="grainVolume" />
  33. <result column="house_id" property="houseId" />
  34. <result column="house_name" property="houseName" />
  35. <result column="house_type" property="houseType" />
  36. <result column="is_accept" property="isAccept" />
  37. <result column="is_new" property="isNew" />
  38. <result column="main_id" property="mainId" />
  39. <result column="medicament_manufacturers" property="medicamentManufacturers" />
  40. <result column="space_dosage" property="spaceDosage" />
  41. <result column="space_volume" property="spaceVolume" />
  42. <result column="temperature_date" property="temperatureDate" />
  43. <result column="theory_dosage" property="theoryDosage" />
  44. <result column="worm_density" property="wormDensity" />
  45. <result column="worm_type" property="wormType" />
  46. </resultMap>
  47. <sql id="columns">
  48. a.`id`,
  49. a.`apply_date`,
  50. a.`approve_date`,
  51. a.`approve_number`,
  52. a.`approve_statement`,
  53. a.`c_id`,
  54. a.`c_time`,
  55. a.`chief`,
  56. a.`general_manager`,
  57. a.`grain_id`,
  58. a.`grain_name`,
  59. a.`history_number`,
  60. a.`lister`,
  61. a.`plan_in_number`,
  62. a.`total_number`,
  63. a.`u_id`,
  64. a.`u_time`,
  65. a.`unit_code1`,
  66. a.`unit_code2`,
  67. a.`uuid`,
  68. a.`vice_general_manager`,
  69. a.`medicine_name`,
  70. a.`medicine_id`,
  71. a.`adjust`,
  72. a.`grain_dosage`,
  73. a.`grain_num`,
  74. a.`grain_type`,
  75. a.`grain_volume`,
  76. a.`house_id`,
  77. a.`house_name`,
  78. a.`house_type`,
  79. a.`is_accept`,
  80. a.`is_new`,
  81. a.`main_id`,
  82. a.`medicament_manufacturers`,
  83. a.`space_dosage`,
  84. a.`space_volume`,
  85. a.`temperature_date`,
  86. a.`theory_dosage`,
  87. a.`worm_density`,
  88. a.`worm_type`
  89. </sql>
  90. <sql id="joinCols">
  91. </sql>
  92. <select id="getBygrainId" resultMap="baseMap">
  93. SELECT
  94. <include refid="columns"/>
  95. FROM record_medicine_branch_new a
  96. <include refid="joinCols"/>
  97. WHERE a.uuid = #{UuId}
  98. </select>
  99. <select id="findByCondition" resultMap="baseMap">
  100. SELECT *
  101. FROM record_medicine_branch_new a
  102. where uuid = #{uuid}
  103. </select>
  104. <select id="findUuid" parameterType="java.lang.Long" resultType="java.lang.String">
  105. SELECT uuid
  106. FROM record_medicine_branch_new
  107. where id = #{id}
  108. </select>
  109. <delete id="deleteByuuid" parameterType="java.lang.String">
  110. delete
  111. FROM record_medicine_branch_new
  112. where uuid = #{uuid}
  113. </delete>
  114. <select id="findList" resultMap="baseMap">
  115. SELECT
  116. <include refid="columns"/>
  117. FROM record_medicine_branch_new a
  118. <include refid="joinCols"/>
  119. <where>
  120. <if test="id !=null">
  121. and a.id = #{id}
  122. </if>
  123. <if test="grainId !=null">
  124. and a.grain_id = #{grainId}
  125. </if>
  126. <if test="applyDate !=null">
  127. and a.apply_date = #{applyDate}
  128. </if>
  129. <if test="approveDate !=null">
  130. and a.approve_date = #{approveDate}
  131. </if>
  132. <if test="approveNumber !=null">
  133. and a.approve_number = #{approveNumber}
  134. </if>
  135. <if test="approveStatement !=null">
  136. and a.approve_statement = #{approveStatement}
  137. </if>
  138. <if test="chief !=null">
  139. and a.chief = #{chief}
  140. </if>
  141. <if test="generalManager !=null">
  142. and a.general_manager = #{generalManager}
  143. </if>
  144. <if test="grainName !=null">
  145. and a.grain_name = #{grainName}
  146. </if>
  147. <if test="historyNumber !=null">
  148. and a.history_number = #{historyNumber}
  149. </if>
  150. <if test="cId !=null">
  151. and a.c_id = #{cId}
  152. </if>
  153. <if test="cTime !=null">
  154. and a.c_time = #{cTime}
  155. </if>
  156. <if test="uId !=null">
  157. and a.u_id = #{uId}
  158. </if>
  159. <if test="uTime !=null">
  160. and a.u_time = #{uTime}
  161. </if>
  162. <if test="uuid !=null">
  163. and a.uuid = #{uuid}
  164. </if>
  165. <if test="lister !=null">
  166. and a.lister = #{lister}
  167. </if>
  168. <if test="planInNumber !=null">
  169. and a.plan_in_number = #{planInNumber}
  170. </if>
  171. <if test="totalNumber !=null">
  172. and a.total_number = #{totalNumber}
  173. </if>
  174. <if test="unitCode1 !=null">
  175. and a.unit_code1 = #{unitCode1}
  176. </if>
  177. <if test="unitCode2 !=null">
  178. and a.unit_code2 = #{unitCode2}
  179. </if>
  180. <if test="viceGeneralManager !=null">
  181. and a.vice_general_manager = #{viceGeneralManager}
  182. </if>
  183. <if test="medicineName !=null">
  184. and a.medicine_name = #{medicineName}
  185. </if>
  186. <if test="medicineId !=null">
  187. and a.medicine_id = #{medicineId}
  188. </if>
  189. <if test="adjust !=null">
  190. and a.adjust = #{adjust}
  191. </if>
  192. <if test="grainDosage !=null">
  193. and a.grain_dosage = #{grainDosage}
  194. </if>
  195. <if test="grainNum !=null">
  196. and a.grain_num = #{grainNum}
  197. </if>
  198. <if test="grainType !=null">
  199. and a.grain_type = #{grainType}
  200. </if>
  201. <if test="grainVolume !=null">
  202. and a.grain_volume = #{grainVolume}
  203. </if>
  204. <if test="houseId !=null">
  205. and a.house_id = #{houseId}
  206. </if>
  207. <if test="houseName !=null">
  208. and a.house_name = #{houseName}
  209. </if>
  210. <if test="houseType !=null">
  211. and a.house_type = #{houseType}
  212. </if>
  213. <if test="isAccept !=null">
  214. and a.is_accept = #{isAccept}
  215. </if>
  216. <if test="isNew !=null">
  217. and a.is_new = #{isNew}
  218. </if>
  219. <if test="mainId !=null">
  220. and a.main_id = #{mainId}
  221. </if>
  222. <if test="medicamentManufacturers !=null">
  223. and a.medicament_manufacturers = #{medicamentManufacturers}
  224. </if>
  225. <if test="spaceDosage !=null">
  226. and a.space_dosage = #{spaceDosage}
  227. </if>
  228. <if test="spaceVolume !=null">
  229. and a.space_volume = #{spaceVolume}
  230. </if>
  231. <if test="temperatureDate !=null">
  232. and a.temperature_date = #{temperatureDate}
  233. </if>
  234. <if test="theoryDosage !=null">
  235. and a.theory_dosage = #{theoryDosage}
  236. </if>
  237. <if test="wormDensity !=null">
  238. and a.worm_density = #{wormDensity}
  239. </if>
  240. <if test="wormType !=null">
  241. and a.worm_type = #{wormType}
  242. </if>
  243. </where>
  244. GROUP BY medicine_id,uuid
  245. <choose>
  246. <when test="page !=null and page.orderBy != null and page.orderBy != ''">
  247. ORDER BY ${page.orderBy}
  248. </when>
  249. <otherwise>
  250. </otherwise>
  251. </choose>
  252. </select>
  253. <select id="findAllList" resultMap="baseMap">
  254. SELECT
  255. <include refid="columns"/>
  256. FROM record_medicine_branch_new a
  257. <include refid="joinCols"/>
  258. <where>
  259. <if test="id !=null">
  260. and a.id = #{id}
  261. </if>
  262. <if test="grainId !=null">
  263. and a.grain_id = #{grainId}
  264. </if>
  265. <if test="applyDate !=null">
  266. and a.apply_date = #{applyDate}
  267. </if>
  268. <if test="approveDate !=null">
  269. and a.approve_date = #{approveDate}
  270. </if>
  271. <if test="approveNumber !=null">
  272. and a.approve_number = #{approveNumber}
  273. </if>
  274. <if test="approveStatement !=null">
  275. and a.approve_statement = #{approveStatement}
  276. </if>
  277. <if test="chief !=null">
  278. and a.chief = #{chief}
  279. </if>
  280. <if test="generalManager !=null">
  281. and a.general_manager = #{generalManager}
  282. </if>
  283. <if test="grainName !=null">
  284. and a.grain_name = #{grainName}
  285. </if>
  286. <if test="historyNumber !=null">
  287. and a.history_number = #{historyNumber}
  288. </if>
  289. <if test="cId !=null">
  290. and a.c_id = #{cId}
  291. </if>
  292. <if test="cTime !=null">
  293. and a.c_time = #{cTime}
  294. </if>
  295. <if test="uId !=null">
  296. and a.u_id = #{uId}
  297. </if>
  298. <if test="uTime !=null">
  299. and a.u_time = #{uTime}
  300. </if>
  301. <if test="uuid !=null">
  302. and a.uuid = #{uuid}
  303. </if>
  304. <if test="lister !=null">
  305. and a.lister = #{lister}
  306. </if>
  307. <if test="planInNumber !=null">
  308. and a.plan_in_number = #{planInNumber}
  309. </if>
  310. <if test="totalNumber !=null">
  311. and a.total_number = #{totalNumber}
  312. </if>
  313. <if test="unitCode1 !=null">
  314. and a.unit_code1 = #{unitCode1}
  315. </if>
  316. <if test="unitCode2 !=null">
  317. and a.unit_code2 = #{unitCode2}
  318. </if>
  319. <if test="viceGeneralManager !=null">
  320. and a.vice_general_manager = #{viceGeneralManager}
  321. </if>
  322. <if test="medicineName !=null">
  323. and a.medicine_name = #{medicineName}
  324. </if>
  325. <if test="medicineId !=null">
  326. and a.medicine_id = #{medicineId}
  327. </if>
  328. <if test="adjust !=null">
  329. and a.adjust = #{adjust}
  330. </if>
  331. <if test="grainDosage !=null">
  332. and a.grain_dosage = #{grainDosage}
  333. </if>
  334. <if test="grainNum !=null">
  335. and a.grain_num = #{grainNum}
  336. </if>
  337. <if test="grainType !=null">
  338. and a.grain_type = #{grainType}
  339. </if>
  340. <if test="grainVolume !=null">
  341. and a.grain_volume = #{grainVolume}
  342. </if>
  343. <if test="houseId !=null">
  344. and a.house_id = #{houseId}
  345. </if>
  346. <if test="houseName !=null">
  347. and a.house_name = #{houseName}
  348. </if>
  349. <if test="houseType !=null">
  350. and a.house_type = #{houseType}
  351. </if>
  352. <if test="isAccept !=null">
  353. and a.is_accept = #{isAccept}
  354. </if>
  355. <if test="isNew !=null">
  356. and a.is_new = #{isNew}
  357. </if>
  358. <if test="mainId !=null">
  359. and a.main_id = #{mainId}
  360. </if>
  361. <if test="medicamentManufacturers !=null">
  362. and a.medicament_manufacturers = #{medicamentManufacturers}
  363. </if>
  364. <if test="spaceDosage !=null">
  365. and a.space_dosage = #{spaceDosage}
  366. </if>
  367. <if test="spaceVolume !=null">
  368. and a.space_volume = #{spaceVolume}
  369. </if>
  370. <if test="temperatureDate !=null">
  371. and a.temperature_date = #{temperatureDate}
  372. </if>
  373. <if test="theoryDosage !=null">
  374. and a.theory_dosage = #{theoryDosage}
  375. </if>
  376. <if test="wormDensity !=null">
  377. and a.worm_density = #{wormDensity}
  378. </if>
  379. <if test="wormType !=null">
  380. and a.worm_type = #{wormType}
  381. </if>
  382. </where>
  383. <choose>
  384. <when test="page !=null and page.orderBy != null and page.orderBy != ''">
  385. ORDER BY ${page.orderBy}
  386. </when>
  387. <otherwise>
  388. </otherwise>
  389. </choose>
  390. </select>
  391. <insert id="insert" keyColumn="id" keyProperty="id" useGeneratedKeys="true"
  392. parameterType="cn.ourwill.module.house.entity.new_entity.RecordMedicineApproveBranchMainNew">
  393. INSERT INTO record_medicine_branch_new
  394. <trim prefix="(" suffix=")" suffixOverrides=",">
  395. <!--<if test=" id != null">
  396. id,
  397. </if>-->
  398. <if test="grainId !=null">
  399. grain_id,
  400. </if>
  401. <if test="applyDate !=null">
  402. apply_date,
  403. </if>
  404. <if test="approveDate !=null">
  405. approve_date,
  406. </if>
  407. <if test="approveNumber !=null">
  408. approve_number,
  409. </if>
  410. <if test="approveStatement !=null">
  411. approve_statement,
  412. </if>
  413. <if test="chief !=null">
  414. chief,
  415. </if>
  416. <if test="generalManager !=null">
  417. general_manager,
  418. </if>
  419. <if test="grainName !=null">
  420. grain_name,
  421. </if>
  422. <if test="historyNumber !=null">
  423. history_number,
  424. </if>
  425. <if test="cId !=null">
  426. c_id,
  427. </if>
  428. <if test="cTime !=null">
  429. c_time,
  430. </if>
  431. <if test="uId !=null">
  432. u_id,
  433. </if>
  434. <if test="uTime !=null">
  435. u_time,
  436. </if>
  437. <if test="uuid !=null">
  438. uuid,
  439. </if>
  440. <if test="lister !=null">
  441. lister,
  442. </if>
  443. <if test="planInNumber !=null">
  444. plan_in_number,
  445. </if>
  446. <if test="totalNumber !=null">
  447. total_number,
  448. </if>
  449. <if test="unitCode1 !=null">
  450. unit_code1,
  451. </if>
  452. <if test="unitCode2 !=null">
  453. unit_code2,
  454. </if>
  455. <if test="viceGeneralManager !=null">
  456. vice_general_manager,
  457. </if>
  458. <if test="medicineName !=null">
  459. medicine_name,
  460. </if>
  461. <if test="medicineId !=null">
  462. medicine_id,
  463. </if>
  464. <if test="adjust !=null">
  465. adjust,
  466. </if>
  467. <if test="grainDosage !=null">
  468. grain_dosage,
  469. </if>
  470. <if test="grainNum !=null">
  471. grain_num,
  472. </if>
  473. <if test="grainType !=null">
  474. grain_type,
  475. </if>
  476. <if test="grainVolume !=null">
  477. grain_volume,
  478. </if>
  479. <if test="houseId !=null">
  480. house_id,
  481. </if>
  482. <if test="houseName !=null">
  483. house_name,
  484. </if>
  485. <if test="houseType !=null">
  486. house_type,
  487. </if>
  488. <if test="isAccept !=null">
  489. is_accept,
  490. </if>
  491. <if test="isNew !=null">
  492. is_new,
  493. </if>
  494. <if test="mainId !=null">
  495. main_id ,
  496. </if>
  497. <if test="medicamentManufacturers !=null">
  498. medicament_manufacturers ,
  499. </if>
  500. <if test="spaceDosage !=null">
  501. space_dosage,
  502. </if>
  503. <if test="spaceVolume !=null">
  504. space_volume,
  505. </if>
  506. <if test="temperatureDate !=null">
  507. temperature_date,
  508. </if>
  509. <if test="theoryDosage !=null">
  510. theory_dosage,
  511. </if>
  512. <if test="wormDensity !=null">
  513. worm_density,
  514. </if>
  515. <if test="wormType !=null">
  516. worm_type
  517. </if>
  518. </trim>
  519. <trim prefix="values (" suffix=")" suffixOverrides=",">
  520. <!--<if test=" id != null">
  521. #{id}, </if>-->
  522. <if test="grainId !=null">
  523. #{grainId},
  524. </if>
  525. <if test="applyDate !=null">
  526. #{applyDate},
  527. </if>
  528. <if test="approveDate !=null">
  529. #{approveDate},
  530. </if>
  531. <if test="approveNumber !=null">
  532. #{approveNumber},
  533. </if>
  534. <if test="approveStatement !=null">
  535. #{approveStatement},
  536. </if>
  537. <if test="chief !=null">
  538. #{chief},
  539. </if>
  540. <if test="generalManager !=null">
  541. #{generalManager},
  542. </if>
  543. <if test="grainName !=null">
  544. #{grainName},
  545. </if>
  546. <if test="historyNumber !=null">
  547. #{historyNumber},
  548. </if>
  549. <if test="cId !=null">
  550. #{cId},
  551. </if>
  552. <if test="cTime !=null">
  553. #{cTime},
  554. </if>
  555. <if test="uId !=null">
  556. #{uId},
  557. </if>
  558. <if test="uTime !=null">
  559. #{uTime},
  560. </if>
  561. <if test="uuid !=null">
  562. #{uuid},
  563. </if>
  564. <if test="lister !=null">
  565. #{lister},
  566. </if>
  567. <if test="planInNumber !=null">
  568. #{planInNumber},
  569. </if>
  570. <if test="totalNumber !=null">
  571. #{totalNumber},
  572. </if>
  573. <if test="unitCode1 !=null">
  574. #{unitCode1},
  575. </if>
  576. <if test="unitCode2 !=null">
  577. #{unitCode2},
  578. </if>
  579. <if test="viceGeneralManager !=null">
  580. #{viceGeneralManager},
  581. </if>
  582. <if test="medicineName !=null">
  583. #{medicineName},
  584. </if>
  585. <if test="medicineId !=null">
  586. #{medicineId},
  587. </if>
  588. <if test="adjust !=null">
  589. #{adjust},
  590. </if>
  591. <if test="grainDosage !=null">
  592. #{grainDosage},
  593. </if>
  594. <if test="grainNum !=null">
  595. #{grainNum},
  596. </if>
  597. <if test="grainType !=null">
  598. #{grainType},
  599. </if>
  600. <if test="grainVolume !=null">
  601. #{grainVolume},
  602. </if>
  603. <if test="houseId !=null">
  604. #{houseId},
  605. </if>
  606. <if test="houseName !=null">
  607. #{houseName},
  608. </if>
  609. <if test="houseType !=null">
  610. #{houseType},
  611. </if>
  612. <if test="isAccept !=null">
  613. #{isAccept},
  614. </if>
  615. <if test="isNew !=null">
  616. #{isNew},
  617. </if>
  618. <if test="mainId !=null">
  619. #{mainId},
  620. </if>
  621. <if test="medicamentManufacturers !=null">
  622. #{medicamentManufacturers},
  623. </if>
  624. <if test="spaceDosage !=null">
  625. #{spaceDosage},
  626. </if>
  627. <if test="spaceVolume !=null">
  628. #{spaceVolume},
  629. </if>
  630. <if test="temperatureDate !=null">
  631. #{temperatureDate},
  632. </if>
  633. <if test="theoryDosage !=null">
  634. #{theoryDosage},
  635. </if>
  636. <if test="wormDensity !=null">
  637. #{wormDensity},
  638. </if>
  639. <if test="wormType !=null">
  640. #{wormType}
  641. </if>
  642. </trim>
  643. </insert>
  644. <update id="update" parameterType="cn.ourwill.module.house.entity.new_entity.RecordMedicineApproveBranchMainNew">
  645. UPDATE record_medicine_branch_new <set>
  646. <if test="id != null">
  647. id= #{id} ,
  648. </if>
  649. <if test="grainId !=null">
  650. grain_id = #{grainId},
  651. </if>
  652. <if test="applyDate !=null">
  653. apply_date = #{applyDate},
  654. </if>
  655. <if test="approveDate !=null">
  656. approve_date = #{approveDate},
  657. </if>
  658. <if test="approveNumber !=null">
  659. approve_number = #{approveNumber},
  660. </if>
  661. <if test="approveStatement !=null">
  662. approve_statement = #{approveStatement},
  663. </if>
  664. <if test="chief !=null">
  665. chief = #{chief},
  666. </if>
  667. <if test="generalManager !=null">
  668. general_manager = #{generalManager},
  669. </if>
  670. <if test="grainName !=null">
  671. grain_name = #{grainName},
  672. </if>
  673. <if test="historyNumber !=null">
  674. history_number = #{historyNumber},
  675. </if>
  676. <if test="cId !=null">
  677. c_id = #{cId},
  678. </if>
  679. <if test="cTime !=null">
  680. c_time = #{cTime},
  681. </if>
  682. <if test="uId !=null">
  683. u_id = #{uId},
  684. </if>
  685. <if test="uTime !=null">
  686. u_time = #{uTime},
  687. </if>
  688. <if test="uuid !=null">
  689. uuid = #{uuid},
  690. </if>
  691. <if test="lister !=null">
  692. lister = #{lister},
  693. </if>
  694. <if test="planInNumber !=null">
  695. plan_in_number = #{planInNumber},
  696. </if>
  697. <if test="totalNumber !=null">
  698. total_number = #{totalNumber},
  699. </if>
  700. <if test="unitCode1 !=null">
  701. unit_code1 = #{unitCode1},
  702. </if>
  703. <if test="unitCode2 !=null">
  704. unit_code2 = #{unitCode2},
  705. </if>
  706. <if test="viceGeneralManager !=null">
  707. vice_general_manager = #{viceGeneralManager},
  708. </if>
  709. <if test="medicineName !=null">
  710. medicine_name = #{medicineName},
  711. </if>
  712. <if test="medicineId !=null">
  713. medicine_id = #{medicineId},
  714. </if>
  715. <if test="adjust !=null">
  716. adjust = #{adjust},
  717. </if>
  718. <if test="grainDosage !=null">
  719. grain_dosage = #{grainDosage},
  720. </if>
  721. <if test="grainNum !=null">
  722. grain_num = #{grainNum},
  723. </if>
  724. <if test="grainType !=null">
  725. grain_type = #{grainType},
  726. </if>
  727. <if test="grainVolume !=null">
  728. grain_volume = #{grainVolume},
  729. </if>
  730. <if test="houseId !=null">
  731. house_id = #{houseId},
  732. </if>
  733. <if test="houseName !=null">
  734. house_name = #{houseName},
  735. </if>
  736. <if test="houseType !=null">
  737. house_type = #{houseType},
  738. </if>
  739. <if test="isAccept !=null">
  740. is_accept = #{isAccept},
  741. </if>
  742. <if test="isNew !=null">
  743. is_new = #{isNew},
  744. </if>
  745. <if test="mainId !=null">
  746. main_id = #{mainId},
  747. </if>
  748. <if test="medicamentManufacturers !=null">
  749. medicament_manufacturers = #{medicamentManufacturers},
  750. </if>
  751. <if test="spaceDosage !=null">
  752. space_dosage = #{spaceDosage},
  753. </if>
  754. <if test="spaceVolume !=null">
  755. space_volume = #{spaceVolume},
  756. </if>
  757. <if test="temperatureDate !=null">
  758. temperature_date = #{temperatureDate},
  759. </if>
  760. <if test="theoryDosage !=null">
  761. theory_dosage = #{theoryDosage},
  762. </if>
  763. <if test="wormDensity !=null">
  764. worm_density = #{wormDensity},
  765. </if>
  766. <if test="wormType !=null">
  767. worm_type = #{wormType}
  768. </if>
  769. </set>
  770. WHERE id = #{id}
  771. </update>
  772. <delete id="deleteById" parameterType="java.lang.Long">
  773. DELETE FROM record_medicine_branch_new WHERE id = #{id}
  774. </delete>
  775. <delete id="deleteByIds" parameterType="java.util.List">
  776. DELETE FROM record_medicine_branch_new WHERE id IN
  777. <foreach collection="list" index="index" item="item" open="(" separator="," close=")">
  778. #{item}
  779. </foreach>
  780. </delete>
  781. </mapper>