mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-06-02 08:08:11 +03:00
Мелкие исправление в компоненте comment
* Исправлено редактирование комментариев * Исправлена блокировка формы комментирования
This commit is contained in:
parent
9581c32553
commit
033d5178af
|
@ -1876,7 +1876,7 @@ class ActionAjax extends Action
|
|||
/**
|
||||
* Комментарий существует?
|
||||
*/
|
||||
$idComment = getRequestStr('comment_id', null, 'post');
|
||||
$idComment = getRequestStr('reply', null, 'post');
|
||||
if (!($oComment = $this->Comment_GetCommentById($idComment))) {
|
||||
return $this->EventErrorDebug();
|
||||
}
|
||||
|
|
|
@ -94,7 +94,7 @@
|
|||
* Добавляет комментарий
|
||||
*/
|
||||
add: function( data ) {
|
||||
this._load( 'add', data, 'onAdd' );
|
||||
this._load( 'add', data, 'onAdd', { onComplete: this.unlock.bind( this ) });
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -102,7 +102,7 @@
|
|||
*/
|
||||
update: function( data ) {
|
||||
this.emptyText();
|
||||
this._load( 'update', data, 'onUpdate' );
|
||||
this._load( 'update', data, 'onUpdate', { onComplete: this.unlock.bind( this ) });
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -110,7 +110,6 @@
|
|||
*/
|
||||
onAdd: function( response ) {
|
||||
this.emptyText();
|
||||
this.unlock();
|
||||
this.option( 'comments' ).lsComments( 'load', response.sCommentId, false );
|
||||
},
|
||||
|
||||
|
@ -128,7 +127,6 @@
|
|||
comment.replaceWith( commentNew );
|
||||
|
||||
this.hide();
|
||||
this.unlock();
|
||||
this.emptyText();
|
||||
|
||||
this.option( 'comments' ).lsComments( 'scrollToComment', commentNew );
|
||||
|
|
Loading…
Reference in a new issue