Skip to content
Snippets Groups Projects
Commit f9ba323c authored by S.Listl's avatar S.Listl
Browse files

Merge origin/master

parents d03439ba bbdfc6bd
No related branches found
No related tags found
No related merge requests found
Showing
with 95 additions and 10 deletions
<?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.2.0" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.2.0">
<name>AnyContact_entity</name>
<description>former Relation</description>
<majorModelMode>DISTRIBUTED</majorModelMode>
<titleProcess>%aditoprj%/entity/AnyContact_entity/titleProcess.js</titleProcess>
<recordContainer>db</recordContainer>
......
......@@ -2,6 +2,7 @@
<entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.2.0" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.2.0">
<name>Communication_entity</name>
<title>Communication</title>
<description>former Comm</description>
<majorModelMode>DISTRIBUTED</majorModelMode>
<titleProcess>%aditoprj%/entity/Communication_entity/titleProcess.js</titleProcess>
<recordContainer>db</recordContainer>
......
......@@ -2,6 +2,7 @@
<entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.2.0" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.2.0">
<name>Organisation_entity</name>
<title>Company</title>
<description>former Org</description>
<majorModelMode>DISTRIBUTED</majorModelMode>
<documentation>%aditoprj%/entity/Organisation_entity/documentation.adoc</documentation>
<iconId>VAADIN:BUILDING</iconId>
......
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("$field.IMAGE");
\ No newline at end of file
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("$field.STANDARD_EMAIL_COMMUNICATION");
\ No newline at end of file
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("$field.STANDARD_PHONE_COMMUNICATION");
\ No newline at end of file
......@@ -3,7 +3,7 @@ import("Organisation_lib");
import("Communication_lib");
import("Entity_lib");
// TODO: this is a workaround for missing possibility to react on changes of fields not connected to record Container
// TODO: this is a workaround for missing possibility to react on changes of fields not connected to record Container #1030023
FieldChanges.assimilateChangeAndDispose("$field.IMAGE", function(state, value){
if (state == FieldChanges.STATE_CHANGED())
OrgUtils.setImage(vars.get("$field.ORGANISATIONID"), value);
......
......@@ -2,6 +2,7 @@
<entity xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.2.0" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/entity/1.2.0">
<name>Person_entity</name>
<title>Contact</title>
<description>former Pers</description>
<majorModelMode>DISTRIBUTED</majorModelMode>
<iconId>VAADIN:USERS</iconId>
<imageProcess>%aditoprj%/entity/Person_entity/imageProcess.js</imageProcess>
......
import("system.translate");
import("system.db");
import("system.vars");
import("system.text");
......@@ -11,6 +12,6 @@ if (vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW)
var newCodeNumber = db.cell("select " + maskingHelper.max("TASK.CODE") + " from TASK");
newCodeNumber = Number(newCodeNumber);//if no number exists till no, start value will be 1 (due to: ++0)
if (isNaN(newCodeNumber))
throw new TypeError();//TODO:add Message
throw new TypeError(translate.text("The code number is not a valid number."));
neon.setFieldValue("$field.CODE", ++newCodeNumber);
}
\ No newline at end of file
import("system.result");
import("Person_lib");
//TODO: try to find a better solution for this
//TODO: try to find a better solution for this -> #TITLE-mechanic when available
var subSql = PersUtils.getResolvingDisplaySubSql("TASK.EDITOR_CONTACT_ID");
result.string(subSql);
\ No newline at end of file
import("system.result");
import("Person_lib");
//TODO: try to find a better solution for this
//TODO: try to find a better solution for this -> #TITLE-mechanic when available
var subSql = PersUtils.getResolvingDisplaySubSql("TASK.REQUESTOR_CONTACT_ID");
result.string(subSql);
\ No newline at end of file
......@@ -3,6 +3,7 @@
<name>Turnover_entity</name>
<title>Turnover</title>
<majorModelMode>DISTRIBUTED</majorModelMode>
<documentation>%aditoprj%/entity/Turnover_entity/documentation.adoc</documentation>
<iconId>VAADIN:CHART</iconId>
<recordContainer>jdito</recordContainer>
<entityFields>
......@@ -31,6 +32,38 @@
<title>Year</title>
<contentType>TEXT</contentType>
</entityField>
<entityParameter>
<name>YearCountToShow_param</name>
<code>%aditoprj%/entity/Turnover_entity/entityfields/yearcounttoshow_param/code.js</code>
<expose v="true" />
<triggerRecalculation v="true" />
<mandatory v="false" />
<documentation>%aditoprj%/entity/Turnover_entity/entityfields/yearcounttoshow_param/documentation.adoc</documentation>
<description>PARAMETER</description>
</entityParameter>
<entityParameter>
<name>MaxYear_param</name>
<code>%aditoprj%/entity/Turnover_entity/entityfields/maxyear_param/code.js</code>
<expose v="true" />
<triggerRecalculation v="true" />
<mandatory v="false" />
<documentation>%aditoprj%/entity/Turnover_entity/entityfields/maxyear_param/documentation.adoc</documentation>
<description>PARAMETER</description>
</entityParameter>
<entityProvider>
<name>FilteredTurnover</name>
<fieldType>DEPENDENCY_IN</fieldType>
<children>
<entityParameter>
<name>MaxYear_param</name>
<expose v="true" />
</entityParameter>
<entityParameter>
<name>YearCountToShow_param</name>
<expose v="true" />
</entityParameter>
</children>
</entityProvider>
</entityFields>
<recordContainers>
<jDitoRecordContainer>
......
== Turnover ==
This entity provides charts to display the Turnover.
\ No newline at end of file
import("system.result");
import("system.vars");
import("system.datetime");
result.string(datetime.toDate(vars.get("$sys.date"), "yyyy"));
\ No newline at end of file
this parameter is for setting the maximum year to show.
The default is the current year.
\ No newline at end of file
import("system.result");
result.string("4");
\ No newline at end of file
This parameter is for setting the number of years to show.
Default is 4.
\ No newline at end of file
import("system.vars");
import("system.logging");
import("system.datetime");
import("system.db");
import("system.result");
......@@ -18,11 +20,13 @@ var chartData = ReferencingData.begin(rootNode);
var skippedCounts = {};
for (let i = 0; i < 4; i++)
var maxYear = parseInt(vars.get("$param.MaxYear_param"));
var yearCountToShow = parseInt(vars.get("$param.YearCountToShow_param"));
for (let i = 0; i < yearCountToShow; i++)
{
// TODO: currently years are hardcoded.
var year = i + 2016;
var year = i + maxYear - yearCountToShow + 1;
var TurnoverYearSum = 0;
var ForecastYearSum = 0;
......
......@@ -2331,6 +2331,18 @@
<entry>
<key>Linktype</key>
</entry>
<entry>
<key>${SQL_LIB_UNSUPPORTED_DBTYPE} function: %0</key>
</entry>
<entry>
<key>Links</key>
</entry>
<entry>
<key>Linktype</key>
</entry>
<entry>
<key>${PRODUCT_LIB_NO_PRODUCT_ID} function: %0</key>
</entry>
</keyValueMap>
<font name="Dialog" style="0" size="11" />
<sqlModels>
......
......@@ -2686,6 +2686,20 @@
<entry>
<key>Linktype</key>
</entry>
<entry>
<key>${SQL_LIB_UNSUPPORTED_DBTYPE} function: %0</key>
<value>Der DB-Typ wird in der Funktion %0 nicht unterstützt.</value>
</entry>
<entry>
<key>Links</key>
</entry>
<entry>
<key>Linktype</key>
</entry>
<entry>
<key>${PRODUCT_LIB_NO_PRODUCT_ID} function: %0</key>
<value>Es wird der Funktion %0 keine Produktid übergeben.</value>
</entry>
</keyValueMap>
<font name="Dialog" style="0" size="11" />
</language>
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