#186 preventing double POST while moderating corrections
This commit is contained in:
parent
a38ca7dd38
commit
bba5513674
@ -200,6 +200,10 @@ else
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2"><p id="saving"> </p></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>
|
||||
تعداد کل:
|
||||
|
||||
@ -324,6 +324,10 @@
|
||||
|
||||
function moderatePoemCorrections(verseCount, correctionId) {
|
||||
|
||||
$('#moderatecorrections').hide();
|
||||
$('#saving').text('در حال بررسی ...');
|
||||
|
||||
|
||||
var titleReviewResult = 'DontCare';
|
||||
if ($('#title_review_result_Approved').length > 0) { //has title
|
||||
titleReviewResult = $('input[name=title_review_result]:checked').val()
|
||||
@ -370,6 +374,8 @@
|
||||
alert(e);
|
||||
else
|
||||
alert(e.responseText);
|
||||
$('#moderatecorrections').show();
|
||||
$('#saving').text('');
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@ -1698,6 +1698,12 @@ namespace RMuseum.Services.Implementation
|
||||
_context.GanjoorPoemCorrections.Update(dbCorrection);
|
||||
await _context.SaveChangesAsync();
|
||||
|
||||
await _notificationService.PushNotification(dbCorrection.UserId,
|
||||
"بررسی ویرایش پیشنهادی شما",
|
||||
$"با سپاس از زحمت و همت شما ویرایش پیشنهادیتان برای <a href=\"{dbPoem.FullUrl}\" target=\"_blank\">{dbPoem.FullTitle}</a> بررسی شد.{Environment.NewLine}" +
|
||||
$"جهت مشاهدهٔ نتیجهٔ بررسی در میز کاربری خود بخش «ویرایشهای من» را مشاهده بفرمایید.{Environment.NewLine}"
|
||||
);
|
||||
|
||||
return new RServiceResult<GanjoorPoemCorrectionViewModel>(moderation);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user