Skip to content
Snippets Groups Projects
Commit 8838d4d6 authored by Dominik Lechner's avatar Dominik Lechner
Browse files

Performance Tuning - FilterView Person and Product - Image

parent ddb07feb
No related branches found
No related tags found
No related merge requests found
......@@ -867,7 +867,7 @@
<entityField>
<name>CONTACT_ID</name>
<documentation>%aditoprj%/entity/Offer_entity/entityfields/contact_id/documentation.adoc</documentation>
<title>Assignment</title>
<title>Contact</title>
<consumer>AnyContacts</consumer>
<linkedContextProcess>%aditoprj%/entity/Offer_entity/entityfields/contact_id/linkedContextProcess.js</linkedContextProcess>
<mandatory v="true" />
......@@ -1050,6 +1050,10 @@
<name>CONTACT_ID.value</name>
<recordfield>OFFER.CONTACT_ID</recordfield>
</dbRecordFieldMapping>
<dbRecordFieldMapping>
<name>CONTACT_ID.displayValue</name>
<expression>%aditoprj%/entity/Offer_entity/recordcontainers/db/recordfieldmappings/contact_id.displayvalue/expression.js</expression>
</dbRecordFieldMapping>
</recordFieldMappings>
</dbRecordContainer>
</recordContainers>
......
import("system.result");
import("system.vars");
import("system.neon");
import("StandardObject_lib");
if (!vars.get("$field.ADDRESS_ID") || StandardObject.isOrganisationAddress(vars.get("$field.ADDRESS_ID")))
{
var possibleStandardAddressID = new StandardObject("Address", null, "Person", vars.get("$field.PERSONID"))
.onPersonValueChange(vars.get("$field.ORGANISATION_ID"));
// If a possible standard addrss was found it should get applied to the field.
if (possibleStandardAddressID)
neon.setFieldValue("$field.ADDRESS_ID", possibleStandardAddressID);
}
\ No newline at end of file
......@@ -7,6 +7,7 @@
<contentTitleProcess>%aditoprj%/entity/Product_entity/contentTitleProcess.js</contentTitleProcess>
<afterUiInit>%aditoprj%/entity/Product_entity/afterUiInit.js</afterUiInit>
<iconId>VAADIN:HAMMER</iconId>
<imageProcess>%aditoprj%/entity/Product_entity/imageProcess.js</imageProcess>
<titlePlural>Products</titlePlural>
<recordContainer>db</recordContainer>
<entityFields>
......@@ -441,6 +442,10 @@
</entityParameter>
</children>
</entityConsumer>
<entityParameter>
<name>ProductText_param</name>
<valueProcess>%aditoprj%/entity/Product_entity/entityfields/producttext_param/valueProcess.js</valueProcess>
</entityParameter>
</entityFields>
<recordContainers>
<dbRecordContainer>
......
......@@ -3,7 +3,4 @@ import("system.neon");
import("system.vars");
import("Product_lib");
if (vars.get("$sys.recordstate") == neon.OPERATINGSTATE_VIEW)
{
result.string(ProductUtils.getImage(vars.get("$field.PRODUCTID"), vars.getString("$field.PRODUCTNAME")));
}
\ No newline at end of file
result.string(ProductUtils.getImage(vars.get("$field.PRODUCTID"), vars.getString("$field.PRODUCTNAME")));
\ No newline at end of file
import("system.vars");
import("system.result");
result.string("TEXT:" + vars.getString("$field.PRODUCTNAME"));
\ No newline at end of file
import("system.vars");
import("system.result");
result.string(vars.get("$param.ProductText_param"));
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<neonView xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.1.1" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/neonView/1.1.1">
<name>ProductFilter_view</name>
<majorModelMode>DISTRIBUTED</majorModelMode>
<filterable v="true" />
<dashletConfigurations>
<neonDashletConfiguration>
<name>AllProductsDashlet</name>
<title>Products</title>
<description>Show all products</description>
<fragment>Product/filter</fragment>
<singleton v="true" />
<requiresConfiguration v="false" />
<icon>vaadin:hammer</icon>
<categories>
<neonDashletCategory>
<name>sales</name>
<title>Sales</title>
</neonDashletCategory>
<neonDashletCategory>
<name>product</name>
<title>Product</title>
</neonDashletCategory>
</categories>
</neonDashletConfiguration>
</dashletConfigurations>
<layout>
<boxLayout>
<name>layout</name>
</boxLayout>
</layout>
<children>
<tableViewTemplate>
<name>Products</name>
<entityField>#ENTITY</entityField>
<columns>
<neonTableColumn>
<name>bf58edbf-0708-41a7-a092-ebc87a60c3c2</name>
<entityField>IMAGE</entityField>
</neonTableColumn>
<neonTableColumn>
<name>913381d1-91cc-4ec7-b732-b35ddab01b90</name>
<entityField>test</entityField>
</neonTableColumn>
<neonTableColumn>
<name>ee627d12-c60c-48c2-a86e-2a144f5853e6</name>
<entityField>PRODUCTCODE</entityField>
</neonTableColumn>
<neonTableColumn>
<name>cd013f0c-b9b0-4c5a-866b-53a9f69ad75e</name>
<entityField>PRODUCTNAME</entityField>
</neonTableColumn>
<neonTableColumn>
<name>346eab87-8fea-4828-8ea6-86af61f973ce</name>
<entityField>GROUPCODEID</entityField>
</neonTableColumn>
<neonTableColumn>
<name>3e774e1c-0998-4b2c-b876-22e99a79cb55</name>
<entityField>STATUS</entityField>
</neonTableColumn>
<neonTableColumn>
<name>4f31b5e8-0e09-4417-b9e9-96b69049b3cf</name>
<entityField>CONTACT_ID</entityField>
<width v="75" />
<expandRatio v="100" />
</neonTableColumn>
<neonTableColumn>
<name>9cfc7b76-3d75-4a26-a21f-3b2b1a2faac5</name>
<entityField>UNIT</entityField>
<width v="75" />
<expandRatio v="100" />
</neonTableColumn>
</columns>
</tableViewTemplate>
</children>
</neonView>
<?xml version="1.0" encoding="UTF-8"?>
<neonView xmlns="http://www.adito.de/2018/ao/Model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" VERSION="1.1.1" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/neonView/1.1.1">
<name>ProductFilter_view</name>
<majorModelMode>DISTRIBUTED</majorModelMode>
<filterable v="true" />
<dashletConfigurations>
<neonDashletConfiguration>
<name>AllProductsDashlet</name>
<title>Products</title>
<description>Show all products</description>
<fragment>Product/filter</fragment>
<singleton v="true" />
<requiresConfiguration v="false" />
<icon>vaadin:hammer</icon>
<categories>
<neonDashletCategory>
<name>sales</name>
<title>Sales</title>
</neonDashletCategory>
<neonDashletCategory>
<name>product</name>
<title>Product</title>
</neonDashletCategory>
</categories>
</neonDashletConfiguration>
</dashletConfigurations>
<layout>
<boxLayout>
<name>layout</name>
</boxLayout>
</layout>
<children>
<tableViewTemplate>
<name>Products</name>
<entityField>#ENTITY</entityField>
<columns>
<neonTableColumn>
<name>2b03ec87-92a8-44dd-932e-80df160b2c8e</name>
<entityField>#IMAGE</entityField>
</neonTableColumn>
<neonTableColumn>
<name>ee627d12-c60c-48c2-a86e-2a144f5853e6</name>
<entityField>PRODUCTCODE</entityField>
</neonTableColumn>
<neonTableColumn>
<name>cd013f0c-b9b0-4c5a-866b-53a9f69ad75e</name>
<entityField>PRODUCTNAME</entityField>
</neonTableColumn>
<neonTableColumn>
<name>346eab87-8fea-4828-8ea6-86af61f973ce</name>
<entityField>GROUPCODEID</entityField>
</neonTableColumn>
<neonTableColumn>
<name>3e774e1c-0998-4b2c-b876-22e99a79cb55</name>
<entityField>STATUS</entityField>
</neonTableColumn>
<neonTableColumn>
<name>4f31b5e8-0e09-4417-b9e9-96b69049b3cf</name>
<entityField>CONTACT_ID</entityField>
<width v="75" />
<expandRatio v="100" />
</neonTableColumn>
<neonTableColumn>
<name>9cfc7b76-3d75-4a26-a21f-3b2b1a2faac5</name>
<entityField>UNIT</entityField>
<width v="75" />
<expandRatio v="100" />
</neonTableColumn>
</columns>
</tableViewTemplate>
</children>
</neonView>
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