Package org.qi4j.sample.dcicargo.sample_a.infrastructure.wicket.color

Examples of org.qi4j.sample.dcicargo.sample_a.infrastructure.wicket.color.ErrorColor


                    item.add( new Label( "loadTime", new Model<Date>( leg.loadTime().get() ) ) );
                    item.add( new Label( "voyage", leg.voyage().get().voyageNumber().get().number().get() ) );

                    Boolean isMisrouted = routingStatus == RoutingStatus.MISROUTED && item.getIndex() == ( getList().size() - 1 );
                    item.add( new Label( "unloadLocation", leg.unloadLocation().get().getCode() )
                                  .add( new ErrorColor( isMisrouted ) ) );

                    item.add( new Label( "unloadTime", new Model<Date>( leg.unloadTime().get() ) ) );
                }
            } );
        }
View Full Code Here


                {
                    map.put( "voyage", event.voyage().get().voyageNumber().get().number().get() );
                }
                IModel text = new StringResourceModel( "handlingEvent.${type}", this, new Model<ValueMap>( map ) );
                item.add( new Label( "event", text )
                              .add( new ErrorColor( isLast && isMisdirected ) )
                              .setEscapeModelStrings( false ) );
            }
        } );
    }
View Full Code Here

                item.add( new Label( "deadline", new Model<Date>( cargo.routeSpecification()
                                                                      .get()
                                                                      .arrivalDeadline()
                                                                      .get() ) ) );

                item.add( new Label( "routingStatus", routingStatus.toString() ).add( new ErrorColor( routingStatus == RoutingStatus.MISROUTED ) ) );

                Boolean inCustoms = delivery.lastHandlingEvent().get() != null
                                    && delivery.lastHandlingEvent()
                                           .get()
                                           .handlingEventType()
                                           .get() == HandlingEventType.CUSTOMS;
                String customsLabel = delivery.transportStatus().get().name() + ( inCustoms ? " (CUSTOMS)" : "" );
                item.add( new Label( "transportStatus", customsLabel ) );

                IModel directed = new Model<String>( delivery.isMisdirected().get() ? "Misdirected" : "On track" );
                item.add( new Label( "deliveryStatus", directed ).add( new ErrorColor( delivery.isMisdirected()
                                                                                           .get() ) ) );
            }
        } );
    }
View Full Code Here

        add( new Label( "origin", cargo.origin().get().getString() ) );
        add( new Label( "destination", routeSpecification.destination()
            .get()
            .getString() ).add( new CorrectColor( isMisrouted ) ) );
        add( new Label( "deadline", Model.of( routeSpecification.arrivalDeadline().get() ) ) );
        add( new Label( "routingStatus", routingStatus.toString() ).add( new ErrorColor( isMisrouted ) ) );
        add( new LinkPanel( "changeDestination", ChangeDestinationPage.class, trackingId, "Change destination" ) );

        if( routingStatus == RoutingStatus.NOT_ROUTED )
        {
            add( new LinkPanel( "routingAction", RouteCargoPage.class, trackingId, "Route" ) );
View Full Code Here

TOP

Related Classes of org.qi4j.sample.dcicargo.sample_a.infrastructure.wicket.color.ErrorColor

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.