1
0
mirror of https://github.com/PanJiaChen/vue-element-admin.git synced 2025-08-13 23:20:12 +08:00

add traduction and icon (#552)

This commit is contained in:
Elsio Sanchez 2020-12-02 12:34:15 -04:00 committed by GitHub
parent 053a250b21
commit 2802e06030
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 12 additions and 8 deletions

View File

@ -56,11 +56,13 @@ export default {
} }
} }
}, },
beforeMount() {
this.$store.dispatch('listPointOfSalesFromServer')
},
methods: { methods: {
formatPrice, formatPrice,
formatQuantity, formatQuantity,
shortcutKeyMethod(event) { shortcutKeyMethod(event) {
console.log(event)
switch (event.srcKey) { switch (event.srcKey) {
case 'refreshList': case 'refreshList':
case 'refreshList2': case 'refreshList2':
@ -74,7 +76,6 @@ export default {
callBack([]) callBack([])
return return
} }
console.log(stringToMatch, callBack)
let results = this.listWithPrice let results = this.listWithPrice
if (stringToMatch) { if (stringToMatch) {
@ -96,8 +97,6 @@ export default {
// Remote search // Remote search
if (this.isEmptyValue(results) && String(stringToMatch.length > 3)) { if (this.isEmptyValue(results) && String(stringToMatch.length > 3)) {
clearTimeout(this.timeOut) clearTimeout(this.timeOut)
const epa = this.$store.getters.getSearchProduct
console.log({ epa })
this.timeOut = setTimeout(() => { this.timeOut = setTimeout(() => {
this.$store.dispatch('listProductPriceFromServerProductInfo', { this.$store.dispatch('listProductPriceFromServerProductInfo', {
containerUuid: 'Products-Price-List-ProductInfo', containerUuid: 'Products-Price-List-ProductInfo',

View File

@ -166,7 +166,6 @@ export default {
} }
}, },
created() { created() {
this.$store.dispatch('listPointOfSalesFromServer')
this.unsubscribe = this.subscribeChanges() this.unsubscribe = this.subscribeChanges()
if (this.isReadyFromGetData) { if (this.isReadyFromGetData) {

View File

@ -11,6 +11,7 @@ export default {
page404: '404', page404: '404',
profile: 'Profile', profile: 'Profile',
ProcessActivity: 'Process Logs', ProcessActivity: 'Process Logs',
ProductInfo: 'Product Information',
role: 'Role', role: 'Role',
organization: 'Organization', organization: 'Organization',
warehouse: 'Warehouse', warehouse: 'Warehouse',
@ -48,7 +49,8 @@ export default {
invalidEmailFormat: 'Invalid email format', invalidEmailFormat: 'Invalid email format',
recordLocked: 'This record has been locked', recordLocked: 'This record has been locked',
recordUnlocked: 'This record has been unlocked', recordUnlocked: 'This record has been unlocked',
noRoleAccess: 'With your current role and settings, you cannot view this information.' noRoleAccess: 'With your current role and settings, you cannot view this information.',
errorPointOfSale: 'No point of sale selected'
}, },
navbar: { navbar: {
badge: { badge: {

View File

@ -11,6 +11,7 @@ export default {
page404: '404', page404: '404',
profile: 'Perfil', profile: 'Perfil',
ProcessActivity: 'Histórico Procesos', ProcessActivity: 'Histórico Procesos',
ProductInfo: 'Informacion de Producto',
role: 'Rol', role: 'Rol',
organization: 'Organización', organization: 'Organización',
warehouse: 'Almacén', warehouse: 'Almacén',
@ -48,7 +49,8 @@ export default {
invalidEmailFormat: 'Formato de correo electronico invalido', invalidEmailFormat: 'Formato de correo electronico invalido',
recordLocked: 'Este registro ha sido bloqueado', recordLocked: 'Este registro ha sido bloqueado',
recordUnlocked: 'Este registro ha sido desbloqueado', recordUnlocked: 'Este registro ha sido desbloqueado',
noRoleAccess: 'Con su rol y configuración actuales, no puede ver esta información.' noRoleAccess: 'Con su rol y configuración actuales, no puede ver esta información.',
errorPointOfSale: 'Sin punto de venta seleccionado'
}, },
navbar: { navbar: {
badge: { badge: {

View File

@ -110,6 +110,7 @@ const staticRoutes = [
name: 'ProductInfo', name: 'ProductInfo',
meta: { meta: {
title: 'ProductInfo', title: 'ProductInfo',
icon: 'search',
isIndex: true isIndex: true
} }
} }

View File

@ -4,6 +4,7 @@ import {
} from '@/api/ADempiere/form/point-of-sales.js' } from '@/api/ADempiere/form/point-of-sales.js'
import { isEmptyValue, extractPagingToken } from '@/utils/ADempiere/valueUtils.js' import { isEmptyValue, extractPagingToken } from '@/utils/ADempiere/valueUtils.js'
import { showMessage } from '@/utils/ADempiere/notification.js' import { showMessage } from '@/utils/ADempiere/notification.js'
import language from '@/lang'
const withoutResponse = { const withoutResponse = {
isLoaded: false, isLoaded: false,
@ -57,7 +58,7 @@ const listProductPrice = {
}) { }) {
const posUuid = rootGetters.getPointOfSalesUuid const posUuid = rootGetters.getPointOfSalesUuid
if (isEmptyValue(posUuid)) { if (isEmptyValue(posUuid)) {
const message = 'Sin punto de venta seleccionado' const message = language.t('notifications.errorPointOfSale')
showMessage({ showMessage({
type: 'info', type: 'info',
message message