mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-28 21:12:43 +02:00
rjs -> webpack
This commit is contained in:
@@ -1,38 +1,30 @@
|
||||
'use strict';
|
||||
var AppLayout = require('../../AppLayout');
|
||||
var Marionette = require('marionette');
|
||||
var EditProfileView = require('./Edit/EditProfileLayout');
|
||||
var AsModelBoundView = require('../../Mixins/AsModelBoundView');
|
||||
require('./AllowedLabeler');
|
||||
require('./LanguageLabel');
|
||||
require('bootstrap');
|
||||
|
||||
define(
|
||||
[
|
||||
'AppLayout',
|
||||
'marionette',
|
||||
'Settings/Profile/Edit/EditProfileLayout',
|
||||
'Mixins/AsModelBoundView',
|
||||
'Settings/Profile/AllowedLabeler',
|
||||
'Settings/Profile/LanguageLabel',
|
||||
'bootstrap'
|
||||
], function (AppLayout, Marionette, EditProfileView, AsModelBoundView) {
|
||||
|
||||
var view = Marionette.ItemView.extend({
|
||||
template: 'Settings/Profile/ProfileViewTemplate',
|
||||
tagName : 'li',
|
||||
|
||||
ui: {
|
||||
'progressbar' : '.progress .bar',
|
||||
'deleteButton': '.x-delete'
|
||||
},
|
||||
|
||||
events: {
|
||||
'click' : '_editProfile'
|
||||
},
|
||||
|
||||
initialize: function () {
|
||||
this.listenTo(this.model, 'sync', this.render);
|
||||
},
|
||||
|
||||
_editProfile: function () {
|
||||
var view = new EditProfileView({ model: this.model, profileCollection: this.model.collection });
|
||||
AppLayout.modalRegion.show(view);
|
||||
}
|
||||
});
|
||||
|
||||
return AsModelBoundView.call(view);
|
||||
module.exports = (function(){
|
||||
var view = Marionette.ItemView.extend({
|
||||
template : 'Settings/Profile/ProfileViewTemplate',
|
||||
tagName : 'li',
|
||||
ui : {
|
||||
"progressbar" : '.progress .bar',
|
||||
"deleteButton" : '.x-delete'
|
||||
},
|
||||
events : {"click" : '_editProfile'},
|
||||
initialize : function(){
|
||||
this.listenTo(this.model, 'sync', this.render);
|
||||
},
|
||||
_editProfile : function(){
|
||||
var view = new EditProfileView({
|
||||
model : this.model,
|
||||
profileCollection : this.model.collection
|
||||
});
|
||||
AppLayout.modalRegion.show(view);
|
||||
}
|
||||
});
|
||||
return AsModelBoundView.call(view);
|
||||
}).call(this);
|
Reference in New Issue
Block a user