mirror of
https://github.com/discourse/discourse.git
synced 2025-05-31 02:29:29 +08:00
Renaming site contents to site text
This commit is contained in:
@ -0,0 +1,20 @@
|
||||
export default Ember.ObjectController.extend({
|
||||
saving: false,
|
||||
saved: false,
|
||||
|
||||
saveDisabled: function() {
|
||||
if (this.get('saving')) { return true; }
|
||||
if ((!this.get('allow_blank')) && Ember.empty(this.get('value'))) { return true; }
|
||||
return false;
|
||||
}.property('saving', 'value'),
|
||||
|
||||
actions: {
|
||||
saveChanges: function() {
|
||||
var self = this;
|
||||
self.setProperties({saving: true, saved: false});
|
||||
self.get('model').save().then(function () {
|
||||
self.setProperties({saving: false, saved: true});
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
Reference in New Issue
Block a user