This commit is contained in:
2020-11-11 18:27:38 +00:00
parent 4cec5dd8cc
commit 6b8bbe23a1
2 changed files with 44 additions and 17 deletions

View File

@@ -15,6 +15,12 @@ export default {
if (tid.type && tid.id != null) { if (tid.type && tid.id != null) {
switch (tid.type) { switch (tid.type) {
case ayatype.Customer:
vm.$router.push({
name: "customer-edit",
params: { recordid: tid.id }
});
break;
case ayatype.Widget: case ayatype.Widget:
vm.$router.push({ vm.$router.push({
name: "widget-edit", name: "widget-edit",

View File

@@ -325,25 +325,46 @@ export default {
selectLists: { selectLists: {
usertypes: [] usertypes: []
}, },
obj: { obj:
//IMPORTANT NOTE: Fields that are NON NULLABLE in the schema for the table but *are* hideable **MUST** have a default value set here or else there will be no way to save the record //IMPORTANT NOTE: Fields that are NON NULLABLE in the schema for the table but *are* hideable **MUST** have a default value set here or else there will be no way to save the record
//I.E. Serial, usertype fields //I.E. Serial, usertype fields
//Also, if it's a non-nullable Enum backed field then it should have a valid selection i.e. not zero if there is no zero //Also, if it's a non-nullable Enum backed field then it should have a valid selection i.e. not zero if there is no zero
{
id: 0, id: 0,
concurrency: 0, concurrency: 0,
name: null, name: null,
serial: 0,
dollarAmount: null,
active: null, active: null,
userType: 2, //defaulted here to something valid
startDate: null,
endDate: null,
notes: null, notes: null,
count: null,
wiki: null, wiki: null,
customFields: "{}", customFields: "{}",
tags: [], tags: [],
userId: null webAddress: null,
popUpNotes: null,
billHeadOffice: false,
headOfficeID: null,
techNotes: null,
accountNumber: null,
usesBanking: false,
contractID: null,
contractExpires: null,
defaultServiceTemplateID: null,
phone1: null,
phone2: null,
phone3: null,
phone4: null,
phone5: null,
emailAddress: null,
postAddress: null,
postCity: null,
postRegion: null,
postCountry: null,
postCode: null,
address: null,
city: null,
region: null,
country: null,
latitude: null,
longitude: null
}, },
formState: { formState: {
ready: false, ready: false,