This commit is contained in:
2020-03-04 00:02:54 +00:00
parent b7115335e7
commit a932da04c6
3 changed files with 29 additions and 3 deletions

View File

@@ -514,12 +514,15 @@ export default {
//this puts a pin in it then resets it after the fetch is completed
var preSelected = [...vm.selected];
//untokenize ListView date token criteria (if there are any)
var untokenizedListView = untokenizeListView(vm.listView);
window.$gz.api
.upsert(vm.apiBaseUrl, {
offset: listOptions.Offset,
limit: listOptions.Limit,
dataListKey: vm.dataListKey,
listView: vm.listView
listView: untokenizedListView
})
.then(res => {
if (res.error != undefined) {
@@ -893,4 +896,19 @@ function loadFormSettings(vm) {
}
}
}
////////////////////
//
function untokenizeListView(lv) {
//[{"fld":"widgetname"},{"fld":"widgetstartdate","filter":{"items":[{"op":"=","value":"*past90days*","token":true}]}},{"fld":"widgetenddate"}]
if (lv == null) {
return lv;
}
//See if it has any date tokens
if (lv.indexOf('"token":true') == -1) {
return;
}
console.log(lv);
console.log(JSON.parse(lv));
}
</script>