From 6d7e886e8c3cc4f3ea1a903a1e220232bf95514c Mon Sep 17 00:00:00 2001 From: "kay.one" Date: Wed, 29 Feb 2012 00:25:41 -0800 Subject: [PATCH] Minor CSS update --- .../ProviderTests/EpisodeProviderTest.cs | 2 +- .../ProviderTests/SeriesProviderTest.cs | 12 ++++++----- NzbDrone.Core/Providers/SeriesProvider.cs | 3 ++- NzbDrone.Web/Content/Grid.css | 19 ++++++++---------- NzbDrone.Web/Content/Menu.css | 2 +- .../Controllers/AddSeriesController.cs | 2 +- NzbDrone.Web/Views/Series/Details.cshtml | 4 ++++ NzbDrone.Web/Views/Series/Index.cshtml | 20 +++---------------- 8 files changed, 27 insertions(+), 37 deletions(-) diff --git a/NzbDrone.Core.Test/ProviderTests/EpisodeProviderTest.cs b/NzbDrone.Core.Test/ProviderTests/EpisodeProviderTest.cs index edc90d3ae..51699f75b 100644 --- a/NzbDrone.Core.Test/ProviderTests/EpisodeProviderTest.cs +++ b/NzbDrone.Core.Test/ProviderTests/EpisodeProviderTest.cs @@ -728,7 +728,7 @@ public void Add_daily_show_episodes() //act var seriesProvider = Mocker.Resolve(); - seriesProvider.AddSeries("c:\\test\\", tvDbSeriesId, 1); + seriesProvider.AddSeries("Test Series","c:\\test\\", tvDbSeriesId, 1); var episodeProvider = Mocker.Resolve(); episodeProvider.RefreshEpisodeInfo(seriesProvider.GetSeries(tvDbSeriesId)); diff --git a/NzbDrone.Core.Test/ProviderTests/SeriesProviderTest.cs b/NzbDrone.Core.Test/ProviderTests/SeriesProviderTest.cs index be827fee0..a003c773e 100644 --- a/NzbDrone.Core.Test/ProviderTests/SeriesProviderTest.cs +++ b/NzbDrone.Core.Test/ProviderTests/SeriesProviderTest.cs @@ -30,12 +30,13 @@ public void Add_new_series(bool useSeasonFolder) Db.InsertMany(fakeProfiles); const string path = "C:\\Test\\"; + const string title = "Test Title"; const int tvDbId = 1234; const int qualityProfileId = 2; //Act var seriesProvider = Mocker.Resolve(); - seriesProvider.AddSeries(path, tvDbId, qualityProfileId); + seriesProvider.AddSeries(title, path, tvDbId, qualityProfileId); //Assert var series = seriesProvider.GetAllSeries(); @@ -43,6 +44,7 @@ public void Add_new_series(bool useSeasonFolder) Assert.AreEqual(path, series.First().Path); Assert.AreEqual(tvDbId, series.First().SeriesId); Assert.AreEqual(qualityProfileId, series.First().QualityProfileId); + Assert.AreEqual(title, series.First().Title); series.First().SeasonFolder.Should().Be(useSeasonFolder); } @@ -52,7 +54,7 @@ public void Add_new_series(bool useSeasonFolder) public void add_series_should_fail_if_series_is_less_than_zero(int seriesId) { WithRealDb(); - Assert.Throws(() => Mocker.Resolve().AddSeries("C:\\Test", seriesId, 1)); + Assert.Throws(() => Mocker.Resolve().AddSeries("Title", "C:\\Test", seriesId, 1)); } [Test] @@ -823,11 +825,11 @@ public void delete_series_should_delete_all_rows_related_to_the_series() { var fakeSeries = Builder.CreateListOfSize(3).Build(); var fakeEpisodes = Builder.CreateListOfSize(30) - .TheFirst(10).With(c=>c.SeriesId = fakeSeries[0].SeriesId) - .TheNext(10).With(c=>c.SeriesId = fakeSeries[1].SeriesId) + .TheFirst(10).With(c => c.SeriesId = fakeSeries[0].SeriesId) + .TheNext(10).With(c => c.SeriesId = fakeSeries[1].SeriesId) .TheNext(10).With(c => c.SeriesId = fakeSeries[2].SeriesId) .Build(); - + } diff --git a/NzbDrone.Core/Providers/SeriesProvider.cs b/NzbDrone.Core/Providers/SeriesProvider.cs index 2618bf8a1..78e7a9538 100644 --- a/NzbDrone.Core/Providers/SeriesProvider.cs +++ b/NzbDrone.Core/Providers/SeriesProvider.cs @@ -103,7 +103,7 @@ public virtual Series UpdateSeriesInfo(int seriesId) return series; } - public virtual void AddSeries(string path, int tvDbSeriesId, int qualityProfileId) + public virtual void AddSeries(string title, string path, int tvDbSeriesId, int qualityProfileId) { Logger.Info("Adding Series [{0}] Path: [{1}]", tvDbSeriesId, path); @@ -117,6 +117,7 @@ public virtual void AddSeries(string path, int tvDbSeriesId, int qualityProfileI repoSeries.Path = path; repoSeries.Monitored = true; //New shows should be monitored repoSeries.QualityProfileId = qualityProfileId; + repoSeries.Title = title; if (qualityProfileId == 0) repoSeries.QualityProfileId = _configProvider.DefaultQualityProfile; diff --git a/NzbDrone.Web/Content/Grid.css b/NzbDrone.Web/Content/Grid.css index 855e20f71..168587d17 100644 --- a/NzbDrone.Web/Content/Grid.css +++ b/NzbDrone.Web/Content/Grid.css @@ -13,10 +13,6 @@ cursor: pointer; } -.statusImage:hover { - background-color: white; -} - /* Custom Grid */ .seriesTable { @@ -45,15 +41,15 @@ padding: 0px 8px 0px 8px; } -.title-row +.title-row td { font-family: "Segoe UI Light" , "Open Sans" , "Segoe UI" , sans-serif; - font-size: 17px; - background-color: grey; + font-size: 20px; + background-color: #F1EDED; font-weight: lighter; - color: white; + color: #3C3C3C; } - + .detail-row { display: none; @@ -68,14 +64,15 @@ /* Episode Grid Row Colouring */ .episodeIgnored { - background: lightgray; + background: rgb(229, 228, 228); + opacity: 0.7; } .episodeMissing { - background-color: #f5c5c5; + background-color: #f5d6d6; } /*Hidden Grid to prevent FOUSC*/ diff --git a/NzbDrone.Web/Content/Menu.css b/NzbDrone.Web/Content/Menu.css index 9fb8949a0..2f3ea6e92 100644 --- a/NzbDrone.Web/Content/Menu.css +++ b/NzbDrone.Web/Content/Menu.css @@ -11,7 +11,7 @@ margin-right: 12px; padding-left: 2px; padding-top: 2px; - border-left: 1px solid #065EFE; + border-left: 7px solid #F1EDED; } .sub-menu a diff --git a/NzbDrone.Web/Controllers/AddSeriesController.cs b/NzbDrone.Web/Controllers/AddSeriesController.cs index f49ab9f16..6d85dc521 100644 --- a/NzbDrone.Web/Controllers/AddSeriesController.cs +++ b/NzbDrone.Web/Controllers/AddSeriesController.cs @@ -124,7 +124,7 @@ public JsonResult AddExistingSeries(string path, string seriesName, int seriesId if (seriesId == 0 || String.IsNullOrWhiteSpace(seriesName)) return JsonNotificationResult.Error("Add Existing series failed.", "Invalid Series information"); - _seriesProvider.AddSeries(path, seriesId, qualityProfileId); + _seriesProvider.AddSeries(seriesName,path, seriesId, qualityProfileId); ScanNewSeries(); return JsonNotificationResult.Info(seriesName, "Was added successfully"); diff --git a/NzbDrone.Web/Views/Series/Details.cshtml b/NzbDrone.Web/Views/Series/Details.cshtml index 39eaf8e1d..87e8cf0b1 100644 --- a/NzbDrone.Web/Views/Series/Details.cshtml +++ b/NzbDrone.Web/Views/Series/Details.cshtml @@ -33,6 +33,10 @@ text-decoration: none; } + .seasonToggleLabel:hover { + color: #065EFE; + } + .seasonToggleTop .ignoredEpisodesMaster { padding-left: 0px; diff --git a/NzbDrone.Web/Views/Series/Index.cshtml b/NzbDrone.Web/Views/Series/Index.cshtml index 1365b3bc0..ca2515d0f 100644 --- a/NzbDrone.Web/Views/Series/Index.cshtml +++ b/NzbDrone.Web/Views/Series/Index.cshtml @@ -46,21 +46,7 @@ { height: 28px; } - - .editButton, .deleteButton - { - width: 18px; - height: 18px; - padding: 3px 1px; - margin: 0px; - vertical-align: middle; - } - - .editButton:hover, .deleteButton:hover - { - background-color: #065EFE; - } - + .commandsColumn, .statusColumn { text-align: center; @@ -192,8 +178,8 @@ } }, //Episodes { sWidth: '50px', "mDataProp": "HasBanner", "bSortable": false, "fnRender": function (row) { - return "" + - ""; + return "" + + ""; } }, //Commands { sWidth: '60px', "mDataProp": "Details", "bSortable": false, "bVisible": false, "fnRender": function (row) {