mirror of
https://github.com/Radarr/Radarr.git
synced 2024-11-04 10:02:40 +01:00
updated more functional element classes to use the x- notation.
This commit is contained in:
parent
30a049e4fb
commit
bb024d6203
@ -201,7 +201,6 @@
|
||||
<Content Include="_backboneApp\Quality\qualityProfileCollection.js" />
|
||||
<Content Include="_backboneApp\Quality\qualityTypeModel.js" />
|
||||
<Content Include="_backboneApp\Quality\qualityTypeCollection.js" />
|
||||
<Content Include="_backboneApp\nzbdrone.logging.js" />
|
||||
<Content Include="_backboneApp\JsLibraries\backbone.marionette.extend.js" />
|
||||
<Compile Include="_backboneApp\CassetteConfiguration.cs" />
|
||||
<Compile Include="Controllers\ImageController.cs" />
|
||||
|
@ -15,17 +15,16 @@ NzbDrone.AddSeries.AddSeriesLayout = Backbone.Marionette.Layout.extend({
|
||||
},
|
||||
|
||||
ui: {
|
||||
addNewTab: ".nav-tabs a[href='#add-new']",
|
||||
importTab: ".nav-tabs a[href='#import-existing']",
|
||||
rootDirTab: ".nav-tabs a[href='#root-folders']",
|
||||
rootTabRequiredMessage: "",
|
||||
addNewTab: ".x-add-new-tab",
|
||||
importExistingTab: ".x-import-existing-tab",
|
||||
rootFoldersTab: ".x-root-folders-tab",
|
||||
},
|
||||
|
||||
|
||||
events: {
|
||||
"click .nav-tabs a[href='#add-new']": 'showAddNew',
|
||||
"click .nav-tabs a[href='#import-existing']": 'showImport',
|
||||
"click .nav-tabs a[href='#root-folders']": 'showRootFolders',
|
||||
"click .x-add-new-tab": 'showAddNew',
|
||||
"click .x-import-existing-tab": 'showImport',
|
||||
"click .x-root-folders-tab": 'showRootFolders',
|
||||
},
|
||||
|
||||
showAddNew: function (e) {
|
||||
@ -39,14 +38,14 @@ NzbDrone.AddSeries.AddSeriesLayout = Backbone.Marionette.Layout.extend({
|
||||
showImport: function (e) {
|
||||
if (e) e.preventDefault();
|
||||
|
||||
this.ui.importTab.tab('show');
|
||||
this.ui.importExistingTab.tab('show');
|
||||
NzbDrone.Router.navigate('series/add/import');
|
||||
},
|
||||
|
||||
showRootFolders: function (e) {
|
||||
if (e) e.preventDefault();
|
||||
|
||||
this.ui.rootDirTab.tab('show');
|
||||
this.ui.rootFoldersTab.tab('show');
|
||||
NzbDrone.Router.navigate('series/add/rootfolders');
|
||||
},
|
||||
|
||||
@ -93,11 +92,11 @@ NzbDrone.AddSeries.AddSeriesLayout = Backbone.Marionette.Layout.extend({
|
||||
evaluateActions: function () {
|
||||
if (this.rootFolderCollection.length == 0) {
|
||||
this.ui.addNewTab.hide();
|
||||
this.ui.importTab.hide();
|
||||
this.ui.importExistingTab.hide();
|
||||
this.showRootFolders();
|
||||
} else {
|
||||
this.ui.addNewTab.show();
|
||||
this.ui.importTab.show();
|
||||
this.ui.importExistingTab.show();
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -3,6 +3,6 @@
|
||||
<span name="freeSpaceString"></span>
|
||||
</td>
|
||||
<td class="span1 nz-row-action">
|
||||
<div id="remove-dir" class="btn btn-danger icon-minus">
|
||||
<div class="btn btn-danger icon-minus x-remove">
|
||||
</div>
|
||||
</td>
|
||||
|
@ -1,8 +1,8 @@
|
||||
<div class="tab-pane" id="root-dir">
|
||||
<div class="input-prepend input-append nz-input-large path">
|
||||
<div class="input-prepend input-append nz-input-large x-path">
|
||||
<i class="add-on icon-folder-open"></i>
|
||||
<input type="text" class="span10" placeholder="Path of the folder to add ...">
|
||||
<div id="add-dir" class="btn icon-plus btn-success" />
|
||||
<div class="btn icon-plus btn-success x-add" />
|
||||
</div>
|
||||
<div class="span15 offset2 result-list" id="current-dirs" />
|
||||
</div>
|
||||
|
@ -8,14 +8,14 @@ NzbDrone.AddSeries.RootDirItemView = Backbone.Marionette.ItemView.extend({
|
||||
tagName: 'tr',
|
||||
|
||||
events: {
|
||||
'click #remove-dir': 'removeDir',
|
||||
'click .x-remove': 'removeFolder',
|
||||
},
|
||||
|
||||
onRender: function () {
|
||||
NzbDrone.ModelBinder.bind(this.model, this.el);
|
||||
},
|
||||
|
||||
removeDir: function () {
|
||||
removeFolder: function () {
|
||||
this.model.destroy({ wait: true });
|
||||
this.model.collection.remove(this.model);
|
||||
},
|
||||
@ -34,7 +34,7 @@ NzbDrone.AddSeries.RootDirView = Backbone.Marionette.Layout.extend({
|
||||
route: "series/add/rootdir",
|
||||
|
||||
ui: {
|
||||
pathInput: '.path input'
|
||||
pathInput: '.x-path input'
|
||||
},
|
||||
|
||||
regions: {
|
||||
@ -42,37 +42,20 @@ NzbDrone.AddSeries.RootDirView = Backbone.Marionette.Layout.extend({
|
||||
},
|
||||
|
||||
events: {
|
||||
'click #add-dir': 'addDir',
|
||||
},
|
||||
|
||||
shortcuts: {
|
||||
'enter': 'addDir'
|
||||
'click .x-add': 'addFolder',
|
||||
},
|
||||
|
||||
|
||||
collection: new NzbDrone.AddSeries.RootDirCollection(),
|
||||
|
||||
onRender: function () {
|
||||
var self = this;
|
||||
|
||||
//NzbDrone.Router.navigate(this.route, { trigger: true });
|
||||
|
||||
/*
|
||||
this.ui.seriesSearch
|
||||
.data('timeout', null)
|
||||
.keyup(function () {
|
||||
clearTimeout(self.$el.data('timeout'));
|
||||
self.$el.data('timeout', setTimeout(self.search, 500, self));
|
||||
});
|
||||
*/
|
||||
|
||||
this.currentDirs.show(new NzbDrone.AddSeries.RootDirListView({ collection: this.collection }));
|
||||
|
||||
this.collection.fetch();
|
||||
},
|
||||
|
||||
|
||||
addDir: function () {
|
||||
addFolder: function () {
|
||||
var newDir = new NzbDrone.AddSeries.RootDirModel(
|
||||
{
|
||||
Path: this.ui.pathInput.val()
|
||||
|
@ -21,9 +21,8 @@
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.result-list .well:hover {
|
||||
.result-list .accordion-heading:hover {
|
||||
background-color: #fcf8e3;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
|
||||
@ -33,6 +32,10 @@
|
||||
padding-left: 10px;
|
||||
}
|
||||
|
||||
.search-item .accordion-body .in {
|
||||
background-color: #fcf8e3;
|
||||
}
|
||||
|
||||
.result-list .result-item a {
|
||||
font-size: 20px;
|
||||
}
|
||||
|
@ -2,9 +2,9 @@
|
||||
<strong>Heads up!</strong> you need to add at least one TV folder.
|
||||
</div>-->
|
||||
<ul class="nav nav-tabs" id="myTab">
|
||||
<li><a href="#add-new">Add New Series</a></li>
|
||||
<li><a href="#import-existing">Import Existing Series</a></li>
|
||||
<li><a href="#root-folders">TV Folders</a></li>
|
||||
<li><a href="#add-new" class="x-add-new-tab">Add New Series</a></li>
|
||||
<li><a href="#import-existing" class="x-import-existing-tab">Import Existing Series</a></li>
|
||||
<li><a href="#root-folders" class ="x-root-folders-tab">TV Folders</a></li>
|
||||
</ul>
|
||||
<div class="tab-content nz-center">
|
||||
<div class="tab-pane" id="add-new">Add new series.</div>
|
||||
|
@ -41,14 +41,14 @@ body {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#footer {
|
||||
#footer-region {
|
||||
font-size: 16px;
|
||||
text-decoration: none;
|
||||
font-weight: lighter;
|
||||
margin: 20px 0 30px 0;
|
||||
}
|
||||
|
||||
#footer a:hover {
|
||||
#footer-region a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
|
@ -11,7 +11,6 @@
|
||||
/// <reference path="JsLibraries/backbone.marionette.viewswapper.js" />
|
||||
/// <reference path="JsLibraries/backbone.modelbinder.js" />
|
||||
/// <reference path="JsLibraries/bootstrap.js" />
|
||||
/// <reference path="nzbdrone.logging.js" />
|
||||
|
||||
if (typeof console == "undefined") {
|
||||
window.console = { log: function () { } };
|
||||
|
@ -1,3 +0,0 @@
|
||||
$(document).ajaxSuccess(function (event, XMLHttpRequest, ajaxOptionsa) {
|
||||
console.log(ajaxOptionsa);
|
||||
});
|
Loading…
Reference in New Issue
Block a user