diff --git a/.liquibase/Data_alias/basic/2019.1.4/changelog.xml b/.liquibase/Data_alias/basic/2019.1.4/changelog.xml index 4a4a9e34293722e9259185911b460a68968b0f9d..6c8dd17bcf0efb55e2d382e92de0b5677588e581 100644 --- a/.liquibase/Data_alias/basic/2019.1.4/changelog.xml +++ b/.liquibase/Data_alias/basic/2019.1.4/changelog.xml @@ -94,7 +94,6 @@ <include relativeToChangelogFile="true" file="constraintsRefactor/indices_Activity.xml"/> <include relativeToChangelogFile="true" file="constraintsRefactor/indices_Task.xml"/> - <include relativeToChangelogFile="true" file="update_Keyword_Essentials.xml" /> <include relativeToChangelogFile="true" file="Contactmanagement_added_ImageBlobs.xml" /> <include relativeToChangelogFile="true" file="alter_activityLink.xml" /> @@ -161,4 +160,6 @@ <include relativeToChangelogFile="true" file="create_description_translation.xml"/> <include relativeToChangelogFile="true" file="remove_productInfo_language.xml"/> + + <include relativeToChangelogFile="true" file="update_Keyword_Essentials.xml"/> </databaseChangeLog> diff --git a/.liquibase/Data_alias/basic/2019.1.4/update_Keyword_Essentials.xml b/.liquibase/Data_alias/basic/2019.1.4/update_Keyword_Essentials.xml index 42e86e904cace377c5d5b0938759eaddb7c5840f..2a81caa90f8217a62d3cde44d9169899531ea189 100644 --- a/.liquibase/Data_alias/basic/2019.1.4/update_Keyword_Essentials.xml +++ b/.liquibase/Data_alias/basic/2019.1.4/update_Keyword_Essentials.xml @@ -3,15 +3,59 @@ <changeSet author="a.loreth" id="b1629529-92ab-437d-b864-0fd68fe5ceab"> <update tableName="AB_KEYWORD_ENTRY"> <column name="ISESSENTIAL" valueNumeric="1" /> - <where>KEYID in ('QUANTITYPIECES', 'i', 'o', 'CONTACTSTATACTIVE', 'NEW', 'TASK', 'PRICELISTDEFAULT', 'TASKPRIONORMAL', 'TASKPROG0')</where> - </update> - - - <rollback> - <update tableName="AB_KEYWORD_ENTRY"> - <column name="ISESSENTIAL" valueNumeric="0" /> - <where>KEYID in ('QUANTITYPIECES', 'i', 'o', 'CONTACTSTATACTIVE', 'NEW', 'TASK', 'PRICELISTDEFAULT', 'TASKPRIONORMAL', 'TASKPROG0')</where> - </update> - </rollback> + <where>CONTAINER = 'QuantityUnit' and KEYID in ('QUANTITYPIECES ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'ActivityDirection' and KEYID in ('i ', 'o ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'ContactStatus' and KEYID in ('CONTACTSTATACTIVE ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'TaskStatus' and KEYID in ('NEW ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'TaskType' and KEYID in ('TASK ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'ProductPricelist' and KEYID in ('PRICELISTDEFAULT ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'TaskPriority' and KEYID in ('TASKPRIOMEDIUM ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'TaskProgress' and KEYID in ('TASKPROG0 ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'ContractStatus' and KEYID in ('CONTRACTSTATVALIDUNLI ', 'CONTRACTSTATVALIDLI ', 'CONTRACTSTATSIGN ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'SalesprojectState' and KEYID in ('SALPROJSTATOPEN ', 'SALPROJSTATPOSTPONED ')</where> + </update> + + <update tableName="AB_KEYWORD_ENTRY"> + <column name="ISESSENTIAL" valueNumeric="1" /> + <where>CONTAINER = 'TaskStatus' and KEYID in ('NEW ', 'ASSIGNED ', 'IN-PROGRESS ', 'WAITING ', 'ENDED ', 'CUSTOMER-CHECKS ', 'UNASSIGNED ')</where> + </update> + + </changeSet> </databaseChangeLog> diff --git a/entity/Task_entity/entityfields/keywordstates/children/whitelistids_param/valueProcess.js b/entity/Task_entity/entityfields/keywordstates/children/whitelistids_param/valueProcess.js index 82820e3158ff5a5eba0f8340bbf49f34891d31dd..03b66f45bd45fd69ac03a36d21907b6bd3c537b4 100644 --- a/entity/Task_entity/entityfields/keywordstates/children/whitelistids_param/valueProcess.js +++ b/entity/Task_entity/entityfields/keywordstates/children/whitelistids_param/valueProcess.js @@ -3,7 +3,7 @@ import("KeywordRegistry_basic"); result.object([ $KeywordRegistry.taskStatus$new(), - $KeywordRegistry.taskStatus$inProcess(), + $KeywordRegistry.taskStatus$inProgress(), $KeywordRegistry.taskStatus$waiting(), $KeywordRegistry.taskStatus$ended() ]); \ No newline at end of file diff --git a/process/Context_lib/process.js b/process/Context_lib/process.js index 04e5cd8b2c71d90a7ef81d3f923f792e3a588995..78ce55472f5a7be0ed3aa9e8778d1c4e8f07ef9c 100644 --- a/process/Context_lib/process.js +++ b/process/Context_lib/process.js @@ -405,7 +405,7 @@ ContextUtils.getSelectMap = function() .setContactIdField("CONTACT_ID") .setCreationDateField("CONTRACTSTART") .setStateField("CONTRACTSTATUS") - .setActiveStates(["e12d37e9-3429-40b5-973b-c1569843ca46", "3579eb0c-d8ca-4b6b-85ee-f1800a9301eb", "4c63c82d-0276-4c12-9937-13fd361ad786"]) + .setActiveStates([$KeywordRegistry.contractState$validLimited(), $KeywordRegistry.contractState$validUnlimited(), $KeywordRegistry.contractState$notSigned()]) ,"Offer": ContextSelector.create("OFFER", "OFFERID") .setTitleExpression(maskingUtils.concat([ "'" + translate.text("Offer") + "'", @@ -444,14 +444,21 @@ ContextUtils.getSelectMap = function() "left join CAMPAIGNSTEP on CAMPAIGNSTEP.CAMPAIGNSTEPID = CAMPAIGNPARTICIPANT.CAMPAIGNSTEP_ID") .setCreationDateField("CAMPAIGNSTEP.DATE_START") .setStateField("CAMPAIGN.STATE") - .setActiveStates(["e04c9c59-0590-463c-a10e-e25c583e9cf2", "42e1ee2b-0108-4ccf-ab43-29cbcb0377bf"]) + .setActiveStates([$KeywordRegistry.campaignState$planning(), $KeywordRegistry.campaignState$approved()]) ,"CampaignStep" : ContextSelector.create("CAMPAIGNSTEP", "CAMPAIGNSTEPID", "NAME") ,"SupportTicket": ContextSelector.create("TICKET", "TICKETID", "TASK.SUBJECT") .setJoinExpression("left join TASK on TASK.TASKID = TICKET.TASK_ID") .setCondition(SqlCondition.begin().andPrepare("TICKET.TICKETTYPE", $KeywordRegistry.ticketType$supportTicket())) .setContactIdField("TASK.REQUESTOR_CONTACT_ID") .setStateField("TASK.STATUS") - .setActiveStates([$KeywordRegistry.taskStatus$new(), $KeywordRegistry.taskStatus$inProcess()]) + .setActiveStates([ + $KeywordRegistry.taskStatus$new(), + $KeywordRegistry.taskStatus$unassigned(), + $KeywordRegistry.taskStatus$assigned(), + $KeywordRegistry.taskStatus$inProgress(), + $KeywordRegistry.taskStatus$waiting(), + $KeywordRegistry.taskStatus$customerChecks(), + ]) .setCreationDateField("TASK.START_DATE") } } diff --git a/process/KeywordRegistry_basic/process.js b/process/KeywordRegistry_basic/process.js index 0de7e18283759d5840cebabdf51bf6df63134f22..6bc74160cf2c26584a293783eac3ef7f3dc2c66d 100644 --- a/process/KeywordRegistry_basic/process.js +++ b/process/KeywordRegistry_basic/process.js @@ -21,6 +21,9 @@ $KeywordRegistry.attributeType = function(){return "AttributeType";}; $KeywordRegistry.keywordAttributeType = function(){return "KeywordAttributeType";}; $KeywordRegistry.contractPayment = function(){return "ContractPayment";}; $KeywordRegistry.contractStatus = function(){return "ContractStatus";}; +$KeywordRegistry.contractState$validLimited = function(){return "CONTRACTSTATVALIDLI ";}; +$KeywordRegistry.contractState$validUnlimited = function(){return "CONTRACTSTATVALIDUNLI ";}; +$KeywordRegistry.contractState$notSigned = function(){return "CONTRACTSTATSIGN ";}; $KeywordRegistry.contractType = function(){return "ContractType";}; $KeywordRegistry.activityDirection = function(){return "ActivityDirection";}; @@ -45,9 +48,12 @@ $KeywordRegistry.personGender = function(){return "PersonGender";}; $KeywordRegistry.taskStatus = function(){return "TaskStatus";}; $KeywordRegistry.taskStatus$new = function(){return "NEW ";}; -$KeywordRegistry.taskStatus$inProcess = function(){return "IN-PROGRESS ";}; +$KeywordRegistry.taskStatus$unassigned = function(){return "UNASSIGNED ";}; +$KeywordRegistry.taskStatus$assigned = function(){return "ASSIGNED ";}; +$KeywordRegistry.taskStatus$inProgress = function(){return "IN-PROGRESS ";}; $KeywordRegistry.taskStatus$waiting = function(){return "WAITING ";}; $KeywordRegistry.taskStatus$ended = function(){return "ENDED ";}; +$KeywordRegistry.taskStatus$customerChecks = function(){return "CUSTOMER-CHECKS ";}; $KeywordRegistry.taskType = function(){return "TaskType";}; $KeywordRegistry.taskType$task = function(){return "TASK";}; @@ -64,12 +70,6 @@ $KeywordRegistry.quantityUnit$pieces = function(){return "QUANTITYPIECES";}; $KeywordRegistry.MemberRole = function(){return "MemberRole";}; $KeywordRegistry.salesprojectSource = function(){return "SalesprojectSource";}; $KeywordRegistry.salesorderState = function(){return "SalesorderState";}; -$KeywordRegistry.salesorderState$open = function(){return "SALPROJSTATOPEN ";}; -$KeywordRegistry.salesorderState$postponed = function(){return "SALPROJSTATPOSTPONED ";}; -$KeywordRegistry.salesorderState$aborted = function(){return "SALPROJSTATABORT ";}; -$KeywordRegistry.salesorderState$partialOrder = function(){return "SALPROJSTATPARTIAL ";}; -$KeywordRegistry.salesorderState$order = function(){return "SALPROJSTATORDER ";}; -$KeywordRegistry.salesorderState$lost = function(){return "SALPROJSTATLOST ";}; $KeywordRegistry.salesprojectWonLost = function(){return "SalesprojectWonLost";}; $KeywordRegistry.stockWarehouse = function(){return "StockWarehouse";}; $KeywordRegistry.salesprojectProbability = function(){return "SalesprojectProbability";}; @@ -85,6 +85,12 @@ $KeywordRegistry.salesprojectPricePolitics = function(){return "SalesprojectPric $KeywordRegistry.salesprojectWeakness = function(){return "SalesprojectWeakness";}; $KeywordRegistry.salesprojectStrenght = function(){return "SalesprojectStrenght";}; $KeywordRegistry.salesprojectState = function(){return "SalesprojectState";}; +$KeywordRegistry.salesprojectState$open = function(){return "SALPROJSTATOPEN ";}; +$KeywordRegistry.salesprojectState$postponed = function(){return "SALPROJSTATPOSTPONED ";}; +$KeywordRegistry.salesprojectState$aborted = function(){return "SALPROJSTATABORT ";}; +$KeywordRegistry.salesprojectState$partialOrder = function(){return "SALPROJSTATPARTIAL ";}; +$KeywordRegistry.salesprojectState$order = function(){return "SALPROJSTATORDER ";}; +$KeywordRegistry.salesprojectState$lost = function(){return "SALPROJSTATLOST ";}; $KeywordRegistry.salesprojectPhase = function(){return "SalesprojectPhase";}; $KeywordRegistry.taskPriority = function(){return "TaskPriority";}; $KeywordRegistry.taskPriority$none = function(){return "TASKPRIONONE";}; @@ -101,9 +107,10 @@ $KeywordRegistry.contactDepartment = function(){return "ContactDepartment";}; $KeywordRegistry.contactPosition = function(){return "ContactPosition";}; $KeywordRegistry.contactContactrole = function(){return "ContactContactrole";}; $KeywordRegistry.campaignState = function(){return "CampaignManagementStates";}; -$KeywordRegistry.campaignState$planning = function(){return "PLANNING";}; +$KeywordRegistry.campaignState$planning = function(){return "PLANNING ";}; +$KeywordRegistry.campaignState$approved = function(){return "APPROVED ";}; $KeywordRegistry.campaignStepState = function(){return "CampaignManagementStepStates";}; -$KeywordRegistry.campaignStepState$open = function(){return "OPEN";}; +$KeywordRegistry.campaignStepState$open = function(){return "OPEN ";}; $KeywordRegistry.campaignStepCostCategory = function(){return "CampaignManagementCostCategory";}; $KeywordRegistry.documentTemplateType = function(){return "DocumentTemplateType";}; $KeywordRegistry.documentTemplateType$letter = function(){return "LET ";};