Ir al contenido
Odoo Menú
  • Iniciar sesión
  • Pruébalo gratis
  • Aplicaciones
    Finanzas
    • Contabilidad
    • Facturación
    • Gastos
    • Hoja de cálculo (BI)
    • Documentos
    • Firma electrónica
    Ventas
    • CRM
    • Ventas
    • PdV para tiendas
    • PdV para restaurantes
    • Suscripciones
    • Alquiler
    Sitios web
    • Creador de sitios web
    • Comercio electrónico
    • Blog
    • Foro
    • Chat en vivo
    • eLearning
    Cadena de suministro
    • Inventario
    • Manufactura
    • PLM
    • Compras
    • Mantenimiento
    • Calidad
    Recursos humanos
    • Empleados
    • Reclutamiento
    • Vacaciones
    • Evaluaciones
    • Referencias
    • Flotilla
    Marketing
    • Redes sociales
    • Marketing por correo
    • Marketing por SMS
    • Eventos
    • Automatización de marketing
    • Encuestas
    Servicios
    • Proyectos
    • Registro de horas
    • Servicio externo
    • Soporte al cliente
    • Planeación
    • Citas
    Productividad
    • Conversaciones
    • Aprobaciones
    • IoT
    • VoIP
    • Artículos
    • WhatsApp
    Aplicaciones externas Studio de Odoo Plataforma de Odoo en la nube
  • Industrias
    Venta minorista
    • Librería
    • Tienda de ropa
    • Mueblería
    • Tienda de abarrotes
    • Ferretería
    • Juguetería
    Alimentos y hospitalidad
    • Bar y pub
    • Restaurante
    • Comida rápida
    • Casa de huéspedes
    • Distribuidora de bebidas
    • Hotel
    Bienes inmuebles
    • Agencia inmobiliaria
    • Estudio de arquitectura
    • Construcción
    • Gestión de bienes inmuebles
    • Jardinería
    • Asociación de propietarios
    Consultoría
    • Firma contable
    • Partner de Odoo
    • Agencia de marketing
    • Bufete de abogados
    • Adquisición de talentos
    • Auditorías y certificaciones
    Manufactura
    • Textil
    • Metal
    • Muebles
    • Comida
    • Cervecería
    • Regalos corporativos
    Salud y ejercicio
    • Club deportivo
    • Óptica
    • Gimnasio
    • Especialistas en bienestar
    • Farmacia
    • Peluquería
    Trades
    • Personal de mantenimiento
    • Hardware y soporte de TI
    • Sistemas de energía solar
    • Zapateros y fabricantes de calzado
    • Servicios de limpieza
    • Servicios de calefacción, ventilación y aire acondicionado
    Otros
    • Organización sin fines de lucro
    • Agencia para la protección del medio ambiente
    • Alquiler de anuncios publicitarios
    • Fotografía
    • Alquiler de bicicletas
    • Distribuidor de software
    Descubre todas las industrias
  • Odoo Community
    Aprende
    • Tutoriales
    • Documentación
    • Certificaciones
    • Capacitación
    • Blog
    • Podcast
    Fortalece la educación
    • Programa educativo
    • Scale Up! El juego empresarial
    • Visita Odoo
    Obtén el software
    • Descargar
    • Compara ediciones
    • Versiones
    Colabora
    • GitHub
    • Foro
    • Eventos
    • Traducciones
    • Conviértete en partner
    • Servicios para partners
    • Registra tu firma contable
    Obtén servicios
    • Encuentra un partner
    • Encuentra un contador
    • Contacta a un consultor
    • Servicios de implementación
    • Referencias de clientes
    • Soporte
    • Actualizaciones
    GitHub YouTube Twitter LinkedIn Instagram Facebook Spotify
    +1 (650) 691-3277
    Solicita una demostración
  • Precios
  • Ayuda

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Contabilidad
  • Inventario
  • PoS
  • Proyectos
  • MRP
All apps
Debe estar registrado para interactuar con la comunidad.
Todas las publicaciones Personas Insignias
Etiquetas (Ver todo)
odoo accounting v14 pos v15
Acerca de este foro
Debe estar registrado para interactuar con la comunidad.
Todas las publicaciones Personas Insignias
Etiquetas (Ver todo)
odoo accounting v14 pos v15
Acerca de este foro
Ayuda

How to allow external keyboard entry in Point of Sales popupwidget?

Suscribirse

Reciba una notificación cuando haya actividad en esta publicación

Se marcó esta pregunta
javascriptposkeyboardpoint_of_salev9
5813 Vistas
Avatar
Pieter Paulussen

I'm having some problems with allowing the user to enter text with an EXTERNAL keyboard in a point of sale 'textinput' popupwidget. Everything works in the background (orders get registered etc.) but it looks to me like the keys are not registering to the correct view. 

