1
0
Fork 0
mirror of https://github.com/lidarr/Lidarr synced 2024-12-26 01:27:00 +00:00

Added autocomplete to edit series path field.

This commit is contained in:
kay.one 2013-07-13 23:05:51 -07:00
parent 45c7a99439
commit 94807ac00b
3 changed files with 26 additions and 14 deletions

View file

@ -2,7 +2,7 @@
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
<h3>Edit: {{title}}</h3>
</div>
<div class="modal-body">
<div class="modal-body edit-series-modal">
<div class="form-horizontal">
<div class="control-group">
@ -52,7 +52,7 @@
<select class="x-quality-profile" id="inputQualityProfile" name="qualityProfileId">
{{#each qualityProfiles.models}}
<option value="{{id}}">{{attributes.name}}</option>
<option value="{{id}}">{{attributes.name}}</option>
{{/each}}
</select>
<span class="help-inline">
@ -65,7 +65,7 @@
<label class="control-label" for="inputPath">Path</label>
<div class="controls">
<input type="text" id="inputPath" placeholder="Path" name="path">
<input type="text" id="inputPath" class="x-path" placeholder="Path" name="path">
<span class="help-inline">
<i class="icon-question-sign" title="Where should NzbDrone store episodes for this series?"/>
</span>

View file

@ -1,19 +1,20 @@
'use strict';
'use strict';
define(
[
'App',
'marionette',
'Series/Delete/DeleteSeriesView',
'Quality/QualityProfileCollection',
'Mixins/AsModelBoundView'
'Mixins/AsModelBoundView',
'Mixins/AutoComplete'
], function (App, Marionette, DeleteSeriesView, QualityProfiles, AsModelBoundView) {
var view = Marionette.ItemView.extend({
template: 'Series/Edit/EditSeriesTemplate',
ui: {
progressbar : '.progress .bar',
qualityProfile : '.x-quality-profile'
qualityProfile: '.x-quality-profile',
path : '.x-path'
},
events: {
@ -39,10 +40,17 @@ define(
App.modalRegion.closeModal();
},
onRender: function () {
this.ui.path.autoComplete('/directories');
},
removeSeries: function () {
var view = new DeleteSeriesView({ model: this.model });
App.modalRegion.show(view);
}
});
return AsModelBoundView.apply(view);
});

View file

@ -2,6 +2,10 @@
@import "../Shared/Styles/clickable.less";
@import "../Content/prefixer";
.edit-series-modal {
overflow : visible;
}
.series-item {
padding-bottom : 30px;
@ -165,16 +169,16 @@
}
.search-buttons {
width: 400px;
margin-left: auto;
margin-right: auto;
width : 400px;
margin-left : auto;
margin-right : auto;
}
}
.season-grid {
.toggle-cell {
width : 12px;
text-align: center;
width : 12px;
text-align : center;
}
.toggle-cell {
@ -185,8 +189,8 @@
}
.season-actions, .series-actions {
font-size : 24px;
text-transform: none;
font-size : 24px;
text-transform : none;
i {
.clickable;