From 0cd8d5b4cf827d76b48168c62e2e8ef454c2c351 Mon Sep 17 00:00:00 2001 From: MahanCh Date: Mon, 19 May 2025 18:29:36 +0330 Subject: [PATCH] change confirm insurance style --- .../InsuranceList/InsuranceConfirm.cshtml | 980 +++++++++--------- 1 file changed, 494 insertions(+), 486 deletions(-) diff --git a/ServiceHost/Areas/Admin/Pages/Company/InsuranceList/InsuranceConfirm.cshtml b/ServiceHost/Areas/Admin/Pages/Company/InsuranceList/InsuranceConfirm.cshtml index f00ecb45..46b64a38 100644 --- a/ServiceHost/Areas/Admin/Pages/Company/InsuranceList/InsuranceConfirm.cshtml +++ b/ServiceHost/Areas/Admin/Pages/Company/InsuranceList/InsuranceConfirm.cshtml @@ -40,8 +40,7 @@ align-items: center; margin: 1rem 0; } - - .last-div { + .last-div{ width: 100%; /* height: 55px; */ } @@ -73,18 +72,20 @@ margin: 0 9rem; } - @@page { + @@page { size: A4 landscape; } .table-container-employee { - display: flex; - width: 100%; - justify-content: space-between; + display: flex; + width: 100%; + justify-content: space-between; } .trTable:nth-child(2n) { - background-color: #f1f1f1 !important; + background-color: #f1f1f1 !important; + -webkit-print-color-adjust: exact !important; + print-color-adjust: exact !important; } #printThis .table-bordered .has-left-work p, #printThis .table-bordered .has-start-work p { @@ -208,15 +209,15 @@ } #printThis .colgp-12 { - width: 44px; + width: 44px; } #printThis .colgp-13 { - width: 44px; + width: 44px; } #printThis .colgp-14 { - width: 40px; + width: 40px; } #printThis .table-bordered > tbody > tr:nth-child(12n) td:first-child { @@ -242,10 +243,10 @@ align-items: center; } - .titleSection p { - margin: 0; - text-align: right; - } + .titleSection p{ + margin: 0; + text-align: right; + } .titles { margin-left: auto; @@ -344,9 +345,9 @@ width: 18px; } - #printThis .colgp-7 { - width: 44px; - } + #printThis .colgp-7 { + width: 44px; + } #printThis .colgp-8 { width: 44px; @@ -356,13 +357,13 @@ width: 44px; } - #printThis .colgp-10 { - width: 44px; - } + #printThis .colgp-10 { + width: 44px; + } - #printThis .colgp-11 { - width: 44px; - } + #printThis .colgp-11 { + width: 44px; + } #printThis .colgp-12 { width: 44px; @@ -384,14 +385,14 @@ width: 60px; } - .col-md-9, .col-sm-9, .col-lg-9 { + .col-md-9, .col-sm-9, .col-lg-9 { width: 75%; - float: right; - } + float: right; + } - .asignment { - width: 25%; - } + .asignment { + width: 25%; + } } @@media screen { @@ -410,8 +411,8 @@ margin: 0 !important; padding: 0 !important; overflow: clip; - -webkit-print-color-adjust: exact !important; - print-color-adjust: exact !important; + -webkit-print-color-adjust:exact !important; + print-color-adjust:exact !important; } .modal-dialog { @@ -432,7 +433,7 @@ } .size-a4 { - width: 276mm; + width: 276mm; } #printThis .table-container { @@ -447,27 +448,26 @@ width: 100%; max-height: 15cm; border: hidden !important; - border-right: 0; + border-right :0; border-left: 0; } - #printThis .table-bordered > thead > tr > th { - font-size: 10px; - color: black; - text-align: center; - vertical-align: middle; - padding: 0; - border: 1px solid black; - } - - #printThis .table-bordered > tbody > tr > td { - padding: 8px 2px; - text-align: center; - font-size: 1rem; - border: 1px solid black; - } + #printThis .table-bordered > thead > tr > th { + font-size: 10px; + color: black; + text-align: center; + vertical-align: middle; + padding: 0; + border: 1px solid black; + } + #printThis .table-bordered > tbody > tr > td { + padding: 8px 2px; + text-align: center; + font-size: 1rem; + border: 1px solid black; + } .summary { display: flex; justify-content: flex-end; @@ -495,24 +495,33 @@ color: grey !important; } - .row-color2 .fa-square:before { - color: grey !important; - } + .row-color2 .fa-square:before { + color: grey !important; + } #printThis .table-bordered .has-left-work td { background: black !important; color: white !important; } - #printThis .table-bordered .has-left-work td p { - color: white !important; - } + #printThis .table-bordered .has-left-work td p{ + color: white !important; + } #printThis .table-bordered .has-start-work td { background: grey !important; } + + #printThis .trTable.new-leftwork td { + background-color: #333333 !important; + color: #ffffff !important; + -webkit-print-color-adjust: exact !important; + print-color-adjust: exact !important; + } } + + @@ -542,24 +551,24 @@
- @* *@ + @* *@
-

- * سطر به رنگ - به معنای ترک کار پرسنل می باشد. -

-

- * سطر به رنگ به معنای شروع بکار پرسنل می باشد. -

-
+

+ * سطر به رنگ + به معنای ترک کار پرسنل می باشد. +

+

+ * سطر به رنگ به معنای شروع بکار پرسنل می باشد. +

+
-

تایید کارفرما جهت تنظیم لیست بیمه پرسنل

-
+

تایید کارفرما جهت تنظیم لیست بیمه پرسنل

+
- -
+ + @@ -587,307 +596,306 @@ - - توضیحات - مجموع مزایای ماهانه غیرمشمول - مجموع حقوق و مزایای ماهیانه - مجموع مزایای ماهیانه - حق تاهل - دستمزد ماهانه - پایه سنوات روزانه - دستمزد روزانه - روز کارکرد - سمت - کدملی - نام و نام خانوادگی - شماره بیمه - ردیف - + + توضیحات + مجموع مزایای ماهانه غیرمشمول + مجموع حقوق و مزایای ماهیانه + مجموع مزایای ماهیانه + حق تاهل + دستمزد ماهانه + پایه سنوات روزانه + دستمزد روزانه + روز کارکرد + سمت + کدملی + نام و نام خانوادگی + شماره بیمه + ردیف + - @{ - int count_j = 0; + @{ + int count_j = 0; - // count_j = (i == 0 ? (((CountList < 12) || (i == (q - 1) && CountList!=12)) ? r : 12) : (((CountList < 12) || (i == (q - 1))) ? r : 12)); + // count_j = (i == 0 ? (((CountList < 12) || (i == (q - 1) && CountList!=12)) ? r : 12) : (((CountList < 12) || (i == (q - 1))) ? r : 12)); - if (i == 0 && ((CountList < 12) || (i == (q - 1) && CountList != 12))) - { - count_j = r; - } - else if (i == 0 && (CountList >= 12 || (i != (q - 1)))) - { - count_j = 12; - } - else if (i != 0 && ((CountList < 12) || ((i == (q - 1)) && r != 0))) - { - count_j = r; - } - else - count_j = 12; - - - if (i == (q - 1)) - count_j = (i * 12) + count_j; - else - { - count_j = ((i + 1) * count_j); - } - } - @for (int j = (i * 12); j < count_j; j++) + if (i == 0 && ((CountList < 12) || (i == (q - 1) && CountList != 12))) { + count_j = r; + } + else if (i == 0 && (CountList >= 12 || (i != (q - 1)))) + { + count_j = 12; + } + else if (i != 0 && ((CountList < 12) || ((i == (q - 1))&& r!=0))) + { + count_j = r; + } + else + count_j = 12; + + + if (i == (q - 1)) + count_j = (i * 12) + count_j; + else + { + count_j = ((i + 1) * count_j); + } + } + @for (int j = (i * 12); j < count_j; j++) + { @**@ - - @if (i == (q - 1)) - { - - @if (!string.IsNullOrEmpty(Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate)) - { -

@Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate

- } - @if (Model.EmployeeDetailsForInsuranceList[j].HasStartWorkInMonth) - { -

@Model.EmployeeDetailsForInsuranceList[j].StartWorkDate

- } - - } - else - { - - @if (!string.IsNullOrEmpty(Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate)) - { -

@Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate

- } - @if (Model.EmployeeDetailsForInsuranceList[j].HasStartWorkInMonth) - { -

@Model.EmployeeDetailsForInsuranceList[j].StartWorkDate

- } - - } - @Model.EmployeeDetailsForInsuranceList[j].BenefitsIncludedNonContinuous.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].BenefitsIncludedContinuous.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].MonthlyBenefits.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].MarriedAllowance.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].MonthlySalary.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].BaseYears.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].DailyWage.ToMoney() - @Model.EmployeeDetailsForInsuranceList[j].WorkingDays - @Model.EmployeeDetailsForInsuranceList[j].JobName - @Model.EmployeeDetailsForInsuranceList[j].NationalCode - @(Model.EmployeeDetailsForInsuranceList[j].FName + " " + Model.EmployeeDetailsForInsuranceList[j].LName) - @Model.EmployeeDetailsForInsuranceList[j].InsuranceCode - @* @index *@ - @if (i == (q - 1)) - { - @index - } - else - { - @index - } + + @if (i == (q - 1)) + { + + @if (!string.IsNullOrEmpty(Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate)) + { +

@Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate

+ } + @if (Model.EmployeeDetailsForInsuranceList[j].HasStartWorkInMonth) + { +

@Model.EmployeeDetailsForInsuranceList[j].StartWorkDate

+ } + + } + else + { + + @if (!string.IsNullOrEmpty(Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate)) + { +

@Model.EmployeeDetailsForInsuranceList[j].LeftWorkDate

+ } + @if (Model.EmployeeDetailsForInsuranceList[j].HasStartWorkInMonth) + { +

@Model.EmployeeDetailsForInsuranceList[j].StartWorkDate

+ } + + } + @Model.EmployeeDetailsForInsuranceList[j].BenefitsIncludedNonContinuous.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].BenefitsIncludedContinuous.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].MonthlyBenefits.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].MarriedAllowance.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].MonthlySalary.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].BaseYears.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].DailyWage.ToMoney() + @Model.EmployeeDetailsForInsuranceList[j].WorkingDays + @Model.EmployeeDetailsForInsuranceList[j].JobName + @Model.EmployeeDetailsForInsuranceList[j].NationalCode + @(Model.EmployeeDetailsForInsuranceList[j].FName + " " + Model.EmployeeDetailsForInsuranceList[j].LName) + @Model.EmployeeDetailsForInsuranceList[j].InsuranceCode + @* @index *@ + @if (i == (q - 1)) + { + @index + } + else + { + @index + } - - index = index + 1; - } - @if (i == (q - 1) && (r > 0 && r <= 8)) - { - CountLastRow = 0; - hasLastRow = true; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedNonContinuous).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedContinuous).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlyBenefits).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.MarriedAllowance).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlySalary).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.BaseYears).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.DailyWage).ToMoney() - @Model.EmployeeDetailsForInsuranceList.Sum(x => x.WorkingDays) - - - - - - - } - else if (i == (q - 1) && (r > 0 && r <= 9)) - { - CountLastRow = 1; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - } - else if (i == (q - 1) && (r > 0 && r <= 10)) - { - CountLastRow = 2; - - - - - - - - - - - - - - - - - } + + index = index + 1; + } + @if (i == (q - 1) && (r>0 && r <= 8 )) + { + CountLastRow = 0; + hasLastRow = true; + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedNonContinuous).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedContinuous).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlyBenefits).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.MarriedAllowance).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlySalary).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.BaseYears).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.DailyWage).ToMoney() + @Model.EmployeeDetailsForInsuranceList.Sum(x => x.WorkingDays) + + + + + + + } + else if (i == (q - 1) && (r>0 && r <= 9)) + { + CountLastRow=1; + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + } + else if (i == (q - 1) && (r>0 && r <= 10)) + { + CountLastRow=2; + + + + + + + + + + + + + + + + + }
-
+
-
- @{ - var pageStartIndex = i * 12; - var pageEndIndex = (i == q - 1) ? ((i * 12) + r) : ((i + 1) * 12); +
+ @{ + var pageStartIndex = i * 12; + var pageEndIndex = (i == q - 1) ? ((i * 12) + r) : ((i + 1) * 12); - var pageEmployees = Model.EmployeeDetailsForInsuranceList - .Skip(pageStartIndex) - .Take(pageEndIndex - pageStartIndex) - .ToList(); - var pageEmployeeIds = pageEmployees.Select(x => x.EmployeeId).ToHashSet(); + var pageEmployees = Model.EmployeeDetailsForInsuranceList + .Skip(pageStartIndex) + .Take(pageEndIndex - pageStartIndex) + .ToList(); + var pageEmployeeIds = pageEmployees.Select(x => x.EmployeeId).ToHashSet(); - var leftWorkList = Model.LeftWorkEmployees - .Where(x => pageEmployeeIds.Contains(x.EmployeeId)) - .Select(x => new LeftWorkViewModel - { - EmployeeFullName = x.EmployeeFullName ?? "-", - LeftWorkDate = x.LeftWorkDate ?? "-" - }) - .ToList(); + var leftWorkList = Model.LeftWorkEmployees + .Where(x => pageEmployeeIds.Contains(x.EmployeeId)) + .Select(x => new LeftWorkViewModel { + EmployeeFullName = x.EmployeeFullName ?? "-", + LeftWorkDate = x.LeftWorkDate ?? "-" + }) + .ToList(); - while (leftWorkList.Count < 12) - { + while (leftWorkList.Count < 12) + { leftWorkList.Add(new LeftWorkViewModel { EmployeeFullName = "-", LeftWorkDate = "-" }); - } + } var tables = new List>(); - for (int t = 0; t < 3; t++) - { - tables.Add(leftWorkList.Skip(t * 4).Take(4).ToList()); - } - } + for (int t = 0; t < 3; t++) + { + tables.Add(leftWorkList.Skip(t * 4).Take(4).ToList()); + } + } -

