From 72e469aeed11a7347c965cd85eeab904cc173431 Mon Sep 17 00:00:00 2001 From: "p.neub" <p.neub@adito.de> Date: Tue, 16 Nov 2021 17:57:57 +0100 Subject: [PATCH] [Projekt: xRM-Sales][TicketNr.: 2001283][Allg. Bugs Sales] --- entity/Orderitem_entity/Orderitem_entity.aod | 2 ++ .../Salesproject_entity.aod | 5 +++++ .../probability.displayvalue/expression.js | 7 +++++++ neonContext/Product/Product.aod | 8 ++++++++ ...roductDescriptionTranslationDrawer_view.aod | 18 ++++++++++++++++++ .../ProductDescritption_view.aod | 12 ++++++------ .../ProductKnowledgeManagementDrawer_view.aod | 18 ++++++++++++++++++ .../ProductPreview_view.aod | 2 +- 8 files changed, 65 insertions(+), 7 deletions(-) create mode 100644 entity/Salesproject_entity/recordcontainers/db/recordfieldmappings/probability.displayvalue/expression.js create mode 100644 neonView/ProductDescriptionTranslationDrawer_view/ProductDescriptionTranslationDrawer_view.aod create mode 100644 neonView/ProductKnowledgeManagementDrawer_view/ProductKnowledgeManagementDrawer_view.aod diff --git a/entity/Orderitem_entity/Orderitem_entity.aod b/entity/Orderitem_entity/Orderitem_entity.aod index d88495d1e76..e5cea0d0343 100644 --- a/entity/Orderitem_entity/Orderitem_entity.aod +++ b/entity/Orderitem_entity/Orderitem_entity.aod @@ -71,6 +71,7 @@ <title>Article</title> <consumer>Products</consumer> <linkedContext>Product</linkedContext> + <mandatory v="true" /> <valueProcess>%aditoprj%/entity/Orderitem_entity/entityfields/product_id/valueProcess.js</valueProcess> <onValueChange>%aditoprj%/entity/Orderitem_entity/entityfields/product_id/onValueChange.js</onValueChange> <onValueChangeTypes> @@ -85,6 +86,7 @@ <contentType>NUMBER</contentType> <minValue v="1" /> <outputFormat>#</outputFormat> + <mandatory v="true" /> <valueProcess>%aditoprj%/entity/Orderitem_entity/entityfields/quantity/valueProcess.js</valueProcess> <onValueChange>%aditoprj%/entity/Orderitem_entity/entityfields/quantity/onValueChange.js</onValueChange> <onValueChangeTypes> diff --git a/entity/Salesproject_entity/Salesproject_entity.aod b/entity/Salesproject_entity/Salesproject_entity.aod index b677647150b..db15fce3cc5 100644 --- a/entity/Salesproject_entity/Salesproject_entity.aod +++ b/entity/Salesproject_entity/Salesproject_entity.aod @@ -134,6 +134,7 @@ <maxValue v="100" /> <minValue v="0" /> <outputFormat>0'%'</outputFormat> + <inputFormat>0'%'</inputFormat> <groupable v="true" /> </entityField> <entityConsumer> @@ -1079,6 +1080,10 @@ <name>USER_NEW.value</name> <recordfield>SALESPROJECT.USER_NEW</recordfield> </dbRecordFieldMapping> + <dbRecordFieldMapping> + <name>PROBABILITY.displayValue</name> + <expression>%aditoprj%/entity/Salesproject_entity/recordcontainers/db/recordfieldmappings/probability.displayvalue/expression.js</expression> + </dbRecordFieldMapping> </recordFieldMappings> <linkInformation> <linkInformation> diff --git a/entity/Salesproject_entity/recordcontainers/db/recordfieldmappings/probability.displayvalue/expression.js b/entity/Salesproject_entity/recordcontainers/db/recordfieldmappings/probability.displayvalue/expression.js new file mode 100644 index 00000000000..fb4fe063f13 --- /dev/null +++ b/entity/Salesproject_entity/recordcontainers/db/recordfieldmappings/probability.displayvalue/expression.js @@ -0,0 +1,7 @@ +import("system.result"); +import("Sql_lib"); +import("system.SQLTYPES"); + +var maskingUtils = new SqlMaskingUtils(); +var probability = maskingUtils.cast("SALESPROJECT.PROBABILITY", SQLTYPES.CHAR, 2); +result.string(maskingUtils.concatenate([probability, "'%'"])); diff --git a/neonContext/Product/Product.aod b/neonContext/Product/Product.aod index a351e047784..dc4076556ec 100644 --- a/neonContext/Product/Product.aod +++ b/neonContext/Product/Product.aod @@ -39,5 +39,13 @@ <name>bcc36a52-f97f-4883-b1eb-21b9daef82f4</name> <view>ProductOfferOrder_view</view> </neonViewReference> + <neonViewReference> + <name>d4a89117-5f6d-4fdf-ad1b-546deb45f497</name> + <view>ProductKnowledgeManagementDrawer_view</view> + </neonViewReference> + <neonViewReference> + <name>97ada610-725f-4636-a812-4da364a41636</name> + <view>ProductDescriptionTranslationDrawer_view</view> + </neonViewReference> </references> </neonContext> diff --git a/neonView/ProductDescriptionTranslationDrawer_view/ProductDescriptionTranslationDrawer_view.aod b/neonView/ProductDescriptionTranslationDrawer_view/ProductDescriptionTranslationDrawer_view.aod new file mode 100644 index 00000000000..0ec9d21eb21 --- /dev/null +++ b/neonView/ProductDescriptionTranslationDrawer_view/ProductDescriptionTranslationDrawer_view.aod @@ -0,0 +1,18 @@ +<?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.8" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/neonView/1.1.8"> + <name>ProductDescriptionTranslationDrawer_view</name> + <majorModelMode>DISTRIBUTED</majorModelMode> + <layout> + <drawerLayout> + <name>layout</name> + <layoutCaption>Descriptions</layoutCaption> + </drawerLayout> + </layout> + <children> + <neonViewReference> + <name>59ca667d-68c8-40c4-a8cb-a9d98eeb0237</name> + <entityField>DescriptionTranslations</entityField> + <view>DescriptionTranslationFilter_view</view> + </neonViewReference> + </children> +</neonView> diff --git a/neonView/ProductDescritption_view/ProductDescritption_view.aod b/neonView/ProductDescritption_view/ProductDescritption_view.aod index a85032efe37..ffdddeb4f50 100644 --- a/neonView/ProductDescritption_view/ProductDescritption_view.aod +++ b/neonView/ProductDescritption_view/ProductDescritption_view.aod @@ -10,14 +10,14 @@ </layout> <children> <neonViewReference> - <name>d1bc2777-ee77-4604-8d7e-735ec79ed551</name> - <entityField>KnowledgeManagements</entityField> - <view>KnowledgeManagementFilter_view</view> + <name>74824d62-9767-4196-89fc-92a1fc432d34</name> + <entityField>#ENTITY</entityField> + <view>ProductKnowledgeManagementDrawer_view</view> </neonViewReference> <neonViewReference> - <name>1871fa72-d36b-43bd-937b-822ea7c2a08d</name> - <entityField>DescriptionTranslations</entityField> - <view>DescriptionTranslationFilter_view</view> + <name>325ad9fb-801b-4462-9899-22d07747c93f</name> + <entityField>#ENTITY</entityField> + <view>ProductDescriptionTranslationDrawer_view</view> </neonViewReference> </children> </neonView> diff --git a/neonView/ProductKnowledgeManagementDrawer_view/ProductKnowledgeManagementDrawer_view.aod b/neonView/ProductKnowledgeManagementDrawer_view/ProductKnowledgeManagementDrawer_view.aod new file mode 100644 index 00000000000..8a4a258a872 --- /dev/null +++ b/neonView/ProductKnowledgeManagementDrawer_view/ProductKnowledgeManagementDrawer_view.aod @@ -0,0 +1,18 @@ +<?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.8" xsi:schemaLocation="http://www.adito.de/2018/ao/Model adito://models/xsd/neonView/1.1.8"> + <name>ProductKnowledgeManagementDrawer_view</name> + <majorModelMode>DISTRIBUTED</majorModelMode> + <layout> + <drawerLayout> + <name>layout</name> + <layoutCaption>Knowledge entries</layoutCaption> + </drawerLayout> + </layout> + <children> + <neonViewReference> + <name>b322e599-ccda-47c1-8f5c-42264d9d362e</name> + <entityField>KnowledgeManagements</entityField> + <view>KnowledgeManagementFilter_view</view> + </neonViewReference> + </children> +</neonView> diff --git a/neonView/ProductPreview_view/ProductPreview_view.aod b/neonView/ProductPreview_view/ProductPreview_view.aod index 687114627be..6bda8f376d2 100644 --- a/neonView/ProductPreview_view/ProductPreview_view.aod +++ b/neonView/ProductPreview_view/ProductPreview_view.aod @@ -11,7 +11,7 @@ <children> <cardViewTemplate> <name>Header</name> - <iconField>PICTURE</iconField> + <iconField>#IMAGE</iconField> <titleField>PRODUCTCODE</titleField> <descriptionField>PRODUCTNAME</descriptionField> <favoriteAction1>newActivity</favoriteAction1> -- GitLab