diff --git a/src/components/RegularizeStockForm.vue b/src/components/RegularizeStockForm.vue new file mode 100644 index 000000000..28236be17 --- /dev/null +++ b/src/components/RegularizeStockForm.vue @@ -0,0 +1,81 @@ + + + + (warehousesOptions = data)" + auto-load + /> + + + + + + + + + + + + + + + + + +es: + Warehouse: Almacén + Type the visible quantity: Introduce la cantidad visible + Regularize stock: Regularizar stock + diff --git a/src/composables/useState.js b/src/composables/useState.js index 1c797e992..6ad8eb22c 100644 --- a/src/composables/useState.js +++ b/src/composables/useState.js @@ -25,6 +25,7 @@ export function useState() { lang: user.value.lang, darkMode: user.value.darkMode, companyFk: user.value.companyFk, + warehouseFk: user.value.warehouseFk, }; }); } @@ -37,6 +38,7 @@ export function useState() { lang: data.lang, darkMode: data.darkMode, companyFk: data.companyFk, + warehouseFk: data.warehouseFk, }; } diff --git a/src/composables/useUserConfig.js b/src/composables/useUserConfig.js index e05d7fb5c..a33779be7 100644 --- a/src/composables/useUserConfig.js +++ b/src/composables/useUserConfig.js @@ -12,6 +12,7 @@ export function useUserConfig() { const user = state.getUser().value; user.darkMode = data.darkMode; user.companyFk = data.companyFk; + user.warehouseFk = data.warehouseFk; state.setUser(user); return data; diff --git a/src/i18n/en/index.js b/src/i18n/en/index.js index 1a7a4c27e..ea8769c58 100644 --- a/src/i18n/en/index.js +++ b/src/i18n/en/index.js @@ -1060,6 +1060,25 @@ export default { totalEntries: 'Total entries', }, }, + item: { + pageTitles: { + items: 'Items', + list: 'List', + diary: 'Diary', + tags: 'Tags', + }, + descriptor: { + item: 'Item', + buyer: 'Buyer', + color: 'Color', + category: 'Category', + stems: 'Stems', + visible: 'Visible', + available: 'Available', + warehouseText: 'Calculated on the warehouse of { warehouseName }', + itemDiary: 'Item diary', + }, + }, components: { topbar: {}, userPanel: { diff --git a/src/i18n/es/index.js b/src/i18n/es/index.js index 83de42ee0..9f407ab0b 100644 --- a/src/i18n/es/index.js +++ b/src/i18n/es/index.js @@ -1060,6 +1060,25 @@ export default { totalEntries: 'Ent. totales', }, }, + item: { + pageTitles: { + items: 'Artículos', + list: 'Listado', + diary: 'Histórico', + tags: 'Etiquetas', + }, + descriptor: { + item: 'Artículo', + buyer: 'Comprador', + color: 'Color', + category: 'Categoría', + stems: 'Tallos', + visible: 'Visible', + available: 'Disponible', + warehouseText: 'Calculado sobre el almacén de { warehouseName }', + itemDiary: 'Registro de compra-venta', + }, + }, components: { topbar: {}, userPanel: { diff --git a/src/pages/Item/Card/ItemCard.vue b/src/pages/Item/Card/ItemCard.vue new file mode 100644 index 000000000..57c3a434d --- /dev/null +++ b/src/pages/Item/Card/ItemCard.vue @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + diff --git a/src/pages/Item/Card/ItemDescriptor.vue b/src/pages/Item/Card/ItemDescriptor.vue new file mode 100644 index 000000000..e5183779b --- /dev/null +++ b/src/pages/Item/Card/ItemDescriptor.vue @@ -0,0 +1,260 @@ + + + + { + item = data; + setData(data); + } + " + > + + + + {{ t('Regularize stock') }} + + + + + + + + {{ t('Clone') }} + + + + + + + + + + + + + {{ t('item.descriptor.item') }} + + + + + + + + + {{ t('item.descriptor.visible') }} + + {{ visible }} + + + + {{ t('item.descriptor.available') }} + + {{ available }} + + + + {{ warehouseText }} + + + + + + + + + {{ t('item.descriptor.buyer') }} + + + + + + + + + + + + {{ t('item.descriptor.itemDiary') }} + + + + + + + +es: + Regularize stock: Regularizar stock + Clone: Clonar + All it's properties will be copied: Todas sus propiedades serán copiadas + Do you want to clone this item?: ¿Desea clonar este artículo? + + + diff --git a/src/pages/Item/Card/ItemDescriptorProxy.vue b/src/pages/Item/Card/ItemDescriptorProxy.vue new file mode 100644 index 000000000..58471dc83 --- /dev/null +++ b/src/pages/Item/Card/ItemDescriptorProxy.vue @@ -0,0 +1,26 @@ + + + + + + + diff --git a/src/pages/Item/Card/ItemDiary.vue b/src/pages/Item/Card/ItemDiary.vue new file mode 100644 index 000000000..21249349f --- /dev/null +++ b/src/pages/Item/Card/ItemDiary.vue @@ -0,0 +1 @@ +Item diary (CREAR CUANDO SE DESARROLLE EL MODULO DE ITEMS) diff --git a/src/pages/Item/Card/ItemSummary.vue b/src/pages/Item/Card/ItemSummary.vue new file mode 100644 index 000000000..567fbf32b --- /dev/null +++ b/src/pages/Item/Card/ItemSummary.vue @@ -0,0 +1 @@ +Item summary diff --git a/src/pages/Item/Card/ItemSummaryDialog.vue b/src/pages/Item/Card/ItemSummaryDialog.vue new file mode 100644 index 000000000..4af617fd9 --- /dev/null +++ b/src/pages/Item/Card/ItemSummaryDialog.vue @@ -0,0 +1,5 @@ + + Item summary dialog (A DESARROLLAR CUANDO SE CREE EL MODULO DE ITEMS) + diff --git a/src/pages/Item/Card/ItemTags.vue b/src/pages/Item/Card/ItemTags.vue new file mode 100644 index 000000000..95f4380e4 --- /dev/null +++ b/src/pages/Item/Card/ItemTags.vue @@ -0,0 +1 @@ +Item tags (CREAR CUANDO SE DESARROLLE EL MODULO DE ITEMS) diff --git a/src/pages/Item/ItemList.vue b/src/pages/Item/ItemList.vue new file mode 100644 index 000000000..49a5dbb64 --- /dev/null +++ b/src/pages/Item/ItemList.vue @@ -0,0 +1 @@ +Item list diff --git a/src/pages/Item/ItemMain.vue b/src/pages/Item/ItemMain.vue new file mode 100644 index 000000000..c1f2a31db --- /dev/null +++ b/src/pages/Item/ItemMain.vue @@ -0,0 +1,18 @@ + + + + + + + + + + + + diff --git a/src/pages/Supplier/Card/SupplierConsumption.vue b/src/pages/Supplier/Card/SupplierConsumption.vue index 7baa8ded5..06438349b 100644 --- a/src/pages/Supplier/Card/SupplierConsumption.vue +++ b/src/pages/Supplier/Card/SupplierConsumption.vue @@ -7,6 +7,7 @@ import { useQuasar } from 'quasar'; import FetchedTags from 'components/ui/FetchedTags.vue'; import SendEmailDialog from 'components/common/SendEmailDialog.vue'; import SupplierConsumptionFilter from './SupplierConsumptionFilter.vue'; +import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue'; import { toDate } from 'src/filters'; import { dashIfEmpty } from 'src/filters'; @@ -174,7 +175,10 @@ onMounted(async () => { {{ row.invoiceNumber }} - {{ buy.itemName }} + + {{ buy.itemName }} + + {{ buy.subName }} diff --git a/src/router/modules/index.js b/src/router/modules/index.js index cc5034959..84a26798d 100644 --- a/src/router/modules/index.js +++ b/src/router/modules/index.js @@ -1,3 +1,4 @@ +import Item from './item'; import Customer from './customer'; import Ticket from './ticket'; import Claim from './claim'; @@ -14,6 +15,7 @@ import Department from './department'; import Entry from './entry'; export default [ + Item, Customer, Ticket, Claim, diff --git a/src/router/modules/item.js b/src/router/modules/item.js new file mode 100644 index 000000000..d3462e15c --- /dev/null +++ b/src/router/modules/item.js @@ -0,0 +1,70 @@ +import { RouterView } from 'vue-router'; + +export default { + path: '/item', + name: 'Item', + meta: { + title: 'items', + icon: 'vn:item', + }, + component: RouterView, + redirect: { name: 'ItemMain' }, + menus: { + main: [], + card: [], + }, + children: [ + { + path: '', + name: 'ItemMain', + component: () => import('src/pages/Item/ItemMain.vue'), + redirect: { name: 'Itemlist' }, + children: [ + { + path: 'list', + name: 'ItemList', + meta: { + title: 'list', + icon: 'view_list', + }, + component: () => import('src/pages/Item/ItemList.vue'), + }, + ], + }, + { + name: 'ItemCard', + path: ':id', + component: () => import('src/pages/Item/Card/ItemCard.vue'), + redirect: { name: 'ItemSummary' }, + children: [ + { + name: 'ItemSummary', + path: 'summary', + meta: { + title: 'summary', + icon: 'launch', + }, + component: () => import('src/pages/Item/Card/ItemSummary.vue'), + }, + { + path: 'diary', + name: 'ItemDiary', + meta: { + title: 'diary', + icon: 'vn:transaction', + }, + component: () => import('src/pages/Item/Card/ItemDiary.vue'), + }, + { + path: 'tags', + name: 'ItemTags', + meta: { + title: 'Tags', + icon: 'vn:tags', + }, + component: () => import('src/pages/Item/Card/ItemTags.vue'), + }, + ], + }, + ], +}; diff --git a/src/router/routes.js b/src/router/routes.js index 6a2fa6a97..d1027955f 100644 --- a/src/router/routes.js +++ b/src/router/routes.js @@ -1,3 +1,4 @@ +import item from './modules/item'; import customer from './modules/customer'; import ticket from './modules/ticket'; import claim from './modules/claim'; @@ -51,6 +52,7 @@ const routes = [ component: () => import('../pages/Dashboard/DashboardMain.vue'), }, // Module routes + item, customer, ticket, claim, diff --git a/src/stores/useNavigationStore.js b/src/stores/useNavigationStore.js index 2eda6f686..568063d1d 100644 --- a/src/stores/useNavigationStore.js +++ b/src/stores/useNavigationStore.js @@ -7,19 +7,19 @@ import routes from 'src/router/modules'; export const useNavigationStore = defineStore('navigationStore', () => { const modules = [ - 'customer', - 'claim', - 'ticket', - 'invoiceOut', - 'invoiceIn', - 'worker', 'shelving', 'order', - 'wagon', - 'route', - 'supplier', - 'travel', + 'customer', 'entry', + 'travel', + 'invoiceOut', + 'invoiceIn', + 'supplier', + 'claim', + 'route', + 'ticket', + 'worker', + 'wagon', ]; const pinnedModules = ref([]); const role = useRole();