mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-28 11:00:39 +00:00
Merge remote-tracking branch 'origin/master' into ads
# Conflicts: # package.json # public/9346.js # public/chunks/admin.js # public/chunks/app-environment.js # public/chunks/app-server.js # public/chunks/billing.js # public/chunks/forgotten-password.js # public/chunks/homepage.js # public/chunks/plan-create/metered.js # public/chunks/plan-settings.js # public/chunks/platform.js # public/chunks/profile.js # public/chunks/recent-uploads.js # public/chunks/request.js # public/chunks/settings.js # public/chunks/shared.js # public/chunks/shared/authenticate.js # public/chunks/shared/single-file.js # public/chunks/sign-in.js # public/css/tailwind.css # public/js/main.js # public/js/main.js.LICENSE.txt # public/mix-manifest.json
This commit is contained in:
@@ -12,8 +12,10 @@
|
||||
</AlertBox>
|
||||
|
||||
<!--Cron Alert-->
|
||||
<AlertBox v-if="!data.app.isRunningCron && !config.isDev" color="rose">
|
||||
We detect your cron jobs probably doesn't work correctly, please check it, you need it for running app correctly. If you set your cron job, please get back one minute later.
|
||||
<AlertBox v-if="!data.app.cron.isRunning && !config.isDev" color="rose">
|
||||
<p class="text-sm text-rose-700 dark:text-rose-500">We detect your cron jobs probably doesn't work correctly, please check it, you need it for running app correctly. If you set your cron job, please get back one minute later.</p>
|
||||
<p class="text-sm text-rose-700 dark:text-rose-500 mt-4 font-bold">Command for Shared Web Hosting (Cpanel, Plesk, etc...): <br/> {{ data.app.cron.command.shared }}</p>
|
||||
<p class="text-sm text-rose-700 dark:text-rose-500 mt-4 font-bold">Command for crontab: <br/> {{ data.app.cron.command.vps }}</p>
|
||||
</AlertBox>
|
||||
|
||||
<!--Metric widgets-->
|
||||
|
||||
@@ -18,14 +18,11 @@
|
||||
@click="getLanguage(language)"
|
||||
v-for="language in languages"
|
||||
:key="language.data.id"
|
||||
class="border-bottom-theme inline-block border-b-2 border-transparent px-4 py-5 text-sm font-bold"
|
||||
class="border-bottom-theme inline-block border-b-2 border-transparent px-4 py-5 text-sm font-bold text-gray-600"
|
||||
:class="{
|
||||
'text-theme router-link-active':
|
||||
selectedLanguage &&
|
||||
selectedLanguage.data.attributes.locale === language.data.attributes.locale,
|
||||
'text-gray-600':
|
||||
!selectedLanguage &&
|
||||
selectedLanguage.data.attributes.locale !== language.data.attributes.locale,
|
||||
}"
|
||||
>
|
||||
{{ language.data.attributes.name }}
|
||||
@@ -55,7 +52,7 @@
|
||||
class="group flex cursor-pointer items-center justify-between py-2 pr-4"
|
||||
>
|
||||
<label
|
||||
class="text-base font-bold"
|
||||
class="text-base font-bold cursor-pointer"
|
||||
:class="{
|
||||
'text-theme':
|
||||
selectedLanguage &&
|
||||
|
||||
@@ -75,6 +75,49 @@
|
||||
</AppInputButton>
|
||||
</div>
|
||||
|
||||
<!--Fraud Prevention Mechanism Rules-->
|
||||
<div v-if="config.subscriptionType === 'metered' && allowedPayments" class="card shadow-card">
|
||||
<FormLabel icon="shield">
|
||||
{{ $t('Usage Restriction Rules for User Accounts') }}
|
||||
</FormLabel>
|
||||
|
||||
<AppInputSwitch
|
||||
:title="$t('allow_limit_usage_in_new_accounts')"
|
||||
:description="$t('limit_usage_description_for_restrictions')"
|
||||
>
|
||||
<SwitchInput
|
||||
@input="$updateText('/admin/settings', 'limit_usage_in_new_accounts', settings.limitUsageInNewAccounts)"
|
||||
v-model="settings.limitUsageInNewAccounts"
|
||||
:state="settings.limitUsageInNewAccounts"
|
||||
/>
|
||||
</AppInputSwitch>
|
||||
|
||||
<AppInputText
|
||||
v-if="settings.limitUsageInNewAccounts"
|
||||
class="-mt-3"
|
||||
>
|
||||
<input
|
||||
@input="$updateText('/admin/settings', 'limit_usage_in_new_accounts_amount', settings.limitUsageInNewAccountsAmount)"
|
||||
v-model="settings.limitUsageInNewAccountsAmount"
|
||||
:placeholder="$t('Max Usage Amount...')"
|
||||
type="number"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
</AppInputText>
|
||||
|
||||
<AppInputSwitch
|
||||
:title="$t('allow_limit_usage_bigger_than_balance')"
|
||||
:description="$t('limit_usage_description_for_restrictions')"
|
||||
:is-last="true"
|
||||
>
|
||||
<SwitchInput
|
||||
@input="$updateText('/admin/settings', 'usage_bigger_than_balance', settings.usageBiggerThanBalance)"
|
||||
v-model="settings.usageBiggerThanBalance"
|
||||
:state="settings.usageBiggerThanBalance"
|
||||
/>
|
||||
</AppInputSwitch>
|
||||
</div>
|
||||
|
||||
<!--Stripe method configuration-->
|
||||
<div v-if="allowedPayments" class="card shadow-card">
|
||||
<img :src="$getPaymentLogo('stripe')" alt="Stripe" class="mb-8 h-8" />
|
||||
@@ -348,7 +391,7 @@
|
||||
</AppInputText>
|
||||
|
||||
<div v-if="paypal.isConfigured">
|
||||
<AppInputSwitch :title="$t('Live Mode')" :description="$t('Toggle between live and sandbox mode')">
|
||||
<AppInputSwitch :title="$t('Live Mode')" :description="$t('Toggle between sandbox and live mode')">
|
||||
<SwitchInput
|
||||
@input="$updateText('/admin/settings', 'paypal_live', config.isPayPalLive)"
|
||||
v-model="config.isPayPalLive"
|
||||
@@ -404,7 +447,7 @@
|
||||
</FormLabel>
|
||||
|
||||
<ValidationProvider>
|
||||
<AppInputSwitch v-if="! paypal.isConfigured" :title="$t('Live Mode')" :description="$t('Toggle between live and sandbox mode')">
|
||||
<AppInputSwitch :title="$t('Live Mode')" :description="$t('Toggle between sandbox and live mode')">
|
||||
<SwitchInput v-model="paypal.credentials.live" :state="paypal.credentials.live" />
|
||||
</AppInputSwitch>
|
||||
</ValidationProvider>
|
||||
@@ -507,11 +550,24 @@ export default {
|
||||
PageTab,
|
||||
InfoBox,
|
||||
},
|
||||
watch: {
|
||||
'paypal.credentials.live': function (val) {
|
||||
this.$updateText('/admin/settings', 'paypal_live', val)
|
||||
|
||||
this.$store.commit('REPLACE_CONFIG_VALUE', {
|
||||
key: 'isPayPalLive',
|
||||
value: val,
|
||||
})
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['config']),
|
||||
...mapGetters([
|
||||
'config'
|
||||
]),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
settings: undefined,
|
||||
allowedRegistrationBonus: true,
|
||||
registrationBonusAmount: undefined,
|
||||
|
||||
@@ -550,7 +606,7 @@ export default {
|
||||
key: undefined,
|
||||
secret: undefined,
|
||||
webhook: undefined,
|
||||
live: undefined,
|
||||
live: false,
|
||||
},
|
||||
},
|
||||
columns: [
|
||||
@@ -651,6 +707,23 @@ export default {
|
||||
})
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
axios
|
||||
.get('/api/admin/settings', {
|
||||
params: {
|
||||
column: 'limit_usage_in_new_accounts|limit_usage_in_new_accounts_amount|usage_bigger_than_balance',
|
||||
},
|
||||
})
|
||||
.then((response) => {
|
||||
this.isLoading = false
|
||||
|
||||
this.settings = {
|
||||
limitUsageInNewAccounts: parseInt(response.data.limit_usage_in_new_accounts),
|
||||
limitUsageInNewAccountsAmount: parseInt(response.data.limit_usage_in_new_accounts_amount),
|
||||
usageBiggerThanBalance: parseInt(response.data.usage_bigger_than_balance),
|
||||
}
|
||||
})
|
||||
},
|
||||
created() {
|
||||
// Set payment description
|
||||
this.stripe.paymentDescription = this.config.stripe_payment_description
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
@@ -111,7 +111,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -133,7 +133,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
@@ -185,7 +185,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
<div class="block-wrapper">
|
||||
@@ -210,7 +210,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
<div class="block-wrapper">
|
||||
@@ -229,7 +229,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
<div class="block-wrapper">
|
||||
@@ -254,7 +254,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
<div class="block-wrapper">
|
||||
@@ -273,7 +273,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
<div class="block-wrapper">
|
||||
@@ -298,14 +298,14 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--Pricing Content-->
|
||||
<div v-if="config.isSaaS" class="card shadow-card">
|
||||
<div v-if="config.subscriptionType === 'fixed'" class="card shadow-card">
|
||||
<FormLabel>Pricing Content</FormLabel>
|
||||
|
||||
<div class="block-wrapper">
|
||||
@@ -354,7 +354,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -376,7 +376,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
@@ -428,7 +428,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -454,7 +454,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
@@ -480,7 +480,7 @@
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
class="focus-border-theme input-dark"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
</div>
|
||||
@@ -540,7 +540,7 @@ export default {
|
||||
})
|
||||
.then((response) => {
|
||||
this.app = {
|
||||
allow_homepage: parseInt(response.data.allow_homepage),
|
||||
allow_homepage: parseInt(response.data.allow_homepage || 1),
|
||||
section_features: parseInt(response.data.section_features),
|
||||
section_feature_boxes: parseInt(response.data.section_feature_boxes),
|
||||
section_pricing_content: parseInt(response.data.section_pricing_content),
|
||||
|
||||
@@ -1,6 +1,22 @@
|
||||
<template>
|
||||
<PageTab :is-loading="isLoading">
|
||||
|
||||
<!-- Subscription -->
|
||||
<div v-if="app" class="card shadow-card">
|
||||
<FormLabel icon="credit-card">
|
||||
{{ $t('subscription') }}
|
||||
</FormLabel>
|
||||
|
||||
<AppInputText :description="$t('subscription_type_note')" :is-last="true" :title="$t('subscription_type')">
|
||||
<SelectInput
|
||||
:default="app.subscriptionType"
|
||||
:options="subscriptionTypes"
|
||||
:placeholder="$t('select_subscription_type')"
|
||||
@change="subscriptionTypeChange"
|
||||
/>
|
||||
</AppInputText>
|
||||
</div>
|
||||
|
||||
<div v-if="app" class="card shadow-card">
|
||||
<FormLabel>
|
||||
{{ $t('upload_settings') }}
|
||||
@@ -216,63 +232,6 @@
|
||||
@input="$updateText('/admin/settings', 'google_analytics', app.googleAnalytics, true)"
|
||||
/>
|
||||
</AppInputText>
|
||||
</div>
|
||||
|
||||
<!--Upgrade License-->
|
||||
<div v-if="app && !config.isSaaS" class="card shadow-card">
|
||||
<FormLabel icon="trending-up">
|
||||
{{ $t('Upgrade your License') }}
|
||||
</FormLabel>
|
||||
|
||||
<ValidationObserver
|
||||
ref="upgradeLicense"
|
||||
v-slot="{ invalid }"
|
||||
class="mt-6"
|
||||
tag="form"
|
||||
@submit.prevent="upgradeLicense"
|
||||
>
|
||||
<ValidationProvider
|
||||
v-slot="{ errors }"
|
||||
mode="passive"
|
||||
name="Purchase Code"
|
||||
rules="required"
|
||||
tag="div"
|
||||
>
|
||||
<AppInputText
|
||||
:error="errors[0]"
|
||||
:is-last="true"
|
||||
>
|
||||
<div class="space-y-4 sm:flex sm:space-x-4 sm:space-y-0">
|
||||
<input
|
||||
v-model="purchaseCode"
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
:placeholder="$t('Paste your Purchase code here...')"
|
||||
class="focus-border-theme input-dark"
|
||||
type="text"
|
||||
/>
|
||||
<ButtonBase :loading="isLoadingUpgradingButton" button-style="theme" class="w-full sm:w-auto" type="submit">
|
||||
{{ $t('Upgrade') }}
|
||||
</ButtonBase>
|
||||
</div>
|
||||
</AppInputText>
|
||||
</ValidationProvider>
|
||||
</ValidationObserver>
|
||||
</div>
|
||||
|
||||
<!-- Subscription -->
|
||||
<div v-if="app && config.isSaaS" class="card shadow-card">
|
||||
<FormLabel icon="credit-card">
|
||||
{{ $t('subscription') }}
|
||||
</FormLabel>
|
||||
|
||||
<AppInputText :description="$t('subscription_type_note')" :is-last="true" :title="$t('subscription_type')">
|
||||
<SelectInput
|
||||
:default="app.subscriptionType"
|
||||
:options="subscriptionTypes"
|
||||
:placeholder="$t('select_subscription_type')"
|
||||
@change="subscriptionTypeChange"
|
||||
/>
|
||||
</AppInputText>
|
||||
</div>
|
||||
</PageTab>
|
||||
</template>
|
||||
@@ -330,45 +289,6 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async upgradeLicense() {
|
||||
this.isLoadingUpgradingButton = true
|
||||
// Validate fields
|
||||
const isValid = await this.$refs.upgradeLicense.validate()
|
||||
|
||||
if (!isValid) return
|
||||
|
||||
axios.post('/api/admin/upgrade-license', {
|
||||
purchaseCode: this.purchaseCode
|
||||
})
|
||||
.then((response) => {
|
||||
this.$store.dispatch('getLanguageTranslations', this.config.locale)
|
||||
|
||||
this.$store.commit('REPLACE_CONFIG_VALUE', {
|
||||
key: 'isSaaS',
|
||||
value: true,
|
||||
})
|
||||
|
||||
events.$emit('toaster', {
|
||||
type: 'success',
|
||||
message: this.$t('Your license was successfully upgraded'),
|
||||
})
|
||||
})
|
||||
.catch((error) => {
|
||||
if (error.response.status === 400) {
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('Purchase code is invalid or is not Extended License'),
|
||||
})
|
||||
} else {
|
||||
events.$emit('alert:open', {
|
||||
title: this.$t('popup_error.title'),
|
||||
message: this.$t('popup_error.message'),
|
||||
})
|
||||
}
|
||||
})
|
||||
.finally(() => {
|
||||
this.isLoadingUpgradingButton = false
|
||||
})
|
||||
},
|
||||
subscriptionTypeChange(type) {
|
||||
events.$emit('confirm:open', {
|
||||
title: this.$t('subscription_type_change_warn'),
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
</div>
|
||||
|
||||
<!--Broadcasting-->
|
||||
<div class="card shadow-card">
|
||||
<div v-if="config.broadcasting" class="card shadow-card">
|
||||
<FormLabel icon="info">Broadcasting</FormLabel>
|
||||
|
||||
<div class="lg:flex lg:space-y-0 space-y-3 items-center justify-between">
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
<tr class="whitespace-nowrap border-b border-dashed border-light dark:border-opacity-5">
|
||||
<td class="py-5 pr-3 md:pr-1">
|
||||
<router-link
|
||||
v-if="row.data.relationships.user"
|
||||
class="flex items-center"
|
||||
:to="{
|
||||
name: 'UserDetail',
|
||||
@@ -35,6 +36,9 @@
|
||||
</span>
|
||||
</div>
|
||||
</router-link>
|
||||
<span v-else class="text-sm font-bold">
|
||||
-
|
||||
</span>
|
||||
</td>
|
||||
<td class="px-3 md:px-1">
|
||||
<ColorLabel :color="$getSubscriptionStatusColor(row.data.attributes.status)">
|
||||
@@ -53,12 +57,7 @@
|
||||
</td>
|
||||
<td class="px-3 md:px-1">
|
||||
<span class="text-sm font-bold">
|
||||
<!--todo: update renew attribute-->
|
||||
{{
|
||||
row.data.attributes.renews_at
|
||||
? row.data.attributes.renews_at
|
||||
: row.data.attributes.created_at
|
||||
}}
|
||||
{{ row.data.attributes.renews_at }}
|
||||
</span>
|
||||
</td>
|
||||
<td class="px-3 md:px-1">
|
||||
|
||||
@@ -91,7 +91,7 @@ export default {
|
||||
this.isSendingRequest = true
|
||||
|
||||
axios
|
||||
.post(this.$store.getters.api + '/admin/users/' + this.$route.params.id + '/delete', {
|
||||
.post(this.$store.getters.api + '/admin/users/' + this.$route.params.id, {
|
||||
name: this.userName,
|
||||
_method: 'delete',
|
||||
})
|
||||
@@ -104,7 +104,7 @@ export default {
|
||||
})
|
||||
}
|
||||
|
||||
if (response.status === 204) {
|
||||
if (response.status === 200) {
|
||||
events.$emit('success:open', {
|
||||
emoji: '👍',
|
||||
title: this.$t('popup_deleted_user.title'),
|
||||
|
||||
@@ -73,7 +73,7 @@ export default {
|
||||
|
||||
this.limitations.push({
|
||||
message: payload.message[key],
|
||||
isVisibleBar: item.total === -1,
|
||||
isVisibleBar: item.total !== -1 && item.total !== 0,
|
||||
distribution: [
|
||||
{
|
||||
progress: item.percentage,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<AuthContentWrapper ref="auth">
|
||||
<AuthContentWrapper ref="auth" class="h-screen">
|
||||
<!--Create new password-->
|
||||
<AuthContent name="create-new-password" :visible="true">
|
||||
<Headline :title="$t('page_create_password.title')" :description="$t('page_create_password.subtitle')" />
|
||||
@@ -30,7 +30,7 @@
|
||||
class="dark:placeholder:text-gray-600 focus-border-theme w-full appearance-none rounded-lg border border-transparent bg-light-background px-5 py-3.5 font-bold dark:bg-2x-dark-foreground"
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
class="dark:placeholder:text-gray-600 focus-border-theme w-full appearance-none rounded-lg border border-transparent bg-light-background px-5 py-3.5 font-bold dark:bg-2x-dark-foreground"
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -76,7 +76,7 @@
|
||||
class="dark:placeholder:text-gray-600 focus-border-theme w-full appearance-none rounded-lg border border-transparent bg-light-background px-5 py-3.5 font-bold dark:bg-2x-dark-foreground"
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -459,7 +459,7 @@ export default {
|
||||
this.$scrollTop()
|
||||
this.$store.commit('PROCESSING_POPUP', undefined)
|
||||
|
||||
if (this.config.isDemo || this.config.isDev) {
|
||||
if (this.config.isPrefilledUsers) {
|
||||
this.loginEmail = 'howdy@hi5ve.digital'
|
||||
this.loginPassword = 'vuefilemanager'
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<AuthContentWrapper ref="auth">
|
||||
<AuthContentWrapper ref="auth" class="h-screen">
|
||||
<!--Registration-->
|
||||
<AuthContent name="sign-up" :visible="true" class="mt-4 mb-12">
|
||||
<AuthContent name="sign-up" :visible="true">
|
||||
<Headline :title="$t('page_registration.title')" :description="$t('page_registration.subtitle')" />
|
||||
|
||||
<ValidationObserver
|
||||
@@ -208,11 +208,10 @@ export default {
|
||||
this.isLoading = true
|
||||
|
||||
// Get ReCaptcha token
|
||||
if (config.allowedRecaptcha) {
|
||||
this.register.reCaptcha = await this.$reCaptchaToken('register').then((response) => {
|
||||
return response
|
||||
})
|
||||
}
|
||||
if (this.config.allowedRecaptcha) {
|
||||
this.register.reCaptcha = await this.$reCaptchaToken('register')
|
||||
.then((response) => response)
|
||||
}
|
||||
|
||||
// Send request to get user token
|
||||
axios
|
||||
@@ -278,7 +277,7 @@ export default {
|
||||
this.$router.push({name: 'Files'})
|
||||
}
|
||||
|
||||
if (this.config.isDemo || this.config.isDev) {
|
||||
if (this.config.isPrefilledUsers) {
|
||||
this.register = {
|
||||
name: 'John Doe',
|
||||
email: 'demo-' + Math.floor(Math.random() * 100000) + '@doe.com',
|
||||
|
||||
@@ -254,7 +254,7 @@ export default {
|
||||
return this.item && this.item.data.type === 'folder'
|
||||
},
|
||||
isInFavourites() {
|
||||
return this.user.data.relationships.favourites.data.find((el) => el.data.id === this.item.data.id)
|
||||
return this.user.data.relationships.favourites.find((el) => el.data.id === this.item.data.id)
|
||||
},
|
||||
hasFile() {
|
||||
return this.clipboard.find((item) => item.data.type !== 'folder')
|
||||
@@ -266,7 +266,7 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$store.dispatch('getFolder', this.$route.params.id)
|
||||
this.$store.dispatch('getFolder', {page: 1, id:this.$route.params.id})
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('context-menu:current-folder', (folder) => (this.item = folder))
|
||||
|
||||
@@ -157,7 +157,7 @@ export default {
|
||||
return this.item && this.item.type === 'folder'
|
||||
},
|
||||
isInFavourites() {
|
||||
return this.user.data.relationships.favourites.data.find((el) => el.id === this.item.id)
|
||||
return this.user.data.relationships.favourites.find((el) => el.id === this.item.id)
|
||||
},
|
||||
hasFile() {
|
||||
return this.clipboard.find((item) => item.type !== 'folder')
|
||||
@@ -169,7 +169,7 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$store.dispatch('getMySharedItems')
|
||||
this.$store.dispatch('getMySharedItems', 1)
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('mobile-context-menu:show', (item) => (this.item = item))
|
||||
|
||||
@@ -234,7 +234,7 @@ export default {
|
||||
},
|
||||
},
|
||||
created() {
|
||||
this.$store.dispatch('getSharedFolder', this.$route.params.id)
|
||||
this.$store.dispatch('getSharedFolder', {page: 1, id: this.$route.params.id})
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('mobile-context-menu:show', (item) => (this.item = item))
|
||||
|
||||
@@ -151,7 +151,7 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$store.dispatch('getRecentUploads')
|
||||
this.$store.dispatch('getRecentUploads', 1)
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('mobile-context-menu:show', (item) => (this.item = item))
|
||||
|
||||
@@ -242,7 +242,7 @@ export default {
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
this.$store.dispatch('getSharedWithMeFolder', this.$route.params.id)
|
||||
this.$store.dispatch('getSharedWithMeFolder',{page: 1, id:this.$route.params.id})
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('mobile-context-menu:show', (item) => (this.item = item))
|
||||
@@ -257,7 +257,7 @@ export default {
|
||||
if (this.$route.params.id) {
|
||||
this.$router.push({ name: 'SharedWithMe' })
|
||||
} else {
|
||||
this.$store.dispatch('getSharedWithMeFolder', undefined)
|
||||
this.$store.dispatch('getSharedWithMeFolder',{page: 1, id:undefined})
|
||||
}
|
||||
|
||||
events.$emit('toaster', {
|
||||
|
||||
@@ -281,7 +281,7 @@ export default {
|
||||
return this.item && this.item.data.type === 'folder'
|
||||
},
|
||||
isInFavourites() {
|
||||
return this.user.data.relationships.favourites.data.find((el) => el.id === this.item.id)
|
||||
return this.user.data.relationships.favourites.find((el) => el.id === this.item.id)
|
||||
},
|
||||
hasFile() {
|
||||
return this.clipboard.find((item) => item.type !== 'folder')
|
||||
@@ -293,7 +293,7 @@ export default {
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.$store.dispatch('getTeamFolder', this.$route.params.id)
|
||||
this.$store.dispatch('getTeamFolder', {page: 1, id:this.$route.params.id})
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('mobile-context-menu:show', (item) => (this.item = item))
|
||||
|
||||
@@ -149,7 +149,7 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.$store.dispatch('getTrash', this.$route.params.id)
|
||||
this.$store.dispatch('getTrash', {page: 1, id: this.$route.params.id})
|
||||
|
||||
events.$on('context-menu:show', (event, item) => (this.item = item))
|
||||
events.$on('mobile-context-menu:show', (item) => (this.item = item))
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
class="focus-border-theme input-dark"
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
/>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
class="focus-border-theme input-dark"
|
||||
:class="{ '!border-rose-600': errors[0] }"
|
||||
></textarea>
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
<span class="text-left text-xs text-red-600" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
@@ -121,11 +121,10 @@ export default {
|
||||
this.isLoading = true
|
||||
|
||||
// Get ReCaptcha token
|
||||
if (config.allowedRecaptcha) {
|
||||
this.register.reCaptcha = await this.$reCaptchaToken('register').then((response) => {
|
||||
return response
|
||||
})
|
||||
}
|
||||
if (this.config.allowedRecaptcha) {
|
||||
this.contact.reCaptcha = await this.$reCaptchaToken('register')
|
||||
.then((response) => response)
|
||||
}
|
||||
|
||||
// Send request to get user token
|
||||
axios
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
<MainFeatures />
|
||||
|
||||
<!--Pricing Tables-->
|
||||
<PricingTables v-if="config.isSaaS && config.subscriptionType === 'fixed'" />
|
||||
<PricingTables v-if="config.subscriptionType === 'fixed'" />
|
||||
|
||||
<!--Get Started Call To Action-->
|
||||
<GetStarted />
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
<div
|
||||
@contextmenu.prevent.capture="contextMenu($event, undefined)"
|
||||
class="lg:flex lg:flex-col lg:w-full lg:px-3.5"
|
||||
class="lg:flex lg:flex-col lg:w-full lg:px-3.5 min-w-0"
|
||||
>
|
||||
<DesktopToolbar />
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
|
||||
<!--File list & info sidebar-->
|
||||
<div class="flex space-x-3 lg:overflow-hidden grow" @drop.stop.prevent="uploadDroppedItems($event)" @dragenter.prevent @dragover.prevent>
|
||||
<router-view id="file-view" class="relative w-full" :key="$route.fullPath" />
|
||||
<router-view id="file-view" class="relative w-full min-w-0" :key="$route.fullPath" />
|
||||
|
||||
<InfoSidebar v-if="isVisibleSidebar" />
|
||||
</div>
|
||||
@@ -62,6 +62,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getFilesFromDataTransferItems } from 'datatransfer-files-promise'
|
||||
import FileSortingMobile from '../components/Menus/FileSortingMobile'
|
||||
import SidebarNavigation from '../components/Sidebar/SidebarNavigation'
|
||||
import FileFilterMobile from '../components/Menus/FileFilterMobile'
|
||||
@@ -116,7 +117,7 @@ export default {
|
||||
DragUI,
|
||||
},
|
||||
computed: {
|
||||
...mapGetters(['isVisibleSidebar', 'isLimitedUser', 'config', 'currentFolder']),
|
||||
...mapGetters(['isVisibleSidebar', 'config', 'currentFolder']),
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@@ -124,8 +125,14 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
uploadDroppedItems(event) {
|
||||
this.$uploadDraggedFiles(event, this.currentFolder?.data.id)
|
||||
async uploadDroppedItems(event) {
|
||||
// Check if user dropped folder with files
|
||||
let files = await getFilesFromDataTransferItems(event.dataTransfer.items)
|
||||
|
||||
if (files.length !== 0) {
|
||||
// Upload folder with files
|
||||
this.$uploadDraggedFolderOrFile(files, this.currentFolder?.data.id)
|
||||
}
|
||||
},
|
||||
contextMenu(event, item) {
|
||||
events.$emit('context-menu:show', event, item)
|
||||
|
||||
@@ -194,7 +194,7 @@
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
<div v-if="isExtended" class="card text-left shadow-card">
|
||||
<div class="card text-left shadow-card">
|
||||
<FormLabel>Subscription</FormLabel>
|
||||
|
||||
<ValidationProvider
|
||||
@@ -275,7 +275,6 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
isLoading: false,
|
||||
isExtended: undefined,
|
||||
app: {
|
||||
color: '#00BC7E',
|
||||
subscriptionType: undefined,
|
||||
@@ -357,8 +356,6 @@ export default {
|
||||
created() {
|
||||
this.$scrollTop()
|
||||
|
||||
this.isExtended = localStorage.getItem('license') === 'Extended'
|
||||
|
||||
if (this.$root.$data.config.isSetupWizardDebug) {
|
||||
this.app.subscriptionType = 'metered'
|
||||
this.app.title = 'VueFileManager'
|
||||
|
||||
@@ -256,7 +256,7 @@ export default {
|
||||
axios
|
||||
.get('/api/ping')
|
||||
.then((response) => {
|
||||
this.apiRunning = response.data === 'pong'
|
||||
this.apiRunning = response.data.message === 'pong'
|
||||
})
|
||||
.catch(() => {
|
||||
this.apiRunning = false
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
<div
|
||||
@contextmenu.prevent.capture="contextMenu($event, undefined)"
|
||||
class="lg:flex lg:flex-col lg:w-full lg:px-3.5"
|
||||
class="lg:flex lg:flex-col lg:w-full lg:px-3.5 min-w-0"
|
||||
>
|
||||
<DesktopSharepageToolbar />
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
<!--File list & info sidebar-->
|
||||
<div class="flex space-x-3 lg:overflow-hidden grow" @drop.stop.prevent="uploadDroppedItems($event)" @dragenter.prevent @dragover.prevent>
|
||||
<router-view id="file-view" class="relative w-full" :key="$route.fullPath" />
|
||||
<router-view id="file-view" class="relative w-full min-w-0" :key="$route.fullPath" />
|
||||
|
||||
<InfoSidebar v-if="isVisibleSidebar" />
|
||||
</div>
|
||||
@@ -64,6 +64,7 @@ import { mapGetters } from 'vuex'
|
||||
import { events } from '../bus'
|
||||
import DesktopSharepageToolbar from '../components/Layout/Toolbars/DesktopSharepageToolbar'
|
||||
import RemoteUploadPopup from "../components/RemoteUpload/RemoteUploadPopup";
|
||||
import {getFilesFromDataTransferItems} from "datatransfer-files-promise";
|
||||
|
||||
export default {
|
||||
name: 'Shared',
|
||||
@@ -95,8 +96,14 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
uploadDroppedItems(event) {
|
||||
this.$uploadDraggedFiles(event, this.currentFolder?.data.id)
|
||||
async uploadDroppedItems(event) {
|
||||
// Check if user dropped folder with files
|
||||
let files = await getFilesFromDataTransferItems(event.dataTransfer.items)
|
||||
|
||||
if (files.length !== 0) {
|
||||
// Upload folder with files
|
||||
this.$uploadDraggedFolderOrFile(files, this.currentFolder?.data.id)
|
||||
}
|
||||
},
|
||||
contextMenu(event, item) {
|
||||
events.$emit('context-menu:show', event, item)
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
<div
|
||||
@contextmenu.prevent.capture="contextMenu($event, undefined)"
|
||||
class="lg:flex lg:flex-col lg:w-full lg:px-3.5"
|
||||
class="lg:flex lg:flex-col lg:w-full lg:px-3.5 min-w-0"
|
||||
>
|
||||
<DesktopUploadRequestToolbar v-if="canShowUI" />
|
||||
<MobileUploadRequestToolBar v-if="canShowUI" />
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
<!--File list & info sidebar-->
|
||||
<div class="flex space-x-3 lg:overflow-hidden grow" @drop.stop.prevent="uploadDroppedItems($event)" @dragenter.prevent @dragover.prevent>
|
||||
<router-view id="file-view" class="relative w-full" :key="$route.fullPath" />
|
||||
<router-view id="file-view" class="relative w-full min-w-0" :key="$route.fullPath" />
|
||||
|
||||
<InfoSidebarUploadRequest v-if="canShowUI && isVisibleSidebar" />
|
||||
</div>
|
||||
@@ -56,6 +56,7 @@ import DragUI from '../components/UI/Others/DragUI'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { events } from '../bus'
|
||||
import RemoteUploadPopup from "../components/RemoteUpload/RemoteUploadPopup";
|
||||
import {getFilesFromDataTransferItems} from "datatransfer-files-promise";
|
||||
|
||||
export default {
|
||||
name: 'UploadRequest',
|
||||
@@ -87,8 +88,14 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
uploadDroppedItems(event) {
|
||||
this.$uploadDraggedFiles(event, this.currentFolder?.data.id)
|
||||
async uploadDroppedItems(event) {
|
||||
// Check if user dropped folder with files
|
||||
let files = await getFilesFromDataTransferItems(event.dataTransfer.items)
|
||||
|
||||
if (files.length !== 0) {
|
||||
// Upload folder with files
|
||||
this.$uploadDraggedFolderOrFile(files, this.currentFolder?.data.id)
|
||||
}
|
||||
},
|
||||
contextMenu(event, item) {
|
||||
events.$emit('context-menu:show', event, item)
|
||||
|
||||
Reference in New Issue
Block a user