1
0
Fork 0
mirror of https://github.com/Sonarr/Sonarr synced 2024-12-25 01:06:30 +00:00

Fixed doctype,

removed telerik script/css registrar
This commit is contained in:
kay.one 2011-06-27 18:23:22 -07:00
parent b98aab87ae
commit 3d961654d8
5 changed files with 96 additions and 90 deletions

View file

@ -95,61 +95,63 @@ Series
Loading...</span>
</div>
}
<script type="text/javascript">
var windowElement;
function grid_edit(args) {
$(args.form)
@section Scripts{
<script type="text/javascript">
var windowElement;
function grid_edit(args) {
$(args.form)
.closest(".t-window")
.data("tWindow")
.center();
var seriesId = args.dataItem.SeriesId;
var url = '@Url.Action("SeasonEditor", "Series")';
$('#season-editor').load(url, { seriesId: seriesId }, function (response, status, xhr) {
$('#seasonEditorLoader').hide();
});
}
function grid_save(e) {
$('#ajaxSaveWheel').show();
var seasonEditor = e.form.SeasonEditor_collection;
var saveSeasonEditUrl = '@Url.Action("SaveSeason", "Series")';
jQuery.each(seasonEditor, function () {
var guid = $(this).val();
var prefix = '#SeasonEditor_' + guid + '__';
var seriesId = $(prefix + 'SeriesId').val();
var seasonNumber = $(prefix + 'SeasonNumber').val();
var monitored = $(prefix + 'Monitored').attr('checked');
$.ajax({
type: "POST",
url: saveSeasonEditUrl,
data: jQuery.param({ seriesId: seriesId, seasonNumber: seasonNumber, monitored: monitored }),
error: function (req, status, error) {
alert("Sorry! We could save season changes at this time. " + error);
},
success: function (data, textStatus, jqXHR) { }
var seriesId = args.dataItem.SeriesId;
var url = '@Url.Action("SeasonEditor", "Series")';
$('#season-editor').load(url, { seriesId: seriesId }, function (response, status, xhr) {
$('#seasonEditorLoader').hide();
});
});
}
}
function grid_rowBound(e) {
var dataItem = e.dataItem;
var seriesId = dataItem.SeriesId;
var episodeCount = dataItem.EpisodeCount;
var episodeFileCount = dataItem.EpisodeFileCount;
function grid_save(e) {
$('#ajaxSaveWheel').show();
$("#progressbar_" + seriesId).episodeProgress(episodeFileCount, episodeCount);
}
</script>
<script type="text/javascript" src="../../Scripts/doTimeout.js"></script>
<script type="text/javascript">
(function ($) {
$.fn.episodeProgress = function (episodes, totalEpisodes) {
return this.each(
var seasonEditor = e.form.SeasonEditor_collection;
var saveSeasonEditUrl = '@Url.Action("SaveSeason", "Series")';
jQuery.each(seasonEditor, function () {
var guid = $(this).val();
var prefix = '#SeasonEditor_' + guid + '__';
var seriesId = $(prefix + 'SeriesId').val();
var seasonNumber = $(prefix + 'SeasonNumber').val();
var monitored = $(prefix + 'Monitored').attr('checked');
$.ajax({
type: "POST",
url: saveSeasonEditUrl,
data: jQuery.param({ seriesId: seriesId, seasonNumber: seasonNumber, monitored: monitored }),
error: function (req, status, error) {
alert("Sorry! We could save season changes at this time. " + error);
},
success: function (data, textStatus, jqXHR) { }
});
});
}
function grid_rowBound(e) {
var dataItem = e.dataItem;
var seriesId = dataItem.SeriesId;
var episodeCount = dataItem.EpisodeCount;
var episodeFileCount = dataItem.EpisodeFileCount;
$("#progressbar_" + seriesId).episodeProgress(episodeFileCount, episodeCount);
}
</script>
<script type="text/javascript" src="../../Scripts/doTimeout.js"></script>
<script type="text/javascript">
(function ($) {
$.fn.episodeProgress = function (episodes, totalEpisodes) {
return this.each(
function () {
var div = $(this);
var progressBar = div.find(".progress");
@ -159,6 +161,7 @@ Series
progressBar.css("width", width + "%");
div.find(".progressText").html(episodes + " / " + totalEpisodes);
});
};
})(jQuery);
</script>
};
})(jQuery);
</script>
}

View file

@ -1,18 +1,2 @@
<script type="text/javascript">
jQuery(document).ready(function () {
document.getElementById('syncTimer').style.display = 'inline'; //Show the timer after the page loads, prevents FOUC (Flash of Unstyled Content)
$('#syncTimer').tgcCountdown({
counter: '<div style="color: #065EFE;">[H]:[M]:[S]</div>',
counter_warning: '<div style="color: #065EFE;">[H]:[M]:[S]</div>',
counter_expired: '<div style="color: #FFFFFF;">00:00:00</div>',
interval: 1000,
warnonminutesleft: 1
});
});
</script>
@*<div>RSS Sync: <span style="display:none" id="syncTimer" class="timer"><@ViewData["RssTimer"]</span></div>*@
<div>RSS Sync: </div>
<div>RSS Sync: </div>
<div style="display:none" id="syncTimer" class="timer">@ViewData["RssTimer"]</div>

View file

@ -1,8 +1,10 @@
@using Helpers;
<html lang="en-US" xmlns="http://www.w3.org/1999/xhtml">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
@using Helpers;
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<link rel="SHORTCUT ICON" href="../../favicon.ico" />
<title>NZBDrone</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
@MvcMiniProfiler.MiniProfiler.RenderIncludes()
<link href="/Content/Blueprint/screen.css" rel="stylesheet" type="text/css" />
<link href="/Content/Blueprint/ie.css" rel="stylesheet" type="text/css" />
@ -49,23 +51,40 @@
<div id="msgBox">
<span id="msgText">Scanning Series Folder...</span>
</div>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/jquery-ui.min.js" />
<script type="text/javascript" src="http://ajax.aspnetcdn.com/ajax/4.0/1/MicrosoftAjax.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.common.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.textbox.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.grid.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.grid.filtering.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.grid.grouping.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.tabstrip.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.panelbar.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.list.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.combobox.min.js" />
<script type="text/javascript" src="http://aspnet-scripts.telerikstatic.com/mvcz/2011.1.414/telerik.menu.min.js" />
<script type="text/javascript" src="/Scripts/jquery-tgc-countdown-1.0.js" />
<script type="text/javascript" src="/Scripts/jquery.form.js" />
<script type="text/javascript" src="/Scripts/jquery.jgrowl.js" />
<script type="text/javascript" src="/Scripts/Notification.js" />
<script type="text/javascript" src="/Scripts/MicrosoftMvcValidation.js" />
<script type="text/javascript" src="/Scripts/episodeSearch.js" />
<script type="text/javascript">
jQuery(document).ready(function () {
document.getElementById('syncTimer').style.display = 'inline'; //Show the timer after the page loads, prevents FOUC (Flash of Unstyled Content)
$('#syncTimer').tgcCountdown({
counter: '<div style="color: #065EFE;">[H]:[M]:[S]</div>',
counter_warning: '<div style="color: #065EFE;">[H]:[M]:[S]</div>',
counter_expired: '<div style="color: #FFFFFF;">00:00:00</div>',
interval: 1000,
warnonminutesleft: 1
});
});
</script>
@RenderSection("Scripts", required: false)
</body>
@RenderSection("Scripts", required: false)
@{Html.Telerik().ScriptRegistrar().jQuery(true).Scripts(
c => c.AddGroup("CDN", group => group
.Add("http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/jquery-ui.min.js")
.Add("http://ajax.aspnetcdn.com/ajax/4.0/1/MicrosoftAjax.js"))
.AddGroup("3rdParty", group => group
.Add("jquery.form.js")
.Add("jquery.jgrowl.js")
.Add("jquery-tgc-countdown-1.0.js")
.Add("MicrosoftMvcValidation.js").Combined(true).Compress(true))
.AddGroup("NzbDrone", group => group
.Add("Notification.js")
.Add("gridLoad.js")
.Add("episodeSearch.js"))
).Render();}
</html>

View file

@ -25,7 +25,7 @@ Configuration
columns.Command(commands =>
{
commands.Edit().ButtonType(GridButtonType.Image);
}).Width(0).Title("Actions");
}).Width(90).Title("Actions");
})
.Editable(editing => editing.Mode(GridEditMode.InLine))
.Sortable()

View file

@ -4,6 +4,6 @@
<supportedRuntime version="v4.0" />
</startup>
<appSettings>
<add key="port" value="8989" />
<add key="port" value="8980" />
</appSettings>
</configuration>