Package org.projectforge.core

Examples of org.projectforge.core.MessageParam


  @SuppressWarnings("unchecked")
  @Override
  protected void onSaveOrModify(final ContractDO obj)
  {
    if (obj.getNumber() == null) {
      throw new UserException("validation.required.valueNotPresent", new MessageParam("legalAffaires.contract.number",
          MessageParamType.I18N_KEY));
    }
    if (obj.getId() == null) {
      // New contract
      final Integer next = getNextNumber(obj);
View Full Code Here


      final TimesheetDO ts = list.get(0);
      if (throwException == true) {
        log.info("Time sheet collision detected of time sheet " + timesheet + " with existing time sheet " + ts);
        final String startTime = DateHelper.formatIsoTimestamp(ts.getStartTime());
        final String stopTime = DateHelper.formatIsoTimestamp(ts.getStopTime());
        throw new UserException("timesheet.error.timeperiodOverlapDetection", new MessageParam(ts.getId()), new MessageParam(startTime),
            new MessageParam(stopTime));
      }
      return true;
    }
    return false;
  }
View Full Code Here

  @SuppressWarnings("unchecked")
  @Override
  protected void onSaveOrModify(final AuftragDO obj)
  {
    if (obj.getNummer() == null) {
      throw new UserException("validation.required.valueNotPresent", new MessageParam("fibu.auftrag.nummer", MessageParamType.I18N_KEY));
    }
    if (obj.getId() == null) {
      // Neuer Auftrag/Angebot
      final Integer next = getNextNumber(obj);
      if (next.intValue() != obj.getNummer().intValue()) {
View Full Code Here

      if (obj.getNummer() != null) {
        throw new UserException("fibu.rechnung.error.gutschriftsanzeigeDarfKeineRechnungsnummerHaben");
      }
    } else {
      if (obj.getNummer() == null) {
        throw new UserException("validation.required.valueNotPresent", new MessageParam("fibu.rechnung.nummer", MessageParamType.I18N_KEY));
      }
      if (obj.getId() == null) {
        // Neue Rechnung
        final Integer next = getNextNumber(obj);
        if (next.intValue() != obj.getNummer().intValue()) {
View Full Code Here

  {
    super(I18N_KEY_STANDARD);
    this.user = user;
    this.accessType = accessType;
    this.operationType = operationType;
    this.msgParams =  new MessageParam[] { new MessageParam(accessType), new MessageParam(operationType) };
    log.info("AccessException: " + this);
  }
View Full Code Here

    super(I18N_KEY_STANDARD_WITH_TASK);
    this.user = user;
    this.taskId = taskId;
    this.accessType = accessType;
    this.operationType = operationType;
    this.msgParams =  new MessageParam[] { new MessageParam(taskId), new MessageParam(accessType), new MessageParam(operationType) };
    log.info("AccessException: " + this);
  }
View Full Code Here

  {
    final MessageParam[] result = new MessageParam[3];
    if (taskTree != null && this.taskId != null) {
      final TaskDO task = taskTree.getTaskById(taskId);
      if (task != null) {
        result[0] = new MessageParam(task.getTitle());
      } else {
        result[0] = new MessageParam(taskId);
      }
    } else {
      result[0] = new MessageParam(taskId);
    }
    if (accessType != null) {
      result[1] = new MessageParam(accessType.getI18nKey(), MessageParamType.I18N_KEY);
    }
    if (operationType != null) {
      result[2] = new MessageParam(operationType.getI18nKey(), MessageParamType.I18N_KEY);
    }
    return result;
  }
View Full Code Here

TOP

Related Classes of org.projectforge.core.MessageParam

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.