This commit is contained in:
@@ -133,7 +133,7 @@
|
||||
<div v-if="item.uiFieldDataType === 1">
|
||||
<v-select
|
||||
v-model="item.tempFilterToken"
|
||||
:items="pickLists.dateFilterTokens"
|
||||
:items="selectLists.dateFilterTokens"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -142,7 +142,7 @@
|
||||
<div v-if="item.tempFilterToken == '*select*'">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.dateFilterOperators"
|
||||
:items="selectLists.dateFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
></v-select>
|
||||
@@ -173,7 +173,7 @@
|
||||
>
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.stringFilterOperators"
|
||||
:items="selectLists.stringFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -201,7 +201,7 @@
|
||||
<div v-if="item.uiFieldDataType === 5">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.integerFilterOperators"
|
||||
:items="selectLists.integerFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -229,7 +229,7 @@
|
||||
<div v-if="item.uiFieldDataType === 6">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.boolFilterOperators"
|
||||
:items="selectLists.boolFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -267,7 +267,7 @@
|
||||
<div v-if="item.uiFieldDataType === 7">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.decimalFilterOperators"
|
||||
:items="selectLists.decimalFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -294,7 +294,7 @@
|
||||
<div v-if="item.uiFieldDataType === 8">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.decimalFilterOperators"
|
||||
:items="selectLists.decimalFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -321,7 +321,7 @@
|
||||
<div v-if="item.uiFieldDataType === 9">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.tagFilterOperators"
|
||||
:items="selectLists.tagFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -345,7 +345,7 @@
|
||||
<div v-if="item.uiFieldDataType === 10">
|
||||
<v-select
|
||||
v-model="item.tempFilterOperator"
|
||||
:items="pickLists.enumFilterOperators"
|
||||
:items="selectLists.enumFilterOperators"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
:label="lt('Filter')"
|
||||
@@ -359,7 +359,7 @@
|
||||
item.tempFilterOperator != '*HASVALUE*'
|
||||
"
|
||||
v-model="item.tempFilterValue"
|
||||
:items="enumPickList(item.enumType)"
|
||||
:items="enumSelectionList(item.enumType)"
|
||||
item-text="name"
|
||||
item-value="id"
|
||||
></v-select>
|
||||
@@ -492,7 +492,7 @@ export default {
|
||||
fieldDefinitions: [],
|
||||
effectiveListView: undefined,
|
||||
concurrencyToken: undefined,
|
||||
pickLists: {
|
||||
selectLists: {
|
||||
dateFilterOperators: [],
|
||||
dateFilterTokens: [],
|
||||
stringFilterOperators: [],
|
||||
@@ -561,8 +561,8 @@ export default {
|
||||
lt: function(ltkey) {
|
||||
return window.$gz.translation.get(ltkey);
|
||||
},
|
||||
enumPickList: function(enumKey) {
|
||||
return window.$gz.enums.getPickList(enumKey);
|
||||
enumSelectionList: function(enumKey) {
|
||||
return window.$gz.enums.getSelectionList(enumKey);
|
||||
},
|
||||
includeChanged: function(item) {
|
||||
if (item.required && item.visible == false) {
|
||||
@@ -977,7 +977,7 @@ function initForm(vm) {
|
||||
(async function() {
|
||||
try {
|
||||
await fetchTranslatedText(vm);
|
||||
await populatePickLists(vm);
|
||||
await populateSelectionLists(vm);
|
||||
await populateFieldDefinitions(vm);
|
||||
await fetchTranslatedFieldNames(vm);
|
||||
await setEffectiveListView(vm);
|
||||
@@ -1049,8 +1049,8 @@ function fetchTranslatedText(vm) {
|
||||
/////////////////////////////////
|
||||
//
|
||||
//
|
||||
function populatePickLists(vm) {
|
||||
vm.pickLists.dateFilterOperators.push(
|
||||
function populateSelectionLists(vm) {
|
||||
vm.selectLists.dateFilterOperators.push(
|
||||
...[
|
||||
{ name: vm.lt("GridRowFilterDropDownBlanksItem"), id: "*NOVALUE*" },
|
||||
{
|
||||
@@ -1069,7 +1069,7 @@ function populatePickLists(vm) {
|
||||
]
|
||||
);
|
||||
|
||||
vm.pickLists.dateFilterTokens.push(
|
||||
vm.selectLists.dateFilterTokens.push(
|
||||
...[
|
||||
{ name: "(" + vm.lt("SelectItem") + ")", id: "*select*" }, //If select then use entry in date /time picker
|
||||
{ name: vm.lt("DateRangeYesterday"), id: "*yesterday*" },
|
||||
@@ -1102,7 +1102,7 @@ function populatePickLists(vm) {
|
||||
]
|
||||
);
|
||||
|
||||
vm.pickLists.stringFilterOperators.push(
|
||||
vm.selectLists.stringFilterOperators.push(
|
||||
...[
|
||||
{ name: vm.lt("GridRowFilterDropDownBlanksItem"), id: "*NOVALUE*" },
|
||||
{
|
||||
@@ -1125,7 +1125,7 @@ function populatePickLists(vm) {
|
||||
]
|
||||
);
|
||||
|
||||
vm.pickLists.integerFilterOperators.push(
|
||||
vm.selectLists.integerFilterOperators.push(
|
||||
...[
|
||||
{ name: vm.lt("GridRowFilterDropDownBlanksItem"), id: "*NOVALUE*" },
|
||||
{
|
||||
@@ -1144,7 +1144,7 @@ function populatePickLists(vm) {
|
||||
]
|
||||
);
|
||||
|
||||
vm.pickLists.boolFilterOperators.push(
|
||||
vm.selectLists.boolFilterOperators.push(
|
||||
...[
|
||||
{ name: vm.lt("GridRowFilterDropDownBlanksItem"), id: "*NOVALUE*" },
|
||||
{
|
||||
@@ -1156,7 +1156,7 @@ function populatePickLists(vm) {
|
||||
]
|
||||
);
|
||||
|
||||
vm.pickLists.decimalFilterOperators.push(
|
||||
vm.selectLists.decimalFilterOperators.push(
|
||||
...[
|
||||
{ name: vm.lt("GridRowFilterDropDownBlanksItem"), id: "*NOVALUE*" },
|
||||
{
|
||||
@@ -1175,12 +1175,12 @@ function populatePickLists(vm) {
|
||||
]
|
||||
);
|
||||
//tags filter only by equals in initial release, see DataListSqlFilterCriteriaBuilder.cs line 523 for deets
|
||||
vm.pickLists.tagFilterOperators.push({
|
||||
vm.selectLists.tagFilterOperators.push({
|
||||
name: vm.lt("GridRowFilterDropDownEquals"),
|
||||
id: "="
|
||||
});
|
||||
|
||||
vm.pickLists.enumFilterOperators.push(
|
||||
vm.selectLists.enumFilterOperators.push(
|
||||
...[
|
||||
{ name: vm.lt("GridRowFilterDropDownBlanksItem"), id: "*NOVALUE*" },
|
||||
{
|
||||
@@ -1430,20 +1430,20 @@ function getDisplayForFilter(
|
||||
) {
|
||||
//BLANKS FILTER
|
||||
if (filterOperator == "=" && filterValue == "*NULL*") {
|
||||
return window.$gz._.find(vm.pickLists.stringFilterOperators, {
|
||||
return window.$gz._.find(vm.selectLists.stringFilterOperators, {
|
||||
id: "*NOVALUE*"
|
||||
}).name;
|
||||
}
|
||||
// NONBLANKS FILTER
|
||||
if (filterOperator == "!=" && filterValue == "*NULL*") {
|
||||
return window.$gz._.find(vm.pickLists.stringFilterOperators, {
|
||||
return window.$gz._.find(vm.selectLists.stringFilterOperators, {
|
||||
id: "*HASVALUE*"
|
||||
}).name;
|
||||
}
|
||||
|
||||
//DATE RELATIVE TOKEN FILTER
|
||||
if (uiFieldDataType === 1 && filterValue[0] == "*") {
|
||||
var valueDisplay = window.$gz._.find(vm.pickLists.dateFilterTokens, {
|
||||
var valueDisplay = window.$gz._.find(vm.selectLists.dateFilterTokens, {
|
||||
id: filterValue
|
||||
}).name;
|
||||
var opDisplay = filterOperator;
|
||||
@@ -1486,7 +1486,7 @@ function getDisplayForFilter(
|
||||
}
|
||||
|
||||
//Operator
|
||||
var opDisplay = window.$gz._.find(vm.pickLists.stringFilterOperators, {
|
||||
var opDisplay = window.$gz._.find(vm.selectLists.stringFilterOperators, {
|
||||
id: filterOperator
|
||||
}).name;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user