| | |
| | | </delete> |
| | | <select id="getLinkBasicPage" resultType="map"> |
| | | SELECT d.`id`, l.`entrust_coding`, l.`entrusted`, d.`samples_number`, d.`sample_name`, |
| | | d.`specifications_models`, |
| | | s.name specifications_models, |
| | | d.spe_name speName, |
| | | DATE_FORMAT(l.`inspection_time`,'%Y-%m-%d') inspectionTime, DATE_FORMAT(l.`completion_deadline`,'%Y-%m-%d') |
| | | completionDeadline, l.`contacts`, |
| | | DATE_FORMAT(d.`date_survey`,'%Y-%m-%d') dateSurvey, d.`inspection_status`, |
| | | DATE_FORMAT(l.`ins_time`,'%Y-%m-%d') insTime |
| | | FROM link_basic_information l, link_detection d |
| | | FROM link_basic_information l, link_detection d,specifications s |
| | | WHERE l.`id` = d.`link_basic_id` |
| | | and s.id=d.`specifications_models` |
| | | AND d.`state` = 1 |
| | | and l.`state` = 1 |
| | | <if test="entrustCoding != null and entrustCoding != null"> |
| | |
| | | |
| | | <select id="selectLinkAll" resultType="java.util.Map"> |
| | | SELECT d.id, |
| | | l.entrust_coding entrustCoding, |
| | | DATE_FORMAT(l.`inspection_time`, '%Y-%m-%d') formTime, |
| | | l.`entrusted` supplier, |
| | | d.`sample_number` mcode, |
| | | d.`sample_name` name, |
| | | d.`specifications_models` specifications, |
| | | d.`spe_name` specifications, |
| | | d.`unit`, |
| | | d.`samples_number` num, |
| | | d.specifications_models specificationsId, |
| | | experiment, |
| | | DATE_FORMAT(date_survey, '%Y-%m-%d') startTime, |
| | | DATE_FORMAT(completion_deadline, '%Y-%m-%d') endTime |
| | |
| | | ld.sample_name sampleName, |
| | | ld.specifications_models specificationsModels, |
| | | ld.unit unit, |
| | | ld.experiment experiment, |
| | | ld.samples_number samplesNumber, |
| | | ld.remarks remarks |
| | | ld.remarks remarks, |
| | | ld.spe_name speName |
| | | FROM link_basic_information lb left join |
| | | link_detection ld |
| | | on lb.id = ld.link_basic_id |
| | | left join specifications s |
| | | on ld.specifications_models = s.id |
| | | where lb.uid = #{uid} |
| | | and lb.state = 1 |
| | | </select> |
| | |
| | | <result property="unit" column="unit"/> |
| | | <result property="samplesNumber" column="samplesNumber"/> |
| | | <result property="remarks" column="remarks"/> |
| | | <result property="experiment" column="experiment"/> |
| | | <result property="speName" column="speName"/> |
| | | </collection> |
| | | </resultMap> |
| | | </mapper> |