Grouping Bug Fixed - task bug fixed - bank count account number bug fixed

This commit is contained in:
SamSys
2025-01-22 18:32:36 +03:30
parent c0764b5cd8
commit 5b673180e1
14 changed files with 1757 additions and 39 deletions

View File

@@ -107,7 +107,7 @@ namespace Query.AdminReports.Handlers
ActiveEmployeesWithRollCallInLastWeekCount = activeEmployeesList.Count(y => y.WorkshopId == x.WorkshopId &&
lastWeekRollCallsList.Contains(y.EmployeeId) && !leavesList.Contains(y.EmployeeId)),
TotalEmployeesCount = workshopsWorkingEmployeesList.FirstOrDefault(y => y.WorkshopId == x.WorkshopId)?.TotalWorkingEmployeesCount ?? 0,
UndoneWorkFlowsCount = workFlowApplication.GetAllWorkFlowCount(x.WorkshopId).Result
//UndoneWorkFlowsCount = workFlowApplication.GetAllWorkFlowCount(x.WorkshopId).Result
}).OrderByDescending(x=>x.IsActive).ToList();
}

View File

@@ -12,16 +12,17 @@ namespace ServiceHost.Areas.AdminNew.Pages.Company.AndroidApk
public class IndexModel : PageModel
{
private readonly IAndroidApkVersionApplication _application;
//private readonly IRollCallDomainService _rollCallDomainService;
//private readonly CompanyContext _context;
private readonly IRollCallDomainService _rollCallDomainService;
private readonly CompanyContext _context;
[BindProperty]
public IFormFile File { get; set; }
public IndexModel(IAndroidApkVersionApplication application)
public IndexModel(IAndroidApkVersionApplication application, IRollCallDomainService rollCallDomainService, CompanyContext context)
{
_application = application;
_application = application;
_rollCallDomainService = rollCallDomainService;
_context = context;
}
public void OnGet()
@@ -37,22 +38,22 @@ namespace ServiceHost.Areas.AdminNew.Pages.Company.AndroidApk
public async Task<IActionResult> OnPostShiftDate()
{
// var customizeWorkshopSettings = _context.CustomizeWorkshopSettings.AsSplitQuery();
var customizeWorkshopSettings = _context.CustomizeWorkshopSettings.AsSplitQuery();
////#if DEBUG
//// customizeWorkshopSettings = customizeWorkshopSettings.Where(x => x.WorkshopId == 27 || x.WorkshopId == 499);
////#endif
// var rollCalls =
// _context.RollCalls.Where(x => customizeWorkshopSettings.Any(a => a.WorkshopId == x.WorkshopId))
// .ToList();
// foreach (var rollCall in rollCalls)
// {
// rollCall.SetShiftDate(_rollCallDomainService);
// Console.WriteLine(rollCall.id);
// }
customizeWorkshopSettings = customizeWorkshopSettings.Where(x => x.WorkshopId == 499);
//await _context.SaveChangesAsync();
var rollCalls =
_context.RollCalls.Where(x => customizeWorkshopSettings.Any(a => a.WorkshopId == x.WorkshopId))
.ToList();
foreach (var rollCall in rollCalls)
{
rollCall.SetShiftDate(_rollCallDomainService);
Console.WriteLine(rollCall.id);
}
await _context.SaveChangesAsync();
ViewData["message"] = "ÊæãÇã";
return Page();
}

View File

@@ -21,6 +21,7 @@ var index = 1;
<link href="~/AssetsClient/css/dropdown.css?ver=@Version.AdminVersion" rel="stylesheet" />
<link href="~/AssetsClient/css/filter-search.css?ver=@Version.AdminVersion" rel="stylesheet" />
<link href="~/assetsclient/libs/three-dots/three-dots.css" rel="stylesheet" />
<!-- sweet alerts -->
<style>
@@ -148,10 +149,10 @@ var index = 1;
</div>
<div class="Rtable-cell column-heading d-md-block d-none width2">نام کارگاه</div>
<div class="Rtable-cell column-heading d-md-block d-none width3">نوع سرویس</div>
<div class="Rtable-cell column-heading d-md-block d-none width3new">کارپوشه</div>
<div class="Rtable-cell column-heading width4 text-center">تعداد پرسنل</div>
<div class="Rtable-cell column-heading width5 text-center">تعداد پرسنل فعال</div>
<div class="Rtable-cell column-heading d-md-block d-none width6 text-center">تعداد پرسنل در حال حضور و غیاب</div>
<div class="Rtable-cell column-heading d-md-block d-none width3new">کارپوشه</div>
<div class="Rtable-cell column-heading d-md-block d-none width7 text-center">وضعیت</div>
<div class="Rtable-cell column-heading d-flex width8 text-end">عملیات</div>
</div>
@@ -174,9 +175,6 @@ var index = 1;
<div class="Rtable-cell d-md-block d-none width3">
<div class="Rtable-cell--content text-start">@item.MaxPersonValid نفره</div>
</div>
<div class="Rtable-cell d-md-block d-none width3new">
<div class="Rtable-cell--content text-start">@item.UndoneWorkFlowsCount</div>
</div>
<div class="Rtable-cell width4">
<div class="Rtable-cell--content text-center">@item.TotalEmployeesCount</div>
</div>
@@ -186,6 +184,15 @@ var index = 1;
<div class="Rtable-cell d-md-block d-none width6">
<div class="Rtable-cell--content text-center">@item.ActiveEmployeesWithRollCallInLastWeekCount</div>
</div>
<div class="Rtable-cell d-md-block d-none width3new">
<div class="Rtable-cell--content text-start" data-workshop-id="@item.WorkshopId">
<div class="snippet" data-title="dot-flashing">
<div class="stage">
<div class="dot-flashing"></div>
</div>
</div>
</div>
</div>
<div class="Rtable-cell d-md-block d-none width7">
<div class="Rtable-cell--content text-center">
@if (item.IsActive)
@@ -365,28 +372,52 @@ var index = 1;
<script src="~/assetsclient/js/site.js?ver=@Version.StyleVersion"></script>
<script>
if ($(window).width() < 768) {
$(document).on("click", ".openAction", function () {
$(this).next().find(".operations-btns").slideToggle(500);
$(".operations-btns").not($(this).next().find(".operations-btns")).slideUp(500);
});
}
var antiForgeryToken = $(`@Html.AntiForgeryToken()`).val();
$(document).ready(function () {
if ($(window).width() < 768) {
$(document).on("click",
".openAction",
function() {
$(this).next().find(".operations-btns").slideToggle(500);
$(".operations-btns").not($(this).next().find(".operations-btns")).slideUp(500);
});
}
$(document).ready(function() {
$("#getWorkshopList , #rollCallStatus ,#getWorkshopList2 , #rollCallStatus2").select2({
language: "fa",
dir: "rtl",
});
language: "fa",
dir: "rtl"
});
var workshopIds = [];
$('.Rtable-cell--content').each(function() {
var workshopId = $(this).data('workshop-id');
if (workshopId) {
workshopIds.push(workshopId);
}
});
var delay = 200;
function executeAjaxRequests(ids, index) {
if (index < ids.length) {
workFlowCountAjax(ids[index]);
setTimeout(function() {
executeAjaxRequests(ids, index + 1);
}, delay);
}
}
executeAjaxRequests(workshopIds, 0);
$('.loadingButton').on('click',
function () {
function() {
var button = $(this);
var loadingDiv = button.find('.loading');
loadingDiv.show();
});
$(window).scroll(function () {
$(window).scroll(function() {
if ($(window).scrollTop() + $(window).height() > $(document).height() - 600) {
//ajaxDataWithoutEmployee();
}
@@ -399,7 +430,7 @@ var index = 1;
});
$('.goToTop').on('click',
function () {
function() {
$('html, body').animate({ scrollTop: 0 }, 360);
return false;
});
@@ -412,5 +443,21 @@ var index = 1;
window.location.href = goTo + workshopId;
}
function workFlowCountAjax(id) {
$.ajax({
dataType: 'json',
type: 'POST',
url: `@Url.Page("./Index", "WorkFlowCountByWorkshopId")`,
data: { workshopId: id },
headers: { "RequestVerificationToken": antiForgeryToken },
success: function(response) {
$(`[data-workshop-id="${id}"]`).text(response.data);
},
error: function(xhr, status, error) {
console.log('Error:', error);
}
});
}
</script>
}

View File

@@ -1,8 +1,10 @@
using CompanyManagment.App.Contracts.Workshop;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.RazorPages;
using Query.AdminReports.Handlers;
using Query.AdminReports.Models;
using WorkFlow.Application.Contracts.WorkFlow;
namespace ServiceHost.Areas.AdminNew.Pages.Company.RollCall
{
@@ -10,17 +12,19 @@ namespace ServiceHost.Areas.AdminNew.Pages.Company.RollCall
{
private readonly IGetWorkshopWithRollCallHandler _workshopWithRollCallHandler;
private readonly IWorkshopApplication _workshopApplication;
private readonly IWorkFlowApplication _workflowApplication;
public List<WorkshopWithRollCallServiceQueryModel> Items { get; set; }
public List<WorkshopWithRollCallServiceQueryModel> WorkshopSearchItems { get; set; }
public WorkshopWithRollCallServiceQueryParameters SearchModel;
public FilterMode FilterMode { get; set; }
public IndexModel(IGetWorkshopWithRollCallHandler workshopWithRollCallHandler, IWorkshopApplication workshopApplication)
public IndexModel(IGetWorkshopWithRollCallHandler workshopWithRollCallHandler, IWorkshopApplication workshopApplication, IWorkFlowApplication workflowApplication)
{
_workshopWithRollCallHandler = workshopWithRollCallHandler;
_workshopApplication = workshopApplication;
_workflowApplication = workflowApplication;
}
public void OnGet(WorkshopWithRollCallServiceQueryParameters searchModel)
{
SearchModel = new WorkshopWithRollCallServiceQueryParameters()
@@ -38,5 +42,14 @@ namespace ServiceHost.Areas.AdminNew.Pages.Company.RollCall
{
WorkshopSearchItems = _workshopWithRollCallHandler.Handle(new WorkshopWithRollCallServiceQueryParameters());
}
public async Task<IActionResult> OnPostWorkFlowCountByWorkshopId(long workshopId)
{
var result = await System.Threading.Tasks.Task.Run(() => _workflowApplication.GetAllWorkFlowCount(workshopId));
return new JsonResult(new
{
data = result
});
}
}
}

View File

@@ -729,6 +729,9 @@
var uploadFileTicketAjax = '@Url.Page("/Company/Task/Index", "UploadFile")';
var deleteFileTicketAjax = '@Url.Page("/Company/Task/Index", "DeleteFile")';
var deleteAllFilesTicketAjax = '@Url.Page("/Company/Task/Index", "RemoveAllTempFiles")';
var urlAjaxAcceptPendingAdminResponse = '@Url.Page("/Company/Ticket/Index", "AcceptPendingAdminResponse")';
var urlAjaxRejectPendingAdminResponse = '@Url.Page("/Company/Ticket/Index", "RejectPendingAdminResponse")';
var urlAjaxEditPendingAdminResponse = '@Url.Page("/Company/Ticket/Index", "EditPendingAdminResponse")';
var taskId = Number(@Model.TaskDetails.Id);
var TicketId = Number(@Model.TaskDetails.TicketViewModel.Id);

View File

@@ -218,7 +218,7 @@
else
{
<div class="col-1 d-flex align-items-center justify-content-end">
<button type="button" class="btnRemoveTimeWork">
<button type="button" class="btnRemoveTimeWorkRS">
<svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="11" cy="11" r="8.25" stroke="white" />
<path d="M6.875 11H15.125" stroke="white" />

View File

@@ -730,6 +730,10 @@
<None Include="wwwroot\AssetsClient\libs\select2\js\select2.full.min.js" />
<None Include="wwwroot\AssetsClient\libs\select2\js\select2.js" />
<None Include="wwwroot\AssetsClient\libs\select2\js\select2.min.js" />
<None Include="wwwroot\AssetsClient\libs\wordifyfa\wordifyfa.js" />
<None Include="wwwroot\AssetsClient\libs\wordifyfa\wordifyfa.js.map" />
<None Include="wwwroot\AssetsClient\libs\wordifyfa\wordifyfa.min.js" />
<None Include="wwwroot\AssetsClient\libs\wordifyfa\wordifyfa.min.js.map" />
<None Include="wwwroot\AssetsClient\pages\Checkouts\js\PrintOne.js" />
<None Include="wwwroot\AssetsClient\pages\Checkouts\js\PrintOneMobile.js" />
<None Include="wwwroot\AssetsClient\pages\Checkouts\js\PrintOneRollCall.js" />

Binary file not shown.

After

Width:  |  Height:  |  Size: 395 KiB

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,353 @@
/******/ (() => { // webpackBootstrap
/******/ "use strict";
/******/ var __webpack_modules__ = ({
/***/ 171:
/***/ ((module, __unused_webpack___webpack_exports__, __webpack_require__) => {
// UNUSED EXPORTS: momentApprox, momentPrecise, wordifyMomentApprox, wordifyMomentPrecise, wordifyRials, wordifyRialsInTomans, wordifyfa
;// CONCATENATED MODULE: ./src/toEnglishDigits.ts
function toEnglishDigits(num) {
if (num === null || num === undefined) {
return null;
}
if (typeof num !== 'string' || num.length === 0)
return num.toString();
var faDigits = '۰۱۲۳۴۵۶۷۸۹';
var arDigits = '٠١٢٣٤٥٦٧٨٩';
var output = "";
for (var ipos = 0; ipos < num.length; ipos++) {
var faIndex = faDigits.indexOf(num[ipos]);
if (faIndex >= 0) {
output += faIndex.toString();
continue;
}
var arIndex = arDigits.indexOf(num[ipos]);
if (arIndex >= 0) {
output += arIndex.toString();
continue;
}
output += num[ipos];
}
return output.replace(/,/g, "");
}
;// CONCATENATED MODULE: ./src/wordifyfa.ts
/* module decorator */ module = __webpack_require__.hmd(module);
function wordifyfa(input, level) {
if (level === void 0) { level = 0; }
if (input === null) {
return "";
}
var num = parseInt(toEnglishDigits(input));
if (num < 0) {
num = num * -1;
return "منفی " + wordifyfa(num, level);
}
if (num === 0) {
if (level === 0) {
return "صفر";
}
else {
return "";
}
}
var result = "";
var yekan = ["یک", "دو", "سه", "چهار", "پنج", "شش", "هفت", "هشت", "نه"], dahgan = ["بیست", "سی", "چهل", "پنجاه", "شصت", "هفتاد", "هشتاد", "نود"], sadgan = ["یکصد", "دویست", "سیصد", "چهارصد", "پانصد", "ششصد", "هفتصد", "هشتصد", "نهصد"], dah = ["ده", "یازده", "دوازده", "سیزده", "چهارده", "پانزده", "شانزده", "هفده", "هیجده", "نوزده"];
if (level > 0) {
result += " و ";
level -= 1;
}
if (num < 10) {
result += yekan[num - 1];
}
else if (num < 20) {
result += dah[num - 10];
}
else if (num < 100) {
result += dahgan[Math.floor(num / 10) - 2] + wordifyfa(num % 10, level + 1);
}
else if (num < 1000) {
result += sadgan[Math.floor(num / 100) - 1] + wordifyfa(num % 100, level + 1);
}
else if (num < 1000000) {
result += wordifyfa(Math.floor(num / 1000), level) + " هزار" + wordifyfa(num % 1000, level + 1);
}
else if (num < 1000000000) {
result += wordifyfa(Math.floor(num / 1000000), level) + " میلیون" + wordifyfa(num % 1000000, level + 1);
}
else if (num < 1000000000000) {
result += wordifyfa(Math.floor(num / 1000000000), level) + " میلیارد" + wordifyfa(num % 1000000000, level + 1);
}
else if (num < 1000000000000000) {
result += wordifyfa(Math.floor(num / 1000000000000), level) + " تریلیارد" + wordifyfa(num % 1000000000000, level + 1);
}
return result;
}
function wordifyRials(num) {
if (num === null || num === undefined || num === "") {
return "";
}
return wordifyfa(num, 0) + " ریال";
}
function wordifyRialsInTomans(num) {
if (num === null || num === undefined || num === "") {
return "";
}
if (typeof num == "string") {
var cleanNumber = toEnglishDigits(num);
num = parseInt(cleanNumber);
}
if (num >= 10 || num <= -10) {
num = Math.floor(num / 10);
}
else {
num = 0;
}
return wordifyfa(num, 0) + " تومان";
}
function momentApprox(date, baseDate, suffixBefore, suffixAfter) {
if (suffixBefore === void 0) { suffixBefore = "پیش"; }
if (suffixAfter === void 0) { suffixAfter = "بعد"; }
return wordifyMomentApprox(date, baseDate, suffixBefore, suffixAfter, false);
}
function wordifyMomentApprox(date, baseDate, suffixBefore, suffixAfter, doWordify) {
if (suffixBefore === void 0) { suffixBefore = "پیش"; }
if (suffixAfter === void 0) { suffixAfter = "بعد"; }
if (doWordify === void 0) { doWordify = true; }
if (date === null || date === undefined || date === "") {
return "";
}
if (baseDate == null || baseDate == undefined || baseDate == "") {
baseDate = new Date();
}
if (typeof date == "string") {
date = new Date(date);
}
if (typeof baseDate == "string") {
baseDate = new Date(baseDate);
}
var suffix = suffixBefore;
var diff = Math.floor((baseDate.getTime() - date.getTime()) / 1000) * 1000;
if (diff < 0) {
suffix = suffixAfter;
diff = Math.abs(diff);
}
var diffYears = Math.floor(diff / 31557600000);
if (diffYears > 0) {
return (doWordify ? wordifyfa(diffYears) : diffYears) + " سال " + suffix;
}
var diffMonths = Math.floor(diff / 2629800000);
if (diffMonths > 0) {
return (doWordify ? wordifyfa(diffMonths) : diffMonths) + " ماه " + suffix;
}
var diffWeeks = Math.floor(diff / 604800000);
if (diffWeeks > 0) {
return (doWordify ? wordifyfa(diffWeeks) : diffWeeks) + " هفته " + suffix;
}
var diffDays = Math.floor(diff / 86400000);
if (diffDays > 0) {
return (doWordify ? wordifyfa(diffDays) : diffDays) + " روز " + suffix;
}
var diffHours = Math.floor(diff / 3600000);
if (diffHours > 0) {
return (doWordify ? wordifyfa(diffHours) : diffHours) + " ساعت " + suffix;
}
var diffMinutes = Math.floor(diff / 60000);
if (diffMinutes > 0) {
return (doWordify ? wordifyfa(diffMinutes) : diffMinutes) + " دقیقه " + suffix;
}
var diffSeconds = Math.floor(diff / 1000);
if (diffSeconds > 0) {
return "چند لحظه " + suffix;
}
return "بلافاصله";
}
function momentPrecise(date, baseDate, suffixBefore, suffixAfter) {
if (suffixBefore === void 0) { suffixBefore = "پیش"; }
if (suffixAfter === void 0) { suffixAfter = "بعد"; }
return wordifyMomentPrecise(date, baseDate, suffixBefore, suffixAfter, false);
}
function wordifyMomentPrecise(date, baseDate, suffixBefore, suffixAfter, doWordify) {
if (suffixBefore === void 0) { suffixBefore = "پیش"; }
if (suffixAfter === void 0) { suffixAfter = "بعد"; }
if (doWordify === void 0) { doWordify = true; }
if (date === null || date === undefined || date === "") {
return "";
}
if (baseDate == null || baseDate == undefined || baseDate == "") {
baseDate = new Date();
}
if (typeof date == "string") {
date = new Date(date);
}
if (typeof baseDate == "string") {
baseDate = new Date(baseDate);
}
var suffix = suffixBefore;
var diff = Math.floor((baseDate.getTime() - date.getTime()) / 1000) * 1000;
if (diff < 0) {
suffix = suffixAfter;
diff = Math.abs(diff);
}
var result = "";
var diffYears = Math.floor(diff / 31557600000);
if (diffYears > 0) {
diff -= (diffYears * 31557600000);
}
var diffMonths = Math.floor(diff / 2629800000);
if (diffMonths > 0) {
diff -= (diffMonths * 2629800000);
}
var diffWeeks = Math.floor(diff / 604800000);
if (diffWeeks > 0) {
diff -= (diffWeeks * 604800000);
}
var diffDays = Math.floor(diff / 86400000);
if (diffDays > 0) {
diff -= (diffDays * 86400000);
}
var diffHours = Math.floor(diff / 3600000);
if (diffHours > 0) {
diff -= (diffHours * 3600000);
}
var diffMinutes = Math.floor(diff / 60000);
if (diffMinutes > 0) {
diff -= (diffMinutes * 60000);
}
var diffSeconds = Math.floor(diff / 1000);
if (diffYears > 0) {
result = (doWordify ? wordifyfa(diffYears) : diffYears) + " سال ";
}
if (diffMonths > 0) {
if (result.length > 0) {
result += "و ";
}
result += (doWordify ? wordifyfa(diffMonths) : diffMinutes) + " ماه ";
}
if (diffWeeks > 0) {
if (result.length > 0) {
result += "و ";
}
result += (doWordify ? wordifyfa(diffWeeks) : diffWeeks) + " هفته ";
}
if (diffDays > 0) {
if (result.length > 0) {
result += "و ";
}
result += (doWordify ? wordifyfa(diffDays) : diffDays) + " روز ";
}
if (diffHours > 0) {
if (result.length > 0) {
result += "و ";
}
result += (doWordify ? wordifyfa(diffHours) : diffHours) + " ساعت ";
}
if (diffMinutes > 0) {
if (result.length > 0) {
result += "و ";
}
result += (doWordify ? wordifyfa(diffMinutes) : diffMinutes) + " دقیقه ";
}
if (diffSeconds > 0) {
if (result.length > 0) {
result += "و ";
}
result += (doWordify ? wordifyfa(diffSeconds) : diffSeconds) + " ثانیه ";
}
if (result.length == 0) {
return "بلافاصله";
}
result += suffix;
return result;
}
(function () {
if (typeof window !== "undefined") {
window["wordifyfa"] = wordifyfa;
window["wordifyRials"] = wordifyRials;
window["wordifyRialsInTomans"] = wordifyRialsInTomans;
window["wordifyMomentApprox"] = wordifyMomentApprox;
window["momentApprox"] = momentApprox;
}
else if ( true && module.exports) {
module.exports["wordifyfa"] = wordifyfa;
module.exports["wordifyRials"] = wordifyRials;
module.exports["wordifyRialsInTomans"] = wordifyRialsInTomans;
module.exports["wordifyMomentApprox"] = wordifyMomentApprox;
module.exports["momentApprox"] = momentApprox;
}
else if (typeof define === 'function' && __webpack_require__.amdO) {
define(function () { return wordifyfa; });
define(function () { return wordifyRials; });
define(function () { return wordifyRialsInTomans; });
define(function () { return wordifyMomentApprox; });
define(function () { return momentApprox; });
}
}());
/***/ })
/******/ });
/************************************************************************/
/******/ // The module cache
/******/ var __webpack_module_cache__ = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/ // Check if module is in cache
/******/ var cachedModule = __webpack_module_cache__[moduleId];
/******/ if (cachedModule !== undefined) {
/******/ return cachedModule.exports;
/******/ }
/******/ // Create a new module (and put it into the cache)
/******/ var module = __webpack_module_cache__[moduleId] = {
/******/ id: moduleId,
/******/ loaded: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.loaded = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/************************************************************************/
/******/ /* webpack/runtime/amd options */
/******/ (() => {
/******/ __webpack_require__.amdO = {};
/******/ })();
/******/
/******/ /* webpack/runtime/harmony module decorator */
/******/ (() => {
/******/ __webpack_require__.hmd = (module) => {
/******/ module = Object.create(module);
/******/ if (!module.children) module.children = [];
/******/ Object.defineProperty(module, 'exports', {
/******/ enumerable: true,
/******/ set: () => {
/******/ throw new Error('ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: ' + module.id);
/******/ }
/******/ });
/******/ return module;
/******/ };
/******/ })();
/******/
/************************************************************************/
/******/
/******/ // startup
/******/ // Load entry module and return exports
/******/ // This entry module is referenced by other modules so it can't be inlined
/******/ var __webpack_exports__ = __webpack_require__(171);
/******/
/******/ })()
;
//# sourceMappingURL=wordifyfa.js.map

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,2 @@
(()=>{"use strict";var r={171:(r,e,t)=>{function o(r){if(null==r)return null;if("string"!=typeof r||0===r.length)return r.toString();for(var e="",t=0;t<r.length;t++){var o="۰۱۲۳۴۵۶۷۸۹".indexOf(r[t]);if(o>=0)e+=o.toString();else{var n="٠١٢٣٤٥٦٧٨٩".indexOf(r[t]);e+=n>=0?n.toString():r[t]}}return e.replace(/,/g,"")}function n(r,e){if(void 0===e&&(e=0),null===r)return"";var t=parseInt(o(r));if(t<0)return"منفی "+n(t*=-1,e);if(0===t)return 0===e?"صفر":"";var i="";return e>0&&(i+=" و ",e-=1),t<10?i+=["یک","دو","سه","چهار","پنج","شش","هفت","هشت","نه"][t-1]:t<20?i+=["ده","یازده","دوازده","سیزده","چهارده","پانزده","شانزده","هفده","هیجده","نوزده"][t-10]:t<100?i+=["بیست","سی","چهل","پنجاه","شصت","هفتاد","هشتاد","نود"][Math.floor(t/10)-2]+n(t%10,e+1):t<1e3?i+=["یکصد","دویست","سیصد","چهارصد","پانصد","ششصد","هفتصد","هشتصد","نهصد"][Math.floor(t/100)-1]+n(t%100,e+1):t<1e6?i+=n(Math.floor(t/1e3),e)+" هزار"+n(t%1e3,e+1):t<1e9?i+=n(Math.floor(t/1e6),e)+" میلیون"+n(t%1e6,e+1):t<1e12?i+=n(Math.floor(t/1e9),e)+" میلیارد"+n(t%1e9,e+1):t<1e15&&(i+=n(Math.floor(t/1e12),e)+" تریلیارد"+n(t%1e12,e+1)),i}function i(r){return null==r||""===r?"":n(r,0)+" ریال"}function f(r){if(null==r||""===r)return"";if("string"==typeof r){var e=o(r);r=parseInt(e)}return n(r=r>=10||r<=-10?Math.floor(r/10):0,0)+" تومان"}function a(r,e,t,o){return void 0===t&&(t="پیش"),void 0===o&&(o="بعد"),u(r,e,t,o,!1)}function u(r,e,t,o,i){if(void 0===t&&(t="پیش"),void 0===o&&(o="بعد"),void 0===i&&(i=!0),null==r||""===r)return"";null!=e&&null!=e&&""!=e||(e=new Date),"string"==typeof r&&(r=new Date(r)),"string"==typeof e&&(e=new Date(e));var f=t,a=1e3*Math.floor((e.getTime()-r.getTime())/1e3);a<0&&(f=o,a=Math.abs(a));var u=Math.floor(a/315576e5);if(u>0)return(i?n(u):u)+" سال "+f;var d=Math.floor(a/26298e5);if(d>0)return(i?n(d):d)+" ماه "+f;var l=Math.floor(a/6048e5);if(l>0)return(i?n(l):l)+" هفته "+f;var s=Math.floor(a/864e5);if(s>0)return(i?n(s):s)+" روز "+f;var p=Math.floor(a/36e5);if(p>0)return(i?n(p):p)+" ساعت "+f;var w=Math.floor(a/6e4);return w>0?(i?n(w):w)+" دقیقه "+f:Math.floor(a/1e3)>0?"چند لحظه "+f:"بلافاصله"}r=t.hmd(r),"undefined"!=typeof window?(window.wordifyfa=n,window.wordifyRials=i,window.wordifyRialsInTomans=f,window.wordifyMomentApprox=u,window.momentApprox=a):r.exports?(r.exports.wordifyfa=n,r.exports.wordifyRials=i,r.exports.wordifyRialsInTomans=f,r.exports.wordifyMomentApprox=u,r.exports.momentApprox=a):"function"==typeof define&&t.amdO&&(define((function(){return n})),define((function(){return i})),define((function(){return f})),define((function(){return u})),define((function(){return a})))}},e={};function t(o){var n=e[o];if(void 0!==n)return n.exports;var i=e[o]={id:o,loaded:!1,exports:{}};return r[o](i,i.exports,t),i.loaded=!0,i.exports}t.amdO={},t.hmd=r=>((r=Object.create(r)).children||(r.children=[]),Object.defineProperty(r,"exports",{enumerable:!0,set:()=>{throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+r.id)}}),r);t(171)})();
//# sourceMappingURL=wordifyfa.min.js.map

File diff suppressed because one or more lines are too long

View File

@@ -475,6 +475,9 @@
// Update Remove button enable/disable state
updateRemoveButtonsRS();
});
updateRemoveButtons();
updateRemoveButtonsRS();
});
function updateRemoveButtons() {