add conflict indicator for employee customize checkout records
This commit is contained in:
@@ -374,6 +374,13 @@ public class CustomizeCheckout : EntityBase
|
||||
TotalPayment = TotalPayment - previousAmount + newAmount;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// آیا مغایرت مبلغ دارد
|
||||
/// </summary>
|
||||
public bool HasAmountConflict { get; private set; }
|
||||
|
||||
|
||||
public void SetHasAmountConflict(bool hasConflict)
|
||||
{
|
||||
HasAmountConflict = hasConflict;
|
||||
}
|
||||
}
|
||||
@@ -377,4 +377,16 @@ public class CustomizeCheckoutTemp : EntityBase
|
||||
{
|
||||
TotalPayment = TotalPayment - previousAmount + newAmount;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// آیا مغایرت مبلغ دارد
|
||||
/// </summary>
|
||||
public bool HasAmountConflict { get; private set; }
|
||||
|
||||
|
||||
|
||||
public void SetHasAmountConflict(bool hasConflict)
|
||||
{
|
||||
HasAmountConflict = hasConflict;
|
||||
}
|
||||
}
|
||||
@@ -109,6 +109,8 @@ namespace CompanyManagment.App.Contracts.CustomizeCheckout
|
||||
public List<CustomizeRotatingShift> CustomizeRotatingShifts { get; set; }
|
||||
public List<CustomizeSifts> RegularShift { get; set; }
|
||||
|
||||
public bool HasAmountConflict { get; set; }
|
||||
|
||||
//public bool HasLeft { get; set; }
|
||||
//public string IsBlockCantracingParty { get; set; }
|
||||
//public string IsActiveString { get; set; }
|
||||
|
||||
@@ -122,12 +122,13 @@ public class SalaryAidApplication : ISalaryAidApplication
|
||||
|
||||
if (customizeCheckouts != null)
|
||||
{
|
||||
var salaryAids = customizeCheckouts.CustomizeCheckoutSalaryAids.ToList();
|
||||
|
||||
salaryAids.Add(new(entity.Amount.ToMoney(), entity.SalaryAidDateTime,
|
||||
entity.SalaryAidDateTime.ToFarsi(), entity.CalculationDate, entity.CalculationDate.ToFarsi(),
|
||||
entity.id));
|
||||
customizeCheckouts.SetSalaryAids(salaryAids);
|
||||
customizeCheckouts.SetHasAmountConflict(true);
|
||||
// var salaryAids = customizeCheckouts.CustomizeCheckoutSalaryAids.ToList();
|
||||
//
|
||||
// salaryAids.Add(new(entity.Amount.ToMoney(), entity.SalaryAidDateTime,
|
||||
// entity.SalaryAidDateTime.ToFarsi(), entity.CalculationDate, entity.CalculationDate.ToFarsi(),
|
||||
// entity.id));
|
||||
//customizeCheckouts.SetSalaryAids(salaryAids);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -138,12 +139,13 @@ public class SalaryAidApplication : ISalaryAidApplication
|
||||
|
||||
if (customizeCheckoutTemp != null)
|
||||
{
|
||||
var salaryAids = customizeCheckoutTemp.CustomizeCheckoutSalaryAids.ToList();
|
||||
|
||||
salaryAids.Add(new(entity.Amount.ToMoney(), entity.SalaryAidDateTime,
|
||||
entity.SalaryAidDateTime.ToFarsi(), entity.CalculationDate, entity.CalculationDate.ToFarsi(),
|
||||
entity.id));
|
||||
customizeCheckoutTemp.SetSalaryAids(salaryAids);
|
||||
customizeCheckoutTemp.SetHasAmountConflict(true);
|
||||
// var salaryAids = customizeCheckoutTemp.CustomizeCheckoutSalaryAids.ToList();
|
||||
//
|
||||
// salaryAids.Add(new(entity.Amount.ToMoney(), entity.SalaryAidDateTime,
|
||||
// entity.SalaryAidDateTime.ToFarsi(), entity.CalculationDate, entity.CalculationDate.ToFarsi(),
|
||||
// entity.id));
|
||||
//customizeCheckoutTemp.SetSalaryAids(salaryAids);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1065,6 +1065,9 @@ namespace CompanyManagment.EFCore.Migrations
|
||||
b.Property<double>("FridayPay")
|
||||
.HasColumnType("float");
|
||||
|
||||
b.Property<bool>("HasAmountConflict")
|
||||
.HasColumnType("bit");
|
||||
|
||||
b.Property<double>("InstallmentDeduction")
|
||||
.HasColumnType("float");
|
||||
|
||||
@@ -1214,6 +1217,9 @@ namespace CompanyManagment.EFCore.Migrations
|
||||
b.Property<double>("FridayPay")
|
||||
.HasColumnType("float");
|
||||
|
||||
b.Property<bool>("HasAmountConflict")
|
||||
.HasColumnType("bit");
|
||||
|
||||
b.Property<double>("InstallmentDeduction")
|
||||
.HasColumnType("float");
|
||||
|
||||
|
||||
@@ -488,6 +488,7 @@ namespace CompanyManagment.EFCore.Repository
|
||||
TotalPayment = x.TotalPayment.ToMoney(),
|
||||
TotalPaymentD = x.TotalPayment,
|
||||
TotalLateToWorkDeduction = x.LateToWorkDeduction.ToMoney(),
|
||||
HasAmountConflict = x.HasAmountConflict
|
||||
|
||||
}).ToList();
|
||||
|
||||
|
||||
@@ -216,6 +216,7 @@ namespace CompanyManagment.EFCore.Repository
|
||||
TotalPayment = x.TotalPayment.ToMoney(),
|
||||
TotalPaymentD = x.TotalPayment,
|
||||
TotalLateToWorkDeduction = x.LateToWorkDeduction.ToMoney(),
|
||||
HasAmountConflict = x.HasAmountConflict
|
||||
}).ToList();
|
||||
|
||||
|
||||
|
||||
@@ -68,6 +68,11 @@
|
||||
background-color: #a8ebc1;
|
||||
}
|
||||
|
||||
.conflict-icon {
|
||||
color: #dc3545;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
@@media (max-width: 767px) {
|
||||
.table-contracts .Rtable .Rtable-row .Rtable-contract .Rtable-cell--heading button.btn-print {
|
||||
width: 30px;
|
||||
@@ -410,7 +415,23 @@
|
||||
</div> *@
|
||||
<div class="Rtable-cell d-md-block d-none width6">
|
||||
<div class="Rtable-cell--heading">نام پرسنل</div>
|
||||
<div class="Rtable-cell--content ">@item.EmployeeFullName</div>
|
||||
<div class="Rtable-cell--content">
|
||||
@item.EmployeeFullName
|
||||
@if (item.HasAmountConflict)
|
||||
{
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
width="24" height="24" fill="red"
|
||||
class="bi bi-exclamation-circle"
|
||||
viewBox="0 0 16 16"
|
||||
style="cursor: pointer; margin-left: 10px;"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-placement="top"
|
||||
title="توجه داشته باشید این فیش حقوقی دارای تغییرات اعمال نشده میباشد. جهت صدور فیش حقوقی استاندارد مجددا فیش را ایجاد کنید!">
|
||||
<path d="M8 15A7 7 0 1 0 8 1a7 7 0 0 0 0 14zm0 1A8 8 0 1 1 8 0a8 8 0 0 1 0 16z"/>
|
||||
<path d="M7.002 11a1 1 0 1 1 2 0 1 1 0 0 1-2 0zm.1-5.995a.905.905 0 0 1 1.8 0l-.35 3.5a.552.552 0 0 1-1.1 0l-.35-3.5z"/>
|
||||
</svg>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="Rtable-cell d-md-block d-none width7">
|
||||
<div class="Rtable-cell--heading">آغاز قرارداد</div>
|
||||
@@ -490,6 +511,21 @@
|
||||
<div class="Rtable-cell--content">
|
||||
<span class="mx-sm-2">
|
||||
@item.EmployeeFullName
|
||||
@if (item.HasAmountConflict)
|
||||
{
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
width="12" height="12" fill="red"
|
||||
class="bi bi-exclamation-circle"
|
||||
viewBox="0 0 16 16"
|
||||
style="cursor: pointer; margin-left: 10px;"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-placement="top"
|
||||
title="توجه داشته باشید این فیش حقوقی دارای تغییرات اعمال نشده میباشد. جهت صدور فیش حقوقی استاندارد مجددا فیش را ایجاد کنید!">
|
||||
<path d="M8 15A7 7 0 1 0 8 1a7 7 0 0 0 0 14zm0 1A8 8 0 1 1 8 0a8 8 0 0 1 0 16z"/>
|
||||
<path d="M7.002 11a1 1 0 1 1 2 0 1 1 0 0 1-2 0zm.1-5.995a.905.905 0 0 1 1.8 0l-.35 3.5a.552.552 0 0 1-1.1 0l-.35-3.5z"/>
|
||||
</svg>
|
||||
|
||||
}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
@@ -761,7 +797,9 @@
|
||||
var deleteOneAjax = `@Url.Page("/Company/CustomizeCheckout/CheckoutTemporary", "DeleteOne")`;
|
||||
var deleteAllAjax = `@Url.Page("/Company/CustomizeCheckout/CheckoutTemporary", "DeleteAll")`;
|
||||
|
||||
|
||||
document.querySelectorAll('[data-bs-toggle="tooltip"]').forEach(el => {
|
||||
bootstrap.Tooltip.getOrCreateInstance(el);
|
||||
});
|
||||
</script>
|
||||
<script src="~/assetsclient/pages/CustomizeCheckout/js/CheckoutTemporary.js?ver=@clientVersion"></script>
|
||||
}
|
||||
}
|
||||
|
||||
@@ -410,7 +410,22 @@
|
||||
</div> *@
|
||||
<div class="Rtable-cell d-md-block d-none width6">
|
||||
<div class="Rtable-cell--heading">نام پرسنل</div>
|
||||
<div class="Rtable-cell--content ">@item.EmployeeFullName</div>
|
||||
<div class="Rtable-cell--content ">@item.EmployeeFullName
|
||||
@if (item.HasAmountConflict)
|
||||
{
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
width="24" height="24" fill="red"
|
||||
class="bi bi-exclamation-circle"
|
||||
viewBox="0 0 16 16"
|
||||
style="cursor: pointer; margin-left: 10px;"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-placement="top"
|
||||
title="توجه داشته باشید این فیش حقوقی دارای تغییرات اعمال نشده میباشد. جهت صدور فیش حقوقی استاندارد مجددا فیش را ایجاد کنید!">
|
||||
<path d="M8 15A7 7 0 1 0 8 1a7 7 0 0 0 0 14zm0 1A8 8 0 1 1 8 0a8 8 0 0 1 0 16z"/>
|
||||
<path d="M7.002 11a1 1 0 1 1 2 0 1 1 0 0 1-2 0zm.1-5.995a.905.905 0 0 1 1.8 0l-.35 3.5a.552.552 0 0 1-1.1 0l-.35-3.5z"/>
|
||||
</svg>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="Rtable-cell d-md-block d-none width7">
|
||||
<div class="Rtable-cell--heading">آغاز قرارداد</div>
|
||||
@@ -490,6 +505,20 @@
|
||||
<div class="Rtable-cell--content">
|
||||
<span class="mx-sm-2">
|
||||
@item.EmployeeFullName
|
||||
@if (item.HasAmountConflict)
|
||||
{
|
||||
<svg xmlns="http://www.w3.org/2000/svg"
|
||||
width="12" height="12" fill="red"
|
||||
class="bi bi-exclamation-circle"
|
||||
viewBox="0 0 16 16"
|
||||
style="cursor: pointer; margin-left: 10px;"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-placement="top"
|
||||
title="توجه داشته باشید این فیش حقوقی دارای تغییرات اعمال نشده میباشد. جهت صدور فیش حقوقی استاندارد مجددا فیش را ایجاد کنید!">
|
||||
<path d="M8 15A7 7 0 1 0 8 1a7 7 0 0 0 0 14zm0 1A8 8 0 1 1 8 0a8 8 0 0 1 0 16z"/>
|
||||
<path d="M7.002 11a1 1 0 1 1 2 0 1 1 0 0 1-2 0zm.1-5.995a.905.905 0 0 1 1.8 0l-.35 3.5a.552.552 0 0 1-1.1 0l-.35-3.5z"/>
|
||||
</svg>
|
||||
}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
@@ -763,6 +792,9 @@
|
||||
|
||||
var deleteOneAjax = `@Url.Page("/Company/CustomizeCheckout/CheckoutUnofficial", "DeleteOne")`;
|
||||
var deleteAllAjax = `@Url.Page("/Company/CustomizeCheckout/CheckoutUnofficial", "DeleteAll")`;
|
||||
document.querySelectorAll('[data-bs-toggle="tooltip"]').forEach(el => {
|
||||
bootstrap.Tooltip.getOrCreateInstance(el);
|
||||
});
|
||||
</script>
|
||||
<script src="~/assetsclient/pages/CustomizeCheckout/js/CheckoutUnofficial.js?ver=@clientVersion"></script>
|
||||
}
|
||||
Reference in New Issue
Block a user