@amirjalili1374/ui-kit 1.5.31 → 1.5.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/ui-kit.es.js
CHANGED
|
@@ -2,7 +2,7 @@ var __defProp2 = Object.defineProperty;
|
|
|
2
2
|
var __defNormalProp2 = (obj, key2, value2) => key2 in obj ? __defProp2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2 }) : obj[key2] = value2;
|
|
3
3
|
var __publicField = (obj, key2, value2) => __defNormalProp2(obj, typeof key2 !== "symbol" ? key2 + "" : key2, value2);
|
|
4
4
|
import { warn, reactive, watchEffect, toRef, capitalize, shallowRef, Fragment, camelize, isVNode, Comment, unref, getCurrentInstance as getCurrentInstance$1, ref, computed, provide, inject, defineComponent as defineComponent$1, h, createElementVNode, normalizeStyle, normalizeClass, toValue, resolveDynamicComponent, nextTick, onScopeDispose, createVNode, mergeProps, toRefs, Text, isRef, TransitionGroup, Transition, watch, onBeforeMount, onBeforeUnmount, withDirectives, vShow, toDisplayString, effectScope, toRaw, readonly, openBlock, createBlock, withCtx, createCommentVNode, useId, onMounted, onUpdated, Teleport, createTextVNode, createElementBlock, renderSlot, onDeactivated, cloneVNode, renderList, createSlots, normalizeProps, guardReactiveProps, resolveComponent, onActivated, onBeforeUpdate, withModifiers, vModelText, withKeys, onUnmounted } from "vue";
|
|
5
|
-
import { IconHome, IconArrowBadgeLeft,
|
|
5
|
+
import { IconHome, IconArrowBadgeLeft, IconCheck, IconSquareX, IconChevronDown, IconChevronRight, IconMinus, IconPlus, IconRefresh, IconChevronLeft, IconDownload, IconPrinter, IconMaximize, IconMinimize, IconX, IconFileText, IconPencil, IconClock, IconMenu2, IconPalette } from "@tabler/icons-vue";
|
|
6
6
|
import axios from "axios";
|
|
7
7
|
import { useDebounceFn } from "@vueuse/core";
|
|
8
8
|
import { useRouter as useRouter$1 } from "vue-router";
|
|
@@ -18251,26 +18251,26 @@ const _hoisted_7$1 = {
|
|
|
18251
18251
|
key: 0,
|
|
18252
18252
|
class: "me-1"
|
|
18253
18253
|
};
|
|
18254
|
-
const _hoisted_8$1 =
|
|
18255
|
-
const _hoisted_9$1 = {
|
|
18254
|
+
const _hoisted_8$1 = { class: "d-flex align-center mb-3" };
|
|
18255
|
+
const _hoisted_9$1 = { class: "d-flex justify-end mt-3 gap-2" };
|
|
18256
|
+
const _hoisted_10$1 = ["aria-busy", "aria-live"];
|
|
18257
|
+
const _hoisted_11$1 = {
|
|
18256
18258
|
key: 0,
|
|
18257
18259
|
class: "grouped-table"
|
|
18258
18260
|
};
|
|
18259
|
-
const
|
|
18260
|
-
const
|
|
18261
|
-
const
|
|
18262
|
-
const
|
|
18263
|
-
const
|
|
18264
|
-
const
|
|
18265
|
-
const
|
|
18261
|
+
const _hoisted_12$1 = { class: "group-controls mb-3" };
|
|
18262
|
+
const _hoisted_13$1 = { class: "groups-container" };
|
|
18263
|
+
const _hoisted_14$1 = ["onClick", "onKeydown", "aria-expanded", "aria-controls", "id"];
|
|
18264
|
+
const _hoisted_15$1 = { class: "group-label" };
|
|
18265
|
+
const _hoisted_16$1 = ["id", "aria-labelledby"];
|
|
18266
|
+
const _hoisted_17 = ["tabindex", "onKeydown", "onClick"];
|
|
18267
|
+
const _hoisted_18 = {
|
|
18266
18268
|
key: 2,
|
|
18267
18269
|
class: "d-flex align-center",
|
|
18268
18270
|
style: { "gap": "4px" }
|
|
18269
18271
|
};
|
|
18270
|
-
const
|
|
18271
|
-
const
|
|
18272
|
-
const _hoisted_19 = { class: "d-flex align-center mb-3" };
|
|
18273
|
-
const _hoisted_20 = { class: "d-flex justify-end mt-3 gap-2" };
|
|
18272
|
+
const _hoisted_19 = ["onClick"];
|
|
18273
|
+
const _hoisted_20 = ["onClick"];
|
|
18274
18274
|
const _hoisted_21 = ["tabindex", "onKeydown", "onClick"];
|
|
18275
18275
|
const _hoisted_22 = {
|
|
18276
18276
|
key: 2,
|
|
@@ -18280,7 +18280,7 @@ const _hoisted_22 = {
|
|
|
18280
18280
|
const _hoisted_23 = ["onClick"];
|
|
18281
18281
|
const _hoisted_24 = ["onClick"];
|
|
18282
18282
|
const _hoisted_25 = {
|
|
18283
|
-
key:
|
|
18283
|
+
key: 2,
|
|
18284
18284
|
class: "d-flex justify-center align-center pa-4"
|
|
18285
18285
|
};
|
|
18286
18286
|
const _hoisted_26 = {
|
|
@@ -19628,6 +19628,151 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19628
19628
|
_: 1
|
|
19629
19629
|
})
|
|
19630
19630
|
]),
|
|
19631
|
+
props.inlineFilter && formHeaders.value.length > 0 ? (openBlock(), createBlock(VCard, {
|
|
19632
|
+
key: 1,
|
|
19633
|
+
class: "mb-4 pa-4",
|
|
19634
|
+
elevation: "1"
|
|
19635
|
+
}, {
|
|
19636
|
+
default: withCtx(() => [
|
|
19637
|
+
createElementVNode("div", _hoisted_8$1, [
|
|
19638
|
+
_cache[36] || (_cache[36] = createElementVNode("span", { class: "text-subtitle-2 font-weight-medium" }, "فیلترها", -1)),
|
|
19639
|
+
createVNode(VSpacer),
|
|
19640
|
+
hasActiveInlineFilters.value ? (openBlock(), createBlock(VBtn, {
|
|
19641
|
+
key: 0,
|
|
19642
|
+
variant: "text",
|
|
19643
|
+
size: "small",
|
|
19644
|
+
color: "error",
|
|
19645
|
+
onClick: resetFilter
|
|
19646
|
+
}, {
|
|
19647
|
+
default: withCtx(() => [..._cache[35] || (_cache[35] = [
|
|
19648
|
+
createTextVNode(" حذف فیلترها ", -1)
|
|
19649
|
+
])]),
|
|
19650
|
+
_: 1
|
|
19651
|
+
})) : createCommentVNode("", true)
|
|
19652
|
+
]),
|
|
19653
|
+
createVNode(VContainer, null, {
|
|
19654
|
+
default: withCtx(() => [
|
|
19655
|
+
createVNode(VRow, null, {
|
|
19656
|
+
default: withCtx(() => [
|
|
19657
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(formHeaders.value, (header) => {
|
|
19658
|
+
return openBlock(), createBlock(VCol, {
|
|
19659
|
+
key: resolveHeaderKey(header),
|
|
19660
|
+
cols: header.cols ? typeof header.cols === "number" ? header.cols : Number(header.cols) : 4,
|
|
19661
|
+
md: header.cols ? typeof header.cols === "number" ? header.cols : Number(header.cols) : 4
|
|
19662
|
+
}, {
|
|
19663
|
+
default: withCtx(() => [
|
|
19664
|
+
!header.hidden ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
19665
|
+
hasFilterOperators(header) ? (openBlock(), createBlock(VSelect, {
|
|
19666
|
+
key: 0,
|
|
19667
|
+
modelValue: filterOperatorModel.value[resolveHeaderKey(header)],
|
|
19668
|
+
"onUpdate:modelValue": ($event) => filterOperatorModel.value[resolveHeaderKey(header)] = $event,
|
|
19669
|
+
items: getHeaderFilterOperators(header),
|
|
19670
|
+
"item-title": "label",
|
|
19671
|
+
"item-value": "value",
|
|
19672
|
+
density: "compact",
|
|
19673
|
+
variant: "underlined",
|
|
19674
|
+
"hide-details": "",
|
|
19675
|
+
class: "mb-1",
|
|
19676
|
+
attach: "",
|
|
19677
|
+
"menu-props": { zIndex: 2e4 }
|
|
19678
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "items"])) : createCommentVNode("", true),
|
|
19679
|
+
isDateHeader(header) ? (openBlock(), createBlock(ShamsiDatePicker, {
|
|
19680
|
+
key: 1,
|
|
19681
|
+
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
19682
|
+
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
19683
|
+
label: resolveHeaderTitle(header),
|
|
19684
|
+
disabled: isHeaderDisabled(header),
|
|
19685
|
+
mode: header.dateMode || "single"
|
|
19686
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled", "mode"])) : hasAutocomplete(header) ? (openBlock(), createBlock(VAutocomplete, {
|
|
19687
|
+
key: 2,
|
|
19688
|
+
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
19689
|
+
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
19690
|
+
label: resolveHeaderTitle(header),
|
|
19691
|
+
items: resolveAutocompleteItems(header, filterModel.value.value),
|
|
19692
|
+
"item-title": resolveAutocompleteItemTitle(header),
|
|
19693
|
+
"item-value": resolveAutocompleteItemValue(header),
|
|
19694
|
+
"return-object": resolveAutocompleteReturnObject(header),
|
|
19695
|
+
multiple: resolveAutocompleteMultiple(header),
|
|
19696
|
+
chips: resolveAutocompleteMultiple(header),
|
|
19697
|
+
"closable-chips": resolveAutocompleteMultiple(header),
|
|
19698
|
+
disabled: isHeaderDisabled(header),
|
|
19699
|
+
clearable: "",
|
|
19700
|
+
variant: "outlined",
|
|
19701
|
+
attach: "",
|
|
19702
|
+
"menu-props": { zIndex: 2e4 }
|
|
19703
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "items", "item-title", "item-value", "return-object", "multiple", "chips", "closable-chips", "disabled"])) : isMoneyHeader(header) ? (openBlock(), createBlock(_sfc_main$i, {
|
|
19704
|
+
key: 3,
|
|
19705
|
+
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
19706
|
+
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
19707
|
+
label: resolveHeaderTitle(header),
|
|
19708
|
+
disabled: isHeaderDisabled(header)
|
|
19709
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled"])) : isTextareaHeader(header) ? (openBlock(), createBlock(VTextarea, {
|
|
19710
|
+
key: 4,
|
|
19711
|
+
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
19712
|
+
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
19713
|
+
label: resolveHeaderTitle(header),
|
|
19714
|
+
variant: "outlined",
|
|
19715
|
+
disabled: isHeaderDisabled(header),
|
|
19716
|
+
dir: header.dir,
|
|
19717
|
+
"auto-grow": "",
|
|
19718
|
+
rows: "3"
|
|
19719
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled", "dir"])) : isToggleHeader(header) ? (openBlock(), createBlock(ToggleSwitch, {
|
|
19720
|
+
key: 5,
|
|
19721
|
+
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
19722
|
+
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
19723
|
+
label: resolveHeaderTitle(header),
|
|
19724
|
+
type: "boolean",
|
|
19725
|
+
activeColor: "#3bd32a",
|
|
19726
|
+
inactiveColor: "#d32a2a",
|
|
19727
|
+
options: [
|
|
19728
|
+
{ value: "true", label: "فعال", icon: unref(IconCheck) },
|
|
19729
|
+
{ value: "false", label: "غیر فعال", icon: unref(IconSquareX) }
|
|
19730
|
+
]
|
|
19731
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "options"])) : (openBlock(), createBlock(VTextField, {
|
|
19732
|
+
key: 6,
|
|
19733
|
+
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
19734
|
+
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
19735
|
+
label: resolveHeaderTitle(header),
|
|
19736
|
+
variant: "outlined",
|
|
19737
|
+
disabled: isHeaderDisabled(header),
|
|
19738
|
+
type: getFieldInputType(header),
|
|
19739
|
+
dir: header.dir
|
|
19740
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled", "type", "dir"]))
|
|
19741
|
+
], 64)) : createCommentVNode("", true)
|
|
19742
|
+
]),
|
|
19743
|
+
_: 2
|
|
19744
|
+
}, 1032, ["cols", "md"]);
|
|
19745
|
+
}), 128))
|
|
19746
|
+
]),
|
|
19747
|
+
_: 1
|
|
19748
|
+
})
|
|
19749
|
+
]),
|
|
19750
|
+
_: 1
|
|
19751
|
+
}),
|
|
19752
|
+
createElementVNode("div", _hoisted_9$1, [
|
|
19753
|
+
createVNode(VBtn, {
|
|
19754
|
+
color: "grey",
|
|
19755
|
+
variant: "tonal",
|
|
19756
|
+
onClick: resetFilter
|
|
19757
|
+
}, {
|
|
19758
|
+
default: withCtx(() => [..._cache[37] || (_cache[37] = [
|
|
19759
|
+
createTextVNode(" حذف فیلترها ", -1)
|
|
19760
|
+
])]),
|
|
19761
|
+
_: 1
|
|
19762
|
+
}),
|
|
19763
|
+
createVNode(VBtn, {
|
|
19764
|
+
color: "primary",
|
|
19765
|
+
onClick: applyFilter
|
|
19766
|
+
}, {
|
|
19767
|
+
default: withCtx(() => [..._cache[38] || (_cache[38] = [
|
|
19768
|
+
createTextVNode(" اعمال فیلتر ", -1)
|
|
19769
|
+
])]),
|
|
19770
|
+
_: 1
|
|
19771
|
+
})
|
|
19772
|
+
])
|
|
19773
|
+
]),
|
|
19774
|
+
_: 1
|
|
19775
|
+
})) : createCommentVNode("", true),
|
|
19631
19776
|
createElementVNode("div", mergeProps({ class: "data-table-container" }, _ctx.$attrs, {
|
|
19632
19777
|
role: "region",
|
|
19633
19778
|
"aria-busy": loading.value || isLoadingMore.value,
|
|
@@ -19646,15 +19791,15 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19646
19791
|
boilerplate: false
|
|
19647
19792
|
}, null, 8, ["loading"])
|
|
19648
19793
|
], 4)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
19649
|
-
props.groupBy && unref(groupedItems).length > 0 ? (openBlock(), createElementBlock("div",
|
|
19650
|
-
createElementVNode("div",
|
|
19794
|
+
props.groupBy && unref(groupedItems).length > 0 ? (openBlock(), createElementBlock("div", _hoisted_11$1, [
|
|
19795
|
+
createElementVNode("div", _hoisted_12$1, [
|
|
19651
19796
|
createVNode(VBtn, {
|
|
19652
19797
|
size: "small",
|
|
19653
19798
|
color: "primary",
|
|
19654
19799
|
onClick: expandAllGroups,
|
|
19655
19800
|
class: "me-2"
|
|
19656
19801
|
}, {
|
|
19657
|
-
default: withCtx(() => [..._cache[
|
|
19802
|
+
default: withCtx(() => [..._cache[39] || (_cache[39] = [
|
|
19658
19803
|
createTextVNode(" گسترش همه ", -1)
|
|
19659
19804
|
])]),
|
|
19660
19805
|
_: 1
|
|
@@ -19665,7 +19810,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19665
19810
|
onClick: collapseAllGroups,
|
|
19666
19811
|
class: "me-2"
|
|
19667
19812
|
}, {
|
|
19668
|
-
default: withCtx(() => [..._cache[
|
|
19813
|
+
default: withCtx(() => [..._cache[40] || (_cache[40] = [
|
|
19669
19814
|
createTextVNode(" جمع کردن همه ", -1)
|
|
19670
19815
|
])]),
|
|
19671
19816
|
_: 1
|
|
@@ -19675,7 +19820,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19675
19820
|
class: "groups-scroll-container",
|
|
19676
19821
|
style: normalizeStyle({ height: `${props.height - 120}px` })
|
|
19677
19822
|
}, [
|
|
19678
|
-
createElementVNode("div",
|
|
19823
|
+
createElementVNode("div", _hoisted_13$1, [
|
|
19679
19824
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(groupedItems), (group) => {
|
|
19680
19825
|
return openBlock(), createElementBlock("div", {
|
|
19681
19826
|
key: group.groupKey,
|
|
@@ -19703,7 +19848,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19703
19848
|
key: 1,
|
|
19704
19849
|
class: "me-2 chevron-icon"
|
|
19705
19850
|
})),
|
|
19706
|
-
createElementVNode("span",
|
|
19851
|
+
createElementVNode("span", _hoisted_15$1, toDisplayString(group.groupLabel), 1),
|
|
19707
19852
|
createVNode(VChip, {
|
|
19708
19853
|
size: "small",
|
|
19709
19854
|
color: "darkprimary",
|
|
@@ -19714,7 +19859,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19714
19859
|
]),
|
|
19715
19860
|
_: 2
|
|
19716
19861
|
}, 1024)
|
|
19717
|
-
], 42,
|
|
19862
|
+
], 42, _hoisted_14$1),
|
|
19718
19863
|
createVNode(Transition, {
|
|
19719
19864
|
name: "group-expand",
|
|
19720
19865
|
appear: ""
|
|
@@ -19793,7 +19938,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19793
19938
|
class: "mr-2",
|
|
19794
19939
|
onClick: ($event) => openDialog(item)
|
|
19795
19940
|
}, {
|
|
19796
|
-
default: withCtx(() => [..._cache[
|
|
19941
|
+
default: withCtx(() => [..._cache[41] || (_cache[41] = [
|
|
19797
19942
|
createTextVNode(" ویرایش ✏️ ", -1)
|
|
19798
19943
|
])]),
|
|
19799
19944
|
_: 1
|
|
@@ -19805,7 +19950,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19805
19950
|
class: "mr-2",
|
|
19806
19951
|
onClick: ($event) => openDeleteDialog(item)
|
|
19807
19952
|
}, {
|
|
19808
|
-
default: withCtx(() => [..._cache[
|
|
19953
|
+
default: withCtx(() => [..._cache[42] || (_cache[42] = [
|
|
19809
19954
|
createTextVNode("حذف ❌ ", -1)
|
|
19810
19955
|
])]),
|
|
19811
19956
|
_: 1
|
|
@@ -19817,7 +19962,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19817
19962
|
class: "mr-2",
|
|
19818
19963
|
onClick: ($event) => goToRoute("view", item)
|
|
19819
19964
|
}, {
|
|
19820
|
-
default: withCtx(() => [..._cache[
|
|
19965
|
+
default: withCtx(() => [..._cache[43] || (_cache[43] = [
|
|
19821
19966
|
createTextVNode("🔍 نمایش ", -1)
|
|
19822
19967
|
])]),
|
|
19823
19968
|
_: 1
|
|
@@ -19895,7 +20040,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19895
20040
|
_: 2
|
|
19896
20041
|
}, 1032, ["color", "onClick"]);
|
|
19897
20042
|
}), 128))
|
|
19898
|
-
], 64)) : (openBlock(), createElementBlock("div",
|
|
20043
|
+
], 64)) : (openBlock(), createElementBlock("div", _hoisted_18, [
|
|
19899
20044
|
shouldTruncate(
|
|
19900
20045
|
getTranslatedValue(getNestedValue2(item, column.key || ""), column, item),
|
|
19901
20046
|
getHeaderForColumn(column.key || "")
|
|
@@ -19908,7 +20053,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19908
20053
|
column.title || column.key || "",
|
|
19909
20054
|
item
|
|
19910
20055
|
), ["stop"])
|
|
19911
|
-
}, toDisplayString(truncateText(getTranslatedValue(getNestedValue2(item, column.key || ""), column, item))), 9,
|
|
20056
|
+
}, toDisplayString(truncateText(getTranslatedValue(getNestedValue2(item, column.key || ""), column, item))), 9, _hoisted_19)) : (openBlock(), createElementBlock("span", {
|
|
19912
20057
|
key: 1,
|
|
19913
20058
|
onClick: withModifiers(($event) => shouldShowCopyButton(getHeaderForColumn(column.key || "")) && openTextPreview(
|
|
19914
20059
|
getTranslatedValue(getNestedValue2(item, column.key || ""), column, item),
|
|
@@ -19916,7 +20061,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19916
20061
|
item
|
|
19917
20062
|
), ["stop"]),
|
|
19918
20063
|
style: normalizeStyle({ cursor: shouldShowCopyButton(getHeaderForColumn(column.key || "")) ? "pointer" : "default" })
|
|
19919
|
-
}, toDisplayString(getTranslatedValue(getNestedValue2(item, column.key || ""), column, item)), 13,
|
|
20064
|
+
}, toDisplayString(getTranslatedValue(getNestedValue2(item, column.key || ""), column, item)), 13, _hoisted_20)),
|
|
19920
20065
|
shouldShowCopyButton(getHeaderForColumn(column.key || "")) ? (openBlock(), createBlock(VBtn, {
|
|
19921
20066
|
key: 2,
|
|
19922
20067
|
icon: "",
|
|
@@ -19932,7 +20077,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19932
20077
|
}, {
|
|
19933
20078
|
default: withCtx(() => [
|
|
19934
20079
|
createVNode(VIcon, { size: "16" }, {
|
|
19935
|
-
default: withCtx(() => [..._cache[
|
|
20080
|
+
default: withCtx(() => [..._cache[44] || (_cache[44] = [
|
|
19936
20081
|
createTextVNode("mdi-content-copy", -1)
|
|
19937
20082
|
])]),
|
|
19938
20083
|
_: 1
|
|
@@ -19943,11 +20088,11 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19943
20088
|
]))
|
|
19944
20089
|
], 4);
|
|
19945
20090
|
}), 128))
|
|
19946
|
-
], 44,
|
|
20091
|
+
], 44, _hoisted_17)
|
|
19947
20092
|
]),
|
|
19948
20093
|
_: 1
|
|
19949
20094
|
}, 8, ["headers", "items", "items-per-page"])
|
|
19950
|
-
], 8,
|
|
20095
|
+
], 8, _hoisted_16$1)) : createCommentVNode("", true)
|
|
19951
20096
|
]),
|
|
19952
20097
|
_: 2
|
|
19953
20098
|
}, 1024)
|
|
@@ -19955,153 +20100,8 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
19955
20100
|
}), 128))
|
|
19956
20101
|
])
|
|
19957
20102
|
], 4)
|
|
19958
|
-
])) :
|
|
19959
|
-
props.inlineFilter && formHeaders.value.length > 0 ? (openBlock(), createBlock(VCard, {
|
|
20103
|
+
])) : (openBlock(), createBlock(VDataTable, {
|
|
19960
20104
|
key: 1,
|
|
19961
|
-
class: "mb-4 pa-4",
|
|
19962
|
-
elevation: "1"
|
|
19963
|
-
}, {
|
|
19964
|
-
default: withCtx(() => [
|
|
19965
|
-
createElementVNode("div", _hoisted_19, [
|
|
19966
|
-
_cache[42] || (_cache[42] = createElementVNode("span", { class: "text-subtitle-2 font-weight-medium" }, "فیلترها", -1)),
|
|
19967
|
-
createVNode(VSpacer),
|
|
19968
|
-
hasActiveInlineFilters.value ? (openBlock(), createBlock(VBtn, {
|
|
19969
|
-
key: 0,
|
|
19970
|
-
variant: "text",
|
|
19971
|
-
size: "small",
|
|
19972
|
-
color: "error",
|
|
19973
|
-
onClick: resetFilter
|
|
19974
|
-
}, {
|
|
19975
|
-
default: withCtx(() => [..._cache[41] || (_cache[41] = [
|
|
19976
|
-
createTextVNode(" حذف فیلترها ", -1)
|
|
19977
|
-
])]),
|
|
19978
|
-
_: 1
|
|
19979
|
-
})) : createCommentVNode("", true)
|
|
19980
|
-
]),
|
|
19981
|
-
createVNode(VContainer, null, {
|
|
19982
|
-
default: withCtx(() => [
|
|
19983
|
-
createVNode(VRow, null, {
|
|
19984
|
-
default: withCtx(() => [
|
|
19985
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(formHeaders.value, (header) => {
|
|
19986
|
-
return openBlock(), createBlock(VCol, {
|
|
19987
|
-
key: resolveHeaderKey(header),
|
|
19988
|
-
cols: header.cols ? typeof header.cols === "number" ? header.cols : Number(header.cols) : 4,
|
|
19989
|
-
md: header.cols ? typeof header.cols === "number" ? header.cols : Number(header.cols) : 4
|
|
19990
|
-
}, {
|
|
19991
|
-
default: withCtx(() => [
|
|
19992
|
-
!header.hidden ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
19993
|
-
hasFilterOperators(header) ? (openBlock(), createBlock(VSelect, {
|
|
19994
|
-
key: 0,
|
|
19995
|
-
modelValue: filterOperatorModel.value[resolveHeaderKey(header)],
|
|
19996
|
-
"onUpdate:modelValue": ($event) => filterOperatorModel.value[resolveHeaderKey(header)] = $event,
|
|
19997
|
-
items: getHeaderFilterOperators(header),
|
|
19998
|
-
"item-title": "label",
|
|
19999
|
-
"item-value": "value",
|
|
20000
|
-
density: "compact",
|
|
20001
|
-
variant: "underlined",
|
|
20002
|
-
"hide-details": "",
|
|
20003
|
-
class: "mb-1",
|
|
20004
|
-
attach: "",
|
|
20005
|
-
"menu-props": { zIndex: 2e4 }
|
|
20006
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "items"])) : createCommentVNode("", true),
|
|
20007
|
-
isDateHeader(header) ? (openBlock(), createBlock(ShamsiDatePicker, {
|
|
20008
|
-
key: 1,
|
|
20009
|
-
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
20010
|
-
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
20011
|
-
label: resolveHeaderTitle(header),
|
|
20012
|
-
disabled: isHeaderDisabled(header),
|
|
20013
|
-
mode: header.dateMode || "single"
|
|
20014
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled", "mode"])) : hasAutocomplete(header) ? (openBlock(), createBlock(VAutocomplete, {
|
|
20015
|
-
key: 2,
|
|
20016
|
-
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
20017
|
-
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
20018
|
-
label: resolveHeaderTitle(header),
|
|
20019
|
-
items: resolveAutocompleteItems(header, filterModel.value.value),
|
|
20020
|
-
"item-title": resolveAutocompleteItemTitle(header),
|
|
20021
|
-
"item-value": resolveAutocompleteItemValue(header),
|
|
20022
|
-
"return-object": resolveAutocompleteReturnObject(header),
|
|
20023
|
-
multiple: resolveAutocompleteMultiple(header),
|
|
20024
|
-
chips: resolveAutocompleteMultiple(header),
|
|
20025
|
-
"closable-chips": resolveAutocompleteMultiple(header),
|
|
20026
|
-
disabled: isHeaderDisabled(header),
|
|
20027
|
-
clearable: "",
|
|
20028
|
-
variant: "outlined",
|
|
20029
|
-
attach: "",
|
|
20030
|
-
"menu-props": { zIndex: 2e4 }
|
|
20031
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "items", "item-title", "item-value", "return-object", "multiple", "chips", "closable-chips", "disabled"])) : isMoneyHeader(header) ? (openBlock(), createBlock(_sfc_main$i, {
|
|
20032
|
-
key: 3,
|
|
20033
|
-
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
20034
|
-
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
20035
|
-
label: resolveHeaderTitle(header),
|
|
20036
|
-
disabled: isHeaderDisabled(header)
|
|
20037
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled"])) : isTextareaHeader(header) ? (openBlock(), createBlock(VTextarea, {
|
|
20038
|
-
key: 4,
|
|
20039
|
-
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
20040
|
-
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
20041
|
-
label: resolveHeaderTitle(header),
|
|
20042
|
-
variant: "outlined",
|
|
20043
|
-
disabled: isHeaderDisabled(header),
|
|
20044
|
-
dir: header.dir,
|
|
20045
|
-
"auto-grow": "",
|
|
20046
|
-
rows: "3"
|
|
20047
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled", "dir"])) : isToggleHeader(header) ? (openBlock(), createBlock(ToggleSwitch, {
|
|
20048
|
-
key: 5,
|
|
20049
|
-
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
20050
|
-
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
20051
|
-
label: resolveHeaderTitle(header),
|
|
20052
|
-
type: "boolean",
|
|
20053
|
-
activeColor: "#3bd32a",
|
|
20054
|
-
inactiveColor: "#d32a2a",
|
|
20055
|
-
options: [
|
|
20056
|
-
{ value: "true", label: "فعال", icon: unref(IconCheck) },
|
|
20057
|
-
{ value: "false", label: "غیر فعال", icon: unref(IconSquareX) }
|
|
20058
|
-
]
|
|
20059
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "options"])) : (openBlock(), createBlock(VTextField, {
|
|
20060
|
-
key: 6,
|
|
20061
|
-
modelValue: filterModel.value[resolveHeaderKey(header)],
|
|
20062
|
-
"onUpdate:modelValue": ($event) => filterModel.value[resolveHeaderKey(header)] = $event,
|
|
20063
|
-
label: resolveHeaderTitle(header),
|
|
20064
|
-
variant: "outlined",
|
|
20065
|
-
disabled: isHeaderDisabled(header),
|
|
20066
|
-
type: getFieldInputType(header),
|
|
20067
|
-
dir: header.dir
|
|
20068
|
-
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "disabled", "type", "dir"]))
|
|
20069
|
-
], 64)) : createCommentVNode("", true)
|
|
20070
|
-
]),
|
|
20071
|
-
_: 2
|
|
20072
|
-
}, 1032, ["cols", "md"]);
|
|
20073
|
-
}), 128))
|
|
20074
|
-
]),
|
|
20075
|
-
_: 1
|
|
20076
|
-
})
|
|
20077
|
-
]),
|
|
20078
|
-
_: 1
|
|
20079
|
-
}),
|
|
20080
|
-
createElementVNode("div", _hoisted_20, [
|
|
20081
|
-
createVNode(VBtn, {
|
|
20082
|
-
color: "grey",
|
|
20083
|
-
variant: "tonal",
|
|
20084
|
-
onClick: resetFilter
|
|
20085
|
-
}, {
|
|
20086
|
-
default: withCtx(() => [..._cache[43] || (_cache[43] = [
|
|
20087
|
-
createTextVNode(" حذف فیلترها ", -1)
|
|
20088
|
-
])]),
|
|
20089
|
-
_: 1
|
|
20090
|
-
}),
|
|
20091
|
-
createVNode(VBtn, {
|
|
20092
|
-
color: "primary",
|
|
20093
|
-
onClick: applyFilter
|
|
20094
|
-
}, {
|
|
20095
|
-
default: withCtx(() => [..._cache[44] || (_cache[44] = [
|
|
20096
|
-
createTextVNode(" اعمال فیلتر ", -1)
|
|
20097
|
-
])]),
|
|
20098
|
-
_: 1
|
|
20099
|
-
})
|
|
20100
|
-
])
|
|
20101
|
-
]),
|
|
20102
|
-
_: 1
|
|
20103
|
-
})) : (openBlock(), createBlock(VDataTable, {
|
|
20104
|
-
key: 2,
|
|
20105
20105
|
headers: normalHeaders.value,
|
|
20106
20106
|
items: items.value,
|
|
20107
20107
|
"items-per-page": itemsPerPage.value,
|
|
@@ -20344,7 +20344,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
20344
20344
|
}, null, 8, ["modelValue", "length"])
|
|
20345
20345
|
])
|
|
20346
20346
|
])) : createCommentVNode("", true)
|
|
20347
|
-
], 16,
|
|
20347
|
+
], 16, _hoisted_10$1),
|
|
20348
20348
|
createVNode(VDialog, {
|
|
20349
20349
|
modelValue: dialog.value,
|
|
20350
20350
|
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => dialog.value = $event),
|
|
@@ -20891,7 +20891,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent$1({
|
|
|
20891
20891
|
_: 1
|
|
20892
20892
|
}, 8, ["modelValue"]),
|
|
20893
20893
|
snackbar.value ? (openBlock(), createBlock(VSnackbar, {
|
|
20894
|
-
key:
|
|
20894
|
+
key: 2,
|
|
20895
20895
|
modelValue: snackbar.value,
|
|
20896
20896
|
"onUpdate:modelValue": _cache[23] || (_cache[23] = ($event) => snackbar.value = $event),
|
|
20897
20897
|
timeout: 3e3,
|