public void Build()
        {
            Directory.CreateDirectory(HtmlPath);

            _pageBuilder = new PageBuilder(HtmlFileName, LocalPath, CreateHeader(StationLocations), "../../");

            _pageBuilder.Append(NavBarHelper.NavBar("../../"));
            AddBreadCrumb(this);

            _pageBuilder.Append("<div class='container mt-4'>");
            Jumbotron(PageTitle, StationLocations);

            string path = Constants.RawDataPath + @"Stations\GCR-Rothley\Gallery";

            Add_Gallrey(HtmlPath, HtmlPath + "images\\", path);

            _pageBuilder.Append("</div>");
            _pageBuilder.Append("</div>");

            _pageBuilder.Append(HTMLRailHelper.Modal());

            _pageBuilder.Append("<script src='../../Scripts/script.js'></script>");

            _pageBuilder.Output();
        }
Esempio n. 2
0
        public static void Build()
        {
            string localpath = Constants.RootPath + Constants.StationFolder;

            Directory.CreateDirectory(localpath);

            eWolfBootstrap.Interfaces.IPageBuilder pageBuilder = new PageBuilder("index.html", localpath, new StationsHeader(), "../");

            pageBuilder.Append(NavBarHelper.NavBar("../"));
            pageBuilder.Append("<div class='container mt-4'>");
            pageBuilder.Append(Jumbotron(null));
            pageBuilder.Append("<div class='row mb-2'>");

            AddStationLoughboroughStation(pageBuilder);
            AddBuildStationsQuornAndWoodHouse(pageBuilder);
            AddStationRothley(pageBuilder);
            AddStationLeicestershireNorth(pageBuilder);
            AddStationRushcliffeHalt(pageBuilder);

            pageBuilder.Append("</div>");
            pageBuilder.Append("</div>");

            pageBuilder.Append(HTMLRailHelper.Modal());

            pageBuilder.Append("<script src='../../Scripts/script.js'></script>");

            pageBuilder.Output();
        }
Esempio n. 3
0
        public static void Build(IModelEvent pageDetails)
        {
            GetLayoutDetails();

            string htmlpath = Constants.FullMyLayouts;

            Directory.CreateDirectory(htmlpath);

            int totalPages = (_orderedDetails.Count(x => x.Active) / DetailsPerPage);

            int pageIndex = 0;

            while (_orderedDetails.Any())
            {
                string pageIndexDisplay = NavBarHelper.GetHtmlPageName(pageIndex);

                var pageBuilder = new PageBuilder($"{pageIndexDisplay}", htmlpath, new MyLayoutHeader(), "../");

                pageBuilder.Append(NavBarHelper.NavBar("../"));

                pageBuilder.Append("<div class='container mt-4'>");

                string imageName     = Constants.DriveLetter + "Trains/_WebsiteData/Others/images/";
                string imageHtmlName = "../Others/images/";

                pageBuilder.JumbotronWithImage("<h1>Cattington</h1>",
                                               "<p'>Now it's our turn, We have just started to build our first layout." +
                                               "</br>We are Building Cattington, and we are updatd details here every week or so.</p>",
                                               imageName,
                                               imageHtmlName,
                                               "CATTINGTON.png");

                pageBuilder.Append(NavBarHelper.Pagination(pageIndex, totalPages));

                for (int i = 0; i < DetailsPerPage; i++)
                {
                    if (_orderedDetails.Any())
                    {
                        BuildDetails(pageBuilder, _orderedDetails[0]);
                        _orderedDetails.RemoveAt(0);
                    }
                }
                pageBuilder.Append(NavBarHelper.Pagination(pageIndex, totalPages));
                pageBuilder.Append("</div>");
                pageBuilder.Append(HTMLRailHelper.Modal());
                pageBuilder.Append("<script src='../Scripts/script.js'></script>");

                pageBuilder.Output();

                pageIndex++;
            }
        }
Esempio n. 4
0
        public static void BuildOld(IModelEvent pageDetails)
        {
            string htmlpath = Constants.FullMyLayouts;

            Directory.CreateDirectory(htmlpath);

            var pageBuilder = new PageBuilder("index.html", htmlpath, new MyLayoutHeader(), "../");

            pageBuilder.Append(NavBarHelper.NavBar("../"));
            pageBuilder.Append("<div class='container mt-4'>");
            pageBuilder.Jumbotron("<h1>Home layouts</h1>", "<p'>It's now our turn, I've just started to build our new layout, currently on the floor!</p>");

            GetLayoutDetails();

            pageBuilder.Append("</div>");
            pageBuilder.Append("</div>");

            pageBuilder.Append(HTMLRailHelper.Modal());

            pageBuilder.Append("<script src='../Scripts/script.js'></script>");

            pageBuilder.Output();
        }
Esempio n. 5
0
        public static void Build(IModelEvent pageDetails)
        {
            string htmlpath = Constants.FullCatalog;

            Directory.CreateDirectory(htmlpath);

            eWolfBootstrap.Interfaces.IPageBuilder pageBuilder = new PageBuilder("index.html", htmlpath, new CatalogHeader(), "../");
            pageBuilder.Append(NavBarHelper.NavBar("../"));
            pageBuilder.Append("<div class='container mt-4'>");
            pageBuilder.Append(Jumbotron(null));

            pageBuilder.Append(AddDetails(htmlpath, htmlpath + "images\\", "Wagons"));
            pageBuilder.Append(AddDetails(htmlpath, htmlpath + "images\\", "Loco"));
            pageBuilder.Append(AddDetails(htmlpath, htmlpath + "images\\", "Coach"));

            pageBuilder.Append("</div>");
            pageBuilder.Append("</div>");

            pageBuilder.Append(HTMLRailHelper.Modal());

            pageBuilder.Append("<script src='../Scripts/script.js'></script>");

            pageBuilder.Output();
        }
        public virtual void Build()
        {
            Directory.CreateDirectory(LocalPath);

            var locref = new LocoRefHeader();

            locref.Title = Title;
            locref.Keywords.Add(Title);

            locref.Keywords.AddRange(Keywords);
            locref.Keywords.Add("Photos");
            locref.Keywords.Add($"Photos of {Keywords[0]}");
            locref.Keywords.Add("Images");
            locref.Keywords.Add("reference");

            _pageBuilder = new PageBuilder(HtmlFileName, LocalPath, locref, "../../");

            _pageBuilder.Append(NavBarHelper.NavBar("../../"));
            AddBreadCrumb(this);

            _pageBuilder.Append("<div class='container mt-12'>");

            LocoRefPageBuilder.Jumbotron(_pageBuilder, Title);
            AddPageDetails();

            AddGallrey(HtmlPath + "images\\", RawImagePath);

            _pageBuilder.Append("</div>");
            _pageBuilder.Append("</div>");

            _pageBuilder.Append(HTMLRailHelper.Modal());

            _pageBuilder.Append("<script src='../../Scripts/script.js'></script>");

            _pageBuilder.Output();
        }