Esempio n. 1
0
  @Override
  protected String doCheck(BusiActionParamVO<T> param) throws BusinessException {
    String commonError = commonCheck(param);
    if (commonError != null) return commonError;

    ActionVO actionVO = param.getLastActionVO();
    // 校验票据动作
    if (!(actionVO.getActioncode().equals(FbmActionConstant.AUDIT)
        && actionVO.getBilltype().equals(FbmBusConstant.BILLTYPE_GATHER)
        && actionVO.getPk_bill().equals(param.getPk_bill()))) {
      return nc.vo.ml.NCLangRes4VoTransl.getNCLangRes()
              .getStrByID("fbmcomm", "UPPFBMComm-000239") /* @res"票据"*/
          + param.getBaseinfoVO().getFbmbillno()
          + nc.vo.ml.NCLangRes4VoTransl.getNCLangRes()
              .getStrByID("fbmcomm", "UPPFBMComm-000263") /* @res"的前一操作必须是审核收票登记单。"*/
          + BusiMessageTranslator.translateAction(param);
    }
    return null;
  }
Esempio n. 2
0
  /**
   * 组装后台需要的RegisterVO
   *
   * @param param
   * @param oldVO
   * @return
   * @throws BusinessException
   */
  private RegisterVO getNewVO(BusiActionParamVO<T> param) throws BusinessException {
    RegisterVO vo = new RegisterVO();

    RegisterVO oldVO = param.getRegisterVO();
    ReliefVO reliefVO = param.getSuperVO();

    vo.setPk_baseinfo(param.getPk_baseinfo());
    vo.setPk_billtypecode(FbmBusConstant.BILLTYPE_GATHER);
    vo.setGatherdate(param.getActiondate());
    vo.setGathertype(FbmBusConstant.GATHER_TYPE_RELIEF); // 调剂来源
    vo.setPk_source(param.getPk_bill()); // 来源单据:调剂出库单
    vo.setPaybillunit(
        dao.queryCustByCorp(InvocationInfoProxy.getInstance().getCorpCode())); // 付票单位为当前登陆的公司
    vo.setHoldunit(reliefVO.getReliefunit()); // 持票单位
    vo.setMoneyy(oldVO.getMoneyy());
    vo.setFrate(oldVO.getFrate());
    vo.setBrate(oldVO.getBrate());
    vo.setMoneyb(oldVO.getMoneyb());
    vo.setMoneyf(oldVO.getMoneyf());
    vo.setKeepunit(
        dao.queryCustByCorp(InvocationInfoProxy.getInstance().getCorpCode())); // 持票单位同付票单位,取中心
    vo.setIsnewbill(UFBoolean.FALSE);
    vo.setSfflag(UFBoolean.FALSE);
    vo.setIsverify(UFBoolean.FALSE);
    vo.setNote("");
    vo.setPk_corp(dao.queryCorpByCust(reliefVO.getReliefunit())); // 根据客商取公司
    vo.setVbillno(
        new HYPubBO().getBillNo(FbmBusConstant.BILLTYPE_GATHER, vo.getPk_corp(), null, null));
    /** ************************************************ */
    vo.setSfflag(UFBoolean.TRUE); // 收付款标志,默认打上true
    /** ************************************************ */
    vo.setVoperatorid(param.getActionperson());
    vo.setDoperatedate(param.getActiondate());
    vo.setVapproveid(param.getActionperson());
    vo.setDapprovedate(param.getActiondate());
    vo.setVapprovenote("");

    return vo;
  }