...
This commit is contained in:
@@ -18,7 +18,7 @@
|
||||
<input style="text-align: center;" value="@order.StatusTitle" type="text" class="form-control" id="StatusTitle" placeholder="وضغیت" readonly />
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label class="col-sm-5 col-form-label">تاریخ ایحاد</label>
|
||||
<label class="col-sm-5 col-form-label">تاریخ ایجاد</label>
|
||||
<InputText style="text-align: center;" @bind-Value="order.DateCreate" type="text" class="form-control" id="DateCreate" placeholder="تاریخ ایجاد" readonly />
|
||||
</div>
|
||||
@if (order.Status != StatusOrder.Create)
|
||||
@@ -45,9 +45,6 @@
|
||||
<GridColumn TItem="OrderItemDto" HeaderText="عنوان">
|
||||
@context.Title
|
||||
</GridColumn>
|
||||
<GridColumn TItem="OrderItemDto" HeaderText="نوع">
|
||||
@context.Type
|
||||
</GridColumn>
|
||||
<GridColumn TItem="OrderItemDto" HeaderText="تعداد">
|
||||
@context.CreditAmount
|
||||
</GridColumn>
|
||||
@@ -91,7 +88,7 @@
|
||||
</div> *@
|
||||
<div class="col-md-3">
|
||||
<label class="col-sm-5 col-form-label">مبلغ نهایی</label>
|
||||
<CurrencyInput style="text-align: center;" TValue="decimal" @bind-Value="order.TTax" Locale="fa-Ir" Placeholder="مبلغ نهایی" readonly />
|
||||
<CurrencyInput style="text-align: center;" TValue="decimal" @bind-Value="order.TPrice" Locale="fa-Ir" Placeholder="مبلغ نهایی" readonly />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -100,7 +97,7 @@
|
||||
@if (order.Status == StatusOrder.Create)
|
||||
{
|
||||
<Button class="mt-3" Color="ButtonColor.Success" @onclick="OnClickPay" Type="ButtonType.Button">
|
||||
پرداخت
|
||||
پرداخت با کیف پول
|
||||
</Button>
|
||||
<Button class="mt-3" Color="ButtonColor.Danger" @onclick="OnClickCancel" Type="ButtonType.Button">
|
||||
ابطال
|
||||
@@ -195,13 +192,14 @@
|
||||
{
|
||||
|
||||
PreloadService.Show(SpinnerColor.Dark);
|
||||
var rsp = await hc.Get($"Orders/CancelOrder/{order.ID}");
|
||||
var rsp = await hc.Delete($"Orders/CancelOrder/{order.ID}");
|
||||
PreloadService.Hide();
|
||||
if (rsp.IsSuccessStatusCode)
|
||||
{
|
||||
if(await rsp.Content.ReadFromJsonAsync<bool>())
|
||||
{
|
||||
order.Status = StatusOrder.Cancel;
|
||||
result = new ActionInResultComponent();
|
||||
result.Status = ComponentStatus.success;
|
||||
result.Action = ComponentAction.delete;
|
||||
await OnMultipleOfThree.InvokeAsync(result);
|
||||
|
Reference in New Issue
Block a user