mirror of
https://github.com/jpros/tacticalrmm-web.git
synced 2026-01-20 03:50:21 +00:00
some quasar cleanup
This commit is contained in:
@@ -1,2 +0,0 @@
|
|||||||
> 1%
|
|
||||||
last 2 versions
|
|
||||||
@@ -1,3 +1,16 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
presets: ["@vue/cli-plugin-babel/preset"]
|
"presets": [
|
||||||
};
|
"@vue/cli-plugin-babel/preset"
|
||||||
|
],
|
||||||
|
"plugins": [
|
||||||
|
[
|
||||||
|
"transform-imports",
|
||||||
|
{
|
||||||
|
"quasar": {
|
||||||
|
"transform": "quasar/dist/babel-transforms/imports.js",
|
||||||
|
"preventFullImport": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
]
|
||||||
|
}
|
||||||
1230
package-lock.json
generated
1230
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
17
package.json
17
package.json
@@ -16,12 +16,19 @@
|
|||||||
"vuex": "^3.1.3"
|
"vuex": "^3.1.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@vue/cli-plugin-babel": "^4.2.3",
|
"@vue/cli-plugin-babel": "~4.3.0",
|
||||||
"@vue/cli-service": "^4.2.3",
|
"@vue/cli-plugin-router": "~4.3.0",
|
||||||
"babel-plugin-transform-imports": "2.0.0",
|
"@vue/cli-plugin-vuex": "~4.3.0",
|
||||||
|
"@vue/cli-service": "~4.3.0",
|
||||||
|
"babel-plugin-transform-imports": "1.5.0",
|
||||||
"stylus": "^0.54.7",
|
"stylus": "^0.54.7",
|
||||||
"stylus-loader": "^3.0.2",
|
"stylus-loader": "^3.0.2",
|
||||||
"vue-cli-plugin-quasar": "^2.0.0",
|
"vue-cli-plugin-quasar": "~2.0.0",
|
||||||
"vue-template-compiler": "^2.6.11"
|
"vue-template-compiler": "^2.6.11"
|
||||||
}
|
},
|
||||||
|
"browserslist": [
|
||||||
|
"> 1%",
|
||||||
|
"last 2 versions",
|
||||||
|
"not dead"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
plugins: {
|
|
||||||
autoprefixer: {}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -3,8 +3,14 @@ import Vue from "vue";
|
|||||||
import "./styles/quasar.styl";
|
import "./styles/quasar.styl";
|
||||||
import "@quasar/extras/material-icons/material-icons.css";
|
import "@quasar/extras/material-icons/material-icons.css";
|
||||||
import "@quasar/extras/fontawesome-v5/fontawesome-v5.css";
|
import "@quasar/extras/fontawesome-v5/fontawesome-v5.css";
|
||||||
import "@quasar/extras/mdi-v3/mdi-v3.css";
|
import {
|
||||||
import Quasar from "quasar";
|
Quasar,
|
||||||
|
Dialog,
|
||||||
|
Loading,
|
||||||
|
LoadingBar,
|
||||||
|
Meta,
|
||||||
|
Notify
|
||||||
|
} from 'quasar';
|
||||||
|
|
||||||
Vue.use(Quasar, {
|
Vue.use(Quasar, {
|
||||||
config: {
|
config: {
|
||||||
@@ -18,5 +24,13 @@ Vue.use(Quasar, {
|
|||||||
textColor: "white",
|
textColor: "white",
|
||||||
actions: [{ icon: "close", color: "white" }]
|
actions: [{ icon: "close", color: "white" }]
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
plugins: {
|
||||||
|
Dialog,
|
||||||
|
Loading,
|
||||||
|
LoadingBar,
|
||||||
|
Meta,
|
||||||
|
Notify
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
import Vue from "vue";
|
import Vue from "vue";
|
||||||
import Router from "vue-router";
|
import VueRouter from "vue-router";
|
||||||
|
|
||||||
Vue.use(Router);
|
Vue.use(VueRouter);
|
||||||
|
|
||||||
export default new Router({
|
const router = new VueRouter({
|
||||||
mode: "history",
|
mode: "history",
|
||||||
base: process.env.BASE_URL,
|
base: process.env.BASE_URL,
|
||||||
routes: [
|
routes: [
|
||||||
{
|
{
|
||||||
path: "/",
|
path: "/",
|
||||||
name: "Dashboard",
|
name: "Dashboard",
|
||||||
component: () => import ("@/views/Dashboard"),
|
component: () => import("@/views/Dashboard"),
|
||||||
meta: {
|
meta: {
|
||||||
requireAuth: true
|
requireAuth: true
|
||||||
}
|
}
|
||||||
@@ -18,7 +18,7 @@ export default new Router({
|
|||||||
{
|
{
|
||||||
path: "/setup",
|
path: "/setup",
|
||||||
name: "InitialSetup",
|
name: "InitialSetup",
|
||||||
component: () => import ("@/views/InitialSetup"),
|
component: () => import("@/views/InitialSetup"),
|
||||||
meta: {
|
meta: {
|
||||||
requireAuth: true
|
requireAuth: true
|
||||||
}
|
}
|
||||||
@@ -26,7 +26,7 @@ export default new Router({
|
|||||||
{
|
{
|
||||||
path: "/takecontrol/:pk",
|
path: "/takecontrol/:pk",
|
||||||
name: "TakeControl",
|
name: "TakeControl",
|
||||||
component: () => import ("@/views/TakeControl"),
|
component: () => import("@/views/TakeControl"),
|
||||||
meta: {
|
meta: {
|
||||||
requireAuth: true
|
requireAuth: true
|
||||||
}
|
}
|
||||||
@@ -34,7 +34,7 @@ export default new Router({
|
|||||||
{
|
{
|
||||||
path: "/remotebackground/:pk",
|
path: "/remotebackground/:pk",
|
||||||
name: "RemoteBackground",
|
name: "RemoteBackground",
|
||||||
component: () => import ("@/views/RemoteBackground"),
|
component: () => import("@/views/RemoteBackground"),
|
||||||
meta: {
|
meta: {
|
||||||
requireAuth: true
|
requireAuth: true
|
||||||
}
|
}
|
||||||
@@ -42,7 +42,7 @@ export default new Router({
|
|||||||
{
|
{
|
||||||
path: "/login",
|
path: "/login",
|
||||||
name: "Login",
|
name: "Login",
|
||||||
component: () => import ("@/views/Login"),
|
component: () => import("@/views/Login"),
|
||||||
meta: {
|
meta: {
|
||||||
requiresVisitor: true
|
requiresVisitor: true
|
||||||
}
|
}
|
||||||
@@ -50,16 +50,18 @@ export default new Router({
|
|||||||
{
|
{
|
||||||
path: "/logout",
|
path: "/logout",
|
||||||
name: "Logout",
|
name: "Logout",
|
||||||
component: () => import ("@/views/Logout")
|
component: () => import("@/views/Logout")
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/expired",
|
path: "/expired",
|
||||||
name: "SessionExpired",
|
name: "SessionExpired",
|
||||||
component: () => import ("@/views/SessionExpired"),
|
component: () => import("@/views/SessionExpired"),
|
||||||
meta: {
|
meta: {
|
||||||
requireAuth: true
|
requireAuth: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{ path: "*", component: () => import ("@/views/NotFound") }
|
{ path: "*", component: () => import("@/views/NotFound") }
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
|
export default router;
|
||||||
|
|||||||
@@ -33,16 +33,16 @@ export const store = new Vuex.Store({
|
|||||||
toggleAutomationManager: false
|
toggleAutomationManager: false
|
||||||
},
|
},
|
||||||
getters: {
|
getters: {
|
||||||
loggedIn(state) {
|
loggedIn (state) {
|
||||||
return state.token !== null;
|
return state.token !== null;
|
||||||
},
|
},
|
||||||
selectedAgentPk(state) {
|
selectedAgentPk (state) {
|
||||||
return state.agentSummary.id;
|
return state.agentSummary.id;
|
||||||
},
|
},
|
||||||
managedByWsus(state) {
|
managedByWsus (state) {
|
||||||
return state.agentSummary.managed_by_wsus;
|
return state.agentSummary.managed_by_wsus;
|
||||||
},
|
},
|
||||||
sortedUpdates(state) {
|
sortedUpdates (state) {
|
||||||
// sort patches by latest then not installed
|
// sort patches by latest then not installed
|
||||||
if (!state.winUpdates.winupdates) {
|
if (!state.winUpdates.winupdates) {
|
||||||
return [];
|
return [];
|
||||||
@@ -55,115 +55,115 @@ export const store = new Vuex.Store({
|
|||||||
);
|
);
|
||||||
return sortedByInstall;
|
return sortedByInstall;
|
||||||
},
|
},
|
||||||
agentHostname(state) {
|
agentHostname (state) {
|
||||||
return state.agentSummary.hostname;
|
return state.agentSummary.hostname;
|
||||||
},
|
},
|
||||||
scripts(state) {
|
scripts (state) {
|
||||||
return state.scripts;
|
return state.scripts;
|
||||||
},
|
},
|
||||||
policies(state) {
|
policies (state) {
|
||||||
return state.policies;
|
return state.policies;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mutations: {
|
mutations: {
|
||||||
TOGGLE_AUTOMATION_MANAGER(state, action) {
|
TOGGLE_AUTOMATION_MANAGER (state, action) {
|
||||||
state.toggleAutomationManager = action;
|
state.toggleAutomationManager = action;
|
||||||
},
|
},
|
||||||
TOGGLE_SCRIPT_MANAGER(state, action) {
|
TOGGLE_SCRIPT_MANAGER (state, action) {
|
||||||
state.toggleScriptManager = action;
|
state.toggleScriptManager = action;
|
||||||
},
|
},
|
||||||
AGENT_TABLE_LOADING(state, visible) {
|
AGENT_TABLE_LOADING (state, visible) {
|
||||||
state.agentTableLoading = visible;
|
state.agentTableLoading = visible;
|
||||||
},
|
},
|
||||||
setActiveRow(state, pk) {
|
setActiveRow (state, pk) {
|
||||||
state.selectedRow = pk;
|
state.selectedRow = pk;
|
||||||
},
|
},
|
||||||
retrieveToken(state, { token, username }) {
|
retrieveToken (state, { token, username }) {
|
||||||
state.token = token;
|
state.token = token;
|
||||||
state.username = username;
|
state.username = username;
|
||||||
},
|
},
|
||||||
destroyCommit(state) {
|
destroyCommit (state) {
|
||||||
state.token = null;
|
state.token = null;
|
||||||
state.username = null;
|
state.username = null;
|
||||||
},
|
},
|
||||||
getUpdatedSites(state, clients) {
|
getUpdatedSites (state, clients) {
|
||||||
state.clients = clients;
|
state.clients = clients;
|
||||||
},
|
},
|
||||||
loadTree(state, treebar) {
|
loadTree (state, treebar) {
|
||||||
state.tree = treebar;
|
state.tree = treebar;
|
||||||
state.treeReady = true;
|
state.treeReady = true;
|
||||||
},
|
},
|
||||||
setSummary(state, summary) {
|
setSummary (state, summary) {
|
||||||
state.agentSummary = summary;
|
state.agentSummary = summary;
|
||||||
},
|
},
|
||||||
SET_WIN_UPDATE(state, updates) {
|
SET_WIN_UPDATE (state, updates) {
|
||||||
state.winUpdates = updates;
|
state.winUpdates = updates;
|
||||||
},
|
},
|
||||||
SET_INSTALLED_SOFTWARE(state, software) {
|
SET_INSTALLED_SOFTWARE (state, software) {
|
||||||
state.installedSoftware = software;
|
state.installedSoftware = software;
|
||||||
},
|
},
|
||||||
setChecks(state, checks) {
|
setChecks (state, checks) {
|
||||||
state.agentChecks = checks;
|
state.agentChecks = checks;
|
||||||
},
|
},
|
||||||
SET_AUTOMATED_TASKS(state, tasks) {
|
SET_AUTOMATED_TASKS (state, tasks) {
|
||||||
state.automatedTasks = tasks;
|
state.automatedTasks = tasks;
|
||||||
},
|
},
|
||||||
destroySubTable(state) {
|
destroySubTable (state) {
|
||||||
(state.agentSummary = {}),
|
(state.agentSummary = {}),
|
||||||
(state.agentChecks = {}),
|
(state.agentChecks = {}),
|
||||||
(state.winUpdates = {});
|
(state.winUpdates = {});
|
||||||
(state.installedSoftware = []);
|
(state.installedSoftware = []);
|
||||||
state.selectedRow = "";
|
state.selectedRow = "";
|
||||||
},
|
},
|
||||||
SET_SCRIPTS(state, scripts) {
|
SET_SCRIPTS (state, scripts) {
|
||||||
state.scripts = scripts;
|
state.scripts = scripts;
|
||||||
},
|
},
|
||||||
SET_POLICIES(state, policies) {
|
SET_POLICIES (state, policies) {
|
||||||
state.policies = policies;
|
state.policies = policies;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
actions: {
|
actions: {
|
||||||
getPolicies(context) {
|
getPolicies (context) {
|
||||||
axios.get("/automation/policies/").then(r => {
|
axios.get("/automation/policies/").then(r => {
|
||||||
context.commit("SET_POLICIES", r.data);
|
context.commit("SET_POLICIES", r.data);
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
loadAutomatedTasks(context, pk) {
|
loadAutomatedTasks (context, pk) {
|
||||||
axios.get(`/automation/${pk}/automatedtasks/`).then(r => {
|
axios.get(`/automation/${pk}/automatedtasks/`).then(r => {
|
||||||
context.commit("SET_AUTOMATED_TASKS", r.data);
|
context.commit("SET_AUTOMATED_TASKS", r.data);
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
getScripts(context) {
|
getScripts (context) {
|
||||||
axios.get("/checks/getscripts/").then(r => {
|
axios.get("/checks/getscripts/").then(r => {
|
||||||
context.commit("SET_SCRIPTS", r.data);
|
context.commit("SET_SCRIPTS", r.data);
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
loadInstalledSoftware(context, pk) {
|
loadInstalledSoftware (context, pk) {
|
||||||
axios.get(`/software/installed/${pk}`).then(r => {
|
axios.get(`/software/installed/${pk}`).then(r => {
|
||||||
context.commit("SET_INSTALLED_SOFTWARE", r.data.software);
|
context.commit("SET_INSTALLED_SOFTWARE", r.data.software);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
loadWinUpdates(context, pk) {
|
loadWinUpdates (context, pk) {
|
||||||
axios.get(`/winupdate/${pk}/getwinupdates/`).then(r => {
|
axios.get(`/winupdate/${pk}/getwinupdates/`).then(r => {
|
||||||
context.commit("SET_WIN_UPDATE", r.data);
|
context.commit("SET_WIN_UPDATE", r.data);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
loadSummary(context, pk) {
|
loadSummary (context, pk) {
|
||||||
axios.get(`/agents/${pk}/agentdetail/`).then(r => {
|
axios.get(`/agents/${pk}/agentdetail/`).then(r => {
|
||||||
context.commit("setSummary", r.data);
|
context.commit("setSummary", r.data);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
loadChecks(context, pk) {
|
loadChecks (context, pk) {
|
||||||
axios.get(`/checks/${pk}/loadchecks/`).then(r => {
|
axios.get(`/checks/${pk}/loadchecks/`).then(r => {
|
||||||
context.commit("setChecks", r.data);
|
context.commit("setChecks", r.data);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
getUpdatedSites(context) {
|
getUpdatedSites (context) {
|
||||||
axios.get("/clients/loadclients/").then(r => {
|
axios.get("/clients/loadclients/").then(r => {
|
||||||
context.commit("getUpdatedSites", r.data);
|
context.commit("getUpdatedSites", r.data);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
loadTree({ commit }) {
|
loadTree ({ commit }) {
|
||||||
axios.get("/clients/loadtree/").then(r => {
|
axios.get("/clients/loadtree/").then(r => {
|
||||||
const input = r.data;
|
const input = r.data;
|
||||||
if (
|
if (
|
||||||
@@ -206,7 +206,7 @@ export const store = new Vuex.Store({
|
|||||||
//commit("destroySubTable");
|
//commit("destroySubTable");
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
retrieveToken(context, credentials) {
|
retrieveToken (context, credentials) {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
axios
|
axios
|
||||||
.post("/login/", credentials)
|
.post("/login/", credentials)
|
||||||
@@ -228,7 +228,7 @@ export const store = new Vuex.Store({
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
destroyToken(context) {
|
destroyToken (context) {
|
||||||
if (context.getters.loggedIn) {
|
if (context.getters.loggedIn) {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
axios
|
axios
|
||||||
|
|||||||
@@ -3,7 +3,12 @@ module.exports = {
|
|||||||
host: "192.168.99.150"
|
host: "192.168.99.150"
|
||||||
},
|
},
|
||||||
pluginOptions: {
|
pluginOptions: {
|
||||||
quasar: {}
|
quasar: {
|
||||||
|
importStrategy: 'kebab',
|
||||||
|
rtlSupport: false
|
||||||
|
}
|
||||||
},
|
},
|
||||||
transpileDependencies: [/[\\\/]node_modules[\\\/]quasar[\\\/]/]
|
transpileDependencies: [
|
||||||
};
|
'quasar'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user