@oniti/quasar-ui-vlank-collection-crud 3.7.53 → 3.7.55

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/index.umd.js CHANGED
@@ -1,14 +1,14 @@
1
1
  /*!
2
- * @oniti/quasar-ui-vlank-collection-crud v3.7.52
2
+ * @oniti/quasar-ui-vlank-collection-crud v3.7.54
3
3
  * (c) 2025 Oniti
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  (function (global, factory) {
8
- typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('vue'), require('quasar'), require('@oniti/oniti-helpers'), require('oniti-sse-client'), require('vuex'), require('vue-router'), require('vlank-collection-crud-forms')) :
9
- typeof define === 'function' && define.amd ? define(['vue', 'quasar', '@oniti/oniti-helpers', 'oniti-sse-client', 'vuex', 'vue-router', 'vlank-collection-crud-forms'], factory) :
10
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.global = factory(global.Vue, global.Quasar, global.onitiHelpers, global.onitiSseClient, global.vuex, global.vueRouter, global.Components));
11
- })(this, (function (vue, quasar, onitiHelpers, onitiSseClient, vuex, vueRouter, Components) { 'use strict';
8
+ typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('vue'), require('quasar'), require('@oniti/oniti-helpers'), require('oniti-sse-client'), require('axios-oniti'), require('vuex'), require('vue-router'), require('vlank-collection-crud-forms')) :
9
+ typeof define === 'function' && define.amd ? define(['vue', 'quasar', '@oniti/oniti-helpers', 'oniti-sse-client', 'axios-oniti', 'vuex', 'vue-router', 'vlank-collection-crud-forms'], factory) :
10
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.global = factory(global.Vue, global.Quasar, global.onitiHelpers, global.onitiSseClient, global.axiosOniti, global.vuex, global.vueRouter, global.Components));
11
+ })(this, (function (vue, quasar, onitiHelpers, onitiSseClient, axiosOniti, vuex, vueRouter, Components) { 'use strict';
12
12
 
13
13
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
14
14
 
@@ -616,6 +616,9 @@
616
616
  },
617
617
  propsLibelleTitle: null,
618
618
  customCreateButtonText: null,
619
+ exportOptions: {
620
+ enabled: false,
621
+ },
619
622
  };
620
623
 
621
624
  /**
@@ -685,6 +688,10 @@
685
688
  var rightName = getRightName("create");
686
689
  return props.value.showBtnCreate && (!rightName || $auth.check(rightName));
687
690
  });
691
+ var showBtnExport = vue.computed(function () {
692
+ // TODO: check a specific 'export' right?
693
+ return props.value.exportOptions && props.value.exportOptions.enabled;
694
+ });
688
695
  var editOnTable = vue.computed(function () {
689
696
  return props.value.editMode === "table" && showBtnEdit.value;
690
697
  });
@@ -697,6 +704,7 @@
697
704
  showBtnEditPage: showBtnEditPage,
698
705
  showBtnEditModal: showBtnEditModal,
699
706
  showBtnCreatePage: showBtnCreatePage,
707
+ showBtnExport: showBtnExport,
700
708
  editOnTable: editOnTable,
701
709
  };
702
710
  }
@@ -1286,6 +1294,72 @@
1286
1294
  }
1287
1295
  }
1288
1296
 
1297
+ function useExportCSV(props, pagination, filter) {
1298
+ var $collectionCrud = vue.inject('vlank-ccrud');
1299
+ var $q = quasar.useQuasar();
1300
+
1301
+ function showDlFailure() {
1302
+ $q.notify({
1303
+ message: 'Téléchargement impossible',
1304
+ color: 'negative',
1305
+ icon: 'warning'
1306
+ });
1307
+ }
1308
+
1309
+ function doExport() {
1310
+ var exportParams = {
1311
+ 'primaryFieldSearch': $collectionCrud.getRouteParameterName(props.value.collection),
1312
+ 'sortBy': pagination.value.sortBy,
1313
+ 'descending': pagination.value.descending,
1314
+ 'filter': filter.value,
1315
+ };
1316
+
1317
+ var options = props.value.exportOptions;
1318
+ var url = (options && options.url) ? options.url : ("/" + (props.value.collection) + "/export");
1319
+
1320
+ axiosOniti.axiosClient
1321
+ .get(url, {
1322
+ params: exportParams,
1323
+ responseType: 'blob',
1324
+ })
1325
+ .then(function (response) {
1326
+ var contentDisposition = response.headers['content-disposition'];
1327
+ if (!contentDisposition) {
1328
+ showDlFailure();
1329
+ console.error('No Content-Disposition header found (see exposed_headers in config/cors.php)');
1330
+ return
1331
+ }
1332
+
1333
+ var parts = contentDisposition.split('filename=');
1334
+ if (parts.length !== 2) {
1335
+ showDlFailure();
1336
+ console.error('Invalid content-disposition header (missing filename)');
1337
+ return
1338
+ }
1339
+
1340
+ var filename = parts[1];
1341
+ var mime = response.data.type;
1342
+
1343
+ var status = quasar.exportFile(
1344
+ filename,
1345
+ response.data,
1346
+ mime
1347
+ );
1348
+
1349
+ if (status !== true) {
1350
+ showDlFailure();
1351
+ }
1352
+ })
1353
+ .catch(function () {
1354
+ showDlFailure();
1355
+ });
1356
+ }
1357
+
1358
+ return {
1359
+ doExport: doExport
1360
+ }
1361
+ }
1362
+
1289
1363
  var _hoisted_1$2 = { class: "col" };
1290
1364
  var _hoisted_2$2 = { key: 1 };
1291
1365
  var _hoisted_3$2 = { key: 2 };
@@ -1363,6 +1437,7 @@
1363
1437
  type: Function,
1364
1438
  default: null
1365
1439
  },
1440
+ exportOptions: Object,
1366
1441
  },
1367
1442
  emits: [
1368
1443
  "detailChange",
@@ -1419,6 +1494,7 @@
1419
1494
  var showBtnEditPage = ref$3.showBtnEditPage;
1420
1495
  var showBtnEditModal = ref$3.showBtnEditModal;
1421
1496
  var showBtnCreatePage = ref$3.showBtnCreatePage;
1497
+ var showBtnExport = ref$3.showBtnExport;
1422
1498
  var editOnTable = ref$3.editOnTable;
1423
1499
 
1424
1500
  var ref$4 = useTable(props, $slots, showBtnEdit, showBtnDelete);
@@ -1565,331 +1641,349 @@
1565
1641
  filter.value = "";
1566
1642
  }
1567
1643
 
1644
+ var ref$9 = useExportCSV(props, pagination, filter);
1645
+ var doExport = ref$9.doExport;
1646
+
1647
+
1568
1648
  return function (_ctx, _cache) {
1569
1649
  return (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$2, [
1570
- (vue.unref(rows))
1571
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QTable), vue.mergeProps({
1572
- key: 0,
1573
- flat: "",
1574
- rows: vue.unref(rows)
1575
- }, vue.unref(table), {
1576
- filter: filter.value,
1577
- onRequest: vue.unref(asyncRequest),
1578
- ref_key: "ccrudTable",
1579
- ref: ccrudTable,
1580
- pagination: vue.unref(pagination),
1581
- "onUpdate:pagination": _cache[1] || (_cache[1] = function ($event) { return (vue.isRef(pagination) ? (pagination).value = $event : null); }),
1582
- selection: vue.unref(selectionMode),
1583
- selected: vue.unref(selectedData),
1584
- "onUpdate:selected": _cache[2] || (_cache[2] = function ($event) { return (vue.isRef(selectedData) ? (selectedData).value = $event : null); })
1585
- }), vue.createSlots({
1586
- "top-left": vue.withCtx(function () { return [
1587
- vue.createElementVNode("div", null, [
1588
- vue.renderSlot(_ctx.$slots, "top-left-content")
1589
- ])
1590
- ]; }),
1591
- "top-right": vue.withCtx(function () { return [
1592
- vue.createElementVNode("div", _hoisted_6, [
1593
- vue.createElementVNode("div", _hoisted_7, [
1594
- (vue.unref(showInputSearch))
1595
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QInput), {
1596
- key: 0,
1597
- dense: "",
1598
- debounce: "300",
1599
- modelValue: filter.value,
1600
- "onUpdate:modelValue": _cache[0] || (_cache[0] = function ($event) { return ((filter).value = $event); }),
1601
- placeholder: "Recherche",
1602
- outlined: "",
1603
- rounded: isMobile.value,
1604
- style: {"width":"180px"}
1605
- }, {
1606
- append: vue.withCtx(function () { return [
1607
- (filter.value)
1608
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1609
- key: 0,
1610
- dense: "",
1611
- flat: "",
1612
- round: "",
1613
- icon: "mdi-close",
1614
- onClick: onClearSearchHandler
1615
- }))
1616
- : (vue.openBlock(), vue.createBlock(vue.unref(quasar.QIcon), {
1617
- key: 1,
1618
- name: "search"
1619
- }))
1620
- ]; }),
1621
- _: 1 /* STABLE */
1622
- }, 8 /* PROPS */, ["modelValue", "rounded"]))
1623
- : vue.createCommentVNode("v-if", true),
1624
- (vue.unref(showBtnCreatePage))
1625
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1626
- key: 1,
1627
- type: "a",
1628
- to: { name: vue.unref(collectionCreateNamedRoute) },
1629
- label: vue.unref(customCreateButtonText) ? vue.unref(customCreateButtonText) : null,
1630
- icon: "add",
1631
- color: "primary",
1632
- style: {"margin-left":"1em"},
1633
- square: ""
1634
- }, {
1635
- default: vue.withCtx(function () { return [
1636
- vue.renderSlot(_ctx.$slots, "create-btn-tooltip")
1637
- ]; }),
1638
- _: 3 /* FORWARDED */
1639
- }, 8 /* PROPS */, ["to", "label"]))
1640
- : (vue.unref(showBtnCreate))
1641
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1642
- key: 2,
1643
- label: vue.unref(customCreateButtonText) ? vue.unref(customCreateButtonText) : null,
1644
- icon: "add",
1645
- color: "primary",
1646
- style: {"margin-left":"1em"},
1647
- onClick: vue.unref(onClickAdd),
1648
- square: ""
1649
- }, {
1650
- default: vue.withCtx(function () { return [
1651
- vue.renderSlot(_ctx.$slots, "create-btn-tooltip")
1652
- ]; }),
1653
- _: 3 /* FORWARDED */
1654
- }, 8 /* PROPS */, ["label", "onClick"]))
1655
- : vue.createCommentVNode("v-if", true),
1656
- vue.renderSlot(_ctx.$slots, "top-right-after-add")
1657
- ]),
1658
- vue.createElementVNode("div", _hoisted_8, [
1659
- vue.renderSlot(_ctx.$slots, "top-right-under-add")
1660
- ])
1661
- ])
1662
- ]; }),
1663
- "body-cell-actions-vlank": vue.withCtx(function (props) {
1664
- var obj, obj$1;
1665
-
1666
- return [
1667
- vue.createElementVNode("td", {
1668
- props: props,
1669
- class: vue.normalizeClass('action-buttons' + vue.unref(getAdditionalClassActionBtns)(props.row))
1670
- }, [
1671
- vue.renderSlot(_ctx.$slots, "row-action-before-controllers", {
1672
- key: 0,
1673
- data: props.row
1674
- })
1675
- ,
1676
- (vue.unref(showBtnEditModal) && __props.displayActionCallback(props.row, 'edit'))
1677
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1678
- key: 1,
1679
- onClick: function ($event) { return (vue.unref(onClickEdit)(props.row)); },
1680
- color: "primary",
1681
- icon: "edit",
1682
- flat: "",
1683
- round: isMobile.value
1684
- }, null, 8 /* PROPS */, ["onClick", "round"]))
1685
- : (vue.unref(showBtnEditPage) && __props.displayActionCallback(props.row, 'edit'))
1686
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1687
- key: 2,
1688
- type: "a",
1689
- to: { name: vue.unref(collectionEditNamedRoute), params: ( obj = {}, obj[vue.unref(route_parameter_name)] = props.row[vue.unref(route_parameter_name)], obj ) },
1690
- color: "primary",
1691
- icon: "edit",
1692
- flat: "",
1693
- round: isMobile.value
1694
- }, null, 8 /* PROPS */, ["to", "round"]))
1695
- : vue.createCommentVNode("v-if", true),
1696
- (!__props.editablePage && vue.unref(showBtnEditPage) && __props.displayActionCallback(props.row, 'show'))
1650
+ vue.createVNode(vue.unref(quasar.QTable), vue.mergeProps({
1651
+ flat: "",
1652
+ rows: vue.unref(rows)
1653
+ }, vue.unref(table), {
1654
+ filter: filter.value,
1655
+ onRequest: vue.unref(asyncRequest),
1656
+ ref_key: "ccrudTable",
1657
+ ref: ccrudTable,
1658
+ pagination: vue.unref(pagination),
1659
+ "onUpdate:pagination": _cache[1] || (_cache[1] = function ($event) { return (vue.isRef(pagination) ? (pagination).value = $event : null); }),
1660
+ selection: vue.unref(selectionMode),
1661
+ selected: vue.unref(selectedData),
1662
+ "onUpdate:selected": _cache[2] || (_cache[2] = function ($event) { return (vue.isRef(selectedData) ? (selectedData).value = $event : null); })
1663
+ }), vue.createSlots({
1664
+ "top-left": vue.withCtx(function () { return [
1665
+ vue.createElementVNode("div", null, [
1666
+ vue.renderSlot(_ctx.$slots, "top-left-content")
1667
+ ])
1668
+ ]; }),
1669
+ "top-right": vue.withCtx(function () { return [
1670
+ vue.createElementVNode("div", _hoisted_6, [
1671
+ vue.createElementVNode("div", _hoisted_7, [
1672
+ (vue.unref(showInputSearch))
1673
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QInput), {
1674
+ key: 0,
1675
+ dense: "",
1676
+ debounce: "300",
1677
+ modelValue: filter.value,
1678
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = function ($event) { return ((filter).value = $event); }),
1679
+ placeholder: "Recherche",
1680
+ outlined: "",
1681
+ rounded: isMobile.value,
1682
+ style: {"width":"180px"}
1683
+ }, {
1684
+ append: vue.withCtx(function () { return [
1685
+ (filter.value)
1686
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1687
+ key: 0,
1688
+ dense: "",
1689
+ flat: "",
1690
+ round: "",
1691
+ icon: "mdi-close",
1692
+ onClick: onClearSearchHandler
1693
+ }))
1694
+ : (vue.openBlock(), vue.createBlock(vue.unref(quasar.QIcon), {
1695
+ key: 1,
1696
+ name: "search"
1697
+ }))
1698
+ ]; }),
1699
+ _: 1 /* STABLE */
1700
+ }, 8 /* PROPS */, ["modelValue", "rounded"]))
1701
+ : vue.createCommentVNode("v-if", true),
1702
+ (vue.unref(showBtnExport))
1703
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1704
+ key: 1,
1705
+ onClick: vue.unref(doExport),
1706
+ color: "primary",
1707
+ icon: __props.exportOptions.icon ? __props.exportOptions.icon : 'mdi-file-download',
1708
+ flat: __props.exportOptions.flat !== undefined ? __props.exportOptions.flat : true,
1709
+ label: __props.exportOptions.label ? __props.exportOptions.label : null,
1710
+ style: {"margin-left":"1em"},
1711
+ square: ""
1712
+ }, {
1713
+ default: vue.withCtx(function () { return [
1714
+ vue.renderSlot(_ctx.$slots, "export-btn-tooltip")
1715
+ ]; }),
1716
+ _: 3 /* FORWARDED */
1717
+ }, 8 /* PROPS */, ["onClick", "icon", "flat", "label"]))
1718
+ : vue.createCommentVNode("v-if", true),
1719
+ (vue.unref(showBtnCreatePage))
1720
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1721
+ key: 2,
1722
+ type: "a",
1723
+ to: { name: vue.unref(collectionCreateNamedRoute) },
1724
+ label: vue.unref(customCreateButtonText) ? vue.unref(customCreateButtonText) : null,
1725
+ icon: "add",
1726
+ color: "primary",
1727
+ style: {"margin-left":"1em"},
1728
+ square: ""
1729
+ }, {
1730
+ default: vue.withCtx(function () { return [
1731
+ vue.renderSlot(_ctx.$slots, "create-btn-tooltip")
1732
+ ]; }),
1733
+ _: 3 /* FORWARDED */
1734
+ }, 8 /* PROPS */, ["to", "label"]))
1735
+ : (vue.unref(showBtnCreate))
1697
1736
  ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1698
