- Moved chunk size option to .env

- Added ability into App Settings to flush application cache
- Renew password page logo fix
- removed put|patch|delete methods from axios and replaced by faking these methods to support incompatible shared hostings where you can't install php extension to support these methods.
- Getting unique_ids fix
This commit is contained in:
Peter Papp
2020-08-18 10:21:24 +02:00
parent 5c2326e492
commit 93a7542502
36 changed files with 132 additions and 68 deletions

View File

@@ -135,7 +135,9 @@
// Send request to get verify account
axios
.put('/api/settings/email', this.mail)
.post('/api/settings/email', this.mail, {
_method: 'put'
})
.then(() => {
events.$emit('toaster', {

View File

@@ -57,7 +57,9 @@
</div>
</div>
<FormLabel class="mt-70">{{ $t('admin_settings.others.section_others') }}</FormLabel>
<FormLabel class="mt-70">
{{ $t('admin_settings.others.section_others') }}
</FormLabel>
<div class="block-wrapper">
<label>{{ $t('admin_settings.others.contact_email') }}:</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="Contact Email"
@@ -77,6 +79,16 @@
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
</div>
<FormLabel class="mt-70">
Application Cache
</FormLabel>
<InfoBox>
Did you change anything in your .env file or change your stripe credentials? Then clear your cache.
</InfoBox>
<ButtonBase @click.native="flushCache" type="submit" button-style="theme" class="submit-button">
Clear Cache
</ButtonBase>
</div>
</PageTabGroup>
</PageTab>
@@ -95,6 +107,7 @@
import PageTab from '@/components/Others/Layout/PageTab'
import InfoBox from '@/components/Others/Forms/InfoBox'
import {required} from 'vee-validate/dist/rules'
import {events} from '@/bus'
import axios from 'axios'
export default {
@@ -126,6 +139,17 @@
},
}
},
methods: {
flushCache() {
axios.get('/api/flush-cache')
.then(() => {
events.$emit('toaster', {
type: 'success',
message: 'Your cache was successfully deleted.',
})
})
}
},
mounted() {
axios.get('/api/settings', {
params: {

View File

@@ -710,7 +710,9 @@
// Send request to get verify account
axios
.put('/api/settings/stripe', this.stripeCredentials)
.post('/api/settings/stripe', this.stripeCredentials, {
_method: 'put'
})
.then(() => {
// End loading

View File

@@ -70,11 +70,12 @@
this.isSendingRequest = true
axios
.delete(this.$store.getters.api + '/plans/' + this.$route.params.id,
.post(this.$store.getters.api + '/plans/' + this.$route.params.id,
{
data: {
name: this.planName
}
},
_method: 'delete'
}
)
.then(() => {

View File

@@ -73,11 +73,12 @@
this.isSendingRequest = true
axios
.delete(this.$store.getters.api + '/users/' + this.$route.params.id + '/delete',
.post(this.$store.getters.api + '/users/' + this.$route.params.id + '/delete',
{
data: {
name: this.userName
}
},
_method: 'delete'
}
)
.then((response) => {

View File

@@ -188,10 +188,11 @@
// Send request to get user reset link
axios
.patch(this.$store.getters.api + '/users/' + this.$route.params.id + '/role', {
.post(this.$store.getters.api + '/users/' + this.$route.params.id + '/role', {
attributes: {
role: this.userRole,
}
},
_method: 'patch'
})
.then(() => {

View File

@@ -96,10 +96,11 @@
// Send request to get user reset link
axios
.patch(this.$store.getters.api + '/users/' + this.$route.params.id + '/capacity', {
.post(this.$store.getters.api + '/users/' + this.$route.params.id + '/capacity', {
attributes: {
storage_capacity: this.capacity
}
},
_method: 'patch'
})
.then(() => {