Fixed: Naming settings resetting when changing fields/saving
This commit is contained in:
parent
6109704fb0
commit
9f92fb3fc1
|
@ -2,11 +2,11 @@
|
||||||
define(
|
define(
|
||||||
[
|
[
|
||||||
'underscore',
|
'underscore',
|
||||||
'vent',
|
|
||||||
'marionette',
|
'marionette',
|
||||||
|
'Config',
|
||||||
'Settings/MediaManagement/Naming/NamingSampleModel',
|
'Settings/MediaManagement/Naming/NamingSampleModel',
|
||||||
'Mixins/AsModelBoundView'
|
'Mixins/AsModelBoundView'
|
||||||
], function (_, vent, Marionette, NamingSampleModel, AsModelBoundView) {
|
], function (_, Marionette, Config, NamingSampleModel, AsModelBoundView) {
|
||||||
|
|
||||||
var view = Marionette.ItemView.extend({
|
var view = Marionette.ItemView.extend({
|
||||||
template: 'Settings/MediaManagement/Naming/Basic/BasicNamingViewTemplate',
|
template: 'Settings/MediaManagement/Naming/Basic/BasicNamingViewTemplate',
|
||||||
|
@ -35,6 +35,10 @@ define(
|
||||||
},
|
},
|
||||||
|
|
||||||
_buildFormat: function () {
|
_buildFormat: function () {
|
||||||
|
if (Config.getValueBoolean(Config.Keys.AdvancedSettings)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (_.has(this.model.changed, 'standardEpisodeFormat') || _.has(this.model.changed, 'dailyEpisodeFormat')) {
|
if (_.has(this.model.changed, 'standardEpisodeFormat') || _.has(this.model.changed, 'dailyEpisodeFormat')) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,12 +3,11 @@ define(
|
||||||
[
|
[
|
||||||
'underscore',
|
'underscore',
|
||||||
'marionette',
|
'marionette',
|
||||||
'Config',
|
|
||||||
'Settings/MediaManagement/Naming/NamingSampleModel',
|
'Settings/MediaManagement/Naming/NamingSampleModel',
|
||||||
'Settings/MediaManagement/Naming/Basic/BasicNamingView',
|
'Settings/MediaManagement/Naming/Basic/BasicNamingView',
|
||||||
'Mixins/AsModelBoundView',
|
'Mixins/AsModelBoundView',
|
||||||
'Mixins/AsValidatedView'
|
'Mixins/AsValidatedView'
|
||||||
], function (_, Marionette, Config, NamingSampleModel, BasicNamingView, AsModelBoundView, AsValidatedView) {
|
], function (_, Marionette, NamingSampleModel, BasicNamingView, AsModelBoundView, AsValidatedView) {
|
||||||
|
|
||||||
var view = Marionette.Layout.extend({
|
var view = Marionette.Layout.extend({
|
||||||
template: 'Settings/MediaManagement/Naming/NamingViewTemplate',
|
template: 'Settings/MediaManagement/Naming/NamingViewTemplate',
|
||||||
|
|
|
@ -245,4 +245,3 @@ define(
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue