1
0
Fork 0
mirror of https://github.com/Oreolek/ifhub.club.git synced 2024-06-02 08:08:11 +03:00

Мелкие исправление в компоненте comment

* Исправлено редактирование комментариев
* Исправлена блокировка формы комментирования
This commit is contained in:
Denis Shakhov 2015-04-21 22:43:42 +07:00
parent 9581c32553
commit 033d5178af
2 changed files with 3 additions and 5 deletions

View file

@ -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();
}

View file

@ -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 );