هشدار پرسنل ذیل با توجه به تاریخ مندرج با مجموعه شما هیچگونه قرارداد کاری ندارند.

-
-
+

هشدار پرسنل ذیل با توجه به تاریخ مندرج با مجموعه شما هیچگونه قرارداد کاری ندارند.

+
+
+ + @for (int t = 0; t < tables.Count; t++) + { + var table = tables[t]; + + + + + - @for (int t = 0; t < tables.Count; t++) - { - var table = tables[t]; -
- - - - + + + + - - - - - - @foreach (var item in table) - { - - + - - } -
تاریخنام پرسنل
تاریخنام پرسنل
+ @foreach (var item in table) + { +
@item.LeftWorkDate + @item.EmployeeFullName
- } + } + + } + + - - - - @* + + @*
@@ -907,11 +915,11 @@
*@ -
-
-
+
+ +
- @*

* سطر به رنگ @@ -921,8 +929,8 @@ * سطر به رنگ به معنای شروع بکار پرسنل می باشد.

*@ -

صفحه @(i + 1) از @((r > 0 && r <= 8) ? q : q + 1)

-
+

صفحه @(i + 1) از @((r > 0 && r <= 8) ? q : q + 1)

+
@*
*@
امضا و تایید کارفرما
@@ -936,7 +944,7 @@ if (!hasLastRow) { -
+
@* *@ @@ -957,42 +965,129 @@
- - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + - @if (CountLastRow == 0) + @if (CountLastRow == 0) + { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + } + else if (CountLastRow == 2) + { + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + } + + else if (CountLastRow == 1) { @@ -1009,113 +1104,26 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - } - else if (CountLastRow == 2) - { - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + } - else if (CountLastRow == 1) - { - - - - - - - - - - - - - - - - - } - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + +
توضیحات مجموع مزایای ماهانه غیرمشمول مجموع حقوق و مزایای ماهیانه مجموع مزایای ماهیانه حق تاهل دستمزد ماهانه پایه سنوات روزانه دستمزد روزانه روز کارکرد سمت کدملی نام و نام خانوادگی شماره بیمه ردیف
توضیحات مجموع مزایای ماهانه غیرمشمول مجموع حقوق و مزایای ماهیانه مجموع مزایای ماهیانه حق تاهل دستمزد ماهانه پایه سنوات روزانه دستمزد روزانه روز کارکرد سمت کدملی نام و نام خانوادگی شماره بیمه ردیف
@Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedNonContinuous).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedContinuous).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlyBenefits).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.MarriedAllowance).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlySalary).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.BaseYears).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.DailyWage).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.WorkingDays)
@Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedNonContinuous).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.BenefitsIncludedContinuous).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlyBenefits).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.MarriedAllowance).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.MonthlySalary).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.BaseYears).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.DailyWage).ToMoney()@Model.EmployeeDetailsForInsuranceList.Sum(x => x.WorkingDays)
@@ -1130,7 +1138,7 @@ * سطر به رنگ به معنای شروع بکار پرسنل می باشد.

-

صفحه @(q + 1) از @(q + 1)

+

صفحه @(q+1) از @(q+1)