This commit is contained in:
@@ -42,7 +42,7 @@ todo: is smoke test really excercising every list? Some are only available from
|
|||||||
this is important because it's going to drive future removal of unused locale keys
|
this is important because it's going to drive future removal of unused locale keys
|
||||||
LIST IS IN SMOKE>JS, JUST CODE IT
|
LIST IS IN SMOKE>JS, JUST CODE IT
|
||||||
|
|
||||||
|
localhost:8080//viewreport?oid=1&rid=1 erroring out, kosher?
|
||||||
|
|
||||||
## V8MIGRATE
|
## V8MIGRATE
|
||||||
|
|
||||||
@@ -53,6 +53,7 @@ todo: dirty big test again with contracts etc
|
|||||||
|
|
||||||
## CLIENT MISC ITEMS
|
## CLIENT MISC ITEMS
|
||||||
|
|
||||||
|
todo: render report directly not working due to server changes, needs to rehydrate the object type to work properly
|
||||||
todo: bugbug sort a column in data table then remove that column from display will trigger error
|
todo: bugbug sort a column in data table then remove that column from display will trigger error
|
||||||
needs to gracefully handle missing columns
|
needs to gracefully handle missing columns
|
||||||
|
|
||||||
|
|||||||
@@ -173,6 +173,7 @@ export default {
|
|||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
//log unhandled api error
|
//log unhandled api error
|
||||||
|
|
||||||
window.$gz.store.commit(
|
window.$gz.store.commit(
|
||||||
"logItem",
|
"logItem",
|
||||||
"API error: status=" +
|
"API error: status=" +
|
||||||
@@ -696,8 +697,11 @@ export default {
|
|||||||
|
|
||||||
let res = await window.$gz.api.upsert("report/render", reportDataOptions);
|
let res = await window.$gz.api.upsert("report/render", reportDataOptions);
|
||||||
if (res.error) {
|
if (res.error) {
|
||||||
throw new Error(window.$gz.errorHandler.errorToString(res));
|
if (redirectNotPopup) {
|
||||||
//throw new Error(res.error);
|
return res;
|
||||||
|
} else {
|
||||||
|
throw new Error(window.$gz.errorHandler.errorToString(res));
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
let reportUrl = window.$gz.api.reportDownloadUrl(res.data);
|
let reportUrl = window.$gz.api.reportDownloadUrl(res.data);
|
||||||
if (redirectNotPopup) {
|
if (redirectNotPopup) {
|
||||||
|
|||||||
@@ -722,13 +722,24 @@ export default new Router({
|
|||||||
{
|
{
|
||||||
//REPORT VIEW FROM URL
|
//REPORT VIEW FROM URL
|
||||||
path: "/viewreport",
|
path: "/viewreport",
|
||||||
beforeEnter: (to, from, next) => {
|
beforeEnter: async (to, from, next) => {
|
||||||
(async function() {
|
// (async function() {
|
||||||
//open report links have a query string /viewreport?oid=[objectid]&rid=[reportid]
|
//open report links have a query string /viewreport?oid=[objectid]&rid=[reportid]
|
||||||
let objectId = parseInt(to.query.oid);
|
let objectId = parseInt(to.query.oid);
|
||||||
let reportId = parseInt(to.query.rid);
|
let reportId = parseInt(to.query.rid);
|
||||||
await window.$gz.api.renderReport(objectId, reportId, true);
|
|
||||||
})();
|
let res = await window.$gz.api.renderReport(objectId, reportId, true);
|
||||||
|
if (res.error) {
|
||||||
|
//log the error and do a popup for it
|
||||||
|
let msg = `/viewReport, query ${JSON.stringify(
|
||||||
|
to.query
|
||||||
|
)}, server error: ${JSON.stringify(res.error)}`;
|
||||||
|
// window.$gz.store.commit("logItem", msg);
|
||||||
|
window.$gz.eventBus.$emit("notify-error", msg);
|
||||||
|
next("/applog");
|
||||||
|
}
|
||||||
|
|
||||||
|
//})();
|
||||||
|
|
||||||
next(false);
|
next(false);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<div v-if="objectType && objectId" class="mb-6">
|
<div v-if="objectType && objectId" class="mb-6">
|
||||||
<v-icon @click="navToTarget()" large>{{ iconForType() }}</v-icon
|
<v-icon data-cy="clickThru" @click="navToTarget()" large>{{
|
||||||
|
iconForType()
|
||||||
|
}}</v-icon
|
||||||
><span @click="navToTarget()" class="text-h5"> {{ name }}</span>
|
><span @click="navToTarget()" class="text-h5"> {{ name }}</span>
|
||||||
</div>
|
</div>
|
||||||
<gz-report-selector ref="reportSelector"></gz-report-selector>
|
<gz-report-selector ref="reportSelector"></gz-report-selector>
|
||||||
|
|||||||
@@ -15,6 +15,7 @@
|
|||||||
:aya-type="ayaTypes().Customer"
|
:aya-type="ayaTypes().Customer"
|
||||||
:show-edit-icon="true"
|
:show-edit-icon="true"
|
||||||
:label="$ay.t('Customer')"
|
:label="$ay.t('Customer')"
|
||||||
|
data-cy="clickThru"
|
||||||
></gz-pick-list>
|
></gz-pick-list>
|
||||||
</v-col>
|
</v-col>
|
||||||
</v-row>
|
</v-row>
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<div v-if="objectType && objectId" class="mb-6">
|
<div v-if="objectType && objectId" class="mb-6">
|
||||||
<v-icon @click="navToTarget()" large>{{ iconForType() }}</v-icon
|
<v-icon data-cy="clickThru" @click="navToTarget()" large>{{
|
||||||
|
iconForType()
|
||||||
|
}}</v-icon
|
||||||
><span @click="navToTarget()" class="text-h5"> {{ name }}</span>
|
><span @click="navToTarget()" class="text-h5"> {{ name }}</span>
|
||||||
</div>
|
</div>
|
||||||
<gz-report-selector ref="reportSelector"></gz-report-selector>
|
<gz-report-selector ref="reportSelector"></gz-report-selector>
|
||||||
|
|||||||
@@ -16,22 +16,21 @@ describe("SMOKE", () => {
|
|||||||
/*
|
/*
|
||||||
|
|
||||||
TODO:
|
TODO:
|
||||||
change widget form customize and datalistcolumnview to other form in prep for eventual widget removal
|
x ay-open path: "/open/:ayatype/:recordid",
|
||||||
ay-open
|
x home-memos/id edit form
|
||||||
home-memos/id edit form
|
x home-remidners/id
|
||||||
home-remidners/id
|
x home-reviews/objecttype/objectid
|
||||||
home-reviews/objecttype/objectid
|
x home-reset
|
||||||
home-reset (last? or at all?)
|
x cust-customer-notes/customerid
|
||||||
cust-customer-notes/customerid
|
x cust-customer-note/recordid
|
||||||
cust-customer-note/recordid
|
XXXXx cust-users/recordid NOT WORKING, NEEDS MORE
|
||||||
cust-users/recordid
|
x inv-part-serials/id
|
||||||
inv-part-serials/id
|
x inv-part-stock-levels/id
|
||||||
inv-part-stock-levels/id
|
x inv-part-adjustment (is transaction edit form)
|
||||||
inv-part-adjustment (is transaction edit form)
|
x acc-service-banks/recordid/objecttype/objectid
|
||||||
acc-service-banks/recordid/objecttype/objectid
|
x adm-users/id
|
||||||
adm-users/id
|
x adm-import
|
||||||
adm-import
|
/viewreport viewreport?oid=[objectid]&rid=[reportid]
|
||||||
/viewreport
|
|
||||||
ay-evaluate !
|
ay-evaluate !
|
||||||
|
|
||||||
|
|
||||||
@@ -54,14 +53,26 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/home-memos");
|
cy.url().should("include", "/home-memos");
|
||||||
cy.get("[data-cy=memosTable]");
|
cy.get("[data-cy=memosTable]");
|
||||||
|
|
||||||
|
cy.visit("/home-memos/0"); //no reliable single id would work for existing
|
||||||
|
cy.url().should("include", "/home-memos/0");
|
||||||
|
cy.get("[data-cy=pickListSelectedUserId]");
|
||||||
|
|
||||||
cy.visit("/home-reminders");
|
cy.visit("/home-reminders");
|
||||||
cy.url().should("include", "/home-reminders");
|
cy.url().should("include", "/home-reminders");
|
||||||
cy.get("[data-cy=remindersTable]");
|
cy.get("[data-cy=remindersTable]");
|
||||||
|
|
||||||
|
cy.visit("/home-reminders/0");
|
||||||
|
cy.url().should("include", "/home-reminders/0");
|
||||||
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
cy.visit("/home-reviews");
|
cy.visit("/home-reviews");
|
||||||
cy.url().should("include", "/home-reviews");
|
cy.url().should("include", "/home-reviews");
|
||||||
cy.get("[data-cy=reviewsTable]");
|
cy.get("[data-cy=reviewsTable]");
|
||||||
|
|
||||||
|
cy.visit("/home-reviews/8/1");
|
||||||
|
cy.url().should("include", "/home-reviews/8/1");
|
||||||
|
cy.get("[data-cy=clickThru]");
|
||||||
|
|
||||||
cy.visit("/home-user-settings");
|
cy.visit("/home-user-settings");
|
||||||
cy.url().should("include", "/home-user-settings");
|
cy.url().should("include", "/home-user-settings");
|
||||||
cy.get("[data-cy=emailAddress]");
|
cy.get("[data-cy=emailAddress]");
|
||||||
@@ -70,6 +81,11 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/home-password");
|
cy.url().should("include", "/home-password");
|
||||||
cy.get("[data-cy=loginName]");
|
cy.get("[data-cy=loginName]");
|
||||||
|
|
||||||
|
//can't do this without reset code etc, just logs out
|
||||||
|
// cy.visit("/home-reset");
|
||||||
|
// cy.url().should("include", "/home-reset");
|
||||||
|
// cy.get("[data-cy=loginName]");
|
||||||
|
|
||||||
cy.visit("/home-notify-subscriptions");
|
cy.visit("/home-notify-subscriptions");
|
||||||
cy.url().should("include", "/home-notify-subscriptions");
|
cy.url().should("include", "/home-notify-subscriptions");
|
||||||
cy.get("[data-cy=subsTable]");
|
cy.get("[data-cy=subsTable]");
|
||||||
@@ -95,6 +111,14 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/cust-customers/1");
|
cy.url().should("include", "/cust-customers/1");
|
||||||
cy.get("[data-cy=name]");
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
|
cy.visit("/cust-customer-notes/1");
|
||||||
|
cy.url().should("include", "/cust-customer-notes/1");
|
||||||
|
cy.get("[data-cy=clickThru]");
|
||||||
|
|
||||||
|
cy.visit("/cust-customer-note/0");
|
||||||
|
cy.url().should("include", "/cust-customer-note/0");
|
||||||
|
cy.get("[data-cy=notes]");
|
||||||
|
|
||||||
cy.visit("/cust-head-offices");
|
cy.visit("/cust-head-offices");
|
||||||
cy.url().should("include", "/cust-head-offices");
|
cy.url().should("include", "/cust-head-offices");
|
||||||
cy.get("[data-cy=headofficesTable]");
|
cy.get("[data-cy=headofficesTable]");
|
||||||
@@ -107,6 +131,10 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/cust-users");
|
cy.url().should("include", "/cust-users");
|
||||||
cy.get("[data-cy=custUsersTable]");
|
cy.get("[data-cy=custUsersTable]");
|
||||||
|
|
||||||
|
// cy.visit("/cust-users/0");
|
||||||
|
// cy.url().should("include", "/cust-users/0");
|
||||||
|
// cy.get("[data-cy=customerId]");
|
||||||
|
|
||||||
//################# SERVICE
|
//################# SERVICE
|
||||||
cy.visit("/svc-schedule");
|
cy.visit("/svc-schedule");
|
||||||
cy.url().should("include", "/svc-schedule");
|
cy.url().should("include", "/svc-schedule");
|
||||||
@@ -217,6 +245,14 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/inv-part-assemblies/1");
|
cy.url().should("include", "/inv-part-assemblies/1");
|
||||||
cy.get("[data-cy=name]");
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
|
cy.visit("/inv-part-serials/1");
|
||||||
|
cy.url().should("include", "/inv-part-serials/1");
|
||||||
|
cy.get("[data-cy=selectedPartId]");
|
||||||
|
|
||||||
|
cy.visit("/inv-part-stock-levels/1");
|
||||||
|
cy.url().should("include", "/inv-part-stock-levels/1");
|
||||||
|
cy.get("[data-cy=selectedPartId]");
|
||||||
|
|
||||||
cy.visit("/inv-part-warehouses");
|
cy.visit("/inv-part-warehouses");
|
||||||
cy.url().should("include", "/inv-part-warehouses");
|
cy.url().should("include", "/inv-part-warehouses");
|
||||||
cy.get("[data-cy=partwarehousesTable]");
|
cy.get("[data-cy=partwarehousesTable]");
|
||||||
@@ -225,9 +261,9 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/inv-part-warehouses/1");
|
cy.url().should("include", "/inv-part-warehouses/1");
|
||||||
cy.get("[data-cy=name]");
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
// cy.visit("/inv-part-requests");
|
cy.visit("/inv-part-adjustment");
|
||||||
// cy.url().should("include", "/inv-part-requests");
|
cy.url().should("include", "/inv-part-adjustment");
|
||||||
// cy.get("[data-cy=underconstruction]");
|
cy.get("[data-cy=description]");
|
||||||
|
|
||||||
//################# VENDORS
|
//################# VENDORS
|
||||||
cy.visit("/vendors");
|
cy.visit("/vendors");
|
||||||
@@ -243,6 +279,14 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/acc-service-banks");
|
cy.url().should("include", "/acc-service-banks");
|
||||||
cy.get("[data-cy=serviceBanksTable]");
|
cy.get("[data-cy=serviceBanksTable]");
|
||||||
|
|
||||||
|
cy.visit("/acc-service-banks/8/1");
|
||||||
|
cy.url().should("include", "/acc-service-banks/8/1");
|
||||||
|
cy.get("[data-cy=clickThru]");
|
||||||
|
|
||||||
|
cy.visit("/acc-service-banks/0/8/1");
|
||||||
|
cy.url().should("include", "/acc-service-banks/0/8/1");
|
||||||
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
cy.visit("/acc-service-rates");
|
cy.visit("/acc-service-rates");
|
||||||
cy.url().should("include", "/acc-service-rates");
|
cy.url().should("include", "/acc-service-rates");
|
||||||
cy.get("[data-cy=serviceRatesTable]");
|
cy.get("[data-cy=serviceRatesTable]");
|
||||||
@@ -288,6 +332,10 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/adm-users");
|
cy.url().should("include", "/adm-users");
|
||||||
cy.get("[data-cy=usersTable]");
|
cy.get("[data-cy=usersTable]");
|
||||||
|
|
||||||
|
cy.visit("/adm-users/1");
|
||||||
|
cy.url().should("include", "/adm-users/1");
|
||||||
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
cy.visit("/adm-translations");
|
cy.visit("/adm-translations");
|
||||||
cy.url().should("include", "/adm-translations");
|
cy.url().should("include", "/adm-translations");
|
||||||
cy.get("[data-cy=transTable]");
|
cy.get("[data-cy=transTable]");
|
||||||
@@ -312,6 +360,10 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/adm-history");
|
cy.url().should("include", "/adm-history");
|
||||||
cy.get("[data-cy=historyTable]");
|
cy.get("[data-cy=historyTable]");
|
||||||
|
|
||||||
|
cy.visit("/adm-import");
|
||||||
|
cy.url().should("include", "/adm-import");
|
||||||
|
cy.get("[data-cy=ayaType]");
|
||||||
|
|
||||||
//################# OPERATIONS
|
//################# OPERATIONS
|
||||||
cy.visit("/ops-backup");
|
cy.visit("/ops-backup");
|
||||||
cy.url().should("include", "/ops-backup");
|
cy.url().should("include", "/ops-backup");
|
||||||
@@ -358,14 +410,12 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/applog");
|
cy.url().should("include", "/applog");
|
||||||
cy.get("[data-cy=logText]");
|
cy.get("[data-cy=logText]");
|
||||||
|
|
||||||
//todo: change to non widget form
|
cy.visit("/customize/Customer");
|
||||||
cy.visit("/customize/Widget");
|
cy.url().should("include", "/customize/Customer");
|
||||||
cy.url().should("include", "/customize/Widget");
|
|
||||||
cy.get("[data-cy=customizeForm]");
|
cy.get("[data-cy=customizeForm]");
|
||||||
|
|
||||||
//todo: change to non widget form
|
cy.visit("/data-list-column-view/CustomerDataList");
|
||||||
cy.visit("/data-list-column-view/TestWidgetDataList");
|
cy.url().should("include", "/data-list-column-view/CustomerDataList");
|
||||||
cy.url().should("include", "/data-list-column-view/TestWidgetDataList");
|
|
||||||
cy.get("[data-cy=dlcForm]");
|
cy.get("[data-cy=dlcForm]");
|
||||||
|
|
||||||
cy.visit("/home-reviews/2/1");
|
cy.visit("/home-reviews/2/1");
|
||||||
@@ -376,14 +426,22 @@ ay-evaluate !
|
|||||||
cy.url().should("include", "/history/3/1");
|
cy.url().should("include", "/history/3/1");
|
||||||
cy.get("[data-cy=timeLine]");
|
cy.get("[data-cy=timeLine]");
|
||||||
|
|
||||||
cy.visit("/widgets");
|
cy.visit("/open/8/1");
|
||||||
cy.url().should("include", "/widgets");
|
cy.url().should("include", "/cust-customers/1");
|
||||||
cy.get("[data-cy=widgetsTable]");
|
|
||||||
|
|
||||||
cy.visit("/widgets/0");
|
|
||||||
cy.url().should("include", "/widgets/0");
|
|
||||||
cy.get("[data-cy=name]");
|
cy.get("[data-cy=name]");
|
||||||
|
|
||||||
|
// cy.visit("/viewreport?oid=1&rid=1");
|
||||||
|
// cy.url().should("include", "/cust-customers/1");
|
||||||
|
// cy.get("[data-cy=name]");
|
||||||
|
|
||||||
|
// cy.visit("/widgets");
|
||||||
|
// cy.url().should("include", "/widgets");
|
||||||
|
// cy.get("[data-cy=widgetsTable]");
|
||||||
|
|
||||||
|
// cy.visit("/widgets/0");
|
||||||
|
// cy.url().should("include", "/widgets/0");
|
||||||
|
// cy.get("[data-cy=name]");
|
||||||
|
|
||||||
cy.visit("/NOTFOUND");
|
cy.visit("/NOTFOUND");
|
||||||
cy.contains("404");
|
cy.contains("404");
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user