Editing of the project's Kariz page

This commit is contained in:
2026-09-15 19:13:30 +03:30
parent 44f9849d0e
commit e61fad95c6
25 changed files with 1751 additions and 567 deletions
@@ -11,8 +11,16 @@ withDefaults(
pipelineName: string;
pipelineOptions: Array<{ id: string; name: string }>;
canCreate?: boolean;
icon?: 'briefcase' | 'grid';
createOptionLabel?: string;
showAmountFilters?: boolean;
}>(),
{ canCreate: false },
{
canCreate: false,
icon: 'briefcase',
createOptionLabel: 'کاریز جدید…',
showAmountFilters: true,
},
);
const emit = defineEmits<{
@@ -43,7 +51,7 @@ function onPick(value: string) {
<header class="toolbar" dir="rtl">
<div class="title-block">
<span class="brand-ico" aria-hidden="true">
<UiIcon name="briefcase" :size="18" />
<UiIcon :name="icon" :size="18" />
</span>
<h1>{{ pipelineName }}</h1>
</div>
@@ -54,7 +62,7 @@ function onPick(value: string) {
</template>
</UiSegmented>
<UiSelect
<UiSelect
class="pipeline-pick"
:model-value="selectedPipelineId"
@update:model-value="onPick"
@@ -66,18 +74,28 @@ function onPick(value: string) {
>
{{ opt.name }}
</option>
<option v-if="canCreate" value="__create__">کاریز جدید…</option>
<option v-if="canCreate" value="__create__">{{ createOptionLabel }}</option>
</UiSelect>
<UiFilterBar v-model:search="search" class="filters">
<label class="field">
<span>حداقل مبلغ</span>
<input v-model="amountMin" type="number" min="0" placeholder="۰" />
</label>
<label class="field">
<span>حداکثر مبلغ</span>
<input v-model="amountMax" type="number" min="0" placeholder="—" />
</label>
<div class="excel-actions">
<slot name="excel" />
</div>
<UiFilterBar
v-model:search="search"
class="filters"
:show-filters="showAmountFilters"
>
<template v-if="showAmountFilters">
<label class="field">
<span>حداقل مبلغ</span>
<input v-model="amountMin" type="number" min="0" placeholder="۰" />
</label>
<label class="field">
<span>حداکثر مبلغ</span>
<input v-model="amountMax" type="number" min="0" placeholder="—" />
</label>
</template>
</UiFilterBar>
</header>
</template>
@@ -127,6 +145,25 @@ h1 {
min-width: 8.5rem;
}
.excel-actions {
display: flex;
flex-wrap: wrap;
gap: 0.4rem;
flex: 0 0 auto;
}
.excel-actions :deep(.btn-ghost-sm) {
border: 1px solid #e2e8f0;
background: #fff;
color: #0f766e;
border-radius: 10px;
padding: 0.45rem 0.75rem;
font-weight: 700;
font-size: 0.85rem;
cursor: pointer;
font: inherit;
}
.filters {
flex: 1 1 12rem;
min-width: 0;
@@ -153,6 +190,7 @@ h1 {
}
.pipeline-pick,
.excel-actions,
.filters {
flex: 1 1 100%;
}