Skip to content

Commit 38a21d0

Browse files
committed
recovery
1 parent c86224d commit 38a21d0

File tree

5 files changed

+48
-26
lines changed

5 files changed

+48
-26
lines changed

dist/vue-pivottable.common.js

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -228832,6 +228832,9 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
228832228832
}
228833228833
},
228834228834
computed: {
228835+
appliedFilter: function appliedFilter() {
228836+
return this.propsData.valueFilter;
228837+
},
228835228838
rendererItems: function rendererItems() {
228836228839
return this.renderers || Object.assign({}, src_TableRenderer, PlotlyRenderer);
228837228840
},
@@ -228918,6 +228921,13 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
228918228921
this.propsData.rows = value;
228919228922
}
228920228923
},
228924+
appliedFilter: {
228925+
handler: function handler(value, oldValue) {
228926+
this.$emit('update:valueFitler', value);
228927+
},
228928+
immediate: true,
228929+
deep: true
228930+
},
228921228931
data: {
228922228932
handler: function handler(value) {
228923228933
this.init();
@@ -228989,12 +228999,10 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
228989228999
this.propsData.aggregatorName = this.aggregatorName;
228990229000
this.propsData.attributes = this.attributes.length > 0 ? this.attributes : Object.keys(this.attrValues);
228991229001
this.unusedOrder = this.unusedAttrs;
228992-
Object.keys(this.attrValues).map(this.assignValue);
228993-
Object.keys(this.openStatus).map(this.assignValue);
228994-
Object.keys(this.valueFilter).forEach(function (key) {
229002+
Object.keys(this.attrValues).forEach(function (key) {
228995229003
return _this4.updateValueFilter({
228996229004
attribute: key,
228997-
valueFilter: _this4.valueFilter[key]
229005+
valueFilter: _this4.valueFilter && _this4.valueFilter[key] && Object.keys(_this4.valueFilter[key].length ? _this4.valueFilter[key] : {})
228998229006
});
228999229007
});
229000229008
},
@@ -229299,11 +229307,11 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
229299229307
}
229300229308
}), h('col')]), h('tbody', [h('tr', [rendererCell, unusedAttrsCell]), h('tr', [aggregatorCell, colAttrsCell]), h('tr', [rowAttrsCell, outputSlot ? h('td', {
229301229309
staticClass: 'pvtOutput'
229302-
}, outputSlot) : undefined, outputScopedSlot && limitOver ? h('td', {
229310+
}, outputSlot) : limitOver ? h('td', {
229303229311
staticClass: 'pvtOutput'
229304229312
}, outputScopedSlot({
229305229313
pivotData: new utils_PivotData(props)
229306-
})) : undefined, !outputSlot && !limitOver && outputCell])])]);
229314+
})) : outputCell])])]);
229307229315
},
229308229316
renderError: function renderError(h, error) {
229309229317
return this.uiRenderError(h);

dist/vue-pivottable.umd.js

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -228841,6 +228841,9 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
228841228841
}
228842228842
},
228843228843
computed: {
228844+
appliedFilter: function appliedFilter() {
228845+
return this.propsData.valueFilter;
228846+
},
228844228847
rendererItems: function rendererItems() {
228845228848
return this.renderers || Object.assign({}, src_TableRenderer, PlotlyRenderer);
228846228849
},
@@ -228927,6 +228930,13 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
228927228930
this.propsData.rows = value;
228928228931
}
228929228932
},
228933+
appliedFilter: {
228934+
handler: function handler(value, oldValue) {
228935+
this.$emit('update:valueFitler', value);
228936+
},
228937+
immediate: true,
228938+
deep: true
228939+
},
228930228940
data: {
228931228941
handler: function handler(value) {
228932228942
this.init();
@@ -228998,12 +229008,10 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
228998229008
this.propsData.aggregatorName = this.aggregatorName;
228999229009
this.propsData.attributes = this.attributes.length > 0 ? this.attributes : Object.keys(this.attrValues);
229000229010
this.unusedOrder = this.unusedAttrs;
229001-
Object.keys(this.attrValues).map(this.assignValue);
229002-
Object.keys(this.openStatus).map(this.assignValue);
229003-
Object.keys(this.valueFilter).forEach(function (key) {
229011+
Object.keys(this.attrValues).forEach(function (key) {
229004229012
return _this4.updateValueFilter({
229005229013
attribute: key,
229006-
valueFilter: _this4.valueFilter[key]
229014+
valueFilter: _this4.valueFilter && _this4.valueFilter[key] && Object.keys(_this4.valueFilter[key].length ? _this4.valueFilter[key] : {})
229007229015
});
229008229016
});
229009229017
},
@@ -229308,11 +229316,11 @@ function PivottableUi_objectSpread(target) { for (var i = 1; i < arguments.lengt
229308229316
}
229309229317
}), h('col')]), h('tbody', [h('tr', [rendererCell, unusedAttrsCell]), h('tr', [aggregatorCell, colAttrsCell]), h('tr', [rowAttrsCell, outputSlot ? h('td', {
229310229318
staticClass: 'pvtOutput'
229311-
}, outputSlot) : undefined, outputScopedSlot && limitOver ? h('td', {
229319+
}, outputSlot) : limitOver ? h('td', {
229312229320
staticClass: 'pvtOutput'
229313229321
}, outputScopedSlot({
229314229322
pivotData: new utils_PivotData(props)
229315-
})) : undefined, !outputSlot && !limitOver && outputCell])])]);
229323+
})) : outputCell])])]);
229316229324
},
229317229325
renderError: function renderError(h, error) {
229318229326
return this.uiRenderError(h);

dist/vue-pivottable.umd.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-pivottable",
3-
"version": "0.3.84",
3+
"version": "0.3.85",
44
"main": "src/index.js",
55
"files": [
66
"dist",

src/PivottableUi.js

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,9 @@ export default {
6666
}
6767
},
6868
computed: {
69+
appliedFilter () {
70+
return this.propsData.valueFilter
71+
},
6972
rendererItems () {
7073
return (this.renderers) || Object.assign({}, TableRenderer, PlotlyRenderer)
7174
},
@@ -79,24 +82,24 @@ export default {
7982
return this.propsData.rows.filter(
8083
e =>
8184
!this.hiddenAttributes.includes(e) &&
82-
!this.hiddenFromDragDrop.includes(e)
85+
!this.hiddenFromDragDrop.includes(e)
8386
)
8487
},
8588
colAttrs () {
8689
return this.propsData.cols.filter(
8790
e =>
8891
!this.hiddenAttributes.includes(e) &&
89-
!this.hiddenFromDragDrop.includes(e)
92+
!this.hiddenFromDragDrop.includes(e)
9093
)
9194
},
9295
unusedAttrs () {
9396
return this.propsData.attributes
9497
.filter(
9598
e =>
9699
!this.propsData.rows.includes(e) &&
97-
!this.propsData.cols.includes(e) &&
98-
!this.hiddenAttributes.includes(e) &&
99-
!this.hiddenFromDragDrop.includes(e)
100+
!this.propsData.cols.includes(e) &&
101+
!this.hiddenAttributes.includes(e) &&
102+
!this.hiddenFromDragDrop.includes(e)
100103
)
101104
.sort(sortAs(this.unusedOrder))
102105
}
@@ -156,6 +159,13 @@ export default {
156159
this.propsData.rows = value
157160
}
158161
},
162+
appliedFilter: {
163+
handler (value, oldValue) {
164+
this.$emit('update:valueFitler', value)
165+
},
166+
immediate: true,
167+
deep: true
168+
},
159169
data: {
160170
handler (value) {
161171
this.init()
@@ -227,9 +237,7 @@ export default {
227237
this.propsData.aggregatorName = this.aggregatorName
228238
this.propsData.attributes = this.attributes.length > 0 ? this.attributes : Object.keys(this.attrValues)
229239
this.unusedOrder = this.unusedAttrs
230-
Object.keys(this.attrValues).map(this.assignValue)
231-
Object.keys(this.openStatus).map(this.assignValue)
232-
Object.keys(this.valueFilter).forEach(key => this.updateValueFilter({ attribute: key, valueFilter: this.valueFilter[key] }))
240+
Object.keys(this.attrValues).forEach(key => this.updateValueFilter({ attribute: key, valueFilter: this.valueFilter && this.valueFilter[key] && Object.keys(this.valueFilter[key].length ? this.valueFilter[key] : {}) }))
233241
},
234242
assignValue (field) {
235243
this.$set(this.propsData.valueFilter, field, {})
@@ -409,7 +417,7 @@ export default {
409417
props: {
410418
values: Object.keys(this.attrValues).filter(e =>
411419
!this.hiddenAttributes.includes(e) &&
412-
!this.hiddenFromAggregators.includes(e))
420+
!this.hiddenFromAggregators.includes(e))
413421
},
414422
domProps: {
415423
value: vals[i]
@@ -555,9 +563,7 @@ export default {
555563
h('tr',
556564
[
557565
rowAttrsCell,
558-
outputSlot ? h('td', { staticClass: 'pvtOutput' }, outputSlot) : undefined,
559-
outputScopedSlot && limitOver ? h('td', { staticClass: 'pvtOutput' }, outputScopedSlot({ pivotData: new PivotData(props) })) : undefined,
560-
!outputSlot && !limitOver && outputCell
566+
outputSlot ? h('td', { staticClass: 'pvtOutput' }, outputSlot) : limitOver ? h('td', { staticClass: 'pvtOutput' }, outputScopedSlot({ pivotData: new PivotData(props) })) : outputCell
561567
]
562568
)
563569
])

0 commit comments

Comments
 (0)