feat: Implement message templates dialog with local storage support
- Added MessageTemplatesDialog component for managing message templates. - Integrated local storage to persist templates in the user's browser. - Implemented functionality to add, delete, and use templates. - Added UI components for template management including MudBlazor components. feat: Create assign tags dialog for product management - Developed AssignTagsDialog component to assign tags to products. - Integrated tag selection and display of current tags. - Implemented functionality to add and remove tags from products. feat: Implement tag management functionality - Created TagEditDialog for creating and editing tags. - Developed TagManagementPage for listing, searching, and managing tags. - Integrated CRUD operations for tags using ITagService. - Added filtering options for active/inactive tags. feat: Enhance user order management with discount and cancellation dialogs - Implemented ApplyDiscountDialog for applying discounts to orders. - Created CancelOrderDialog for canceling orders with optional refund. - Developed ChangeOrderStatusDialog for updating order delivery statuses. - Integrated gRPC services for order management operations.
This commit is contained in:
@@ -9,6 +9,30 @@
|
||||
<BackOffice.Common.BaseComponents.BasePageComponent @ref="_basePage" OnClearFilterClick="OnFilterCleared"
|
||||
OnSubmitClick="OnFilterSubmit">
|
||||
<Filters>
|
||||
<MudNumericField HideSpinButtons="true"
|
||||
T="long?"
|
||||
Clearable="true"
|
||||
Label="شناسه سفارش"
|
||||
@bind-Value="@_orderIdFilter"
|
||||
Variant="Variant.Outlined"
|
||||
Margin="Margin.Dense"/>
|
||||
|
||||
<MudNumericField HideSpinButtons="true"
|
||||
T="long?"
|
||||
Clearable="true"
|
||||
Label="شناسه کاربر"
|
||||
@bind-Value="@_userIdFilter"
|
||||
Variant="Variant.Outlined"
|
||||
Margin="Margin.Dense"/>
|
||||
|
||||
<MudNumericField HideSpinButtons="true"
|
||||
T="long?"
|
||||
Clearable="true"
|
||||
Label="شناسه تراکنش"
|
||||
@bind-Value="@_transactionIdFilter"
|
||||
Variant="Variant.Outlined"
|
||||
Margin="Margin.Dense"/>
|
||||
|
||||
<MudNumericField HideSpinButtons="true"
|
||||
T="long?"
|
||||
Clearable="true"
|
||||
@@ -56,9 +80,43 @@
|
||||
</MudSelect>
|
||||
</Filters>
|
||||
<Content>
|
||||
<MudGrid Class="mb-2">
|
||||
<MudItem xs="12" md="4">
|
||||
<MudCard>
|
||||
<MudCardContent>
|
||||
<MudText Typo="Typo.subtitle2">جمع سفارشها در بازه فعلی</MudText>
|
||||
<MudText Typo="Typo.h5">@_stats.TotalOrders.ToString("N0")</MudText>
|
||||
<MudText Typo="Typo.caption" Color="Color.Secondary">
|
||||
مجموع مبلغ: @_stats.TotalAmount.ToString("N0") ریال
|
||||
</MudText>
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
</MudItem>
|
||||
<MudItem xs="12" md="8">
|
||||
<MudCard>
|
||||
<MudCardContent>
|
||||
<MudText Typo="Typo.subtitle2" Class="mb-2">نمودار تعداد سفارشها بر اساس وضعیت ارسال</MudText>
|
||||
@if (_statusChartLabels.Length == 0)
|
||||
{
|
||||
<MudText Typo="Typo.caption" Color="Color.Secondary">
|
||||
برای این فیلتر، سفارش فعالی یافت نشد.
|
||||
</MudText>
|
||||
}
|
||||
else
|
||||
{
|
||||
<MudChart ChartType="ChartType.Bar"
|
||||
ChartSeries="@_statusChartSeries"
|
||||
XAxisLabels="@_statusChartLabels"
|
||||
Height="200px" />
|
||||
}
|
||||
</MudCardContent>
|
||||
</MudCard>
|
||||
</MudItem>
|
||||
</MudGrid>
|
||||
|
||||
<MudDataGrid T="DataModel"
|
||||
ServerData="@(new Func<GridState<DataModel>, Task<GridData<DataModel>>>(ServerReload))"
|
||||
Hover="true" @ref="_gridData" Height="72vh">
|
||||
Hover="true" @ref="_gridData" Height="60vh">
|
||||
<ColGroup>
|
||||
<col/>
|
||||
<col/>
|
||||
@@ -143,6 +201,33 @@
|
||||
Style="cursor:pointer;"/>
|
||||
</MudTooltip>
|
||||
|
||||
<MudTooltip Text="تغییر وضعیت ارسال">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.LocalShipping"
|
||||
Size="Size.Small"
|
||||
Color="Color.Primary"
|
||||
ButtonType="ButtonType.Button"
|
||||
OnClick="@(() => OpenChangeStatus(context.Item))"
|
||||
Style="cursor:pointer;"/>
|
||||
</MudTooltip>
|
||||
|
||||
<MudTooltip Text="اعمال تخفیف">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.PriceChange"
|
||||
Size="Size.Small"
|
||||
Color="Color.Secondary"
|
||||
ButtonType="ButtonType.Button"
|
||||
OnClick="@(() => OpenApplyDiscount(context.Item))"
|
||||
Style="cursor:pointer;"/>
|
||||
</MudTooltip>
|
||||
|
||||
<MudTooltip Text="لغو سفارش">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.Cancel"
|
||||
Size="Size.Small"
|
||||
Color="Color.Error"
|
||||
ButtonType="ButtonType.Button"
|
||||
OnClick="@(() => OpenCancelOrder(context.Item))"
|
||||
Style="cursor:pointer;"/>
|
||||
</MudTooltip>
|
||||
|
||||
<MudTooltip Text="آرشیو">
|
||||
<MudIconButton Icon="@Icons.Material.Filled.DeleteOutline" Size="Size.Small"
|
||||
ButtonType="ButtonType.Button" OnClick="@(() => OnDelete(context.Item))"
|
||||
|
||||
Reference in New Issue
Block a user