|
@@ -491,19 +491,21 @@ public interface JianYanJianChaDao {
|
|
|
*
|
|
|
* @return
|
|
|
*/
|
|
|
- @Select("select distinct rtrim(zy_order_code) as code,\n" +
|
|
|
- " rtrim(name) as name,\n" +
|
|
|
- " rtrim(class) as classes,\n" +
|
|
|
- " exec_unit,\n" +
|
|
|
- " exec_unit_name = (select name from zd_unit_code where zd_unit_code.code = exec_unit),\n" +
|
|
|
- " '2' as type,\n" +
|
|
|
- " inspect_stuff as inspectStuff,\n" +
|
|
|
- " inspectStuffName = (select rtrim(name) from jy_zd_sample with (NOLOCK) where code = inspect_stuff)\n" +
|
|
|
- "from jy_zd_item a,\n" +
|
|
|
- " zy_tc_detail_yj b\n" +
|
|
|
- "where isnull(del_flag, '0') = '0'\n" +
|
|
|
- " and isnull(zy_flag, '0') = '0'\n" +
|
|
|
- " and a.zy_order_code = b.order_code")
|
|
|
+ @Select("select distinct rtrim(zy_order_code) as code, " +
|
|
|
+ " rtrim(name) as name, " +
|
|
|
+ " rtrim(class) as classes, " +
|
|
|
+ " exec_unit, " +
|
|
|
+ " exec_unit_name = (select name from zd_unit_code where zd_unit_code.code = exec_unit), " +
|
|
|
+ " '2' as type, " +
|
|
|
+ " inspect_stuff as inspectStuff, " +
|
|
|
+ " inspectStuffName = (select rtrim(name) from jy_zd_sample with (NOLOCK) where code = inspect_stuff) " +
|
|
|
+ "from jy_zd_item a, " +
|
|
|
+ " zy_tc_detail_yj b " +
|
|
|
+ "where isnull(del_flag, '0') = '0' " +
|
|
|
+ " and isnull(zy_flag, '0') = '0' " +
|
|
|
+ " and a.zy_order_code = b.order_code " +
|
|
|
+ " and inspect_stuff is not null " +
|
|
|
+ " and nullif(exec_unit, '') is not null")
|
|
|
List<JyJcItem> getJyDetailedItems();
|
|
|
|
|
|
|
|
@@ -524,5 +526,33 @@ public interface JianYanJianChaDao {
|
|
|
"order by class;")
|
|
|
List<JyJcItem> selectJcDetailItems();
|
|
|
|
|
|
+ @Select("select zy_order_code as code, " +
|
|
|
+ " name, " +
|
|
|
+ " exec_unit, " +
|
|
|
+ " exec_unit_name = (select name from zd_unit_code where zd_unit_code.code = exec_unit) " +
|
|
|
+ "from jc_zd_item " +
|
|
|
+ "where del_flag = 0 " +
|
|
|
+ " and zy_flag = 0 " +
|
|
|
+ " and (zy_order_code like #{code} or py_code like #{code} or d_code like #{code} or name like #{code})")
|
|
|
+ List<JyJcItem> getJcItem(String code);
|
|
|
+
|
|
|
+ @Select("select distinct rtrim(zy_order_code) as code, " +
|
|
|
+ " rtrim(name) as name, " +
|
|
|
+ " rtrim(class) as classes, " +
|
|
|
+ " exec_unit, " +
|
|
|
+ " exec_unit_name = (select name from zd_unit_code where zd_unit_code.code = exec_unit), " +
|
|
|
+ " '2' as type, " +
|
|
|
+ " inspect_stuff as inspectStuff, " +
|
|
|
+ " inspectStuffName = (select rtrim(name) from jy_zd_sample with (NOLOCK) where code = inspect_stuff) " +
|
|
|
+ "from jy_zd_item a, " +
|
|
|
+ " zy_tc_detail_yj b " +
|
|
|
+ "where isnull(del_flag, '0') = '0' " +
|
|
|
+ " and isnull(zy_flag, '0') = '0' " +
|
|
|
+ " and a.zy_order_code = b.order_code " +
|
|
|
+ " and inspect_stuff is not null " +
|
|
|
+ " and nullif(exec_unit, '') is not null " +
|
|
|
+ " and (zy_order_code like #{code} or py_code like #{code} or d_code like #{code} or name like #{code})")
|
|
|
+ List<JyJcItem> getJyItem(String code);
|
|
|
+
|
|
|
|
|
|
}
|