diff --git a/entity/AttributeFilter_entity/AttributeFilter_entity.aod b/entity/AttributeFilter_entity/AttributeFilter_entity.aod index d23d907b6eb4769ffd40b533343ea221663d2ac4..365718d1c4b0d9e2a46fe82fc910943cd3e64e8e 100644 --- a/entity/AttributeFilter_entity/AttributeFilter_entity.aod +++ b/entity/AttributeFilter_entity/AttributeFilter_entity.aod @@ -21,7 +21,7 @@ </entityField> <entityField> <name>COMPONENT</name> - <title>Component</title> + <title>Search component</title> <consumer>KeywordComponent</consumer> <mandatory v="true" /> <valueProcess>%aditoprj%/entity/AttributeFilter_entity/entityfields/component/valueProcess.js</valueProcess> diff --git a/entity/InboxFilter_entity/InboxFilter_entity.aod b/entity/InboxFilter_entity/InboxFilter_entity.aod index 5f4616f78ac646a858b79f7205f2a28dd5bcf259..cdd385f811b6ce55210bff0e99dc1e7f89cc28f7 100644 --- a/entity/InboxFilter_entity/InboxFilter_entity.aod +++ b/entity/InboxFilter_entity/InboxFilter_entity.aod @@ -20,7 +20,7 @@ </entityField> <entityField> <name>COMPONENT</name> - <title>Component</title> + <title>Search component</title> <consumer>KeywordComponent</consumer> <displayValueProcess>%aditoprj%/entity/InboxFilter_entity/entityfields/component/displayValueProcess.js</displayValueProcess> </entityField> diff --git a/entity/SupportTicketTemplate_entity/SupportTicketTemplate_entity.aod b/entity/SupportTicketTemplate_entity/SupportTicketTemplate_entity.aod index 3be511ca9e18e41d4535ae5011c9784eb3a7710f..55224bb6edc71c401690663acb1d1b644d6f6613 100644 --- a/entity/SupportTicketTemplate_entity/SupportTicketTemplate_entity.aod +++ b/entity/SupportTicketTemplate_entity/SupportTicketTemplate_entity.aod @@ -92,11 +92,12 @@ <name>TEMPLATENO</name> <title>Template No.</title> <contentType>NUMBER</contentType> - <maxValue v="999" /> - <minValue v="1" /> + <outputFormat>000</outputFormat> + <inputFormat>000</inputFormat> <mandatory v="true" /> - <state>READONLY</state> + <state>AUTO</state> <valueProcess>%aditoprj%/entity/SupportTicketTemplate_entity/entityfields/templateno/valueProcess.js</valueProcess> + <onValidation>%aditoprj%/entity/SupportTicketTemplate_entity/entityfields/templateno/onValidation.js</onValidation> </entityField> <entityField> <name>PRIORITY</name> @@ -230,14 +231,16 @@ <title>Individual Answer</title> <contentType>BOOLEAN</contentType> <groupable v="true" /> + <state>AUTO</state> </entityField> <entityField> <name>DOCUMENTTEMPLATE_ID</name> <title>Individual Reply Template</title> <consumer>ReplyDocumentTemplates</consumer> <mandatoryProcess>%aditoprj%/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/mandatoryProcess.js</mandatoryProcess> + <state>INVISIBLE</state> + <stateProcess>%aditoprj%/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/stateProcess.js</stateProcess> <titleProcess>%aditoprj%/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/titleProcess.js</titleProcess> - <displayValueProcess>%aditoprj%/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/displayValueProcess.js</displayValueProcess> </entityField> <entityConsumer> <name>ReplyDocumentTemplates</name> @@ -360,6 +363,10 @@ <recordfield>TICKETTEMPLATE.DOCUMENTTEMPLATE_ID</recordfield> <isFilterable v="false" /> </dbRecordFieldMapping> + <dbRecordFieldMapping> + <name>DOCUMENTTEMPLATE_ID.displayValue</name> + <expression>%aditoprj%/entity/SupportTicketTemplate_entity/recordcontainers/db/recordfieldmappings/documenttemplate_id.displayvalue/expression.js</expression> + </dbRecordFieldMapping> </recordFieldMappings> <linkInformation> <linkInformation> diff --git a/entity/SupportTicketTemplate_entity/entityfields/active_icon/colorProcess.js b/entity/SupportTicketTemplate_entity/entityfields/active_icon/colorProcess.js index 9f6b4ca223fb99248e6dbf1c4dcae2aae67b7682..63d07d348cb8ddb198701710443a2784135055a8 100644 --- a/entity/SupportTicketTemplate_entity/entityfields/active_icon/colorProcess.js +++ b/entity/SupportTicketTemplate_entity/entityfields/active_icon/colorProcess.js @@ -2,16 +2,19 @@ import("system.neon"); import("system.result"); import("system.vars"); -var str_pmtType = vars.get( "$field.ACTIVE"); -var str_ret = ""; -switch( str_pmtType) +if (vars.get( "$field.ACTIVE")) { - case "0": - str_ret = neon.PRIORITY_HIGH_COLOR; - break; - case "1": - str_ret = neon.PRIORITY_LOW_COLOR; - break; + switch( vars.get( "$field.ACTIVE")) + { + case "0": + result.string(neon.PRIORITY_HIGH_COLOR); + break; + case "1": + result.string(neon.PRIORITY_LOW_COLOR); + break; + } +} +else +{ + result.string(neon.PRIORITY_NONE_COLOR); } - -result.string( str_ret); diff --git a/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/displayValueProcess.js b/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/displayValueProcess.js deleted file mode 100644 index 2f5bed9490093a71bcd8def9c8b9a4c0547704e1..0000000000000000000000000000000000000000 --- a/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/displayValueProcess.js +++ /dev/null @@ -1,10 +0,0 @@ -import("Sql_lib"); -import("system.vars"); -import("system.result"); - - -var sql = newSelect("DOCUMENTTEMPLATE.NAME") - .from("DOCUMENTTEMPLATE") - .where("DOCUMENTTEMPLATE.DOCUMENTTEMPLATEID",vars.get("$field.DOCUMENTTEMPLATE_ID")) - .cell(); -result.string(sql.tostring); \ No newline at end of file diff --git a/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/stateProcess.js b/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/stateProcess.js new file mode 100644 index 0000000000000000000000000000000000000000..9eb72a64e4fe6829f84b0ed7a63f522bc9b605ff --- /dev/null +++ b/entity/SupportTicketTemplate_entity/entityfields/documenttemplate_id/stateProcess.js @@ -0,0 +1,13 @@ +import("Util_lib"); +import("system.vars"); +import("system.neon"); +import("system.result"); + +if(Utils.toBoolean(vars.get("$field.INDIVIDUAL_ANSWER"))) +{ + result.string(neon.COMPONENTSTATE_EDITABLE); +} +else +{ + result.string(neon.COMPONENTSTATE_INVISIBLE); +} diff --git a/entity/SupportTicketTemplate_entity/entityfields/templateno/onValidation.js b/entity/SupportTicketTemplate_entity/entityfields/templateno/onValidation.js new file mode 100644 index 0000000000000000000000000000000000000000..1f76109237b6237c5e46e4f532f890f2db3f4884 --- /dev/null +++ b/entity/SupportTicketTemplate_entity/entityfields/templateno/onValidation.js @@ -0,0 +1,17 @@ +import("system.neon"); +import("system.translate"); +import("system.result"); +import("system.vars"); +import("Sql_lib"); + +var sql = new SqlBuilder() + .selectCount("TEMPLATENO") + .from("TICKETTEMPLATE") + .where("TICKETTEMPLATE.TEMPLATENO", vars.get("$field.TEMPLATENO")) + .andIfSet("TICKETTEMPLATE.TICKETTEMPLATEID", vars.get("$field.TEMPLATE_ID"),SqlBuilder.NOT_EQUAL()) + .cell(); + +if (sql > 0) +{ + result.string(translate.text("Number has to be unique") + "."); +} \ No newline at end of file diff --git a/entity/SupportTicketTemplate_entity/entityfields/templateno/valueProcess.js b/entity/SupportTicketTemplate_entity/entityfields/templateno/valueProcess.js index b2ecc35230136b8b184a8610350048e5fb2f22ed..72cfe326b3761f0d83332b6cfd0632e6b4007a55 100644 --- a/entity/SupportTicketTemplate_entity/entityfields/templateno/valueProcess.js +++ b/entity/SupportTicketTemplate_entity/entityfields/templateno/valueProcess.js @@ -1,13 +1,10 @@ import("Util_lib"); import("system.neon"); -import("system.eMath"); import("system.result"); -import("system.db"); import("system.vars"); -var str_templateNo = vars.get( "$field.TEMPLATENO"); -if( !str_templateNo && [neon.OPERATINGSTATE_NEW, neon.OPERATINGSTATE_EDIT].includes( vars.get( "$sys.recordstate"))) +if(!vars.get("$this.value") && vars.get("$sys.recordstate") == neon.OPERATINGSTATE_NEW) { - result.string(NumberSequencingUtils.getNextUniqueNumber("TEMPLATENO", "TICKETTEMPLATE")); + result.string(NumberSequencingUtils.getNextUniqueNumber("TEMPLATENO", "TICKETTEMPLATE",0)); } \ No newline at end of file diff --git a/entity/SupportTicketTemplate_entity/recordcontainers/db/recordfieldmappings/documenttemplate_id.displayvalue/expression.js b/entity/SupportTicketTemplate_entity/recordcontainers/db/recordfieldmappings/documenttemplate_id.displayvalue/expression.js new file mode 100644 index 0000000000000000000000000000000000000000..993f0f5ff4564915f6a2cc4fd3603a9e1eb4037a --- /dev/null +++ b/entity/SupportTicketTemplate_entity/recordcontainers/db/recordfieldmappings/documenttemplate_id.displayvalue/expression.js @@ -0,0 +1,6 @@ +import("Sql_lib"); +import("system.result"); + +result.string(newSelect("NAME") +.from("DOCUMENTTEMPLATE") +.where("DOCUMENTTEMPLATE.DOCUMENTTEMPLATEID = TICKETTEMPLATE.DOCUMENTTEMPLATE_ID").toString()); \ No newline at end of file diff --git a/entity/SupportTicket_entity/SupportTicket_entity.aod b/entity/SupportTicket_entity/SupportTicket_entity.aod index 2a2933e68495dca2ec5179f3001e3838b9ffc35b..d997c1e83686b04061ed92c089dfe041f6730d7a 100644 --- a/entity/SupportTicket_entity/SupportTicket_entity.aod +++ b/entity/SupportTicket_entity/SupportTicket_entity.aod @@ -41,7 +41,6 @@ <groupable v="true" /> <mandatory v="true" /> <stateProcess>%aditoprj%/entity/SupportTicket_entity/entityfields/task_status/stateProcess.js</stateProcess> - <titleProcess>%aditoprj%/entity/SupportTicket_entity/entityfields/task_status/titleProcess.js</titleProcess> <valueProcess>%aditoprj%/entity/SupportTicket_entity/entityfields/task_status/valueProcess.js</valueProcess> <displayValueProcess>%aditoprj%/entity/SupportTicket_entity/entityfields/task_status/displayValueProcess.js</displayValueProcess> <onValueChange>%aditoprj%/entity/SupportTicket_entity/entityfields/task_status/onValueChange.js</onValueChange> @@ -1025,10 +1024,6 @@ <name>TASK_PROGRESS.displayValue</name> <expression>%aditoprj%/entity/SupportTicket_entity/recordcontainers/db/recordfieldmappings/task_progress.displayvalue/expression.js</expression> </dbRecordFieldMapping> - <dbRecordFieldMapping> - <name>TASK_STATUS.displayValue</name> - <expression>%aditoprj%/entity/SupportTicket_entity/recordcontainers/db/recordfieldmappings/task_status.displayvalue/expression.js</expression> - </dbRecordFieldMapping> <dbRecordFieldMapping> <name>TASK_TYPE.value</name> <recordfield>TASK.KIND</recordfield> diff --git a/entity/SupportTicket_entity/entityfields/openadminview/onActionProcess.js b/entity/SupportTicket_entity/entityfields/openadminview/onActionProcess.js index a7200fa50671a7ae517fa732726a43a3f6d6570e..0ae33907cd06d1de07eaa51494cb73aaa2251ee0 100644 --- a/entity/SupportTicket_entity/entityfields/openadminview/onActionProcess.js +++ b/entity/SupportTicket_entity/entityfields/openadminview/onActionProcess.js @@ -4,7 +4,6 @@ import("Context_lib"); AdminViewUtils.open("TICKETID", [ ["TASK_ID", vars.get("$field.TASK_ID")], ["TASK_REQUESTOR_CONTACT_ID", vars.get("$field.TASK_REQUESTOR_CONTACT_ID")], - ["TASK_PARENT_ID", vars.get("$field.TASK_PARENT_ID")], ["TICKET_EDITOR_CONTACT_ID", vars.get("$field.TICKET_EDITOR_CONTACT_ID")], ["MAILSIGNATURE_ID", vars.get("$field.MAILSIGNATURE_ID")], ["INBOX_ID", vars.get("$field.INBOX_ID")], diff --git a/entity/SupportTicket_entity/entityfields/task_status/titleProcess.js b/entity/SupportTicket_entity/entityfields/task_status/titleProcess.js deleted file mode 100644 index bcde88cc195a0f7b4bb80ae7bfc970bd3afe4689..0000000000000000000000000000000000000000 --- a/entity/SupportTicket_entity/entityfields/task_status/titleProcess.js +++ /dev/null @@ -1,15 +0,0 @@ -import("system.translate"); -import("system.vars"); -import("system.neon"); -import("system.result"); - -// FOR CHANGE STATUS ACTION - -var actionName = vars.get("$param.ActionName_param"); -if( (vars.get("$sys.recordstate") == neon.OPERATINGSTATE_EDIT) && actionName ) -{ - if(actionName == "changeStatusAfterForwardEmail") - { - result.string(translate.text("Select new status")); - } -} \ No newline at end of file diff --git a/entity/SupportTicket_entity/recordcontainers/db/onDBUpdate.js b/entity/SupportTicket_entity/recordcontainers/db/onDBUpdate.js index b80e95042cc1410c3b480ff3f4873c8355191fbb..58ba8d1829b48623d7960fd8f4cb0c89954e856b 100644 --- a/entity/SupportTicket_entity/recordcontainers/db/onDBUpdate.js +++ b/entity/SupportTicket_entity/recordcontainers/db/onDBUpdate.js @@ -1,3 +1,4 @@ +import("Context_lib"); import("ActivityTask_lib"); import("system.datetime"); import("system.tools"); diff --git a/entity/SupportTicket_entity/recordcontainers/db/recordfieldmappings/task_status.displayvalue/expression.js b/entity/SupportTicket_entity/recordcontainers/db/recordfieldmappings/task_status.displayvalue/expression.js deleted file mode 100644 index 2ff962697835ef0243dc987da40063bfc1dee5b6..0000000000000000000000000000000000000000 --- a/entity/SupportTicket_entity/recordcontainers/db/recordfieldmappings/task_status.displayvalue/expression.js +++ /dev/null @@ -1,2 +0,0 @@ -// do not use this, because TaskUtils.getTypeStatusKeyword(vars.get("$field.TYPE")) has to be called, which is not possible in a subselect. -// --> only use display value process \ No newline at end of file diff --git a/language/_____LANGUAGE_EXTRA/_____LANGUAGE_EXTRA.aod b/language/_____LANGUAGE_EXTRA/_____LANGUAGE_EXTRA.aod index c0dec5cc101010be254693ba27a95db96b9ec379..22b7b76079dd99b3c8d51651cd37da343ede4aec 100644 --- a/language/_____LANGUAGE_EXTRA/_____LANGUAGE_EXTRA.aod +++ b/language/_____LANGUAGE_EXTRA/_____LANGUAGE_EXTRA.aod @@ -11003,6 +11003,12 @@ <entry> <key>Inbox \"%0\" has been deleted.</key> </entry> + <entry> + <key>Employee group already selected</key> + </entry> + <entry> + <key>Show my finished Tickets in the last 4 weeks</key> + </entry> <entry> <key>Move</key> </entry> diff --git a/language/_____LANGUAGE_de/_____LANGUAGE_de.aod b/language/_____LANGUAGE_de/_____LANGUAGE_de.aod index e87c99efc3226b85b833b9cc34a2eb00945b80af..148dda55e00d4efc36060f0163749bbfe4184c6e 100644 --- a/language/_____LANGUAGE_de/_____LANGUAGE_de.aod +++ b/language/_____LANGUAGE_de/_____LANGUAGE_de.aod @@ -27,6 +27,7 @@ </entry> <entry> <key>Original editor</key> + <value>Originaler Bearbeiter</value> </entry> <entry> <key>Single (Service/External)</key> @@ -9145,6 +9146,7 @@ Bitte Datumseingabe prüfen</value> </entry> <entry> <key>Returned by</key> + <value>Zurückgegeben durch</value> </entry> <entry> <key>My workflow tasks</key> @@ -11837,6 +11839,10 @@ Bitte Datumseingabe prüfen</value> <key>Workshop for project-realization planned</key> <value>Workshop für Projektumsetzung geplannt</value> </entry> + <entry> + <key>Show my finished Tickets in the last 4 weeks</key> + <value>Meine abgeschlossenen Tickets der letzten 4 Tage anzeigen</value> + </entry> <entry> <key>Ticket created through duplication by</key> <value>Ticket durch Duplizierung erstellt. Anwender</value> @@ -13209,6 +13215,7 @@ Bitte Datumseingabe prüfen</value> </entry> <entry> <key>Ticket returned to pool</key> + <value>Ticket zurück in den Pool gegeben</value> </entry> <entry> <key>Contigent exhausted, please buy some new one to continue</key> @@ -14163,6 +14170,7 @@ Bitte Datumseingabe prüfen</value> </entry> <entry> <key>Pull next ticket or create new ones</key> + <value></value> </entry> <entry> <key>Abgeschlossen</key> @@ -14187,6 +14195,7 @@ Bitte Datumseingabe prüfen</value> </entry> <entry> <key>Ticket returned</key> + <value>Ticket zurückgegeben</value> </entry> <entry> <key>Ticket filter</key> @@ -14196,6 +14205,7 @@ Bitte Datumseingabe prüfen</value> </entry> <entry> <key>Pull Ticket</key> + <value>Ticket ziehen</value> </entry> <entry> <key>Service-Admin</key> @@ -14452,6 +14462,9 @@ Bitte Datumseingabe prüfen</value> <entry> <key>Do you really want to resynchronize the user completely?\nThe data in ADITO will be deleted.\nThe outlook contacts must be cleared manually.</key> </entry> + <entry> + <key>Employee group already selected.</key> + </entry> </keyValueMap> <font name="Dialog" style="0" size="11" /> </language> diff --git a/language/_____LANGUAGE_en/_____LANGUAGE_en.aod b/language/_____LANGUAGE_en/_____LANGUAGE_en.aod index ec3bdcc2ffb7a9d70102288e28736633c99ac921..b9ef429fe95d1552c6e6c87134fdf701e1d99ffb 100644 --- a/language/_____LANGUAGE_en/_____LANGUAGE_en.aod +++ b/language/_____LANGUAGE_en/_____LANGUAGE_en.aod @@ -11093,6 +11093,12 @@ <entry> <key>Inbox \"%0\" has been deleted.</key> </entry> + <entry> + <key>Employee group already selected</key> + </entry> + <entry> + <key>Show my finished Tickets in the last 4 weeks</key> + </entry> <entry> <key>Move</key> </entry> diff --git a/neonView/SupportTicketTemplateEdit_view/SupportTicketTemplateEdit_view.aod b/neonView/SupportTicketTemplateEdit_view/SupportTicketTemplateEdit_view.aod index cbf558764db0f8eb25689038bbb8af5b570027a6..56392a16b7bac3a4729d7d9d3be050411858aaf1 100644 --- a/neonView/SupportTicketTemplateEdit_view/SupportTicketTemplateEdit_view.aod +++ b/neonView/SupportTicketTemplateEdit_view/SupportTicketTemplateEdit_view.aod @@ -21,7 +21,7 @@ <entityField>NAME</entityField> </entityFieldLink> <entityFieldLink> - <name>e6f7252c-371d-46df-87eb-2254ea6aa6aa</name> + <name>9cffec22-cf83-4e72-9602-b5bce02def48</name> <entityField>TEMPLATENO</entityField> </entityFieldLink> <entityFieldLink> diff --git a/process/KeywordRegistry_basic/process.js b/process/KeywordRegistry_basic/process.js index cc85d170a716afb3a5e352b754534ce5b5b93330..429ad73d64d95944e75944fa1deeb4e2243fbe92 100644 --- a/process/KeywordRegistry_basic/process.js +++ b/process/KeywordRegistry_basic/process.js @@ -407,6 +407,8 @@ $KeywordRegistry.employeeGroupStatus = function(){return "EmployeeGroupStatus";} $KeywordRegistry.employeeGroupStatus$active = function(){return "ACTIVE";}; $KeywordRegistry.employeeGroupStatus$inactive = function(){return "INACTIVE";}; +$KeywordRegistry.ticketTemplateIndivAnswer$active = function(){return "1";} +$KeywordRegistry.ticketTemplateIndivAnswer$inactive = function(){return "0";} $KeywordRegistry.ticketCategory = function(){return "TicketCategory";} $KeywordRegistry.ticketCategory$undefined = function(){return "UNDEFINED";} $KeywordRegistry.ticketCategory$all = function(){return "ALL";} diff --git a/process/TicketTemplate_lib/process.js b/process/TicketTemplate_lib/process.js index 6d1a536b747424c28057da93fe0ab89da967a54e..0fb6c6aedbf926e2b27dc162eaf83f817c242437 100644 --- a/process/TicketTemplate_lib/process.js +++ b/process/TicketTemplate_lib/process.js @@ -115,6 +115,7 @@ TicketTemplateUtils.checkIndividualAnswer = function (pTemplateId) .from("TICKETTEMPLATE") .join("DOCUMENTTEMPLATE","TICKETTEMPLATE.DOCUMENTTEMPLATE_ID = DOCUMENTTEMPLATE.DOCUMENTTEMPLATEID") .whereIfSet("TICKETTEMPLATE.TICKETTEMPLATEID",pTemplateId) + .and("TICKETTEMPLATE.INDIVIDUAL_ANSWER", $KeywordRegistry.ticketTemplateIndivAnswer$active()) .cell() return sql; } \ No newline at end of file