mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-31 04:32:06 +08:00
Merge pull request #1806 from okriuchykhin/ok_SCI_3507
Fix step numbering update on reposition [SCI-3507]
This commit is contained in:
commit
f68b69ae02
1 changed files with 4 additions and 4 deletions
|
@ -184,8 +184,8 @@
|
|||
// Switch position of top and bottom steps
|
||||
if (!_.isUndefined($stepDown) && !_.isUndefined($stepUp)) {
|
||||
$stepDown.insertAfter($stepUp);
|
||||
$stepDown.find(".badge").html(stepDownPosition+1);
|
||||
$stepUp.find(".badge").html(stepUpPosition+1);
|
||||
$stepDown.find(".step-number").html(stepDownPosition + 1);
|
||||
$stepUp.find(".step-number").html(stepUpPosition + 1);
|
||||
$("html, body").animate({ scrollTop: $step.offset().top - window.innerHeight / 2 });
|
||||
}
|
||||
|
||||
|
@ -220,7 +220,7 @@
|
|||
});
|
||||
}
|
||||
|
||||
// Init ajax success/error for edit form
|
||||
// Init ajax success/error for edit form
|
||||
function formEditAjax($form) {
|
||||
$form
|
||||
.on("ajax:beforeSend", function () {
|
||||
|
@ -249,7 +249,7 @@
|
|||
});
|
||||
setupAssetsLoading();
|
||||
})
|
||||
.on("ajax:error", function(e, xhr, status, error) {
|
||||
.on("ajax:error", function(e, xhr, status, error) {
|
||||
$form.renderFormErrors('step', xhr.responseJSON, true, e);
|
||||
|
||||
formCallback($form);
|
||||
|
|
Loading…
Reference in a new issue