예제 #1
0
        private void GenerateBossFightPage(bool DEBUG_Website, bool filteredData, int uniqueRaidID, RaidBossFight interestingFight)
        {
            if (interestingFight == null)
            {
                Response.Redirect("RaidList.aspx");
            }

            var realmDB = ApplicationInstance.Instance.GetRealmDB(interestingFight.GetRaid().Realm);

            if (interestingFight != null)
            {
                //int fightDuration = timeEnd - timeStart;
                //if (fightDuration <= 0)
                //{
                //    if (timeEnd < timeStart)
                //        fightDuration = interestingFight.GetFightData().GetFightRecordDuration() - timeStart;
                //    else
                //        fightDuration = interestingFight.GetFightData().GetFightRecordDuration();
                //}
                m_BreadCrumbHTML = new MvcHtmlString(PageUtility.BreadCrumb_AddHome()
                                                     + PageUtility.BreadCrumb_AddRaidList()
                                                     + PageUtility.BreadCrumb_AddLink("RaidList.aspx?Guild=" + interestingFight.GetRaid().RaidOwnerName + "&realm=" + StaticValues.ConvertRealmParam(realmDB.Realm), interestingFight.GetRaid().RaidOwnerName)
                                                     + PageUtility.BreadCrumb_AddRaidOverview(interestingFight.GetRaid())
                                                     + PageUtility.BreadCrumb_AddFinish(interestingFight.GetBossName()));

                var raidSummary = ApplicationInstance.Instance.GetSummaryDatabase().GetRaid(uniqueRaidID);
                m_FightOverviewInfoHTML = new MvcHtmlString(FightOverviewGenerator.Generate(realmDB, raidSummary, interestingFight
                                                                                            , new FightOverviewGenerator.GenerateDetails
                {
                    FilterSpikes          = filteredData
                    , DebugInfo           = DEBUG_Website
                    , DebugBuff           = PageUtility.GetQueryString(Request, "DebugBuff", null)
                    , FilterSpikesURL     = PageUtility.CreateUrlWithNewQueryValue(Request, "Filtered", "true")
                    , NoFilterSpikesURL   = PageUtility.CreateUrlWithNewQueryValue(Request, "Filtered", "false")
                    , VersionChangeURL    = PageUtility.CreateUrlWithNewQueryValue(Request, "Version", "versionchangeid")
                    , ItemSummaryDatabase = ApplicationInstance.Instance.GetItemSummaryDatabase()
                    , GetItemInfoFunc     = ApplicationInstance.Instance.GetItemInfo
                }));
            }
            else
            {
                Response.Redirect("RaidOverview.aspx?Raid=" + uniqueRaidID);
            }
        }