1737
  key: 3,
1699
- type: "a",
1700
- to: { name: vue.unref(collectionEditNamedRoute), params: ( obj$1 = {}, obj$1[vue.unref(route_parameter_name)] = props.row[vue.unref(route_parameter_name)], obj$1 ) },
1738
+ label: vue.unref(customCreateButtonText) ? vue.unref(customCreateButtonText) : null,
1739
+ icon: "add",
1701
1740
  color: "primary",
1702
- icon: "mdi-magnify-plus-outline",
1703
- flat: ""
1704
- }, null, 8 /* PROPS */, ["to"]))
1705
- : vue.createCommentVNode("v-if", true),
1706
- (vue.unref(showBtnDelete) && __props.displayActionCallback(props.row, 'delete'))
1707
- ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1708
- key: 4,
1709
- onClick: function ($event) { return (vue.unref(onClickDelete)(props.row)); },
1710
- color: "negative",
1711
- icon: "delete",
1712
- flat: "",
1713
- round: isMobile.value
1714
- }, null, 8 /* PROPS */, ["onClick", "round"]))
1741
+ style: {"margin-left":"1em"},
1742
+ onClick: vue.unref(onClickAdd),
1743
+ square: ""
1744
+ }, {
1745
+ default: vue.withCtx(function () { return [
1746
+ vue.renderSlot(_ctx.$slots, "create-btn-tooltip")
1747
+ ]; }),
1748
+ _: 3 /* FORWARDED */
1749
+ }, 8 /* PROPS */, ["label", "onClick"]))
1715
1750
  : vue.createCommentVNode("v-if", true),
