This commit is contained in:
@@ -62,6 +62,8 @@ export default {
|
|||||||
customTitle: null,
|
customTitle: null,
|
||||||
timeSpan: "*thismonth*",
|
timeSpan: "*thismonth*",
|
||||||
interval: "day",
|
interval: "day",
|
||||||
|
wotags: [],
|
||||||
|
woitemtags: [],
|
||||||
color: "#00205B"
|
color: "#00205B"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -74,6 +76,8 @@ export default {
|
|||||||
settings: {
|
settings: {
|
||||||
customTitle: null,
|
customTitle: null,
|
||||||
timeSpan: "*thismonth*",
|
timeSpan: "*thismonth*",
|
||||||
|
wotags: [],
|
||||||
|
woitemtags: [],
|
||||||
interval: "day",
|
interval: "day",
|
||||||
color: "#00205B"
|
color: "#00205B"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
<v-dialog
|
<v-dialog
|
||||||
v-model="context"
|
v-model="context"
|
||||||
scrollable
|
scrollable
|
||||||
max-width="600px"
|
max-width="400px"
|
||||||
data-cy="dashSettings"
|
data-cy="dashSettings"
|
||||||
@keydown.esc="cancel"
|
@keydown.esc="cancel"
|
||||||
>
|
>
|
||||||
@@ -34,7 +34,7 @@
|
|||||||
<span> {{ $ay.t("Settings") }} </span>
|
<span> {{ $ay.t("Settings") }} </span>
|
||||||
</v-card-title>
|
</v-card-title>
|
||||||
|
|
||||||
<v-card-text style="height: 500px;">
|
<v-card-text >
|
||||||
<v-select
|
<v-select
|
||||||
v-model="localSettings.timeSpan"
|
v-model="localSettings.timeSpan"
|
||||||
:items="selectLists.dateFilterTokens"
|
:items="selectLists.dateFilterTokens"
|
||||||
@@ -51,6 +51,16 @@
|
|||||||
:label="$ay.t('Interval')"
|
:label="$ay.t('Interval')"
|
||||||
></v-select>
|
></v-select>
|
||||||
|
|
||||||
|
<gz-tag-picker
|
||||||
|
v-model="localSettings.wotags"
|
||||||
|
:label="$ay.t('Tags') + ' - ' + $ay.t('WorkOrder')"
|
||||||
|
></gz-tag-picker>
|
||||||
|
|
||||||
|
<gz-tag-picker
|
||||||
|
v-model="localSettings.woitemtags"
|
||||||
|
:label="$ay.t('Tags') + ' - ' + $ay.t('WorkOrderItem')"
|
||||||
|
></gz-tag-picker>
|
||||||
|
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="localSettings.customTitle"
|
v-model="localSettings.customTitle"
|
||||||
:label="$ay.t('Name')"
|
:label="$ay.t('Name')"
|
||||||
@@ -157,14 +167,18 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
showContext: function() {
|
showContext: function() {
|
||||||
this.localSettings = window.$gz.util.deepCopySkip(this.settings);
|
this.localSettings = window.$gz.util.deepCopySkip(this.settings);
|
||||||
|
console.log(JSON.stringify(this.localSettings));
|
||||||
this.context = true;
|
this.context = true;
|
||||||
},
|
},
|
||||||
updateSettings: function() {
|
updateSettings: function() {
|
||||||
//copy settings from local to
|
//copy settings from local to parent settings, need to do it this way or get error about mutating prop directly which is vexing and has no easy solution seemingly
|
||||||
this.settings.customTitle = this.localSettings.customTitle;
|
this.settings.customTitle = this.localSettings.customTitle;
|
||||||
this.settings.timeSpan = this.localSettings.timeSpan;
|
this.settings.timeSpan = this.localSettings.timeSpan;
|
||||||
this.settings.interval = this.localSettings.interval;
|
this.settings.interval = this.localSettings.interval;
|
||||||
this.settings.color = this.localSettings.color;
|
this.settings.color = this.localSettings.color;
|
||||||
|
this.settings.wotags = this.localSettings.wotags;
|
||||||
|
this.settings.woitemtags = this.localSettings.woitemtags;
|
||||||
|
|
||||||
this.$emit("dash-change"); //trigger save to server
|
this.$emit("dash-change"); //trigger save to server
|
||||||
this.context = false;
|
this.context = false;
|
||||||
this.getDataFromApi();
|
this.getDataFromApi();
|
||||||
@@ -177,7 +191,9 @@ export default {
|
|||||||
KPIName: "WorkOrderItemLaborQuantitySummary",
|
KPIName: "WorkOrderItemLaborQuantitySummary",
|
||||||
criteria: {
|
criteria: {
|
||||||
timeSpan: this.settings.timeSpan,
|
timeSpan: this.settings.timeSpan,
|
||||||
interval: this.settings.interval
|
interval: this.settings.interval,
|
||||||
|
wotags: this.settings.wotags,
|
||||||
|
woitemtags: this.settings.woitemtags
|
||||||
},
|
},
|
||||||
clientTimeStamp: window.$gz.locale.clientLocalZoneTimeStamp()
|
clientTimeStamp: window.$gz.locale.clientLocalZoneTimeStamp()
|
||||||
});
|
});
|
||||||
@@ -258,7 +274,9 @@ async function fetchTranslatedText() {
|
|||||||
"WorkOrderItemLaborServiceRateQuantity",
|
"WorkOrderItemLaborServiceRateQuantity",
|
||||||
"Name",
|
"Name",
|
||||||
"TimeSpan",
|
"TimeSpan",
|
||||||
"Interval"
|
"Interval",
|
||||||
|
"WorkOrder",
|
||||||
|
"WorkOrderItem"
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -347,6 +365,9 @@ function populateSelectionLists(vm) {
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
||||||
|
todo: tag filtering hasn't been added yet
|
||||||
|
todo: from client click on view of total billable hours by period
|
||||||
|
add to v.next case
|
||||||
todo: clean up line version of dash-labor-hours-personal with lessons learned from bar one
|
todo: clean up line version of dash-labor-hours-personal with lessons learned from bar one
|
||||||
todo: add icons to dashregistry with title so can include some indication of type of chart when names are duped
|
todo: add icons to dashregistry with title so can include some indication of type of chart when names are duped
|
||||||
or subtitle if icons too fucky
|
or subtitle if icons too fucky
|
||||||
|
|||||||
Reference in New Issue
Block a user