This commit is contained in:
@@ -118,6 +118,20 @@ export default {
|
|||||||
//do not want the client end to have to do math or anything and also it needs to drive reporting of the same type as the widget display
|
//do not want the client end to have to do math or anything and also it needs to drive reporting of the same type as the widget display
|
||||||
//so as similar as possible to the datatable system but handles the math and summarizing ideally in the db server itself
|
//so as similar as possible to the datatable system but handles the math and summarizing ideally in the db server itself
|
||||||
/*
|
/*
|
||||||
|
TODO:
|
||||||
|
DYNAMIC FROM SETS
|
||||||
|
handle params (time range, currentusertoken,period)
|
||||||
|
enforce current user only (I guess that's built in if use token or leave out token because it's assumed in which case rename to WorkOrderItemLaborQuantitySummaryPERSONAL )
|
||||||
|
ACTUAL CHART WORKING
|
||||||
|
line chart, can it work with this data, does it need adjustment to locale?
|
||||||
|
scroll? Vertical better than horizontal? Select bar OR line?
|
||||||
|
|
||||||
|
|
||||||
|
REPORTING
|
||||||
|
v.nexxt?
|
||||||
|
charts lib at server?
|
||||||
|
|
||||||
|
|
||||||
DateTrunc https://www.postgresqltutorial.com/postgresql-date_trunc/ will respect changes of month or year or whatever so this works
|
DateTrunc https://www.postgresqltutorial.com/postgresql-date_trunc/ will respect changes of month or year or whatever so this works
|
||||||
|
|
||||||
SELECT row_to_json(t) as res from (
|
SELECT row_to_json(t) as res from (
|
||||||
@@ -133,27 +147,30 @@ GROUP BY timeframe
|
|||||||
ORDER BY timeframe ASC
|
ORDER BY timeframe ASC
|
||||||
) t
|
) t
|
||||||
|
|
||||||
TODO:
|
|
||||||
DYNAMIC FROM SETS
|
|
||||||
handle params (time range, currentusertoken,period)
|
|
||||||
enforce current user only (I guess that's built in if use token or leave out token because it's assumed in which case rename to WorkOrderItemLaborQuantitySummaryPERSONAL )
|
|
||||||
ACTUAL CHART WORKING
|
|
||||||
line chart, can it work with this data, does it need adjustment to locale?
|
|
||||||
scroll? Vertical better than horizontal? Select bar OR line?
|
|
||||||
|
|
||||||
|
|
||||||
REPORTING
|
|
||||||
v.nexxt?
|
|
||||||
charts lib at server?
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// let tt = {
|
||||||
|
// KPIName: "WorkOrderItemLaborQuantitySummary",
|
||||||
|
// criteria: {
|
||||||
|
// dateRange: this.settings.dateRange,
|
||||||
|
// unit: this.settings.unit
|
||||||
|
// },
|
||||||
|
// clientTimeStamp: window.$gz.locale.clientLocalZoneTimeStamp()
|
||||||
|
// };
|
||||||
|
// console.log(tt);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
this.errorMessage = null;
|
this.errorMessage = null;
|
||||||
const res = await window.$gz.api.post("kpi", {
|
const res = await window.$gz.api.post("kpi", {
|
||||||
KPIName: "WorkOrderItemLaborQuantitySummary",
|
KPIName: "WorkOrderItemLaborQuantitySummary",
|
||||||
criteria: JSON.stringify({ test: 12, blah: "blahbittyblahblahblah" }),
|
criteria: {
|
||||||
|
dateRange: this.settings.dateRange,
|
||||||
|
unit: this.settings.unit
|
||||||
|
},
|
||||||
clientTimeStamp: window.$gz.locale.clientLocalZoneTimeStamp()
|
clientTimeStamp: window.$gz.locale.clientLocalZoneTimeStamp()
|
||||||
});
|
});
|
||||||
if (res.error) {
|
if (res.error) {
|
||||||
|
|||||||
Reference in New Issue
Block a user