1716
- vue.renderSlot(_ctx.$slots, "row-action-after-controllers", {
1751
+ vue.renderSlot(_ctx.$slots, "top-right-after-add")
1752
+ ]),
1753
+ vue.createElementVNode("div", _hoisted_8, [
1754
+ vue.renderSlot(_ctx.$slots, "top-right-under-add")
1755
+ ])
1756
+ ])
1757
+ ]; }),
1758
+ "body-cell-actions-vlank": vue.withCtx(function (props) {
1759
+ var obj, obj$1;
1760
+
1761
+ return [
1762
+ vue.createElementVNode("td", {
1763
+ props: props,
1764
+ class: vue.normalizeClass('action-buttons' + vue.unref(getAdditionalClassActionBtns)(props.row))
1765
+ }, [
1766
+ vue.renderSlot(_ctx.$slots, "row-action-before-controllers", {
1767
+ key: 0,
1717
1768
  data: props.row
1718
1769
  })
1719
- ], 10 /* CLASS, PROPS */, _hoisted_9)
1720
- ];
1770
+ ,
1771
+ (vue.unref(showBtnEditModal) && __props.displayActionCallback(props.row, 'edit'))
1772
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1773
+ key: 1,
1774
+ onClick: function ($event) { return (vue.unref(onClickEdit)(props.row)); },
1775
+ color: "primary",
1776
+ icon: "edit",
1777
+ flat: "",
1778
+ round: isMobile.value
1779
+ }, null, 8 /* PROPS */, ["onClick", "round"]))
1780
+ : (vue.unref(showBtnEditPage) && __props.displayActionCallback(props.row, 'edit'))
1781
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1782
+ key: 2,
1783
+ type: "a",
1784
+ to: { name: vue.unref(collectionEditNamedRoute), params: ( obj = {}, obj[vue.unref(route_parameter_name)] = props.row[vue.unref(route_parameter_name)], obj ) },
1785
+ color: "primary",
1786
+ icon: "edit",
1787
+ flat: "",
1788
+ round: isMobile.value
1789
+ }, null, 8 /* PROPS */, ["to", "round"]))
1790
+ : vue.createCommentVNode("v-if", true),
1791
+ (!__props.editablePage && vue.unref(showBtnEditPage) && __props.displayActionCallback(props.row, 'show'))
1792
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1793
+ key: 3,
1794
+ type: "a",
1795
+ to: { name: vue.unref(collectionEditNamedRoute), params: ( obj$1 = {}, obj$1[vue.unref(route_parameter_name)] = props.row[vue.unref(route_parameter_name)], obj$1 ) },
1796
+ color: "primary",
1797
+ icon: "mdi-magnify-plus-outline",
1798
+ flat: ""
1799
+ }, null, 8 /* PROPS */, ["to"]))
1800
+ : vue.createCommentVNode("v-if", true),
1801
+ (vue.unref(showBtnDelete) && __props.displayActionCallback(props.row, 'delete'))
1802
+ ? (vue.openBlock(), vue.createBlock(vue.unref(quasar.QBtn), {
1803
+ key: 4,
1804
+ onClick: function ($event) { return (vue.unref(onClickDelete)(props.row)); },
1805
+ color: "negative",
1806
+ icon: "delete",
1807
+ flat: "",
1808
+ round: isMobile.value
1809
+ }, null, 8 /* PROPS */, ["onClick", "round"]))
1810
+ : vue.createCommentVNode("v-if", true),
1811
+ vue.renderSlot(_ctx.$slots, "row-action-after-controllers", {
1812
+ data: props.row
1813
+ })
1814
+ ], 10 /* CLASS, PROPS */, _hoisted_9)
1815
+ ];
1721
1816
  }),
