Scontistica- Parte 1
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
fab
|
||||
color="primary"
|
||||
icon="fas fa-info"
|
||||
class="absolute"
|
||||
class="absolute semi-transparent"
|
||||
style="top: 0; right: 12px; transform: translateY(-50%)"
|
||||
:to="`/product/` + myproduct.code"
|
||||
/>
|
||||
|
||||
@@ -36,6 +36,7 @@ const msg_website_it = {
|
||||
categories: 'Categorie',
|
||||
storehouses: 'Magazzino',
|
||||
providers: 'Fornitori',
|
||||
scontisticas: 'Scontistica',
|
||||
departments: 'Uffici',
|
||||
orders: 'Ordini Ricevuti',
|
||||
orders2: 'Ordini Ricevuti',
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { IAction } from '@src/model/Projects'
|
||||
import { IFriends, IGroupShort, IMyGroup, IPaymentType } from '@src/model/UserStore'
|
||||
import {
|
||||
IDepartment, IProducer, IShareWithUs, IStorehouse, IProvider, ICategory
|
||||
IDepartment, IProducer, IShareWithUs, IStorehouse, IProvider, IScontistica, ICategory
|
||||
} from '@src/model/Products'
|
||||
|
||||
import { IUserFields, IUserProfile } from '@src/model/UserStore'
|
||||
@@ -440,6 +440,7 @@ export interface IGlobalState {
|
||||
calzoom: ICalZoom[],
|
||||
producers: IProducer[],
|
||||
providers: IProvider[],
|
||||
scontisticas: IScontistica[],
|
||||
storehouses: IStorehouse[],
|
||||
departments: IDepartment[],
|
||||
categories: ICategory[],
|
||||
|
||||
@@ -121,6 +121,17 @@ export interface IProvider {
|
||||
website?: string,
|
||||
}
|
||||
|
||||
export interface IScontistica {
|
||||
_id?: any
|
||||
idapp?: string
|
||||
code?: string,
|
||||
description?: string,
|
||||
qta: number,
|
||||
perc_sconto: number,
|
||||
price: number,
|
||||
comulativo: boolean,
|
||||
}
|
||||
|
||||
export interface ICart {
|
||||
_id?: any
|
||||
idapp?: string
|
||||
|
||||
0
src/rootgen/admin/scontistica/scontistica.scss
Executable file
0
src/rootgen/admin/scontistica/scontistica.scss
Executable file
24
src/rootgen/admin/scontistica/scontistica.ts
Executable file
24
src/rootgen/admin/scontistica/scontistica.ts
Executable file
@@ -0,0 +1,24 @@
|
||||
import { defineComponent } from 'vue'
|
||||
|
||||
import { CImgText } from '../../../components/CImgText/index'
|
||||
import { CCard } from '../../../components/CCard'
|
||||
import { CMyPage } from '../../../components/CMyPage'
|
||||
import { CTitleBanner } from '../../../components/CTitleBanner'
|
||||
import { CGridTableRec } from '../../../components/CGridTableRec'
|
||||
|
||||
import { colTableScontistica } from '../../../store/Modules/fieldsTable'
|
||||
import MixinMetaTags from '../../../mixins/mixin-metatags'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'scontistica',
|
||||
components: { CImgText, CCard, CMyPage, CTitleBanner, CGridTableRec },
|
||||
setup() {
|
||||
|
||||
const { setmeta } = MixinMetaTags()
|
||||
|
||||
return {
|
||||
colTableScontistica,
|
||||
setmeta,
|
||||
}
|
||||
}
|
||||
})
|
||||
31
src/rootgen/admin/scontistica/scontistica.vue
Executable file
31
src/rootgen/admin/scontistica/scontistica.vue
Executable file
@@ -0,0 +1,31 @@
|
||||
<template>
|
||||
<CMyPage title="Scontistica" imgbackground="images/produttori.jpg" sizes="max-height: 120px">
|
||||
<span>{{
|
||||
setmeta({
|
||||
title: 'Scontistica',
|
||||
description: '',
|
||||
keywords: '',
|
||||
})
|
||||
}}
|
||||
</span>
|
||||
|
||||
<div class="q-ma-sm q-gutter-sm q-pa-xs">
|
||||
<CTitleBanner title="Scontistica"></CTitleBanner>
|
||||
<CGridTableRec
|
||||
prop_mytable="scontisticas"
|
||||
prop_mytitle="Lista Scontistica"
|
||||
:prop_mycolumns="colTableScontistica"
|
||||
prop_colkey="code"
|
||||
nodataLabel="Nessuna Scontistica"
|
||||
noresultLabel="Il filtro selezionato non ha trovato nessun risultato">
|
||||
|
||||
</CGridTableRec>
|
||||
</div>
|
||||
</CMyPage>
|
||||
</template>
|
||||
<script lang="ts" src="./scontistica.ts">
|
||||
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
@import 'scontistica.scss';
|
||||
</style>
|
||||
@@ -125,6 +125,20 @@ function getRoutesEcomm(site: ISites) {
|
||||
onlyManager: true,
|
||||
onlyEditor: true
|
||||
},
|
||||
{
|
||||
active: true,
|
||||
order: 30,
|
||||
path: '/admin/ecommerce/scontistica',
|
||||
materialIcon: 'fas fa-gift',
|
||||
name: 'pages.scontisticas',
|
||||
component: () => import('@/rootgen/admin/scontistica/scontistica.vue'),
|
||||
inmenu: true,
|
||||
submenu: true,
|
||||
level_parent: 0,
|
||||
level_child: 0.5,
|
||||
onlyManager: true,
|
||||
onlyEditor: true
|
||||
},
|
||||
{
|
||||
active: true,
|
||||
order: 31,
|
||||
@@ -205,6 +219,14 @@ function getRoutesEcomm(site: ISites) {
|
||||
component: () => import('@/rootgen/admin/providers/providers.vue'),
|
||||
infooter: false,
|
||||
},
|
||||
{
|
||||
active: true,
|
||||
order: 32,
|
||||
path: '/admin/ecommerce/scontistica',
|
||||
name: 'pages.scontisticas',
|
||||
component: () => import('@/rootgen/admin/scontistica/scontistica.vue'),
|
||||
infooter: false,
|
||||
},
|
||||
{
|
||||
active: true,
|
||||
order: 32,
|
||||
|
||||
@@ -84,6 +84,15 @@ const msg_it = {
|
||||
providers: {
|
||||
name: 'Fornitori',
|
||||
},
|
||||
scontistica: {
|
||||
name: 'scontistica',
|
||||
code: 'Codice',
|
||||
description: 'Descrizione',
|
||||
perc_sconto: 'Sconto %',
|
||||
price: 'Prezzo',
|
||||
qta: 'Quantita',
|
||||
comulativo: 'Cumulativo',
|
||||
},
|
||||
otherpages: {
|
||||
myactivities: 'Attività',
|
||||
myactivities2: 'Mie Attività',
|
||||
|
||||
@@ -442,6 +442,16 @@ export const colTableProviders = [
|
||||
AddCol(DeleteRec),
|
||||
AddCol(DuplicateRec),
|
||||
]
|
||||
export const colTableScontistica = [
|
||||
AddCol({ name: 'code', label_trans: 'scontistica.code' }),
|
||||
AddCol({ name: 'description', label_trans: 'scontistica.description' }),
|
||||
AddCol({ name: 'qta', label_trans: 'scontistica.qta', fieldtype: costanti.FieldType.number }),
|
||||
AddCol({ name: 'perc_sconto', label_trans: 'scontistica.perc_sconto', fieldtype: costanti.FieldType.number }),
|
||||
AddCol({ name: 'price', label_trans: 'products.price', fieldtype: costanti.FieldType.number }),
|
||||
AddCol({ name: 'comulativo', label_trans: 'products.comulativo', fieldtype: costanti.FieldType.boolean }),
|
||||
AddCol(DeleteRec),
|
||||
AddCol(DuplicateRec),
|
||||
]
|
||||
|
||||
export const colAdType = [
|
||||
AddCol({ name: '_id', label_trans: 'index', fieldtype: costanti.FieldType.number }),
|
||||
@@ -1959,6 +1969,12 @@ export const colTableProducts = [
|
||||
fieldtype: costanti.FieldType.select,
|
||||
jointable: 'providers',
|
||||
}),
|
||||
AddCol({
|
||||
name: 'idScontisticas',
|
||||
label_trans: 'scontistica.name',
|
||||
fieldtype: costanti.FieldType.multiselect,
|
||||
jointable: 'scontisticas',
|
||||
}),
|
||||
AddCol({
|
||||
name: 'department',
|
||||
label_trans: 'products.department',
|
||||
@@ -3545,6 +3561,13 @@ export const fieldsTable = {
|
||||
colkey: '_id',
|
||||
collabel: 'name',
|
||||
},
|
||||
{
|
||||
value: 'scontisticas',
|
||||
label: 'Scontistica',
|
||||
columns: colTableScontistica,
|
||||
colkey: '_id',
|
||||
collabel: 'code',
|
||||
},
|
||||
{
|
||||
value: 'sharewithus',
|
||||
label: 'Condividi con Noi',
|
||||
|
||||
@@ -121,6 +121,7 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
workers: [],
|
||||
storehouses: [],
|
||||
providers: [],
|
||||
scontisticas: [],
|
||||
departments: [],
|
||||
categories: [],
|
||||
sharewithus: [],
|
||||
@@ -308,6 +309,7 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
else if (table === 'producers') ris = state.producers
|
||||
else if (table === 'storehouses') ris = state.storehouses
|
||||
else if (table === 'providers') ris = state.providers
|
||||
else if (table === 'scontisticas') ris = state.scontisticas
|
||||
else if (table === 'groups') ris = state.groups
|
||||
else if (table === 'resps') ris = state.resps
|
||||
else if (table === 'workers') ris = state.workers
|
||||
@@ -1535,6 +1537,7 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
this.producers = (res.data.producers) ? [...res.data.producers] : []
|
||||
this.storehouses = (res.data.storehouses) ? [...res.data.storehouses] : []
|
||||
this.providers = (res.data.providers) ? [...res.data.providers] : []
|
||||
this.scontisticas = (res.data.scontisticas) ? [...res.data.scontisticas] : []
|
||||
this.groups = (res.data.groups) ? [...res.data.groups] : []
|
||||
this.resps = (res.data.resps) ? [...res.data.resps] : []
|
||||
this.workers = (res.data.workers) ? [...res.data.workers] : []
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
<template>
|
||||
<q-page>
|
||||
<CTitleBanner :title="$t('ecomm.carrello')"></CTitleBanner>
|
||||
{{ tools.getstrDateTimeShort(mycart.modify_at) }}
|
||||
<q-spinner v-if="!endload" color="primary" size="3em" :thickness="2" />
|
||||
<div v-if="endload">
|
||||
<div v-if="recOrderCart" class="panel">
|
||||
@@ -37,8 +36,6 @@
|
||||
<br />
|
||||
</div>
|
||||
|
||||
recOrderCart.status: {{ recOrderCart.status }}
|
||||
|
||||
<div class="text-center">
|
||||
<q-btn
|
||||
v-if="
|
||||
|
||||
Reference in New Issue
Block a user