New swipWithCard property in parameters.properties, only used in ClientProfile.java for card number field for now

+
* Suppress serial warning
* Better French translation
* replace ShowKeyboardInSaveSale by showKeyboardInSaveSale in Java code

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk/specialpurpose@825444 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jacques Le Roux
2009-10-15 09:19:40 +00:00
parent 05e51c964e
commit d06e2b146c
5 changed files with 16 additions and 12 deletions
+1 -1
View File
@@ -98,7 +98,7 @@
<property key="PosCredNo">
<value xml:lang="en">Enter Card Number:</value>
<value xml:lang="es">Ingrese número de tarjeta :</value>
<value xml:lang="fr">Entrez le n° de la carte :</value>
<value xml:lang="fr">Entrez le n° de carte :</value>
<value xml:lang="it">Inserire Numero Carta:</value>
<value xml:lang="ro">Introduceti Numarul Cartii:</value>
<value xml:lang="zh">输入卡号:</value>
+5 -2
View File
@@ -18,6 +18,9 @@
#
### Miscellaneous parameters
# Used with a touch screen to allow showing vituals keyboards (alpha and keypad).
# Used with a touch screen to allow showing vituals keyboards (alpha and keypad). True by default
# For now this properties is used with both. Maybe at some point we will need both in the same screen.
ShowKeyboardInSaveSale=Y
ShowKeyboardInSaveSale=Y
# Used with MSR to allow to force swiping from card when showKeyboardInSaveSale is also true
# For instance the card number in Client Profile screen. False by default
SwipWithCard=N
@@ -77,7 +77,8 @@ public class ClientProfile extends XPage implements ActionListener {
protected static PosTransaction m_trans = null;
protected String m_type = null;
protected boolean cancelled = false;
private static boolean ShowKeyboardInSaveSale = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "ShowKeyboardInSaveSale", "Y");
private static boolean showKeyboardInSaveSale = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "ShowKeyboardInSaveSale", "Y");
private static boolean swipWithCard = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "SwipWithCard", "N");
private static Locale locale = Locale.getDefault();
private String m_partyId = null;
@@ -160,7 +161,7 @@ public class ClientProfile extends XPage implements ActionListener {
}
public synchronized void editName() {
if (wasMouseClicked() && ShowKeyboardInSaveSale) {
if (wasMouseClicked() && showKeyboardInSaveSale) {
try {
Keyboard keyboard = new Keyboard(m_pos);
keyboard.setText(m_nameEdit.getText());
@@ -174,7 +175,7 @@ public class ClientProfile extends XPage implements ActionListener {
}
public synchronized void editEmail() {
if (wasMouseClicked() && ShowKeyboardInSaveSale) {
if (wasMouseClicked() && showKeyboardInSaveSale) {
try {
Keyboard keyboard = new Keyboard(m_pos);
keyboard.setText(m_emailEdit.getText());
@@ -188,7 +189,7 @@ public class ClientProfile extends XPage implements ActionListener {
}
public synchronized void editPhone() {
if (wasMouseClicked() && ShowKeyboardInSaveSale) {
if (wasMouseClicked() && showKeyboardInSaveSale) {
try {
NumericKeypad numericKeypad = new NumericKeypad(m_pos);
numericKeypad.setMinus(true);
@@ -203,7 +204,7 @@ public class ClientProfile extends XPage implements ActionListener {
}
public synchronized void editCard() {
if (wasMouseClicked() && ShowKeyboardInSaveSale) {
if (wasMouseClicked() && showKeyboardInSaveSale && !swipWithCard) {
try {
NumericKeypad numericKeypad = new NumericKeypad(m_pos);
numericKeypad.setMinus(true);
+2 -2
View File
@@ -65,7 +65,7 @@ public class PaidInOut extends XPage {
protected static PosTransaction m_trans = null;
protected String m_type = null;
protected boolean cancelled = false;
private static boolean ShowKeyboardInSaveSale = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "ShowKeyboardInSaveSale", "Y");
private static boolean showKeyboardInSaveSale = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "ShowKeyboardInSaveSale", "Y");
//TODO : make getter and setter for members (ie m_*) if needed (extern calls). For that in Eclipse use Source/Generate Getters and setters
@@ -146,7 +146,7 @@ public class PaidInOut extends XPage {
}
public synchronized void editAmount() {
if (wasMouseClicked() && ShowKeyboardInSaveSale) {
if (wasMouseClicked() && showKeyboardInSaveSale) {
try {
NumericKeypad numericKeypad = new NumericKeypad(m_pos);
numericKeypad.setMinus(true);
+2 -2
View File
@@ -53,7 +53,7 @@ public class SaveSale extends XPage {
//protected XButton m_saveAndPrint = null; //FIXME : button does not exist yet
protected static PosTransaction m_trans = null;
public static SimpleDateFormat sdf = new SimpleDateFormat(UtilProperties.getMessage(PosTransaction.resource,"PosDateTimeFormat",Locale.getDefault()));
private static boolean ShowKeyboardInSaveSale = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "ShowKeyboardInSaveSale", "Y");
private static boolean showKeyboardInSaveSale = UtilProperties.propertyValueEqualsIgnoreCase("parameters", "ShowKeyboardInSaveSale", "Y");
//TODO : make getter and setter for members (ie m_*) if needed (extern calls). For that in Eclipse use Source/Generate Getters and setters
@@ -128,7 +128,7 @@ public class SaveSale extends XPage {
}
public synchronized void editSaleName() {
if (wasMouseClicked() && ShowKeyboardInSaveSale) {
if (wasMouseClicked() && showKeyboardInSaveSale) {
try {
Keyboard keyboard = new Keyboard(m_pos);
keyboard.setText(m_saleName.getText());