Skip to content
Snippets Groups Projects
Commit 052124d0 authored by Maximilian Schröger's avatar Maximilian Schröger
Browse files

Merge branch 'master' of gitlab.adito.de:xrm/basic

# Conflicts:
#	language/_____LANGUAGE_EXTRA/_____LANGUAGE_EXTRA.aod
#	language/_____LANGUAGE_de/_____LANGUAGE_de.aod
#	language/_____LANGUAGE_en/_____LANGUAGE_en.aod
parents 80e95a3d 1a201cd7
No related branches found
No related tags found
No related merge requests found
Showing
with 99 additions and 7 deletions
...@@ -8,6 +8,6 @@ cond = new SqlCondition(); ...@@ -8,6 +8,6 @@ cond = new SqlCondition();
cond.andPrepareVars("RELATION.RELATIONID", "$param.RelId_param"); cond.andPrepareVars("RELATION.RELATIONID", "$param.RelId_param");
//TODO: this should happen by 1:1 links instead of manually requesting the data by a select //TODO: this should happen by 1:1 links instead of manually requesting the data by a select
country = db.cell(cond.buildSelect("select ADDRESS.COUNTRY from ADDRESS " country = db.cell(cond.buildSelect("select ADDRESS.COUNTRY from ADDRESS "
+ "join RELATION on RELATION.ADDRESS_ID = ADDRESS.ADDRESSID ")); + "join RELATION on RELATION.ADDRESS_ID = ADDRESS.ADDRESSID ", "1 = 1"));
if (country != "") if (country != "")
result.string(country); result.string(country);
\ No newline at end of file
...@@ -6,4 +6,4 @@ var cond = new SqlCondition(); ...@@ -6,4 +6,4 @@ var cond = new SqlCondition();
cond.andPrepareVars("HISTORYLINK.ROW_ID", "$param.RowId_param"); cond.andPrepareVars("HISTORYLINK.ROW_ID", "$param.RowId_param");
//TODO: use a preparedCondition when available //TODO: use a preparedCondition when available
result.string(db.translateCondition(cond.build())); result.string(db.translateCondition(cond.build("1 = 1")));
\ No newline at end of file \ No newline at end of file
...@@ -6,4 +6,4 @@ var cond = new SqlCondition(); ...@@ -6,4 +6,4 @@ var cond = new SqlCondition();
cond.andPrepareVars("OFFER.SALESPROJECT_ID", "$param.SalesprojectId_param"); cond.andPrepareVars("OFFER.SALESPROJECT_ID", "$param.SalesprojectId_param");
//TODO: use a preparedCondition when available //TODO: use a preparedCondition when available
result.string(db.translateCondition(cond.build())); result.string(db.translateCondition(cond.build("1 = 1")));
\ No newline at end of file \ No newline at end of file
...@@ -7,4 +7,4 @@ cond.andPrepareVars("RELATION.ORG_ID", "$param.OrgId_param"); ...@@ -7,4 +7,4 @@ cond.andPrepareVars("RELATION.ORG_ID", "$param.OrgId_param");
//TODO; add OBJECT_ID (probably another param) //TODO; add OBJECT_ID (probably another param)
//TODO: use a preparedCondition when available //TODO: use a preparedCondition when available
result.string(db.translateCondition(cond.build())); result.string(db.translateCondition(cond.build("1 = 1")));
\ No newline at end of file \ No newline at end of file
...@@ -9,6 +9,6 @@ orgId = vars.get("$field.ORGID"); ...@@ -9,6 +9,6 @@ orgId = vars.get("$field.ORGID");
if (orgId){ if (orgId){
cond = new SqlCondition(); cond = new SqlCondition();
cond.and("RELATION.PERS_ID is null").andPrepare("RELATION.ORG_ID", orgId) cond.and("RELATION.PERS_ID is null").andPrepare("RELATION.ORG_ID", orgId)
orgRelId = db.cell(cond.buildSelect("select RELATION.RELATIONID from RELATION")); orgRelId = db.cell(cond.buildSelect("select RELATION.RELATIONID from RELATION", "1 = 1"));
result.string(orgRelId); result.string(orgRelId);
} }
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.0.4" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.0.4"> <entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.0.4" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.0.4">
<name>SalesprojectCompetition_entity</name> <name>SalesprojectCompetition_entity</name>
<title>Competition</title>
<majorModelMode>DISTRIBUTED</majorModelMode> <majorModelMode>DISTRIBUTED</majorModelMode>
<recordContainerType>DB</recordContainerType> <recordContainerType>DB</recordContainerType>
<caption>Competition</caption>
<alias>Data_alias</alias> <alias>Data_alias</alias>
<conditionProcess>%aditoprj%/entity/SalesprojectCompetition_entity/conditionProcess.js</conditionProcess> <conditionProcess>%aditoprj%/entity/SalesprojectCompetition_entity/conditionProcess.js</conditionProcess>
<entityFields> <entityFields>
...@@ -21,11 +23,13 @@ ...@@ -21,11 +23,13 @@
<name>DATE_EDIT</name> <name>DATE_EDIT</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>DATE_EDIT</columnName> <columnName>DATE_EDIT</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/date_edit/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>DATE_NEW</name> <name>DATE_NEW</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>DATE_NEW</columnName> <columnName>DATE_NEW</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/date_new/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>INFO</name> <name>INFO</name>
...@@ -38,39 +42,48 @@ ...@@ -38,39 +42,48 @@
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>ORGNAME</columnName> <columnName>ORGNAME</columnName>
<caption>Competitor</caption> <caption>Competitor</caption>
<mandatory v="true" />
</entityField> </entityField>
<entityField> <entityField>
<name>REASON</name> <name>REASON</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>REASON</columnName> <columnName>REASON</columnName>
<caption>Reason</caption> <caption>Reason</caption>
<possibleItemsProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/reason/possibleItemsProcess.js</possibleItemsProcess>
<onValidation>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/reason/onValidation.js</onValidation>
</entityField> </entityField>
<entityField> <entityField>
<name>SALESPROJECT_COMPETITIONID</name> <name>SALESPROJECT_COMPETITIONID</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>SALESPROJECT_COMPETITIONID</columnName> <columnName>SALESPROJECT_COMPETITIONID</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/salesproject_competitionid/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>SALESPROJECT_ID</name> <name>SALESPROJECT_ID</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>SALESPROJECT_ID</columnName> <columnName>SALESPROJECT_ID</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/salesproject_id/valueProcess.js</valueProcess>
<onValidation>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/salesproject_id/onValidation.js</onValidation>
</entityField> </entityField>
<entityField> <entityField>
<name>STATUS</name> <name>STATUS</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>STATUS</columnName> <columnName>STATUS</columnName>
<caption>State</caption> <caption>State</caption>
<mandatory v="true" />
<possibleItemsProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/status/possibleItemsProcess.js</possibleItemsProcess> <possibleItemsProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/status/possibleItemsProcess.js</possibleItemsProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>USER_EDIT</name> <name>USER_EDIT</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>USER_EDIT</columnName> <columnName>USER_EDIT</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/user_edit/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>USER_NEW</name> <name>USER_NEW</name>
<tableName>SALESPROJECT_COMPETITION</tableName> <tableName>SALESPROJECT_COMPETITION</tableName>
<columnName>USER_NEW</columnName> <columnName>USER_NEW</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCompetition_entity/entityfields/user_new/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityParameter> <entityParameter>
<name>SalesprojectId_param</name> <name>SalesprojectId_param</name>
......
...@@ -6,4 +6,4 @@ var cond = new SqlCondition(); ...@@ -6,4 +6,4 @@ var cond = new SqlCondition();
cond.andPrepareVars("SALESPROJECT_COMPETITION.SALESPROJECT_ID", "$param.SalesprojectId_param"); cond.andPrepareVars("SALESPROJECT_COMPETITION.SALESPROJECT_ID", "$param.SalesprojectId_param");
//TODO: use a preparedCondition when available //TODO: use a preparedCondition when available
result.string(db.translateCondition(cond.build())); result.string(db.translateCondition(cond.build("1 = 1")));
\ No newline at end of file \ No newline at end of file
import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_EDIT)
result.string(vars.getString("$sys.date"));
\ No newline at end of file
import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_NEW)
result.string(vars.getString("$sys.date"));
\ No newline at end of file
import("system.result");
import("system.vars");
import("system.translate");
import("Util_lib");
var reason = ProcessHandlingUtil.getOnValidationValue(vars.get("$field.REASON"));
if (!vars.getString("$field.DATE_CANCELLED") && reason) {
result.string(translate.text("A reason is only possible if a date is given."))
}
import("system.result");
import("Keyword_lib");
var kwdUtils, items;
kwdUtils = new KeywordUtils();
items = kwdUtils.getStandardArray("SALESPROJECT.WONLOST");
result.object(items);
\ No newline at end of file
import("system.util");
import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_NEW)
result.string(util.getNewUUID());
\ No newline at end of file
import("system.result");
import("system.neon");
import("system.vars");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_NEW)
{
if(vars.exists("$param.SalesprojectId_param") && vars.get("$param.SalesprojectId_param") != null) {
result.string(vars.getString("$param.SalesprojectId_param"));
}
}
\ No newline at end of file
import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_EDIT)
result.string(vars.getString("$sys.user"));
\ No newline at end of file
import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_NEW)
result.string(vars.getString("$sys.user"));
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.0.4" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.0.4"> <entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.0.4" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.0.4">
<name>SalesprojectCycle_entity</name> <name>SalesprojectCycle_entity</name>
<title>Milestones</title>
<majorModelMode>DISTRIBUTED</majorModelMode> <majorModelMode>DISTRIBUTED</majorModelMode>
<recordContainerType>DB</recordContainerType> <recordContainerType>DB</recordContainerType>
<caption>Milestones</caption> <caption>Milestones</caption>
...@@ -29,11 +30,13 @@ ...@@ -29,11 +30,13 @@
<name>SALESPROJECT_CYCLEID</name> <name>SALESPROJECT_CYCLEID</name>
<tableName>SALESPROJECT_CYCLE</tableName> <tableName>SALESPROJECT_CYCLE</tableName>
<columnName>SALESPROJECT_CYCLEID</columnName> <columnName>SALESPROJECT_CYCLEID</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCycle_entity/entityfields/salesproject_cycleid/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>SALESPROJECT_ID</name> <name>SALESPROJECT_ID</name>
<tableName>SALESPROJECT_CYCLE</tableName> <tableName>SALESPROJECT_CYCLE</tableName>
<columnName>SALESPROJECT_ID</columnName> <columnName>SALESPROJECT_ID</columnName>
<valueProcess>%aditoprj%/entity/SalesprojectCycle_entity/entityfields/salesproject_id/valueProcess.js</valueProcess>
</entityField> </entityField>
<entityField> <entityField>
<name>TYPE</name> <name>TYPE</name>
......
...@@ -6,4 +6,4 @@ var cond = new SqlCondition(); ...@@ -6,4 +6,4 @@ var cond = new SqlCondition();
cond.andPrepareVars("SALESPROJECT_CYCLE.SALESPROJECT_ID", "$param.SalesprojectId_param"); cond.andPrepareVars("SALESPROJECT_CYCLE.SALESPROJECT_ID", "$param.SalesprojectId_param");
//TODO: use a preparedCondition when available //TODO: use a preparedCondition when available
result.string(db.translateCondition(cond.build())); result.string(db.translateCondition(cond.build("1 = 1")));
\ No newline at end of file \ No newline at end of file
import("system.util");
import("system.vars");
import("system.result");
import("system.neon");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_NEW)
result.string(util.getNewUUID());
\ No newline at end of file
import("system.result");
import("system.neon");
import("system.vars");
if(vars.get("$sys.operatingstate") == neon.OPERATINGSTATE_NEW)
{
if(vars.exists("$param.SalesprojectId_param") && vars.get("$param.SalesprojectId_param") != null) {
result.string(vars.getString("$param.SalesprojectId_param"));
}
}
\ 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