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

[Projekt: Entwicklung - Neon][TicketNr.: 1032647][Vertrieb - Produkt -...

[Projekt: Entwicklung - Neon][TicketNr.: 1032647][Vertrieb - Produkt - Preisliste - Bei Neueintrag soll des Feld Produkt vorbelegt sein]
parent 21e0b2d2
No related branches found
No related tags found
No related merge requests found
......@@ -4,14 +4,6 @@ import("system.result");
import("system.db");
import("Sql_lib");
logging.log("rowid: " + vars.get("$param.Object1Rowid_param"))
logging.log("type: " + vars.get("$param.Object1Type_param"))
logging.log(SqlCondition.begin()
.andPrepareVars("AB_OBJECTRELATION.OBJECT1_TYPE", "$param.Object1Type_param")
.andPrepareVars("AB_OBJECTRELATION.OBJECT1_ROWID", "$param.Object1Rowid_param")
.andPrepareVars("AB_OBJECTRELATION.AB_OBJECTRELATIONID", "$param.ObjectRelatonId_param")
.build("1=2").toSource())
result.string(db.translateCondition(SqlCondition.begin()
.andPrepareVars("AB_OBJECTRELATION.OBJECT1_TYPE", "$param.Object1Type_param")
.andPrepareVars("AB_OBJECTRELATION.OBJECT1_ROWID", "$param.Object1Rowid_param")
......
......@@ -4,7 +4,6 @@
<title>Price list</title>
<majorModelMode>DISTRIBUTED</majorModelMode>
<documentation>%aditoprj%/entity/Productprice_entity/documentation.adoc</documentation>
<onValidation>%aditoprj%/entity/Productprice_entity/onValidation.js</onValidation>
<recordContainer>db</recordContainer>
<entityFields>
<entityField>
......@@ -56,10 +55,11 @@
<name>PRODUCT_ID</name>
<title>Product</title>
<linkedContext>Product_context</linkedContext>
<mandatory v="false" />
<mandatory v="true" />
<outgoingField>ProductpriceProduct_dfo</outgoingField>
<state>AUTO</state>
<valueProcess>%aditoprj%/entity/Productprice_entity/entityfields/product_id/valueProcess.js</valueProcess>
<displayValueProcess>%aditoprj%/entity/Productprice_entity/entityfields/product_id/displayValueProcess.js</displayValueProcess>
</entityField>
<entityField>
<name>RELATION_ID</name>
......@@ -134,11 +134,6 @@
<mandatory v="false" />
<description>PARAMETER</description>
</entityParameter>
<entityField>
<name>PRODUCT_GROUPCODEID</name>
<title>Product group</title>
<possibleItemsProcess>%aditoprj%/entity/Productprice_entity/entityfields/product_groupcodeid/possibleItemsProcess.js</possibleItemsProcess>
</entityField>
<entityIncomingField>
<name>OrgProductprice_dfi</name>
<fieldType>DEPENDENCY_IN</fieldType>
......@@ -194,13 +189,11 @@
<dbRecordContainer>
<name>db</name>
<alias>Data_alias</alias>
<maximumDbRows v="0" />
<conditionProcess>%aditoprj%/entity/Productprice_entity/recordcontainers/db/conditionProcess.js</conditionProcess>
<orderClauseProcess>%aditoprj%/entity/Productprice_entity/recordcontainers/db/orderClauseProcess.js</orderClauseProcess>
<onDBInsert>%aditoprj%/entity/Productprice_entity/onDBInsert.js</onDBInsert>
<linkInformation>
<linkInformation>
<name>b65e4aab-35f4-49d0-8f05-389572f29dcb</name>
<name>85fd1bcf-499f-4708-ad8e-18f5a0f5337d</name>
<tableName>PRODUCTPRICE</tableName>
<primaryKey>PRODUCTPRICEID</primaryKey>
<isUIDTable v="true" />
......
import("system.result");
import("Keyword_lib");
var items;
items = KeywordUtils.getStandardArray("GROUPCODE");
result.object(items);
\ No newline at end of file
import("system.result");
import("system.db");
import("Sql_lib");
// TODO: Wenn es möglich ist, den anzeigenamen des Produkts über die Entity beziehung zu laden, dann umbauen...!!!
result.string(db.cell(SqlCondition.begin()
.andPrepareVars("PRODUCT.PRODUCTID", "$field.PRODUCT_ID")
.buildSql("select PRODUCTNAME from PRODUCT", "1=2")));
\ No newline at end of file
import("system.logging");
import("system.result");
import("system.neon");
import("system.vars");
if(vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW)
if(vars.exists("$param.ProductId_param") && vars.get("$param.ProductId_param"))
{
if(vars.exists("$param.ProductId_param") && vars.get("$param.ProductId_param") != null && vars.get("$param.ProductId_param") != "")
result.string(vars.getString("$param.ProductId_param"));
}
result.string(vars.getString("$param.ProductId_param"));
logging.log("---" + vars.get("$param.ProductId_param"))
}
\ No newline at end of file
......@@ -48,7 +48,7 @@ ProductUtils.getCurrentProductPrice = function(pid, buySell) {
else
return "";
} else {
throw new Error(); // TODO: add message
return "";
}
}
......
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