From 0a5065f5b3d91a6fa7f1cb8e8e3f0bd28dc9986c Mon Sep 17 00:00:00 2001 From: mmrbnjd Date: Wed, 7 Aug 2024 16:31:55 +0330 Subject: [PATCH] ... --- Back/Controllers/TaxPayerController.cs | 42 ++++++++++++------- .../Pages/UserPanel/InvoiceItem.razor | 3 +- 2 files changed, 28 insertions(+), 17 deletions(-) diff --git a/Back/Controllers/TaxPayerController.cs b/Back/Controllers/TaxPayerController.cs index 156f865..6182614 100644 --- a/Back/Controllers/TaxPayerController.cs +++ b/Back/Controllers/TaxPayerController.cs @@ -266,12 +266,18 @@ namespace Back.Controllers Sstid = bitem.sstid, //شرح کاال/خدمت Sstt = bitem.sstt, - //واحد اندازه گیری - Mu = string.IsNullOrEmpty(bitem.mu) ? null : bitem.mu, // تعداد Am = bitem.am, + //واحد اندازه گیری + Mu = string.IsNullOrEmpty(bitem.mu) ? null : bitem.mu, // مبلغ واحد Fee = bitem.fee, + //میزان ارز + Cfee = bitem.cfee, + //نوع ارز + Cut = string.IsNullOrEmpty(bitem.cut) ? null : bitem.cut, + //نرخ برابری ارز با ریال + Exr = bitem.exr, //مبلغ قبل از تخفیف Prdis = bitem.prdis, //مبلغ تخفیف @@ -282,22 +288,26 @@ namespace Back.Controllers Vra = bitem.vra, //مبلغ مالیات بر ارزش افزوده Vam = bitem.vam, + //موضوع سایر مالیات و عوارض + Odt = string.IsNullOrEmpty(bitem.odt) ? null : bitem.odt, + //نرخ سایر مالیات و عوارض + Odr = bitem.odr, + //مبلغ سایر مالیات و عوارض + Odam = bitem.odam, + //موضوع سایر وجوه قانونی + Olt = string.IsNullOrEmpty(bitem.olt) ? null : bitem.olt, + //نرخ سایر وجوه قانونی + Olr = bitem.olr, + //مبلغ سایر وجوه قانونی + Olam = bitem.olam, + //سهم نقدی از پرداخت + Cop = bitem.cop, + //سهم مالیات بر لرزش افزوده از پرداخت + Vop = bitem.vop, + //شناسه یکتای ثبت قرارداد حق العمل کاری + Bsrn = string.IsNullOrEmpty(bitem.bsrn) ? null : bitem.bsrn, // مبلغ کل کالا / خدمت Tsstam = bitem.tsstam, - Cfee = bitem.cfee, - Cut = string.IsNullOrEmpty(bitem.cut) ? null : bitem.cut, - Exr = bitem.exr, - Odt = string.IsNullOrEmpty(bitem.odt) ? null : bitem.odt, - Odr = bitem.odr, - Odam = bitem.odam, - Olt = string.IsNullOrEmpty(bitem.olt) ? null : bitem.olt, - Olr = bitem.olr, - Olam = bitem.olam, - Cop = bitem.cop, - Vop = bitem.vop, - Bsrn = string.IsNullOrEmpty(bitem.bsrn) ? null : bitem.bsrn, - - }; #endregion InvoiceBody.Add(item); diff --git a/TaxPayerFull/Pages/UserPanel/InvoiceItem.razor b/TaxPayerFull/Pages/UserPanel/InvoiceItem.razor index de0ff4b..958840a 100644 --- a/TaxPayerFull/Pages/UserPanel/InvoiceItem.razor +++ b/TaxPayerFull/Pages/UserPanel/InvoiceItem.razor @@ -569,7 +569,8 @@ if (rsp.IsSuccessStatusCode) { invoice = await rsp.Content.ReadFromJsonAsync(); - + if (!Cus.Any(w => w.ID == invoice.CustomerID)) + invoice.CustomerID = 0; } else if (rsp.StatusCode == System.Net.HttpStatusCode.BadRequest)