示例#1
0
  // 영수증 재발행
  @RequestMapping(value = "/bsar/ar/arReceiptReport", method = RequestMethod.GET)
  public String receiptReportOpen(Model model, ReceiptCmd receiptCmd) {

    try {

      model.addAttribute("recpData", "");
      model.addAttribute("arPymDialogName", "");
      model.addAttribute("callBackFunc", "");
      receiptCmd.setLanguage("mn");
      model.addAttribute("receiptCmd", receiptCmd);

      // model.addAttribute("rshtItemCnt", attributeValue)

    } catch (AcubeCommonException me) {

      logger.error("[receiptReprint] " + me.toString(), me);
      model.addAttribute("RESULT", "FAIL");
      model.addAttribute("MESSAGE", me.toString());
    } catch (Exception e) {

      logger.error("[receiptReprint] " + e.toString(), e);
      model.addAttribute("RESULT", "FAIL");
      model.addAttribute("MESSAGE", "err.500");
    } finally {
      if (logger.isDebugEnabled()) {
        logger.debug("[receiptReprint] END");
      }
    }

    // return new ModelAndView("bsar/ar/arReceipt","data",data);
    return "bsar/ar/arReceiptReport";
  }
示例#2
0
  @SuppressWarnings({"rawtypes", "unchecked"})
  @RequestMapping(value = "/bsar/ar/arReceiptReport", method = RequestMethod.POST)
  public String receiptReportOpen(
      Model model, ReceiptCmd receiptCmd, @RequestBody OtimeVO otimeVO) {

    ObjectMapper om = new ObjectMapper();

    String temp = null;

    try {

      temp = om.defaultPrettyPrintingWriter().writeValueAsString(otimeVO);

      model.addAttribute("recpData", temp);
      // model.addAttribute("receipt",receiptService.getReceipt(receiptCmd));
      // model.addAttribute("rshtLabel",new
      // ObjectMapper().defaultPrettyPrintingWriter().writeValueAsString(receiptService.getRshtLabel(receiptCmd))
      // );

      model.addAttribute("arPymDialogName", receiptCmd.getArPymDialogName());

      model.addAttribute("callBackFunc", receiptCmd.getCallBackFunc());
      receiptCmd.setLanguage("mn");
      model.addAttribute("receiptCmd", receiptCmd);

    } catch (AcubeCommonException me) {

      logger.error("[receiptOpen] " + me.toString(), me);
      model.addAttribute("RESULT", "FAIL");
      model.addAttribute("MESSAGE", me.toString());
    } catch (Exception e) {

      logger.error("[receiptOpen] " + e.toString(), e);
      model.addAttribute("RESULT", "FAIL");
      model.addAttribute("MESSAGE", "err.500");
    } finally {
      if (logger.isDebugEnabled()) {
        logger.debug("[receiptOpen] END");
      }
    }

    // return new ModelAndView("bsar/ar/arReceipt","data",data);
    return "bsar/ar/arReceiptReport";
  }