public void preRender() {
    AcPageSession ps = getPageSession();
    JwDate startUtcDt = ps.getInternationalRouteBlockStartUtcDt();
    JwDate endUtcDt = ps.getInternationalRouteBlockEndUtcDt();
    AcGlobalUspsInternationalSubmissionBlock block = getBlock(startUtcDt, endUtcDt);

    Integer sourceId = ps.getInternationalRequestedRouteSourceId();
    String originAirport = ps.getInternationalRequestedRouteDetailsOriginAirportCode();
    String destinationAirport = ps.getInternationalRequestedRouteDetailsDestinationAirportCode();
    JwTime departureLocalTm = ps.getInternationalRequestedRouteDetailsDepartureLocalTm();
    JwTimestamp departureLocalTs = new JwTimestamp();
    departureLocalTs.setTime(departureLocalTm);
    JwTime arrivalLocalTm = ps.getInternationalRequestedRouteDetailsArrivalLocalTm();
    JwTimestamp arrivalLocalTs = new JwTimestamp();
    arrivalLocalTs.setTime(arrivalLocalTm);
    JwList<AcUspsInternationalRequestedRoute> v =
        getInternationalRequestedRoutes(
            sourceId,
            startUtcDt,
            endUtcDt,
            originAirport,
            destinationAirport,
            departureLocalTm,
            arrivalLocalTm);

    boolean hasBlock = block != null;
    _blockTitle.setVisible(hasBlock);
    _blockTitle.applyModel(block);
    _dateTitle.setVisible(!hasBlock);
    _dateStart.setValue(startUtcDt);
    _dateEnd.setValue(endUtcDt);

    _originAirport.setValue(originAirport);
    _destinationAirport.setValue(destinationAirport);
    _departureLocalTm.setValue(departureLocalTs);
    _arrivalLocalTm.setValue(arrivalLocalTs);

    _grid.setList(v);
  }
Ejemplo n.º 2
0
 public void preRender() {
   AcModuleConfig e = getModuleConfig();
   _name.applyModel(e);
   _module.applyModel(e);
   _createdBy.applyModel(e);
 }