Commit 220e4483 authored by suichenguang's avatar suichenguang

交接单修改3.0

parent 90c70513
......@@ -65,11 +65,10 @@ public interface ReceiptMapper {
//根据身份证号查询特证交接单
//查询未复核交接单
@Select("SELECT RECEIPT_LIST.* FROM RECEIPT_LIST where state=0\n")
public List<Map<String,Object>>selectReceiptListOfSpecialCard ();
//根据身份证号查询普通证交接单
@Select("SELECT RECEIPT_LIST.* FROM RECEIPT_LIST \n" +
"LEFT JOIN PROD_CARD_T@PROD_LINK ON subStr(PROD_CARD_T.ACCEPT_NO,0,8) =RECEIPT_LIST.QR_CODE\n" +
......@@ -87,9 +86,48 @@ public interface ReceiptMapper {
"check_date = #{date},\n" +
"check_name=#{checkName} \n" +
"where id=#{receiptId}")
public boolean updateReceiptList(int receiptId, String checkName, Date date);
public boolean updateReceiptList(String receiptId, String checkName, Date date);
//根据输入id查询交接单是否生成
@Select("select count(*) from RECEIPT_LIST where QR_CODE=(select accept_no from prod_card_t@prod_link where id_no=#{id})")
public int selectCountById(@Param("id") String id);
//根据输入id查询是否生成详单
@Select("select count(*) from DETAIL_RECEIPT_LIST where ACCEPT_NO=(select accept_no from prod_card_t@prod_link where id_no=#{id})")
public int selectReceiptById(@Param("id") String id);
//复核一致,按交接单编号查询证件数量
@Select("select FINISH_COUNT from RECEIPT_LIST WHERE ID=#{receiptId}")
public int selectCountByReceiptId(@Param("receiptId")String receiptId);
//符合一致,按交接单编号查询详单库数量
public int selectDetailCountByReceiptId(@Param("receiptId")String receiptId);
@Select("SELECT RECEIPT_LIST.*FROM RECEIPT_LIST where state=0;\n" +
"select \n" +
"count(prod_trace_t.download_no)as download,\n" +
"count(prod_trace_t.checker_no) as checkerCount,\n" +
"count(prod_trace_t.ELECTRIC_WRITER_NO)as electricCount\n" +
"from prod_trace_t@PROD_LINK \n" +
"WHERE subStr(ACCEPT_NO,0,8) = #{groupNo} or ACCEPT_NO=#{groupNo}")
public Map<String,Object> selectCountTime(String groupNo);
@Select("SELECT RECEIPT_LIST.*FROM RECEIPT_LIST where state=0;\n" +
"select \n" +
"prod_trace_t.DOWNLOAD_DATE as downloadDate,\n" +
"prod_trace_t.CHECK_DATE as checkDate,\n" +
"prod_trace_t.ELECTRIC_WRITE_DATE as electricDate\n" +
"from prod_trace_t@PROD_LINK \n" +
"WHERE subStr(ACCEPT_NO,0,8) = #{groupNo} or ACCEPT_NO=#{groupNo}")
public Map<String,Object>selectTimes(String groupNo);
}
......@@ -28,9 +28,29 @@ public interface ReceiptService {
public List<Map<String,Object>> selectDetailList(String receiptId);
public boolean updateReceiptList(int receiptId, String checkName, Date date);
public boolean updateReceiptList(String receiptId, String checkName, Date date);
public int selectCount(String GROUP_NO);
public boolean updateFinishCount(String GROUP_NO,int count);
//特证查询是否生成交接单
public int selectCountById(@Param("id") String id);
//查询是否已生成交接单详单
public int selectReceiptById(@Param("id") String id);
//复核一致,按交接单编号查询证件数量
public int selectCountByReceiptId(@Param("receiptId")String receiptId);
//符合一致,按交接单编号查询详单库数量
public int selectDetailCountByReceiptId(@Param("receiptId")String receiptId);
public Map<String,Object> selectCountTime(String groupNo);
public Map<String,Object> selectTimes(String groupNo);
}
......@@ -77,7 +77,7 @@ public class ReceiptServiceImpl implements ReceiptService {
}
@Override
public boolean updateReceiptList(int receiptId, String checkName, Date date) {
public boolean updateReceiptList(String receiptId, String checkName, Date date) {
receiptMapper.updateReceiptList(receiptId, checkName, date);
return true;
}
......@@ -94,5 +94,39 @@ public class ReceiptServiceImpl implements ReceiptService {
return true;
}
@Override
public int selectCountById(String id) {
int countAccept= receiptMapper.selectCountById(id);
return countAccept;
}
@Override
public int selectReceiptById(String id) {
int receiptCount = receiptMapper.selectReceiptById(id);
return receiptCount;
}
@Override
public int selectCountByReceiptId(String receiptId) {
int finishCount = selectCountByReceiptId(receiptId);
return finishCount;
}
@Override
public int selectDetailCountByReceiptId(String receiptId) {
int detailCount = selectDetailCountByReceiptId(receiptId);
return detailCount;
}
@Override
public Map<String, Object> selectCountTime(String groupNo) {
Map<String, Object> maps = receiptMapper.selectCountTime(groupNo);
return maps;
}
@Override
public Map<String, Object> selectTimes(String groupNo) {
Map<String, Object> maps = receiptMapper.selectTimes(groupNo);
return maps;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment