This commit is contained in:
@@ -53,9 +53,6 @@ CURRENT TODOs
|
||||
|
||||
todo: login form, if trial or dev then needs to display list of sample users to login as and it fills in the login and password
|
||||
|
||||
todo: Why is there an error in the console when a user is not logged in and opens client?
|
||||
- It should just go to login, no error should show in the console
|
||||
|
||||
todo: ANY TIME - SIDE v7 STUFF DataDump plugin needs an explanation of what it is in the flow, right now it's completely cryptic and people may be using it for stuff thinking it's for something it's not
|
||||
- Also, verify it's manager account only that can run it or maybe someone with total rights to everything?
|
||||
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
<v-row align="center" justify="center" class="mx-auto mt-sm-12 mb-8">
|
||||
<v-col cols="12" offset-md="4">
|
||||
<form>
|
||||
{{ trialMode }}
|
||||
<v-row>
|
||||
<v-col cols="12" class="hidden-md-and-up">
|
||||
<v-img
|
||||
@@ -73,8 +74,12 @@
|
||||
<script>
|
||||
/* xeslint-disable */
|
||||
import auth from "../api/auth";
|
||||
let TRIAL_MODE = false;
|
||||
export default {
|
||||
name: "Login",
|
||||
// beforeCreate() {
|
||||
// //calling this here because created is never called on this form and I don't know why
|
||||
|
||||
// },
|
||||
data() {
|
||||
return {
|
||||
input: {
|
||||
@@ -83,18 +88,32 @@ export default {
|
||||
// username: "CustomerLimited",
|
||||
// password: "CustomerLimited"
|
||||
},
|
||||
trialMode: false,
|
||||
errorBadCreds: false,
|
||||
reveal: false,
|
||||
formState: { errorBoxMessage: null }
|
||||
};
|
||||
},
|
||||
created() {
|
||||
let vm = this;
|
||||
window.$gz.eventBus.$emit("menu-change", {
|
||||
isMain: true,
|
||||
icon: "",
|
||||
title: ""
|
||||
});
|
||||
window.$gz.api
|
||||
.get("license/trial")
|
||||
.then(res => {
|
||||
if (res.data) {
|
||||
// console.log("res.data:", res.data);
|
||||
vm.trialMode = res.data;
|
||||
}
|
||||
})
|
||||
.catch(function handleGetTrialModeError(error) {
|
||||
//squash it, this isn't critical
|
||||
});
|
||||
},
|
||||
computed: {},
|
||||
methods: {
|
||||
onEnterUserName: function() {
|
||||
//move focus to password
|
||||
@@ -163,4 +182,40 @@ export default {
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
// created() {
|
||||
// console.log("CREATED");
|
||||
// // window.$gz.api
|
||||
// // .get("license/trial")
|
||||
// // .then(res => {
|
||||
// // debugger;
|
||||
// // vm.formState.ready = true;
|
||||
// // if (res.error != undefined) {
|
||||
// // vm.formState.serverError = res.error;
|
||||
// // window.$gz.form.setErrorBoxErrors(vm);
|
||||
// // } else {
|
||||
// // vm.trialMode = res.data;
|
||||
// // // vm.obj = res.data;
|
||||
|
||||
// // // //Update the form status
|
||||
// // // window.$gz.form.setFormState({
|
||||
// // // vm: vm,
|
||||
// // // dirty: false,
|
||||
// // // valid: true,
|
||||
// // // loading: false,
|
||||
// // // readOnly: res.readOnly ? true : false
|
||||
// // // });
|
||||
// // // //modify the menu as necessary
|
||||
// // // generateMenu(vm);
|
||||
// // }
|
||||
// // })
|
||||
// // .catch(function handleGetDataFromAPIError(error) {
|
||||
// // //Update the form status
|
||||
// // window.$gz.form.setFormState({
|
||||
// // vm: vm,
|
||||
// // loading: false
|
||||
// // });
|
||||
// // window.$gz.errorHandler.handleFormError(error, vm);
|
||||
// // });
|
||||
// },
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user