Skip to content
Snippets Groups Projects
Commit c59a1932 authored by Johannes Hörmann's avatar Johannes Hörmann
Browse files

fix Product

parent e7da15de
No related branches found
No related tags found
No related merge requests found
......@@ -81,6 +81,7 @@
<contentType>NUMBER</contentType>
<outputFormat>#</outputFormat>
<valueProcess>%aditoprj%/entity/Offeritem_entity/entityfields/quantity/valueProcess.js</valueProcess>
<onValidation>%aditoprj%/entity/Offeritem_entity/entityfields/quantity/onValidation.js</onValidation>
<onValueChange>%aditoprj%/entity/Offeritem_entity/entityfields/quantity/onValueChange.js</onValueChange>
<onValueChangeTypes>
<element>MASK</element>
......
import("system.logging");
import("system.result");
import("system.vars");
logging.log("validate")
if (parseInt(vars.get("$field.QUANTITY")) <= 0)
{
result.string("${QUANTITY_LOWER_THAN_0}");
}
\ No newline at end of file
......@@ -2,7 +2,7 @@ import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW && !vars.get("$this.value"))
if(vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW)
{
result.string("1");
}
\ No newline at end of file
......@@ -27,6 +27,8 @@
<entityField>
<name>QUANTITY</name>
<title>Quantity</title>
<contentType>NUMBER</contentType>
<outputFormat>#</outputFormat>
<valueProcess>%aditoprj%/entity/Prod2prod_entity/entityfields/quantity/valueProcess.js</valueProcess>
</entityField>
<entityField>
......
//import("system.vars");
//import("system.result");
//import("system.neon");
//
//if(vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW && vars.get("$this.value") == "")
//{
// result.string("1");
//}
//else
// result.string(vars.get("$this.value"));
\ No newline at end of file
import("system.vars");
import("system.result");
import("system.neon");
if (vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW && !vars.get("$field.QUANTITY"))
{
result.string("1");
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment