mirror of
https://github.com/InvoiceShelf/InvoiceShelf.git
synced 2026-05-25 20:54:56 +00:00
Merge branch 'master' into frontend-performance-improvements
This commit is contained in:
8
resources/scripts/admin/admin-router.js
vendored
8
resources/scripts/admin/admin-router.js
vendored
@@ -56,6 +56,8 @@ const UpdateApp = () =>
|
||||
import('@/scripts/admin/views/settings/UpdateAppSetting.vue')
|
||||
const RolesSettings = () =>
|
||||
import('@/scripts/admin/views/settings/RolesSettings.vue')
|
||||
const PDFGenerationSettings = () =>
|
||||
import('@/scripts/admin/views/settings/PDFGenerationSetting.vue')
|
||||
|
||||
// Items
|
||||
const ItemsIndex = () => import('@/scripts/admin/views/items/Index.vue')
|
||||
@@ -327,6 +329,12 @@ export default [
|
||||
meta: { isOwner: true },
|
||||
component: UpdateApp,
|
||||
},
|
||||
{
|
||||
path: 'pdf-generation',
|
||||
name: 'pdf.generation',
|
||||
meta: { isOwner: true },
|
||||
component: PDFGenerationSettings,
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit customField -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown :content-loading="customerStore.isFetchingViewData">
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'customers.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- Edit Customer -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'estimates.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else class="text-gray-500" name="DotsHorizontalIcon" />
|
||||
<BaseIcon v-else class="text-gray-500" name="EllipsisHorizontalIcon" />
|
||||
</template>
|
||||
|
||||
<!-- Copy PDF url -->
|
||||
|
||||
@@ -5,9 +5,9 @@
|
||||
v-if="route.name === 'expenseCategorys.view'"
|
||||
variant="primary"
|
||||
>
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit expenseCategory -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'expenses.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit expense -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'invoices.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- Edit Invoice -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'items.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit item -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'notes.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit note -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown :content-loading="contentLoading">
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'payments.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- Copy pdf url -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'paymentModes.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit paymentMode -->
|
||||
|
||||
@@ -5,9 +5,9 @@
|
||||
v-if="route.name === 'recurring-invoices.view'"
|
||||
variant="primary"
|
||||
>
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- Edit Recurring Invoice -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'roles.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit role -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'tax-types.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit tax-type -->
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<BaseButton v-if="route.name === 'users.view'" variant="primary">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="h-5 text-white" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="h-5 text-white" />
|
||||
</BaseButton>
|
||||
<BaseIcon v-else name="DotsHorizontalIcon" class="h-5 text-gray-500" />
|
||||
<BaseIcon v-else name="EllipsisHorizontalIcon" class="h-5 text-gray-500" />
|
||||
</template>
|
||||
|
||||
<!-- edit user -->
|
||||
|
||||
@@ -264,22 +264,12 @@ const quantity = computed({
|
||||
const price = computed({
|
||||
get: () => {
|
||||
const price = props.itemData.price
|
||||
|
||||
if (parseFloat(price) > 0) {
|
||||
return price / 100
|
||||
}
|
||||
|
||||
return price
|
||||
return price / 100
|
||||
},
|
||||
|
||||
set: (newValue) => {
|
||||
if (parseFloat(newValue) > 0) {
|
||||
let price = Math.round(newValue * 100)
|
||||
|
||||
updateItemAttribute('price', price)
|
||||
} else {
|
||||
updateItemAttribute('price', newValue)
|
||||
}
|
||||
let price = Math.round(newValue * 100)
|
||||
updateItemAttribute('price', price)
|
||||
setDiscount()
|
||||
},
|
||||
})
|
||||
|
||||
@@ -19,12 +19,24 @@
|
||||
>
|
||||
<template #singlelabel="{ value }">
|
||||
<div class="absolute left-3.5">
|
||||
{{ value.name }} - {{ value.percent }} %
|
||||
{{ value.name }} -
|
||||
<template v-if="value.calculation_type === 'fixed'">
|
||||
<BaseFormatMoney :amount="value.fixed_amount" :currency="currency" />
|
||||
</template>
|
||||
<template v-else>
|
||||
{{ value.percent }} %
|
||||
</template>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<template #option="{ option }">
|
||||
{{ option.name }} - {{ option.percent }} %
|
||||
{{ option.name }} -
|
||||
<template v-if="option.calculation_type === 'fixed'">
|
||||
<BaseFormatMoney :amount="option.fixed_amount" :currency="currency" />
|
||||
</template>
|
||||
<template v-else>
|
||||
{{ option.percent }} %
|
||||
</template>
|
||||
</template>
|
||||
|
||||
<template v-if="userStore.hasAbilities(ability)" #action>
|
||||
@@ -149,7 +161,12 @@ const filteredTypes = computed(() => {
|
||||
})
|
||||
|
||||
const taxAmount = computed(() => {
|
||||
if (props.discountedTotal && localTax.percent) {
|
||||
|
||||
if(localTax.calculation_type === 'fixed') {
|
||||
return localTax.fixed_amount
|
||||
}
|
||||
|
||||
if (props.discountedTotal) {
|
||||
const taxPerItemEnabled = props.store[props.storeProp].tax_per_item === 'YES'
|
||||
const discountPerItemEnabled = props.store[props.storeProp].discount_per_item === 'YES'
|
||||
if (taxPerItemEnabled && !discountPerItemEnabled){
|
||||
@@ -191,7 +208,9 @@ if (props.taxData.tax_type_id > 0) {
|
||||
updateRowTax()
|
||||
|
||||
function onSelectTax(val) {
|
||||
localTax.percent = val.percent
|
||||
localTax.calculation_type = val.calculation_type
|
||||
localTax.percent = val.calculation_type === 'percentage' ? val.percent : null
|
||||
localTax.fixed_amount = val.calculation_type === 'fixed' ? val.fixed_amount : null
|
||||
localTax.tax_type_id = val.id
|
||||
localTax.name = val.name
|
||||
|
||||
@@ -235,6 +254,11 @@ function removeTax(index) {
|
||||
}
|
||||
|
||||
function getTaxAmount() {
|
||||
|
||||
if (localTax.calculation_type === 'fixed') {
|
||||
return localTax.fixed_amount
|
||||
}
|
||||
|
||||
let total = 0
|
||||
let discount = 0
|
||||
const itemTotal = props.discountedTotal
|
||||
@@ -253,3 +277,4 @@ function getTaxAmount() {
|
||||
return Math.round((props.discountedTotal * localTax.percent) / 100)
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
@@ -50,7 +50,12 @@
|
||||
v-else-if="store[storeProp].tax_per_item === 'YES'"
|
||||
class="m-0 text-sm font-semibold leading-5 text-gray-500 uppercase"
|
||||
>
|
||||
{{ tax.name }} - {{ tax.percent }}%
|
||||
<template v-if="tax.calculation_type === 'percentage'">
|
||||
{{ tax.name }} - {{ tax.percent }}%
|
||||
</template>
|
||||
<template v-else>
|
||||
{{ tax.name }} - <BaseFormatMoney :amount="tax.fixed_amount" :currency="defaultCurrency" />
|
||||
</template>
|
||||
</label>
|
||||
|
||||
<BaseContentPlaceholders v-if="isLoading">
|
||||
@@ -277,6 +282,8 @@ const itemWiseTaxes = computed(() => {
|
||||
amount: Math.round(tax.amount),
|
||||
percent: tax.percent,
|
||||
name: tax.name,
|
||||
calculation_type: tax.calculation_type,
|
||||
fixed_amount: tax.fixed_amount
|
||||
})
|
||||
}
|
||||
})
|
||||
@@ -331,10 +338,12 @@ function selectPercentage() {
|
||||
|
||||
function onSelectTax(selectedTax) {
|
||||
let amount = 0
|
||||
if (props.store.getSubtotalWithDiscount && selectedTax.percent) {
|
||||
if (selectedTax.calculation_type === 'percentage' && props.store.getSubtotalWithDiscount && selectedTax.percent) {
|
||||
amount = Math.round(
|
||||
(props.store.getSubtotalWithDiscount * selectedTax.percent) / 100
|
||||
)
|
||||
} else if (selectedTax.calculation_type === 'fixed') {
|
||||
amount = selectedTax.fixed_amount
|
||||
}
|
||||
|
||||
let data = {
|
||||
@@ -344,6 +353,8 @@ function onSelectTax(selectedTax) {
|
||||
percent: selectedTax.percent,
|
||||
tax_type_id: selectedTax.id,
|
||||
amount,
|
||||
calculation_type: selectedTax.calculation_type,
|
||||
fixed_amount: selectedTax.fixed_amount
|
||||
}
|
||||
props.store.$patch((state) => {
|
||||
state[props.storeProp].taxes.push({ ...data })
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
<template>
|
||||
<div class="flex items-center justify-between w-full mt-2 text-sm">
|
||||
<label class="font-semibold leading-5 text-gray-500 uppercase">
|
||||
<label v-if="tax.calculation_type === 'percentage'" class="font-semibold leading-5 text-gray-500 uppercase">
|
||||
{{ tax.name }} ({{ tax.percent }} %)
|
||||
</label>
|
||||
<label v-else class="font-semibold leading-5 text-gray-500 uppercase">
|
||||
{{ tax.name }} (<BaseFormatMoney :amount="tax.fixed_amount" :currency="currency" />)
|
||||
</label>
|
||||
<label class="flex items-center justify-center text-lg text-black">
|
||||
<BaseFormatMoney :amount="tax.amount" :currency="currency" />
|
||||
|
||||
@@ -52,6 +55,10 @@ const emit = defineEmits(['update', 'remove'])
|
||||
const utils = inject('$utils')
|
||||
|
||||
const taxAmount = computed(() => {
|
||||
if (props.tax.calculation_type === 'fixed') {
|
||||
return props.tax.fixed_amount;
|
||||
}
|
||||
|
||||
if (props.tax.compound_tax && props.store.getSubtotalWithDiscount) {
|
||||
return Math.round(
|
||||
((props.store.getSubtotalWithDiscount + props.store.getTotalSimpleTax) *
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<div v-if="hasActiveProvider && isEdit">
|
||||
<BaseIcon
|
||||
v-tooltip="{ content: 'Fetch Latest Exchange rate' }"
|
||||
name="RefreshIcon"
|
||||
name="ArrowPathIcon"
|
||||
:class="`h-4 w-4 text-primary-500 cursor-pointer outline-none ${
|
||||
isFetching
|
||||
? ' animate-spin rotate-180 cursor-not-allowed pointer-events-none '
|
||||
|
||||
@@ -110,7 +110,12 @@
|
||||
cursor-pointer
|
||||
"
|
||||
>
|
||||
{{ taxType.percent }} %
|
||||
<template v-if="taxType.calculation_type === 'fixed'">
|
||||
<BaseFormatMoney :amount="taxType.fixed_amount" :currency="companyStore.selectedCompanyCurrency" />
|
||||
</template>
|
||||
<template v-else>
|
||||
{{ taxType.percent }} %
|
||||
</template>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
@@ -173,9 +178,11 @@ import { useInvoiceStore } from '@/scripts/admin/stores/invoice'
|
||||
import { useModalStore } from '@/scripts/stores/modal'
|
||||
import { useTaxTypeStore } from '@/scripts/admin/stores/tax-type'
|
||||
import { useUserStore } from '@/scripts/admin/stores/user'
|
||||
import { useCompanyStore } from '@/scripts/admin/stores/company'
|
||||
import abilities from '@/scripts/admin/stub/abilities'
|
||||
import BaseIcon from '@/scripts/components/base/BaseIcon.vue'
|
||||
import BaseInput from '@/scripts/components/base/BaseInput.vue'
|
||||
import BaseFormatMoney from '@/scripts/components/base/BaseFormatMoney.vue'
|
||||
|
||||
const props = defineProps({
|
||||
type: {
|
||||
@@ -197,10 +204,15 @@ const emit = defineEmits(['select:taxType'])
|
||||
const modalStore = useModalStore()
|
||||
const taxTypeStore = useTaxTypeStore()
|
||||
const userStore = useUserStore()
|
||||
const companyStore = useCompanyStore()
|
||||
|
||||
const { t } = useI18n()
|
||||
const textSearch = ref(null)
|
||||
|
||||
const formatMoney = (amount) => {
|
||||
return companyStore.formatMoney(amount)
|
||||
}
|
||||
|
||||
const filteredTaxType = computed(() => {
|
||||
if (textSearch.value) {
|
||||
return taxTypeStore.taxTypes.filter(function (el) {
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="onCancel"
|
||||
/>
|
||||
@@ -78,7 +78,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isCreateLoading"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeCategoryModal"
|
||||
/>
|
||||
@@ -74,7 +74,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
{{ modalStore.title }}
|
||||
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeCompanyModal"
|
||||
/>
|
||||
@@ -117,7 +117,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
{{ modalStore.title }}
|
||||
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeCustomerModal"
|
||||
/>
|
||||
@@ -167,7 +167,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
@@ -193,7 +193,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowConfirmPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowConfirmPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowConfirmPassword = !isShowConfirmPassword"
|
||||
/>
|
||||
@@ -438,7 +438,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isLoading"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
{{ modalStore.title }}
|
||||
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeExchangeRateModal"
|
||||
/>
|
||||
@@ -171,7 +171,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeDiskModal"
|
||||
/>
|
||||
@@ -40,7 +40,7 @@
|
||||
>
|
||||
<BaseIcon
|
||||
v-if="!isRequestFire(slotProps)"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
class="w-6 mr-2"
|
||||
/>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeItemModal"
|
||||
/>
|
||||
@@ -107,7 +107,7 @@
|
||||
type="submit"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ itemStore.isEdit ? $t('general.update') : $t('general.save') }}
|
||||
</BaseButton>
|
||||
@@ -178,7 +178,7 @@ const taxes = computed({
|
||||
return {
|
||||
...tax,
|
||||
tax_type_id: tax.id,
|
||||
tax_name: tax.name + ' (' + tax.percent + '%)',
|
||||
tax_name: tax.name + ' (' + (tax.calculation_type === 'fixed' ? tax.fixed_amount : tax.percent) + (tax.calculation_type === 'fixed' ? companyStore.selectedCompanyCurrency.symbol : '%') + ')',
|
||||
}
|
||||
}
|
||||
}),
|
||||
@@ -217,7 +217,17 @@ const v$ = useVuelidate(
|
||||
|
||||
const getTaxTypes = computed(() => {
|
||||
return taxTypeStore.taxTypes.map((tax) => {
|
||||
return { ...tax, tax_name: tax.name + ' (' + tax.percent + '%)' }
|
||||
const amount = tax.calculation_type === 'fixed'
|
||||
? new Intl.NumberFormat(undefined, {
|
||||
style: 'currency',
|
||||
currency: companyStore.selectedCompanyCurrency.code
|
||||
}).format(tax.fixed_amount / 100)
|
||||
: `${tax.percent}%`
|
||||
|
||||
return {
|
||||
...tax,
|
||||
tax_name: `${tax.name} (${amount})`
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
@@ -238,8 +248,10 @@ async function submitItemData() {
|
||||
taxes: itemStore.currentItem.taxes.map((tax) => {
|
||||
return {
|
||||
tax_type_id: tax.id,
|
||||
amount: (price.value * tax.percent) / 100,
|
||||
amount: tax.calculation_type === 'fixed' ? tax.fixed_amount : (price.value * tax.percent) / 100,
|
||||
percent: tax.percent,
|
||||
fixed_amount: tax.fixed_amount,
|
||||
calculation_type: tax.calculation_type,
|
||||
name: tax.name,
|
||||
collective_tax: 0,
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeItemUnitModal"
|
||||
/>
|
||||
@@ -58,7 +58,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeTestModal"
|
||||
/>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeNoteModal"
|
||||
/>
|
||||
@@ -45,6 +45,11 @@
|
||||
class="mt-2"
|
||||
/>
|
||||
</BaseInputGroup>
|
||||
<BaseSwitchSection
|
||||
v-model="noteStore.currentNote.is_default"
|
||||
:title="$t('settings.customization.notes.is_default')"
|
||||
:description="$t('settings.customization.notes.is_default_description')"
|
||||
_ />
|
||||
|
||||
<BaseInputGroup
|
||||
:label="$t('settings.customization.notes.notes')"
|
||||
@@ -89,7 +94,7 @@
|
||||
type="submit"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ noteStore.isEdit ? $t('general.update') : $t('general.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closePaymentModeModal"
|
||||
/>
|
||||
@@ -48,7 +48,7 @@
|
||||
type="submit"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{
|
||||
paymentStore.currentPaymentMode.id
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
{{ modalStore.title }}
|
||||
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeRolesModal"
|
||||
/>
|
||||
@@ -140,7 +140,7 @@
|
||||
type="submit"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ !roleStore.isEdit ? $t('general.save') : $t('general.update') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalTitle }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeModal"
|
||||
/>
|
||||
@@ -76,7 +76,7 @@
|
||||
</BaseButton>
|
||||
<BaseButton variant="primary" @click="chooseTemplate()">
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('general.choose') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeSendEstimateModal"
|
||||
/>
|
||||
@@ -82,7 +82,7 @@
|
||||
class="mr-3"
|
||||
@click="submitForm"
|
||||
>
|
||||
<BaseIcon v-if="!isLoading" name="PhotographIcon" class="h-5 mr-2" />
|
||||
<BaseIcon v-if="!isLoading" name="PhotoIcon" class="h-5 mr-2" />
|
||||
{{ $t('general.preview') }}
|
||||
</BaseButton>
|
||||
</div>
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalTitle }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeSendInvoiceModal"
|
||||
/>
|
||||
@@ -88,7 +88,7 @@
|
||||
<BaseIcon
|
||||
v-if="!isLoading"
|
||||
:class="slotProps.class"
|
||||
name="PhotographIcon"
|
||||
name="PhotoIcon"
|
||||
/>
|
||||
</template>
|
||||
{{ $t('general.preview') }}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalTitle }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeSendPaymentModal"
|
||||
/>
|
||||
@@ -88,7 +88,7 @@
|
||||
<BaseIcon
|
||||
v-if="!isLoading"
|
||||
:class="slotProps.class"
|
||||
name="PhotographIcon"
|
||||
name="PhotoIcon"
|
||||
/>
|
||||
</template>
|
||||
{{ $t('general.preview') }}
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<div class="flex justify-between w-full">
|
||||
{{ modalStore.title }}
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeTaxTypeModal"
|
||||
/>
|
||||
@@ -34,12 +34,28 @@
|
||||
</BaseInputGroup>
|
||||
|
||||
<BaseInputGroup
|
||||
:label="$t('tax_types.tax_type')"
|
||||
variant="horizontal"
|
||||
required
|
||||
>
|
||||
<BaseSelectInput
|
||||
v-model="taxTypeStore.currentTaxType.calculation_type"
|
||||
:options="[
|
||||
{ id: 'percentage', label: $t('tax_types.percentage') },
|
||||
{ id: 'fixed', label: $t('tax_types.fixed_amount') }
|
||||
]"
|
||||
:allow-empty="false"
|
||||
value-prop="id"
|
||||
label-prop="label"
|
||||
track-by="label"
|
||||
:searchable="false"
|
||||
/>
|
||||
</BaseInputGroup>
|
||||
|
||||
<BaseInputGroup
|
||||
v-if="taxTypeStore.currentTaxType.calculation_type === 'percentage'"
|
||||
:label="$t('tax_types.percent')"
|
||||
variant="horizontal"
|
||||
:error="
|
||||
v$.currentTaxType.percent.$error &&
|
||||
v$.currentTaxType.percent.$errors[0].$message
|
||||
"
|
||||
required
|
||||
>
|
||||
<BaseMoney
|
||||
@@ -51,13 +67,18 @@
|
||||
precision: 2,
|
||||
masked: false,
|
||||
}"
|
||||
:invalid="v$.currentTaxType.percent.$error"
|
||||
class="
|
||||
relative
|
||||
w-full
|
||||
focus:border focus:border-solid focus:border-primary
|
||||
"
|
||||
@input="v$.currentTaxType.percent.$touch()"
|
||||
/>
|
||||
</BaseInputGroup>
|
||||
|
||||
<BaseInputGroup
|
||||
v-else
|
||||
:label="$t('tax_types.fixed_amount')"
|
||||
variant="horizontal"
|
||||
required
|
||||
>
|
||||
<BaseMoney
|
||||
v-model="fixedAmount"
|
||||
:currency="defaultCurrency"
|
||||
/>
|
||||
</BaseInputGroup>
|
||||
|
||||
@@ -105,7 +126,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
@@ -127,6 +148,8 @@ import { computed, ref } from 'vue'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import Guid from 'guid'
|
||||
import TaxStub from '@/scripts/admin/stub/abilities'
|
||||
import { useCompanyStore } from '@/scripts/admin/stores/company'
|
||||
|
||||
import {
|
||||
required,
|
||||
minLength,
|
||||
@@ -148,6 +171,8 @@ const taxTypeStore = useTaxTypeStore()
|
||||
const modalStore = useModalStore()
|
||||
const notificationStore = useNotificationStore()
|
||||
const estimateStore = useEstimateStore()
|
||||
const companyStore = useCompanyStore()
|
||||
const defaultCurrency = computed(() => companyStore.selectedCompanyCurrency)
|
||||
|
||||
const { t, tm } = useI18n()
|
||||
let isSaving = ref(false)
|
||||
@@ -162,6 +187,9 @@ const rules = computed(() => {
|
||||
minLength(3)
|
||||
),
|
||||
},
|
||||
calculation_type: {
|
||||
required: helpers.withMessage(t('validation.required'), required),
|
||||
},
|
||||
percent: {
|
||||
required: helpers.withMessage(t('validation.required'), required),
|
||||
between: helpers.withMessage(
|
||||
@@ -169,6 +197,9 @@ const rules = computed(() => {
|
||||
between(-100, 100)
|
||||
),
|
||||
},
|
||||
fixed_amount: {
|
||||
required: helpers.withMessage(t('validation.required'), required),
|
||||
},
|
||||
description: {
|
||||
maxLength: helpers.withMessage(
|
||||
t('validation.description_maxlength', { count: 255 }),
|
||||
@@ -206,16 +237,22 @@ async function submitTaxTypeData() {
|
||||
|
||||
function SelectTax(taxData) {
|
||||
let amount = 0
|
||||
if (estimateStore.getSubtotalWithDiscount && taxData.percent) {
|
||||
amount = Math.round(
|
||||
(estimateStore.getSubtotalWithDiscount * taxData.percent) / 100
|
||||
)
|
||||
if (estimateStore.getSubtotalWithDiscount) {
|
||||
if (taxData.calculation_type === 'percentage') {
|
||||
amount = Math.round(
|
||||
(estimateStore.getSubtotalWithDiscount * taxData.percent) / 100
|
||||
)
|
||||
} else {
|
||||
amount = taxData.fixed_amount
|
||||
}
|
||||
}
|
||||
let data = {
|
||||
...TaxStub,
|
||||
id: Guid.raw(),
|
||||
name: taxData.name,
|
||||
calculation_type: taxData.calculation_type,
|
||||
percent: taxData.percent,
|
||||
fixed_amount: taxData.fixed_amount,
|
||||
tax_type_id: taxData.id,
|
||||
amount,
|
||||
}
|
||||
@@ -230,7 +267,9 @@ function selectItemTax(taxData) {
|
||||
...TaxStub,
|
||||
id: Guid.raw(),
|
||||
name: taxData.name,
|
||||
calculation_type: taxData.calculation_type,
|
||||
percent: taxData.percent,
|
||||
fixed_amount: taxData.fixed_amount,
|
||||
tax_type_id: taxData.id,
|
||||
}
|
||||
modalStore.refreshData(data)
|
||||
@@ -244,4 +283,11 @@ function closeTaxTypeModal() {
|
||||
v$.value.$reset()
|
||||
}, 300)
|
||||
}
|
||||
|
||||
const fixedAmount = computed({
|
||||
get: () => taxTypeStore.currentTaxType.fixed_amount / 100,
|
||||
set: (value) => {
|
||||
taxTypeStore.currentTaxType.fixed_amount = Math.round(value * 100)
|
||||
},
|
||||
})
|
||||
</script>
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
</p>
|
||||
</div>
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="h-6 w-6 text-gray-500 cursor-pointer"
|
||||
@click="closeModal"
|
||||
/>
|
||||
@@ -103,7 +103,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isLoading"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
{{ modalStore.title }}
|
||||
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-gray-500 cursor-pointer"
|
||||
@click="closeCustomFieldModal"
|
||||
/>
|
||||
@@ -201,7 +201,7 @@
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
:class="slotProps.class"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
/>
|
||||
</template>
|
||||
{{
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
"
|
||||
@click.prevent="onToggle"
|
||||
>
|
||||
<BaseIcon name="MenuIcon" class="!w-6 !h-6 text-gray-500" />
|
||||
<BaseIcon name="Bars3Icon" class="!w-6 !h-6 text-gray-500" />
|
||||
</div>
|
||||
|
||||
<ul class="flex float-right h-8 m-0 list-none md:h-9">
|
||||
@@ -160,7 +160,7 @@
|
||||
|
||||
<BaseDropdownItem @click="logout">
|
||||
<BaseIcon
|
||||
name="LogoutIcon"
|
||||
name="ArrowRightOnRectangleIcon"
|
||||
class="w-5 h-5 mr-3 text-gray-400 group-hover:text-gray-500"
|
||||
aria-hidden="true"
|
||||
/>
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
>
|
||||
<span class="sr-only">Close sidebar</span>
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="w-6 h-6 text-white"
|
||||
aria-hidden="true"
|
||||
/>
|
||||
|
||||
4
resources/scripts/admin/stores/estimate.js
vendored
4
resources/scripts/admin/stores/estimate.js
vendored
@@ -14,6 +14,7 @@ import estimateStub from '../stub/estimate'
|
||||
import estimateItemStub from '../stub/estimate-item'
|
||||
import taxStub from '../stub/tax'
|
||||
import { useUserStore } from './user'
|
||||
import { useNotesStore } from './note'
|
||||
|
||||
export const useEstimateStore = (useWindow = false) => {
|
||||
const defineStoreFunc = useWindow ? window.pinia.defineStore : defineStore
|
||||
@@ -554,6 +555,7 @@ export const useEstimateStore = (useWindow = false) => {
|
||||
const taxTypeStore = useTaxTypeStore()
|
||||
const route = useRoute()
|
||||
const userStore = useUserStore()
|
||||
const notesStore = useNotesStore()
|
||||
|
||||
this.isFetchingInitialSettings = true
|
||||
this.newEstimate.selectedCurrency = companyStore.selectedCompanyCurrency
|
||||
@@ -567,6 +569,8 @@ export const useEstimateStore = (useWindow = false) => {
|
||||
let editActions = []
|
||||
|
||||
if (!isEdit) {
|
||||
await notesStore.fetchNotes()
|
||||
this.newEstimate.notes = notesStore.getDefaultNoteForType('Estimate')?.notes
|
||||
this.newEstimate.tax_per_item =
|
||||
companyStore.selectedCompanySettings.tax_per_item
|
||||
this.newEstimate.sales_tax_type = companyStore.selectedCompanySettings.sales_tax_type
|
||||
|
||||
6
resources/scripts/admin/stores/invoice.js
vendored
6
resources/scripts/admin/stores/invoice.js
vendored
@@ -15,6 +15,7 @@ import { useTaxTypeStore } from './tax-type'
|
||||
import { useCompanyStore } from './company'
|
||||
import { useItemStore } from './item'
|
||||
import { useUserStore } from './user'
|
||||
import { useNotesStore } from './note'
|
||||
|
||||
export const useInvoiceStore = (useWindow = false) => {
|
||||
const defineStoreFunc = useWindow ? window.pinia.defineStore : defineStore
|
||||
@@ -479,6 +480,7 @@ export const useInvoiceStore = (useWindow = false) => {
|
||||
const taxTypeStore = useTaxTypeStore()
|
||||
const route = useRoute()
|
||||
const userStore = useUserStore()
|
||||
const notesStore = useNotesStore()
|
||||
|
||||
this.isFetchingInitialSettings = true
|
||||
|
||||
@@ -491,8 +493,10 @@ export const useInvoiceStore = (useWindow = false) => {
|
||||
}
|
||||
|
||||
let editActions = []
|
||||
|
||||
|
||||
if (!isEdit) {
|
||||
await notesStore.fetchNotes()
|
||||
this.newInvoice.notes = notesStore.getDefaultNoteForType('Invoice')?.notes
|
||||
this.newInvoice.tax_per_item =
|
||||
companyStore.selectedCompanySettings.tax_per_item
|
||||
this.newInvoice.sales_tax_type = companyStore.selectedCompanySettings.sales_tax_type
|
||||
|
||||
@@ -37,6 +37,7 @@ export const useMailDriverStore = (useWindow = false) => {
|
||||
mail_port: null,
|
||||
mail_ses_key: '',
|
||||
mail_ses_secret: '',
|
||||
mail_ses_region: '',
|
||||
mail_encryption: 'tls',
|
||||
from_mail: '',
|
||||
from_name: '',
|
||||
|
||||
6
resources/scripts/admin/stores/note.js
vendored
6
resources/scripts/admin/stores/note.js
vendored
@@ -14,6 +14,7 @@ export const useNotesStore = (useWindow = false) => {
|
||||
currentNote: {
|
||||
id: null,
|
||||
type: '',
|
||||
is_default: false,
|
||||
name: '',
|
||||
notes: '',
|
||||
},
|
||||
@@ -24,9 +25,14 @@ export const useNotesStore = (useWindow = false) => {
|
||||
},
|
||||
|
||||
actions: {
|
||||
getDefaultNoteForType(type) {
|
||||
return this.notes.find((note) => note.type === type && note.is_default)
|
||||
},
|
||||
|
||||
resetCurrentNote() {
|
||||
this.currentNote = {
|
||||
type: '',
|
||||
is_default: false,
|
||||
name: '',
|
||||
notes: '',
|
||||
}
|
||||
|
||||
4
resources/scripts/admin/stores/payment.js
vendored
4
resources/scripts/admin/stores/payment.js
vendored
@@ -6,6 +6,7 @@ import { useCompanyStore } from './company'
|
||||
import { useNotificationStore } from '@/scripts/stores/notification'
|
||||
import paymentStub from '../stub/payment'
|
||||
import { handleError } from '@/scripts/helpers/error-handling'
|
||||
import { useNotesStore } from './note'
|
||||
|
||||
export const usePaymentStore = (useWindow = false) => {
|
||||
const defineStoreFunc = useWindow ? window.pinia.defineStore : defineStore
|
||||
@@ -56,6 +57,7 @@ export const usePaymentStore = (useWindow = false) => {
|
||||
actions: {
|
||||
fetchPaymentInitialData(isEdit) {
|
||||
const companyStore = useCompanyStore()
|
||||
const notesStore = useNotesStore()
|
||||
const route = useRoute()
|
||||
|
||||
this.isFetchingInitialData = true
|
||||
@@ -80,6 +82,8 @@ export const usePaymentStore = (useWindow = false) => {
|
||||
|
||||
// On Create
|
||||
else if (!isEdit && res2.data) {
|
||||
await notesStore.fetchNotes()
|
||||
this.currentPayment.notes = notesStore.getDefaultNoteForType('Payment')?.notes
|
||||
this.currentPayment.payment_date = moment().format('YYYY-MM-DD')
|
||||
this.currentPayment.payment_number = res2.data.nextNumber
|
||||
this.currentPayment.currency =
|
||||
|
||||
70
resources/scripts/admin/stores/pdf-driver.js
vendored
Normal file
70
resources/scripts/admin/stores/pdf-driver.js
vendored
Normal file
@@ -0,0 +1,70 @@
|
||||
const { defineStore } = window.pinia
|
||||
import { handleError } from '@/scripts/helpers/error-handling'
|
||||
import { useNotificationStore } from '@/scripts/stores/notification'
|
||||
import axios from 'axios'
|
||||
|
||||
export const usePDFDriverStore = (useWindow = false) => {
|
||||
const defineStoreFunc = useWindow ? window.pinia.defineStore : defineStore
|
||||
const { global } = window.i18n
|
||||
|
||||
return defineStoreFunc({
|
||||
id: 'pdf-driver',
|
||||
|
||||
state: () => ({
|
||||
pdfDriverConfig: null,
|
||||
pdf_driver: 'dompdf',
|
||||
pdf_drivers: [],
|
||||
|
||||
dompdf: {
|
||||
pdf_driver: '',
|
||||
},
|
||||
gotenberg: {
|
||||
pdf_driver: '',
|
||||
gotenberg_host: '',
|
||||
gotenberg_papersize: ''
|
||||
}
|
||||
}),
|
||||
|
||||
actions: {
|
||||
async fetchDrivers() {
|
||||
try {
|
||||
const response = await axios.get('/api/v1/pdf/drivers')
|
||||
this.pdf_drivers = response.data
|
||||
} catch (err) {
|
||||
handleError(err)
|
||||
throw err
|
||||
}
|
||||
},
|
||||
async fetchConfig() {
|
||||
try {
|
||||
const response = await axios.get('/api/v1/pdf/config')
|
||||
this.pdfDriverConfig = response.data
|
||||
this.pdf_driver = response.data.pdf_driver
|
||||
} catch (err) {
|
||||
handleError(err)
|
||||
throw err
|
||||
}
|
||||
},
|
||||
async updateConfig(data) {
|
||||
try {
|
||||
const response = await axios.post('/api/v1/pdf/config', data)
|
||||
const notificationStore = useNotificationStore()
|
||||
if (response.data.success) {
|
||||
notificationStore.showNotification({
|
||||
type: 'success',
|
||||
message: global.t('settings.pdf.' + response.data.success),
|
||||
})
|
||||
} else {
|
||||
notificationStore.showNotification({
|
||||
type: 'error',
|
||||
message: global.t('settings.pdf.' + response.data.error),
|
||||
})
|
||||
}
|
||||
} catch (err) {
|
||||
handleError(err)
|
||||
throw err
|
||||
}
|
||||
},
|
||||
},
|
||||
})()
|
||||
}
|
||||
@@ -14,6 +14,7 @@ import moment from 'moment'
|
||||
import _ from 'lodash'
|
||||
import { useInvoiceStore } from './invoice'
|
||||
import { useNotificationStore } from '@/scripts/stores/notification'
|
||||
import { useNotesStore } from './note'
|
||||
|
||||
export const useRecurringInvoiceStore = (useWindow = false) => {
|
||||
const defineStoreFunc = useWindow ? window.pinia.defineStore : defineStore
|
||||
@@ -334,6 +335,7 @@ export const useRecurringInvoiceStore = (useWindow = false) => {
|
||||
const invoiceStore = useInvoiceStore()
|
||||
const taxTypeStore = useTaxTypeStore()
|
||||
const route = useRoute()
|
||||
const notesStore = useNotesStore()
|
||||
|
||||
this.isFetchingInitialSettings = true
|
||||
this.newRecurringInvoice.currency = companyStore.selectedCompanyCurrency
|
||||
@@ -348,6 +350,8 @@ export const useRecurringInvoiceStore = (useWindow = false) => {
|
||||
|
||||
// on create
|
||||
if (!isEdit) {
|
||||
await notesStore.fetchNotes()
|
||||
this.newRecurringInvoice.notes = notesStore.getDefaultNoteForType('Invoice')?.notes
|
||||
this.newRecurringInvoice.tax_per_item =
|
||||
companyStore.selectedCompanySettings.tax_per_item
|
||||
this.newRecurringInvoice.discount_per_item =
|
||||
|
||||
4
resources/scripts/admin/stores/tax-type.js
vendored
4
resources/scripts/admin/stores/tax-type.js
vendored
@@ -15,7 +15,9 @@ export const useTaxTypeStore = (useWindow = false) => {
|
||||
currentTaxType: {
|
||||
id: null,
|
||||
name: '',
|
||||
calculation_type: 'percentage',
|
||||
percent: 0,
|
||||
fixed_amount: 0,
|
||||
description: '',
|
||||
compound_tax: false,
|
||||
collective_tax: 0,
|
||||
@@ -31,7 +33,9 @@ export const useTaxTypeStore = (useWindow = false) => {
|
||||
this.currentTaxType = {
|
||||
id: null,
|
||||
name: '',
|
||||
calculation_type: 'percentage',
|
||||
percent: 0,
|
||||
fixed_amount: 0,
|
||||
description: '',
|
||||
compound_tax: false,
|
||||
collective_tax: 0,
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
<base-dropdown width-class="w-48" margin-class="mt-1">
|
||||
<template #activator>
|
||||
<div class="flex items-center justify-center">
|
||||
<DotsHorizontalIcon class="w-6 h-6 text-gray-600" />
|
||||
<EllipsisHorizontalIcon class="w-6 h-6 text-gray-600" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -79,17 +79,18 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import BaseDropdownItem from '@/scripts/components/base/BaseDropdownItem.vue'
|
||||
import BaseDropdown from '@/scripts/components/base/BaseDropdown.vue'
|
||||
import BasePage from '@/scripts/components/base/BasePage.vue'
|
||||
|
||||
import { computed, reactive } from 'vue'
|
||||
import { useItemStore } from '@/scripts/admin/stores/item'
|
||||
import {
|
||||
UserIcon,
|
||||
DocumentIcon,
|
||||
DocumentTextIcon,
|
||||
DotsHorizontalIcon,
|
||||
} from '@heroicons/vue/solid'
|
||||
import BaseDropdownItem from '@/scripts/components/base/BaseDropdownItem.vue'
|
||||
import BaseDropdown from '@/scripts/components/base/BaseDropdown.vue'
|
||||
import BasePage from '@/scripts/components/base/BasePage.vue'
|
||||
EllipsisHorizontalIcon,
|
||||
} from '@heroicons/vue/24/solid'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
@@ -97,7 +98,7 @@ export default {
|
||||
BaseDropdown,
|
||||
BaseDropdownItem,
|
||||
BaseTable,
|
||||
DotsHorizontalIcon,
|
||||
EllipsisHorizontalIcon,
|
||||
UserIcon,
|
||||
DocumentIcon,
|
||||
DocumentTextIcon,
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<div class="flex items-center justify-end">
|
||||
<BaseButton type="submit" :loading="isSaving" :disabled="isSaving">
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{
|
||||
isEdit
|
||||
@@ -223,7 +223,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
@@ -250,7 +250,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowConfirmPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowConfirmPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowConfirmPassword = !isShowConfirmPassword"
|
||||
/>
|
||||
|
||||
@@ -22,10 +22,10 @@
|
||||
<template #right="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<div class="col-span-12 xl:col-span-9 xxl:col-span-10">
|
||||
<div class="flex justify-between mt-1 mb-6">
|
||||
<h6 class="flex items-center">
|
||||
<BaseIcon name="ChartSquareBarIcon" class="h-5 text-primary-400" />
|
||||
<BaseIcon name="ChartBarSquareIcon" class="h-5 text-primary-400" />
|
||||
{{ $t('dashboard.monthly_chart.title') }}
|
||||
</h6>
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
variant="gray"
|
||||
@input="onSearch()"
|
||||
>
|
||||
<BaseIcon name="SearchIcon" class="text-gray-500" />
|
||||
<BaseIcon name="MagnifyingGlassIcon" class="text-gray-500" />
|
||||
</BaseInput>
|
||||
|
||||
<div class="flex mb-6 ml-3" role="group" aria-label="First group">
|
||||
@@ -47,7 +47,7 @@
|
||||
>
|
||||
<template #activator>
|
||||
<BaseButton variant="gray">
|
||||
<BaseIcon name="FilterIcon" />
|
||||
<BaseIcon name="FunnelIcon" />
|
||||
</BaseButton>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
>
|
||||
<div class="flex justify-between mt-1 mb-4 flex-col md:flex-row">
|
||||
<h6 class="flex items-center sw-section-title h-10">
|
||||
<BaseIcon name="ChartSquareBarIcon" class="text-primary-400 mr-1" />
|
||||
<BaseIcon name="ChartBarSquareIcon" class="text-primary-400 mr-1" />
|
||||
{{ $t('dashboard.monthly_chart.title') }}
|
||||
</h6>
|
||||
|
||||
|
||||
@@ -24,9 +24,9 @@
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
:class="slotProps.class"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -73,7 +73,7 @@
|
||||
@input="onSearched()"
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon name="SearchIcon" class="text-gray-400" />
|
||||
<BaseIcon name="MagnifyingGlassIcon" class="text-gray-400" />
|
||||
</template>
|
||||
</BaseInput>
|
||||
</div>
|
||||
@@ -87,7 +87,7 @@
|
||||
>
|
||||
<template #activator>
|
||||
<BaseButton size="md" variant="gray">
|
||||
<BaseIcon name="FilterIcon" />
|
||||
<BaseIcon name="FunnelIcon" />
|
||||
</BaseButton>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
:class="slotProps.class"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
/>
|
||||
</template>
|
||||
{{ $t('estimates.save_estimate') }}
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
@@ -264,7 +264,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -17,10 +17,10 @@
|
||||
<template #right="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
@@ -94,7 +94,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowConfirmPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowConfirmPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowConfirmPassword = !isShowConfirmPassword"
|
||||
/>
|
||||
@@ -105,7 +105,7 @@
|
||||
|
||||
<BaseButton :loading="isSaving" :disabled="isSaving" class="mt-4">
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('wizard.save_cont') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -153,7 +153,7 @@
|
||||
|
||||
<BaseButton :loading="isSaving" :disabled="isSaving" class="mt-4">
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('wizard.save_cont') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('wizard.save_cont') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
:disabled="isSaving"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('wizard.save_cont') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -118,7 +118,7 @@
|
||||
:disabled="isSaving"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('wizard.save_cont') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
:disabled="isSaving"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('wizard.save_cont') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('general.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
@@ -137,7 +137,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('general.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -160,13 +160,32 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
</template>
|
||||
</BaseInput>
|
||||
</BaseInputGroup>
|
||||
|
||||
<BaseInputGroup
|
||||
:label="$t('settings.mail.ses_region')"
|
||||
:content-loading="isFetchingInitialData"
|
||||
:error="
|
||||
v$.sesConfig.mail_ses_region.$error &&
|
||||
v$.sesConfig.mail_ses_region.$errors[0].$message
|
||||
"
|
||||
required
|
||||
>
|
||||
<BaseInput
|
||||
v-model.trim="mailDriverStore.sesConfig.mail_ses_region"
|
||||
:content-loading="isFetchingInitialData"
|
||||
type="text"
|
||||
name="mail_ses_region"
|
||||
:invalid="v$.sesConfig.mail_ses_region.$error"
|
||||
@input="v$.sesConfig.mail_ses_region.$touch()"
|
||||
/>
|
||||
</BaseInputGroup>
|
||||
</div>
|
||||
|
||||
<BaseButton
|
||||
@@ -176,7 +195,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
|
||||
{{ $t('general.save') }}
|
||||
@@ -242,6 +261,9 @@ const rules = computed(() => {
|
||||
mail_ses_secret: {
|
||||
required: helpers.withMessage(t('validation.required'), required),
|
||||
},
|
||||
mail_ses_region: {
|
||||
required: helpers.withMessage(t('validation.required'), required),
|
||||
},
|
||||
mail_encryption: {
|
||||
required: helpers.withMessage(t('validation.required'), required),
|
||||
},
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeOffIcon'"
|
||||
:name="isShowPassword ? 'EyeIcon' : 'EyeSlashIcon'"
|
||||
class="mr-1 text-gray-500 cursor-pointer"
|
||||
@click="isShowPassword = !isShowPassword"
|
||||
/>
|
||||
@@ -163,7 +163,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-if="!isSaving" name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('general.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -17,10 +17,10 @@
|
||||
<template #right="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -335,7 +335,7 @@ onSearched = debounce(onSearched, 500)
|
||||
@input="onSearched()"
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon name="SearchIcon" class="h-5 text-gray-400" />
|
||||
<BaseIcon name="MagnifyingGlassIcon" class="h-5 text-gray-400" />
|
||||
</template>
|
||||
</BaseInput>
|
||||
</div>
|
||||
@@ -344,7 +344,7 @@ onSearched = debounce(onSearched, 500)
|
||||
<BaseDropdown class="ml-3" position="bottom-start">
|
||||
<template #activator>
|
||||
<BaseButton size="md" variant="gray">
|
||||
<BaseIcon name="FilterIcon" />
|
||||
<BaseIcon name="FunnelIcon" />
|
||||
</BaseButton>
|
||||
</template>
|
||||
<div
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
@@ -145,6 +145,7 @@ import { cloneDeep } from 'lodash'
|
||||
|
||||
import { useInvoiceStore } from '@/scripts/admin/stores/invoice'
|
||||
import { useModuleStore } from '@/scripts/admin/stores/module'
|
||||
import { useNotesStore } from '@/scripts/admin/stores/note'
|
||||
import { useCompanyStore } from '@/scripts/admin/stores/company'
|
||||
import { useCustomFieldStore } from '@/scripts/admin/stores/custom-field'
|
||||
|
||||
@@ -170,6 +171,8 @@ const invoiceStore = useInvoiceStore()
|
||||
const companyStore = useCompanyStore()
|
||||
const customFieldStore = useCustomFieldStore()
|
||||
const moduleStore = useModuleStore()
|
||||
const notesStore = useNotesStore()
|
||||
|
||||
const { t } = useI18n()
|
||||
let route = useRoute()
|
||||
let router = useRouter()
|
||||
|
||||
@@ -118,7 +118,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
@@ -191,7 +191,12 @@ const taxes = computed({
|
||||
return {
|
||||
...tax,
|
||||
tax_type_id: tax.id,
|
||||
tax_name: tax.name + ' (' + tax.percent + '%)',
|
||||
tax_name: `${tax.name} (${tax.calculation_type === 'fixed'
|
||||
? new Intl.NumberFormat(undefined, {
|
||||
style: 'currency',
|
||||
currency: companyStore.selectedCompanyCurrency.code
|
||||
}).format(tax.fixed_amount / 100)
|
||||
: `${tax.percent}%`})`,
|
||||
}
|
||||
}
|
||||
}),
|
||||
@@ -211,7 +216,12 @@ const getTaxTypes = computed(() => {
|
||||
return {
|
||||
...tax,
|
||||
tax_type_id: tax.id,
|
||||
tax_name: tax.name + ' (' + tax.percent + '%)',
|
||||
tax_name: `${tax.name} (${tax.calculation_type === 'fixed'
|
||||
? new Intl.NumberFormat(undefined, {
|
||||
style: 'currency',
|
||||
currency: companyStore.selectedCompanyCurrency.code
|
||||
}).format(tax.fixed_amount / 100)
|
||||
: `${tax.percent}%`})`,
|
||||
}
|
||||
})
|
||||
})
|
||||
@@ -287,7 +297,9 @@ async function submitItem() {
|
||||
data.taxes = itemStore.currentItem.taxes.map((tax) => {
|
||||
return {
|
||||
tax_type_id: tax.tax_type_id,
|
||||
amount: price.value * tax.percent,
|
||||
calculation_type: tax.calculation_type,
|
||||
fixed_amount: tax.fixed_amount,
|
||||
amount: tax.calculation_type === 'fixed' ? tax.fixed_amount : price.value * tax.percent,
|
||||
percent: tax.percent,
|
||||
name: tax.name,
|
||||
collective_tax: 0,
|
||||
|
||||
@@ -18,9 +18,9 @@
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
:class="slotProps.class"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -90,7 +90,7 @@
|
||||
<div class="flex space-x-2">
|
||||
<BaseButton class="mt-6" :loading="isSaving" type="submit">
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('general.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -274,7 +274,7 @@
|
||||
class="mr-4 flex items-center justify-center text-base"
|
||||
@click="installModule()"
|
||||
>
|
||||
<BaseIcon v-if="!isInstalling" name="DownloadIcon" class="mr-2" />
|
||||
<BaseIcon v-if="!isInstalling" name="ArrowDownTrayIcon" class="mr-2" />
|
||||
{{ $t('modules.install') }}
|
||||
</BaseButton>
|
||||
</div>
|
||||
@@ -306,7 +306,7 @@
|
||||
class="mr-4 flex items-center justify-center text-base"
|
||||
@click="disableModule"
|
||||
>
|
||||
<BaseIcon v-if="!isDisabling" name="BanIcon" class="mr-2" />
|
||||
<BaseIcon v-if="!isDisabling" name="NoSymbolIcon" class="mr-2" />
|
||||
{{ $t('modules.disable') }}
|
||||
</BaseButton>
|
||||
<BaseButton
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
@@ -237,7 +237,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -19,9 +19,9 @@
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
:class="slotProps.class"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
type="text"
|
||||
@input="onSearch"
|
||||
>
|
||||
<BaseIcon name="SearchIcon" class="h-5" />
|
||||
<BaseIcon name="MagnifyingGlassIcon" class="h-5" />
|
||||
</BaseInput>
|
||||
|
||||
<div class="flex ml-3" role="group" aria-label="First group">
|
||||
@@ -65,7 +65,7 @@
|
||||
>
|
||||
<template #activator>
|
||||
<BaseButton variant="gray">
|
||||
<BaseIcon name="FilterIcon" />
|
||||
<BaseIcon name="FunnelIcon" />
|
||||
</BaseButton>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -23,10 +23,10 @@
|
||||
<template #right="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!showFilters"
|
||||
name="FilterIcon"
|
||||
name="FunnelIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
<BaseIcon v-else name="XIcon" :class="slotProps.class" />
|
||||
<BaseIcon v-else name="XMarkIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
</BaseButton>
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
</template>
|
||||
|
||||
@@ -186,7 +186,7 @@ onSearched = debounce(onSearched, 500)
|
||||
@input="onSearched()"
|
||||
>
|
||||
<template #right>
|
||||
<BaseIcon name="SearchIcon" class="h-5 text-gray-400" />
|
||||
<BaseIcon name="MagnifyingGlassIcon" class="h-5 text-gray-400" />
|
||||
</template>
|
||||
</BaseInput>
|
||||
</div>
|
||||
@@ -195,7 +195,7 @@ onSearched = debounce(onSearched, 500)
|
||||
<BaseDropdown class="ml-3" position="bottom-start">
|
||||
<template #activator>
|
||||
<BaseButton size="md" variant="gray">
|
||||
<BaseIcon name="FilterIcon" class="h-5" />
|
||||
<BaseIcon name="FunnelIcon" class="h-5" />
|
||||
</BaseButton>
|
||||
</template>
|
||||
<div
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<template #actions>
|
||||
<BaseButton variant="primary" class="ml-4" @click="onDownload">
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="DownloadIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownTrayIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('reports.download_pdf') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -86,7 +86,7 @@
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
:class="slotProps.class"
|
||||
></BaseIcon>
|
||||
</template>
|
||||
|
||||
@@ -47,12 +47,12 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<div class="inline-block">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="text-gray-500" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="text-gray-500" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<BaseDropdownItem @click="onDownloadBckup(row.data)">
|
||||
<BaseIcon name="CloudDownloadIcon" class="mr-3 text-gray-600" />
|
||||
<BaseIcon name="CloudArrowDownIcon" class="mr-3 text-gray-600" />
|
||||
|
||||
{{ $t('general.download') }}
|
||||
</BaseDropdownItem>
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
class="mt-6"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="SaveIcon" />
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="ArrowDownOnSquareIcon" />
|
||||
</template>
|
||||
{{ $t('settings.company_info.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
<BaseDropdown>
|
||||
<template #activator>
|
||||
<div class="inline-block">
|
||||
<DotsHorizontalIcon class="w-5 text-gray-500" />
|
||||
<EllipsisHorizontalIcon class="w-5 text-gray-500" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -71,10 +71,17 @@ import { useExchangeRateStore } from '@/scripts/admin/stores/exchange-rate'
|
||||
import { useCompanyStore } from '@/scripts/admin/stores/company'
|
||||
import { useModalStore } from '@/scripts/stores/modal'
|
||||
import { useDialogStore } from '@/scripts/stores/dialog'
|
||||
import { DotsHorizontalIcon, PencilIcon, PlusIcon, TrashIcon } from '@heroicons/vue/outline'
|
||||
import { computed, inject, reactive, ref } from 'vue'
|
||||
import { ArrowDownOnSquareIcon } from '@heroicons/vue/24/outline'
|
||||
import { ref, computed, inject, reactive } from 'vue'
|
||||
import ExchangeRateProviderModal from '@/scripts/admin/components/modal-components/ExchangeRateProviderModal.vue'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import {
|
||||
PlusIcon,
|
||||
EllipsisHorizontalIcon,
|
||||
PencilIcon,
|
||||
TrashIcon,
|
||||
} from '@heroicons/vue/24/outline'
|
||||
|
||||
import BaseTable from '@/scripts/components/base/base-table/BaseTable.vue'
|
||||
import BaseDropdownItem from '@/scripts/components/base/BaseDropdownItem.vue'
|
||||
import BaseDropdown from '@/scripts/components/base/BaseDropdown.vue'
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
<BaseDropdown v-if="isNotSystemDisk(row.data)">
|
||||
<template #activator>
|
||||
<div class="inline-block">
|
||||
<BaseIcon name="DotsHorizontalIcon" class="text-gray-500" />
|
||||
<BaseIcon name="EllipsisHorizontalIcon" class="text-gray-500" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -31,6 +31,10 @@
|
||||
:load-data="refreshTable"
|
||||
/>
|
||||
</template>
|
||||
<template #cell-name="{ row }">
|
||||
{{ row.data.name }}
|
||||
<BaseIcon v-if="row.data.is_default" name="StarIcon" class="w-3 h-3 text-primary-400" />
|
||||
</template>
|
||||
<template #cell-type="{ row }">
|
||||
{{ getLabelNote(row.data.type) }}
|
||||
</template>
|
||||
@@ -42,9 +46,7 @@
|
||||
import { computed, reactive, ref } from 'vue'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { useModalStore } from '@/scripts/stores/modal'
|
||||
import { useDialogStore } from '@/scripts/stores/dialog'
|
||||
import { useNotesStore } from '@/scripts/admin/stores/note'
|
||||
import { useNotificationStore } from '@/scripts/stores/notification'
|
||||
import NoteDropdown from '@/scripts/admin/components/dropdowns/NoteIndexDropdown.vue'
|
||||
import NoteModal from '@/scripts/admin/components/modal-components/NoteModal.vue'
|
||||
import { useUserStore } from '@/scripts/admin/stores/user'
|
||||
@@ -57,9 +59,7 @@ import BaseSettingCard from '@/scripts/components/base/BaseSettingCard.vue'
|
||||
const { t } = useI18n()
|
||||
|
||||
const modalStore = useModalStore()
|
||||
const dialogStore = useDialogStore()
|
||||
const noteStore = useNotesStore()
|
||||
const notificationStore = useNotificationStore()
|
||||
const userStore = useUserStore()
|
||||
|
||||
const table = ref('')
|
||||
@@ -70,7 +70,7 @@ const notesColumns = computed(() => {
|
||||
key: 'name',
|
||||
label: t('settings.customization.notes.name'),
|
||||
thClass: 'extra',
|
||||
tdClass: 'font-medium text-gray-900',
|
||||
tdClass: 'font-medium text-gray-900 flex gap-1 items-center',
|
||||
},
|
||||
{
|
||||
key: 'type',
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
<BaseIcon
|
||||
v-if="!isSaving"
|
||||
:class="slotProps.class"
|
||||
name="SaveIcon"
|
||||
name="ArrowDownOnSquareIcon"
|
||||
/>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
<template>
|
||||
<BaseSettingCard
|
||||
:title="$t('settings.pdf.pdf_configuration')"
|
||||
:description="$t('settings.pdf.section_description')"
|
||||
>
|
||||
<div v-if="pdfDriverStore && pdfDriverStore.pdfDriverConfig" class="mt-14">
|
||||
<component
|
||||
:is="pdfDriver"
|
||||
:config-data="pdfDriverStore.pdfDriverConfig"
|
||||
:is-saving="isSaving"
|
||||
:drivers="pdfDriverStore.pdf_drivers"
|
||||
:is-fetching-initial-data="isFetchingInitialData"
|
||||
@on-change-driver="(val) => changeDriver(val)"
|
||||
@submit-data="saveConfig"
|
||||
>
|
||||
</component>
|
||||
</div>
|
||||
</BaseSettingCard>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import GotenbergDriver from '@/scripts/admin/views/settings/pdf-driver/GotenbergDriver.vue';
|
||||
import DomPDFDriver from '@/scripts/admin/views/settings/pdf-driver/DomPDFDriver.vue';
|
||||
import { ref, computed } from 'vue'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { usePDFDriverStore } from '@/scripts/admin/stores/pdf-driver'
|
||||
const emit = defineEmits(['submit-data', 'on-change-driver'])
|
||||
|
||||
let isFetchingInitialData = ref(false)
|
||||
let isSaving = ref(false)
|
||||
|
||||
const pdfDriverStore = usePDFDriverStore();
|
||||
const { t } = useI18n();
|
||||
|
||||
function changeDriver(value) {
|
||||
pdfDriverStore.pdf_driver = value
|
||||
pdfDriverStore.pdfDriverConfig.pdf_driver = value
|
||||
}
|
||||
|
||||
async function loadData() {
|
||||
isFetchingInitialData.value = true
|
||||
await Promise.all([
|
||||
pdfDriverStore.fetchDrivers(),
|
||||
pdfDriverStore.fetchConfig(),
|
||||
])
|
||||
isFetchingInitialData.value = false
|
||||
}
|
||||
loadData();
|
||||
|
||||
async function saveConfig(value) {
|
||||
try {
|
||||
isSaving.value = true
|
||||
await pdfDriverStore.updateConfig(value)
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
} finally {
|
||||
isSaving.value = false
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
const pdfDriver = computed(() => {
|
||||
switch (pdfDriverStore.pdf_driver) {
|
||||
case 'dompdf':
|
||||
return DomPDFDriver
|
||||
case 'gotenberg':
|
||||
return GotenbergDriver
|
||||
default:
|
||||
return DomPDFDriver
|
||||
}
|
||||
})
|
||||
</script>
|
||||
@@ -143,7 +143,7 @@
|
||||
class="mt-6"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('settings.company_info.save') }}
|
||||
</BaseButton>
|
||||
@@ -183,7 +183,7 @@
|
||||
class="mt-6"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon name="SaveIcon" :class="slotProps.class" />
|
||||
<BaseIcon name="ArrowDownOnSquareIcon" :class="slotProps.class" />
|
||||
</template>
|
||||
{{ $t('general.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -20,7 +20,20 @@
|
||||
:data="fetchData"
|
||||
:columns="taxTypeColumns"
|
||||
>
|
||||
<template #cell-percent="{ row }"> {{ row.data.percent }} % </template>
|
||||
<template #cell-calculation_type="{ row }">
|
||||
{{ $t(`settings.tax_types.${row.data.calculation_type}`) }}
|
||||
</template>
|
||||
<template #cell-amount="{ row }">
|
||||
<template v-if="row.data.calculation_type === 'percentage'">
|
||||
{{ row.data.percent }} %
|
||||
</template>
|
||||
<template v-else-if="row.data.calculation_type === 'fixed'">
|
||||
<BaseFormatMoney :amount="row.data.fixed_amount" :currency="defaultCurrency" />
|
||||
</template>
|
||||
<template v-else>
|
||||
-
|
||||
</template>
|
||||
</template>
|
||||
|
||||
<template v-if="hasAtleastOneAbility()" #cell-actions="{ row }">
|
||||
<TaxTypeDropdown
|
||||
@@ -70,9 +83,9 @@ const taxTypeStore = useTaxTypeStore()
|
||||
const modalStore = useModalStore()
|
||||
const userStore = useUserStore()
|
||||
const moduleStore = useModuleStore()
|
||||
|
||||
const table = ref(null)
|
||||
const taxPerItemSetting = ref(companyStore.selectedCompanySettings.tax_per_item)
|
||||
const defaultCurrency = computed(() => companyStore.selectedCompanyCurrency)
|
||||
|
||||
const taxTypeColumns = computed(() => {
|
||||
return [
|
||||
@@ -83,8 +96,14 @@ const taxTypeColumns = computed(() => {
|
||||
tdClass: 'font-medium text-gray-900',
|
||||
},
|
||||
{
|
||||
key: 'percent',
|
||||
label: t('settings.tax_types.percent'),
|
||||
key: 'calculation_type',
|
||||
label: t('settings.tax_types.calculation_type'),
|
||||
thClass: 'extra',
|
||||
tdClass: 'font-medium text-gray-900',
|
||||
},
|
||||
{
|
||||
key: 'amount',
|
||||
label: t('settings.tax_types.amount'),
|
||||
thClass: 'extra',
|
||||
tdClass: 'font-medium text-gray-900',
|
||||
},
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
{{ $t('general.remove') }}
|
||||
<template #left="slotProps">
|
||||
<BaseIcon
|
||||
name="XIcon"
|
||||
name="XMarkIcon"
|
||||
class="!sm:m-0"
|
||||
:class="slotProps.class"
|
||||
/>
|
||||
@@ -189,7 +189,7 @@
|
||||
@click="submitForm"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="SaveIcon" />
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="ArrowDownOnSquareIcon" />
|
||||
</template>
|
||||
{{ $t('settings.customization.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="SaveIcon" />
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="ArrowDownOnSquareIcon" />
|
||||
</template>
|
||||
{{ $t('settings.customization.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="SaveIcon" />
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="ArrowDownOnSquareIcon" />
|
||||
</template>
|
||||
{{ $t('settings.customization.save') }}
|
||||
</BaseButton>
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
class="mt-4"
|
||||
>
|
||||
<template #left="slotProps">
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="SaveIcon" />
|
||||
<BaseIcon v-if="!isSaving" :class="slotProps.class" name="ArrowDownOnSquareIcon" />
|
||||
</template>
|
||||
{{ $t('settings.customization.save') }}
|
||||
</BaseButton>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user