| | |
| | | ir.url, |
| | | ir.url_s, |
| | | (select count(*) from ins_sample isa2 |
| | | where isa2.ins_order_id = io.id and isa2.sample_code NOT REGEXP '/' ) sample_num, |
| | | where isa2.ins_order_id = io.id) sample_num, |
| | | concat(ROUND((select count(*) from ins_product ip |
| | | where state = 1 and ins_result is not null and ip.ins_sample_id in (select id from ins_sample where ins_sample.ins_order_id= io.id )) / (select count(*) from ins_product ip2 |
| | | where state = 1 and ip2.ins_sample_id in (select id from ins_sample where ins_sample.ins_order_id= io.id )) * 100, 2), '%') insProgress, |
| | | where state = 1 and ins_result is not null and ip.ins_sample_id in (select id from ins_sample where |
| | | ins_sample.ins_order_id= io.id )) / (select count(*) from ins_product ip2 |
| | | where state = 1 and ip2.ins_sample_id in (select id from ins_sample where ins_sample.ins_order_id= io.id )) * |
| | | 100, 2), '%') insProgress, |
| | | group_concat(distinct isa.sample_code,' ') sample_code, |
| | | group_concat(distinct isa.sample,' ') sample_name, |
| | | group_concat(distinct isa.model,' ') sample_model, |
| | |
| | | from laboratory |
| | | where laboratory_name = #{laboratory} |
| | | </select> |
| | | <select id="selectReportModelByOrderId" resultType="java.util.Map"> |
| | | select distinct id, name |
| | | from standard_template |
| | | where id in (select template_id |
| | | from ins_product |
| | | where son_laboratory = #{laboratory} |
| | | and ins_sample_id in |
| | | (select id from ins_sample where ins_order_id = #{id})) |
| | | </select> |
| | | </mapper> |