mirror of
https://git.meshkee.com/cssd/cssd-front.git
synced 2026-10-13 16:03:20 +03:30
fix : title of pages
This commit is contained in:
+39
-36
@@ -11,12 +11,12 @@ import Vue from 'vue'
|
|||||||
// import VueAnalytics from 'vue-analytics'
|
// import VueAnalytics from 'vue-analytics'
|
||||||
import Router from 'vue-router'
|
import Router from 'vue-router'
|
||||||
import Meta from 'vue-meta'
|
import Meta from 'vue-meta'
|
||||||
import { TokenService } from '@/services'
|
import {TokenService} from '@/services'
|
||||||
|
|
||||||
// Routes
|
// Routes
|
||||||
import paths from './paths'
|
import paths from './paths'
|
||||||
|
|
||||||
function route (options) {
|
function route(options) {
|
||||||
let path = options.path;
|
let path = options.path;
|
||||||
let view = options.view;
|
let view = options.view;
|
||||||
let name = options.name;
|
let name = options.name;
|
||||||
@@ -26,8 +26,8 @@ function route (options) {
|
|||||||
path,
|
path,
|
||||||
meta,
|
meta,
|
||||||
component: (resovle) => import(
|
component: (resovle) => import(
|
||||||
`@/views/${view}.vue`
|
`@/views/${view}.vue`
|
||||||
).then(resovle)
|
).then(resovle)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -35,51 +35,54 @@ Vue.use(Router)
|
|||||||
|
|
||||||
// Create a new router
|
// Create a new router
|
||||||
const router = new Router({
|
const router = new Router({
|
||||||
mode: 'history',
|
mode: 'history',
|
||||||
routes: paths.map(path => route(path)).concat([
|
routes: paths.map(path => route(path)).concat([
|
||||||
{ path: '*', redirect: '/dashboard' }
|
{path: '*', redirect: '/dashboard'}
|
||||||
]),
|
]),
|
||||||
scrollBehavior (to, from, savedPosition) {
|
scrollBehavior(to, from, savedPosition) {
|
||||||
if (savedPosition) {
|
if (savedPosition) {
|
||||||
return savedPosition
|
return savedPosition
|
||||||
|
}
|
||||||
|
if (to.hash) {
|
||||||
|
return {selector: to.hash}
|
||||||
|
}
|
||||||
|
return {x: 0, y: 0}
|
||||||
}
|
}
|
||||||
if (to.hash) {
|
|
||||||
return { selector: to.hash }
|
|
||||||
}
|
|
||||||
return { x: 0, y: 0 }
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
Vue.use(Meta)
|
|
||||||
|
Vue.use(Meta, {
|
||||||
|
refreshOnceOnNavigation: true
|
||||||
|
})
|
||||||
|
|
||||||
import {$hasRole} from '@/services/acl/role';
|
import {$hasRole} from '@/services/acl/role';
|
||||||
|
|
||||||
router.beforeEach((to, from, next) => {
|
router.beforeEach((to, from, next) => {
|
||||||
const isPublic = to.matched.some(record => record.meta.public);
|
const isPublic = to.matched.some(record => record.meta.public);
|
||||||
const onlyWhenLoggedOut = to.matched.some(record => record.meta.onlyWhenLoggedOut);
|
const onlyWhenLoggedOut = to.matched.some(record => record.meta.onlyWhenLoggedOut);
|
||||||
const loggedIn = !!TokenService.getToken();
|
const loggedIn = !!TokenService.getToken();
|
||||||
const roles = (to.meta && to.meta.roles) ? to.meta.roles : null;
|
const roles = (to.meta && to.meta.roles) ? to.meta.roles : null;
|
||||||
if (to.meta.title) {
|
if (to.meta.title) {
|
||||||
document.title = to.meta.title;
|
document.title = to.meta.title;
|
||||||
}
|
}
|
||||||
if (!isPublic && !loggedIn) {
|
if (!isPublic && !loggedIn) {
|
||||||
return next({
|
return next({
|
||||||
path:'/login',
|
path: '/login',
|
||||||
query: {redirect: to.fullPath} // Store the full path to redirect the user to after login
|
query: {redirect: to.fullPath} // Store the full path to redirect the user to after login
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// Do not allow user to visit login page or register page if they are logged in
|
// Do not allow user to visit login page or register page if they are logged in
|
||||||
if (loggedIn && onlyWhenLoggedOut ) {
|
if (loggedIn && onlyWhenLoggedOut) {
|
||||||
return next('/')
|
return next('/')
|
||||||
}
|
}
|
||||||
|
|
||||||
// Do not allow user to visit Pages then not access roles
|
// Do not allow user to visit Pages then not access roles
|
||||||
if (roles && !$hasRole(roles)) {
|
if (roles && !$hasRole(roles)) {
|
||||||
return next('/')
|
return next('/')
|
||||||
}
|
}
|
||||||
|
|
||||||
next();
|
next();
|
||||||
});
|
});
|
||||||
|
|
||||||
// Bootstrap Analytics
|
// Bootstrap Analytics
|
||||||
|
|||||||
+310
-310
@@ -4,316 +4,316 @@
|
|||||||
* official documentation https://router.vuejs.org/en/
|
* official documentation https://router.vuejs.org/en/
|
||||||
*/
|
*/
|
||||||
export default [
|
export default [
|
||||||
{
|
{
|
||||||
path: '/dashboard',
|
path: '/dashboard',
|
||||||
name: 'Dashboard',
|
name: 'Dashboard',
|
||||||
view: 'Dashboard',
|
view: 'Dashboard',
|
||||||
meta: {
|
meta: {
|
||||||
title:'CSSD Dashboard'
|
title: 'CSSD Dashboard'
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/my-info',
|
|
||||||
name: 'MyInfo',
|
|
||||||
view: 'User/MyInfo',
|
|
||||||
meta: {
|
|
||||||
title:'My Inf | CSSD Dashboard'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/manage-users',
|
|
||||||
name: 'ManageUsers',
|
|
||||||
view: 'User/List',
|
|
||||||
meta: {
|
|
||||||
roles: 'Admin|Supervisor',
|
|
||||||
title:'Manage User | CSSD Dashboard'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/test-type/create',
|
|
||||||
name: 'AddTestType',
|
|
||||||
view: 'TestType/AddEdit',
|
|
||||||
meta: {
|
|
||||||
title:'Add Test Typ | CSSD Dashboard'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/test-type/:testType/edit',
|
|
||||||
name: 'EditTestType',
|
|
||||||
view: 'TestType/AddEdit',
|
|
||||||
meta: {
|
|
||||||
roles: 'Admin',
|
|
||||||
title:'Edit Test Typ | CSSD Dashboard'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/test-types',
|
|
||||||
name: 'ListTestType',
|
|
||||||
view: 'TestType/List',
|
|
||||||
meta: {
|
|
||||||
roles: 'Admin',
|
|
||||||
title:'List Test Typ | CSSD Dashboard'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/medical-center',
|
|
||||||
name: 'ManageMedicalCenter',
|
|
||||||
view: 'MedicalCenter/List',
|
|
||||||
meta: {
|
|
||||||
title:'Manage Medical Center | CSSD Dashboard',
|
|
||||||
roles: 'Admin'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/medical-center/create',
|
|
||||||
name: 'AddMedicalCenter',
|
|
||||||
view: 'MedicalCenter/AddEdit',
|
|
||||||
meta: {
|
|
||||||
title:'Add Medical Center | CSSD Dashboard',
|
|
||||||
roles: 'Admin'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/medical-center/:medicalCenter/edit',
|
|
||||||
name: 'EditMedicalCenter',
|
|
||||||
view: 'MedicalCenter/AddEdit',
|
|
||||||
meta: {
|
|
||||||
title:'Edit Medical Center | CSSD Dashboard',
|
|
||||||
roles: 'Admin'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/add-operator/:medicalCenter',
|
|
||||||
name: 'AddOperator',
|
|
||||||
view: 'Auth/Register',
|
|
||||||
meta: {
|
|
||||||
title:'Add Operator | CSSD Dashboard',
|
|
||||||
roles: 'Admin'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/operator-list/:medicalCenter',
|
|
||||||
name: 'OperatorList',
|
|
||||||
view: 'MedicalCenter/OperatorList',
|
|
||||||
meta: {
|
|
||||||
title:'Operator List | CSSD Dashboard',
|
|
||||||
roles: 'Admin'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/login',
|
|
||||||
name: 'Login',
|
|
||||||
view: 'Auth/Login',
|
|
||||||
meta: {
|
|
||||||
title:'Login | CSSD Dashboard',
|
|
||||||
public: true, // Allow access to even if not logged in
|
|
||||||
onlyWhenLoggedOut: true
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/register',
|
|
||||||
name: 'Register',
|
|
||||||
view: 'Auth/Register',
|
|
||||||
meta: {
|
|
||||||
title:'Register | CSSD Dashboard',
|
|
||||||
public: true, // Allow access to even if not logged in
|
|
||||||
onlyWhenLoggedOut: true,
|
|
||||||
roles: 'Admin'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/forgot-password',
|
|
||||||
name: 'ForgotPassword',
|
|
||||||
view: 'Auth/ForgotPassword',
|
|
||||||
meta: {
|
|
||||||
title:'Forgot Password | CSSD Dashboard',
|
|
||||||
public: true, // Allow access to even if not logged in
|
|
||||||
onlyWhenLoggedOut: true
|
|
||||||
},
|
},
|
||||||
},
|
{
|
||||||
{
|
path: '/my-info',
|
||||||
path: '/ShowTestResult/:testResult',
|
name: 'MyInfo',
|
||||||
name: 'ShowTestResult',
|
view: 'User/MyInfo',
|
||||||
view: 'TestResult/Show',
|
meta: {
|
||||||
meta: {
|
title: 'My Info | CSSD Dashboard'
|
||||||
title:'Show Test Result | CSSD Dashboard',
|
}
|
||||||
public: true,
|
},
|
||||||
|
{
|
||||||
|
path: '/manage-users',
|
||||||
|
name: 'ManageUsers',
|
||||||
|
view: 'User/List',
|
||||||
|
meta: {
|
||||||
|
roles: 'Admin|Supervisor',
|
||||||
|
title: 'Manage User | CSSD Dashboard'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/test-type/create',
|
||||||
|
name: 'AddTestType',
|
||||||
|
view: 'TestType/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Test Typ | CSSD Dashboard'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/test-type/:testType/edit',
|
||||||
|
name: 'EditTestType',
|
||||||
|
view: 'TestType/AddEdit',
|
||||||
|
meta: {
|
||||||
|
roles: 'Admin',
|
||||||
|
title: 'Edit Test Typ | CSSD Dashboard'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/test-types',
|
||||||
|
name: 'ListTestType',
|
||||||
|
view: 'TestType/List',
|
||||||
|
meta: {
|
||||||
|
roles: 'Admin',
|
||||||
|
title: 'List Test Typ | CSSD Dashboard'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/medical-center',
|
||||||
|
name: 'ManageMedicalCenter',
|
||||||
|
view: 'MedicalCenter/List',
|
||||||
|
meta: {
|
||||||
|
title: 'Manage Medical Center | CSSD Dashboard',
|
||||||
|
roles: 'Admin'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/medical-center/create',
|
||||||
|
name: 'AddMedicalCenter',
|
||||||
|
view: 'MedicalCenter/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Medical Center | CSSD Dashboard',
|
||||||
|
roles: 'Admin'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/medical-center/:medicalCenter/edit',
|
||||||
|
name: 'EditMedicalCenter',
|
||||||
|
view: 'MedicalCenter/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Edit Medical Center | CSSD Dashboard',
|
||||||
|
roles: 'Admin'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/add-operator/:medicalCenter',
|
||||||
|
name: 'AddOperator',
|
||||||
|
view: 'Auth/Register',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Operator | CSSD Dashboard',
|
||||||
|
roles: 'Admin'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/operator-list/:medicalCenter',
|
||||||
|
name: 'OperatorList',
|
||||||
|
view: 'MedicalCenter/OperatorList',
|
||||||
|
meta: {
|
||||||
|
title: 'Operator List | CSSD Dashboard',
|
||||||
|
roles: 'Admin'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/login',
|
||||||
|
name: 'Login',
|
||||||
|
view: 'Auth/Login',
|
||||||
|
meta: {
|
||||||
|
title: 'Login | CSSD Dashboard',
|
||||||
|
public: true, // Allow access to even if not logged in
|
||||||
|
onlyWhenLoggedOut: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/register',
|
||||||
|
name: 'Register',
|
||||||
|
view: 'Auth/Register',
|
||||||
|
meta: {
|
||||||
|
title: 'Register | CSSD Dashboard',
|
||||||
|
public: true, // Allow access to even if not logged in
|
||||||
|
onlyWhenLoggedOut: true,
|
||||||
|
roles: 'Admin'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/forgot-password',
|
||||||
|
name: 'ForgotPassword',
|
||||||
|
view: 'Auth/ForgotPassword',
|
||||||
|
meta: {
|
||||||
|
title: 'Forgot Password | CSSD Dashboard',
|
||||||
|
public: true, // Allow access to even if not logged in
|
||||||
|
onlyWhenLoggedOut: true
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/ShowTestResult/:testResult',
|
||||||
|
name: 'ShowTestResult',
|
||||||
|
view: 'TestResult/Show',
|
||||||
|
meta: {
|
||||||
|
title: 'Show Test Result | CSSD Dashboard',
|
||||||
|
public: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/result-test',
|
||||||
|
name: 'AllResultTest',
|
||||||
|
view: 'TestResult/List',
|
||||||
|
meta: {
|
||||||
|
title: 'All Result Test | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/add-test-result',
|
||||||
|
name: 'SubmitTestResult',
|
||||||
|
view: 'TestResult/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Submit Test Result | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/test-result/:testResult/edit',
|
||||||
|
name: 'EditTestResult',
|
||||||
|
view: 'TestResult/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Edit Test Result | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/test-result/NotVerified',
|
||||||
|
name: 'NotVerifyTestResult',
|
||||||
|
view: 'TestResult/List',
|
||||||
|
meta: {
|
||||||
|
title: 'Not Verify Test Resul | CSSD Dashboard'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/statistics',
|
||||||
|
name: 'Statistics',
|
||||||
|
view: 'Statistics/Chart',
|
||||||
|
meta: {
|
||||||
|
title: 'Statistics | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/add-package',
|
||||||
|
name: 'AddPackage',
|
||||||
|
view: 'Package/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Package | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/packages',
|
||||||
|
name: 'AllPackage',
|
||||||
|
view: 'Package/List',
|
||||||
|
meta: {
|
||||||
|
title: 'All Package | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/packages/:package/edit',
|
||||||
|
name: 'EditPackage',
|
||||||
|
view: 'Package/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Edit Package | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/add-label',
|
||||||
|
name: 'AddLabel',
|
||||||
|
view: 'Label/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Label | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/labels',
|
||||||
|
name: 'AllLabels',
|
||||||
|
view: 'Label/List',
|
||||||
|
meta: {
|
||||||
|
title: 'All Labels | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/label/:label/edit',
|
||||||
|
name: 'EditLabel',
|
||||||
|
view: 'Label/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Edit Label | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/add-cycle',
|
||||||
|
name: 'AddCycle',
|
||||||
|
view: 'Cycle/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Cycle | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/cycles',
|
||||||
|
name: 'AllCycle',
|
||||||
|
view: 'Cycle/List',
|
||||||
|
meta: {
|
||||||
|
title: 'All Cycle | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/cycle/:cycle/edit',
|
||||||
|
name: 'EditCycle',
|
||||||
|
view: 'Cycle/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Edit Cycle | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/add-Item',
|
||||||
|
name: 'AddItem',
|
||||||
|
view: 'Item/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Add Item | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/Items',
|
||||||
|
name: 'AllItem',
|
||||||
|
view: 'Item/List',
|
||||||
|
meta: {
|
||||||
|
title: 'All Item | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/Item/:Item/edit',
|
||||||
|
name: 'EditItem',
|
||||||
|
view: 'Item/AddEdit',
|
||||||
|
meta: {
|
||||||
|
title: 'Edit Item | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/my-Items',
|
||||||
|
name: 'MyItem',
|
||||||
|
view: 'MyItem/List',
|
||||||
|
meta: {
|
||||||
|
title: 'My Item | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/my-Package',
|
||||||
|
name: 'MyPackage',
|
||||||
|
view: 'MyPackage/List',
|
||||||
|
meta: {
|
||||||
|
title: 'My Package | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/tickets',
|
||||||
|
name: 'Tickets',
|
||||||
|
view: 'Tickets/List',
|
||||||
|
meta: {
|
||||||
|
title: 'Tickets | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
/* {
|
||||||
|
path: '/ShowPackage/:package',
|
||||||
|
name: 'ShowPackage',
|
||||||
|
view: 'Package/ShowPackage',
|
||||||
|
meta:{
|
||||||
|
title:'Show Package | CSSD Dashboard',
|
||||||
|
}
|
||||||
|
},*/
|
||||||
|
{
|
||||||
|
path: '/Intro',
|
||||||
|
name: 'Intro',
|
||||||
|
view: 'Intro/Intro',
|
||||||
|
meta: {
|
||||||
|
title: 'Intro | CSSD Dashboard',
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/result-test',
|
|
||||||
name: 'AllResultTest',
|
|
||||||
view: 'TestResult/List',
|
|
||||||
meta:{
|
|
||||||
title:'All Result Test | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/add-test-result',
|
|
||||||
name: 'SubmitTestResult',
|
|
||||||
view: 'TestResult/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Submit Test Result | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/test-result/:testResult/edit',
|
|
||||||
name: 'EditTestResult',
|
|
||||||
view: 'TestResult/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Edit Test Result | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/test-result/NotVerified',
|
|
||||||
name: 'NotVerifyTestResult',
|
|
||||||
view: 'TestResult/List',
|
|
||||||
meta:{
|
|
||||||
title:'Not Verify Test Resul | CSSD Dashboard'
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/statistics',
|
|
||||||
name: 'Statistics',
|
|
||||||
view: 'Statistics/Chart',
|
|
||||||
meta:{
|
|
||||||
title:'Statistics | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/add-package',
|
|
||||||
name: 'AddPackage',
|
|
||||||
view: 'Package/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Add Package | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/packages',
|
|
||||||
name: 'AllPackage',
|
|
||||||
view: 'Package/List',
|
|
||||||
meta:{
|
|
||||||
title:'All Package | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/packages/:package/edit',
|
|
||||||
name: 'EditPackage',
|
|
||||||
view: 'Package/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Edit Package | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/add-label',
|
|
||||||
name: 'AddLabel',
|
|
||||||
view: 'Label/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Add Label | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/labels',
|
|
||||||
name: 'AllLabels',
|
|
||||||
view: 'Label/List',
|
|
||||||
meta:{
|
|
||||||
title:'All Labels | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/label/:label/edit',
|
|
||||||
name: 'EditLabel',
|
|
||||||
view: 'Label/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Edit Label | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/add-cycle',
|
|
||||||
name: 'AddCycle',
|
|
||||||
view: 'Cycle/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Add Cycle | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/cycles',
|
|
||||||
name: 'AllCycle',
|
|
||||||
view: 'Cycle/List',
|
|
||||||
meta:{
|
|
||||||
title:'All Cycle | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/cycle/:cycle/edit',
|
|
||||||
name: 'EditCycle',
|
|
||||||
view: 'Cycle/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Edit Cycle | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/add-Item',
|
|
||||||
name: 'AddItem',
|
|
||||||
view: 'Item/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Add Item | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/Items',
|
|
||||||
name: 'AllItem',
|
|
||||||
view: 'Item/List',
|
|
||||||
meta:{
|
|
||||||
title:'All Item | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/Item/:Item/edit',
|
|
||||||
name: 'EditItem',
|
|
||||||
view: 'Item/AddEdit',
|
|
||||||
meta:{
|
|
||||||
title:'Edit Item | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/my-Items',
|
|
||||||
name: 'MyItem',
|
|
||||||
view: 'MyItem/List',
|
|
||||||
meta:{
|
|
||||||
title:'My Item | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/my-Package',
|
|
||||||
name: 'MyPackage',
|
|
||||||
view: 'MyPackage/List',
|
|
||||||
meta:{
|
|
||||||
title:'My Package | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/tickets',
|
|
||||||
name: 'Tickets',
|
|
||||||
view: 'Tickets/List',
|
|
||||||
meta:{
|
|
||||||
title:'Tickets | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
/* {
|
|
||||||
path: '/ShowPackage/:package',
|
|
||||||
name: 'ShowPackage',
|
|
||||||
view: 'Package/ShowPackage',
|
|
||||||
meta:{
|
|
||||||
title:'Show Package | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},*/
|
|
||||||
{
|
|
||||||
path: '/Intro',
|
|
||||||
name: 'Intro',
|
|
||||||
view: 'Intro/Intro',
|
|
||||||
meta:{
|
|
||||||
title:'Intro | CSSD Dashboard',
|
|
||||||
}
|
|
||||||
},
|
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -1,70 +1,77 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-form ref="form">
|
<v-form ref="form">
|
||||||
<v-container grid-list-xs>
|
<v-container grid-list-xs>
|
||||||
<v-layout row wrap class="justify-center">
|
<v-layout row wrap class="justify-center">
|
||||||
<v-flex xs12 md3 sm3 class="WM-WidthScreen-SM WM-WidthScreen-XS">
|
<v-flex xs12 md3 sm3 class="WM-WidthScreen-SM WM-WidthScreen-XS">
|
||||||
<material-card color="black" title="Login Page">
|
<material-card color="black" title="Login Page">
|
||||||
<v-layout row wrap class="px-3">
|
<v-layout row wrap class="px-3">
|
||||||
<v-flex xs12 md12 sm12>
|
<v-flex xs12 md12 sm12>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="form.cell_number"
|
v-model="form.cell_number"
|
||||||
name="cellnumber"
|
name="cellnumber"
|
||||||
label="Cell Number"
|
label="Cell Number"
|
||||||
color="black"
|
color="black"
|
||||||
:rules="[rules.required, rules.cellNumberCounter]"
|
:rules="[rules.required, rules.cellNumberCounter]"
|
||||||
mask="#### ### ####"
|
mask="#### ### ####"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
<v-layout row wrap class="px-3">
|
||||||
|
<v-flex xs12 md6 sm6 class="text-md-left text-sm-center text-xs-center">
|
||||||
|
<v-btn
|
||||||
|
class="WM-CyanBlueGradient-BG"
|
||||||
|
style="padding:10px 60px"
|
||||||
|
@click="handleSubmit"
|
||||||
|
>
|
||||||
|
<v-icon class="white--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
||||||
|
<span class="white--text">Send</span>
|
||||||
|
</v-btn>
|
||||||
|
</v-flex>
|
||||||
|
<v-flex xs12 md6 sm6 class="text-md-right text-sm-center text-xs-center">
|
||||||
|
<router-link class="black--text" :to="{name: 'Login'}">
|
||||||
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
||||||
|
<v-icon class="black--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
||||||
|
<span class="black--text">Login</span>
|
||||||
|
</v-btn>
|
||||||
|
</router-link>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
</material-card>
|
||||||
|
</v-flex>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
<v-layout row wrap class="px-3">
|
</v-container>
|
||||||
<v-flex xs12 md6 sm6 class="text-md-left text-sm-center text-xs-center">
|
</v-form>
|
||||||
<v-btn
|
|
||||||
class="WM-CyanBlueGradient-BG"
|
|
||||||
style="padding:10px 60px"
|
|
||||||
@click="handleSubmit"
|
|
||||||
>
|
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
|
||||||
<span class="white--text">Send</span>
|
|
||||||
</v-btn>
|
|
||||||
</v-flex>
|
|
||||||
<v-flex xs12 md6 sm6 class="text-md-right text-sm-center text-xs-center">
|
|
||||||
<router-link class="black--text" :to="{name: 'Login'}">
|
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
|
||||||
<span class="black--text">Login</span>
|
|
||||||
</v-btn>
|
|
||||||
</router-link>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
</material-card>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
</v-container>
|
|
||||||
</v-form>
|
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { mapActions, mapMutations } from "vuex";
|
import {mapActions, mapMutations} from "vuex";
|
||||||
import { ApiService } from "@/services";
|
import {ApiService} from "@/services";
|
||||||
import { urls } from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
metaInfo() {
|
||||||
return {
|
return {
|
||||||
form :{
|
title: this.$route.meta.title,
|
||||||
cell_number: ""
|
meta: this.$route.meta.metaTags || []
|
||||||
},
|
}
|
||||||
rules: {
|
},
|
||||||
required: value => !!value || "Required.",
|
data() {
|
||||||
cellNumberCounter: value => (value && value.length == 11) || "must 11 characters"
|
return {
|
||||||
}
|
form: {
|
||||||
};
|
cell_number: ""
|
||||||
},
|
},
|
||||||
methods: {
|
rules: {
|
||||||
...mapActions("auth", ["forgotPassword"]),
|
required: value => !!value || "Required.",
|
||||||
async handleSubmit() {
|
cellNumberCounter: value => (value && value.length == 11) || "must 11 characters"
|
||||||
if (this.$refs.form.validate()) {
|
}
|
||||||
this.forgotPassword({form : this.form});
|
};
|
||||||
}
|
},
|
||||||
|
methods: {
|
||||||
|
...mapActions("auth", ["forgotPassword"]),
|
||||||
|
async handleSubmit() {
|
||||||
|
if (this.$refs.form.validate()) {
|
||||||
|
this.forgotPassword({form: this.form});
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
+95
-87
@@ -1,96 +1,104 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-form ref="form" >
|
<v-form ref="form">
|
||||||
<v-container grid-list-xs>
|
<v-container grid-list-xs>
|
||||||
<v-layout row wrap class="justify-center">
|
<v-layout row wrap class="justify-center">
|
||||||
<v-flex xs12 md3 sm3 class="WM-WidthScreen-SM WM-WidthScreen-XS">
|
<v-flex xs12 md3 sm3 class="WM-WidthScreen-SM WM-WidthScreen-XS">
|
||||||
<material-card
|
<material-card
|
||||||
color="black"
|
color="black"
|
||||||
title="Login Page">
|
title="Login Page">
|
||||||
<v-layout row wrap class="px-3">
|
<v-layout row wrap class="px-3">
|
||||||
<v-flex xs12 md12 sm12>
|
<v-flex xs12 md12 sm12>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="cell_number"
|
v-model="cell_number"
|
||||||
name="cellnumber"
|
name="cellnumber"
|
||||||
label="Cell Number"
|
label="Cell Number"
|
||||||
color="black"
|
color="black"
|
||||||
:rules="[rules.required, rules.cellNumberCounter]"
|
:rules="[rules.required, rules.cellNumberCounter]"
|
||||||
mask="#### ### ####"
|
mask="#### ### ####"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
<v-layout row wrap class="px-3">
|
||||||
|
<v-flex xs12 md12 sm12>
|
||||||
|
<v-text-field
|
||||||
|
name="password"
|
||||||
|
label="Password"
|
||||||
|
v-model="password"
|
||||||
|
:type="show1 ? 'text' : 'password'"
|
||||||
|
:append-icon="show1 ? 'visibility' : 'visibility_off'"
|
||||||
|
@click:append="show1 = !show1"
|
||||||
|
:rules="[rules.required, rules.passCounter]"
|
||||||
|
color="black"
|
||||||
|
class="pa-2"
|
||||||
|
></v-text-field>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
<v-layout row wrap class="px-3">
|
||||||
|
<v-flex xs12 md6 sm6 class="text-md-left text-sm-center text-xs-center">
|
||||||
|
<v-btn class="WM-CyanBlueGradient-BG" style="padding:10px 60px" @click="handleSubmit">
|
||||||
|
<v-icon class="white--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
||||||
|
<span class="white--text">Login</span>
|
||||||
|
</v-btn>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
<v-layout row wrap class="text-md-left text-sm-center text-xs-center">
|
||||||
|
<v-flex xs12 md12 sm12 class="px-4 py-3">
|
||||||
|
<router-link :to="{name: 'ForgotPassword'}">
|
||||||
|
<span class="black--text"
|
||||||
|
style="border-bottom:1px solid #000;">Forgot Password ?</span>
|
||||||
|
</router-link>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
</material-card>
|
||||||
|
</v-flex>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
<v-layout row wrap class="px-3">
|
</v-container>
|
||||||
<v-flex xs12 md12 sm12>
|
</v-form>
|
||||||
<v-text-field
|
|
||||||
name="password"
|
|
||||||
label="Password"
|
|
||||||
v-model="password"
|
|
||||||
:type="show1 ? 'text' : 'password'"
|
|
||||||
:append-icon="show1 ? 'visibility' : 'visibility_off'"
|
|
||||||
@click:append="show1 = !show1"
|
|
||||||
:rules="[rules.required, rules.passCounter]"
|
|
||||||
color="black"
|
|
||||||
class="pa-2"
|
|
||||||
></v-text-field>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
<v-layout row wrap class="px-3">
|
|
||||||
<v-flex xs12 md6 sm6 class="text-md-left text-sm-center text-xs-center">
|
|
||||||
<v-btn class="WM-CyanBlueGradient-BG" style="padding:10px 60px" @click="handleSubmit">
|
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
|
||||||
<span class="white--text">Login</span>
|
|
||||||
</v-btn>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
<v-layout row wrap class="text-md-left text-sm-center text-xs-center">
|
|
||||||
<v-flex xs12 md12 sm12 class="px-4 py-3">
|
|
||||||
<router-link :to="{name: 'ForgotPassword'}">
|
|
||||||
<span class="black--text" style="border-bottom:1px solid #000;">Forgot Password ?</span>
|
|
||||||
</router-link>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
</material-card>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
</v-container>
|
|
||||||
</v-form>
|
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { mapGetters, mapActions } from "vuex";
|
import {mapGetters, mapActions} from "vuex";
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
cell_number: "",
|
|
||||||
password: "",
|
|
||||||
show1: false,
|
|
||||||
rules: {
|
|
||||||
required: value => !!value || "Required.",
|
|
||||||
passCounter: value => (value && value.length >= 8) || "Min 8 characters",
|
|
||||||
cellNumberCounter: value => (value && value.length == 11) || "must 11 characters"
|
|
||||||
}
|
|
||||||
};
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
...mapGetters('auth', [
|
|
||||||
'authenticating',
|
|
||||||
'authenticationError',
|
|
||||||
'authenticationErrorCode'
|
|
||||||
])
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
...mapActions('auth', [
|
|
||||||
'login'
|
|
||||||
]),
|
|
||||||
async handleSubmit() {
|
|
||||||
// Perform a simple validation that cell_number and password have been typed in
|
|
||||||
if (this.$refs.form.validate()) {
|
|
||||||
const response = await this.login({cell_number: this.cell_number, password: this.password});
|
|
||||||
|
|
||||||
if (!response.status || response.status !== 200) {
|
export default {
|
||||||
this.password = "";
|
metaInfo() {
|
||||||
}
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
}
|
data() {
|
||||||
|
return {
|
||||||
|
cell_number: "",
|
||||||
|
password: "",
|
||||||
|
show1: false,
|
||||||
|
rules: {
|
||||||
|
required: value => !!value || "Required.",
|
||||||
|
passCounter: value => (value && value.length >= 8) || "Min 8 characters",
|
||||||
|
cellNumberCounter: value => (value && value.length == 11) || "must 11 characters"
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
...mapGetters('auth', [
|
||||||
|
'authenticating',
|
||||||
|
'authenticationError',
|
||||||
|
'authenticationErrorCode'
|
||||||
|
])
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
...mapActions('auth', [
|
||||||
|
'login'
|
||||||
|
]),
|
||||||
|
async handleSubmit() {
|
||||||
|
// Perform a simple validation that cell_number and password have been typed in
|
||||||
|
if (this.$refs.form.validate()) {
|
||||||
|
const response = await this.login({cell_number: this.cell_number, password: this.password});
|
||||||
|
|
||||||
|
if (!response.status || response.status !== 200) {
|
||||||
|
this.password = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
+129
-123
@@ -1,133 +1,139 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-form ref="form">
|
<v-form ref="form">
|
||||||
<v-container grid-list-xs>
|
<v-container grid-list-xs>
|
||||||
<v-layout row wrap class="justify-center">
|
<v-layout row wrap class="justify-center">
|
||||||
<v-flex xs12 md3 sm6 class="WM-WidthScreen-SM WM-WidthScreen-XS">
|
<v-flex xs12 md3 sm6 class="WM-WidthScreen-SM WM-WidthScreen-XS">
|
||||||
<material-card color="black" title="Register Page">
|
<material-card color="black" title="Register Page">
|
||||||
<v-layout column>
|
<v-layout column>
|
||||||
<v-flex xs12 md2 sm2>
|
<v-flex xs12 md2 sm2>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
name="name"
|
name="name"
|
||||||
label="Name"
|
label="Name"
|
||||||
v-model="form.name"
|
v-model="form.name"
|
||||||
color="black"
|
color="black"
|
||||||
class="pa-2"
|
class="pa-2"
|
||||||
:rules="[rules.required, rules.nameCounter]"
|
:rules="[rules.required, rules.nameCounter]"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 md2 sm2>
|
<v-flex xs12 md2 sm2>
|
||||||
<v-select
|
<v-select
|
||||||
:items="items"
|
:items="items"
|
||||||
label="Gender"
|
label="Gender"
|
||||||
name="gender"
|
name="gender"
|
||||||
v-model="form.gender"
|
v-model="form.gender"
|
||||||
single-line
|
single-line
|
||||||
class="pa-2"
|
class="pa-2"
|
||||||
color="black"
|
color="black"
|
||||||
:rules="[rules.required]"
|
:rules="[rules.required]"
|
||||||
></v-select>
|
></v-select>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs2 md2 sm2>
|
<v-flex xs2 md2 sm2>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="form.country_code"
|
v-model="form.country_code"
|
||||||
name="country_code"
|
name="country_code"
|
||||||
label="Country Code"
|
label="Country Code"
|
||||||
color="black"
|
color="black"
|
||||||
:rules="[rules.required, rules.countryCode]"
|
:rules="[rules.required, rules.countryCode]"
|
||||||
mask="####"
|
mask="####"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs10 md10 sm10>
|
<v-flex xs10 md10 sm10>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
v-model="form.cell_number"
|
v-model="form.cell_number"
|
||||||
name="cellnumber"
|
name="cellnumber"
|
||||||
label="Cell Number"
|
label="Cell Number"
|
||||||
color="black"
|
color="black"
|
||||||
:rules="[rules.required, rules.cellNumberCounter]"
|
:rules="[rules.required, rules.cellNumberCounter]"
|
||||||
mask="#### ### ####"
|
mask="#### ### ####"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 md2 sm2>
|
<v-flex xs12 md2 sm2>
|
||||||
<v-text-field
|
<v-text-field
|
||||||
name="password"
|
name="password"
|
||||||
label="Password"
|
label="Password"
|
||||||
v-model="form.password"
|
v-model="form.password"
|
||||||
:type="show1 ? 'text' : 'password'"
|
:type="show1 ? 'text' : 'password'"
|
||||||
:append-icon="show1 ? 'visibility' : 'visibility_off'"
|
:append-icon="show1 ? 'visibility' : 'visibility_off'"
|
||||||
@click:append="show1 = !show1"
|
@click:append="show1 = !show1"
|
||||||
color="black"
|
color="black"
|
||||||
class="pa-2"
|
class="pa-2"
|
||||||
:rules="[rules.required, rules.passCounter]"
|
:rules="[rules.required, rules.passCounter]"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
<v-layout row wrap>
|
||||||
|
<v-flex xs12 md6 sm6 class="text-md-left text-sm-center text-xs-center">
|
||||||
|
<v-btn @click="register" class="WM-CyanBlueGradient-BG" style="padding:10px 60px">
|
||||||
|
<v-icon class="white--text mr-2 caption">fas fa-plus</v-icon>
|
||||||
|
<span class="white--text">Register</span>
|
||||||
|
</v-btn>
|
||||||
|
</v-flex>
|
||||||
|
<v-flex
|
||||||
|
v-if="!isLogin"
|
||||||
|
xs12
|
||||||
|
md6
|
||||||
|
sm6
|
||||||
|
class="text-md-right text-sm-center text-xs-center"
|
||||||
|
>
|
||||||
|
<router-link to="/login">
|
||||||
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
||||||
|
<v-icon class="black--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
||||||
|
<span class="black--text">Login</span>
|
||||||
|
</v-btn>
|
||||||
|
</router-link>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
</material-card>
|
||||||
|
</v-flex>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
<v-layout row wrap>
|
</v-container>
|
||||||
<v-flex xs12 md6 sm6 class="text-md-left text-sm-center text-xs-center">
|
</v-form>
|
||||||
<v-btn @click="register" class="WM-CyanBlueGradient-BG" style="padding:10px 60px">
|
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-plus</v-icon>
|
|
||||||
<span class="white--text">Register</span>
|
|
||||||
</v-btn>
|
|
||||||
</v-flex>
|
|
||||||
<v-flex
|
|
||||||
v-if="!isLogin"
|
|
||||||
xs12
|
|
||||||
md6
|
|
||||||
sm6
|
|
||||||
class="text-md-right text-sm-center text-xs-center"
|
|
||||||
>
|
|
||||||
<router-link to="/login">
|
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-sign-in-alt</v-icon>
|
|
||||||
<span class="black--text">Login</span>
|
|
||||||
</v-btn>
|
|
||||||
</router-link>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
</material-card>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
</v-container>
|
|
||||||
</v-form>
|
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { TokenService, ApiService } from "@/services";
|
import {TokenService, ApiService} from "@/services";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
metaInfo() {
|
||||||
const defaultForm = Object.freeze({
|
return {
|
||||||
cell_number: "",
|
title: this.$route.meta.title,
|
||||||
password: "",
|
meta: this.$route.meta.metaTags || []
|
||||||
name: "",
|
}
|
||||||
gender: "",
|
},
|
||||||
medical_center_id: this.$route.params.medicalCenter
|
data() {
|
||||||
? this.$route.params.medicalCenter
|
const defaultForm = Object.freeze({
|
||||||
: ''
|
cell_number: "",
|
||||||
});
|
password: "",
|
||||||
return {
|
name: "",
|
||||||
form: Object.assign({}, defaultForm),
|
gender: "",
|
||||||
show1: false,
|
medical_center_id: this.$route.params.medicalCenter
|
||||||
items: ["Male", "FeMale"],
|
? this.$route.params.medicalCenter
|
||||||
isLogin: TokenService.getInfo(),
|
: ''
|
||||||
rules: {
|
});
|
||||||
required: value => !!value || "Required.",
|
return {
|
||||||
nameCounter: value => (value && value.length >= 5) || "Min 5 characters",
|
form: Object.assign({}, defaultForm),
|
||||||
passCounter: value => (value && value.length >= 8) || "Min 8 characters",
|
show1: false,
|
||||||
cellNumberCounter: value => (value && value.length == 11) || "must 11 characters",
|
items: ["Male", "FeMale"],
|
||||||
countryCode: value => (value && value.length == 4) || "must 4 characters for example (0098)"
|
isLogin: TokenService.getInfo(),
|
||||||
}
|
rules: {
|
||||||
};
|
required: value => !!value || "Required.",
|
||||||
},
|
nameCounter: value => (value && value.length >= 5) || "Min 5 characters",
|
||||||
methods: {
|
passCounter: value => (value && value.length >= 8) || "Min 8 characters",
|
||||||
async register() {
|
cellNumberCounter: value => (value && value.length == 11) || "must 11 characters",
|
||||||
if (this.$refs.form.validate()) {
|
countryCode: value => (value && value.length == 4) || "must 4 characters for example (0098)"
|
||||||
var result = await ApiService.post(`register`, this.form);
|
}
|
||||||
if (result && result.status == 200) {
|
};
|
||||||
this.$router.push(
|
},
|
||||||
{name:`OperatorList`, params: { medicalCenter: this.form.medical_center_id }}
|
methods: {
|
||||||
);
|
async register() {
|
||||||
|
if (this.$refs.form.validate()) {
|
||||||
|
var result = await ApiService.post(`register`, this.form);
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.$router.push(
|
||||||
|
{name: `OperatorList`, params: {medicalCenter: this.form.medical_center_id}}
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -111,6 +111,12 @@ import {urls} from "@/config/urls";
|
|||||||
import {mapMutations} from "vuex";
|
import {mapMutations} from "vuex";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
fromMenuDate: false,
|
fromMenuDate: false,
|
||||||
|
|||||||
@@ -143,6 +143,12 @@ import {urls} from "@/config/urls";
|
|||||||
import {mapMutations, mapGetters} from "vuex";
|
import {mapMutations, mapGetters} from "vuex";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{sortable: false, text: "ID", value: "Cycle ID"},
|
{sortable: false, text: "ID", value: "Cycle ID"},
|
||||||
|
|||||||
@@ -54,6 +54,12 @@
|
|||||||
<script>
|
<script>
|
||||||
// import { UserService } from '@/services';
|
// import { UserService } from '@/services';
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
AdminCards: [
|
AdminCards: [
|
||||||
|
|||||||
+155
-164
@@ -1,178 +1,169 @@
|
|||||||
<template id="">
|
<template id="">
|
||||||
<div class="">
|
<div class="">
|
||||||
<v-toolbar color="white">
|
<v-toolbar color="white">
|
||||||
<v-toolbar-title v-text="title"></v-toolbar-title>
|
<v-toolbar-title v-text="title"></v-toolbar-title>
|
||||||
</v-toolbar>
|
</v-toolbar>
|
||||||
<!-- _______________ Section 2::Begin _______________ -->
|
<!-- _______________ Section 2::Begin _______________ -->
|
||||||
<section>
|
<section>
|
||||||
<v-parallax src="https://images.squarespace-cdn.com/content/v1/5bf5d5da506fbea76ffa4abe/1547249524951-CQ5U440SQYT23ODKL23G/ke17ZwdGBToddI8pDm48kKAwwdAfKsTlKsCcElEApLR7gQa3H78H3Y0txjaiv_0fDoOvxcdMmMKkDsyUqMSsMWxHk725yiiHCCLfrh8O1z5QPOohDIaIeljMHgDF5CVlOqpeNLcJ80NK65_fV7S1UegTYNQkRo-Jk4EWsyBNhwKrKLo5CceA1-Tdpfgyxoog5ck0MD3_q0rY3jFJjjoLbQ/yenyi.jpg" height="600">
|
<v-parallax
|
||||||
<v-layout
|
src="https://images.squarespace-cdn.com/content/v1/5bf5d5da506fbea76ffa4abe/1547249524951-CQ5U440SQYT23ODKL23G/ke17ZwdGBToddI8pDm48kKAwwdAfKsTlKsCcElEApLR7gQa3H78H3Y0txjaiv_0fDoOvxcdMmMKkDsyUqMSsMWxHk725yiiHCCLfrh8O1z5QPOohDIaIeljMHgDF5CVlOqpeNLcJ80NK65_fV7S1UegTYNQkRo-Jk4EWsyBNhwKrKLo5CceA1-Tdpfgyxoog5ck0MD3_q0rY3jFJjjoLbQ/yenyi.jpg"
|
||||||
column
|
height="600">
|
||||||
align-center
|
<v-layout
|
||||||
justify-center
|
column
|
||||||
class="white--text"
|
align-center
|
||||||
>
|
justify-center
|
||||||
<!-- <img src="assets/vuetify.png" alt="Vuetify.js" height="200"> -->
|
class="white--text"
|
||||||
<p class="display-4 mb-5">CSSD-DOC</p>
|
>
|
||||||
<h1 class="white--text mb-2 mt-5 display-1 text-center">Central Sterile Supply Department App & Software</h1>
|
<!-- <img src="assets/vuetify.png" alt="Vuetify.js" height="200"> -->
|
||||||
<div class="subheading mb-4 text-center">Management & Traceability & Documentation solution for CSSD / SPD</div>
|
<p class="display-4 mb-5">CSSD-DOC</p>
|
||||||
</v-layout>
|
<h1 class="white--text mb-2 mt-5 display-1 text-center">Central Sterile Supply Department App &
|
||||||
</v-parallax>
|
Software</h1>
|
||||||
</section>
|
<div class="subheading mb-4 text-center">Management & Traceability & Documentation solution for CSSD
|
||||||
<section>
|
/ SPD
|
||||||
<v-layout
|
</div>
|
||||||
column
|
</v-layout>
|
||||||
wrap
|
</v-parallax>
|
||||||
class="my-12"
|
</section>
|
||||||
align-center
|
<section>
|
||||||
>
|
<v-layout
|
||||||
<v-flex xs12 sm4 class="my-4">
|
column
|
||||||
<div class="text-center">
|
wrap
|
||||||
<h2 class="headline">-Sterilization process monitoring</h2>
|
class="my-12"
|
||||||
<span class="subheading">
|
align-center
|
||||||
|
>
|
||||||
|
<v-flex xs12 sm4 class="my-4">
|
||||||
|
<div class="text-center">
|
||||||
|
<h2 class="headline">-Sterilization process monitoring</h2>
|
||||||
|
<span class="subheading">
|
||||||
- Sterilizer test records
|
- Sterilizer test records
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12>
|
<v-flex xs12>
|
||||||
<v-container grid-list-xl>
|
<v-container grid-list-xl>
|
||||||
<v-layout row wrap align-left>
|
<v-layout row wrap align-left>
|
||||||
<v-flex xs12 md4>
|
<v-flex xs12 md4>
|
||||||
<v-card flat class="transparent">
|
<v-card flat class="transparent">
|
||||||
<p v-for="(item , i) in items.items1" :key="i" class="headline text-left">item</p>
|
<p v-for="(item , i) in items.items1" :key="i" class="headline text-left">item</p>
|
||||||
</v-card>
|
</v-card>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 md4>
|
<v-flex xs12 md4>
|
||||||
<v-card flat class="transparent">
|
<v-card flat class="transparent">
|
||||||
<p v-for="(item , i) in items.items2" :key="i" class="headline text-left">item</p>
|
<p v-for="(item , i) in items.items2" :key="i" class="headline text-left">item</p>
|
||||||
</v-card>
|
</v-card>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 md4>
|
<v-flex xs12 md4>
|
||||||
<v-card flat class="transparent">
|
<v-card flat class="transparent">
|
||||||
<p v-for="(item , i) in items.items3" :key="i" class="headline text-left" v-text="item"></p>
|
<p v-for="(item , i) in items.items3" :key="i" class="headline text-left"
|
||||||
</v-card>
|
v-text="item"></p>
|
||||||
</v-flex>
|
</v-card>
|
||||||
</v-layout>
|
</v-flex>
|
||||||
</v-container>
|
</v-layout>
|
||||||
</v-flex>
|
</v-container>
|
||||||
</v-layout>
|
</v-flex>
|
||||||
</section>
|
</v-layout>
|
||||||
<!-- _______________ Section 2::End _______________ -->
|
</section>
|
||||||
|
<!-- _______________ Section 2::End _______________ -->
|
||||||
|
|
||||||
<!-- _______________ Section 7::Begin _______________ -->
|
<!-- _______________ Section 7::Begin _______________ -->
|
||||||
<section>
|
<section>
|
||||||
<v-layout
|
<v-layout
|
||||||
column
|
column
|
||||||
wrap
|
wrap
|
||||||
class="my-12"
|
class="my-12"
|
||||||
align-center
|
align-center
|
||||||
>
|
>
|
||||||
<v-flex xs12 sm4 class="my-4">
|
<v-flex xs12 sm4 class="my-4">
|
||||||
<div class="text-center">
|
<div class="text-center">
|
||||||
<h2 class="headline">Product identification and traceability</h2>
|
<h2 class="headline">Product identification and traceability</h2>
|
||||||
<span class="subheading">
|
<span class="subheading">
|
||||||
Cras facilisis mi vitae nunc
|
Cras facilisis mi vitae nunc
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12>
|
<v-flex xs12>
|
||||||
<v-container grid-list-xl>
|
<v-container grid-list-xl>
|
||||||
<v-layout row wrap align-center>
|
<v-layout row wrap align-center>
|
||||||
<v-flex xs12 md4>
|
<v-flex xs12 md4>
|
||||||
<v-card flat class="transparent">
|
<v-card flat class="transparent">
|
||||||
<v-card-text class="text-center">
|
<v-card-text class="text-center">
|
||||||
<v-icon x-large class="blue--text text--lighten-2">mdi-palette</v-icon>
|
<v-icon x-large class="blue--text text--lighten-2">mdi-palette</v-icon>
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
<v-card-title primary-title class="layout justify-center">
|
<v-card-title primary-title class="layout justify-center">
|
||||||
<div class="headline text-center">Item</div>
|
<div class="headline text-center">Item</div>
|
||||||
</v-card-title>
|
</v-card-title>
|
||||||
<v-card-text>
|
<v-card-text>
|
||||||
Define and identify every instrument.
|
Define and identify every instrument.
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
</v-card>
|
</v-card>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 md4>
|
<v-flex xs12 md4>
|
||||||
<v-card flat class="transparent">
|
<v-card flat class="transparent">
|
||||||
<v-card-text class="text-center">
|
<v-card-text class="text-center">
|
||||||
<v-icon x-large class="blue--text text--lighten-2">mdi-flash</v-icon>
|
<v-icon x-large class="blue--text text--lighten-2">mdi-flash</v-icon>
|
||||||
</v-card-text>
|
</v-card-text>
|
||||||
<v-card-title primary-title class="layout justify-center">
|
<v-card-title primary-title class="layout justify-center">
|
||||||
<div class="headline">Fast development</div>
|
<div class="headline">Fast development</div>
|
||||||
</v-card-title>
|
</v-card-title>
|
||||||
<v-card-text>
|
<v-card-text>
|
||||||
Cras facilisis mi vitae nunc lobortis pharetra. Nulla volutpat tincidunt ornare.
|
Cras facilisis mi vitae nunc lobortis pharetra. Nulla volutpat tincidunt ornare.
|
||||||
Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas.
|
Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac
|
||||||
Nullam in aliquet odio. Aliquam eu est vitae tellus bibendum tincidunt. Suspendisse potenti.
|
turpis egestas.
|
||||||
</v-card-text>
|
Nullam in aliquet odio. Aliquam eu est vitae tellus bibendum tincidunt.
|
||||||
</v-card>
|
Suspendisse potenti.
|
||||||
</v-flex>
|
</v-card-text>
|
||||||
<v-flex xs12 md4>
|
</v-card>
|
||||||
<v-card flat class="transparent">
|
</v-flex>
|
||||||
<v-card-text class="text-center">
|
<v-flex xs12 md4>
|
||||||
<v-icon x-large class="blue--text text--lighten-2">mdi-wrench</v-icon>
|
<v-card flat class="transparent">
|
||||||
</v-card-text>
|
<v-card-text class="text-center">
|
||||||
<v-card-title primary-title class="layout justify-center">
|
<v-icon x-large class="blue--text text--lighten-2">mdi-wrench</v-icon>
|
||||||
<div class="headline text-center">Completely Open Sourced</div>
|
</v-card-text>
|
||||||
</v-card-title>
|
<v-card-title primary-title class="layout justify-center">
|
||||||
<v-card-text>
|
<div class="headline text-center">Completely Open Sourced</div>
|
||||||
Cras facilisis mi vitae nunc lobortis pharetra. Nulla volutpat tincidunt ornare.
|
</v-card-title>
|
||||||
Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas.
|
<v-card-text>
|
||||||
Nullam in aliquet odio. Aliquam eu est vitae tellus bibendum tincidunt. Suspendisse potenti.
|
Cras facilisis mi vitae nunc lobortis pharetra. Nulla volutpat tincidunt ornare.
|
||||||
</v-card-text>
|
Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac
|
||||||
</v-card>
|
turpis egestas.
|
||||||
</v-flex>
|
Nullam in aliquet odio. Aliquam eu est vitae tellus bibendum tincidunt.
|
||||||
</v-layout>
|
Suspendisse potenti.
|
||||||
</v-container>
|
</v-card-text>
|
||||||
</v-flex>
|
</v-card>
|
||||||
</v-layout>
|
</v-flex>
|
||||||
</section>
|
</v-layout>
|
||||||
|
</v-container>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
</section>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data: () => ({
|
|
||||||
items: [
|
|
||||||
{
|
|
||||||
items1 : [
|
|
||||||
'aaaaa',
|
|
||||||
'aaaaa',
|
|
||||||
'aaaaaa'
|
|
||||||
],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
items2 : [
|
|
||||||
'aaaaa',
|
|
||||||
'aaaaa',
|
|
||||||
'aaaaaa'
|
|
||||||
],
|
|
||||||
},
|
|
||||||
{
|
|
||||||
items3 : [
|
|
||||||
'aaaaa',
|
|
||||||
'aaaaa',
|
|
||||||
'aaaaaa'
|
|
||||||
],
|
|
||||||
},
|
|
||||||
],
|
|
||||||
disabled: false,
|
|
||||||
dense: false,
|
|
||||||
twoLine: false,
|
|
||||||
threeLine: false,
|
|
||||||
shaped: false,
|
|
||||||
flat: false,
|
|
||||||
subheader: false,
|
|
||||||
inactive: false,
|
|
||||||
subGroup: false,
|
|
||||||
nav: false,
|
|
||||||
avatar: false,
|
|
||||||
rounded: false,
|
|
||||||
}),
|
|
||||||
components: {
|
|
||||||
|
|
||||||
},
|
data: () => ({
|
||||||
created(){
|
items: [
|
||||||
},
|
{items1: ['aaaaa', 'aaaaa', 'aaaaaa'],},
|
||||||
|
{items2: ['aaaaa', 'aaaaa', 'aaaaaa'],},
|
||||||
|
{items3: ['aaaaa', 'aaaaa', 'aaaaaa'],},
|
||||||
|
],
|
||||||
|
disabled: false,
|
||||||
|
dense: false,
|
||||||
|
twoLine: false,
|
||||||
|
threeLine: false,
|
||||||
|
shaped: false,
|
||||||
|
flat: false,
|
||||||
|
subheader: false,
|
||||||
|
inactive: false,
|
||||||
|
subGroup: false,
|
||||||
|
nav: false,
|
||||||
|
avatar: false,
|
||||||
|
rounded: false,
|
||||||
|
}),
|
||||||
|
components: {},
|
||||||
|
created() {
|
||||||
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -79,6 +79,12 @@ import {mapMutations} from 'vuex';
|
|||||||
import Dropzone from '@/components/core/Dropzone'
|
import Dropzone from '@/components/core/Dropzone'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
components: {
|
components: {
|
||||||
'wm-Dropzone': Dropzone,
|
'wm-Dropzone': Dropzone,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -157,6 +157,12 @@ import {mapMutations, mapGetters} from "vuex";
|
|||||||
import toast from "@/services/global/toast.service";
|
import toast from "@/services/global/toast.service";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
// {sortable: true,text: "ID",value: "id"},
|
// {sortable: true,text: "ID",value: "id"},
|
||||||
|
|||||||
+152
-143
@@ -1,61 +1,63 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-form ref="form">
|
<v-form ref="form">
|
||||||
<v-container grid-list-xs fluid>
|
<v-container grid-list-xs fluid>
|
||||||
<material-card color="black" title="Add Label on Set ">
|
<material-card color="black" title="Add Label on Set ">
|
||||||
<v-layout wrap class="px-5 my-3">
|
<v-layout wrap class="px-5 my-3">
|
||||||
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
||||||
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"/>
|
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"/>
|
||||||
<v-text-field name="sterilizerId" label="Sterilizer ID" color="black"
|
<v-text-field name="sterilizerId" label="Sterilizer ID" color="black"
|
||||||
v-model="formData.sterilizer_id" class="py-3 pr-3"/>
|
v-model="formData.sterilizer_id" class="py-3 pr-3"/>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
||||||
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"/>
|
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"/>
|
||||||
<v-text-field name="cycle_number" label="Preferred Cycle Number" color="black" v-model="formData.cycle_number"
|
<v-text-field name="cycle_number" label="Preferred Cycle Number" color="black"
|
||||||
class="py-3 pr-3"/>
|
v-model="formData.cycle_number"
|
||||||
</v-flex>
|
class="py-3 pr-3"/>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
</v-flex>
|
||||||
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"/>
|
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
||||||
<v-text-field name="lot_number" label="Lot Number" color="black" readonly v-model="lotNumber"
|
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"/>
|
||||||
class="py-3 pr-3"/>
|
<v-text-field name="lot_number" label="Lot Number" color="black" readonly v-model="lotNumber"
|
||||||
</v-flex>
|
class="py-3 pr-3"/>
|
||||||
<v-spacer/>
|
</v-flex>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter">
|
<v-spacer/>
|
||||||
<v-icon class="fas fa-check mr-2 WM-Margin-B-8"/>
|
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter">
|
||||||
<v-autocomplete color="black" :items="items" item-text="name" v-model="formData.package_id"
|
<v-icon class="fas fa-check mr-2 WM-Margin-B-8"/>
|
||||||
item-value="id" label="Package ID" class="py-3 pr-3" :filter="customFilter">
|
<v-autocomplete color="black" :items="items" item-text="name" v-model="formData.package_id"
|
||||||
<template v-slot:chip="{ item }">
|
item-value="id" label="Package ID" class="py-3 pr-3" :filter="customFilter">
|
||||||
{{ item.name }} - {{ item.id }}
|
<template v-slot:chip="{ item }">
|
||||||
</template>
|
{{ item.name }} - {{ item.id }}
|
||||||
|
</template>
|
||||||
|
|
||||||
<template v-slot:item="{ item }">
|
<template v-slot:item="{ item }">
|
||||||
{{ item.name }} - {{ item.id }}
|
{{ item.name }} - {{ item.id }}
|
||||||
</template>
|
</template>
|
||||||
</v-autocomplete>
|
</v-autocomplete>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
||||||
<v-icon class="far fa-calendar-alt mr-2"/>
|
<v-icon class="far fa-calendar-alt mr-2"/>
|
||||||
<v-menu lazy :close-on-content-click="true" transition="v-scale-transition" offset-y
|
<v-menu lazy :close-on-content-click="true" transition="v-scale-transition" offset-y
|
||||||
v-model="fromMenuSterile" style="width: 100%">
|
v-model="fromMenuSterile" style="width: 100%">
|
||||||
<v-text-field required slot="activator" label="Sterile Date" color="black" class="pr-3"
|
<v-text-field required slot="activator" label="Sterile Date" color="black" class="pr-3"
|
||||||
v-model="formData.sterile_date"/>
|
v-model="formData.sterile_date"/>
|
||||||
<v-date-picker color="pink" :min="today" no-title v-model="formData.sterile_date"
|
<v-date-picker color="pink" :min="today" no-title v-model="formData.sterile_date"
|
||||||
:date-format="date => new Date(date).toDateString()"/>
|
:date-format="date => new Date(date).toDateString()"/>
|
||||||
</v-menu>
|
</v-menu>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
<v-flex xs12 sm6 md4 lg3 class="WM-FlexCenter pl-3">
|
||||||
<v-icon class="far fa-calendar-alt mr-2"/>
|
<v-icon class="far fa-calendar-alt mr-2"/>
|
||||||
<v-menu lazy :close-on-content-click="true" transition="v-scale-transition" offset-y
|
<v-menu lazy :close-on-content-click="true" transition="v-scale-transition" offset-y
|
||||||
v-model="fromMenuExpire" style="width: 100%">
|
v-model="fromMenuExpire" style="width: 100%">
|
||||||
<v-text-field required slot="activator" label="Expire Date" color="black" class="pr-3"
|
<v-text-field required slot="activator" label="Expire Date" color="black" class="pr-3"
|
||||||
v-model="formData.expire_date"/>
|
v-model="formData.expire_date"/>
|
||||||
<v-date-picker :show-current="showCurrent" :min="formData.sterile_date" color="pink" no-title
|
<v-date-picker :show-current="showCurrent" :min="formData.sterile_date" color="pink"
|
||||||
v-model="formData.expire_date"
|
no-title
|
||||||
:date-format="date => new Date(date).toDateString()"/>
|
v-model="formData.expire_date"
|
||||||
</v-menu>
|
:date-format="date => new Date(date).toDateString()"/>
|
||||||
</v-flex>
|
</v-menu>
|
||||||
</v-layout>
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
|
||||||
<v-layout row wrap justify-center align-center>
|
<v-layout row wrap justify-center align-center>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="text-md-center text-sm-center text-xs-center">
|
<v-flex xs12 sm6 md4 lg3 class="text-md-center text-sm-center text-xs-center">
|
||||||
<router-link :to="{ name: 'AllLabels' }">
|
<router-link :to="{ name: 'AllLabels' }">
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
||||||
@@ -64,108 +66,115 @@
|
|||||||
</v-btn>
|
</v-btn>
|
||||||
</router-link>
|
</router-link>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-flex xs12 sm6 md4 lg3 class="text-md-center text-xs-center">
|
<v-flex xs12 sm6 md4 lg3 class="text-md-center text-xs-center">
|
||||||
<v-btn class="WM-CyanBlueGradient-BG" style="padding:10px 60px" @click="submitForm()">
|
<v-btn class="WM-CyanBlueGradient-BG" style="padding:10px 60px" @click="submitForm()">
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-check</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-check</v-icon>
|
||||||
<span class="white--text">SAVE</span>
|
<span class="white--text">SAVE</span>
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
</material-card>
|
</material-card>
|
||||||
</v-container>
|
</v-container>
|
||||||
</v-form>
|
</v-form>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { ApiService } from "@/services";
|
import {ApiService} from "@/services";
|
||||||
import { urls } from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
showCurrent: false,
|
|
||||||
fromMenuSterile: false,
|
|
||||||
fromMenuExpire: false,
|
|
||||||
today: new Date().toISOString().split("T")[0],
|
|
||||||
formData: {
|
|
||||||
result: "",
|
|
||||||
package_id: "",
|
|
||||||
expire_date: null,
|
|
||||||
sterilizer_id: '',
|
|
||||||
cycle_number: '',
|
|
||||||
sterile_date: new Date().toISOString().substr(0, 10)
|
|
||||||
},
|
|
||||||
items: [],
|
|
||||||
rules: {
|
|
||||||
required: value => !!value || "Required.",
|
|
||||||
counter: value =>
|
|
||||||
!value ||
|
|
||||||
value.length == 0 ||
|
|
||||||
value.length >= 5 ||
|
|
||||||
"Min 5 characters"
|
|
||||||
}
|
|
||||||
};
|
|
||||||
},
|
|
||||||
created() {
|
|
||||||
if (this.$route.params.label) {
|
|
||||||
this.load(this.$route.params.label);
|
|
||||||
}
|
|
||||||
this.loadItems();
|
|
||||||
},
|
|
||||||
computed: {
|
|
||||||
lotNumber() {
|
|
||||||
return this.formData.sterilizer_id + ' - ' + this.formData.cycle_number;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
customFilter(item, queryText) {
|
|
||||||
const name = item.name.toLowerCase();
|
|
||||||
const udi = item.udi ? item.udi.toLowerCase() : null;
|
|
||||||
const searchText = queryText.toLowerCase();
|
|
||||||
if (udi) {
|
|
||||||
return name.indexOf(searchText) > -1 ||
|
|
||||||
udi.indexOf(searchText) > -1
|
|
||||||
}
|
|
||||||
return name.indexOf(searchText) > -1
|
|
||||||
},
|
|
||||||
async load(id) {
|
|
||||||
const result = await ApiService.get(urls.editLabel(id));
|
|
||||||
if (result && result.status == 200) {
|
|
||||||
this.formData = result.data.data;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async loadItems() {
|
|
||||||
const result = await ApiService.get(urls.listAllPackage());
|
|
||||||
if (result && result.status == 200) {
|
|
||||||
this.items = result.data.data;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async submitForm() {
|
|
||||||
let result;
|
|
||||||
this.formData['lot_number'] = this.lotNumber;
|
|
||||||
if (this.$route.params.label) {
|
|
||||||
result = await ApiService.put(urls.updateLabel(this.$route.params.label), this.formData);
|
|
||||||
} else {
|
|
||||||
result = await ApiService.post(urls.storeLabel, this.formData);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (result && result.status == 200) {
|
export default {
|
||||||
this.$router.push({ name: 'AllLabels' });
|
metaInfo() {
|
||||||
}
|
return {
|
||||||
}
|
title: this.$route.meta.title,
|
||||||
}
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
showCurrent: false,
|
||||||
|
fromMenuSterile: false,
|
||||||
|
fromMenuExpire: false,
|
||||||
|
today: new Date().toISOString().split("T")[0],
|
||||||
|
formData: {
|
||||||
|
result: "",
|
||||||
|
package_id: "",
|
||||||
|
expire_date: null,
|
||||||
|
sterilizer_id: '',
|
||||||
|
cycle_number: '',
|
||||||
|
sterile_date: new Date().toISOString().substr(0, 10)
|
||||||
|
},
|
||||||
|
items: [],
|
||||||
|
rules: {
|
||||||
|
required: value => !!value || "Required.",
|
||||||
|
counter: value =>
|
||||||
|
!value ||
|
||||||
|
value.length == 0 ||
|
||||||
|
value.length >= 5 ||
|
||||||
|
"Min 5 characters"
|
||||||
|
}
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
if (this.$route.params.label) {
|
||||||
|
this.load(this.$route.params.label);
|
||||||
|
}
|
||||||
|
this.loadItems();
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
lotNumber() {
|
||||||
|
return this.formData.sterilizer_id + ' - ' + this.formData.cycle_number;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
customFilter(item, queryText) {
|
||||||
|
const name = item.name.toLowerCase();
|
||||||
|
const udi = item.udi ? item.udi.toLowerCase() : null;
|
||||||
|
const searchText = queryText.toLowerCase();
|
||||||
|
if (udi) {
|
||||||
|
return name.indexOf(searchText) > -1 ||
|
||||||
|
udi.indexOf(searchText) > -1
|
||||||
|
}
|
||||||
|
return name.indexOf(searchText) > -1
|
||||||
|
},
|
||||||
|
async load(id) {
|
||||||
|
const result = await ApiService.get(urls.editLabel(id));
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.formData = result.data.data;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async loadItems() {
|
||||||
|
const result = await ApiService.get(urls.listAllPackage());
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.items = result.data.data;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async submitForm() {
|
||||||
|
let result;
|
||||||
|
this.formData['lot_number'] = this.lotNumber;
|
||||||
|
if (this.$route.params.label) {
|
||||||
|
result = await ApiService.put(urls.updateLabel(this.$route.params.label), this.formData);
|
||||||
|
} else {
|
||||||
|
result = await ApiService.post(urls.storeLabel, this.formData);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.$router.push({name: 'AllLabels'});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style>
|
<style>
|
||||||
.v-btn--floating {
|
.v-btn--floating {
|
||||||
padding: 0 !important;
|
padding: 0 !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.theme--light.v-btn.v-btn--flat {
|
.theme--light.v-btn.v-btn--flat {
|
||||||
color: rgba(0, 0, 0, .87) !important;
|
color: rgba(0, 0, 0, .87) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.v-btn--floating,
|
.v-btn--floating,
|
||||||
.v-btn--icon:before {
|
.v-btn--icon:before {
|
||||||
border-radius: 50% !important;
|
border-radius: 50% !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -145,6 +145,12 @@ import {urls} from "@/config/urls";
|
|||||||
import {mapMutations, mapGetters} from "vuex";
|
import {mapMutations, mapGetters} from "vuex";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{sortable: false, text: "ID", value: "Label ID"},
|
{sortable: false, text: "ID", value: "Label ID"},
|
||||||
|
|||||||
@@ -71,6 +71,12 @@ import {ApiService} from "@/services";
|
|||||||
import {urls} from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
medicalCenter: {
|
medicalCenter: {
|
||||||
|
|||||||
+147
-137
@@ -1,154 +1,164 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-container fluid>
|
<v-container fluid>
|
||||||
<material-card class color="black" title="Medical Centers List" text>
|
<material-card class color="black" title="Medical Centers List" text>
|
||||||
<v-layout wrap class="px-5 mb-3">
|
<v-layout wrap class="px-5 mb-3">
|
||||||
<v-flex xs12 md3 sm3 class="pr-3">
|
<v-flex xs12 md3 sm3 class="pr-3">
|
||||||
<v-text-field label="Name" v-model="filter.name" color="black"/>
|
<v-text-field label="Name" v-model="filter.name" color="black"/>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
<v-spacer/>
|
<v-spacer/>
|
||||||
<v-flex class xs12 sm6 md6 lg2 xl1>
|
<v-flex class xs12 sm6 md6 lg2 xl1>
|
||||||
<v-btn class="WM-CyanBlueGradient-BG" style="padding:10px 30px" @click="load()">
|
<v-btn class="WM-CyanBlueGradient-BG" style="padding:10px 30px" @click="load()">
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-search</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-search</v-icon>
|
||||||
<span class="white--text">Filter</span>
|
<span class="white--text">Filter</span>
|
||||||
</v-btn>
|
|
||||||
</v-flex>
|
|
||||||
<v-flex xs12 sm6 md6 lg1 xl1 class="text-xs-right">
|
|
||||||
<router-link :to="{ name: 'AddMedicalCenter' }">
|
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-plus</v-icon>
|
|
||||||
<span class="black--text">Add</span>
|
|
||||||
</v-btn>
|
|
||||||
</router-link>
|
|
||||||
</v-flex>
|
|
||||||
</v-layout>
|
|
||||||
<v-layout class="px-4 my-3">
|
|
||||||
<v-divider/>
|
|
||||||
</v-layout>
|
|
||||||
<v-layout align-center justify-center wrap class="px-5 mt-3">
|
|
||||||
<v-flex md12>
|
|
||||||
<v-data-table :headers="headers" :items="items" hide-actions>
|
|
||||||
<template slot="headerCell" slot-scope="{ header }">
|
|
||||||
<span class="subheading font-weight-light text-white text--darken-3" v-text="header.text" />
|
|
||||||
</template>
|
|
||||||
<template slot="items" slot-scope="{ item }">
|
|
||||||
<td class="title font-weight-light WM-NoLetterSpacing">{{ item.name }}</td>
|
|
||||||
<td class="title font-weight-light">{{ $d(new Date(item.created_at), 'long') }}</td>
|
|
||||||
<td class="title font-weight-light">{{ item.users_count }} Operator</td>
|
|
||||||
<td class="text-xs-right FlexBtn Height-MD-80 Height-SM-48 justify-self-end">
|
|
||||||
<v-tooltip bottom open-on-hover>
|
|
||||||
<template v-slot:activator="{ on, attrs }">
|
|
||||||
<router-link class="LinkBtn"
|
|
||||||
:to="{ name: 'EditMedicalCenter', params: { medicalCenter: item.id } }">
|
|
||||||
<v-btn v-bind="attrs" v-on="on" color="cyan" class="mr-2 WM-ActionButton">
|
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-pen</v-icon>
|
|
||||||
<span>Edit</span>
|
|
||||||
</v-btn>
|
|
||||||
</router-link>
|
|
||||||
</template>
|
|
||||||
<span>Edit</span>
|
|
||||||
</v-tooltip>
|
|
||||||
<v-tooltip bottom open-on-hover>
|
|
||||||
<template v-slot:activator="{ on, attrs }">
|
|
||||||
<router-link class="LinkBtn" :to="{ name: 'OperatorList', params: { medicalCenter: item.id } }">
|
|
||||||
<v-btn v-bind="attrs" v-on="on" color="orange darken-1" class="mr-2 WM-ActionButton">
|
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-user</v-icon>
|
|
||||||
<span>Operator</span>
|
|
||||||
</v-btn>
|
|
||||||
</router-link>
|
|
||||||
</template>
|
|
||||||
<span>Operator</span>
|
|
||||||
</v-tooltip>
|
|
||||||
<v-tooltip bottom open-on-hover>
|
|
||||||
<template v-slot:activator="{ on, attrs }">
|
|
||||||
<v-btn v-bind="attrs" v-on="on" color="pink" @click="remove(item.id)" class="WM-ActionButton">
|
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-trash</v-icon>
|
|
||||||
<span>Remove</span>
|
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</template>
|
</v-flex>
|
||||||
<span>Remove</span>
|
<v-flex xs12 sm6 md6 lg1 xl1 class="text-xs-right">
|
||||||
</v-tooltip>
|
<router-link :to="{ name: 'AddMedicalCenter' }">
|
||||||
</td>
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
||||||
</template>
|
<v-icon class="black--text mr-2 caption">fas fa-plus</v-icon>
|
||||||
</v-data-table>
|
<span class="black--text">Add</span>
|
||||||
</v-flex>
|
</v-btn>
|
||||||
</v-layout>
|
</router-link>
|
||||||
<v-divider/>
|
</v-flex>
|
||||||
<div class="text-xs-center mt-2" v-if="lastPage > 1">
|
</v-layout>
|
||||||
<v-pagination color="black" v-model="currentPage" :length="lastPage" :total-visible="6"></v-pagination>
|
<v-layout class="px-4 my-3">
|
||||||
</div>
|
<v-divider/>
|
||||||
<v-layout row wrap align-center justify-center class="mt-3">
|
</v-layout>
|
||||||
<router-link :to="{ name: 'Dashboard' }">
|
<v-layout align-center justify-center wrap class="px-5 mt-3">
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black ml-5">
|
<v-flex md12>
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-chevron-left</v-icon>
|
<v-data-table :headers="headers" :items="items" hide-actions>
|
||||||
<span class="black--text">Back</span>
|
<template slot="headerCell" slot-scope="{ header }">
|
||||||
</v-btn>
|
<span class="subheading font-weight-light text-white text--darken-3" v-text="header.text"/>
|
||||||
</router-link>
|
</template>
|
||||||
</v-layout>
|
<template slot="items" slot-scope="{ item }">
|
||||||
</material-card>
|
<td class="title font-weight-light WM-NoLetterSpacing">{{ item.name }}</td>
|
||||||
</v-container>
|
<td class="title font-weight-light">{{ $d(new Date(item.created_at), 'long') }}</td>
|
||||||
|
<td class="title font-weight-light">{{ item.users_count }} Operator</td>
|
||||||
|
<td class="text-xs-right FlexBtn Height-MD-80 Height-SM-48 justify-self-end">
|
||||||
|
<v-tooltip bottom open-on-hover>
|
||||||
|
<template v-slot:activator="{ on, attrs }">
|
||||||
|
<router-link class="LinkBtn"
|
||||||
|
:to="{ name: 'EditMedicalCenter', params: { medicalCenter: item.id } }">
|
||||||
|
<v-btn v-bind="attrs" v-on="on" color="cyan" class="mr-2 WM-ActionButton">
|
||||||
|
<v-icon class="white--text mr-2 caption">fas fa-pen</v-icon>
|
||||||
|
<span>Edit</span>
|
||||||
|
</v-btn>
|
||||||
|
</router-link>
|
||||||
|
</template>
|
||||||
|
<span>Edit</span>
|
||||||
|
</v-tooltip>
|
||||||
|
<v-tooltip bottom open-on-hover>
|
||||||
|
<template v-slot:activator="{ on, attrs }">
|
||||||
|
<router-link class="LinkBtn"
|
||||||
|
:to="{ name: 'OperatorList', params: { medicalCenter: item.id } }">
|
||||||
|
<v-btn v-bind="attrs" v-on="on" color="orange darken-1"
|
||||||
|
class="mr-2 WM-ActionButton">
|
||||||
|
<v-icon class="white--text mr-2 caption">fas fa-user</v-icon>
|
||||||
|
<span>Operator</span>
|
||||||
|
</v-btn>
|
||||||
|
</router-link>
|
||||||
|
</template>
|
||||||
|
<span>Operator</span>
|
||||||
|
</v-tooltip>
|
||||||
|
<v-tooltip bottom open-on-hover>
|
||||||
|
<template v-slot:activator="{ on, attrs }">
|
||||||
|
<v-btn v-bind="attrs" v-on="on" color="pink" @click="remove(item.id)"
|
||||||
|
class="WM-ActionButton">
|
||||||
|
<v-icon class="white--text mr-2 caption">fas fa-trash</v-icon>
|
||||||
|
<span>Remove</span>
|
||||||
|
</v-btn>
|
||||||
|
</template>
|
||||||
|
<span>Remove</span>
|
||||||
|
</v-tooltip>
|
||||||
|
</td>
|
||||||
|
</template>
|
||||||
|
</v-data-table>
|
||||||
|
</v-flex>
|
||||||
|
</v-layout>
|
||||||
|
<v-divider/>
|
||||||
|
<div class="text-xs-center mt-2" v-if="lastPage > 1">
|
||||||
|
<v-pagination color="black" v-model="currentPage" :length="lastPage" :total-visible="6"></v-pagination>
|
||||||
|
</div>
|
||||||
|
<v-layout row wrap align-center justify-center class="mt-3">
|
||||||
|
<router-link :to="{ name: 'Dashboard' }">
|
||||||
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black ml-5">
|
||||||
|
<v-icon class="black--text mr-2 caption">fas fa-chevron-left</v-icon>
|
||||||
|
<span class="black--text">Back</span>
|
||||||
|
</v-btn>
|
||||||
|
</router-link>
|
||||||
|
</v-layout>
|
||||||
|
</material-card>
|
||||||
|
</v-container>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { ApiService } from "@/services";
|
import {ApiService} from "@/services";
|
||||||
import { urls } from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
import { mapMutations } from 'vuex'
|
import {mapMutations} from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data: () => ({
|
metaInfo() {
|
||||||
headers: [
|
return {
|
||||||
{sortable: false, text: "Hospital Name", value: "name"},
|
title: this.$route.meta.title,
|
||||||
{sortable: false, text: "Date", value: "date"},
|
meta: this.$route.meta.metaTags || []
|
||||||
{sortable: false, text: "Operator", value: "operator"},
|
}
|
||||||
{sortable: false, text: "Action", value: "action", align: "center",}
|
|
||||||
],
|
|
||||||
filter: {
|
|
||||||
name: ''
|
|
||||||
},
|
},
|
||||||
items: [],
|
data: () => ({
|
||||||
currentPage: 1,
|
headers: [
|
||||||
lastPage: 1
|
{sortable: false, text: "Hospital Name", value: "name"},
|
||||||
}),
|
{sortable: false, text: "Date", value: "date"},
|
||||||
created() {
|
{sortable: false, text: "Operator", value: "operator"},
|
||||||
this.load();
|
{sortable: false, text: "Action", value: "action", align: "center",}
|
||||||
},
|
],
|
||||||
methods: {
|
filter: {
|
||||||
...mapMutations("modal", ["changeCurrentModal", "closeModal"]),
|
name: ''
|
||||||
async load(page = 1) {
|
},
|
||||||
let filter = `?page=${page}&name=${this.filter.name}`;
|
items: [],
|
||||||
const result = await ApiService.get(urls.listMedicalCenter(filter));
|
currentPage: 1,
|
||||||
this.items = result.data.data.data;
|
lastPage: 1
|
||||||
this.currentPage = result.data.data.current_page;
|
}),
|
||||||
this.lastPage = result.data.data.last_page;
|
created() {
|
||||||
|
this.load();
|
||||||
},
|
},
|
||||||
async remove(id) {
|
methods: {
|
||||||
this.changeCurrentModal({
|
...mapMutations("modal", ["changeCurrentModal", "closeModal"]),
|
||||||
modal: "modal-user-confirmation",
|
async load(page = 1) {
|
||||||
properties: {
|
let filter = `?page=${page}&name=${this.filter.name}`;
|
||||||
width: '30'
|
const result = await ApiService.get(urls.listMedicalCenter(filter));
|
||||||
|
this.items = result.data.data.data;
|
||||||
|
this.currentPage = result.data.data.current_page;
|
||||||
|
this.lastPage = result.data.data.last_page;
|
||||||
},
|
},
|
||||||
success: async () => {
|
async remove(id) {
|
||||||
const result = await ApiService.delete(urls.deleteMedicalCenter(id));
|
this.changeCurrentModal({
|
||||||
this.closeModal();
|
modal: "modal-user-confirmation",
|
||||||
if (result && result.status == 200) {
|
properties: {
|
||||||
for (const key in this.items) {
|
width: '30'
|
||||||
if (this.items[key].id == id) {
|
},
|
||||||
this.items.splice(key, 1);
|
success: async () => {
|
||||||
}
|
const result = await ApiService.delete(urls.deleteMedicalCenter(id));
|
||||||
}
|
this.closeModal();
|
||||||
}
|
if (result && result.status == 200) {
|
||||||
},
|
for (const key in this.items) {
|
||||||
});
|
if (this.items[key].id == id) {
|
||||||
|
this.items.splice(key, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
currentPage(page) {
|
||||||
|
this.load(page);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
|
||||||
watch: {
|
|
||||||
currentPage(page) {
|
|
||||||
this.load(page);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="css" scoped>
|
<style lang="css" scoped>
|
||||||
.WM-ActionButton {
|
.WM-ActionButton {
|
||||||
padding: 8px 22px;
|
padding: 8px 22px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -1,200 +1,189 @@
|
|||||||
<template>
|
<template>
|
||||||
<v-container grid-list-xs>
|
<v-container grid-list-xs>
|
||||||
<material-card class color="black" :title="`Operator List`" text>
|
<material-card class color="black" :title="`Operator List`" text>
|
||||||
<v-layout row wrap class="px-5 mb-3">
|
<v-layout row wrap class="px-5 mb-3">
|
||||||
<v-flex xs12 md3 xs3>
|
<v-flex xs12 md3 xs3>
|
||||||
<v-text-field name="Name" v-model="filter.name" label="Name" class="pa-2" color="black"></v-text-field>
|
<v-text-field name="Name" v-model="filter.name" label="Name" class="pa-2"
|
||||||
</v-flex>
|
color="black"></v-text-field>
|
||||||
<v-flex xs12 md3 xs3>
|
</v-flex>
|
||||||
<v-text-field name="cell_number" v-model="filter.cell_number" label="Cell Number" class="pa-2" color="black"></v-text-field>
|
<v-flex xs12 md3 xs3>
|
||||||
</v-flex>
|
<v-text-field name="cell_number" v-model="filter.cell_number" label="Cell Number" class="pa-2"
|
||||||
<v-flex xs12 md2 xs3>
|
color="black"></v-text-field>
|
||||||
<v-select :items="roles" name="roles" v-model="filter.role" label="Roles" class="pa-2" color="black"></v-select>
|
</v-flex>
|
||||||
</v-flex>
|
<v-flex xs12 md2 xs3>
|
||||||
<v-flex xs12 md2 sm2 class="text-xs-right">
|
<v-select :items="roles" name="roles" v-model="filter.role" label="Roles" class="pa-2"
|
||||||
<v-btn class="WM-CyanBlueGradient-BG" @click="load" style="padding:10px 30px">
|
color="black"></v-select>
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-search</v-icon>
|
</v-flex>
|
||||||
<span class="white--text">Filter</span>
|
<v-flex xs12 md2 sm2 class="text-xs-right">
|
||||||
</v-btn>
|
<v-btn class="WM-CyanBlueGradient-BG" @click="load" style="padding:10px 30px">
|
||||||
</v-flex>
|
<v-icon class="white--text mr-2 caption">fas fa-search</v-icon>
|
||||||
<v-spacer></v-spacer>
|
<span class="white--text">Filter</span>
|
||||||
<v-flex xs12 md2 sm2 class="text-xs-right">
|
</v-btn>
|
||||||
<router-link :to="`/add-operator/${$route.params.medicalCenter}`">
|
</v-flex>
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
<v-spacer></v-spacer>
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-plus</v-icon>
|
<v-flex xs12 md2 sm2 class="text-xs-right">
|
||||||
<span class="black--text">Add</span>
|
<router-link :to="`/add-operator/${$route.params.medicalCenter}`">
|
||||||
</v-btn>
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black">
|
||||||
</router-link>
|
<v-icon class="black--text mr-2 caption">fas fa-plus</v-icon>
|
||||||
</v-flex>
|
<span class="black--text">Add</span>
|
||||||
</v-layout>
|
</v-btn>
|
||||||
<v-layout row align-center justify-center wrap class="px-5 mt-3">
|
</router-link>
|
||||||
<v-flex md12>
|
</v-flex>
|
||||||
<v-data-table :headers="headers" :items="items" hide-actions>
|
</v-layout>
|
||||||
<template slot="headerCell" slot-scope="{ header }">
|
<v-layout row align-center justify-center wrap class="px-5 mt-3">
|
||||||
|
<v-flex md12>
|
||||||
|
<v-data-table :headers="headers" :items="items" hide-actions>
|
||||||
|
<template slot="headerCell" slot-scope="{ header }">
|
||||||
<span
|
<span
|
||||||
class="subheading font-weight-light text-white text--darken-3"
|
class="subheading font-weight-light text-white text--darken-3"
|
||||||
v-text="header.text"
|
v-text="header.text"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template slot="items" slot-scope="{ item }">
|
<template slot="items" slot-scope="{ item }">
|
||||||
<td class="headline font-weight-light">{{ item.name }}</td>
|
<td class="headline font-weight-light">{{ item.name }}</td>
|
||||||
<td class="title font-weight-light">
|
<td class="title font-weight-light">
|
||||||
<span v-for="(role, key) in item.roles" :key="key">{{ role.name }}</span>
|
<span v-for="(role, key) in item.roles" :key="key">{{ role.name }}</span>
|
||||||
</td>
|
</td>
|
||||||
<td class="title font-weight-light">{{ item.cell_number }}</td>
|
<td class="title font-weight-light">{{ item.cell_number }}</td>
|
||||||
<td class="title font-weight-light">{{ item.status }}</td>
|
<td class="title font-weight-light">{{ item.status }}</td>
|
||||||
<td class="text-xs-right justify-self-end">
|
<td class="text-xs-right justify-self-end">
|
||||||
<v-btn
|
<v-btn
|
||||||
:color="item.status == 'Active' ? 'red' : 'green'"
|
:color="item.status == 'Active' ? 'red' : 'green'"
|
||||||
@click="changeStatus(item.id)"
|
@click="changeStatus(item.id)"
|
||||||
class="mr-2 WM-ActionButton"
|
class="mr-2 WM-ActionButton"
|
||||||
>
|
>
|
||||||
<template v-if="item.status == 'Active'">
|
<template v-if="item.status == 'Active'">
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-user-tag</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-user-tag</v-icon>
|
||||||
<span v-if="item.status == 'Active'">Suspended</span>
|
<span v-if="item.status == 'Active'">Suspended</span>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-user-tag</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-user-tag</v-icon>
|
||||||
<span>Active</span>
|
<span>Active</span>
|
||||||
</template>
|
</template>
|
||||||
</v-btn>
|
</v-btn>
|
||||||
<v-btn
|
<v-btn
|
||||||
color="orange darken-1"
|
color="orange darken-1"
|
||||||
@click="changeRoleModal(item)"
|
@click="changeRoleModal(item)"
|
||||||
class="mr-2 WM-ActionButton"
|
class="mr-2 WM-ActionButton"
|
||||||
>
|
>
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-user-tag</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-user-tag</v-icon>
|
||||||
<span>Role</span>
|
<span>Role</span>
|
||||||
</v-btn>
|
</v-btn>
|
||||||
<v-btn color="pink" class="WM-ActionButton" @click="remove(item.id)">
|
<v-btn color="pink" class="WM-ActionButton" @click="remove(item.id)">
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-times</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-times</v-icon>
|
||||||
<span>Remove</span>
|
<span>Remove</span>
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</td>
|
</td>
|
||||||
</template>
|
</template>
|
||||||
</v-data-table>
|
</v-data-table>
|
||||||
</v-flex>
|
</v-flex>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
<v-divider/>
|
<v-divider/>
|
||||||
<v-layout row wrap align-center justify-center class="mt-3">
|
<v-layout row wrap align-center justify-center class="mt-3">
|
||||||
<router-link to="/manage-medical-center">
|
<router-link to="/manage-medical-center">
|
||||||
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black ml-5">
|
<v-btn class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black ml-5">
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-chevron-left</v-icon>
|
<v-icon class="black--text mr-2 caption">fas fa-chevron-left</v-icon>
|
||||||
<span class="black--text">Back</span>
|
<span class="black--text">Back</span>
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</router-link>
|
</router-link>
|
||||||
</v-layout>
|
</v-layout>
|
||||||
</material-card>
|
</material-card>
|
||||||
</v-container>
|
</v-container>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { ApiService } from "@/services";
|
import {ApiService} from "@/services";
|
||||||
import { mapMutations, mapGetters } from "vuex";
|
import {mapMutations, mapGetters} from "vuex";
|
||||||
import { urls } from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
import { roles } from "@/config/utils";
|
import {roles} from "@/config/utils";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data: () => ({
|
metaInfo() {
|
||||||
headers: [
|
return {
|
||||||
{
|
title: this.$route.meta.title,
|
||||||
sortable: true,
|
meta: this.$route.meta.metaTags || []
|
||||||
text: "Operator Name",
|
|
||||||
value: "name"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
sortable: false,
|
|
||||||
text: "Role",
|
|
||||||
value: "role"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
sortable: false,
|
|
||||||
text: "Number",
|
|
||||||
value: "number"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
sortable: false,
|
|
||||||
text: "Status",
|
|
||||||
value: "status"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
sortable: false,
|
|
||||||
text: "Action",
|
|
||||||
value: "action",
|
|
||||||
align: "right"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
filter: {
|
|
||||||
name: '',
|
|
||||||
cell_number: '',
|
|
||||||
role: '',
|
|
||||||
},
|
|
||||||
items: [],
|
|
||||||
name: "",
|
|
||||||
roles,
|
|
||||||
}),
|
|
||||||
created() {
|
|
||||||
if (this.$route.params.medicalCenter) {
|
|
||||||
this.load();
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async load() {
|
|
||||||
let medicalCenterId = this.$route.params.medicalCenter;
|
|
||||||
let filter = "?";
|
|
||||||
for (const key in this.filter) {
|
|
||||||
if (this.filter.hasOwnProperty(key)) {
|
|
||||||
filter += `${key}=${this.filter[key]}&`;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const result = await ApiService.get(
|
|
||||||
urls.listOpertorMedicalCenter(medicalCenterId, filter)
|
|
||||||
);
|
|
||||||
if (result && result.status == 200) {
|
|
||||||
this.items = result.data.data.users;
|
|
||||||
} else {
|
|
||||||
this.$router.push({name:`Dashboard`});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
async changeStatus(userId) {
|
|
||||||
const result = await ApiService.post(urls.changeStatusUser(userId));
|
|
||||||
if (result && result.status == 200) {
|
|
||||||
for (let user of this.items) {
|
|
||||||
if (user.id == userId) {
|
|
||||||
user.status = result.data.data.status;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
this.$router.push({name:`Dashboard`});
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
...mapMutations("modal", ["changeCurrentModal"]),
|
data: () => ({
|
||||||
changeRoleModal(user) {
|
headers: [
|
||||||
this.changeCurrentModal({
|
{sortable: false, text: "Operator Name", value: "name"},
|
||||||
modal: "modal-user-role",
|
{sortable: false, text: "Role", value: "role"},
|
||||||
properties: { user }
|
{sortable: false, text: "Number", value: "number"},
|
||||||
});
|
{sortable: false, text: "Status", value: "status"},
|
||||||
|
{sortable: false, text: "Action", value: "action", align: "right"}
|
||||||
|
],
|
||||||
|
filter: {
|
||||||
|
name: '',
|
||||||
|
cell_number: '',
|
||||||
|
role: '',
|
||||||
|
},
|
||||||
|
items: [],
|
||||||
|
name: "",
|
||||||
|
roles,
|
||||||
|
}),
|
||||||
|
created() {
|
||||||
|
if (this.$route.params.medicalCenter) {
|
||||||
|
this.load();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
async remove(userId) {
|
methods: {
|
||||||
const result = await ApiService.delete(urls.deleteUser(userId));
|
async load() {
|
||||||
if (result && result.status == 200) {
|
let medicalCenterId = this.$route.params.medicalCenter;
|
||||||
for (const key in this.items) {
|
let filter = "?";
|
||||||
if (this.items.hasOwnProperty(key) && this.items[key].id == userId) {
|
for (const key in this.filter) {
|
||||||
this.items.splice(key, 1);
|
if (this.filter.hasOwnProperty(key)) {
|
||||||
}
|
filter += `${key}=${this.filter[key]}&`;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
const result = await ApiService.get(
|
||||||
|
urls.listOpertorMedicalCenter(medicalCenterId, filter)
|
||||||
|
);
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.items = result.data.data.users;
|
||||||
|
} else {
|
||||||
|
this.$router.push({name: `Dashboard`});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async changeStatus(userId) {
|
||||||
|
const result = await ApiService.post(urls.changeStatusUser(userId));
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
for (let user of this.items) {
|
||||||
|
if (user.id == userId) {
|
||||||
|
user.status = result.data.data.status;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$router.push({name: `Dashboard`});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
...mapMutations("modal", ["changeCurrentModal"]),
|
||||||
|
changeRoleModal(user) {
|
||||||
|
this.changeCurrentModal({
|
||||||
|
modal: "modal-user-role",
|
||||||
|
properties: {user}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
async remove(userId) {
|
||||||
|
const result = await ApiService.delete(urls.deleteUser(userId));
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
for (const key in this.items) {
|
||||||
|
if (this.items.hasOwnProperty(key) && this.items[key].id == userId) {
|
||||||
|
this.items.splice(key, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
},
|
||||||
}
|
computed: {
|
||||||
},
|
...mapGetters("modal", ["getModalResult"])
|
||||||
computed: {
|
},
|
||||||
...mapGetters("modal", ["getModalResult"])
|
watch: {
|
||||||
},
|
getModalResult(user) {
|
||||||
watch: {
|
for (const userList of this.items) {
|
||||||
getModalResult(user) {
|
if (userList.id == user.id) {
|
||||||
for (const userList of this.items) {
|
userList.roles = user.roles;
|
||||||
if (userList.id == user.id) {
|
}
|
||||||
userList.roles = user.roles;
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
@@ -167,6 +167,12 @@ import {mapMutations, mapGetters, mapActions} from "vuex";
|
|||||||
import toast from "@/services/global/toast.service";
|
import toast from "@/services/global/toast.service";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
// {sortable: true,text: "ID",value: "id"},
|
// {sortable: true,text: "ID",value: "id"},
|
||||||
|
|||||||
@@ -56,10 +56,16 @@
|
|||||||
<td class="title font-weight-light">{{ item.status }}</td>
|
<td class="title font-weight-light">{{ item.status }}</td>
|
||||||
<td class="text-xs-right FlexBtn Height-MD-60 justify-self-end">
|
<td class="text-xs-right FlexBtn Height-MD-60 justify-self-end">
|
||||||
<template v-if="$hasRole('Admin|Supervisor')">
|
<template v-if="$hasRole('Admin|Supervisor')">
|
||||||
<v-tooltip v-for="status in getStatus(item)" :key="status.label" bottom open-on-hover>
|
<v-tooltip v-for="status in getStatus(item)" :key="status.label" bottom
|
||||||
|
open-on-hover>
|
||||||
<template v-slot:activator="{ on, attrs }">
|
<template v-slot:activator="{ on, attrs }">
|
||||||
<v-btn :color="status.color" class="mr-2" @click="changeStatus(item, status.status)" v-bind="attrs" v-on="on">
|
<v-btn :color="status.color" class="mr-2"
|
||||||
<v-icon class="white--text mr-1 caption">fas {{ status.icon }}</v-icon>
|
@click="changeStatus(item, status.status)" v-bind="attrs"
|
||||||
|
v-on="on">
|
||||||
|
<v-icon class="white--text mr-1 caption">fas {{
|
||||||
|
status.icon
|
||||||
|
}}
|
||||||
|
</v-icon>
|
||||||
<span>{{ status.label }}</span>
|
<span>{{ status.label }}</span>
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</template>
|
</template>
|
||||||
@@ -154,6 +160,12 @@ import {mapMutations, mapGetters} from "vuex";
|
|||||||
import toast from "@/services/global/toast.service";
|
import toast from "@/services/global/toast.service";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{sortable: false, text: "ID", value: "Package ID"},
|
{sortable: false, text: "ID", value: "Package ID"},
|
||||||
@@ -161,7 +173,7 @@ export default {
|
|||||||
{sortable: false, text: "Hospital", value: "Hospital"},
|
{sortable: false, text: "Hospital", value: "Hospital"},
|
||||||
{sortable: false, text: "Description", value: "description"},
|
{sortable: false, text: "Description", value: "description"},
|
||||||
{sortable: false, text: "Status", value: "status"},
|
{sortable: false, text: "Status", value: "status"},
|
||||||
{sortable: false, text: "Action", value: "action", align: "center",width:'20%'}
|
{sortable: false, text: "Action", value: "action", align: "center", width: '20%'}
|
||||||
],
|
],
|
||||||
filter: {
|
filter: {
|
||||||
name: '',
|
name: '',
|
||||||
@@ -191,8 +203,8 @@ export default {
|
|||||||
if (result && result.status == 200) {
|
if (result && result.status == 200) {
|
||||||
const {data, meta} = result.data;
|
const {data, meta} = result.data;
|
||||||
this.items = data;
|
this.items = data;
|
||||||
this.currentPage = meta? meta.current_page : 1;
|
this.currentPage = meta ? meta.current_page : 1;
|
||||||
this.lastPage =meta? meta.last_page : 1;
|
this.lastPage = meta ? meta.last_page : 1;
|
||||||
}
|
}
|
||||||
this.loadMedicalCenters();
|
this.loadMedicalCenters();
|
||||||
},
|
},
|
||||||
@@ -227,8 +239,8 @@ export default {
|
|||||||
getStatus(item) {
|
getStatus(item) {
|
||||||
if (item.status === 'pending') {
|
if (item.status === 'pending') {
|
||||||
return [
|
return [
|
||||||
{ status: 'rejected', label: 'reject', color: 'red', icon: 'fa-close' },
|
{status: 'rejected', label: 'reject', color: 'red', icon: 'fa-close'},
|
||||||
{ status: 'approved', label: 'approve', color: 'green', icon: 'fa-check' }
|
{status: 'approved', label: 'approve', color: 'green', icon: 'fa-check'}
|
||||||
]
|
]
|
||||||
} else {
|
} else {
|
||||||
const nextStatus = item.status === 'rejected' ? 'approved' : 'rejected'
|
const nextStatus = item.status === 'rejected' ? 'approved' : 'rejected'
|
||||||
@@ -243,7 +255,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
async changeStatus(item, status) {
|
async changeStatus(item, status) {
|
||||||
const result = await ApiService.post(urls.changePackageStatus(item.id), { status })
|
const result = await ApiService.post(urls.changePackageStatus(item.id), {status})
|
||||||
|
|
||||||
if (result?.data?.data?.status) {
|
if (result?.data?.data?.status) {
|
||||||
const newStatus = result.data.data.status
|
const newStatus = result.data.data.status
|
||||||
|
|||||||
@@ -118,6 +118,12 @@ import {urls} from "@/config/urls";
|
|||||||
import {mapMutations} from "vuex";
|
import {mapMutations} from "vuex";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
formData: {
|
formData: {
|
||||||
|
|||||||
@@ -160,6 +160,12 @@ import {mapMutations, mapGetters} from "vuex";
|
|||||||
import toast from "@/services/global/toast.service";
|
import toast from "@/services/global/toast.service";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{sortable: false, text: "ID", value: "Package ID"},
|
{sortable: false, text: "ID", value: "Package ID"},
|
||||||
|
|||||||
+186
-169
@@ -1,195 +1,212 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<v-form ref="form">
|
<v-form ref="form">
|
||||||
<v-container grid-list-xs>
|
<v-container grid-list-xs>
|
||||||
<material-card color="black" title="Search Result">
|
<material-card color="black" title="Search Result">
|
||||||
<v-layout align-center justify-center wrap class="px-5 my-3">
|
<v-layout align-center justify-center wrap class="px-5 my-3">
|
||||||
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
||||||
<v-icon class="fa fa-align-left mr-2 WM-Margin-B-8"></v-icon>
|
<v-icon class="fa fa-align-left mr-2 WM-Margin-B-8"></v-icon>
|
||||||
<v-autocomplete :items="medicalCenters" item-text="name" item-value="id" v-model="form.medicalCenterId" @change="fillUsers" label="Hospital" color="black" class="pa-2"></v-autocomplete>
|
<v-autocomplete :items="medicalCenters" item-text="name" item-value="id"
|
||||||
</v-flex>
|
v-model="form.medicalCenterId" @change="fillUsers" label="Hospital"
|
||||||
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
color="black" class="pa-2"></v-autocomplete>
|
||||||
<v-icon class="fa fa-user mr-2 WM-Margin-B-8"></v-icon>
|
</v-flex>
|
||||||
<v-autocomplete :items="users" item-text="name" item-value="id" v-model="form.userId" label="User" color="black" class="py-3 pr-3"></v-autocomplete>
|
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
||||||
</v-flex>
|
<v-icon class="fa fa-user mr-2 WM-Margin-B-8"></v-icon>
|
||||||
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
<v-autocomplete :items="users" item-text="name" item-value="id" v-model="form.userId"
|
||||||
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"></v-icon>
|
label="User" color="black" class="py-3 pr-3"></v-autocomplete>
|
||||||
<v-autocomplete :items="testTypes" item-text="name" item-value="id" v-model="form.testTypeId" label="TestType" color="black" class="py-3 pr-3"></v-autocomplete>
|
</v-flex>
|
||||||
</v-flex>
|
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
||||||
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
<v-icon class="fas fa-sort-numeric-up mr-2 WM-Margin-B-8"></v-icon>
|
||||||
<v-icon class="fas fa-angle-right mr-2 WM-Margin-B-8"></v-icon>
|
<v-autocomplete :items="testTypes" item-text="name" item-value="id"
|
||||||
<v-autocomplete :items="result" v-model="form.result" label="Result" color="black" class="py-3 pr-3"></v-autocomplete>
|
v-model="form.testTypeId" label="TestType" color="black"
|
||||||
</v-flex>
|
class="py-3 pr-3"></v-autocomplete>
|
||||||
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
</v-flex>
|
||||||
<v-icon class="fas fa-angle-right mr-2 WM-Margin-B-8"></v-icon>
|
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
||||||
<v-autocomplete :items="verify" v-model="form.verify" label="Verify" color="black" class="py-3 pr-3"></v-autocomplete>
|
<v-icon class="fas fa-angle-right mr-2 WM-Margin-B-8"></v-icon>
|
||||||
</v-flex>
|
<v-autocomplete :items="result" v-model="form.result" label="Result" color="black"
|
||||||
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
class="py-3 pr-3"></v-autocomplete>
|
||||||
<v-icon class="fas fa-line-chart mr-2 WM-Margin-B-8"></v-icon>
|
</v-flex>
|
||||||
<v-autocomplete :items="type" v-model="form.type" label="Type" color="black" class="py-3 pr-3"></v-autocomplete>
|
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
||||||
</v-flex>
|
<v-icon class="fas fa-angle-right mr-2 WM-Margin-B-8"></v-icon>
|
||||||
<v-flex xs12 sm6 md2 class="WM-FlexCenter pl-3">
|
<v-autocomplete :items="verify" v-model="form.verify" label="Verify" color="black"
|
||||||
<v-icon class="far fa-calendar-alt mr-2"></v-icon>
|
class="py-3 pr-3"></v-autocomplete>
|
||||||
<v-menu
|
</v-flex>
|
||||||
lazy
|
<v-flex xs12 sm4 md4 class="WM-FlexCenter pl-3">
|
||||||
:close-on-content-click="true"
|
<v-icon class="fas fa-line-chart mr-2 WM-Margin-B-8"></v-icon>
|
||||||
transition="v-scale-transition"
|
<v-autocomplete :items="type" v-model="form.type" label="Type" color="black"
|
||||||
offset-y
|
class="py-3 pr-3"></v-autocomplete>
|
||||||
v-model="fromMenu"
|
</v-flex>
|
||||||
>
|
<v-flex xs12 sm6 md2 class="WM-FlexCenter pl-3">
|
||||||
<v-text-field
|
<v-icon class="far fa-calendar-alt mr-2"></v-icon>
|
||||||
required
|
<v-menu
|
||||||
slot="activator"
|
lazy
|
||||||
label="FromDate"
|
:close-on-content-click="true"
|
||||||
color="black"
|
transition="v-scale-transition"
|
||||||
v-model="form.fromPicker">
|
offset-y
|
||||||
</v-text-field>
|
v-model="fromMenu"
|
||||||
<v-date-picker
|
>
|
||||||
color="pink"
|
<v-text-field
|
||||||
no-title
|
required
|
||||||
v-model="form.fromPicker"
|
slot="activator"
|
||||||
:date-format="date => new Date(date).toDateString()"
|
label="FromDate"
|
||||||
></v-date-picker>
|
color="black"
|
||||||
</v-menu>
|
v-model="form.fromPicker">
|
||||||
</v-flex>
|
</v-text-field>
|
||||||
<v-flex xs12 sm6 md2 class="WM-FlexCenter pl-3">
|
<v-date-picker
|
||||||
<v-icon class="far fa-calendar-alt mr-2"></v-icon>
|
color="pink"
|
||||||
<v-menu
|
no-title
|
||||||
lazy
|
v-model="form.fromPicker"
|
||||||
:close-on-content-click="true"
|
:date-format="date => new Date(date).toDateString()"
|
||||||
transition="v-scale-transition"
|
></v-date-picker>
|
||||||
offset-y
|
</v-menu>
|
||||||
v-model="upToMenu"
|
</v-flex>
|
||||||
>
|
<v-flex xs12 sm6 md2 class="WM-FlexCenter pl-3">
|
||||||
<v-text-field
|
<v-icon class="far fa-calendar-alt mr-2"></v-icon>
|
||||||
required
|
<v-menu
|
||||||
slot="activator"
|
lazy
|
||||||
label="UpToDate"
|
:close-on-content-click="true"
|
||||||
color="black"
|
transition="v-scale-transition"
|
||||||
v-model="form.upToPicker">
|
offset-y
|
||||||
</v-text-field>
|
v-model="upToMenu"
|
||||||
<v-date-picker
|
>
|
||||||
color="pink"
|
<v-text-field
|
||||||
no-title
|
required
|
||||||
v-model="form.upToPicker"
|
slot="activator"
|
||||||
:date-format="date => new Date(date).toDateString()"
|
label="UpToDate"
|
||||||
></v-date-picker>
|
color="black"
|
||||||
</v-menu>
|
v-model="form.upToPicker">
|
||||||
</v-flex>
|
</v-text-field>
|
||||||
<v-spacer></v-spacer>
|
<v-date-picker
|
||||||
<v-flex xs12 md2 sm2 class="text-xs-center text-sm-center text-md-right">
|
color="pink"
|
||||||
<v-btn
|
no-title
|
||||||
class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black"
|
v-model="form.upToPicker"
|
||||||
style="padding:10px 60px;"
|
:date-format="date => new Date(date).toDateString()"
|
||||||
@click="submitForm"
|
></v-date-picker>
|
||||||
>
|
</v-menu>
|
||||||
<v-icon class="black--text mr-2 caption">fas fa-chevron-right</v-icon>
|
</v-flex>
|
||||||
<span class="black--text">GO</span>
|
<v-spacer></v-spacer>
|
||||||
</v-btn>
|
<v-flex xs12 md2 sm2 class="text-xs-center text-sm-center text-md-right">
|
||||||
</v-flex>
|
<v-btn
|
||||||
</v-layout>
|
class="WM-NoShadow WM-Outline-Btn WM-Border WM-Border-Black"
|
||||||
<v-layout row wrap class="px-5 my-3" v-if="!$route.params.testResult">
|
style="padding:10px 60px;"
|
||||||
<v-divider></v-divider>
|
@click="submitForm"
|
||||||
</v-layout>
|
>
|
||||||
</material-card>
|
<v-icon class="black--text mr-2 caption">fas fa-chevron-right</v-icon>
|
||||||
</v-container>
|
<span class="black--text">GO</span>
|
||||||
</v-form>
|
</v-btn>
|
||||||
<div v-if="chart" class="small">
|
</v-flex>
|
||||||
<pie-chart v-if="form.type === 'PieChart'" :chart-data="datacollection"></pie-chart>
|
</v-layout>
|
||||||
<bar-chart v-else :chart-data="datacollection"></bar-chart>
|
<v-layout row wrap class="px-5 my-3" v-if="!$route.params.testResult">
|
||||||
|
<v-divider></v-divider>
|
||||||
|
</v-layout>
|
||||||
|
</material-card>
|
||||||
|
</v-container>
|
||||||
|
</v-form>
|
||||||
|
<div v-if="chart" class="small">
|
||||||
|
<pie-chart v-if="form.type === 'PieChart'" :chart-data="datacollection"></pie-chart>
|
||||||
|
<bar-chart v-else :chart-data="datacollection"></bar-chart>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import BarChart from "@/plugins/chart/BarChart.js";
|
import BarChart from "@/plugins/chart/BarChart.js";
|
||||||
import PieChart from "@/plugins/chart/PieChart.js";
|
import PieChart from "@/plugins/chart/PieChart.js";
|
||||||
import { ApiService } from "@/services";
|
import {ApiService} from "@/services";
|
||||||
import { urls } from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
metaInfo() {
|
||||||
BarChart,
|
return {
|
||||||
PieChart
|
title: this.$route.meta.title,
|
||||||
},
|
meta: this.$route.meta.metaTags || []
|
||||||
data() {
|
}
|
||||||
return {
|
|
||||||
datacollection: null,
|
|
||||||
fromMenu: '',
|
|
||||||
upToMenu: '',
|
|
||||||
verify: ['Verified', 'NotVerified'],
|
|
||||||
result: ['Accept', 'Failed'],
|
|
||||||
type: ['BarChart', 'PieChart'],
|
|
||||||
users: [],
|
|
||||||
medicalCenters: [],
|
|
||||||
testTypes: [],
|
|
||||||
form: {
|
|
||||||
medicalCenterId: null,
|
|
||||||
userId: null,
|
|
||||||
testTypeId: null,
|
|
||||||
result: null,
|
|
||||||
verify: null,
|
|
||||||
type: 'PieChart',
|
|
||||||
fromPicker: '',
|
|
||||||
upToPicker: '',
|
|
||||||
},
|
|
||||||
chart: false
|
|
||||||
};
|
|
||||||
},
|
|
||||||
created() {
|
|
||||||
this.load();
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
fillData(options) {
|
|
||||||
this.datacollection = {
|
|
||||||
labels: options.labels,
|
|
||||||
// labels: [this.getRandomInt(), this.getRandomInt()],
|
|
||||||
datasets: [
|
|
||||||
{
|
|
||||||
label: "Data One",
|
|
||||||
backgroundColor: ["#f87979", "#ccc"],
|
|
||||||
data: options.data,
|
|
||||||
// data: [this.getRandomInt(), this.getRandomInt()],
|
|
||||||
}
|
|
||||||
]
|
|
||||||
};
|
|
||||||
},
|
},
|
||||||
async load() {
|
components: {
|
||||||
const result = await ApiService.get(urls.listFilterItemsTestResult);
|
BarChart,
|
||||||
if (result && result.status == 200) {
|
PieChart
|
||||||
this.medicalCenters = result.data.data.MedicalCenters;
|
|
||||||
this.testTypes = result.data.data.TestTypes;
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
async fillUsers() {
|
data() {
|
||||||
const result = await ApiService.get(urls.listOpertorMedicalCenter(this.form.medicalCenterId));
|
return {
|
||||||
if (result && result.status == 200) {
|
datacollection: null,
|
||||||
this.users = result.data.data.users;
|
fromMenu: '',
|
||||||
}
|
upToMenu: '',
|
||||||
|
verify: ['Verified', 'NotVerified'],
|
||||||
|
result: ['Accept', 'Failed'],
|
||||||
|
type: ['BarChart', 'PieChart'],
|
||||||
|
users: [],
|
||||||
|
medicalCenters: [],
|
||||||
|
testTypes: [],
|
||||||
|
form: {
|
||||||
|
medicalCenterId: null,
|
||||||
|
userId: null,
|
||||||
|
testTypeId: null,
|
||||||
|
result: null,
|
||||||
|
verify: null,
|
||||||
|
type: 'PieChart',
|
||||||
|
fromPicker: '',
|
||||||
|
upToPicker: '',
|
||||||
|
},
|
||||||
|
chart: false
|
||||||
|
};
|
||||||
},
|
},
|
||||||
async submitForm() {
|
created() {
|
||||||
const result = await ApiService.post(urls.statistics, this.form);
|
this.load();
|
||||||
if (result && result.status == 200) {
|
|
||||||
this.fillData(result.data.data);
|
|
||||||
this.chart = true;
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
}
|
methods: {
|
||||||
|
fillData(options) {
|
||||||
|
this.datacollection = {
|
||||||
|
labels: options.labels,
|
||||||
|
// labels: [this.getRandomInt(), this.getRandomInt()],
|
||||||
|
datasets: [
|
||||||
|
{
|
||||||
|
label: "Data One",
|
||||||
|
backgroundColor: ["#f87979", "#ccc"],
|
||||||
|
data: options.data,
|
||||||
|
// data: [this.getRandomInt(), this.getRandomInt()],
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
},
|
||||||
|
async load() {
|
||||||
|
const result = await ApiService.get(urls.listFilterItemsTestResult);
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.medicalCenters = result.data.data.MedicalCenters;
|
||||||
|
this.testTypes = result.data.data.TestTypes;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async fillUsers() {
|
||||||
|
const result = await ApiService.get(urls.listOpertorMedicalCenter(this.form.medicalCenterId));
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.users = result.data.data.users;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async submitForm() {
|
||||||
|
const result = await ApiService.post(urls.statistics, this.form);
|
||||||
|
if (result && result.status == 200) {
|
||||||
|
this.fillData(result.data.data);
|
||||||
|
this.chart = true;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.small {
|
.small {
|
||||||
max-width: 600px;
|
max-width: 600px;
|
||||||
margin: 150px auto;
|
margin: 150px auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.v-btn--floating {
|
.v-btn--floating {
|
||||||
padding: 0!important;
|
padding: 0 !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.theme--light.v-btn.v-btn--flat {
|
.theme--light.v-btn.v-btn--flat {
|
||||||
color: rgba(0,0,0,.87)!important;
|
color: rgba(0, 0, 0, .87) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.v-btn--floating, .v-btn--icon:before {
|
.v-btn--floating, .v-btn--icon:before {
|
||||||
border-radius: 50%!important;
|
border-radius: 50% !important;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -416,6 +416,12 @@ import {ApiService} from "@/services";
|
|||||||
import {urls} from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
components: {
|
components: {
|
||||||
'wm-Dropzone': Dropzone,
|
'wm-Dropzone': Dropzone,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -186,6 +186,12 @@ import {
|
|||||||
} from "vuex";
|
} from "vuex";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{sortable: false, text: "ID", value: "name"},
|
{sortable: false, text: "ID", value: "name"},
|
||||||
|
|||||||
@@ -126,6 +126,12 @@ import { mapGetters, mapMutations } from "vuex";
|
|||||||
import { ApiService } from "@/services";
|
import { ApiService } from "@/services";
|
||||||
import { urls } from "@/config/urls";
|
import { urls } from "@/config/urls";
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
data: {
|
data: {
|
||||||
user: {
|
user: {
|
||||||
|
|||||||
@@ -266,7 +266,8 @@
|
|||||||
<v-icon class="white--text mr-2 caption">fas fa-times</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-times</v-icon>
|
||||||
REMOVE
|
REMOVE
|
||||||
</v-btn>
|
</v-btn>
|
||||||
<v-layout row wrap align-center justify-center class="mt-4" v-if="(form.info.length -1) == keyForm">
|
<v-layout row wrap align-center justify-center class="mt-4"
|
||||||
|
v-if="(form.info.length -1) == keyForm">
|
||||||
<v-btn absolute right bottom small @click="addInput" color="pink" class="mb-2">
|
<v-btn absolute right bottom small @click="addInput" color="pink" class="mb-2">
|
||||||
<v-icon class="white--text mr-2 caption">fas fa-plus</v-icon>
|
<v-icon class="white--text mr-2 caption">fas fa-plus</v-icon>
|
||||||
<span class="white--text">Add</span>
|
<span class="white--text">Add</span>
|
||||||
@@ -301,6 +302,12 @@ import {ApiService} from "@/services";
|
|||||||
import {urls} from "@/config/urls";
|
import {urls} from "@/config/urls";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
form: {
|
form: {
|
||||||
|
|||||||
@@ -150,6 +150,12 @@ import {urls} from "@/config/urls";
|
|||||||
import {mapMutations, mapGetters} from "vuex";
|
import {mapMutations, mapGetters} from "vuex";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{sortable: false, text: "TestType Name", value: "name"},
|
{sortable: false, text: "TestType Name", value: "name"},
|
||||||
|
|||||||
@@ -144,6 +144,12 @@ import {mapMutations, mapGetters} from "vuex";
|
|||||||
import {roles} from "@/config/utils";
|
import {roles} from "@/config/utils";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data: () => ({
|
data: () => ({
|
||||||
headers: [
|
headers: [
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -96,6 +96,12 @@ import {urls} from "@/config/urls";
|
|||||||
import {mapMutations} from 'vuex';
|
import {mapMutations} from 'vuex';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
metaInfo() {
|
||||||
|
return {
|
||||||
|
title: this.$route.meta.title,
|
||||||
|
meta: this.$route.meta.metaTags || []
|
||||||
|
}
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
user: {
|
user: {
|
||||||
|
|||||||
Reference in New Issue
Block a user