[PE][SSE] Lock document info settings
This commit is contained in:
parent
d7abed8f38
commit
e07a6caca4
|
@ -720,7 +720,7 @@ define([
|
|||
|
||||
this.tblAuthor.on('click', function(e) {
|
||||
var btn = $(e.target);
|
||||
if (btn.hasClass('close')) {
|
||||
if (btn.hasClass('close') && !btn.hasClass('disabled')) {
|
||||
var el = btn.closest('tr'),
|
||||
idx = me.tblAuthor.find('tr').index(el);
|
||||
el.remove();
|
||||
|
@ -882,10 +882,19 @@ define([
|
|||
|
||||
setApi: function(o) {
|
||||
this.api = o;
|
||||
this.api.asc_registerCallback('asc_onLockCore', _.bind(this.onLockCore, this));
|
||||
this.updateInfo(this.doc);
|
||||
return this;
|
||||
},
|
||||
|
||||
onLockCore: function(lock) {
|
||||
this.inputTitle.setDisabled(lock);
|
||||
this.inputSubject.setDisabled(lock);
|
||||
this.inputComment.setDisabled(lock);
|
||||
this.inputAuthor.setDisabled(lock);
|
||||
this.tblAuthor.find('.close').toggleClass('disabled', lock);
|
||||
},
|
||||
|
||||
txtPlacement: 'Location',
|
||||
txtOwner: 'Owner',
|
||||
txtUploaded: 'Uploaded',
|
||||
|
|
|
@ -448,6 +448,11 @@
|
|||
&:hover {
|
||||
background-position: @but-close-offset-x @but-close-offset-y - 16px;
|
||||
}
|
||||
|
||||
&.disabled {
|
||||
background-position: @but-close-offset-x @but-close-offset-y - 32px;
|
||||
cursor: default;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1171,7 +1171,7 @@ define([
|
|||
|
||||
this.tblAuthor.on('click', function(e) {
|
||||
var btn = $(e.target);
|
||||
if (btn.hasClass('close')) {
|
||||
if (btn.hasClass('close') && !btn.hasClass('disabled')) {
|
||||
var el = btn.closest('tr'),
|
||||
idx = me.tblAuthor.find('tr').index(el);
|
||||
el.remove();
|
||||
|
@ -1333,10 +1333,19 @@ define([
|
|||
|
||||
setApi: function(o) {
|
||||
this.api = o;
|
||||
this.api.asc_registerCallback('asc_onLockCore', _.bind(this.onLockCore, this));
|
||||
this.updateInfo(this.doc);
|
||||
return this;
|
||||
},
|
||||
|
||||
onLockCore: function(lock) {
|
||||
this.inputTitle.setDisabled(lock);
|
||||
this.inputSubject.setDisabled(lock);
|
||||
this.inputComment.setDisabled(lock);
|
||||
this.inputAuthor.setDisabled(lock);
|
||||
this.tblAuthor.find('.close').toggleClass('disabled', lock);
|
||||
},
|
||||
|
||||
txtPlacement: 'Location',
|
||||
txtOwner: 'Owner',
|
||||
txtUploaded: 'Uploaded',
|
||||
|
|
|
@ -515,6 +515,11 @@
|
|||
&:hover {
|
||||
background-position: @but-close-offset-x @but-close-offset-y - 16px;
|
||||
}
|
||||
|
||||
&.disabled {
|
||||
background-position: @but-close-offset-x @but-close-offset-y - 32px;
|
||||
cursor: default;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue