mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-06 02:33:48 +00:00
Invoice empty page
This commit is contained in:
@@ -39,10 +39,10 @@
|
||||
"/chunks/files.js": "/chunks/files.js?id=ee5b19530d832c6f9f34",
|
||||
"/chunks/files~chunks/oasis/invoices/list~chunks/oasis/platba~chunks/settings-subscription~chunks/shar~d6675e1e.js": "/chunks/files~chunks/oasis/invoices/list~chunks/oasis/platba~chunks/settings-subscription~chunks/shar~d6675e1e.js?id=effef49b99446fdaee0b",
|
||||
"/chunks/files~chunks/oasis/invoices/list~chunks/platform~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/oasis/invoices/list~chunks/platform~chunks/shared-files~chunks/shared/file-browser.js?id=e4b969d39eeef45f88f5",
|
||||
"/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.js?id=a35f0d58f42da919a182",
|
||||
"/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.js?id=bf0089c1be9398233d98",
|
||||
"/chunks/files~chunks/oasis/invoices~chunks/oasis/invoices/list~chunks/platform~chunks/shared~chunks/s~87b39a8d.js": "/chunks/files~chunks/oasis/invoices~chunks/oasis/invoices/list~chunks/platform~chunks/shared~chunks/s~87b39a8d.js?id=c226fe89b510c599615f",
|
||||
"/chunks/files~chunks/oasis/invoices~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/f~9f6a6eef.js": "/chunks/files~chunks/oasis/invoices~chunks/platform~chunks/shared~chunks/shared-files~chunks/shared/f~9f6a6eef.js?id=d85fcb76a9b5d1cf4da5",
|
||||
"/chunks/files~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser.js?id=b16063b4c7277725485e",
|
||||
"/chunks/files~chunks/shared-files~chunks/shared/file-browser.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser.js?id=5d4291b6fe4985bde86a",
|
||||
"/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.js": "/chunks/files~chunks/shared-files~chunks/shared/file-browser~chunks/shared/single-file.js?id=01b0782ff7a9c0bd5f5f",
|
||||
"/chunks/files~chunks/shared/file-browser.js": "/chunks/files~chunks/shared/file-browser.js?id=44899a3c3880630dbcd9",
|
||||
"/chunks/forgotten-password.js": "/chunks/forgotten-password.js?id=877a9289b77ac3885042",
|
||||
@@ -51,14 +51,14 @@
|
||||
"/chunks/invoices.js": "/chunks/invoices.js?id=1deb187f6d3eb1e81ad0",
|
||||
"/chunks/not-found-shared.js": "/chunks/not-found-shared.js?id=7fc7f9b6f10bdfac770e",
|
||||
"/chunks/oasis/homepage.js": "/chunks/oasis/homepage.js?id=a1885dd8814f9eb63a1c",
|
||||
"/chunks/oasis/invoices.js": "/chunks/oasis/invoices.js?id=44eaa1aabc42857a86d8",
|
||||
"/chunks/oasis/invoices.js": "/chunks/oasis/invoices.js?id=416333fce97bf3a118a2",
|
||||
"/chunks/oasis/invoices/client.js": "/chunks/oasis/invoices/client.js?id=63a83703890e6cf422f4",
|
||||
"/chunks/oasis/invoices/client-detail.js": "/chunks/oasis/invoices/client-detail.js?id=2414e131ef16f6f2a27a",
|
||||
"/chunks/oasis/invoices/client-invoices.js": "/chunks/oasis/invoices/client-invoices.js?id=988b280cc50ad75eec8c",
|
||||
"/chunks/oasis/invoices/create-client.js": "/chunks/oasis/invoices/create-client.js?id=03f3f613dbea4bb786cb",
|
||||
"/chunks/oasis/invoices/create-invoice.js": "/chunks/oasis/invoices/create-invoice.js?id=8dafd9d9bc583b487df4",
|
||||
"/chunks/oasis/invoices/create-client.js": "/chunks/oasis/invoices/create-client.js?id=1074eed0dd32164a0459",
|
||||
"/chunks/oasis/invoices/create-invoice.js": "/chunks/oasis/invoices/create-invoice.js?id=d9deb3eb0c78b7cb9a12",
|
||||
"/chunks/oasis/invoices/edit-invoice.js": "/chunks/oasis/invoices/edit-invoice.js?id=f46025ebb44bb463b0e4",
|
||||
"/chunks/oasis/invoices/list.js": "/chunks/oasis/invoices/list.js?id=fc7eab97714b6151c10c",
|
||||
"/chunks/oasis/invoices/list.js": "/chunks/oasis/invoices/list.js?id=c8c730eb1e4d088d257d",
|
||||
"/chunks/oasis/invoices/profile.js": "/chunks/oasis/invoices/profile.js?id=ea95035cbe1e905f0e95",
|
||||
"/chunks/oasis/invoices~chunks/platform~chunks/shared.js": "/chunks/oasis/invoices~chunks/platform~chunks/shared.js?id=865f72ddd4457b2f06a7",
|
||||
"/chunks/oasis/platba.js": "/chunks/oasis/platba.js?id=74bc76fa643e04156e64",
|
||||
@@ -160,5 +160,47 @@
|
||||
"/chunks/oasis/invoices/edit-invoice.80a52aeb3183100af99d.hot-update.js": "/chunks/oasis/invoices/edit-invoice.80a52aeb3183100af99d.hot-update.js",
|
||||
"/chunks/oasis/invoices/edit-invoice.ffea9fa001d9b2ac34eb.hot-update.js": "/chunks/oasis/invoices/edit-invoice.ffea9fa001d9b2ac34eb.hot-update.js",
|
||||
"/chunks/oasis/invoices/edit-invoice.91f9c200784731462be0.hot-update.js": "/chunks/oasis/invoices/edit-invoice.91f9c200784731462be0.hot-update.js",
|
||||
"/chunks/oasis/invoices/client-invoices.5072ebf8fa7df556cb57.hot-update.js": "/chunks/oasis/invoices/client-invoices.5072ebf8fa7df556cb57.hot-update.js"
|
||||
"/chunks/oasis/invoices/client-invoices.5072ebf8fa7df556cb57.hot-update.js": "/chunks/oasis/invoices/client-invoices.5072ebf8fa7df556cb57.hot-update.js",
|
||||
"/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.b74b4a9e0d0fce8c9999.hot-update.js": "/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.b74b4a9e0d0fce8c9999.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.b74b4a9e0d0fce8c9999.hot-update.js": "/chunks/oasis/invoices/list.b74b4a9e0d0fce8c9999.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.a530873b79e6f02e963b.hot-update.js": "/chunks/oasis/invoices/list.a530873b79e6f02e963b.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.3ef4bc2a5de3c62b1a5b.hot-update.js": "/chunks/oasis/invoices/list.3ef4bc2a5de3c62b1a5b.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.7752eb2fa6862f28056d.hot-update.js": "/chunks/oasis/invoices/list.7752eb2fa6862f28056d.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.aa29b2473860c7f19e8a.hot-update.js": "/chunks/oasis/invoices/list.aa29b2473860c7f19e8a.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.69799a73ad4b61c770d5.hot-update.js": "/chunks/oasis/invoices/list.69799a73ad4b61c770d5.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.d090fc1951292d8ff624.hot-update.js": "/chunks/oasis/invoices/list.d090fc1951292d8ff624.hot-update.js",
|
||||
"/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.1eeaa09c71309950462a.hot-update.js": "/chunks/files~chunks/oasis/invoices/list~chunks/shared-files~chunks/shared/file-browser.1eeaa09c71309950462a.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.1eeaa09c71309950462a.hot-update.js": "/chunks/oasis/invoices/list.1eeaa09c71309950462a.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.08544d7b8731a337ef90.hot-update.js": "/chunks/oasis/invoices/list.08544d7b8731a337ef90.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.ccf656f65531c10a92bd.hot-update.js": "/chunks/oasis/invoices/list.ccf656f65531c10a92bd.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.18e55f927f14fa1d4280.hot-update.js": "/chunks/oasis/invoices/list.18e55f927f14fa1d4280.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.d32761e519863923f58b.hot-update.js": "/chunks/oasis/invoices/list.d32761e519863923f58b.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.9c653b2af725b526e8c7.hot-update.js": "/chunks/oasis/invoices/list.9c653b2af725b526e8c7.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.273d35f00b860ba38a0c.hot-update.js": "/chunks/oasis/invoices/list.273d35f00b860ba38a0c.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.32466dc196d5899a7512.hot-update.js": "/chunks/oasis/invoices/list.32466dc196d5899a7512.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.b5235811bc51f8ec5c72.hot-update.js": "/chunks/oasis/invoices/list.b5235811bc51f8ec5c72.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.1f90791d8365c6f04be1.hot-update.js": "/chunks/oasis/invoices/list.1f90791d8365c6f04be1.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.43e162d60462e4a7ac9c.hot-update.js": "/chunks/oasis/invoices/list.43e162d60462e4a7ac9c.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.f3674673c63d2b13e36a.hot-update.js": "/chunks/oasis/invoices/list.f3674673c63d2b13e36a.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.989c61f17b13c9a59ee3.hot-update.js": "/chunks/oasis/invoices/list.989c61f17b13c9a59ee3.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.8f464b4bcd840fef801b.hot-update.js": "/chunks/oasis/invoices/list.8f464b4bcd840fef801b.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.c2ee1fee228bbdea8c6a.hot-update.js": "/chunks/oasis/invoices/list.c2ee1fee228bbdea8c6a.hot-update.js",
|
||||
"/chunks/oasis/invoices.6d960f3754123a387928.hot-update.js": "/chunks/oasis/invoices.6d960f3754123a387928.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.6d960f3754123a387928.hot-update.js": "/chunks/oasis/invoices/list.6d960f3754123a387928.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.aa9ca31164bc17e8ea1e.hot-update.js": "/chunks/oasis/invoices/list.aa9ca31164bc17e8ea1e.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.a98a7ec97895651e30d0.hot-update.js": "/chunks/oasis/invoices/list.a98a7ec97895651e30d0.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.fa3795eb169c96b0dcd3.hot-update.js": "/chunks/oasis/invoices/list.fa3795eb169c96b0dcd3.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.363db8c53aa63943b976.hot-update.js": "/chunks/oasis/invoices/list.363db8c53aa63943b976.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.1602a2804fc10d48d94e.hot-update.js": "/chunks/oasis/invoices/list.1602a2804fc10d48d94e.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.5b6f375d9ac0bd58b748.hot-update.js": "/chunks/oasis/invoices/list.5b6f375d9ac0bd58b748.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.a3b1b93dfbfa2b24354e.hot-update.js": "/chunks/oasis/invoices/list.a3b1b93dfbfa2b24354e.hot-update.js",
|
||||
"/chunks/oasis/invoices/list.3b8fb33e179c233a099f.hot-update.js": "/chunks/oasis/invoices/list.3b8fb33e179c233a099f.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.df15c2f6ab404c0a5aa5.hot-update.js": "/chunks/oasis/invoices/create-invoice.df15c2f6ab404c0a5aa5.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-client.5295c95cefe5a365db39.hot-update.js": "/chunks/oasis/invoices/create-client.5295c95cefe5a365db39.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.2ead30e8d0c6b1c13381.hot-update.js": "/chunks/oasis/invoices/create-invoice.2ead30e8d0c6b1c13381.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.e562483356f2538a3914.hot-update.js": "/chunks/oasis/invoices/create-invoice.e562483356f2538a3914.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.f955b3c368ef5e10b02e.hot-update.js": "/chunks/oasis/invoices/create-invoice.f955b3c368ef5e10b02e.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.b87e7cc19deb5d8134ac.hot-update.js": "/chunks/oasis/invoices/create-invoice.b87e7cc19deb5d8134ac.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.c3185882e157a1203d4c.hot-update.js": "/chunks/oasis/invoices/create-invoice.c3185882e157a1203d4c.hot-update.js",
|
||||
"/chunks/oasis/invoices/create-invoice.fce45048a1e1b00ef163.hot-update.js": "/chunks/oasis/invoices/create-invoice.fce45048a1e1b00ef163.hot-update.js"
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<MobileHeader :title="$router.currentRoute.meta.title" />
|
||||
<PageHeader :title="$router.currentRoute.meta.title" />
|
||||
<PageHeader :title="$router.currentRoute.meta.title" :can-back="true" />
|
||||
|
||||
<div id="page-content" class="medium-width">
|
||||
<div class="content-page">
|
||||
|
||||
@@ -142,6 +142,15 @@
|
||||
.catch(() => this.$isSomethingWrong())
|
||||
}
|
||||
})
|
||||
|
||||
events.$on('action:confirmed', data => {
|
||||
if (data.operation === 'delete-client') {
|
||||
|
||||
axios.delete(`/api/oasis/clients/${data.id}`)
|
||||
.then(() => this.goTo(this.currentFolder.location))
|
||||
.catch(() => this.$isSomethingWrong())
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div id="single-page">
|
||||
<MobileHeader :title="pageTitle" />
|
||||
<PageHeader :title="pageTitle" />
|
||||
<PageHeader :title="pageTitle" :can-back="true" />
|
||||
|
||||
<div id="page-content">
|
||||
<div class="content-page" v-if="! isLoadingPage">
|
||||
@@ -69,7 +69,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.dic') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_dic" rules="required" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_dic" :placeholder="$t('client_dic')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_dic" :placeholder="$t('in_editor.plac.client_dic')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -77,7 +77,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.ic_dph') }} ({{ $t('global.optional') }}):</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_ic_dph" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_ic_dph" :placeholder="$t('client_ic_dph')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_ic_dph" :placeholder="$t('in_editor.plac.client_ic_dph')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -85,7 +85,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.company_name') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_name" rules="required" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_name" :placeholder="$t('client_company')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_name" :placeholder="$t('in_editor.plac.client_company')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -93,7 +93,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.client_address') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_address" rules="required" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_address" :placeholder="$t('client_address')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_address" :placeholder="$t('in_editor.plac.client_address')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -102,7 +102,7 @@
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('in_editor.client_city') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_city" rules="required" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_city" :placeholder="$t('client_city')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_city" :placeholder="$t('in_editor.plac.client_city')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -110,7 +110,7 @@
|
||||
<div class="block-wrapper">
|
||||
<label>{{ $t('in_editor.client_postal_code') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_postal_code" rules="required" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_postal_code" :placeholder="$t('client_postal_code')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_postal_code" :placeholder="$t('in_editor.plac.client_postal_code')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -119,7 +119,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.client_country') }}:</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_country" rules="required" v-slot="{ errors }">
|
||||
<SelectInput v-model="invoice.client_country" :default="invoice.client_country" :options="countries" :placeholder="$t('client_country')" :isError="errors[0]" />
|
||||
<SelectInput v-model="invoice.client_country" :default="invoice.client_country" :options="countries" :placeholder="$t('in_editor.plac.client_country')" :isError="errors[0]" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -127,7 +127,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.client_phone') }} ({{ $t('global.optional') }}):</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_phone_number" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_phone_number" :placeholder="$t('client_phone')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_phone_number" :placeholder="$t('in_editor.plac.client_phone')" type="text" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
@@ -135,7 +135,7 @@
|
||||
<div v-if="isNewClient" class="block-wrapper">
|
||||
<label>{{ $t('in_editor.client_email') }} ({{ $t('global.optional') }}):</label>
|
||||
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="client_email" v-slot="{ errors }">
|
||||
<input v-model="invoice.client_email" :placeholder="$t('client_email')" type="email" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<input v-model="invoice.client_email" :placeholder="$t('in_editor.plac.client_email')" type="email" :class="{'is-error': errors[0]}" class="focus-border-theme" />
|
||||
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
|
||||
</ValidationProvider>
|
||||
</div>
|
||||
|
||||
137
resources/js/Oasis/Invoices/components/EmptyInvoicePage.vue
Normal file
137
resources/js/Oasis/Invoices/components/EmptyInvoicePage.vue
Normal file
@@ -0,0 +1,137 @@
|
||||
<template>
|
||||
<div class="empty-page" v-if="isLoading || isEmpty">
|
||||
<div class="empty-state">
|
||||
|
||||
<!--Base invoice browser empty message-->
|
||||
<div class="text-content" v-if="$isThisLocation(['regular-invoice', 'advance-invoice']) && !isLoading">
|
||||
<h1 class="title">
|
||||
Create Your First Invoice
|
||||
</h1>
|
||||
|
||||
<p class="description">
|
||||
It's very easy, just click on the button below.
|
||||
</p>
|
||||
|
||||
<ButtonBase @click.native="createInvoice" button-style="theme" class="button">
|
||||
{{ buttonTitle }}
|
||||
</ButtonBase>
|
||||
</div>
|
||||
<div class="text-content" v-if="$isThisLocation('clients') && !isLoading">
|
||||
<h1 class="title">
|
||||
Create Your First Client
|
||||
</h1>
|
||||
|
||||
<p class="description">
|
||||
It's very easy, just click on the button below.
|
||||
</p>
|
||||
|
||||
<ButtonBase @click.native="createClient" button-style="theme" class="button">
|
||||
Create Client
|
||||
</ButtonBase>
|
||||
</div>
|
||||
|
||||
<!--Spinner-->
|
||||
<div class="text-content" v-if="isLoading">
|
||||
<Spinner />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import ButtonBase from '@/components/FilesView/ButtonBase'
|
||||
import Spinner from '@/components/FilesView/Spinner'
|
||||
import {mapGetters} from 'vuex'
|
||||
|
||||
export default {
|
||||
name: 'EmptyFilePage',
|
||||
props: [
|
||||
'title',
|
||||
'description',
|
||||
],
|
||||
components: {
|
||||
ButtonBase,
|
||||
Spinner,
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'currentFolder',
|
||||
'isLoading',
|
||||
'entries',
|
||||
]),
|
||||
isEmpty() {
|
||||
return this.entries && this.entries.length == 0
|
||||
},
|
||||
buttonTitle() {
|
||||
return this.$isThisLocation('regular-invoice') ? 'Create Regular Invoice' : 'Create Advance Invoice'
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
createInvoice() {
|
||||
this.$router.push({name: 'CreateInvoice', query: {type: this.currentFolder.location}})
|
||||
},
|
||||
createClient() {
|
||||
this.$router.push({name: 'CreateClient'})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
@import '@assets/vuefilemanager/_variables';
|
||||
@import '@assets/vuefilemanager/_mixins';
|
||||
|
||||
.empty-page {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
top: 0;
|
||||
margin-top: 20px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.empty-state {
|
||||
margin: 0 auto;
|
||||
padding-left: 15px;
|
||||
padding-right: 15px;
|
||||
}
|
||||
}
|
||||
|
||||
.text-content {
|
||||
text-align: center;
|
||||
margin: 30px 0;
|
||||
|
||||
.title {
|
||||
@include font-size(20);
|
||||
color: $text;
|
||||
font-weight: 700;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.description {
|
||||
@include font-size(13);
|
||||
color: $text-muted;
|
||||
margin-bottom: 20px;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.button {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
}
|
||||
|
||||
@media (prefers-color-scheme: dark) {
|
||||
.text-content {
|
||||
|
||||
.title {
|
||||
color: $dark_mode_text_primary;
|
||||
}
|
||||
|
||||
.description {
|
||||
color: $dark_mode_text_secondary;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -44,7 +44,7 @@
|
||||
</div>
|
||||
|
||||
<!--Show empty page if folder is empty-->
|
||||
<EmptyFilePage v-if="! isSearching" />
|
||||
<EmptyInvoicePage v-if="! isSearching" />
|
||||
|
||||
<!--Show empty page if no search results-->
|
||||
<EmptyMessage
|
||||
@@ -64,9 +64,9 @@
|
||||
<script>
|
||||
import InvoiceActionsMobile from '@/Oasis/Invoices/components/InvoiceActionsMobile'
|
||||
import InvoiceInfoSidebar from '@/Oasis/Invoices/components/InvoiceInfoSidebar'
|
||||
import EmptyInvoicePage from '@/Oasis/Invoices/components/EmptyInvoicePage'
|
||||
import InvoiceItem from '@/Oasis/Invoices/components/InvoiceItem'
|
||||
import ClientItem from '@/Oasis/Invoices/components/ClientItem'
|
||||
import EmptyFilePage from '@/components/FilesView/EmptyFilePage'
|
||||
import MobileToolbar from '@/components/FilesView/MobileToolbar'
|
||||
import EmptyMessage from '@/components/FilesView/EmptyMessage'
|
||||
import SearchBar from '@/components/FilesView/SearchBar'
|
||||
@@ -78,7 +78,7 @@
|
||||
components: {
|
||||
InvoiceActionsMobile,
|
||||
InvoiceInfoSidebar,
|
||||
EmptyFilePage,
|
||||
EmptyInvoicePage,
|
||||
MobileToolbar,
|
||||
EmptyMessage,
|
||||
InvoiceItem,
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<Option @click.native="editItem" title="Edit Invoice" icon="rename" />
|
||||
<Option @click.native="" title="Send Invoice" icon="send" />
|
||||
<Option @click.native="goToCompany" title="Go to Company" icon="user" />
|
||||
<Option @click.native="deleteItem" :title="$t('context_menu.delete')" icon="trash" />
|
||||
<Option @click.native="deleteInvoice" :title="$t('context_menu.delete')" icon="trash" />
|
||||
</OptionGroup>
|
||||
|
||||
<OptionGroup>
|
||||
@@ -20,7 +20,7 @@
|
||||
<div v-show="isClient" class="menu-options" id="menu-list">
|
||||
<OptionGroup class="menu-option-group">
|
||||
<Option @click.native="goToCompany" title="Edit" icon="rename" />
|
||||
<Option @click.native="deleteItem" title="Delete" icon="trash" />
|
||||
<Option @click.native="deleteClient" title="Delete" icon="trash" />
|
||||
</OptionGroup>
|
||||
<OptionGroup>
|
||||
<Option @click.native="goToCompany" title="Go to Profile" icon="user" />
|
||||
@@ -75,7 +75,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
goToCompany() {
|
||||
this.$router.push({name: 'ClientDetail', params: {id: this.item.client_id}})
|
||||
this.$router.push({name: 'ClientDetail', params: {id: this.item.client_id ?? this.item.id}})
|
||||
|
||||
events.$emit('file-preview:hide')
|
||||
|
||||
@@ -98,7 +98,7 @@ export default {
|
||||
editItem() {
|
||||
this.$router.push({name: 'EditInvoice', params: {id: this.item.id}})
|
||||
},
|
||||
deleteItem() {
|
||||
deleteInvoice() {
|
||||
events.$emit('confirm:open', {
|
||||
title: `Are you sure you want to delete invoice number ${this.item.invoice_number}?`,
|
||||
message: 'Your invoice will be permanently deleted.',
|
||||
@@ -108,6 +108,17 @@ export default {
|
||||
operation: 'delete-invoice'
|
||||
}
|
||||
})
|
||||
},
|
||||
deleteClient() {
|
||||
events.$emit('confirm:open', {
|
||||
title: `Are you sure you want to delete client ${this.item.name}?`,
|
||||
message: 'Your client will be permanently deleted.',
|
||||
buttonColor: 'danger-solid',
|
||||
action: {
|
||||
id: this.item.id,
|
||||
operation: 'delete-client'
|
||||
}
|
||||
})
|
||||
},
|
||||
closeAndResetContextMenu() {
|
||||
// Close context menu
|
||||
|
||||
@@ -36,8 +36,8 @@
|
||||
<!--Invoice Controls-->
|
||||
<ToolbarGroup v-if="! $isMobile()">
|
||||
<ToolbarButton @click.native="shareInvoice" :class="{'is-inactive': canActiveInView }" source="send" :action="$t('actions.share')" />
|
||||
<ToolbarButton @click.native="editInvoice" :class="{'is-inactive': canActiveInView }" source="rename" :action="$t('actions.share')" />
|
||||
<ToolbarButton @click.native="deleteInvoice" :class="{'is-inactive': canActiveInView }" source="trash" :action="$t('actions.delete')" />
|
||||
<ToolbarButton @click.native="editItem" :class="{'is-inactive': canActiveInView }" source="rename" :action="$t('actions.share')" />
|
||||
<ToolbarButton @click.native="deleteItem" :class="{'is-inactive': canActiveInView }" source="trash" :action="$t('actions.delete')" />
|
||||
</ToolbarGroup>
|
||||
|
||||
<!--View Controls-->
|
||||
@@ -100,6 +100,7 @@
|
||||
let locations = [
|
||||
'regular-invoice',
|
||||
'advance-invoice',
|
||||
'clients',
|
||||
]
|
||||
return !this.$isThisLocation(locations) || this.clipboard.length === 0
|
||||
},
|
||||
@@ -127,8 +128,9 @@
|
||||
createCreateMenu() {
|
||||
events.$emit('popover:open', 'desktop-create-invoices')
|
||||
},
|
||||
deleteInvoice() {
|
||||
if (this.clipboard.length > 0) {
|
||||
deleteItem() {
|
||||
|
||||
if (this.$isThisLocation(['regular-invoice', 'advance-invoice']) && this.clipboard.length > 0) {
|
||||
|
||||
events.$emit('confirm:open', {
|
||||
title: `Are you sure you want to delete invoice number ${this.clipboard[0].invoice_number}?`,
|
||||
@@ -140,12 +142,30 @@
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
if (this.$isThisLocation('clients') && this.clipboard.length > 0) {
|
||||
events.$emit('confirm:open', {
|
||||
title: `Are you sure you want to delete client ${this.clipboard[0].name}?`,
|
||||
message: 'Your client will be permanently deleted.',
|
||||
buttonColor: 'danger-solid',
|
||||
action: {
|
||||
id: this.clipboard[0].id,
|
||||
operation: 'delete-client'
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
shareInvoice() {
|
||||
alert('Send Invoice')
|
||||
},
|
||||
editInvoice() {
|
||||
this.$router.push({name: 'EditInvoice', params: {id: this.clipboard[0].id}})
|
||||
editItem() {
|
||||
if (this.$isThisLocation(['regular-invoice', 'advance-invoice'])) {
|
||||
this.$router.push({name: 'EditInvoice', params: {id: this.clipboard[0].id}})
|
||||
}
|
||||
|
||||
if (this.$isThisLocation('clients')) {
|
||||
this.$router.push({name: 'ClientDetail', params: {id: this.clipboard[0].id}})
|
||||
}
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user