/**
   * 初始化
   *
   * @param user
   * @param dto
   * @param conn
   */
  private void init(SfUserDTO user, UrgentDTO dto, Connection conn) {
    this.userAccount = user;
    this.conn = conn;
    this.leaseDTO = dto;

    this.lines = leaseDTO.getLines();
    this.headerDTO = leaseDTO.getHeaderDTO();
    this.headerDAO = new UrgentDAO(user, headerDTO, conn);
  }
  /**
   * 取头信息
   *
   * @throws QueryException
   */
  protected void prodHeader() throws QueryException {
    headerDAO.setDTOClassName(UrgentHeaderDTO.class.getName());
    headerDAO.setCalPattern(CalendarConstant.LINE_PATTERN);

    UrgentHeaderDTO tmpDTO = (UrgentHeaderDTO) headerDTO.clone();

    headerDTO = (UrgentHeaderDTO) headerDAO.getDataByPrimaryKey();
    // 当新建时候
    if (null == headerDTO || StrUtil.isEmpty(headerDTO.getTransId())) {
      headerDTO = new UrgentHeaderDTO();
      headerDTO = initHeaderData(headerDTO);
    }
    headerDTO.setSf_task_attribute3(tmpDTO.getSf_task_attribute3());

    leaseDTO.setHeaderDTO(headerDTO);
  }
 public void setForm(UrgentDTO leaseDTO) {
   this.leaseDTO = leaseDTO;
   this.lines = leaseDTO.getLines();
   this.headerDTO = leaseDTO.getHeaderDTO();
   this.headerDAO = new UrgentDAO(userAccount, headerDTO, conn);
 }
 public UrgentDTO getForm() {
   leaseDTO.setHeaderDTO(headerDTO);
   leaseDTO.setLines(lines);
   return leaseDTO;
 }
 /**
  * 取行信息
  *
  * @throws QueryException
  */
 protected void prodLines() throws QueryException {
   lines = headerDAO.getLinesData(headerDTO.getTransId());
   leaseDTO.setLines(lines);
 }