Files
Backend-Api/ServiceHost/Areas/Admin/Pages/Company/Checkouts/Details.cshtml
2025-05-20 20:30:50 +03:30

1472 lines
82 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
@using System.Security.Cryptography.X509Certificates
@model CompanyManagment.App.Contracts.Checkout.CheckoutViewModel
@{
var totalDays = Model.MonthlyRollCall?.Count ?? 0;
var rightSideDays = totalDays / 2;
var leftSideDays = totalDays - rightSideDays;
var maxRows = rightSideDays;
var rawHeight = (int)Math.Floor(300.0 / maxRows);
var rowHeight = Math.Max(15, Math.Min(16, rawHeight));
var calculateHeight = rowHeight + "px";
<style>
.modal .modal-dialog .modal-content {
background-color: white !important;
}
.modal-dialog {
max-width: 100%;
width: 22.4cm;
}
/* @@page {
size: 7in 9.25in;
margin: 27mm 16mm 27mm 16mm;
}*/
@@page {
size: A4;
margin: 0mm;
page-break-after: auto;
}
@@media screen {
#printSection {
display: none;
}
}
.print:last-child {
page-break-after: auto !important;
}
@@media print {
body * {
visibility: hidden;
page-break-after: auto;
}
html, body {
height: 100%;
margin: 0 !important;
padding: 0 !important;
overflow: hidden;
}
#printSection, #printSection * {
visibility: visible;
page-break-after: auto;
}
footer {
page-break-after: auto;
display: none;
}
header {
display: none;
}
#printSection {
position: absolute;
left: 0;
page-break-after: auto;
top: 0;
}
.head {
background-color: #cdcdcd !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.week {
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.radio-info input[type="radio"]:checked + label::after {
background-color: black !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
}
.col-xs-4, .col-xs-3, .col-xs-9,
.col-xs-2, .col-xs-10, .col-xs-6,
.col-xs-8, .col-xs-5, .col-xs-7,
.col-xs-offset-1 {
float: right !important;
}
h5, h6 {
margin: 5px 0px !important;
}
body .modal {
font-size: 11px;
}
label .modal {
margin-bottom: 2px;
}
.radio {
display: inline-block;
margin-top: -10px !important;
}
.radio input[type=radio] {
position: unset !important;
}
textarea.form-control {
height: 100px !important;
}
.fontBold {
font-family: IranYekanEXBold !important;
}
.fontNumber {
font-family: IranText !important;
}
.modal-body {
height: 99%;
}
.row {
margin-right: -10px !important;
margin-left: -10px !important;
}
div span.week {
/* border-radius: 5px;
padding: 2px 8px;
margin-right: 32px;
pointer-events: none;*/
}
#shanbeh, #yekshanbeh, #doshanbeh, #seshanbeh, #cheharshanbeh, #panjshanbeh, #jomeh {
width: 80px;
}
#Sh1, #Sh2, #Sh3, #Sh4, #Sh5, #Sh6, #Sh7, #Sh8 {
width: 80px;
margin-right: 21%;
border-radius: 15px;
font-size: 8px !important;
}
.week {
width: 48px !important;
border-radius: 5px;
padding: 1px !important;
font-size: 8px !important;
pointer-events: none;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.time {
width: 8%;
text-align: center;
padding: 0px !important;
direction: ltr;
border-radius: 5px;
border: 1px solid #47c848 !important;
pointer-events: none;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
font-size: 8px !important;
}
.time2 {
width: 8%;
text-align: center;
direction: ltr;
border-radius: 5px;
border: 1px solid #47c848 !important;
pointer-events: none;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
font-size: 8px !important;
}
.fild {
border: 1px solid #878686 !important;
background-color: #f7f7f7 !important;
border-radius: 10px;
margin: 5px 10px;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.fild2 {
border: 1px solid #878686 !important;
background-color: #d9d9d9 !important;
border-radius: 10px;
padding: 10px 0 10px 0;
display: inline;
float: left;
width: 80%;
margin-left: 15px;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.fild3 {
border: 1px solid #878686 !important;
background-color: #e7e7e7 !important;
border-radius: 10px;
display: inline;
float: left;
width: 100%;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.call {
background-color: #d2dbd2 !important;
border-radius: 5px;
margin-bottom: 3px;
margin-left: 10px;
margin-right: 10px;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.rest {
pointer-events: none;
font-size: 8px !important;
}
.shiftDisplayNone {
display: none;
}
.fildeWeek {
height: 126px !important;
width: 48% !important;
display: inline-block;
border: 1px solid #cfcfcf !important;
background-color: #e7e5e5 !important;
border-radius: 12px 0px 12px 12px;
padding: 2px 15px !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.fildeWeek .row {
height: 16px;
}
.weekName {
margin-bottom: -8px !important;
top: -8px;
position: relative;
margin-right: -16px;
padding-right: 5px !important;
font-size: 10px !important;
border-bottom: 0px;
color: #505458 !important;
background-color: #bdd1be !important;
border-radius: 15px 5px 0px 0px;
width: 57px;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
}
.trTable:nth-child(even) {
background-color: #F6F6F6 !important;
}
.headerInfo {
border-radius: 6px;
border: 1px solid #000000 !important;
}
.cusSpanTitle {
border-radius: 4px;
font-weight: bold;
background-color: #ebe6e6 !important;
-webkit-print-color-adjust: exact;
print-color-adjust: exact;
padding: 0 3px;
margin: auto 4px;
}
.table-container {
display: flex;
width: 100%;
justify-content: space-between;
}
.shiftWorkContainerMsg {
position: relative;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
border: 1px solid #D9D9D9 !important;
border-radius: 7px;
color: #1F1F1F !important;
font-size: 16px !important;
gap: 9px;
padding: 15px 21px;
max-width: 380px;
margin: auto;
}
.shiftTitle {
position: absolute;
top: -10px;
right: 5px;
padding: 2px 4px;
color: #000000 !important;
font-size: 12px !important;
background-color: #F6F6F6 !important;
}
.shiftTime {
display: flex;
align-items: center;
justify-content: center;
gap: 6px;
}
</style>
}
<div class="modal-header" style="border-bottom: unset">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
</div>
<form asp-page="./Index" asp-page-handler="Details"
method="post"
data-ajax="true"
data-callback=""
data-action="Refresh"
enctype="multipart/form-data">
<div class="modal-body print" id="printThis">
<div class="row">
<div class="col-md-12">
<fieldset style="border: 1px solid black; padding: revert; border-radius: 10px; height: 28cm; margin: 3mm 5mm 0 5mm;">
<div class="row" dir="rtl">
<div class="col-xs-3 d-inline-block"><fieldset style="border: 1px solid black; border-radius: 15px; padding: 1px 15px 1px 15px; margin-top: 5px; width: 60%; font-size: 12px; text-align: center;"> @Model.ContractNo</fieldset></div>
<div class="col-xs-6 d-inline-block text-center">
<p style="font-size: 18px; font-family: 'IranNastaliq' !important; margin: 0;">بسمه تعالی</p>
<p style="font-size: 15px; font-weight: bold; margin: 0;">فیش حقوقی و رسید پرداخت حقوق</p>
</div>
<div class="col-xs-3 d-inline-block"></div>
</div>
<div class="headerInfo">
<div class="row" style="font-size: 12px; margin-bottom: 3px;">
<div class="col-xs-12" style="padding: 0 10px;">
<div style="display: flex; align-items: center; border-bottom: 1px solid #000000 !important;">
<div style="width: 34%; padding: 3px 0 !important;">
<div>
<span class="cusSpanTitle">اینجانب</span>
<span>@Model.EmployeeFullName</span>
</div>
</div>
<div style="width: 22%; padding: 3px 0 !important; border-right: 1px solid #000000 !important;">
<span class="cusSpanTitle">نام پدر<span>:</span></span>
@if (string.IsNullOrWhiteSpace(@Model.FathersName))
{
<span style="visibility: hidden">""</span>
}
else
{
<span>@Model.FathersName</span>
}
</div>
<div style="width: 22%; padding: 3px 0 !important; border-right: 1px solid #000000 !important;">
<span class="cusSpanTitle">به کد ملی<span>:</span></span>
@if (string.IsNullOrWhiteSpace(@Model.NationalCode))
{
<span style="margin-left: 15px; visibility: hidden"></span>
}
else
{
<span>
@Model.NationalCode
</span>
}
</div>
<div style="width: 22%; padding: 3px 0 !important; border-right: 1px solid #000000 !important;">
<span class="cusSpanTitle">متولد<span>:</span></span>
@if (string.IsNullOrWhiteSpace(@Model.DateOfBirth))
{
<span style="visibility: hidden">1401/01/01</span>
}
else
{
<span>@Model.DateOfBirth</span>
}
</div>
</div>
</div>
<div class="col-xs-12" style="font-size: 12px; text-align: justify; padding: 0 10px;">
<div style="display: flex; align-items: center; border-bottom: 1px solid #000000 !important; height: 23px; padding: 0;">
@{
if (@Model.EmployerList.FirstOrDefault().IsLegal == "حقیقی")
{
<div style="width: 50%; padding: 3px 0 !important;">
<div>
<span class="cusSpanTitle">نام کارگاه<span>:</span> </span>
<span>@Model.WorkshopName</span>
</div>
</div>
<div style="width: 50%; padding: 3px 0 !important; border-right: 1px solid #000000 !important;">
<span class="cusSpanTitle">نام کارفرما<span>:</span> </span>
@if (Model.EmployerList.Count > 1)
{
<span>
@Model.EmployerList[0].EmployerFullName <span>،</span>
<span>&nbsp;</span>@Model.EmployerList[1].EmployerFullName
@if (@Model.EmployerList.Count > 2)
{
<span>و غیره</span>
}
</span>
}
else
{
<span>
@Model.EmployerList.FirstOrDefault().EmployerFullName
</span>
}
</div>
}
else if (@Model.EmployerList.FirstOrDefault().IsLegal == "حقوقی")
{
<div style="width: 100%; padding: 3px 0 !important;">
<span class="cusSpanTitle">پـرسنل شرکت/موسسه<span>:</span> </span>
<span>
@Model.WorkshopName
</span>
</div>
}
}
</div>
<div style="text-align: justify; padding: 0 6px;">
@{
var items = new List<string>();
if (Model.MonthlySalary != "0") items.Add("حقوق و مزد");
if (Model.ConsumableItems != "0") items.Add("کمک هزینه اقلام مصرفی خانوار");
if (Model.HousingAllowance != "0") items.Add("کمک هزینه مسکن");
if (!string.IsNullOrWhiteSpace(Model.OvertimePay) && Model.OvertimePay != "0") items.Add("فوق العاده اضافه کاری");
if (!string.IsNullOrWhiteSpace(Model.NightworkPay) && Model.NightworkPay != "0") items.Add("فوق العاده شب کاری");
if (!string.IsNullOrWhiteSpace(Model.FridayPay) && Model.FridayPay != "0") items.Add("فوق العاده جمعه کاری");
if (Model.MissionPay != "0") items.Add("فوق العاده ماموریت");
if (Model.ShiftPay != "0") items.Add("فوق العاده نوبت کاری");
if (Model.FamilyAllowance != "0") items.Add("کمک هزینه عائله مندی");
if (Model.MarriedAllowance != "0") items.Add("حق تاهل");
if (Model.RewardPay != "0") items.Add("پاداش");
if (Model.BonusesPay != "0") items.Add("عیدی و پاداش");
if (Model.YearsPay != "0") items.Add("سنوات");
if (Model.LeavePay != "0") items.Add("مزد مرخصی");
string finalText = "";
if (items.Count == 1)
{
finalText = items[0];
}
else if (items.Count > 1)
{
finalText = string.Join("<span>،</span> ", items.Take(items.Count - 1)) + " و " + items.Last();
}
}
<span>
کلیه حق السعی خود اعم از @Html.Raw(finalText) @Model.Month ماه سال @Model.Year برابر با قرارداد به شماره فوق را از کارفرما بصورت وجه نقد و واریز به حساب دریافت نموده ام.
</span>
</div>
</div>
</div>
</div>
<div class="row" style="margin-top: 10px; padding: 0 12px;">
<fieldset style="border: 1px solid black !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; border-radius: 10px 10px 10px 10px; margin: 0px 0px; overflow: hidden; padding: 0;">
<table style="/* table-layout: fixed; */width: 100%">
<tr style="border-bottom: 1px solid; height: 25px; border-collapse: separate; background-color: #cdcdcd !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
@* <th style="text-align: center; width: 8mm; font-size: 12px; padding: 2px; border-collapse: separate; border-radius: 0px 10px 0px 0px;"> </th> *@
<th colspan="4" style="text-align: center; position: relative; font-size: 13px; padding-top: 4px; border-left: 2px solid #000;"> مطالبات </th>
@* <th style="text-align: center;"> </th>
<th style="text-align: center; border-left: 2px solid #000; font-size: 12px"> </th> *@
<th colspan="3" style="text-align: center; font-size: 13px; position: relative; padding-top: 4px;"> کسورات </th>
@* <th style="text-align: center; font-size: 12px; border-collapse: separate; border-radius: 0px 0px 0px 0px;"> </th>
<th style="text-align: center; font-size: 12px; border-collapse: separate; border-radius: 10px 0px 0px 0px;"> </th> *@
</tr>
<tr style="border-bottom: 1px solid; background-color: #e1e1e1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<th style="width: 5%; text-align: center; border-left: 1px solid #000; font-size: 12px; padding: 2px"> ردیف </th>
<th style="width: 23%; text-align: center; border-left: 1px solid #000; font-size: 12px"> شرح </th>
<th style="width: 10%; text-align: center; border-left: 1px solid #000; font-size: 9px"> ساعت/روز/تعداد </th>
<th style="width: 12%; text-align: center; border-left: 2px solid #000; font-size: 12px"> مبلغ(ریال) </th>
<th style="width: 28%; text-align: center; border-left: 1px solid #000; font-size: 12px"> شرح </th>
<th style="width: 10%; text-align: center; border-left: 1px solid #000; font-size: 9px"> ساعت/روز/تعداد </th>
<th style="width: 12%; text-align: center; font-size: 12px"> مبلغ(ریال) </th>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">1</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> حقوق و مزد </td>
<td style="text-align: center; border-left: 1px solid #000;"> @Model.SumOfWorkingDays </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.MonthlySalary == "0" ? "-" : Model.MonthlySalary) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> حق بیمه سهم کارگر </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center;"> @(Model.InsuranceDeduction == "0" ? "-" : Model.InsuranceDeduction) </td>
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">2</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> پایه سنوات </td>
<td style="text-align: center; border-left: 1px solid #000;"> @(Model.BaseYearsPay == "0" ? "-" : Model.SumOfWorkingDays) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.BaseYearsPay == "0" ? "-" : Model.BaseYearsPay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> مالیات بر حقوق </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center;"> @(Model.TaxDeducation == "0" ? "-" : Model.TaxDeducation) </td>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">3</td>
<td style="padding-right: 8px; border-left: 1px solid #000; white-space: nowrap;"> کمک هزینه اقلام مصرفی خانوار </td>
<td style="text-align: center; border-left: 1px solid #000;"> @(Model.ConsumableItems == "0" ? "-" : Model.SumOfWorkingDays) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.ConsumableItems == "0" ? "-" : Model.ConsumableItems) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> قسط تسهیلات </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center;"> @(Model.InstallmentDeduction == "0" ? "-" : Model.InstallmentDeduction) </td>
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">4</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> کمک هزینه مسکن </td>
<td style="text-align: center; border-left: 1px solid #000;"> @(Model.HousingAllowance == "0" ? "-" : Model.SumOfWorkingDays) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.HousingAllowance == "0" ? "-" : Model.HousingAllowance) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> مساعده </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center;"> @(Model.SalaryAidDeduction == "0" ? "-" : Model.SalaryAidDeduction) </td>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">5</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> فوق العاده اضافه کاری </td>
<td style="text-align: center; border-left: 1px solid #000;"> @((Model.OverTimeWorkValue == "00:00" || string.IsNullOrWhiteSpace(Model.OverTimeWorkValue)) ? "-" : Model.OverTimeWorkValue) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @((Model.OvertimePay == "0" || string.IsNullOrWhiteSpace(Model.OvertimePay)) ? "-" : Model.OvertimePay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> غیبت </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center;"> @(Model.AbsenceDeduction == "0" ? "-" : Model.AbsenceDeduction) </td>
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">6</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> فوق العاده شب کاری </td>
<td style="text-align: center; border-left: 1px solid #000;"> @((Model.OverNightWorkValue == "00:00" || string.IsNullOrWhiteSpace(Model.OverNightWorkValue)) ? "-" : Model.OverNightWorkValue) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @((Model.NightworkPay == "0" || string.IsNullOrWhiteSpace(Model.NightworkPay)) ? "-" : Model.NightworkPay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"></td>
<td style="text-align: center; border-left: 1px solid #000;"></td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">7</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> فوق العاده جمعه کاری </td>
<td style="text-align: center; border-left: 1px solid #000;"> @((Model.FridayWorkValue == "0" || string.IsNullOrWhiteSpace(Model.FridayWorkValue)) ? "-" : Model.FridayWorkValue) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @((Model.FridayPay == "0" || string.IsNullOrWhiteSpace(Model.FridayPay)) ? "-" : Model.FridayPay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"></td>
<td style="text-align: center; border-left: 1px solid #000;"></td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">8</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> فوق العاده ماموریت </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.MissionPay == "0" ? "-" : Model.MissionPay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">9</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> فوق العاده نوبت کاری </td>
<td style="text-align: center; border-left: 1px solid #000;"> @((Model.RotatingShiftValue == "0" || string.IsNullOrWhiteSpace(Model.RotatingShiftValue)) ? "-" : "%" + Model.RotatingShiftValue) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.ShiftPay == "0" ? "-" : Model.ShiftPay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">10</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> کمک هزینه عائله مندی </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.FamilyAllowance == "0" ? "-" : Model.FamilyAllowance) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">11</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> حق تاهل </td>
<td style="text-align: center; border-left: 1px solid #000;"> @Model.MaritalStatus </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.MarriedAllowance == "0" ? "-" : Model.MarriedAllowance) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">12</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> پاداش </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.RewardPay == "0" ? "-" : Model.RewardPay) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">13</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> عیدی و پاداش </td>
<td style="text-align: center; border-left: 1px solid #000;"> @(Model.BonusesPay == "0" ? "-" : Model.SumOfWorkingDays) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.BonusesPay == "0" ? "-" : Model.BonusesPay) </td>
@{
if (Model.IsLeft)
{
<td style="text-align: center; background-color: #ffffff !important;" colspan="3" rowspan="3">
<div style="border-top: 1px solid #000; border-top-left-radius: 15px; border-top-right-radius: 15px; height: 65px;">
<div style="padding: 0 6px; text-align: start; display: block; align-items: center; height: 64px; margin: 6px;">
<span>طبق تصفیه حساب نهایی تنظیمی فوق، آخرین روز اشتغال بکار اینجانب</span>
<span>@Model.LastDayOfWork</span>
<span>بوده و قطع همکاری با کارفرما و کارگاه از تاریخ</span>
<span>@Model.LeftWorkDate</span>
<span>می باشد</span>
</div>
</div>
</td>
}
else
{
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
}
}
</tr>
<tr style="font-size: 12px; background-color: #f1f1f1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">14</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> سنوات </td>
<td style="text-align: center; border-left: 1px solid #000;"> @(Model.YearsPay == "0" ? "-" : Model.SumOfWorkingDays)</td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.YearsPay == "0" ? "-" : Model.YearsPay) </td>
@{
if (!Model.IsLeft)
{
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
}
}
</tr>
<tr style="font-size: 12px;">
<td style="text-align: center; border-left: 1px solid #000; padding: 2px">15</td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> مزد مرخصی </td>
<td style="text-align: center; border-left: 1px solid #000;"> @(Model.LeavePay == "0" ? "-" : Model.SumOfWorkingDays) </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.LeavePay == "0" ? "-" : Model.LeavePay) </td>
@{
if (!Model.IsLeft)
{
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center;"> </td>
}
}
</tr>
<tr style="font-size: 12px; height: 20px; background-color: #dddcdc !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; border-bottom: 1px solid #000; border-top: 1px solid #000;">
<td style="text-align: center; padding: 2px"></td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> جمع مطالبات </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.TotalClaims == "0" ? "-" : Model.TotalClaims) </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> جمع کسورات </td>
<td style="text-align: center; border-left: 1px solid #000;"> - </td>
<td style="text-align: center;"> @(Model.TotalDeductions == "0" ? "-" : Model.TotalDeductions) </td>
</tr>
<tr style="font-size: 12px; border-radius: 0px 0px 10px 10px !important; height: 20px; background-color: #efefef !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="text-align: center; padding: 2px; border-radius: 0px 0px 10px 0px"></td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> مبلغ قابل پرداخت </td>
<td style="padding-right: 8px; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-left: 2px solid #000;"> @(Model.TotalPayment == "0" ? "-" : Model.TotalPayment) </td>
<td style="padding-right: 8px;"> </td>
<td style="text-align: center; border-left: 1px solid #000;"> </td>
<td style="text-align: center; border-radius: 0px 0px 0px 10px"> </td>
</tr>
</table>
</fieldset>
</div>
<div class="row" style="margin-top: 10px; padding: 0 12px;">
<fieldset style="border: 1px solid black !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; border-radius: 10px 10px 10px 10px; margin: 0px 0px; overflow: hidden; padding: 0; display: flex; width: 100%;">
<div class="table-container">
<table style="width: 100%;">
<colgroup>
<col style="width: 12%;">
<col style="width: 12%;">
<col style="width: 12%;">
<col style="width: 7%;">
<col style="width: 7%;">
<col style="width: 12%;">
<col style="width: 12%;">
<col style="width: 12%;">
<col style="width: 7%;">
<col style="width: 7%;">
</colgroup>
<tr style="text-align: center; color:#ffffff !important;font-size: 10px; padding: 1px 4px; height: 20px; border-bottom: 1px solid; border-collapse: separate; background-color: #575656 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<th colspan="10" style="text-align: center; color:#ffffff !important;font-size: 10px;">فیش حقوقی بدون سیستم هوشمند حضور غیاب</th>
</tr>
@if (Model.CreateWorkingHoursTemp.ShiftWork == "4")
{
<tr style="border-bottom: 1px solid; background-color: #F6F6F6 !important; font-size: 10px; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<th style="width: 12%; text-align: start; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px; padding: 2px"> تاریخ </th>
<th style="width: 12%; text-align: center; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px"> مقطع اول کار </th>
<th style="width: 12%; text-align: center; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px"> مقطع دوم کار </th>
<th style="width: 7%; text-align: center; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px"> استراحت </th>
<th style="width: 7%; text-align: center; border-bottom: 1px solid #000; border-left: 2px solid #000; font-size: 10px"> جمع </th>
<th style="width: 12%; text-align: start; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px; padding: 2px"> تاریخ </th>
<th style="width: 12%; text-align: center; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px"> مقطع اول کار </th>
<th style="width: 12%; text-align: center; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px"> مقطع دوم کار </th>
<th style="width: 7%; text-align: center; border-bottom: 1px solid #000; border-left: 1px solid #000; font-size: 10px"> استراحت </th>
<th style="width: 7%; text-align: center; border-bottom: 1px solid #000; font-size: 10px"> جمع </th>
</tr>
@for (int i = 0; i < 16; i++)
{
@* var dailyStatic = Model.MonthlyRollCall[i]; *@
@* var leftItem = i < leftSideDays ? Model.MonthlyRollCall[i] : null; *@
var leftItem = i < 15 ? Model.MonthlyRollCall[i] : null;
@* var rightItem = i < rightSideDays ? Model.MonthlyRollCall[i + leftSideDays] : null; *@
var rightIndex = 15 + i;
var rightItem = rightIndex < Model.MonthlyRollCall.Count ? Model.MonthlyRollCall[rightIndex] : null;
<tr class="trTable" style="font-size: 10px; height: @calculateHeight;">
@* section one *@
<td style="font-size: 8px; text-align: start; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((leftItem?.IsHoliday ?? false) || (leftItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(leftItem?.RollCallDateFa ?? "") @(leftItem?.DayOfWeek ?? "")
</td>
@if (string.IsNullOrWhiteSpace(leftItem?.LeaveType))
{
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((leftItem?.IsHoliday ?? false) || (leftItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(!String.IsNullOrWhiteSpace(leftItem?.StartDate1) ? leftItem?.StartDate1 + " الی " + leftItem?.EndDate1 : "")
</td>
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((leftItem?.IsHoliday ?? false) || (leftItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(!String.IsNullOrWhiteSpace(leftItem?.StartDate2) ? leftItem?.StartDate2 + " الی " + leftItem?.EndDate2 : "")
</td>
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((leftItem?.IsHoliday ?? false) || (leftItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(leftItem?.BreakTimeString ?? "")
</td>
}
else
{
<td colspan="3" style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((leftItem?.IsHoliday ?? false) || (leftItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
<span style="color: #737373; border-radius: 30px; border: 1px solid #737373; padding: 0px 6px; font-size: 7px;">@leftItem?.LeaveType</span>
</td>
}
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 2px solid black; background-color: @((leftItem?.IsHoliday ?? false) || (leftItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(leftItem?.TotalWorkingHours ?? "")
</td>
@* section two *@
<td style="font-size: 8px; text-align: start; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((rightItem?.IsHoliday ?? false) || (rightItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(rightItem?.RollCallDateFa ?? "") @(rightItem?.DayOfWeek ?? "")
</td>
@if (string.IsNullOrWhiteSpace(rightItem?.LeaveType))
{
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((rightItem?.IsHoliday ?? false) || (rightItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(!String.IsNullOrWhiteSpace(rightItem?.StartDate1) ? rightItem?.StartDate1 + " الی " + rightItem?.EndDate1 : "")
</td>
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((rightItem?.IsHoliday ?? false) || (rightItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(!String.IsNullOrWhiteSpace(rightItem?.StartDate2) ? rightItem?.StartDate2 + " الی " + rightItem?.EndDate2 : "")
</td>
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((rightItem?.IsHoliday ?? false) || (rightItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(rightItem?.BreakTimeString ?? "")
</td>
}
else
{
<td colspan="3" style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;") border-left: 1px solid black; background-color: @((rightItem?.IsHoliday ?? false) || (rightItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
<span style="color: #737373; border-radius: 30px; border: 1px solid #737373; padding: 0px 6px; font-size: 7px;">@rightItem?.LeaveType</span>
</td>
}
<td style="font-size: 8px; text-align: center; @(i == 15 ? "" : "border-bottom: 1px solid #000;"); background-color: @((rightItem?.IsHoliday ?? false) || (rightItem?.IsFriday ?? false) ? "#BBBBBB !important" : "#FFFFFF !important")">
@(rightItem?.TotalWorkingHours ?? "")
</td>
</tr>
}
}
else
{
//[12-24 : 5] [24-24 : 6] [12-36 : 7] [24-48 : 8]
var shiftType = Model.CreateWorkingHoursTemp.ShiftWork switch
{
"5"=>"12 ساعت کار / 24 ساعت استراحت",
"6"=>"24 ساعت کار / 24 ساعت استراحت",
"7"=>"12 ساعت کار / 36 ساعت استراحت",
"8"=>"24 ساعت کار / 48 ساعت استراحت",
_=>""
};
<tr style="border-bottom: 1px solid; background-color: #F6F6F6 !important; font-size: 10px;">
<td colspan="10" style="text-align: center; font-size: 8px; padding: 2px; height: 270px; vertical-align: middle;">
<div class="shiftWorkContainerMsg">
<div class="shiftTitle">شیفت کاری</div>
<div style="text-align: center;">
<div>ساعات ‌کاری این پرسنل در قالب</div>
<div>@shiftType</div>
</div>
<div class="shiftTime">
<svg width="22" height="22" viewBox="0 0 22 22" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M11 6.41667V11H8.25M19.25 11C19.25 15.5564 15.5564 19.25 11 19.25C6.44365 19.25 2.75 15.5564 2.75 11C2.75 6.44365 6.44365 2.75 11 2.75C15.5564 2.75 19.25 6.44365 19.25 11Z" stroke="#1F1F1F" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" />
</svg>
<span>@Model.CreateWorkingHoursTemp.StartComplex الی @Model.CreateWorkingHoursTemp.EndComplex</span>
</div>
</div>
</td>
</tr>
}
<tr style="height: 20px; border-bottom: 1px solid; color:#ffffff !important; background-color: #575656 !important; font-size: 10px; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td colspan="5" style="color:#ffffff !important; text-align: center; border-bottom: 1px solid #CCCCCC; border-left: 1px solid #CCCCCC; font-size: 8px; padding: 2px"> مدت مرخصی استحقاقی <span>:</span> @Model.TotalPaidLeave </td>
<td colspan="5" style="color:#ffffff !important; text-align: center; border-bottom: 1px solid #CCCCCC; font-size: 8px; padding: 2px"> مدت مرخصی استعلاجی <span>:</span> @Model.TotalSickLeave </td>
</tr>
<tr>
<td colspan="10" style="padding: 0;">
<table style="width: 100%; table-layout: fixed;">
<tr style="height: 20px; color:#ffffff !important; background-color: #575656 !important; font-size: 10px; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<td style="color:#ffffff !important; width:25%; text-align: center; border-left: 1px solid #CCCCCC; font-size: 8px; padding: 2px"> موظفی @Model.Month @Model.Year <span>:</span> @Model.TotalMandatoryTimeStr </td>
<td style="color:#ffffff !important; width:25%; text-align: center; border-left: 1px solid #CCCCCC; font-size: 8px; padding: 2px"> ساعات حضور <span>:</span> @Model.TotalPresentTimeStr </td>
<td style="color:#ffffff !important; width:25%; text-align: center; border-left: 1px solid #CCCCCC; font-size: 8px; padding: 2px"> ساعات استراحت <span>:</span> @Model.TotalBreakTimeStr </td>
<td style="color:#ffffff !important; width:25%; text-align: center; font-size: 8px; padding: 2px"> ساعات کارکرد واقعی <span>:</span> @Model.TotalWorkingTimeStr </td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</fieldset>
</div>
<div class="" style="margin: 10px 0 0 0;display: flex;gap: 0px;">
<div style="width: 65%;">
<div style="display: flex; gap: 10px;">
<fieldset style="border: 1px solid black !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; border-radius: 10px 10px 10px 10px; margin: 0px 0px; overflow: hidden; padding: 0; display: flex; width: 50%;">
<div class="table-container">
<table style="width: 100%;">
<colgroup>
<col style="width: 50%;">
<col style="width: 50%;">
</colgroup>
<tr style="text-align: center; font-size: 10px; padding: 1px 4px; height: 15px; border-bottom: 1px solid; border-collapse: separate; background-color: #cdcdcd !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<th colspan="3" style="text-align: center; font-size: 11px;">مساعده</th>
</tr>
<tr style="border-bottom: 1px solid; background-color: #e1e1e1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; font-size: 9px; height: 15px;">
<th style="padding: 1px 4px; text-align: center; border-left: 1px solid black; min-width: 3rem; font-size: 11px;">تاریخ</th>
<th style="padding: 1px 4px; text-align: center; min-width: 4rem; font-size: 11px;">مبلغ</th>
</tr>
@for (int i = 0; i < 5; i++)
{
<tr class="trTable" style="text-align: right; font-size: 10px; height: 15px;">
<td style="font-size: 8px; text-align: center;border-left: 1px solid black">
@(Model.SalaryAidViewModels != null && i < Model.SalaryAidViewModels.Count
? Model.SalaryAidViewModels[i]?.SalaryAidDateTimeFa ?? ""
: "")
</td>
<td style="font-size: 8px; text-align: center;">
@(Model.SalaryAidViewModels != null && i < Model.SalaryAidViewModels.Count
? Model.SalaryAidViewModels[i]?.Amount ?? ""
: "")
</td>
</tr>
}
</table>
</div>
</fieldset>
<fieldset style="border: 1px solid black !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; border-radius: 10px 10px 10px 10px; margin: 0px 0px; overflow: hidden; padding: 0; display: flex; width: 50%;">
<div class="table-container">
<table style="width: 100%;">
<colgroup>
<col style="width: 30%;">
<col style="width: 35%;">
<col style="width: 35%;">
</colgroup>
<tr style="text-align: center; font-size: 11px; padding: 1px 4px; height: 15px; border-bottom: 1px solid; border-collapse: separate; background-color: #cdcdcd !important; -webkit-print-color-adjust: exact; print-color-adjust: exact;">
<th colspan="3" style="text-align: center; font-size: 11px;">وام</th>
</tr>
<tr style="border-bottom: 1px solid; background-color: #e1e1e1 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; font-size: 9px; height: 15px;">
<th style="padding: 1px 4px; text-align: center; border-left: 1px solid black; min-width: 4rem;font-size: 10px;">مبلغ کل</th>
<th style="padding: 1px 4px; text-align: center; border-left: 1px solid black; min-width: 4rem;font-size: 10px;">مبلغ هر قسط</th>
<th style="padding: 1px 4px; text-align: center; min-width: 4rem;font-size: 10px;">مبلغ باقیمانده</th>
</tr>
@for (int i = 0; i < 5; i++)
{
<tr class="trTable" style="text-align: right; font-size: 9px; height: 15px;">
<td style="font-size: 8px; text-align: center;border-left: 1px solid black">
@(Model.InstallmentViewModels != null && i < Model.InstallmentViewModels.Count
? Model.InstallmentViewModels[i]?.LoanAmount ?? ""
: "")
</td>
<td style="font-size: 8px; text-align: center;border-left: 1px solid black">
@(Model.InstallmentViewModels != null && i < Model.InstallmentViewModels.Count
? Model.InstallmentViewModels[i]?.Amount ?? ""
: "")
</td>
<td style="font-size: 8px; text-align: center;">
@(Model.InstallmentViewModels != null && i < Model.InstallmentViewModels.Count
? Model.InstallmentViewModels[i]?.RemainingAmount ?? ""
: "")
</td>
</tr>
}
</table>
</div>
</fieldset>
</div>
</div>
<div style="width: 40%; display: flex; justify-content: end;align-items: end;">
<div style="display: flex; justify-content: end;" class="signSection">
<div style="margin-left: 15px; position: relative; width: 80px; border: 1px solid #000; height: 114px; border-radius: 10px;">
<span style="border-collapse: separate; background-color: #FFFFFF !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; font-size: 12px; margin: -10px 8px 0 0; display: table-caption; padding: 0 4px; white-space: nowrap;">اثر انگشت</span>
</div>
<div style="position: relative; width: 160px; border: 1px solid #000; height: 114px; border-radius: 10px;">
<span style="border-collapse: separate; background-color: #FFFFFF !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; font-size: 12px; margin: -10px 54px 0 0; display: table-caption; padding: 0 4px;">امضاء</span>
</div>
</div>
</div>
</div>
</fieldset>
</div>
</div>
</div>
<input type="hidden" asp-for="Id" value="@Model.Id" />
<input type="hidden" id="shiftWorkval" name="shiftWorkval" value="@Model.CreateWorkingHoursTemp.ShiftWork">
<div class="modal-footer" style="border-top: unset; padding: 1px 15px 10px;">
<button id="btnPrint" type="button" class="btn btn-success btn-rounded waves-effect waves-light">پرینت قرارداد </button>
<button type="button" id="closingOnePrint" class="btn btn-warning btn-rounded waves-effect waves-light m-b-10" data-dismiss="modal">بستن فرم</button>
</div>
</form>
<!--<script src="~/AdminTheme/assets/js/workingHoursPrintable.js"></script>-->
<script>
var shiftNumber = $('#shiftWorkval').val();
if (shiftNumber === "4") {
$('#ComplexFildset').addClass("shiftDisplayNone");
$('#WeeklyFildset').removeClass("shiftDisplayNone");
} else {
$('#WeeklyFildset').addClass("shiftDisplayNone");
$('#ComplexFildset').removeClass("shiftDisplayNone");
}
if ($('#fw1').is(":checked")) {//شنبه
$('#shanbehw1').addClass("btn-active");
} else {
$('#shanbehw1').removeClass("btn-active");
$('#shanbehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#shanbehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f1w1').is(":checked")) {//یکشنبه
$('#yekshanbehw1').addClass("btn-active");
} else {
$('#yekshanbehw1').removeClass("btn-active");
$('#yekshanbehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#yekshanbehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f2w1').is(":checked")) {//دوشنبه
$('#doshanbehw1').addClass("btn-active");
} else {
$('#doshanbehw1').removeClass("btn-active");
$('#doshanbehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#doshanbehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f3w1').is(":checked")) {//سه شنبه
$('#seshanbehw1').addClass("btn-active");
} else {
$('#seshanbehw1').removeClass("btn-active");
$('#seshanbehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#seshanbehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f4w1').is(":checked")) {//چهارشنبه
$('#cheharshanbehw1').addClass("btn-active");
} else {
$('#cheharshanbehw1').removeClass("btn-active");
$('#cheharshanbehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#cheharshanbehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f5w1').is(":checked")) {//پنجشنبه
$('#panjshanbehw1').addClass("btn-active");
} else {
$('#panjshanbehw1').removeClass("btn-active");
$('#panjshanbehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#panjshanbehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f6w1').is(":checked")) {//جمعه
$('#jomehw1').addClass("btn-active");
} else {
$('#jomehw1').removeClass("btn-active");
$('#jomehRow3w1 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
$(this).val("");
});
$('#jomehRow3w1 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
//week2 days by value
if ($('#fw2').is(":checked")) {//شنبه
$('#shanbehw2').addClass("btn-active");
} else {
$('#shanbehw2').removeClass("btn-active");
$('#shanbehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#shanbehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f1w2').is(":checked")) {//یکشنبه
$('#yekshanbehw2').addClass("btn-active");
} else {
$('#yekshanbehw2').removeClass("btn-active");
$('#yekshanbehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#yekshanbehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f2w2').is(":checked")) {//دوشنبه
$('#doshanbehw2').addClass("btn-active");
} else {
$('#doshanbehw2').removeClass("btn-active");
$('#doshanbehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#doshanbehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f3w2').is(":checked")) {//سه شنبه
$('#seshanbehw2').addClass("btn-active");
} else {
$('#seshanbehw2').removeClass("btn-active");
$('#seshanbehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#seshanbehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f4w2').is(":checked")) {//چهارشنبه
$('#cheharshanbehw2').addClass("btn-active");
} else {
$('#cheharshanbehw2').removeClass("btn-active");
$('#cheharshanbehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#cheharshanbehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f5w2').is(":checked")) {//پنجشنبه
$('#panjshanbehw2').addClass("btn-active");
} else {
$('#panjshanbehw2').removeClass("btn-active");
$('#panjshanbehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#panjshanbehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f6w2').is(":checked")) {//جمعه
$('#jomehw2').addClass("btn-active");
} else {
$('#jomehw2').removeClass("btn-active");
$('#jomehRow3w2 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
$(this).val("");
});
$('#jomehRow3w2 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#fw3').is(":checked")) {//شنبه
$('#shanbehw3').addClass("btn-active");
} else {
$('#shanbehw3').removeClass("btn-active");
$('#shanbehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#shanbehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f1w3').is(":checked")) {//یکشنبه
$('#yekshanbehw3').addClass("btn-active");
} else {
$('#yekshanbehw3').removeClass("btn-active");
$('#yekshanbehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#yekshanbehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f2w3').is(":checked")) {//دوشنبه
$('#doshanbehw3').addClass("btn-active");
} else {
$('#doshanbehw3').removeClass("btn-active");
$('#doshanbehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#doshanbehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f3w3').is(":checked")) {//سه شنبه
$('#seshanbehw3').addClass("btn-active");
} else {
$('#seshanbehw3').removeClass("btn-active");
$('#seshanbehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#seshanbehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f4w3').is(":checked")) {//چهارشنبه
$('#cheharshanbehw3').addClass("btn-active");
} else {
$('#cheharshanbehw3').removeClass("btn-active");
$('#cheharshanbehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#cheharshanbehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f5w3').is(":checked")) {//پنجشنبه
$('#panjshanbehw3').addClass("btn-active");
} else {
$('#panjshanbehw3').removeClass("btn-active");
$('#panjshanbehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#panjshanbehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f6w3').is(":checked")) {//جمعه
$('#jomehw3').addClass("btn-active");
} else {
$('#jomehw3').removeClass("btn-active");
$('#jomehRow3w3 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
$(this).val("");
});
$('#jomehRow3w3 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#fw4').is(":checked")) {//شنبه
$('#shanbehw4').addClass("btn-active");
} else {
$('#shanbehw4').removeClass("btn-active");
$('#shanbehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#shanbehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f1w4').is(":checked")) {//یکشنبه
$('#yekshanbehw4').addClass("btn-active");
} else {
$('#yekshanbehw4').removeClass("btn-active");
$('#yekshanbehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#yekshanbehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f2w4').is(":checked")) {//دوشنبه
$('#doshanbehw4').addClass("btn-active");
} else {
$('#doshanbehw4').removeClass("btn-active");
$('#doshanbehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#doshanbehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f3w4').is(":checked")) {//سه شنبه
$('#seshanbehw4').addClass("btn-active");
} else {
$('#seshanbehw4').removeClass("btn-active");
$('#seshanbehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#seshanbehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f4w4').is(":checked")) {//چهارشنبه
$('#cheharshanbehw4').addClass("btn-active");
} else {
$('#cheharshanbehw4').removeClass("btn-active");
$('#cheharshanbehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#cheharshanbehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f5w4').is(":checked")) {//پنجشنبه
$('#panjshanbehw4').addClass("btn-active");
} else {
$('#panjshanbehw4').removeClass("btn-active");
$('#panjshanbehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
});
$('#panjshanbehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
if ($('#f6w4').is(":checked")) {//جمعه
$('#jomehw4').addClass("btn-active");
} else {
$('#jomehw4').removeClass("btn-active");
$('#jomehRow3w4 input').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
$(this).val("");
});
$('#jomehRow3w4 .rest').each(function () {
$(this).prop('selectedIndex', 0);
});
}
//disable shifte 2
function towDeactive() {
$('input.tow').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
$(this).val("");
$(this).removeProp("style");
});
}
//active shift2
function towActive() {
$('input.tow').each(function () {
$(this).removeAttr("disabled");
$(this).removeClass("input-deactive");
});
}
function oneActive() {
$('input.one').each(function () {
$(this).removeAttr("disabled");
$(this).removeClass("input-deactive");
});
}
//rest disable
function restDeactive() {
$('.restActive').each(function () {
$(this).attr("disabled", "disabled");
$(this).addClass("input-deactive");
$(this).prop('selectedIndex', 0);
});
}
//empty rest
function restReset() {
$('.restActive').each(function () {
$(this).prop('selectedIndex', 0);
});
}
//rest active
function restActive() {
$('.restActive').each(function () {
$(this).removeAttr("disabled");
$(this).removeClass("input-deactive");
});
}
</script>
<script>
$(document).ready(function() {
document.getElementById("btnPrint").onclick = function () {
printElement(document.getElementById("printThis"));
}
function printElement(elem) {
var domClone = elem.cloneNode(true);
var $printSection = document.getElementById("printSection");
if (!$printSection) {
$printSection = document.createElement("div");
$printSection.id = "printSection";
document.body.appendChild($printSection);
}
$printSection.innerHTML = "";
$printSection.appendChild(domClone);
window.print();
}
});
// window.onfocus=function(){
// $('#closingOnePrint').click();
// }
// window.onafterprint=function(){
// $('#closingOnePrint').click();
// }
</script>