Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added cancel button when editing #424

Merged
merged 1 commit into from
Jul 23, 2017
Merged

Added cancel button when editing #424

merged 1 commit into from
Jul 23, 2017

Conversation

mohitanand001
Copy link
Contributor

Also the edit and delete button will be hidden.

@@ -77,6 +77,8 @@ $(function () {
var old_message = $('#text_div_'+comment_id).text();
$('#text_comment_'+comment_id).val(old_message);
$('#text_div_'+comment_id).text('');
$(this).hide();
$('#del_comment_'+comment_id).hide();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the wrong way!
Remove the id from delete button.
Replace this $('#del_comment_'+comment_id).hide(); with $(this).closest('.del_comment').hide();

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, Just use: $(this).next('.del_comment').hide();

@jajodiaraghav jajodiaraghav merged commit 4e0578f into OWASP-BLT:master Jul 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants