quasar-factory-lib 0.0.51 → 0.0.52

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/package.json CHANGED
@@ -97,6 +97,6 @@
97
97
  "release": "standard-version"
98
98
  },
99
99
  "type": "module",
100
- "version": "0.0.51",
100
+ "version": "0.0.52",
101
101
  "author": ""
102
102
  }
@@ -31,7 +31,7 @@
31
31
  <q-item-label class="itemsFontSize ellipsis text-color-lightGray">
32
32
  {{
33
33
  col.label
34
- }}xxxxx
34
+ }}
35
35
  </q-item-label>
36
36
  </q-item-section>
37
37
 
@@ -21,6 +21,19 @@ const utils = {
21
21
  }
22
22
  const n = Number(footerHeightHeight) + Number(headerHeight)
23
23
  return `height:${window.innerHeight - n}px`
24
+ },
25
+ setModalTableHeight (elementId: string):string {
26
+ const topCard = document.getElementById(elementId)
27
+ let topCardHeight = ''
28
+ if (topCard) {
29
+ const computedHeight = window.getComputedStyle(topCard).height
30
+
31
+ if (computedHeight !== 'auto') {
32
+ topCardHeight = computedHeight.replace('px', '')
33
+ }
34
+ }
35
+ const n = Number(topCardHeight)
36
+ return `height:${window.innerHeight - n}px`
24
37
  }
25
38
  }
26
39
 
@@ -7,8 +7,8 @@
7
7
  <div
8
8
  class="full-width"
9
9
  >
10
- <!-- {{ store.prepared }}
11
- <q-btn @click="store.prepared = !store.prepared">Click</q-btn> -->
10
+ {{ store.prepared }}
11
+ <q-btn @click="store.prepared = !store.prepared">Click</q-btn>
12
12
  <Table
13
13
  ref="table"
14
14
  :rows="rows"
@@ -20,6 +20,9 @@
20
20
  :show-skeleton="false"
21
21
  :selection-type="'multiple'"
22
22
  :getCellClass="getCellClass"
23
+ :filterComputedOptions="{ preparedQuantity: store.prepared}"
24
+ :additional-sort-conditions="additionalSortConditions"
25
+ :additional-filter-conditions="additionalFilterConditions"
23
26
  @on-select-visible-columns="saveSelectedColumns"
24
27
  @on-update-basic-checkbox-value="onUpdateBasicCheckboxValue"
25
28
  @on-update-customized-checkbox-value="onUpdateCustomizedCheckboxValue"
@@ -378,16 +381,17 @@ export default {
378
381
  },
379
382
  additionalFilterConditions (rows_: object[] | [], filteredRowsParam_: object[] | []) {
380
383
  console.log('additional filter conditions')
381
- filteredRowsParam_ = []
384
+ const rowsToReturn = []
385
+ const filteredOrAllRows = filteredRowsParam_.length > 0 ? filteredRowsParam_: rows_
382
386
  if (this.store.prepared) {
383
- for (let i = 0; i < rows_.length; i++) {
384
- if (rows_[i].sodium >= 300) {
385
- filteredRowsParam_.push(rows_[i])
387
+ for (let i = 0; i < filteredOrAllRows.length; i++) {
388
+ if (filteredOrAllRows[i].sodium >= 300) {
389
+ rowsToReturn.push(filteredOrAllRows[i])
386
390
  }
387
391
  }
388
- return filteredRowsParam_
392
+ return rowsToReturn
389
393
  } else {
390
- return rows_
394
+ return filteredRowsParam_
391
395
  }
392
396
  },
393
397
  additionalSortConditions (filteredRowsData: object[] | [], rows: object[] | []) {