This commit is contained in:
2020-12-23 18:35:42 +00:00
parent 39a94500a1
commit 5caf2acb23
2 changed files with 30 additions and 14 deletions

View File

@@ -106,6 +106,8 @@
<!-- ******** BUILDER FOR EACH TYPE Tag, decimal,currency, bool, integer, string, datetime ******** -->
<!-- NOTE: currently not implemented: TimeSpan=15, seems unsupportable for a filter -->
<!-- DATETIME BUILDER -->
<!-- Note: date time is a bit unusual in that it presents the date tokens first as it would be the most common choice whereas the other types would do something
like that later -->
<div v-if="item.uiFieldDataType === 1">
<v-select
v-model="item.tempFilterToken"
@@ -608,22 +610,34 @@ export default {
//DATE relative token?
if (item.uiFieldDataType === 1) {
//some kind of relative date token?
if (
item.tempFilterToken &&
item.tempFilterToken != "*select*" &&
item.tempFilterToken != "*NOVALUE*" &&
item.tempFilterToken != "*HASVALUE*"
) {
//special relative token
filterItem.op = "="; //equality
filterItem.token = true;
filterItem.value = item.tempFilterToken;
filterItemSet = true;
if (item.tempFilterToken) {
//no or has value?
//this redundancy is because there are two ways to select the no value and has value; both present in the relative pick list
//and also in the select specific value picklist as the date filter picker for convenience so this is a workaround
//to simulate if the user had done the full *select* first then picked novalue or has value
if (item.tempFilterToken == "*NOVALUE*") {
filterItem.op = "=";
filterItem.value = "*NULL*";
filterItemSet = true;
} else if (item.tempFilterToken == "*HASVALUE*") {
filterItem.op = "!=";
filterItem.value = "*NULL*";
filterItemSet = true;
} else {
//some kind of relative date token?
if (item.tempFilterToken != "*select*") {
//special relative token
filterItem.op = "="; //equality
filterItem.token = true;
filterItem.value = item.tempFilterToken;
filterItemSet = true;
}
}
}
}
debugger;
//BLANKS / NONBLANKS TOKENS?
if (false == filterItemSet && item.tempFilterOperator == "*NOVALUE*") {
filterItem.op = "=";