0004800: Quilometragem - Mudar para decimal
git-svn-id: http://desenvolvimento.rjconsultores.com.br/repositorio/sco/AdmVenta/Web/trunk/ventaboletos@34280 d1611594-4594-4d17-8e1d-87c2c4800839master
parent
9151a9a0c0
commit
ee830c3417
|
@ -11,6 +11,7 @@ import java.util.List;
|
||||||
|
|
||||||
import org.apache.commons.collections.CollectionUtils;
|
import org.apache.commons.collections.CollectionUtils;
|
||||||
import org.apache.commons.collections.Predicate;
|
import org.apache.commons.collections.Predicate;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
import org.apache.log4j.Logger;
|
import org.apache.log4j.Logger;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.context.annotation.Scope;
|
import org.springframework.context.annotation.Scope;
|
||||||
|
@ -188,7 +189,7 @@ public class EditarTramosController extends MyGenericForwardComposer {
|
||||||
}
|
}
|
||||||
tramoCoeficientesList.setData(lsOrgamoTramo);
|
tramoCoeficientesList.setData(lsOrgamoTramo);
|
||||||
|
|
||||||
txKmReal.setValue(tramo.getKmReal().toString());
|
txKmReal.setValue(maskKmReal(tramo.getKmReal()));
|
||||||
}
|
}
|
||||||
tramosList = (MyListbox) Executions.getCurrent().getArg().get("tramosList");
|
tramosList = (MyListbox) Executions.getCurrent().getArg().get("tramosList");
|
||||||
|
|
||||||
|
@ -197,14 +198,20 @@ public class EditarTramosController extends MyGenericForwardComposer {
|
||||||
}
|
}
|
||||||
|
|
||||||
txtNome.focus();
|
txtNome.focus();
|
||||||
|
|
||||||
constraintTarifa = new ConstraintNumberBD(7, 2, true);
|
|
||||||
|
|
||||||
txKmReal.setConstraint(constraintTarifa);
|
|
||||||
tabExcepcionesKm.setVisible(ApplicationProperties.getInstance().exhibirExcepcionesTramoKm());
|
tabExcepcionesKm.setVisible(ApplicationProperties.getInstance().exhibirExcepcionesTramoKm());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private String maskKmReal(BigDecimal kmReal) {
|
||||||
|
try {
|
||||||
|
String resp = kmReal.toString();
|
||||||
|
resp = resp.replaceAll("\\.", ",");
|
||||||
|
return resp;
|
||||||
|
} catch (Exception e) {
|
||||||
|
}
|
||||||
|
return StringUtils.EMPTY;
|
||||||
|
}
|
||||||
|
|
||||||
public void onClick$btnSalvarServicio(Event ev) throws InterruptedException {
|
public void onClick$btnSalvarServicio(Event ev) throws InterruptedException {
|
||||||
spHora.getValue();
|
spHora.getValue();
|
||||||
spMinuto.getValue();
|
spMinuto.getValue();
|
||||||
|
|
|
@ -93,7 +93,7 @@
|
||||||
value="${c:l('editarTramosController.lbKmReal.value')}" />
|
value="${c:l('editarTramosController.lbKmReal.value')}" />
|
||||||
|
|
||||||
<textbox id="txKmReal" width="80%"
|
<textbox id="txKmReal" width="80%"
|
||||||
precision="9" scale="2"
|
precision="7" scale="2"
|
||||||
constraint="no empty, no zero, no negative"
|
constraint="no empty, no zero, no negative"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
||||||
</row>
|
</row>
|
||||||
|
@ -340,7 +340,7 @@
|
||||||
<label
|
<label
|
||||||
value="${c:l('editarTramosController.labelKMCoeficiente1.value')}" />
|
value="${c:l('editarTramosController.labelKMCoeficiente1.value')}" />
|
||||||
<textbox id="txtKMCoeficiente1"
|
<textbox id="txtKMCoeficiente1"
|
||||||
precision="9" scale="2"
|
precision="7" scale="2"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
||||||
|
|
||||||
</row>
|
</row>
|
||||||
|
@ -355,7 +355,7 @@
|
||||||
<label
|
<label
|
||||||
value="${c:l('editarTramosController.labelKMCoeficiente2.value')}" />
|
value="${c:l('editarTramosController.labelKMCoeficiente2.value')}" />
|
||||||
<textbox id="txtKMCoeficiente2"
|
<textbox id="txtKMCoeficiente2"
|
||||||
precision="9" scale="2"
|
precision="7" scale="2"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
||||||
</row>
|
</row>
|
||||||
<row spans="1,1,1,1">
|
<row spans="1,1,1,1">
|
||||||
|
@ -369,7 +369,7 @@
|
||||||
<label
|
<label
|
||||||
value="${c:l('editarTramosController.labelKMCoeficiente3.value')}" />
|
value="${c:l('editarTramosController.labelKMCoeficiente3.value')}" />
|
||||||
<textbox id="txtKMCoeficiente3"
|
<textbox id="txtKMCoeficiente3"
|
||||||
precision="9" scale="2"
|
precision="7" scale="2"
|
||||||
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
use="com.rjconsultores.ventaboletos.web.utilerias.MyTextboxDecimal" />
|
||||||
</row>
|
</row>
|
||||||
<row spans="1,1,1,1">
|
<row spans="1,1,1,1">
|
||||||
|
|
Loading…
Reference in New Issue