This commit is contained in:
@@ -76,13 +76,13 @@ CURRENTLY WORKING ON: Customer
|
||||
OUTSTANDING
|
||||
|
||||
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
|
||||
documentation update for form
|
||||
Customer
|
||||
v8 migrate
|
||||
|
||||
|
||||
|
||||
todo: TESTING After customer form is made
|
||||
Test with devices
|
||||
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)
|
||||
//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 (tid.inside == undefined && tid.id != 0) {
|
||||
if (tid.id != 0) {
|
||||
//lookup which one to open from server
|
||||
(async () => {
|
||||
try {
|
||||
let res = await window.$gz.api.get(
|
||||
"user/inside-type/" + tid.id
|
||||
);
|
||||
|
||||
if (res.error) {
|
||||
throw new Error(res.error);
|
||||
//shortcut for superuser, always id 1
|
||||
if (tid.inside == undefined && tid.id == 1) {
|
||||
tid.inside = true;
|
||||
}
|
||||
if (res.data) {
|
||||
tid.inside = res.data;
|
||||
if (tid.inside == undefined) {
|
||||
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) {
|
||||
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;
|
||||
case ayatype.NotifySubscription:
|
||||
vm.$router.push({
|
||||
|
||||
Reference in New Issue
Block a user