Ejemplo n.º 1
0
  @RequestMapping("QryAuthDtl")
  public String queryAuthDtl(Model model, FTZ210205Form form, @PageableDefaults Pageable pageable) {
    FtzInMsgCtl query_FtzInMsgCtl = new FtzInMsgCtl();
    query_FtzInMsgCtl.setMsgId(form.getSelected_msgId());
    FtzInMsgCtl result_FtzInMsgCtl = ftz210205Serv.queryFtzInMsgCtl(query_FtzInMsgCtl);
    if (null == result_FtzInMsgCtl) {
      model.addAttribute(ResultMessages.info().add("w.sm.0001"));
      form.setSelected_msgId("");
      form.setSelected_seqNo(null);
      return "ftzmis/FTZ210205_Auth_Qry_Dtl";
    } else {
      result_FtzInMsgCtl.setSubmitDate(
          DateUtil.getFormatDateAddSprit(result_FtzInMsgCtl.getSubmitDate()));
      result_FtzInMsgCtl.setSndDatetime(
          DateUtil.getFormatDateTimeAddSpritAndColon(result_FtzInMsgCtl.getSndDatetime()));
      result_FtzInMsgCtl.setAckDatetime(
          DateUtil.getFormatDateTimeAddSpritAndColon(result_FtzInMsgCtl.getAckDatetime()));
      result_FtzInMsgCtl.setBalanceCode(result_FtzInMsgCtl.getBalanceCode().trim());
      form.setFtzInMsgCtl(result_FtzInMsgCtl);
      FtzInTxnDtl query_FtzInTxnDtl = new FtzInTxnDtl();
      query_FtzInTxnDtl.setMsgId(form.getSelected_msgId());
      // 查询待审核数据
      if ("1".equals(form.getUnAuthFlag())) {
        query_FtzInTxnDtl.setChkStatus(CommonConst.FTZ_MSG_STATUS_INPUT_COMPLETED);
        Page<FtzInTxnDtl> page = ftz210205Serv.queryFtzInTxnDtlPage(pageable, query_FtzInTxnDtl);
        if (page.getContent().size() > 0) {
          List<FtzInTxnDtl> ftzInTxnDtls = page.getContent();
          for (FtzInTxnDtl ftzInTxnDtl : ftzInTxnDtls) {
            ftzInTxnDtl.setTranDate(DateUtil.getFormatDateAddSprit(ftzInTxnDtl.getTranDate()));
          }
          model.addAttribute("page", page);
        }
      }
      // 查询全部数据
      else {
        Page<FtzInTxnDtl> page = ftz210205Serv.queryFtzInTxnDtlPage(pageable, query_FtzInTxnDtl);
        if (page.getContent().size() > 0) {
          List<FtzInTxnDtl> ftzInTxnDtls = page.getContent();
          for (FtzInTxnDtl ftzInTxnDtl : ftzInTxnDtls) {
            ftzInTxnDtl.setTranDate(DateUtil.getFormatDateAddSprit(ftzInTxnDtl.getTranDate()));
          }
          model.addAttribute("page", page);
        }
      }

      form.setSelected_msgId("");
      form.setSelected_seqNo(null);
      return "ftzmis/FTZ210205_Auth_Qry_Dtl";
    }
  }
Ejemplo n.º 2
0
 // 点击查看明细
 @RequestMapping("QryDtl")
 public String queryDtl(Model model, FTZ210205Form form, @PageableDefaults Pageable pageable) {
   logger.info("买入返售资产批量查询开始...");
   // 组装查询信息
   FtzInMsgCtl query_FtzInMsgCtl = new FtzInMsgCtl();
   query_FtzInMsgCtl.setMsgId(form.getSelected_msgId());
   // 查询数据
   FtzInMsgCtl result_FtzInMsgCtl = ftz210205Serv.queryFtzInMsgCtl(query_FtzInMsgCtl);
   if (null == result_FtzInMsgCtl) {
     // 若无数据 则返回提示信息
     model.addAttribute(ResultMessages.info().add("w.sm.0001"));
     form.setSelected_msgId("");
     form.setSelected_seqNo(null);
     logger.error("查询无记录!");
     logger.info("买入返售资产批量查询结束...");
     return "ftzmis/FTZ210205_Qry";
   } else {
     // 有数据则进行数据转换,查询明细数据
     result_FtzInMsgCtl.setBalanceCode(result_FtzInMsgCtl.getBalanceCode().trim());
     result_FtzInMsgCtl.setSubmitDate(
         DateUtil.getFormatDateAddSprit(result_FtzInMsgCtl.getSubmitDate()));
     result_FtzInMsgCtl.setSndDatetime(
         DateUtil.getFormatDateTimeAddSpritAndColon(result_FtzInMsgCtl.getSndDatetime()));
     result_FtzInMsgCtl.setAckDatetime(
         DateUtil.getFormatDateTimeAddSpritAndColon(result_FtzInMsgCtl.getAckDatetime()));
     result_FtzInMsgCtl.setBalanceCode(result_FtzInMsgCtl.getBalanceCode().trim());
     form.setFtzInMsgCtl(result_FtzInMsgCtl);
     FtzInTxnDtl query_FtzInTxnDtl = new FtzInTxnDtl();
     query_FtzInTxnDtl.setMsgId(form.getSelected_msgId());
     Page<FtzInTxnDtl> page = ftz210205Serv.queryFtzInTxnDtlPage(pageable, query_FtzInTxnDtl);
     if (page.getContent().size() > 0) {
       List<FtzInTxnDtl> ftzInTxnDtls = page.getContent();
       for (FtzInTxnDtl ftzInTxnDtl : ftzInTxnDtls) {
         ftzInTxnDtl.setTranDate(DateUtil.getFormatDateAddSprit(ftzInTxnDtl.getTranDate()));
       }
       model.addAttribute("page", page);
       form.setSelected_msgId("");
       form.setSelected_seqNo(null);
     }
     logger.info("买入返售资产批量查询结束...");
     return "ftzmis/FTZ210205_Qry_Dtl";
   }
 }