This commit is contained in:
@@ -76,13 +76,13 @@ CURRENTLY WORKING ON: Customer
|
|||||||
OUTSTANDING
|
OUTSTANDING
|
||||||
|
|
||||||
User opening in cust-user, not internal user, needs to know which one I guess or object open needs a hint
|
User opening in cust-user, not internal user, needs to know which one I guess or object open needs a hint
|
||||||
customer notes
|
|
||||||
help docs
|
|
||||||
|
|
||||||
Customer
|
Customer
|
||||||
documentation update for form
|
|
||||||
v8 migrate
|
v8 migrate
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
todo: TESTING After customer form is made
|
todo: TESTING After customer form is made
|
||||||
Test with devices
|
Test with devices
|
||||||
ensure that a PHONE "tel" field can be triggered to make a phone call
|
ensure that a PHONE "tel" field can be triggered to make a phone call
|
||||||
|
|||||||
@@ -37,36 +37,41 @@ export default {
|
|||||||
//Is it an "Inside" user (staff or subcontractor)
|
//Is it an "Inside" user (staff or subcontractor)
|
||||||
//or an "outside" user (customer or headoffice)
|
//or an "outside" user (customer or headoffice)
|
||||||
//if key doesn't provide this then need to directly find out first before determining which form to redirect to
|
//if key doesn't provide this then need to directly find out first before determining which form to redirect to
|
||||||
if (tid.inside == undefined && tid.id != 0) {
|
if (tid.id != 0) {
|
||||||
//lookup which one to open from server
|
//lookup which one to open from server
|
||||||
(async () => {
|
(async () => {
|
||||||
try {
|
try {
|
||||||
let res = await window.$gz.api.get(
|
//shortcut for superuser, always id 1
|
||||||
"user/inside-type/" + tid.id
|
if (tid.inside == undefined && tid.id == 1) {
|
||||||
);
|
tid.inside = true;
|
||||||
|
|
||||||
if (res.error) {
|
|
||||||
throw new Error(res.error);
|
|
||||||
}
|
}
|
||||||
if (res.data) {
|
if (tid.inside == undefined) {
|
||||||
tid.inside = res.data;
|
let res = await window.$gz.api.get(
|
||||||
|
"user/inside-type/" + tid.id
|
||||||
|
);
|
||||||
|
if (res.error) {
|
||||||
|
throw new Error(res.error);
|
||||||
|
}
|
||||||
|
if (res.data) {
|
||||||
|
tid.inside = res.data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (tid.inside == true) {
|
||||||
|
vm.$router.push({
|
||||||
|
name: "adm-user",
|
||||||
|
params: { recordid: tid.id }
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
vm.$router.push({
|
||||||
|
name: "cust-user",
|
||||||
|
params: { recordid: tid.id }
|
||||||
|
});
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
throw new Error(e);
|
throw new Error(e);
|
||||||
}
|
}
|
||||||
})();
|
})();
|
||||||
}
|
}
|
||||||
if (tid.inside == true) {
|
|
||||||
vm.$router.push({
|
|
||||||
name: "adm-user",
|
|
||||||
params: { recordid: tid.id }
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
vm.$router.push({
|
|
||||||
name: "cust-user",
|
|
||||||
params: { recordid: tid.id }
|
|
||||||
});
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
case ayatype.NotifySubscription:
|
case ayatype.NotifySubscription:
|
||||||
vm.$router.push({
|
vm.$router.push({
|
||||||
|
|||||||
Reference in New Issue
Block a user