1722
- _: 2 /* DYNAMIC */
1723
- }, [
1724
- (isMobile.value)
1725
- ? {
1726
- name: "header",
1727
- fn: vue.withCtx(function (props) { return []; }),
1728
- key: "0"
1729
- }
1730
- : undefined,
1731
- (isMobile.value)
1732
- ? {
1733
- name: "body",
1734
- fn: vue.withCtx(function (props) { return [
1735
- vue.createVNode(vue.unref(quasar.QSlideItem), {
1736
- ref_key: "mobileSlideItem",
1737
- ref: mobileSlideItem,
1738
- onLeft: function (element) { return onSlideLeft(element, props.row); },
1739
- onRight: function (element) { return onSlideRight(element, props.row); },
1740
- onSlide: onSlide,
1741
- reset: "",
1742
- "right-color": "negative",
1743
- "left-color": "accent"
1744
- }, vue.createSlots({
1817
+ _: 2 /* DYNAMIC */
1818
+ }, [
1819
+ (isMobile.value)
1820
+ ? {
1821
+ name: "header",
1822
+ fn: vue.withCtx(function (props) { return []; }),
1823
+ key: "0"
1824
+ }
1825
+ : undefined,
1826
+ (isMobile.value)
1827
+ ? {
1828
+ name: "body",
1829
+ fn: vue.withCtx(function (props) { return [
1830
+ vue.createVNode(vue.unref(quasar.QSlideItem), {
1831
+ ref_key: "mobileSlideItem",
1832
+ ref: mobileSlideItem,
1833
+ onLeft: function (element) { return onSlideLeft(element, props.row); },
1834
+ onRight: function (element) { return onSlideRight(element, props.row); },
1835
+ onSlide: onSlide,
1836
+ reset: "",
1837
+ "right-color": "negative",
1838
+ "left-color": "accent"
1839
+ }, vue.createSlots({
1840
+ default: vue.withCtx(function () { return [
1841
+ vue.createVNode(vue.unref(quasar.QItem), {
1842
+ style: {"align-items":"center"},
1843
+ class: vue.normalizeClass('mobile-item' + vue.unref(getAdditionalClassActionBtns)(props.row))
1844
+ }, {
1745
1845
  default: vue.withCtx(function () { return [
1746
- vue.createVNode(vue.unref(quasar.QItem), {
1747
- style: {"align-items":"center"},
1748
- class: vue.normalizeClass('mobile-item' + vue.unref(getAdditionalClassActionBtns)(props.row))
1846
+ vue.createCommentVNode(" On affiche la première colonne seulement et on garde celle des actions "),
1847
+ vue.createVNode(vue.unref(quasar.QItemSection), {
1848
+ class: "mobile-item-content",
1849
+ onClick: function ($event) { return (vue.unref(showBtnEdit) ? onClickRow(props.row) : ''); }
1749
1850
  }, {
1750
1851
  default: vue.withCtx(function () { return [
1751
- vue.createCommentVNode(" On affiche la première colonne seulement et on garde celle des actions "),
1752
- vue.createVNode(vue.unref(quasar.QItemSection), {
1753
- class: "mobile-item-content",
1754
- onClick: function ($event) { return (vue.unref(showBtnEdit) ? onClickRow(props.row) : ''); }
1755
- }, {
1756
- default: vue.withCtx(function () { return [
1757
- (vue.unref($slots)['body-cell-mobile'])
1758
- ? vue.renderSlot(_ctx.$slots, "body-cell-mobile", {
1759
- key: 0,
1760
- data: props.row,
1761
- class: "body-cell-mobile"
1762
- })
1763
- : (mobileColumn.value)
1764
- ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_2$2, vue.toDisplayString(props.cols.filter(function (col) { return col.name === mobileColumn.value.name; })[0].value), 1 /* TEXT */))
1765
- : (vue.openBlock(), vue.createElementBlock("span", _hoisted_3$2, vue.toDisplayString(props.cols[0].value), 1 /* TEXT */))
1766
- ]; }),
1767
- _: 2 /* DYNAMIC */
1768
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"]),
1769
- vue.createVNode(vue.unref(quasar.QItemSection), {
1770
- style: {"display":"flex","flex-direction":"row","align-items":"center"},
1771
- side: ""
1772
- }, {
1773
- default: vue.withCtx(function () { return [
1774
- vue.renderSlot(_ctx.$slots, "row-action-before-controllers", {
1775
- key: 0,
1776
- data: props.row
1777
- })
1778
-
1779
- ]; }),
1780
- _: 2 /* DYNAMIC */
1781
- }, 1024 /* DYNAMIC_SLOTS */)
1852
+ (vue.unref($slots)['body-cell-mobile'])
1853
+ ? vue.renderSlot(_ctx.$slots, "body-cell-mobile", {
1854
+ key: 0,
1855
+ data: props.row,
1856
+ class: "body-cell-mobile"
1857
+ })
1858
+ : (mobileColumn.value)
1859
+ ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_2$2, vue.toDisplayString(props.cols.filter(function (col) { return col.name === mobileColumn.value.name; })[0].value), 1 /* TEXT */))
1860
+ : (vue.openBlock(), vue.createElementBlock("span", _hoisted_3$2, vue.toDisplayString(props.cols[0].value), 1 /* TEXT */))
1782
1861
  ]; }),
1783
1862
  _: 2 /* DYNAMIC */
1784
- }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class"])
1863
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"]),
1864
+ vue.createVNode(vue.unref(quasar.QItemSection), {
1865
+ style: {"display":"flex","flex-direction":"row","align-items":"center"},
1866
+ side: ""
1867
+ }, {
1868
+ default: vue.withCtx(function () { return [
1869
+ vue.renderSlot(_ctx.$slots, "row-action-before-controllers", {
1870
+ key: 0,
1871
+ data: props.row
1872
+ })
1873
+
1874
+ ]; }),
1875
+ _: 2 /* DYNAMIC */
1876
+ }, 1024 /* DYNAMIC_SLOTS */)
1785
1877
  ]; }),
1786
1878
  _: 2 /* DYNAMIC */
1787
- }, [
1788
- (__props.showSlideLeft)
1789
- ? {
1790
- name: "left",
1791
- fn: vue.withCtx(function () { return [
1792
- vue.renderSlot(_ctx.$slots, "content-slider-left", {
1793
- data: props.row
1794
- }, function () { return [
1795
- vue.createVNode(vue.unref(quasar.QIcon), { name: "mdi-pencil" })
1796
- ]; })
1797
- ]; }),
1798
- key: "0"
1799
- }
1800
- : undefined,
1801
- (vue.unref(showBtnDelete))
1802
- ? {
1803
- name: "right",
1804
- fn: vue.withCtx(function () { return [
1805
- vue.createVNode(vue.unref(quasar.QIcon), { name: "mdi-delete" })
1806
- ]; }),
1807
- key: "1"
1808
- }
1809
- : undefined
1810
- ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["onLeft", "onRight"])
1879
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["class"])
1811
1880
  ]; }),
1812
- key: "1"
1813
- }
1814
- : undefined,
1815
- vue.renderList(vue.unref(customFields), function (options) {
1816
- return {
1817
- name: options.slotName,
1818
- fn: vue.withCtx(function (props) { return [
1819
- (options.type == 'boolean')
1820
- ? (vue.openBlock(), vue.createElementBlock("td", {
1821
- props: props,
1822
- key: options.slotName,
1823
- class: vue.normalizeClass((vue.unref(isTdClickable)(options) ? 'cursor-pointer' : '') + vue.unref(getAdditionalClassActionBtns)(props.row)),
1824
- onClick: function ($event) { return (vue.unref(isTdClickable)(options) ? options.to(props.row) : null); }
1825
- }, [
1826
- (props.row[options.field])
1827
- ? vue.renderSlot(_ctx.$slots, getScopedSlotName('boolean-check', options.field), {
1828
- key: 0,
1829
- data: props.row
1830
- }, function () { return [
1831
- vue.createVNode(vue.unref(quasar.QIcon), {
1832
- color: "positive",
1833
- size: "2rem",
1834
- name: "check"
1835
- })
1836
- ]; })
1837
- : vue.renderSlot(_ctx.$slots, getScopedSlotName('boolean-uncheck', options.field), {
1838
- key: 1,
1839
- data: props.row
1840
- })
1841
- ], 10 /* CLASS, PROPS */, _hoisted_4$2))
1842
- : (vue.openBlock(), vue.createElementBlock("td", {
1843
- props: props,
1844
- key: options.slotName + '-else',
1845
- class: vue.normalizeClass('cursor-pointer' + vue.unref(getAdditionalClassActionBtns)(props.row)),
1846
- onClick: function ($event) { return (options.to(props.row)); }
1847
- }, vue.toDisplayString(options.format
1881
+ _: 2 /* DYNAMIC */
1882
+ }, [
1883
+ (__props.showSlideLeft)
1884
+ ? {
1885
+ name: "left",
1886
+ fn: vue.withCtx(function () { return [
1887
+ vue.renderSlot(_ctx.$slots, "content-slider-left", {
1888
+ data: props.row
1889
+ }, function () { return [
1890
+ vue.createVNode(vue.unref(quasar.QIcon), { name: "mdi-pencil" })
1891
+ ]; })
1892
+ ]; }),
1893
+ key: "0"
1894
+ }
1895
+ : undefined,
1896
+ (vue.unref(showBtnDelete))
1897
+ ? {
1898
+ name: "right",
1899
+ fn: vue.withCtx(function () { return [
1900
+ vue.createVNode(vue.unref(quasar.QIcon), { name: "mdi-delete" })
1901
+ ]; }),
1902
+ key: "1"
1903
+ }
1904
+ : undefined
1905
+ ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["onLeft", "onRight"])
1906
+ ]; }),
1907
+ key: "1"
1908
+ }
1909
+ : undefined,
1910
+ vue.renderList(vue.unref(customFields), function (options) {
1911
+ return {
1912
+ name: options.slotName,
1913
+ fn: vue.withCtx(function (props) { return [
1914
+ (options.type == 'boolean')
1915
+ ? (vue.openBlock(), vue.createElementBlock("td", {
1916
+ props: props,
1917
+ key: options.slotName,
1918
+ class: vue.normalizeClass((vue.unref(isTdClickable)(options) ? 'cursor-pointer' : '') + vue.unref(getAdditionalClassActionBtns)(props.row)),
1919
+ onClick: function ($event) { return (vue.unref(isTdClickable)(options) ? options.to(props.row) : null); }
1920
+ }, [
1921
+ (props.row[options.field])
1922
+ ? vue.renderSlot(_ctx.$slots, getScopedSlotName('boolean-check', options.field), {
1923
+ key: 0,
1924
+ data: props.row
1925
+ }, function () { return [
1926
+ vue.createVNode(vue.unref(quasar.QIcon), {
1927
+ color: "positive",
1928
+ size: "2rem",
1929
+ name: "check"
1930
+ })
1931
+ ]; })
1932
+ : vue.renderSlot(_ctx.$slots, getScopedSlotName('boolean-uncheck', options.field), {
1933
+ key: 1,
1934
+ data: props.row
1935
+ })
1936
+ ], 10 /* CLASS, PROPS */, _hoisted_4$2))
1937
+ : (vue.openBlock(), vue.createElementBlock("td", {
1938
+ props: props,
1939
+ key: options.slotName + '-else',
1940
+ class: vue.normalizeClass('cursor-pointer' + vue.unref(getAdditionalClassActionBtns)(props.row)),
1941
+ onClick: function ($event) { return (options.to(props.row)); }
1942
+ }, vue.toDisplayString(options.format
1848
1943
  ? options.format(props.row)
1849
1944
  : props.row[options.field]), 11 /* TEXT, CLASS, PROPS */, _hoisted_5$1))
1850
- ]; })
1851
- }
1852
- }),
1853
- vue.renderList(vue.unref($slots), function (_, slotName) {
1854
- return {
1855
- name: slotName,
1856
- fn: vue.withCtx(function (props) { return [
1857
- vue.renderSlot(_ctx.$slots, slotName, vue.normalizeProps(vue.guardReactiveProps(props)))
1858
- ]; })
1859
- }
1860
- }),
1861
- vue.renderList(vue.unref(getEditablesTd), function (config, index) {
1862
- return {
1863
- name: config.slotName,
1864
- fn: vue.withCtx(function (slotProps) { return [
1865
- (vue.unref(editOnTable))
1866
- ? (vue.openBlock(), vue.createBlock(script$3, {
1867
- ref: function (el) { popupCells.value[getRowIndex(slotProps.row) + '_' + index] = el; },
1868
- key: config.slotName,
1869
- rowIndex: getRowIndex(slotProps.row),
1870
- cellIndex: index,
1871
- data: slotProps.row,
1872
- props: vue.unref(props),
1873
- colOptions: config.options,
1874
- onUpdate: vue.unref(onUpdateTd),
1875
- onOnEditCellHandler: onEditCellHandler,
1876
- onOnClickTabHandler: onClickTabHandler
1877
- }, vue.createSlots({ _: 2 /* DYNAMIC */ }, [
1878
- vue.renderList(vue.unref($slots), function (_, slot) {
1879
- return {
1880
- name: slot,
1881
- fn: vue.withCtx(function (scope) { return [
1882
- vue.renderSlot(_ctx.$slots, slot, vue.normalizeProps(vue.guardReactiveProps(scope)))
1883
- ]; })
1884
- }
1885
- })
1886
- ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["rowIndex", "cellIndex", "data", "props", "colOptions", "onUpdate"]))
1887
- : vue.createCommentVNode("v-if", true)
1888
- ]; })
1889
- }
1890
- })
1891
- ]), 1040 /* FULL_PROPS, DYNAMIC_SLOTS */, ["rows", "filter", "onRequest", "pagination", "selection", "selected"]))
1892
- : vue.createCommentVNode("v-if", true),
1945
+ ]; })
1946
+ }
1947
+ }),
1948
+ vue.renderList(vue.unref($slots), function (_, slotName) {
1949
+ return {
1950
+ name: slotName,
1951
+ fn: vue.withCtx(function (props) { return [
1952
+ vue.renderSlot(_ctx.$slots, slotName, vue.normalizeProps(vue.guardReactiveProps(props)))
1953
+ ]; })
1954
+ }
1955
+ }),
1956
+ vue.renderList(vue.unref(getEditablesTd), function (config, index) {
1957
+ return {
1958
+ name: config.slotName,
1959
+ fn: vue.withCtx(function (slotProps) { return [
1960
+ (vue.unref(editOnTable))
1961
+ ? (vue.openBlock(), vue.createBlock(script$3, {
1962
+ ref: function (el) { popupCells.value[getRowIndex(slotProps.row) + '_' + index] = el; },
1963
+ key: config.slotName,
1964
+ rowIndex: getRowIndex(slotProps.row),
1965
+ cellIndex: index,
1966
+ data: slotProps.row,
1967
+ props: vue.unref(props),
1968
+ colOptions: config.options,
1969
+ onUpdate: vue.unref(onUpdateTd),
1970
+ onOnEditCellHandler: onEditCellHandler,
1971
+ onOnClickTabHandler: onClickTabHandler
1972
+ }, vue.createSlots({ _: 2 /* DYNAMIC */ }, [
1973
+ vue.renderList(vue.unref($slots), function (_, slot) {
1974
+ return {
1975
+ name: slot,
1976
+ fn: vue.withCtx(function (scope) { return [
1977
+ vue.renderSlot(_ctx.$slots, slot, vue.normalizeProps(vue.guardReactiveProps(scope)))
1978
+ ]; })
1979
+ }
1980
+ })
1981
+ ]), 1032 /* PROPS, DYNAMIC_SLOTS */, ["rowIndex", "cellIndex", "data", "props", "colOptions", "onUpdate"]))
1982
+ : vue.createCommentVNode("v-if", true)
1983
+ ]; })
1984
+ }
1985
+ })
1986
+ ]), 1040 /* FULL_PROPS, DYNAMIC_SLOTS */, ["rows", "filter", "onRequest", "pagination", "selection", "selected"]),
1893
1987
  vue.createCommentVNode(" Modal de Confirmation Suppression "),
1894
1988
  vue.createVNode(script$5, {
1895
1989
  localDetail: localDetail.value,
@@ -2399,7 +2493,7 @@
2399
2493
  script.__scopeId = "data-v-29e3989a";
2400
2494
  script.__file = "src/components/VlankCreatePage.vue";
2401
2495
 
2402
- var version = '3.7.52';
2496
+ var version = '3.7.54';
2403
2497
 
2404
2498
  function install (app) {
2405
2499
  app.component(script$2.name, script$2);