@iankibetsh/shframework 5.7.8 → 5.8.0
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/README.md +130 -5
- package/dist/dist/library.mjs.css +57 -48
- package/dist/library.js +349 -174
- package/dist/library.mjs +350 -175
- package/package.json +1 -1
package/dist/library.js
CHANGED
|
@@ -4820,6 +4820,9 @@ const props = __props;
|
|
|
4820
4820
|
|
|
4821
4821
|
const url = vue.ref(props.action.path || props.action.url || props.action.link);
|
|
4822
4822
|
|
|
4823
|
+
const hasAction = vue.computed(() => !!(props.action.callback || props.action.callBack || props.action.emits));
|
|
4824
|
+
const actionValue = vue.computed(() => props.action.callback || props.action.callBack || props.action.emits);
|
|
4825
|
+
|
|
4823
4826
|
vue.onMounted(()=>{
|
|
4824
4827
|
if(!url.value) {
|
|
4825
4828
|
url.value = '';
|
|
@@ -4922,7 +4925,7 @@ return (_ctx, _cache) => {
|
|
|
4922
4925
|
: vue.createCommentVNode("v-if", true),
|
|
4923
4926
|
vue.createTextVNode(" " + vue.toDisplayString(__props.action.label), 1 /* TEXT */)
|
|
4924
4927
|
], 10 /* CLASS, PROPS */, _hoisted_1$f))
|
|
4925
|
-
: (
|
|
4928
|
+
: (hasAction.value)
|
|
4926
4929
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
4927
4930
|
key: 3,
|
|
4928
4931
|
title: __props.action.title,
|
|
@@ -4933,7 +4936,7 @@ return (_ctx, _cache) => {
|
|
|
4933
4936
|
},
|
|
4934
4937
|
__props.actionClass
|
|
4935
4938
|
]),
|
|
4936
|
-
onClick: _cache[2] || (_cache[2] = $event => (doEmitAction(
|
|
4939
|
+
onClick: _cache[2] || (_cache[2] = $event => (doEmitAction(actionValue.value, __props.record)))
|
|
4937
4940
|
}, [
|
|
4938
4941
|
(__props.action.icon)
|
|
4939
4942
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
@@ -4943,7 +4946,7 @@ return (_ctx, _cache) => {
|
|
|
4943
4946
|
: vue.createCommentVNode("v-if", true),
|
|
4944
4947
|
vue.createTextVNode(" " + vue.toDisplayString(__props.action.label), 1 /* TEXT */)
|
|
4945
4948
|
], 10 /* CLASS, PROPS */, _hoisted_2$c))
|
|
4946
|
-
: (!
|
|
4949
|
+
: (!hasAction.value)
|
|
4947
4950
|
? (vue.openBlock(), vue.createBlock(_component_router_link, {
|
|
4948
4951
|
key: 4,
|
|
4949
4952
|
title: __props.action.title,
|
|
@@ -5498,89 +5501,104 @@ const _hoisted_12$1 = {
|
|
|
5498
5501
|
class: "alert alert-danger error-loading"
|
|
5499
5502
|
};
|
|
5500
5503
|
const _hoisted_13$1 = { class: "sh-thead" };
|
|
5501
|
-
const _hoisted_14$1 = {
|
|
5502
|
-
|
|
5504
|
+
const _hoisted_14$1 = {
|
|
5505
|
+
key: 0,
|
|
5506
|
+
style: {"width":"40px"}
|
|
5507
|
+
};
|
|
5508
|
+
const _hoisted_15$1 = { key: 0 };
|
|
5503
5509
|
const _hoisted_16 = ["onClick"];
|
|
5504
5510
|
const _hoisted_17 = ["onClick"];
|
|
5505
5511
|
const _hoisted_18 = ["onClick"];
|
|
5506
|
-
const _hoisted_19 =
|
|
5507
|
-
|
|
5512
|
+
const _hoisted_19 = ["onClick"];
|
|
5513
|
+
const _hoisted_20 = {
|
|
5514
|
+
key: 1,
|
|
5508
5515
|
class: "text-capitalize"
|
|
5509
5516
|
};
|
|
5510
|
-
const
|
|
5511
|
-
const
|
|
5517
|
+
const _hoisted_21 = { class: "sh-tbody" };
|
|
5518
|
+
const _hoisted_22 = {
|
|
5512
5519
|
key: 0,
|
|
5513
5520
|
class: "text-center"
|
|
5514
5521
|
};
|
|
5515
|
-
const
|
|
5516
|
-
const
|
|
5522
|
+
const _hoisted_23 = ["colspan"];
|
|
5523
|
+
const _hoisted_24 = {
|
|
5517
5524
|
key: 1,
|
|
5518
5525
|
class: "text-center alert alert-danger"
|
|
5519
5526
|
};
|
|
5520
|
-
const
|
|
5521
|
-
const
|
|
5527
|
+
const _hoisted_25 = ["colspan"];
|
|
5528
|
+
const _hoisted_26 = {
|
|
5522
5529
|
key: 2,
|
|
5523
5530
|
class: "no_records"
|
|
5524
5531
|
};
|
|
5525
|
-
const
|
|
5526
|
-
const
|
|
5527
|
-
const
|
|
5528
|
-
const
|
|
5529
|
-
const
|
|
5532
|
+
const _hoisted_27 = ["colspan"];
|
|
5533
|
+
const _hoisted_28 = ["onClick"];
|
|
5534
|
+
const _hoisted_29 = ["value", "checked", "onChange"];
|
|
5535
|
+
const _hoisted_30 = { key: 0 };
|
|
5536
|
+
const _hoisted_31 = { key: 1 };
|
|
5537
|
+
const _hoisted_32 = {
|
|
5530
5538
|
key: 2,
|
|
5531
5539
|
class: "text-success fw-bold"
|
|
5532
5540
|
};
|
|
5533
|
-
const
|
|
5534
|
-
const _hoisted_32 = ["innerHTML"];
|
|
5535
|
-
const _hoisted_33 = ["innerHTML"];
|
|
5541
|
+
const _hoisted_33 = { key: 3 };
|
|
5536
5542
|
const _hoisted_34 = ["innerHTML"];
|
|
5537
5543
|
const _hoisted_35 = ["innerHTML"];
|
|
5538
5544
|
const _hoisted_36 = ["innerHTML"];
|
|
5539
5545
|
const _hoisted_37 = ["innerHTML"];
|
|
5540
|
-
const _hoisted_38 =
|
|
5541
|
-
|
|
5546
|
+
const _hoisted_38 = ["innerHTML"];
|
|
5547
|
+
const _hoisted_39 = ["innerHTML"];
|
|
5548
|
+
const _hoisted_40 = {
|
|
5549
|
+
key: 1,
|
|
5542
5550
|
style: {"white-space":"nowrap"}
|
|
5543
5551
|
};
|
|
5544
|
-
const
|
|
5545
|
-
const
|
|
5552
|
+
const _hoisted_41 = { key: 5 };
|
|
5553
|
+
const _hoisted_42 = {
|
|
5546
5554
|
key: 0,
|
|
5547
5555
|
class: "text-center"
|
|
5548
5556
|
};
|
|
5549
|
-
const
|
|
5550
|
-
const
|
|
5557
|
+
const _hoisted_43 = { key: 1 };
|
|
5558
|
+
const _hoisted_44 = {
|
|
5551
5559
|
key: 2,
|
|
5552
5560
|
class: "mobile-list-items"
|
|
5553
5561
|
};
|
|
5554
|
-
const
|
|
5555
|
-
const
|
|
5562
|
+
const _hoisted_45 = ["onClick"];
|
|
5563
|
+
const _hoisted_46 = { class: "form-check" };
|
|
5564
|
+
const _hoisted_47 = ["id", "checked", "onChange"];
|
|
5565
|
+
const _hoisted_48 = ["for"];
|
|
5566
|
+
const _hoisted_49 = {
|
|
5556
5567
|
key: 0,
|
|
5557
5568
|
class: "mb-1 font-weight-bold text-capitalize profile-form-title"
|
|
5558
5569
|
};
|
|
5559
|
-
const
|
|
5570
|
+
const _hoisted_50 = {
|
|
5560
5571
|
key: 1,
|
|
5561
5572
|
class: "mb-1 font-weight-bold text-capitalize profile-form-title"
|
|
5562
5573
|
};
|
|
5563
|
-
const
|
|
5574
|
+
const _hoisted_51 = {
|
|
5564
5575
|
key: 2,
|
|
5565
5576
|
class: "mb-1 font-weight-bold text-capitalize profile-form-title"
|
|
5566
5577
|
};
|
|
5567
|
-
const
|
|
5578
|
+
const _hoisted_52 = {
|
|
5568
5579
|
key: 3,
|
|
5569
5580
|
class: "mb-1 font-weight-bold text-capitalize profile-form-title"
|
|
5570
5581
|
};
|
|
5571
|
-
const
|
|
5572
|
-
const
|
|
5582
|
+
const _hoisted_53 = { key: 1 };
|
|
5583
|
+
const _hoisted_54 = {
|
|
5573
5584
|
key: 2,
|
|
5574
5585
|
class: "text-primary fw-bold"
|
|
5575
5586
|
};
|
|
5576
|
-
const
|
|
5577
|
-
const _hoisted_51 = ["innerHTML"];
|
|
5578
|
-
const _hoisted_52 = ["innerHTML"];
|
|
5579
|
-
const _hoisted_53 = ["innerHTML"];
|
|
5580
|
-
const _hoisted_54 = ["innerHTML"];
|
|
5581
|
-
const _hoisted_55 = ["innerHTML"];
|
|
5587
|
+
const _hoisted_55 = { key: 3 };
|
|
5582
5588
|
const _hoisted_56 = ["innerHTML"];
|
|
5583
|
-
const _hoisted_57 =
|
|
5589
|
+
const _hoisted_57 = ["innerHTML"];
|
|
5590
|
+
const _hoisted_58 = ["innerHTML"];
|
|
5591
|
+
const _hoisted_59 = ["innerHTML"];
|
|
5592
|
+
const _hoisted_60 = ["innerHTML"];
|
|
5593
|
+
const _hoisted_61 = ["innerHTML"];
|
|
5594
|
+
const _hoisted_62 = { key: 1 };
|
|
5595
|
+
const _hoisted_63 = {
|
|
5596
|
+
key: 8,
|
|
5597
|
+
class: "sh-multi-actions-bar shadow-lg border rounded p-3 bg-white d-flex justify-content-between align-items-center animate__animated animate__slideInUp"
|
|
5598
|
+
};
|
|
5599
|
+
const _hoisted_64 = { class: "badge bg-primary rounded-pill me-2" };
|
|
5600
|
+
const _hoisted_65 = { class: "d-flex gap-2" };
|
|
5601
|
+
const _hoisted_66 = ["onClick"];
|
|
5584
5602
|
|
|
5585
5603
|
// --- Props / Emits
|
|
5586
5604
|
|
|
@@ -5615,7 +5633,8 @@ var script$d = {
|
|
|
5615
5633
|
paginationStyle: [String, null],
|
|
5616
5634
|
hasRange: {type: Boolean, default: false},
|
|
5617
5635
|
selectedRange: [Object, null],
|
|
5618
|
-
noRecordsMessage: [String, null]
|
|
5636
|
+
noRecordsMessage: [String, null],
|
|
5637
|
+
multiActions: {type: Array, default: () => []}
|
|
5619
5638
|
},
|
|
5620
5639
|
emits: ['rowSelected', 'dataReloaded', 'dataLoaded'],
|
|
5621
5640
|
setup(__props, { emit: __emit }) {
|
|
@@ -5654,6 +5673,9 @@ const to = vue.ref(null);
|
|
|
5654
5673
|
const period = vue.ref(null);
|
|
5655
5674
|
const lastId = vue.ref(null);
|
|
5656
5675
|
|
|
5676
|
+
const selectedItems = vue.ref([]);
|
|
5677
|
+
const selectAll = vue.ref(false);
|
|
5678
|
+
|
|
5657
5679
|
// Responsive width
|
|
5658
5680
|
const windowWidth = vue.ref(typeof window !== 'undefined' ? window.innerWidth : 1024);
|
|
5659
5681
|
const handleResize = () => (windowWidth.value = window.innerWidth);
|
|
@@ -5686,6 +5708,39 @@ vue.onBeforeUnmount(() => {
|
|
|
5686
5708
|
});
|
|
5687
5709
|
|
|
5688
5710
|
// --- Utils used in template
|
|
5711
|
+
const getData = (record, key) => {
|
|
5712
|
+
if (!key || !record) return ''
|
|
5713
|
+
if (typeof key !== 'string') return ''
|
|
5714
|
+
return key.split('.').reduce((obj, i) => (obj ? obj[i] : ''), record)
|
|
5715
|
+
};
|
|
5716
|
+
|
|
5717
|
+
const getLabel = (title) => {
|
|
5718
|
+
if (typeof title === 'string') {
|
|
5719
|
+
if (title.includes('.')) {
|
|
5720
|
+
const parts = title.split('.');
|
|
5721
|
+
return parts[parts.length - 1].replace(/_/g, ' ')
|
|
5722
|
+
}
|
|
5723
|
+
return title.replace(/_/g, ' ')
|
|
5724
|
+
}
|
|
5725
|
+
if (typeof title === 'object') {
|
|
5726
|
+
if (title.label) return title.label
|
|
5727
|
+
const key = title.key ?? title.field ?? '';
|
|
5728
|
+
if (key.includes('.')) {
|
|
5729
|
+
const parts = key.split('.');
|
|
5730
|
+
return parts[parts.length - 1].replace(/_/g, ' ')
|
|
5731
|
+
}
|
|
5732
|
+
return key.replace(/_/g, ' ')
|
|
5733
|
+
}
|
|
5734
|
+
return ''
|
|
5735
|
+
};
|
|
5736
|
+
|
|
5737
|
+
const getSlotName = (key) => {
|
|
5738
|
+
if (typeof key === 'string') return key
|
|
5739
|
+
if (typeof key === 'object') return key.key ?? key.field ?? ''
|
|
5740
|
+
if (typeof key === 'function') return key(null)
|
|
5741
|
+
return ''
|
|
5742
|
+
};
|
|
5743
|
+
|
|
5689
5744
|
const cleanColumn = (col) => {
|
|
5690
5745
|
const newCol = {...col};
|
|
5691
5746
|
delete newCol.component;
|
|
@@ -5748,9 +5803,13 @@ const getFieldType = (field) => {
|
|
|
5748
5803
|
const numbers = ['age', 'interest_rate_pa'];
|
|
5749
5804
|
const moneys = ['amount', 'paid_amount', 'total_paid', 'total', 'monthly_fee', 'share_cost', 'min_contribution', 'min_membership_contribution'];
|
|
5750
5805
|
const dates = ['invoice_date', 'free_tier_days', 'updated_at', 'created_at', 'end_time'];
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5806
|
+
|
|
5807
|
+
const rawField = typeof field === 'object' ? (field.key ?? field.field ?? '') : field;
|
|
5808
|
+
const lastPart = typeof rawField === 'string' && rawField.includes('.') ? rawField.split('.').pop() : rawField;
|
|
5809
|
+
|
|
5810
|
+
if (typeof lastPart === 'string' && numbers.includes(lastPart)) return 'numeric'
|
|
5811
|
+
if (typeof lastPart === 'string' && moneys.includes(lastPart)) return 'money'
|
|
5812
|
+
if (typeof lastPart === 'string' && dates.includes(lastPart)) return 'date'
|
|
5754
5813
|
return 'string'
|
|
5755
5814
|
};
|
|
5756
5815
|
|
|
@@ -5914,6 +5973,36 @@ const reloadData = (newPage, append) => {
|
|
|
5914
5973
|
});
|
|
5915
5974
|
};
|
|
5916
5975
|
|
|
5976
|
+
const toggleSelectAll = (event) => {
|
|
5977
|
+
if (event.target.checked) {
|
|
5978
|
+
selectedItems.value = records.value.map(r => r.id);
|
|
5979
|
+
} else {
|
|
5980
|
+
selectedItems.value = [];
|
|
5981
|
+
}
|
|
5982
|
+
};
|
|
5983
|
+
|
|
5984
|
+
const toggleSelectItem = (id) => {
|
|
5985
|
+
const index = selectedItems.value.indexOf(id);
|
|
5986
|
+
if (index > -1) {
|
|
5987
|
+
selectedItems.value.splice(index, 1);
|
|
5988
|
+
} else {
|
|
5989
|
+
selectedItems.value.push(id);
|
|
5990
|
+
}
|
|
5991
|
+
};
|
|
5992
|
+
|
|
5993
|
+
const runMultiAction = (action) => {
|
|
5994
|
+
const selectedRecords = records.value.filter(r => selectedItems.value.includes(r.id));
|
|
5995
|
+
if (typeof action.callback === 'function') {
|
|
5996
|
+
action.callback(selectedRecords);
|
|
5997
|
+
}
|
|
5998
|
+
selectedItems.value = [];
|
|
5999
|
+
};
|
|
6000
|
+
|
|
6001
|
+
vue.watch(selectedItems, (newVal) => {
|
|
6002
|
+
selectAll.value = newVal.length === records.value.length && records.value.length > 0;
|
|
6003
|
+
}, {deep: true});
|
|
6004
|
+
|
|
6005
|
+
|
|
5917
6006
|
// --- Watches
|
|
5918
6007
|
vue.watch(() => props.hideIds, (newVal) => {
|
|
5919
6008
|
if (Array.isArray(newVal) && Array.isArray(records.value)) {
|
|
@@ -5942,16 +6031,16 @@ return (_ctx, _cache) => {
|
|
|
5942
6031
|
}, [
|
|
5943
6032
|
(!downloading.value)
|
|
5944
6033
|
? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
|
|
5945
|
-
_cache[
|
|
5946
|
-
_cache[
|
|
6034
|
+
_cache[8] || (_cache[8] = vue.createElementVNode("i", { class: "bi-download" }, null, -1 /* CACHED */)),
|
|
6035
|
+
_cache[9] || (_cache[9] = vue.createTextVNode(" Export ", -1 /* CACHED */))
|
|
5947
6036
|
], 64 /* STABLE_FRAGMENT */))
|
|
5948
6037
|
: (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
5949
|
-
_cache[
|
|
6038
|
+
_cache[10] || (_cache[10] = vue.createElementVNode("span", {
|
|
5950
6039
|
class: "spinner-border spinner-border-sm",
|
|
5951
6040
|
role: "status",
|
|
5952
6041
|
"aria-hidden": "true"
|
|
5953
6042
|
}, null, -1 /* CACHED */)),
|
|
5954
|
-
_cache[
|
|
6043
|
+
_cache[11] || (_cache[11] = vue.createElementVNode("span", { class: "visually-hidden" }, "Loading...", -1 /* CACHED */))
|
|
5955
6044
|
], 64 /* STABLE_FRAGMENT */))
|
|
5956
6045
|
], 8 /* PROPS */, _hoisted_3$6)
|
|
5957
6046
|
]))
|
|
@@ -5983,7 +6072,7 @@ return (_ctx, _cache) => {
|
|
|
5983
6072
|
}, null, 544 /* NEED_HYDRATION, NEED_PATCH */), [
|
|
5984
6073
|
[vue.vModelCheckbox, exactMatch.value]
|
|
5985
6074
|
]),
|
|
5986
|
-
_cache[
|
|
6075
|
+
_cache[12] || (_cache[12] = vue.createElementVNode("span", { class: "ms-1" }, "Exact", -1 /* CACHED */))
|
|
5987
6076
|
]))
|
|
5988
6077
|
: vue.createCommentVNode("v-if", true)
|
|
5989
6078
|
], 2 /* CLASS */),
|
|
@@ -6001,7 +6090,7 @@ return (_ctx, _cache) => {
|
|
|
6001
6090
|
(hasDefaultSlot.value)
|
|
6002
6091
|
? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 2 }, [
|
|
6003
6092
|
(loading.value === 'loading')
|
|
6004
|
-
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_9$2, [...(_cache[
|
|
6093
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_9$2, [...(_cache[13] || (_cache[13] = [
|
|
6005
6094
|
vue.createElementVNode("div", {
|
|
6006
6095
|
class: "spinner-border",
|
|
6007
6096
|
role: "status"
|
|
@@ -6026,7 +6115,7 @@ return (_ctx, _cache) => {
|
|
|
6026
6115
|
: (hasRecordsSlot.value)
|
|
6027
6116
|
? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 3 }, [
|
|
6028
6117
|
(loading.value === 'loading' && !__props.cacheKey)
|
|
6029
|
-
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_11$1, [...(_cache[
|
|
6118
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_11$1, [...(_cache[14] || (_cache[14] = [
|
|
6030
6119
|
vue.createElementVNode("div", {
|
|
6031
6120
|
class: "spinner-border",
|
|
6032
6121
|
role: "status"
|
|
@@ -6044,7 +6133,7 @@ return (_ctx, _cache) => {
|
|
|
6044
6133
|
(!records.value || records.value.length === 0)
|
|
6045
6134
|
? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(noRecordsComponent)), { key: 0 }, {
|
|
6046
6135
|
default: vue.withCtx(() => [
|
|
6047
|
-
_cache[
|
|
6136
|
+
_cache[15] || (_cache[15] = vue.createElementVNode("i", { class: "bi-info-circle" }, null, -1 /* CACHED */)),
|
|
6048
6137
|
vue.createTextVNode(" " + vue.toDisplayString(__props.noRecordsMessage ?? 'No records found'), 1 /* TEXT */)
|
|
6049
6138
|
]),
|
|
6050
6139
|
_: 1 /* STABLE */
|
|
@@ -6061,50 +6150,62 @@ return (_ctx, _cache) => {
|
|
|
6061
6150
|
}, [
|
|
6062
6151
|
vue.createElementVNode("thead", _hoisted_13$1, [
|
|
6063
6152
|
vue.createElementVNode("tr", null, [
|
|
6153
|
+
(__props.multiActions.length > 0)
|
|
6154
|
+
? (vue.openBlock(), vue.createElementBlock("th", _hoisted_14$1, [
|
|
6155
|
+
vue.withDirectives(vue.createElementVNode("input", {
|
|
6156
|
+
type: "checkbox",
|
|
6157
|
+
class: "form-check-input",
|
|
6158
|
+
"onUpdate:modelValue": _cache[4] || (_cache[4] = $event => ((selectAll).value = $event)),
|
|
6159
|
+
onChange: toggleSelectAll
|
|
6160
|
+
}, null, 544 /* NEED_HYDRATION, NEED_PATCH */), [
|
|
6161
|
+
[vue.vModelCheckbox, selectAll.value]
|
|
6162
|
+
])
|
|
6163
|
+
]))
|
|
6164
|
+
: vue.createCommentVNode("v-if", true),
|
|
6064
6165
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(tableHeaders.value, (title) => {
|
|
6065
6166
|
return (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: title }, [
|
|
6066
6167
|
(showColumn(title))
|
|
6067
|
-
? (vue.openBlock(), vue.createElementBlock("th",
|
|
6168
|
+
? (vue.openBlock(), vue.createElementBlock("th", _hoisted_15$1, [
|
|
6068
6169
|
(typeof title === 'string')
|
|
6069
6170
|
? (vue.openBlock(), vue.createElementBlock("a", {
|
|
6070
6171
|
key: 0,
|
|
6071
6172
|
class: "text-capitalize",
|
|
6072
6173
|
onClick: $event => (changeKey('order_by', title))
|
|
6073
|
-
}, vue.toDisplayString(title
|
|
6174
|
+
}, vue.toDisplayString(getLabel(title)), 9 /* TEXT, PROPS */, _hoisted_16))
|
|
6074
6175
|
: (typeof title === 'object')
|
|
6075
6176
|
? (vue.openBlock(), vue.createElementBlock("a", {
|
|
6076
6177
|
key: 1,
|
|
6077
6178
|
class: "text-capitalize",
|
|
6078
6179
|
onClick: $event => (changeKey('order_by', title.key))
|
|
6079
|
-
}, vue.toDisplayString(title
|
|
6180
|
+
}, vue.toDisplayString(getLabel(title)), 9 /* TEXT, PROPS */, _hoisted_17))
|
|
6080
6181
|
: (typeof title === 'function')
|
|
6081
6182
|
? (vue.openBlock(), vue.createElementBlock("a", {
|
|
6082
6183
|
key: 2,
|
|
6083
6184
|
class: "text-capitalize",
|
|
6084
6185
|
onClick: $event => (changeKey('order_by', title(null)))
|
|
6085
|
-
}, vue.toDisplayString(title(null).replace(/_/g, ' ')), 9 /* TEXT, PROPS */,
|
|
6186
|
+
}, vue.toDisplayString(title(null).replace(/_/g, ' ')), 9 /* TEXT, PROPS */, _hoisted_18))
|
|
6086
6187
|
: (typeof title !== 'undefined')
|
|
6087
6188
|
? (vue.openBlock(), vue.createElementBlock("a", {
|
|
6088
6189
|
key: 3,
|
|
6089
6190
|
class: "text-capitalize",
|
|
6090
6191
|
onClick: $event => (changeKey('order_by', title))
|
|
6091
|
-
}, vue.toDisplayString(String(title)
|
|
6192
|
+
}, vue.toDisplayString(String(getLabel(title))), 9 /* TEXT, PROPS */, _hoisted_19))
|
|
6092
6193
|
: vue.createCommentVNode("v-if", true)
|
|
6093
6194
|
]))
|
|
6094
6195
|
: vue.createCommentVNode("v-if", true)
|
|
6095
6196
|
], 64 /* STABLE_FRAGMENT */))
|
|
6096
6197
|
}), 128 /* KEYED_FRAGMENT */)),
|
|
6097
6198
|
(__props.actions)
|
|
6098
|
-
? (vue.openBlock(), vue.createElementBlock("th",
|
|
6199
|
+
? (vue.openBlock(), vue.createElementBlock("th", _hoisted_20, vue.toDisplayString(__props.actions.label), 1 /* TEXT */))
|
|
6099
6200
|
: vue.createCommentVNode("v-if", true)
|
|
6100
6201
|
])
|
|
6101
6202
|
]),
|
|
6102
|
-
vue.createElementVNode("tbody",
|
|
6203
|
+
vue.createElementVNode("tbody", _hoisted_21, [
|
|
6103
6204
|
(loading.value === 'loading')
|
|
6104
|
-
? (vue.openBlock(), vue.createElementBlock("tr",
|
|
6205
|
+
? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_22, [
|
|
6105
6206
|
vue.createElementVNode("td", {
|
|
6106
|
-
colspan: tableHeaders.value.length
|
|
6107
|
-
}, [...(_cache[
|
|
6207
|
+
colspan: __props.multiActions.length > 0 ? tableHeaders.value.length + 1 : tableHeaders.value.length
|
|
6208
|
+
}, [...(_cache[16] || (_cache[16] = [
|
|
6108
6209
|
vue.createElementVNode("div", { class: "text-center" }, [
|
|
6109
6210
|
vue.createElementVNode("div", {
|
|
6110
6211
|
class: "spinner-border",
|
|
@@ -6113,24 +6214,24 @@ return (_ctx, _cache) => {
|
|
|
6113
6214
|
vue.createElementVNode("span", { class: "visually-hidden" }, "Loading...")
|
|
6114
6215
|
])
|
|
6115
6216
|
], -1 /* CACHED */)
|
|
6116
|
-
]))], 8 /* PROPS */,
|
|
6217
|
+
]))], 8 /* PROPS */, _hoisted_23)
|
|
6117
6218
|
]))
|
|
6118
6219
|
: (loading.value === 'error')
|
|
6119
|
-
? (vue.openBlock(), vue.createElementBlock("tr",
|
|
6220
|
+
? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_24, [
|
|
6120
6221
|
vue.createElementVNode("td", {
|
|
6121
|
-
colspan: tableHeaders.value.length
|
|
6122
|
-
}, vue.toDisplayString(loading_error.value), 9 /* TEXT, PROPS */,
|
|
6222
|
+
colspan: __props.multiActions.length > 0 ? tableHeaders.value.length + 1 : tableHeaders.value.length
|
|
6223
|
+
}, vue.toDisplayString(loading_error.value), 9 /* TEXT, PROPS */, _hoisted_25)
|
|
6123
6224
|
]))
|
|
6124
6225
|
: (records.value.length === 0)
|
|
6125
|
-
? (vue.openBlock(), vue.createElementBlock("tr",
|
|
6226
|
+
? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_26, [
|
|
6126
6227
|
vue.createElementVNode("td", {
|
|
6127
|
-
colspan: __props.actions ? tableHeaders.value.length + 1 : tableHeaders.value.length
|
|
6128
|
-
}, [...(_cache[
|
|
6228
|
+
colspan: __props.actions ? tableHeaders.value.length + (__props.multiActions.length > 0 ? 2:1) : tableHeaders.value.length + (__props.multiActions.length > 0 ? 1:0)
|
|
6229
|
+
}, [...(_cache[17] || (_cache[17] = [
|
|
6129
6230
|
vue.createElementVNode("div", { class: "text-center bg-primary-light px-2 py-1 rounded no_records_div" }, [
|
|
6130
6231
|
vue.createElementVNode("i", { class: "bi-info-circle" }),
|
|
6131
6232
|
vue.createTextVNode(" No records found ")
|
|
6132
6233
|
], -1 /* CACHED */)
|
|
6133
|
-
]))], 8 /* PROPS */,
|
|
6234
|
+
]))], 8 /* PROPS */, _hoisted_27)
|
|
6134
6235
|
]))
|
|
6135
6236
|
: (loading.value === 'done')
|
|
6136
6237
|
? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 3 }, vue.renderList(records.value, (record, index) => {
|
|
@@ -6139,64 +6240,83 @@ return (_ctx, _cache) => {
|
|
|
6139
6240
|
class: vue.normalizeClass(record.class),
|
|
6140
6241
|
onClick: $event => (rowSelected(record))
|
|
6141
6242
|
}, [
|
|
6243
|
+
(__props.multiActions.length > 0)
|
|
6244
|
+
? (vue.openBlock(), vue.createElementBlock("td", {
|
|
6245
|
+
key: 0,
|
|
6246
|
+
onClick: _cache[5] || (_cache[5] = vue.withModifiers(() => {}, ["stop"]))
|
|
6247
|
+
}, [
|
|
6248
|
+
vue.createElementVNode("input", {
|
|
6249
|
+
type: "checkbox",
|
|
6250
|
+
class: "form-check-input",
|
|
6251
|
+
value: record.id,
|
|
6252
|
+
checked: selectedItems.value.includes(record.id),
|
|
6253
|
+
onChange: $event => (toggleSelectItem(record.id))
|
|
6254
|
+
}, null, 40 /* PROPS, NEED_HYDRATION */, _hoisted_29)
|
|
6255
|
+
]))
|
|
6256
|
+
: vue.createCommentVNode("v-if", true),
|
|
6142
6257
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(tableHeaders.value, (key) => {
|
|
6143
6258
|
return (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: key }, [
|
|
6144
6259
|
(showColumn(key))
|
|
6145
|
-
? (vue.openBlock(), vue.createElementBlock("td",
|
|
6146
|
-
(
|
|
6147
|
-
|
|
6148
|
-
|
|
6149
|
-
|
|
6150
|
-
|
|
6151
|
-
|
|
6152
|
-
|
|
6153
|
-
|
|
6154
|
-
|
|
6155
|
-
|
|
6156
|
-
|
|
6157
|
-
|
|
6158
|
-
|
|
6159
|
-
|
|
6160
|
-
|
|
6161
|
-
|
|
6162
|
-
|
|
6163
|
-
|
|
6164
|
-
|
|
6165
|
-
: (typeof key === 'function')
|
|
6260
|
+
? (vue.openBlock(), vue.createElementBlock("td", _hoisted_30, [
|
|
6261
|
+
vue.renderSlot(_ctx.$slots, getSlotName(key), {
|
|
6262
|
+
row: record,
|
|
6263
|
+
index: index
|
|
6264
|
+
}, () => [
|
|
6265
|
+
(typeof key === 'string' && __props.links && __props.links[key])
|
|
6266
|
+
? (vue.openBlock(), vue.createBlock(_component_router_link, {
|
|
6267
|
+
key: 0,
|
|
6268
|
+
target: __props.links[key].target ? '_blank':'',
|
|
6269
|
+
to: replaceLinkUrl(__props.links[key], record),
|
|
6270
|
+
class: vue.normalizeClass(getLinkClass(__props.links[key])),
|
|
6271
|
+
innerHTML: getData(record, key)
|
|
6272
|
+
}, null, 8 /* PROPS */, ["target", "to", "class", "innerHTML"]))
|
|
6273
|
+
: (getFieldType(key) === 'numeric')
|
|
6274
|
+
? (vue.openBlock(), vue.createElementBlock("span", _hoisted_31, vue.toDisplayString(Intl.NumberFormat().format(getData(record, key))), 1 /* TEXT */))
|
|
6275
|
+
: (getFieldType(key) === 'money')
|
|
6276
|
+
? (vue.openBlock(), vue.createElementBlock("span", _hoisted_32, vue.toDisplayString(Intl.NumberFormat().format(getData(record, key))), 1 /* TEXT */))
|
|
6277
|
+
: (getFieldType(key) === 'date')
|
|
6278
|
+
? (vue.openBlock(), vue.createElementBlock("span", _hoisted_33, vue.toDisplayString(formatDate(getData(record, key))), 1 /* TEXT */))
|
|
6279
|
+
: (typeof key === 'string')
|
|
6166
6280
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6167
|
-
key:
|
|
6168
|
-
innerHTML:
|
|
6169
|
-
}, null, 8 /* PROPS */,
|
|
6170
|
-
: (typeof key === '
|
|
6281
|
+
key: 4,
|
|
6282
|
+
innerHTML: getData(record, key)
|
|
6283
|
+
}, null, 8 /* PROPS */, _hoisted_34))
|
|
6284
|
+
: (typeof key === 'function')
|
|
6171
6285
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6172
|
-
key:
|
|
6173
|
-
innerHTML: key
|
|
6174
|
-
}, null, 8 /* PROPS */,
|
|
6175
|
-
: (typeof key === 'object' && key.
|
|
6286
|
+
key: 5,
|
|
6287
|
+
innerHTML: key(record, index)
|
|
6288
|
+
}, null, 8 /* PROPS */, _hoisted_35))
|
|
6289
|
+
: (typeof key === 'object' && key.callBack)
|
|
6176
6290
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6177
|
-
key:
|
|
6178
|
-
innerHTML: key.
|
|
6179
|
-
}, null, 8 /* PROPS */,
|
|
6180
|
-
: (typeof key === 'object' && key.
|
|
6181
|
-
? (vue.openBlock(), vue.
|
|
6182
|
-
key:
|
|
6183
|
-
|
|
6184
|
-
},
|
|
6185
|
-
: (typeof key === 'object')
|
|
6186
|
-
? (vue.openBlock(), vue.
|
|
6187
|
-
key:
|
|
6188
|
-
|
|
6189
|
-
}, null,
|
|
6190
|
-
: (
|
|
6191
|
-
|
|
6192
|
-
|
|
6193
|
-
|
|
6291
|
+
key: 6,
|
|
6292
|
+
innerHTML: key.callBack(record, index)
|
|
6293
|
+
}, null, 8 /* PROPS */, _hoisted_36))
|
|
6294
|
+
: (typeof key === 'object' && key.callback)
|
|
6295
|
+
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6296
|
+
key: 7,
|
|
6297
|
+
innerHTML: key.callback(record, index)
|
|
6298
|
+
}, null, 8 /* PROPS */, _hoisted_37))
|
|
6299
|
+
: (typeof key === 'object' && key.component)
|
|
6300
|
+
? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(key.component), vue.mergeProps({
|
|
6301
|
+
key: 8,
|
|
6302
|
+
item: record
|
|
6303
|
+
}, { ref_for: true }, cleanColumn(key)), null, 16 /* FULL_PROPS */, ["item"]))
|
|
6304
|
+
: (typeof key === 'object')
|
|
6305
|
+
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6306
|
+
key: 9,
|
|
6307
|
+
innerHTML: getData(record, key.key ?? key.field)
|
|
6308
|
+
}, null, 8 /* PROPS */, _hoisted_38))
|
|
6309
|
+
: (vue.openBlock(), vue.createElementBlock("span", {
|
|
6310
|
+
key: 10,
|
|
6311
|
+
innerHTML: getData(record, key[0])
|
|
6312
|
+
}, null, 8 /* PROPS */, _hoisted_39))
|
|
6313
|
+
])
|
|
6194
6314
|
]))
|
|
6195
6315
|
: vue.createCommentVNode("v-if", true)
|
|
6196
6316
|
], 64 /* STABLE_FRAGMENT */))
|
|
6197
6317
|
}), 128 /* KEYED_FRAGMENT */)),
|
|
6198
6318
|
(__props.actions)
|
|
6199
|
-
? (vue.openBlock(), vue.createElementBlock("td",
|
|
6319
|
+
? (vue.openBlock(), vue.createElementBlock("td", _hoisted_40, [
|
|
6200
6320
|
vue.createVNode(script$g, {
|
|
6201
6321
|
emitAction: doEmitAction,
|
|
6202
6322
|
actions: __props.actions,
|
|
@@ -6204,14 +6324,14 @@ return (_ctx, _cache) => {
|
|
|
6204
6324
|
}, null, 8 /* PROPS */, ["actions", "record"])
|
|
6205
6325
|
]))
|
|
6206
6326
|
: vue.createCommentVNode("v-if", true)
|
|
6207
|
-
], 10 /* CLASS, PROPS */,
|
|
6327
|
+
], 10 /* CLASS, PROPS */, _hoisted_28))
|
|
6208
6328
|
}), 128 /* KEYED_FRAGMENT */))
|
|
6209
6329
|
: vue.createCommentVNode("v-if", true)
|
|
6210
6330
|
])
|
|
6211
6331
|
], 2 /* CLASS */))
|
|
6212
|
-
: (vue.openBlock(), vue.createElementBlock("div",
|
|
6332
|
+
: (vue.openBlock(), vue.createElementBlock("div", _hoisted_41, [
|
|
6213
6333
|
(loading.value === 'loading')
|
|
6214
|
-
? (vue.openBlock(), vue.createElementBlock("div",
|
|
6334
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_42, [...(_cache[18] || (_cache[18] = [
|
|
6215
6335
|
vue.createElementVNode("div", { class: "text-center" }, [
|
|
6216
6336
|
vue.createElementVNode("div", {
|
|
6217
6337
|
class: "spinner-border",
|
|
@@ -6222,17 +6342,38 @@ return (_ctx, _cache) => {
|
|
|
6222
6342
|
], -1 /* CACHED */)
|
|
6223
6343
|
]))]))
|
|
6224
6344
|
: (loading.value === 'error')
|
|
6225
|
-
? (vue.openBlock(), vue.createElementBlock("div",
|
|
6345
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_43, [
|
|
6226
6346
|
vue.createElementVNode("span", null, vue.toDisplayString(loading_error.value), 1 /* TEXT */)
|
|
6227
6347
|
]))
|
|
6228
6348
|
: (loading.value === 'done')
|
|
6229
|
-
? (vue.openBlock(), vue.createElementBlock("div",
|
|
6349
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_44, [
|
|
6230
6350
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(records.value, (record, index) => {
|
|
6231
6351
|
return (vue.openBlock(), vue.createElementBlock("div", {
|
|
6232
6352
|
key: record.id,
|
|
6233
6353
|
class: "single-mobile-req bg-light p-3",
|
|
6234
6354
|
onClick: $event => (rowSelected(record))
|
|
6235
6355
|
}, [
|
|
6356
|
+
(__props.multiActions.length > 0)
|
|
6357
|
+
? (vue.openBlock(), vue.createElementBlock("div", {
|
|
6358
|
+
key: 0,
|
|
6359
|
+
class: "mb-2",
|
|
6360
|
+
onClick: _cache[6] || (_cache[6] = vue.withModifiers(() => {}, ["stop"]))
|
|
6361
|
+
}, [
|
|
6362
|
+
vue.createElementVNode("div", _hoisted_46, [
|
|
6363
|
+
vue.createElementVNode("input", {
|
|
6364
|
+
type: "checkbox",
|
|
6365
|
+
class: "form-check-input",
|
|
6366
|
+
id: 'mobile-check-'+record.id,
|
|
6367
|
+
checked: selectedItems.value.includes(record.id),
|
|
6368
|
+
onChange: $event => (toggleSelectItem(record.id))
|
|
6369
|
+
}, null, 40 /* PROPS, NEED_HYDRATION */, _hoisted_47),
|
|
6370
|
+
vue.createElementVNode("label", {
|
|
6371
|
+
class: "form-check-label",
|
|
6372
|
+
for: 'mobile-check-'+record.id
|
|
6373
|
+
}, "Select Item", 8 /* PROPS */, _hoisted_48)
|
|
6374
|
+
])
|
|
6375
|
+
]))
|
|
6376
|
+
: vue.createCommentVNode("v-if", true),
|
|
6236
6377
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(tableHeaders.value, (key) => {
|
|
6237
6378
|
return (vue.openBlock(), vue.createElementBlock(vue.Fragment, {
|
|
6238
6379
|
key: key[0]
|
|
@@ -6240,68 +6381,73 @@ return (_ctx, _cache) => {
|
|
|
6240
6381
|
(showColumn(key))
|
|
6241
6382
|
? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
|
|
6242
6383
|
(typeof key === 'string' )
|
|
6243
|
-
? (vue.openBlock(), vue.createElementBlock("p",
|
|
6384
|
+
? (vue.openBlock(), vue.createElementBlock("p", _hoisted_49, vue.toDisplayString(getLabel(key)), 1 /* TEXT */))
|
|
6244
6385
|
: (typeof key === 'function')
|
|
6245
|
-
? (vue.openBlock(), vue.createElementBlock("p",
|
|
6386
|
+
? (vue.openBlock(), vue.createElementBlock("p", _hoisted_50, vue.toDisplayString(key(null).replace(/_/g, ' ')), 1 /* TEXT */))
|
|
6246
6387
|
: (typeof key === 'object')
|
|
6247
|
-
? (vue.openBlock(), vue.createElementBlock("p",
|
|
6248
|
-
: (vue.openBlock(), vue.createElementBlock("p",
|
|
6388
|
+
? (vue.openBlock(), vue.createElementBlock("p", _hoisted_51, vue.toDisplayString(getLabel(key)), 1 /* TEXT */))
|
|
6389
|
+
: (vue.openBlock(), vue.createElementBlock("p", _hoisted_52, vue.toDisplayString(key[1].replace(/_/g, ' ')), 1 /* TEXT */)),
|
|
6249
6390
|
vue.createElementVNode("span", null, [
|
|
6250
|
-
(
|
|
6251
|
-
|
|
6252
|
-
|
|
6253
|
-
|
|
6254
|
-
|
|
6255
|
-
|
|
6256
|
-
|
|
6257
|
-
|
|
6258
|
-
|
|
6259
|
-
|
|
6260
|
-
|
|
6261
|
-
|
|
6262
|
-
|
|
6263
|
-
|
|
6264
|
-
|
|
6265
|
-
|
|
6266
|
-
|
|
6267
|
-
|
|
6268
|
-
: (typeof key === 'object' && key.callBack)
|
|
6391
|
+
vue.renderSlot(_ctx.$slots, getSlotName(key), {
|
|
6392
|
+
row: record,
|
|
6393
|
+
index: index
|
|
6394
|
+
}, () => [
|
|
6395
|
+
(typeof key === 'string' && __props.links && __props.links[key])
|
|
6396
|
+
? (vue.openBlock(), vue.createBlock(_component_router_link, {
|
|
6397
|
+
key: 0,
|
|
6398
|
+
to: replaceLinkUrl(__props.links[key],record),
|
|
6399
|
+
class: vue.normalizeClass(getLinkClass(__props.links[key])),
|
|
6400
|
+
innerHTML: getData(record, key)
|
|
6401
|
+
}, null, 8 /* PROPS */, ["to", "class", "innerHTML"]))
|
|
6402
|
+
: (getFieldType(key) === 'numeric')
|
|
6403
|
+
? (vue.openBlock(), vue.createElementBlock("span", _hoisted_53, vue.toDisplayString(Intl.NumberFormat().format(getData(record, key))), 1 /* TEXT */))
|
|
6404
|
+
: (getFieldType(key) === 'money')
|
|
6405
|
+
? (vue.openBlock(), vue.createElementBlock("span", _hoisted_54, vue.toDisplayString(Intl.NumberFormat().format(getData(record, key))), 1 /* TEXT */))
|
|
6406
|
+
: (getFieldType(key) === 'date')
|
|
6407
|
+
? (vue.openBlock(), vue.createElementBlock("span", _hoisted_55, vue.toDisplayString(formatDate(getData(record, key))), 1 /* TEXT */))
|
|
6408
|
+
: (typeof key === 'string')
|
|
6269
6409
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6270
|
-
key:
|
|
6271
|
-
innerHTML:
|
|
6272
|
-
}, null, 8 /* PROPS */,
|
|
6273
|
-
: (typeof key === 'object' && key.
|
|
6410
|
+
key: 4,
|
|
6411
|
+
innerHTML: getData(record, key)
|
|
6412
|
+
}, null, 8 /* PROPS */, _hoisted_56))
|
|
6413
|
+
: (typeof key === 'object' && key.callBack)
|
|
6274
6414
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6275
|
-
key:
|
|
6276
|
-
innerHTML: key.
|
|
6277
|
-
}, null, 8 /* PROPS */,
|
|
6278
|
-
: (typeof key === 'object' && key.
|
|
6279
|
-
? (vue.openBlock(), vue.
|
|
6280
|
-
key:
|
|
6281
|
-
|
|
6282
|
-
},
|
|
6283
|
-
: (typeof key === 'object')
|
|
6284
|
-
? (vue.openBlock(), vue.
|
|
6285
|
-
key:
|
|
6286
|
-
|
|
6287
|
-
}, null,
|
|
6288
|
-
: (typeof key === '
|
|
6415
|
+
key: 5,
|
|
6416
|
+
innerHTML: key.callBack(record, index)
|
|
6417
|
+
}, null, 8 /* PROPS */, _hoisted_57))
|
|
6418
|
+
: (typeof key === 'object' && key.callback)
|
|
6419
|
+
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6420
|
+
key: 6,
|
|
6421
|
+
innerHTML: key.callback(record, index)
|
|
6422
|
+
}, null, 8 /* PROPS */, _hoisted_58))
|
|
6423
|
+
: (typeof key === 'object' && key.component)
|
|
6424
|
+
? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(key.component), vue.mergeProps({
|
|
6425
|
+
key: 7,
|
|
6426
|
+
item: record
|
|
6427
|
+
}, { ref_for: true }, cleanColumn(key)), null, 16 /* FULL_PROPS */, ["item"]))
|
|
6428
|
+
: (typeof key === 'object')
|
|
6289
6429
|
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6290
|
-
key:
|
|
6291
|
-
innerHTML:
|
|
6292
|
-
}, null, 8 /* PROPS */,
|
|
6293
|
-
: (
|
|
6294
|
-
|
|
6295
|
-
|
|
6296
|
-
|
|
6430
|
+
key: 8,
|
|
6431
|
+
innerHTML: getData(record, key.key ?? key.field)
|
|
6432
|
+
}, null, 8 /* PROPS */, _hoisted_59))
|
|
6433
|
+
: (typeof key === 'function')
|
|
6434
|
+
? (vue.openBlock(), vue.createElementBlock("span", {
|
|
6435
|
+
key: 9,
|
|
6436
|
+
innerHTML: key(record, index)
|
|
6437
|
+
}, null, 8 /* PROPS */, _hoisted_60))
|
|
6438
|
+
: (vue.openBlock(), vue.createElementBlock("span", {
|
|
6439
|
+
key: 10,
|
|
6440
|
+
innerHTML: getData(record, key[0])
|
|
6441
|
+
}, null, 8 /* PROPS */, _hoisted_61))
|
|
6442
|
+
])
|
|
6297
6443
|
])
|
|
6298
6444
|
], 64 /* STABLE_FRAGMENT */))
|
|
6299
6445
|
: vue.createCommentVNode("v-if", true),
|
|
6300
|
-
_cache[
|
|
6446
|
+
_cache[19] || (_cache[19] = vue.createElementVNode("hr", { class: "my-2" }, null, -1 /* CACHED */))
|
|
6301
6447
|
], 64 /* STABLE_FRAGMENT */))
|
|
6302
6448
|
}), 128 /* KEYED_FRAGMENT */)),
|
|
6303
6449
|
(__props.actions)
|
|
6304
|
-
? (vue.openBlock(), vue.createElementBlock("div",
|
|
6450
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_62, [
|
|
6305
6451
|
vue.createVNode(script$g, {
|
|
6306
6452
|
emitAction: doEmitAction,
|
|
6307
6453
|
actions: __props.actions,
|
|
@@ -6309,7 +6455,7 @@ return (_ctx, _cache) => {
|
|
|
6309
6455
|
}, null, 8 /* PROPS */, ["actions", "record"])
|
|
6310
6456
|
]))
|
|
6311
6457
|
: vue.createCommentVNode("v-if", true)
|
|
6312
|
-
], 8 /* PROPS */,
|
|
6458
|
+
], 8 /* PROPS */, _hoisted_45))
|
|
6313
6459
|
}), 128 /* KEYED_FRAGMENT */))
|
|
6314
6460
|
]))
|
|
6315
6461
|
: vue.createCommentVNode("v-if", true)
|
|
@@ -6353,6 +6499,35 @@ return (_ctx, _cache) => {
|
|
|
6353
6499
|
: vue.createCommentVNode("v-if", true)
|
|
6354
6500
|
], 64 /* STABLE_FRAGMENT */))
|
|
6355
6501
|
}), 128 /* KEYED_FRAGMENT */))
|
|
6502
|
+
: vue.createCommentVNode("v-if", true),
|
|
6503
|
+
(selectedItems.value.length > 0)
|
|
6504
|
+
? (vue.openBlock(), vue.createElementBlock("div", _hoisted_63, [
|
|
6505
|
+
vue.createElementVNode("div", null, [
|
|
6506
|
+
vue.createElementVNode("span", _hoisted_64, vue.toDisplayString(selectedItems.value.length), 1 /* TEXT */),
|
|
6507
|
+
_cache[20] || (_cache[20] = vue.createTextVNode(" items selected ", -1 /* CACHED */))
|
|
6508
|
+
]),
|
|
6509
|
+
vue.createElementVNode("div", _hoisted_65, [
|
|
6510
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.multiActions, (action) => {
|
|
6511
|
+
return (vue.openBlock(), vue.createElementBlock("button", {
|
|
6512
|
+
key: action.label,
|
|
6513
|
+
class: vue.normalizeClass(["btn btn-sm", action.class ?? 'btn-outline-primary']),
|
|
6514
|
+
onClick: $event => (runMultiAction(action))
|
|
6515
|
+
}, [
|
|
6516
|
+
(action.icon)
|
|
6517
|
+
? (vue.openBlock(), vue.createElementBlock("i", {
|
|
6518
|
+
key: 0,
|
|
6519
|
+
class: vue.normalizeClass(action.icon)
|
|
6520
|
+
}, null, 2 /* CLASS */))
|
|
6521
|
+
: vue.createCommentVNode("v-if", true),
|
|
6522
|
+
vue.createTextVNode(" " + vue.toDisplayString(action.label), 1 /* TEXT */)
|
|
6523
|
+
], 10 /* CLASS, PROPS */, _hoisted_66))
|
|
6524
|
+
}), 128 /* KEYED_FRAGMENT */)),
|
|
6525
|
+
vue.createElementVNode("button", {
|
|
6526
|
+
class: "btn btn-sm btn-light",
|
|
6527
|
+
onClick: _cache[7] || (_cache[7] = $event => (selectedItems.value = []))
|
|
6528
|
+
}, "Cancel")
|
|
6529
|
+
])
|
|
6530
|
+
]))
|
|
6356
6531
|
: vue.createCommentVNode("v-if", true)
|
|
6357
6532
|
]))
|
|
6358
6533
|
}
|