예제 #1
0
        public ActionResult AllUnverified()
        {
            var model = new SpeedListModel
            {
                SpeedList = DocumentSession.Query <SpeedReadModel>().Where(speed => !speed.IsVerified).ToList()
            };

            return(View("UnverifiedIndex", model));
        }
예제 #2
0
        public AircraftModel(AircraftReadModel readModel)
        {
            ReadModel = readModel;

            SpeedList = new SpeedListModel
            {
                SpeedList = readModel.AllVerifiedSpeeds
                            .Select(summary => new SpeedReadModel
                {
                    Id   = summary.SpeedId,
                    Date = summary.Date,
                    SpeedInMilesPerHour = summary.SpeedInMilesPerHour,
                    AircraftName        = readModel.AircraftName,
                    PilotName           = summary.PilotName,
                    SiteName            = summary.SiteName,
                    SiteLocation        = summary.SiteLocation,
                    SiteCountryName     = summary.SiteCountryName,
                    IsVerified          = true
                }).ToList()
            };
        }