mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-29 19:25:57 +00:00
v1.6 released
This commit is contained in:
+5
-21
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div id="vue-file-manager" :class="appSize" v-cloak>
|
||||
<div id="vue-file-manager" v-cloak>
|
||||
|
||||
<!--System alerts-->
|
||||
<Alert/>
|
||||
@@ -25,7 +25,9 @@
|
||||
<ToastrWrapper/>
|
||||
|
||||
<!--File page-->
|
||||
<router-view :class="{'is-scaled-down': isScaledDown}"/>
|
||||
<keep-alive :include="['Admin', 'Users']">
|
||||
<router-view :class="{'is-scaled-down': isScaledDown}"/>
|
||||
</keep-alive>
|
||||
</div>
|
||||
|
||||
<router-view v-if="layout === 'unauthorized'"/>
|
||||
@@ -45,7 +47,6 @@
|
||||
import Vignette from '@/components/Others/Vignette'
|
||||
import MenuBar from '@/components/Sidebar/MenuBar'
|
||||
import Alert from '@/components/FilesView/Alert'
|
||||
import {ResizeSensor} from 'css-element-queries'
|
||||
import {includes} from 'lodash'
|
||||
import {mapGetters} from 'vuex'
|
||||
import {events} from "./bus"
|
||||
@@ -65,7 +66,7 @@
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'appSize', 'isLogged', 'isGuest'
|
||||
'isLogged', 'isGuest'
|
||||
]),
|
||||
layout() {
|
||||
if (includes(['VerifyByPassword', 'SharedPage', 'NotFoundShared', 'SignIn', 'SignUp', 'ForgottenPassword', 'CreateNewPassword'], this.$route.name)) {
|
||||
@@ -80,19 +81,6 @@
|
||||
isScaledDown: false,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleAppResize() {
|
||||
let appView = document.getElementById('vue-file-manager')
|
||||
.offsetWidth
|
||||
|
||||
if (appView <= 690)
|
||||
this.$store.commit('SET_APP_WIDTH', 'small')
|
||||
if (appView > 690 && appView < 960)
|
||||
this.$store.commit('SET_APP_WIDTH', 'medium')
|
||||
if (appView > 960)
|
||||
this.$store.commit('SET_APP_WIDTH', 'large')
|
||||
},
|
||||
},
|
||||
beforeMount() {
|
||||
|
||||
// Store config to vuex
|
||||
@@ -107,10 +95,6 @@
|
||||
})
|
||||
},
|
||||
mounted() {
|
||||
// Handle VueFileManager width
|
||||
var VueFileManager = document.getElementById('vue-file-manager');
|
||||
new ResizeSensor(VueFileManager, this.handleAppResize);
|
||||
|
||||
// Handle mobile navigation scale animation
|
||||
events.$on('show:mobile-navigation', () => this.isScaledDown = true)
|
||||
events.$on('hide:mobile-navigation', () => this.isScaledDown = false)
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<list-icon v-if="icon === 'th-list'" size="15" class="icon"></list-icon>
|
||||
<trash-icon v-if="icon === 'trash'" size="15" class="icon"></trash-icon>
|
||||
<grid-icon v-if="icon === 'th'" size="15" class="icon"></grid-icon>
|
||||
<user-plus-icon v-if="icon === 'user-plus'" size="15" class="icon"></user-plus-icon>
|
||||
<span class="label">
|
||||
<slot></slot>
|
||||
</span>
|
||||
@@ -13,7 +14,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { FolderPlusIcon, ListIcon, GridIcon, TrashIcon } from 'vue-feather-icons'
|
||||
import { FolderPlusIcon, ListIcon, GridIcon, TrashIcon, UserPlusIcon } from 'vue-feather-icons'
|
||||
|
||||
export default {
|
||||
name: 'MobileActionButton',
|
||||
@@ -22,6 +23,7 @@
|
||||
],
|
||||
components: {
|
||||
FolderPlusIcon,
|
||||
UserPlusIcon,
|
||||
TrashIcon,
|
||||
ListIcon,
|
||||
GridIcon,
|
||||
@@ -40,6 +42,7 @@
|
||||
padding: 7px 10px;
|
||||
cursor: pointer;
|
||||
border: none;
|
||||
@include transition(150ms);
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
@@ -49,13 +52,36 @@
|
||||
.icon {
|
||||
margin-right: 10px;
|
||||
@include font-size(14);
|
||||
|
||||
path, line, polyline, rect, circle {
|
||||
@include transition(150ms);
|
||||
}
|
||||
}
|
||||
|
||||
.label {
|
||||
@include transition(150ms);
|
||||
@include font-size(14);
|
||||
font-weight: 700;
|
||||
color: $text;
|
||||
}
|
||||
|
||||
&:active {
|
||||
@include transform(scale(0.95));
|
||||
}
|
||||
|
||||
&:hover {
|
||||
background: rgba($theme, 0.1);
|
||||
|
||||
.icon {
|
||||
path, line, polyline, rect, circle {
|
||||
stroke: $theme;
|
||||
}
|
||||
}
|
||||
|
||||
.label {
|
||||
color: $theme;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
|
||||
@@ -44,13 +44,9 @@
|
||||
'currentFolder',
|
||||
'browseHistory',
|
||||
'homeDirectory',
|
||||
'appSize',
|
||||
]),
|
||||
directoryName() {
|
||||
return this.currentFolder ? this.currentFolder.name : this.homeDirectory.name
|
||||
},
|
||||
isSmallAppSize() {
|
||||
return this.appSize === 'small'
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
@@ -94,7 +94,7 @@
|
||||
@media only screen and (max-width: 690px) {
|
||||
.mobile-header {
|
||||
display: flex;
|
||||
margin-bottom: 25px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -12,7 +12,6 @@
|
||||
import DesktopToolbar from '@/components/FilesView/DesktopToolbar'
|
||||
import FileBrowser from '@/components/FilesView/FileBrowser'
|
||||
import ContextMenu from '@/components/FilesView/ContextMenu'
|
||||
import {ResizeSensor} from 'css-element-queries'
|
||||
import {mapGetters} from 'vuex'
|
||||
import {events} from '@/bus'
|
||||
|
||||
|
||||
@@ -0,0 +1,166 @@
|
||||
<template>
|
||||
<div class="dropzone" :class="{ 'is-error': error }">
|
||||
<input
|
||||
ref="file"
|
||||
type="file"
|
||||
@change="showImagePreview($event)"
|
||||
class="dummy"
|
||||
/>
|
||||
<img
|
||||
ref="image"
|
||||
:src="imagePreview"
|
||||
class="image-preview"
|
||||
v-if="imagePreview"
|
||||
/>
|
||||
|
||||
<div class="dropzone-message" v-show="! isData">
|
||||
<upload-icon size="19" class="icon-upload"></upload-icon>
|
||||
<span class="dropzone-title">
|
||||
{{ $t('input_image.title') }}
|
||||
</span>
|
||||
<span class="dropzone-description">
|
||||
{{ $t('input_image.supported') }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { UploadIcon } from 'vue-feather-icons'
|
||||
|
||||
export default {
|
||||
name: 'ImageInput',
|
||||
props: [
|
||||
'image', 'error'
|
||||
],
|
||||
components: {
|
||||
UploadIcon
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
imagePreview: undefined
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
isData() {
|
||||
return typeof this.imagePreview === 'undefined' || this.imagePreview === '' ? false : true
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
showImagePreview(event) {
|
||||
const imgPath = event.target.files[0].name,
|
||||
extn = imgPath
|
||||
.substring(imgPath.lastIndexOf('.') + 1)
|
||||
.toLowerCase()
|
||||
|
||||
if (['png', 'jpg', 'jpeg'].includes(extn)) {
|
||||
const file = event.target.files[0],
|
||||
reader = new FileReader()
|
||||
|
||||
reader.onload = () => (this.imagePreview = reader.result)
|
||||
|
||||
reader.readAsDataURL(file)
|
||||
|
||||
// Update user avatar
|
||||
this.$emit('input', event.target.files[0])
|
||||
} else {
|
||||
alert( this.$t('validation_errors.wrong_image') )
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
// If has default image then load
|
||||
if (this.image) this.imagePreview = this.image
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import '@assets/vue-file-manager/_variables';
|
||||
@import '@assets/vue-file-manager/_mixins';
|
||||
|
||||
.dropzone {
|
||||
border: 1px dashed #a1abc2;
|
||||
border-radius: 8px;
|
||||
position: relative;
|
||||
text-align: center;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
min-height: 210px;
|
||||
|
||||
&.is-error {
|
||||
border: 2px dashed rgba(253, 57, 122, 0.3);
|
||||
|
||||
.dropzone-title {
|
||||
color: $danger;
|
||||
}
|
||||
|
||||
.icon-upload path {
|
||||
fill: $danger
|
||||
}
|
||||
}
|
||||
|
||||
input[type='file'] {
|
||||
opacity: 0;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
z-index: 1;
|
||||
width: 100%;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.image-preview {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: contain;
|
||||
left: 0;
|
||||
padding: 7px;
|
||||
display: block;
|
||||
|
||||
&.fit-image {
|
||||
object-fit: cover;
|
||||
border-radius: 12px;
|
||||
overflow: hidden;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.dropzone-message {
|
||||
padding: 50px 0;
|
||||
width: 100%;
|
||||
|
||||
.dropzone-title {
|
||||
@include font-size(16);
|
||||
font-weight: 700;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.dropzone-description {
|
||||
color: $text_muted;
|
||||
@include font-size(12);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
.dropzone {
|
||||
|
||||
.dropzone-message {
|
||||
|
||||
.icon-upload {
|
||||
path, polyline, line {
|
||||
stroke: $theme;
|
||||
}
|
||||
}
|
||||
|
||||
.dropzone-description {
|
||||
color: $dark_mode_text_secondary;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -115,9 +115,9 @@
|
||||
}
|
||||
|
||||
.input-area {
|
||||
border: 1px solid #ebebeb;
|
||||
justify-content: space-between;
|
||||
background: $light_mode_input_background;
|
||||
border: 1px solid transparent;
|
||||
@include transition(150ms);
|
||||
align-items: center;
|
||||
border-radius: 8px;
|
||||
@@ -182,6 +182,7 @@
|
||||
|
||||
.input-area {
|
||||
background: $dark_mode_foreground;
|
||||
border-color: $dark_mode_foreground;
|
||||
|
||||
.option-icon {
|
||||
path {
|
||||
|
||||
@@ -25,7 +25,6 @@
|
||||
@include font-size(19);
|
||||
margin-bottom: 15px;
|
||||
display: block;
|
||||
//color: $theme;
|
||||
}
|
||||
|
||||
.description {
|
||||
@@ -46,6 +45,19 @@
|
||||
}
|
||||
}
|
||||
|
||||
/deep/ input {
|
||||
|
||||
&[type='text'],
|
||||
&[type='number'],
|
||||
.input-area {
|
||||
background: white;
|
||||
}
|
||||
}
|
||||
|
||||
/deep/ .input-area {
|
||||
background: white;
|
||||
}
|
||||
|
||||
/deep/ .form {
|
||||
margin-top: 20px;
|
||||
|
||||
@@ -83,6 +95,16 @@
|
||||
@media only screen and (max-width: 690px) {
|
||||
|
||||
.setup-box {
|
||||
padding: 15px;
|
||||
|
||||
.title {
|
||||
@include font-size(17);
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.description {
|
||||
@include font-size(14);
|
||||
}
|
||||
|
||||
/deep/ .form.block-form {
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
{
|
||||
icon: 'settings',
|
||||
title: this.$t('menu.settings'),
|
||||
routeName: 'MobileSettings',
|
||||
routeName: 'Profile',
|
||||
isVisible: true,
|
||||
},
|
||||
{
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
|
||||
.fade-enter-active,
|
||||
.fade-leave-active {
|
||||
transition: 0.8s ease;
|
||||
transition: 0.3s ease;
|
||||
}
|
||||
|
||||
.fade-enter,
|
||||
@@ -107,6 +107,7 @@
|
||||
justify-content: center;
|
||||
padding: 0;
|
||||
font-size: 20px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
&.success {
|
||||
@@ -133,4 +134,28 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 690px) {
|
||||
|
||||
.toastr-item {
|
||||
margin-bottom: 0;
|
||||
margin-top: 20px;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.fade-enter,
|
||||
.fade-leave-to {
|
||||
opacity: 0;
|
||||
@include transform(translateY(100%));
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
.toastr-item {
|
||||
|
||||
&.success, &.danger {
|
||||
background: $dark_mode_foreground;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -48,4 +48,15 @@
|
||||
top: 30px;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 690px) {
|
||||
|
||||
#toastr-wrapper {
|
||||
top: initial;
|
||||
right: 15px;
|
||||
left: 15px;
|
||||
bottom: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="page-header" @click="goHome">
|
||||
<div class="icon" v-if="isSmallAppSize">
|
||||
<FontAwesomeIcon icon="chevron-left" />
|
||||
<div class="page-header">
|
||||
<div class="go-back" v-if="canBack" @click="$router.back()">
|
||||
<chevron-left-icon size="17"></chevron-left-icon>
|
||||
</div>
|
||||
<div class="content">
|
||||
<h1 class="title">{{ title }}</h1>
|
||||
@@ -10,28 +10,16 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {mapGetters} from 'vuex'
|
||||
import {events} from '@/bus'
|
||||
import { ChevronLeftIcon } from 'vue-feather-icons'
|
||||
|
||||
export default {
|
||||
name: 'PageHeader',
|
||||
props: [
|
||||
'title'
|
||||
'title', 'canBack'
|
||||
],
|
||||
computed: {
|
||||
...mapGetters(['appSize']),
|
||||
isSmallAppSize() {
|
||||
return this.appSize === 'small'
|
||||
}
|
||||
components: {
|
||||
ChevronLeftIcon
|
||||
},
|
||||
methods: {
|
||||
goHome() {
|
||||
if (this.isSmallAppSize) {
|
||||
events.$emit('show:sidebar')
|
||||
this.$router.push({name: 'Files'})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -55,10 +43,14 @@
|
||||
color: $text;
|
||||
}
|
||||
|
||||
.icon {
|
||||
@include font-size(16);
|
||||
margin-right: 15px;
|
||||
.go-back {
|
||||
margin-right: 10px;
|
||||
cursor: pointer;
|
||||
|
||||
svg {
|
||||
vertical-align: middle;
|
||||
margin-top: -4px;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -173,6 +173,7 @@
|
||||
.table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
overflow-x: auto;
|
||||
|
||||
tr {
|
||||
width: 100%;
|
||||
@@ -194,13 +195,13 @@
|
||||
|
||||
tr {
|
||||
td {
|
||||
padding-top: 10px;
|
||||
padding-bottom: 10px;
|
||||
padding: 12px;
|
||||
|
||||
span {
|
||||
color: #AFAFAF;
|
||||
font-weight: 700;
|
||||
@include font-size(12);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
&.sortable {
|
||||
@@ -243,8 +244,7 @@
|
||||
}
|
||||
|
||||
td {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
padding: 12px;
|
||||
|
||||
&:last-child {
|
||||
button {
|
||||
@@ -332,6 +332,18 @@
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 690px) {
|
||||
.paginator-wrapper {
|
||||
display: block;
|
||||
text-align: center;
|
||||
|
||||
.paginator-info {
|
||||
margin-top: 10px;
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
|
||||
.table {
|
||||
|
||||
@@ -80,8 +80,8 @@
|
||||
}
|
||||
|
||||
.image-preview {
|
||||
width: 56px;
|
||||
height: 56px;
|
||||
width: 62px;
|
||||
height: 62px;
|
||||
object-fit: cover;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
</div>
|
||||
</router-link>
|
||||
|
||||
<router-link v-if="app.user.role === 'admin'" :to="{name: 'Users'}" :class="{'is-active': $isThisRoute($route, ['Users'])}" class="icon-navigation-item users">
|
||||
<router-link v-if="app.user.role === 'admin'" :to="{name: 'Users'}" :class="{'is-active': $isThisRoute($route, ['Users', 'User', 'UserDetail', 'UserStorage', 'UserPassword', 'UserDelete'])}" class="icon-navigation-item users">
|
||||
<div class="button-icon">
|
||||
<users-icon size="19"></users-icon>
|
||||
</div>
|
||||
@@ -190,6 +190,7 @@
|
||||
|
||||
@media only screen and (max-width: 1024px) {
|
||||
.menu-bar {
|
||||
min-width: 60px;
|
||||
width: 60px;
|
||||
}
|
||||
|
||||
|
||||
@@ -3,22 +3,22 @@
|
||||
"create_new_password": "创建新密码"
|
||||
},
|
||||
"routes_title": {
|
||||
"profile": "User Profile",
|
||||
"profile": "My Profile",
|
||||
"settings_password": "Change Password",
|
||||
"settings_storage": "Storage",
|
||||
"settings_mobile": "Settings",
|
||||
"users_list": "User Management",
|
||||
"users_user": "User",
|
||||
"users_detail": "Detail",
|
||||
"users_storage_usage": "Storage Usage",
|
||||
"users_password": "Password",
|
||||
"users_delete": "Delete User"
|
||||
"users_delete": "Delete User",
|
||||
"user_create": "Create User"
|
||||
},
|
||||
"profile": {
|
||||
"store_pass": "保存您的密码",
|
||||
"change_pass": "修改您的密码",
|
||||
"profile_info": "用户信息",
|
||||
"photo_description": "修改您的头像",
|
||||
"photo_supported": "支持的格式 .png, .jpg, .jpeg."
|
||||
"profile_info": "用户信息"
|
||||
},
|
||||
"page_registration": {
|
||||
"title": "创建一个新用户",
|
||||
@@ -307,13 +307,23 @@
|
||||
"role": "Role",
|
||||
"storage_used": "Storage Used",
|
||||
"storage_capacity": "Storage Capacity",
|
||||
"created_at": "Registered",
|
||||
"action": "Action"
|
||||
},
|
||||
"create_user": {
|
||||
"group_details": "Account Details",
|
||||
"group_settings": "Account Settings",
|
||||
"submit": "Create User",
|
||||
"label_email": "Type E-mail",
|
||||
"label_name": "Type full name",
|
||||
"label_conf_pass": "Confirm password"
|
||||
}
|
||||
},
|
||||
"toaster": {
|
||||
"changed_user": "You successfully changed user's role!",
|
||||
"sended_password": "You successfully send user email for reset password!",
|
||||
"changed_capacity": "You successfully changed user's storage size!"
|
||||
"changed_capacity": "You successfully changed user's storage size!",
|
||||
"created_user": "User was created successfully!"
|
||||
},
|
||||
"roles": {
|
||||
"admin": "Admin",
|
||||
@@ -321,5 +331,9 @@
|
||||
},
|
||||
"datatable": {
|
||||
"paginate_info": "Showing 1 - {visible} from {total} records"
|
||||
},
|
||||
"input_image": {
|
||||
"title": "Upload Image",
|
||||
"supported": "Supported formats are .png, .jpg, .jpeg."
|
||||
}
|
||||
}
|
||||
@@ -3,22 +3,22 @@
|
||||
"create_new_password": "create-new-password"
|
||||
},
|
||||
"routes_title": {
|
||||
"profile": "User Profile",
|
||||
"profile": "My Profile",
|
||||
"settings_password": "Change Password",
|
||||
"settings_storage": "Storage",
|
||||
"settings_mobile": "Settings",
|
||||
"users_list": "User Management",
|
||||
"users_user": "User",
|
||||
"users_detail": "Detail",
|
||||
"users_storage_usage": "Storage Usage",
|
||||
"users_password": "Password",
|
||||
"users_delete": "Delete User"
|
||||
"users_delete": "Delete User",
|
||||
"user_create": "Create User"
|
||||
},
|
||||
"profile": {
|
||||
"store_pass": "Store New Password",
|
||||
"change_pass": "Change Password",
|
||||
"profile_info": "Profile Information",
|
||||
"photo_description": "Change your avatar",
|
||||
"photo_supported": "Supported formats are .png, .jpg, .jpeg."
|
||||
"profile_info": "Profile Information"
|
||||
},
|
||||
"page_registration": {
|
||||
"title": "Create New Account",
|
||||
@@ -307,13 +307,23 @@
|
||||
"role": "Role",
|
||||
"storage_used": "Storage Used",
|
||||
"storage_capacity": "Storage Capacity",
|
||||
"created_at": "Registered",
|
||||
"action": "Action"
|
||||
},
|
||||
"create_user": {
|
||||
"group_details": "Account Details",
|
||||
"group_settings": "Account Settings",
|
||||
"submit": "Create User",
|
||||
"label_email": "Type E-mail",
|
||||
"label_name": "Type full name",
|
||||
"label_conf_pass": "Confirm password"
|
||||
}
|
||||
},
|
||||
"toaster": {
|
||||
"changed_user": "You successfully changed user's role!",
|
||||
"sended_password": "You successfully send user email for reset password!",
|
||||
"changed_capacity": "You successfully changed user's storage size!"
|
||||
"changed_capacity": "You successfully changed user's storage size!",
|
||||
"created_user": "User was created successfully!"
|
||||
},
|
||||
"roles": {
|
||||
"admin": "Admin",
|
||||
@@ -321,5 +331,9 @@
|
||||
},
|
||||
"datatable": {
|
||||
"paginate_info": "Showing 1 - {visible} from {total} records"
|
||||
},
|
||||
"input_image": {
|
||||
"title": "Upload Image",
|
||||
"supported": "Supported formats are .png, .jpg, .jpeg."
|
||||
}
|
||||
}
|
||||
@@ -3,22 +3,22 @@
|
||||
"create_new_password": "vytvorit-nove-heslo"
|
||||
},
|
||||
"routes_title": {
|
||||
"profile": "Uživateľský profil",
|
||||
"profile": "Môj profil",
|
||||
"settings_password": "Zmeniť heslo",
|
||||
"settings_storage": "Úložisko",
|
||||
"settings_mobile": "Nastavenia",
|
||||
"users_list": "Správca uživateľov",
|
||||
"users_user": "Uživateľ",
|
||||
"users_detail": "Detail",
|
||||
"users_storage_usage": "Využitie úložiska",
|
||||
"users_password": "Heslo",
|
||||
"users_delete": "Vymazať uživateľa"
|
||||
"users_delete": "Vymazať uživateľa",
|
||||
"user_create": "Vytvoriť uživateľa"
|
||||
},
|
||||
"profile": {
|
||||
"store_pass": "Uložiť nové heslo",
|
||||
"change_pass": "Zmeniť heslo",
|
||||
"profile_info": "Profil",
|
||||
"photo_description": "Zmeň svoj avatar",
|
||||
"photo_supported": "Podporované formáty sú .png, .jpg, .jpeg."
|
||||
"profile_info": "Profil"
|
||||
},
|
||||
"page_registration": {
|
||||
"title": "Vytvorenie nového účtu",
|
||||
@@ -307,13 +307,23 @@
|
||||
"role": "Rola",
|
||||
"storage_used": "Využitie úložiska",
|
||||
"storage_capacity": "Kapacita úložiska",
|
||||
"created_at": "Registrovaný",
|
||||
"action": "Akcia"
|
||||
},
|
||||
"create_user": {
|
||||
"group_details": "Detail účtu",
|
||||
"group_settings": "Nastavenia účtu",
|
||||
"submit": "Vytvoriť uživateľa",
|
||||
"label_email": "Napíšte E-mail",
|
||||
"label_name": "Napíšte celé meno",
|
||||
"label_conf_pass": "Potvrďte heslo"
|
||||
}
|
||||
},
|
||||
"toaster": {
|
||||
"changed_user": "Úspešne ste zmenili rolu užívateľa",
|
||||
"sended_password": "Úspešne ste odoslali email uživateľovi pre reset hesla!",
|
||||
"changed_capacity": "Úspešne ste zmenili kapacitu úložiska uživateľa!"
|
||||
"changed_capacity": "Úspešne ste zmenili kapacitu úložiska uživateľa!",
|
||||
"created_user": "Úspešne ste vytvorili uživateľa1"
|
||||
},
|
||||
"roles": {
|
||||
"admin": "Admin",
|
||||
@@ -321,5 +331,9 @@
|
||||
},
|
||||
"datatable": {
|
||||
"paginate_info": "Zobrazuje sa 1 - {visible} z {total} položiek"
|
||||
},
|
||||
"input_image": {
|
||||
"title": "Vložte obrázok",
|
||||
"supported": "Podporované formáty sú .png, .jpg, .jpeg."
|
||||
}
|
||||
}
|
||||
Vendored
+11
-1
@@ -23,6 +23,7 @@ import Admin from './views/Admin'
|
||||
import Users from './views/Admin/Users'
|
||||
|
||||
import User from './views/Admin/Users/User'
|
||||
import UserCreate from './views/Admin/Users/UserCreate'
|
||||
import UserDetail from './views/Admin/Users/UserTabs/UserDetail'
|
||||
import UserDelete from './views/Admin/Users/UserTabs/UserDelete'
|
||||
import UserStorage from './views/Admin/Users/UserTabs/UserStorage'
|
||||
@@ -120,7 +121,16 @@ const router = new Router({
|
||||
component: Users,
|
||||
meta: {
|
||||
requiresAuth: true,
|
||||
title: 'Users'
|
||||
title: i18n.t('routes_title.users_list')
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'UserCreate',
|
||||
path: '/admin/user/create',
|
||||
component: UserCreate,
|
||||
meta: {
|
||||
requiresAuth: true,
|
||||
title: i18n.t('routes_title.user_create')
|
||||
},
|
||||
},
|
||||
{
|
||||
|
||||
Vendored
+13
-5
@@ -1,10 +1,21 @@
|
||||
import i18n from '@/i18n/index'
|
||||
|
||||
const defaultState = {
|
||||
fileInfoPanelVisible: localStorage.getItem('file_info_visibility') == 'true' || false,
|
||||
FilePreviewType: localStorage.getItem('preview_type') || 'list',
|
||||
appSize: undefined,
|
||||
config: undefined,
|
||||
authorized: undefined,
|
||||
homeDirectory: undefined,
|
||||
roles: [
|
||||
{
|
||||
label: i18n.t('roles.admin'),
|
||||
value: 'admin',
|
||||
},
|
||||
{
|
||||
label: i18n.t('roles.user'),
|
||||
value: 'user',
|
||||
},
|
||||
],
|
||||
}
|
||||
const actions = {
|
||||
changePreviewType: ({commit, dispatch, state, getters}) => {
|
||||
@@ -40,9 +51,6 @@ const mutations = {
|
||||
|
||||
localStorage.setItem('file_info_visibility', isVisible)
|
||||
},
|
||||
SET_APP_WIDTH(state, scale) {
|
||||
state.appSize = scale
|
||||
},
|
||||
SET_AUTHORIZED(state, data) {
|
||||
state.authorized = data
|
||||
},
|
||||
@@ -53,7 +61,7 @@ const mutations = {
|
||||
const getters = {
|
||||
fileInfoVisible: state => state.fileInfoPanelVisible,
|
||||
FilePreviewType: state => state.FilePreviewType,
|
||||
appSize: state => state.appSize,
|
||||
roles: state => state.roles,
|
||||
api: state => state.config.api,
|
||||
config: state => state.config,
|
||||
homeDirectory: state => state.homeDirectory,
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<template>
|
||||
<section id="viewport">
|
||||
|
||||
<ContentSidebar>
|
||||
<ContentSidebar v-if="false">
|
||||
|
||||
<!--Locations-->
|
||||
<ContentGroup :title="$t('admin_menu.admin_label')" class="navigator">
|
||||
<div class="menu-list-wrapper">
|
||||
<div class="menu-list-wrapper vertical">
|
||||
<router-link :to="{name: 'Users'}" class="menu-list-item link">
|
||||
<div class="icon">
|
||||
<users-icon size="17"></users-icon>
|
||||
@@ -18,7 +18,9 @@
|
||||
</ContentGroup>
|
||||
</ContentSidebar>
|
||||
|
||||
<router-view/>
|
||||
<keep-alive :include="['Users']">
|
||||
<router-view/>
|
||||
</keep-alive>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -1,14 +1,26 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<div id="page-content" class="full-width" v-if="! isLoading">
|
||||
<div id="page-content" class="medium-width" v-if="! isLoading">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :title="$router.currentRoute.meta.title"/>
|
||||
|
||||
<div class="content-page">
|
||||
<div class="table-tools">
|
||||
<div class="buttons">
|
||||
<router-link :to="{name: 'UserCreate'}">
|
||||
<MobileActionButton icon="user-plus">
|
||||
{{ $t('admin_page_user.create_user.submit') }}
|
||||
</MobileActionButton>
|
||||
</router-link>
|
||||
</div>
|
||||
<div class="searching">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<DatatableWrapper :paginator="true" :columns="columns" :data="users" class="table table-users">
|
||||
<template scope="{ row }">
|
||||
<tr>
|
||||
<td style="width: 320px">
|
||||
<td style="width: 300px">
|
||||
<router-link :to="{name: 'UserDetail', params: {id: row.data.id}}" tag="div" class="user-thumbnail">
|
||||
<div class="avatar">
|
||||
<img :src="row.data.attributes.avatar" :alt="row.data.attributes.name">
|
||||
@@ -34,6 +46,11 @@
|
||||
{{ row.data.attributes.storage.capacity_formatted }}
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<span class="cell-item">
|
||||
{{ row.data.attributes.created_at_formatted }}
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<div class="action-icons">
|
||||
<router-link :to="{name: 'UserDetail', params: {id: row.data.id}}">
|
||||
@@ -57,8 +74,10 @@
|
||||
|
||||
<script>
|
||||
import DatatableWrapper from '@/components/Others/Tables/DatatableWrapper'
|
||||
import MobileActionButton from '@/components/FilesView/MobileActionButton'
|
||||
import MobileHeader from '@/components/Mobile/MobileHeader'
|
||||
import SectionTitle from '@/components/Others/SectionTitle'
|
||||
import ButtonBase from '@/components/FilesView/ButtonBase'
|
||||
import {Trash2Icon, Edit2Icon} from "vue-feather-icons";
|
||||
import PageHeader from '@/components/Others/PageHeader'
|
||||
import ColorLabel from '@/components/Others/ColorLabel'
|
||||
@@ -68,11 +87,13 @@
|
||||
export default {
|
||||
name: 'Profile',
|
||||
components: {
|
||||
MobileActionButton,
|
||||
DatatableWrapper,
|
||||
SectionTitle,
|
||||
MobileHeader,
|
||||
Trash2Icon,
|
||||
PageHeader,
|
||||
ButtonBase,
|
||||
ColorLabel,
|
||||
Edit2Icon,
|
||||
Spinner,
|
||||
@@ -84,27 +105,32 @@
|
||||
columns: [
|
||||
{
|
||||
label: this.$t('admin_page_user.table.name'),
|
||||
field: 'attributes.name',
|
||||
field: 'data.attributes.name',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
label: this.$t('admin_page_user.table.role'),
|
||||
field: 'attributes.role',
|
||||
field: 'data.attributes.role',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
label: this.$t('admin_page_user.table.storage_used'),
|
||||
field: 'attributes.storage.used',
|
||||
field: 'data.attributes.storage.used',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
label: this.$t('admin_page_user.table.storage_capacity'),
|
||||
field: 'attributes.storage.capacity',
|
||||
field: 'data.attributes.storage.capacity',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
label: this.$t('admin_page_user.table.created_at'),
|
||||
field: 'data.attributes.created_at_formatted',
|
||||
sortable: true
|
||||
},
|
||||
{
|
||||
label: this.$t('admin_page_user.table.action'),
|
||||
field: 'action',
|
||||
field: 'data.action',
|
||||
sortable: false
|
||||
},
|
||||
],
|
||||
@@ -136,7 +162,18 @@
|
||||
@import '@assets/vue-file-manager/_variables';
|
||||
@import '@assets/vue-file-manager/_mixins';
|
||||
|
||||
.table-tools {
|
||||
background: white;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding: 15px 0 10px;
|
||||
position: sticky;
|
||||
top: 40px;
|
||||
z-index: 9;
|
||||
}
|
||||
|
||||
.action-icons {
|
||||
white-space: nowrap;
|
||||
|
||||
a {
|
||||
display: inline-block;
|
||||
@@ -166,6 +203,7 @@
|
||||
|
||||
.cell-item {
|
||||
@include font-size(15);
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -188,8 +226,15 @@
|
||||
|
||||
.info {
|
||||
|
||||
.name {
|
||||
.name, .email {
|
||||
max-width: 150px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.name {
|
||||
@include font-size(15);
|
||||
line-height: 1;
|
||||
}
|
||||
@@ -201,8 +246,18 @@
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 690px) {
|
||||
.table-tools {
|
||||
padding: 0 0 5px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
|
||||
.table-tools {
|
||||
background: $dark_mode_background;
|
||||
}
|
||||
|
||||
.action-icons {
|
||||
|
||||
.icon {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<template>
|
||||
<div id="single-page" v-if="app">
|
||||
<div id="page-content" v-if="! isLoading">
|
||||
<div id="page-content" class="medium-width" v-if="! isLoading">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :can-back="true" :title="$router.currentRoute.meta.title"/>
|
||||
|
||||
<div class="content-page">
|
||||
|
||||
@@ -168,7 +168,6 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
@@ -0,0 +1,234 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<div id="page-content" class="small-width">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :can-back="true" :title="$router.currentRoute.meta.title"/>
|
||||
|
||||
<div class="content-page">
|
||||
<ValidationObserver @submit.prevent="createUser" ref="createUser" v-slot="{ invalid }" tag="form" class="form block-form">
|
||||
|
||||
<div class="form-group">
|
||||
<b class="form-group-label">
|
||||
{{ $t('admin_page_user.create_user.group_details') }}
|
||||
</b>
|
||||
|
||||
<!--Avatar-->
|
||||
<div class="block-wrapper">
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="avatar" v-slot="{ errors }">
|
||||
<ImageInput v-model="user.avatar" :error="errors[0]" />
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<!--Email-->
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_email') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="email" rules="required" v-slot="{ errors }">
|
||||
<input v-model="user.email" :placeholder="$t('admin_page_user.create_user.label_email')" type="email" :class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<!--Name-->
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_name') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="user name" rules="required" v-slot="{ errors }">
|
||||
<input v-model="user.name" :placeholder="$t('admin_page_user.create_user.label_name')" type="text" :class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<!--Password-->
|
||||
<div class="wrapper-inline">
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_pass') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="password" rules="required" v-slot="{ errors }">
|
||||
<input v-model="user.password" :placeholder="$t('page_registration.placeholder_pass')" type="password" :class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_confirm_pass') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="password confirm" rules="required" v-slot="{ errors }">
|
||||
<input v-model="user.password_confirmation" :placeholder="$t('admin_page_user.create_user.label_conf_pass')" type="password" :class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<b class="form-group-label">
|
||||
{{ $t('admin_page_user.create_user.group_settings') }}
|
||||
</b>
|
||||
|
||||
|
||||
<!--User Role-->
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('admin_page_user.select_role') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="permission" rules="required" v-slot="{ errors }">
|
||||
<SelectInput v-model="user.role" :options="roles" :placeholder="$t('admin_page_user.select_role')" :isError="errors[0]"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<!--Storage Capacity-->
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('admin_page_user.label_change_capacity') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="storage capacity" rules="required" v-slot="{ errors }">
|
||||
<input v-model="user.storage_capacity" min="1" max="999999999" :placeholder="$t('admin_page_user.label_change_capacity')" type="number" :class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<ButtonBase :disabled="isLoading" :loading="isLoading" button-style="theme" type="submit">
|
||||
{{ $t('admin_page_user.create_user.submit') }}
|
||||
</ButtonBase>
|
||||
</div>
|
||||
</ValidationObserver>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {ValidationProvider, ValidationObserver} from 'vee-validate/dist/vee-validate.full'
|
||||
import SelectInput from '@/components/Others/Forms/SelectInput'
|
||||
import ImageInput from '@/components/Others/Forms/ImageInput'
|
||||
import MobileHeader from '@/components/Mobile/MobileHeader'
|
||||
import SectionTitle from '@/components/Others/SectionTitle'
|
||||
import ButtonBase from '@/components/FilesView/ButtonBase'
|
||||
import PageHeader from '@/components/Others/PageHeader'
|
||||
import {required} from 'vee-validate/dist/rules'
|
||||
import { mapGetters } from 'vuex'
|
||||
import {events} from "@/bus"
|
||||
import axios from 'axios'
|
||||
|
||||
export default {
|
||||
name: 'Profile',
|
||||
components: {
|
||||
ValidationProvider,
|
||||
ValidationObserver,
|
||||
SectionTitle,
|
||||
MobileHeader,
|
||||
SelectInput,
|
||||
ButtonBase,
|
||||
ImageInput,
|
||||
PageHeader,
|
||||
required,
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['roles']),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
isLoading: false,
|
||||
user: {
|
||||
role: '',
|
||||
avatar: undefined,
|
||||
name: '',
|
||||
email: '',
|
||||
password: '',
|
||||
password_confirmation: '',
|
||||
storage_capacity: 5,
|
||||
},
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async createUser() {
|
||||
|
||||
// Validate fields
|
||||
const isValid = await this.$refs.createUser.validate();
|
||||
|
||||
if (!isValid) return;
|
||||
|
||||
// Start loading
|
||||
this.isLoading = true
|
||||
|
||||
// Create form
|
||||
let formData = new FormData()
|
||||
|
||||
// Add image to form
|
||||
formData.append('name', this.user.name)
|
||||
formData.append('role', this.user.role)
|
||||
formData.append('email', this.user.email)
|
||||
formData.append('password', this.user.password)
|
||||
formData.append('storage_capacity', this.user.storage_capacity)
|
||||
formData.append('password_confirmation', this.user.password_confirmation)
|
||||
|
||||
// Append avatar if exist
|
||||
if (this.user.avatar)
|
||||
formData.append('avatar', this.user.avatar)
|
||||
|
||||
// Send request to get user token
|
||||
axios
|
||||
.post('/api/users/create', formData, {
|
||||
headers: {
|
||||
'Content-Type': 'multipart/form-data',
|
||||
}
|
||||
})
|
||||
.then(response => {
|
||||
|
||||
// End loading
|
||||
this.isLoading = false
|
||||
|
||||
// Show toaster
|
||||
events.$emit('toaster', {
|
||||
type: 'success',
|
||||
message: this.$t('toaster.created_user'),
|
||||
})
|
||||
|
||||
// Go to User page
|
||||
this.$router.push({name: 'UserDetail', params: {id: response.data.data.id}})
|
||||
})
|
||||
.catch(error => {
|
||||
|
||||
// Validation errors
|
||||
if (error.response.status == 422) {
|
||||
|
||||
// Email validation error
|
||||
if (error.response.data.errors['email']) {
|
||||
|
||||
this.$refs.createUser.setErrors({
|
||||
'email': error.response.data.errors['email']
|
||||
});
|
||||
}
|
||||
|
||||
// Password validation error
|
||||
if (error.response.data.errors['password']) {
|
||||
|
||||
this.$refs.createUser.setErrors({
|
||||
'password': error.response.data.errors['password']
|
||||
});
|
||||
}
|
||||
|
||||
// Password validation error
|
||||
if (error.response.data.errors['storage_capacity']) {
|
||||
|
||||
this.$refs.createUser.setErrors({
|
||||
'storage capacity': 'The storage capacity must be lower than 10 digit number.'
|
||||
});
|
||||
}
|
||||
} else {
|
||||
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('popup_error.title'),
|
||||
message: this.$t('popup_error.message'),
|
||||
})
|
||||
}
|
||||
|
||||
// End loading
|
||||
this.isLoading = false
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import '@assets/vue-file-manager/_variables';
|
||||
@import '@assets/vue-file-manager/_mixins';
|
||||
@import '@assets/vue-file-manager/_forms';
|
||||
</style>
|
||||
@@ -89,6 +89,15 @@
|
||||
|
||||
this.$router.push({name: 'Users'})
|
||||
})
|
||||
.catch(() => {
|
||||
|
||||
this.isSendingRequest = false
|
||||
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('popup_error.title'),
|
||||
message: this.$t('popup_error.message'),
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,6 +64,7 @@
|
||||
import ButtonBase from '@/components/FilesView/ButtonBase'
|
||||
import SetupBox from '@/components/Others/Forms/SetupBox'
|
||||
import {required} from 'vee-validate/dist/rules'
|
||||
import { mapGetters } from 'vuex'
|
||||
import {events} from "@/bus"
|
||||
import axios from 'axios'
|
||||
|
||||
@@ -81,20 +82,13 @@
|
||||
SetupBox,
|
||||
required,
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['roles']),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
isLoading: false,
|
||||
isSendingRequest: false,
|
||||
roles: [
|
||||
{
|
||||
label: this.$t('roles.admin'),
|
||||
value: 'admin',
|
||||
},
|
||||
{
|
||||
label: this.$t('roles.user'),
|
||||
value: 'user',
|
||||
},
|
||||
],
|
||||
userRole: undefined,
|
||||
}
|
||||
},
|
||||
@@ -129,8 +123,14 @@
|
||||
message: this.$t('toaster.changed_user'),
|
||||
})
|
||||
})
|
||||
.catch(error => {
|
||||
.catch(() => {
|
||||
|
||||
this.isSendingRequest = false
|
||||
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('popup_error.title'),
|
||||
message: this.$t('popup_error.message'),
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -57,6 +57,15 @@
|
||||
message: this.$t('toaster.sended_password'),
|
||||
})
|
||||
})
|
||||
.catch(() => {
|
||||
|
||||
this.isSendingRequest = false
|
||||
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('popup_error.title'),
|
||||
message: this.$t('popup_error.message'),
|
||||
})
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,6 +22,8 @@
|
||||
<input v-model="capacity"
|
||||
:placeholder="$t('admin_page_user.label_change_capacity')"
|
||||
type="number"
|
||||
min="1"
|
||||
max="999999999"
|
||||
:class="{'is-error': errors[0]}"
|
||||
/>
|
||||
<ButtonBase :loading="isSendingRequest" :disabled="isSendingRequest" type="submit" button-style="theme" class="submit-button">
|
||||
@@ -106,6 +108,23 @@
|
||||
.catch(error => {
|
||||
|
||||
this.isSendingRequest = false
|
||||
|
||||
if (error.response.status == 422) {
|
||||
|
||||
// Password validation error
|
||||
if (error.response.data.errors['attributes.storage_capacity']) {
|
||||
|
||||
this.$refs.changeStorageCapacity.setErrors({
|
||||
'Capacity': 'The storage capacity must be lower than 10 digit number.'
|
||||
});
|
||||
}
|
||||
} else {
|
||||
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('popup_error.title'),
|
||||
message: this.$t('popup_error.message'),
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
getStorageDetails() {
|
||||
|
||||
@@ -86,8 +86,8 @@
|
||||
return {
|
||||
isLoading: false,
|
||||
checkedAccount: undefined,
|
||||
loginPassword: 'vuefilemanager',
|
||||
loginEmail: 'howdy@hi5ve.digital',
|
||||
loginPassword: '',
|
||||
loginEmail: '',
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
<!--Locations-->
|
||||
<ContentGroup :title="$t('sidebar.locations_title')">
|
||||
<div class="menu-list-wrapper">
|
||||
<div class="menu-list-wrapper vertical">
|
||||
<a class="menu-list-item link" :class="{'is-active': $isThisLocation(['base'])}" @click="goHome">
|
||||
<div class="icon">
|
||||
<home-icon size="17"></home-icon>
|
||||
@@ -38,7 +38,7 @@
|
||||
<!--Favourites-->
|
||||
<ContentGroup :title="$t('sidebar.favourites')">
|
||||
|
||||
<div class="menu-list-wrapper favourites"
|
||||
<div class="menu-list-wrapper vertical favourites"
|
||||
:class="{ 'is-dragenter': area }"
|
||||
@dragover.prevent="dragEnter"
|
||||
@dragleave="dragLeave"
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
<!--Navigator-->
|
||||
<ContentGroup :title="$t('sidebar.locations_title')">
|
||||
<div class="menu-list-wrapper">
|
||||
<div class="menu-list-wrapper vertical">
|
||||
<li class="menu-list-item link" :class="{'is-active': $isThisLocation(['shared'])}" @click="getShared()">
|
||||
<div class="icon">
|
||||
<link-icon size="17"></link-icon>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
<!--Tools-->
|
||||
<ContentGroup :title="$t('sidebar.tools_title')" class="navigator">
|
||||
<div class="menu-list-wrapper">
|
||||
<div class="menu-list-wrapper vertical">
|
||||
<div class="menu-list-item link" @click="emptyTrash()">
|
||||
<div class="icon">
|
||||
<trash-icon size="17"></trash-icon>
|
||||
|
||||
+113
-33
@@ -1,15 +1,28 @@
|
||||
<template>
|
||||
<section id="viewport">
|
||||
<div id="single-page" v-if="app">
|
||||
<div id="page-content" class="medium-width" v-if="! isLoading">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :title="$router.currentRoute.meta.title"/>
|
||||
|
||||
<ContentSidebar>
|
||||
<div class="content-page">
|
||||
|
||||
<!--User Headline-->
|
||||
<UserHeadline class="user-headline"/>
|
||||
<!--User thumbnail-->
|
||||
<div class="user-thumbnail">
|
||||
<div class="avatar">
|
||||
<UserImageInput
|
||||
v-model="avatar"
|
||||
:avatar="app.user.avatar"
|
||||
/>
|
||||
</div>
|
||||
<div class="info">
|
||||
<b class="name">{{ app.user.name }}</b>
|
||||
<span class="email">{{ app.user.email }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--Locations-->
|
||||
<ContentGroup title="Menu" class="navigator">
|
||||
<div class="menu-list-wrapper">
|
||||
<router-link :to="{name: 'Profile'}" class="menu-list-item link">
|
||||
<!--Page Tab links-->
|
||||
<div class="menu-list-wrapper horizontal">
|
||||
<router-link replace :to="{name: 'Profile'}" class="menu-list-item link">
|
||||
<div class="icon">
|
||||
<user-icon size="17"></user-icon>
|
||||
</div>
|
||||
@@ -17,15 +30,8 @@
|
||||
{{ $t('menu.profile') }}
|
||||
</div>
|
||||
</router-link>
|
||||
<router-link :to="{name: 'Password'}" class="menu-list-item link">
|
||||
<div class="icon">
|
||||
<lock-icon size="17"></lock-icon>
|
||||
</div>
|
||||
<div class="label">
|
||||
{{ $t('menu.password') }}
|
||||
</div>
|
||||
</router-link>
|
||||
<router-link v-if="config.storageLimit" :to="{name: 'Storage'}" class="menu-list-item link">
|
||||
|
||||
<router-link replace :to="{name: 'Storage'}" class="menu-list-item link">
|
||||
<div class="icon">
|
||||
<hard-drive-icon size="17"></hard-drive-icon>
|
||||
</div>
|
||||
@@ -33,18 +39,42 @@
|
||||
{{ $t('menu.storage') }}
|
||||
</div>
|
||||
</router-link>
|
||||
</div>
|
||||
</ContentGroup>
|
||||
</ContentSidebar>
|
||||
|
||||
<router-view/>
|
||||
</section>
|
||||
<router-link replace :to="{name: 'Password'}" class="menu-list-item link">
|
||||
<div class="icon">
|
||||
<lock-icon size="17"></lock-icon>
|
||||
</div>
|
||||
<div class="label">
|
||||
{{ $t('menu.password') }}
|
||||
</div>
|
||||
</router-link>
|
||||
|
||||
<!--<router-link replace :to="{name: 'UserDelete'}" v-if="user.attributes.name !== app.user.name" class="menu-list-item link">
|
||||
<div class="icon">
|
||||
<trash2-icon size="17"></trash2-icon>
|
||||
</div>
|
||||
<div class="label">
|
||||
{{ $t('admin_page_user.tabs.delete') }}
|
||||
</div>
|
||||
</router-link>-->
|
||||
</div>
|
||||
|
||||
<!--Router Content-->
|
||||
<router-view :user="app.user" />
|
||||
</div>
|
||||
</div>
|
||||
<div id="loader" v-if="isLoading">
|
||||
<Spinner></Spinner>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import ContentSidebar from '@/components/Sidebar/ContentSidebar'
|
||||
import ContentGroup from '@/components/Sidebar/ContentGroup'
|
||||
import UserHeadline from '@/components/Sidebar/UserHeadline'
|
||||
import UserImageInput from '@/components/Others/UserImageInput'
|
||||
import MobileHeader from '@/components/Mobile/MobileHeader'
|
||||
import PageHeader from '@/components/Others/PageHeader'
|
||||
import Spinner from '@/components/FilesView/Spinner'
|
||||
|
||||
import { mapGetters } from 'vuex'
|
||||
import {
|
||||
HardDriveIcon,
|
||||
@@ -54,23 +84,73 @@
|
||||
|
||||
export default {
|
||||
name: 'Settings',
|
||||
computed: {
|
||||
...mapGetters(['config']),
|
||||
},
|
||||
components: {
|
||||
ContentSidebar,
|
||||
UserImageInput,
|
||||
MobileHeader,
|
||||
PageHeader,
|
||||
Spinner,
|
||||
HardDriveIcon,
|
||||
UserHeadline,
|
||||
ContentGroup,
|
||||
UserIcon,
|
||||
LockIcon,
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'config', 'app'
|
||||
]),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
avatar: undefined,
|
||||
isLoading: false,
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import '@assets/vue-file-manager/_variables';
|
||||
@import '@assets/vue-file-manager/_mixins';
|
||||
|
||||
.user-headline {
|
||||
margin-bottom: 38px;
|
||||
.user-thumbnail {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
cursor: pointer;
|
||||
|
||||
.avatar {
|
||||
margin-right: 20px;
|
||||
|
||||
img {
|
||||
line-height: 0;
|
||||
width: 62px;
|
||||
height: 62px;
|
||||
border-radius: 12px;
|
||||
}
|
||||
}
|
||||
|
||||
.info {
|
||||
|
||||
.name {
|
||||
display: block;
|
||||
@include font-size(17);
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.email {
|
||||
color: $text-muted;
|
||||
@include font-size(14);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
.user-thumbnail {
|
||||
|
||||
.info {
|
||||
|
||||
.email {
|
||||
color: $dark_mode_text_secondary;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div id="shared" :class="appSize">
|
||||
<div id="shared">
|
||||
|
||||
<!--Loading Spinenr-->
|
||||
<Spinner v-if="isPageLoading"/>
|
||||
@@ -78,7 +78,6 @@
|
||||
import Vignette from '@/components/Others/Vignette'
|
||||
import Alert from '@/components/FilesView/Alert'
|
||||
import {required} from 'vee-validate/dist/rules'
|
||||
import {ResizeSensor} from 'css-element-queries'
|
||||
import {mapGetters} from 'vuex'
|
||||
import {events} from '@/bus'
|
||||
import axios from 'axios'
|
||||
@@ -103,7 +102,7 @@
|
||||
Alert,
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['config', 'sharedDetail', 'sharedFile', 'appSize']),
|
||||
...mapGetters(['config', 'sharedDetail', 'sharedFile']),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
|
||||
@@ -1,46 +1,37 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<div id="page-content" class="full-width" v-if="! isLoading">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :title="$router.currentRoute.meta.title"/>
|
||||
<div class="page-tab">
|
||||
<div class="page-tab-group">
|
||||
<ValidationObserver ref="password" @submit.prevent="resetPassword" v-slot="{ invalid }" tag="form"
|
||||
class="form block-form">
|
||||
|
||||
<div class="content-page">
|
||||
<div class="block-wrapper">
|
||||
<b class="form-group-label">{{ $t('page_create_password.label_new_pass') }}:</b>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="New Password"
|
||||
rules="required" v-slot="{ errors }">
|
||||
<input v-model="newPassword" :placeholder="$t('page_create_password.label_new_pass')"
|
||||
type="password"
|
||||
:class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<ValidationObserver ref="password" @submit.prevent="resetPassword" v-slot="{ invalid }" tag="form"
|
||||
class="form block-form">
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_create_password.label_confirm_pass') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="Confirm Your Password"
|
||||
rules="required" v-slot="{ errors }">
|
||||
<input v-model="newPasswordConfirmation"
|
||||
:placeholder="$t('page_create_password.label_confirm_pass')" type="password"
|
||||
:class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_create_password.label_new_pass') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="New Password"
|
||||
rules="required" v-slot="{ errors }">
|
||||
<input v-model="newPassword" :placeholder="$t('page_create_password.label_new_pass')"
|
||||
type="password"
|
||||
:class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_create_password.label_confirm_pass') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="Confirm Your Password"
|
||||
rules="required" v-slot="{ errors }">
|
||||
<input v-model="newPasswordConfirmation"
|
||||
:placeholder="$t('page_create_password.label_confirm_pass')" type="password"
|
||||
:class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<div class="block-wrapper">
|
||||
<ButtonBase type="submit" button-style="theme" class="confirm-form">
|
||||
{{ $t('profile.store_pass') }}
|
||||
</ButtonBase>
|
||||
</div>
|
||||
</ValidationObserver>
|
||||
</div>
|
||||
</div>
|
||||
<div id="loader" v-if="isLoading">
|
||||
<Spinner></Spinner>
|
||||
<div class="block-wrapper">
|
||||
<ButtonBase type="submit" button-style="theme" class="confirm-form">
|
||||
{{ $t('profile.store_pass') }}
|
||||
</ButtonBase>
|
||||
</div>
|
||||
</ValidationObserver>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -1,52 +1,31 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<div id="page-content" class="full-width" v-if="! isLoading">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :title="$router.currentRoute.meta.title"/>
|
||||
|
||||
<div class="content-page">
|
||||
<div class="avatar-upload">
|
||||
<UserImageInput
|
||||
v-model="avatar"
|
||||
:avatar="app.user.avatar"
|
||||
/>
|
||||
<div class="info">
|
||||
<span class="description">{{ $t('profile.photo_description') }}</span>
|
||||
<span class="supported">{{ $t('profile.photo_supported') }}</span>
|
||||
<div class="page-tab">
|
||||
<div class="page-tab-group">
|
||||
<ValidationObserver ref="account" v-slot="{ invalid }" tag="form" class="form block-form">
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_email') }}</label>
|
||||
<div class="input-wrapper">
|
||||
<input :value="app.user.email" :placeholder="$t('page_registration.placeholder_email')"
|
||||
type="email" disabled/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ValidationObserver ref="account" v-slot="{ invalid }" tag="form" class="form block-form">
|
||||
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_email') }}</label>
|
||||
<div class="input-wrapper">
|
||||
<input :value="app.user.email" :placeholder="$t('page_registration.placeholder_email')" type="email" disabled/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_name') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="Full Name" rules="required"
|
||||
v-slot="{ errors }">
|
||||
<input @keyup="$updateText('/user/profile', 'name', name)" v-model="name"
|
||||
:placeholder="$t('page_registration.placeholder_name')" type="text"
|
||||
:class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</ValidationObserver>
|
||||
</div>
|
||||
</div>
|
||||
<div id="loader" v-if="isLoading">
|
||||
<Spinner></Spinner>
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('page_registration.label_name') }}</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="Full Name" rules="required"
|
||||
v-slot="{ errors }">
|
||||
<input @keyup="$updateText('/user/profile', 'name', name)" v-model="name"
|
||||
:placeholder="$t('page_registration.placeholder_name')" type="text"
|
||||
:class="{'is-error': errors[0]}"/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</ValidationObserver>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {ValidationProvider, ValidationObserver} from 'vee-validate/dist/vee-validate.full'
|
||||
import UserImageInput from '@/components/Others/UserImageInput'
|
||||
import MobileHeader from '@/components/Mobile/MobileHeader'
|
||||
import ButtonBase from '@/components/FilesView/ButtonBase'
|
||||
import PageHeader from '@/components/Others/PageHeader'
|
||||
@@ -54,15 +33,12 @@
|
||||
import {required} from 'vee-validate/dist/rules'
|
||||
import {mapGetters} from 'vuex'
|
||||
import {debounce} from 'lodash'
|
||||
import {events} from '@/bus'
|
||||
import axios from 'axios'
|
||||
|
||||
export default {
|
||||
name: 'Profile',
|
||||
components: {
|
||||
ValidationProvider,
|
||||
ValidationObserver,
|
||||
UserImageInput,
|
||||
MobileHeader,
|
||||
PageHeader,
|
||||
ButtonBase,
|
||||
@@ -81,7 +57,6 @@
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
avatar: undefined,
|
||||
name: '',
|
||||
isLoading: false,
|
||||
}
|
||||
@@ -100,29 +75,6 @@
|
||||
@import '@assets/vue-file-manager/_mixins';
|
||||
@import '@assets/vue-file-manager/_forms';
|
||||
|
||||
.avatar-upload {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 30px;
|
||||
|
||||
.info {
|
||||
margin-left: 25px;
|
||||
|
||||
.description {
|
||||
@include font-size(15);
|
||||
font-weight: 700;
|
||||
color: $text;
|
||||
}
|
||||
|
||||
.supported {
|
||||
display: block;
|
||||
@include font-size(12);
|
||||
font-weight: 500;
|
||||
color: $light_text;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media only screen and (max-width: 960px) {
|
||||
|
||||
.form {
|
||||
@@ -136,16 +88,6 @@
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
|
||||
.avatar-upload .info {
|
||||
|
||||
.description {
|
||||
color: $dark_mode_text_primary;
|
||||
}
|
||||
|
||||
.supported {
|
||||
color: $dark_mode_text_secondary;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
@@ -1,23 +1,16 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<div id="page-content" class="full-width" v-if="! isLoading">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title"/>
|
||||
<PageHeader :title="$router.currentRoute.meta.title"/>
|
||||
|
||||
<div class="content-page">
|
||||
<SectionTitle>{{ $t('storage.sec_capacity') }}</SectionTitle>
|
||||
<StorageItemDetail type="disk" :title="$t('storage.total_used', {used: storage.attributes.used})" :percentage="storage.attributes.percentage" :used="$t('storage.total_capacity', {capacity: storage.attributes.capacity})"/>
|
||||
|
||||
<SectionTitle>{{ $t('storage.sec_details') }}</SectionTitle>
|
||||
<StorageItemDetail type="images" :title="$t('storage.images')" :percentage="storage.meta.images.percentage" :used="storage.meta.images.used" />
|
||||
<StorageItemDetail type="videos" :title="$t('storage.videos')" :percentage="storage.meta.videos.percentage" :used="storage.meta.videos.used" />
|
||||
<StorageItemDetail type="audios" :title="$t('storage.audios')" :percentage="storage.meta.audios.percentage" :used="storage.meta.audios.used" />
|
||||
<StorageItemDetail type="documents" :title="$t('storage.documents')" :percentage="storage.meta.documents.percentage" :used="storage.meta.documents.used" />
|
||||
<StorageItemDetail type="others" :title="$t('storage.others')" :percentage="storage.meta.others.percentage" :used="storage.meta.others.used" />
|
||||
</div>
|
||||
<div class="page-tab" v-if="storage">
|
||||
<div class="page-tab-group">
|
||||
<b class="form-group-label">{{ $t('storage.sec_capacity') }}</b>
|
||||
<StorageItemDetail type="disk" :title="$t('storage.total_used', {used: storage.attributes.used})" :percentage="storage.attributes.percentage" :used="$t('storage.total_capacity', {capacity: storage.attributes.capacity})"/>
|
||||
</div>
|
||||
<div id="loader" v-if="isLoading">
|
||||
<Spinner></Spinner>
|
||||
<div class="page-tab-group">
|
||||
<b class="form-group-label">{{ $t('storage.sec_details') }}</b>
|
||||
<StorageItemDetail type="images" :title="$t('storage.images')" :percentage="storage.meta.images.percentage" :used="storage.meta.images.used" />
|
||||
<StorageItemDetail type="videos" :title="$t('storage.videos')" :percentage="storage.meta.videos.percentage" :used="storage.meta.videos.used" />
|
||||
<StorageItemDetail type="audios" :title="$t('storage.audios')" :percentage="storage.meta.audios.percentage" :used="storage.meta.audios.used" />
|
||||
<StorageItemDetail type="documents" :title="$t('storage.documents')" :percentage="storage.meta.documents.percentage" :used="storage.meta.documents.used" />
|
||||
<StorageItemDetail type="others" :title="$t('storage.others')" :percentage="storage.meta.others.percentage" :used="storage.meta.others.used" />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user