The general idea is this: I want to ask the user of the point of the sale for the customer zip code. The process starts when the 'pay' button is clicked in the ActionpadWidget. The view passes to the Paymentscreenwidget. He then enters the zip code using the 'number' popup widget. (BTW: it's not possible here either to work with the numpad part of the external keyboard)

 When the zip code is not yet present in the database the user should be asked for the city name. That needs to be entered into the 'textinput' widget. However typing text is entered to the textfield. It is possible however copy paste text to the field and from there on everything works fine. 

The javascript code I have a the moment:

QUESTION: How do I get the external keyboard entry to the correct field?

screens.ActionpadWidget.include({
/**
* When the button 'pay' is clicked and the postcode of the customer should be tracked -> show popup.
* When a customer is selected, no popup will be shown and the customer data will be used to register zipcode.
* Unless the zip code in the customer field is unknown. Then a popup will be shown
*/
renderElement: function(){
var self = this;
this._super();
var track_postal_codes = self.pos.config.postal_code_tracking;
this.$('.pay').click(function(){
var postal_codes = self.pos.postal_codes_by_id;
if (track_postal_codes == true) {
console.log(self.pos.get_order().attributes.client);
if (self.pos.get_order().attributes.client){
var client = self.pos.get_order().attributes.client;
if (client.zip == "" || client.city == "") {
self.pos.gui.show_popup('number', {
title: _t('Enter Customer Postal Code'),
value: _t('0'),
confirm: function (new_postal_code) {
if (postal_codes.hasOwnProperty(new_postal_code.toString())) {
self.pos.get_order().set_postal_code(new_postal_code);
} else {
this.pos.gui.show_popup('textinput', {
title: _t('Enter City Name'),
value: _t("New City Name"),
confirm: function (new_city_name) {
self.pos.get_order().set_postal_code(new_postal_code);
self.pos.get_order().set_city_name(new_city_name);
self.pos.postal_codes_by_id[new_postal_code] = new_city_name;
}
});
}
}
});
} else {
if (postal_codes.hasOwnProperty(client.zip.toString())) {
self.pos.get_order().set_postal_code(client.zip);
self.pos.get_order().set_city_name(client.city);
} else {
self.pos.get_order().set_postal_code(client.zip);
self.pos.get_order().set_city_name(client.city);
self.pos.postal_codes_by_id[client.zip] = client.city;
}
}
} else {
self.pos.gui.show_popup('number', {
title: _t('Enter Customer Postal Code'),
value: _t('0'),
confirm: function (new_postal_code) {
if (postal_codes.hasOwnProperty(new_postal_code.toString())) {
self.pos.get_order().set_postal_code(new_postal_code);
} else {
this.pos.gui.show_popup('textinput', {
title: _t('Enter City Name'),
value: _t("New City Name"),
confirm: function (new_city_name) {
console.log(new_city_name);
self.pos.get_order().set_postal_code(new_postal_code);
self.pos.get_order().set_city_name(new_city_name);
self.pos.postal_codes_by_id[new_postal_code] = new_city_name;
}
});
}
}
});
}
}
});
}
});


2
Avatar
Descartar
¿Le interesa esta conversación? ¡Participe en ella!

Cree una cuenta para poder utilizar funciones exclusivas e interactuar con la comunidad.

Registrarse
Publicaciones relacionadas Respuestas Vistas Actividad
Step by step guidelines to accept credit card payments in Odoo POS Resuelto
creditcard pos point_of_sale v9
Avatar
1
abr 23
27036
Point of sale override TicketScreen method
javascript pos override point_of_sale
Avatar
0
nov 22
3655
How to set drop-down list for customers in point of sale interface Resuelto
javascript pos customer point_of_sale
Avatar
Avatar
1
oct 22
6633
Uncaught (in promise) TypeError: this._rpc(...).then(...).fail is not a function Resuelto
javascript pos point_of_sale odoo13.0
Avatar
Avatar
Avatar
2
jul 22
21261
Point of sale image src call javaScript variable
javascript pos point_of_sale odoo11
Avatar
0
mar 19
4099
Comunidad
  • Tutoriales
  • Documentación
  • Foro
Código abierto
  • Descargar
  • GitHub
  • Runbot
  • Traducciones
Servicios
  • Alojamiento en Odoo.sh
  • Soporte
  • Actualizaciones del software
  • Desarrollos personalizados
  • Educación
  • Encuentra un contador
  • Encuentra un partner
  • Conviértete en partner
Sobre nosotros
  • Nuestra empresa
  • Activos de marca
  • Contáctanos
  • Empleos
  • Eventos
  • Podcast
  • Blog
  • Clientes
  • Legal • Privacidad
  • Seguridad
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo es un conjunto de aplicaciones de código abierto que cubren todas las necesidades de tu empresa: CRM, comercio electrónico, contabilidad, inventario, punto de venta, gestión de proyectos, etc.

La propuesta única de valor de Odoo es ser muy fácil de usar y estar totalmente integrado.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now