message_admin - Fetch 'workflow_name' when displaying list view
authorTim Otten <totten@civicrm.org>
Tue, 11 Jul 2023 03:35:08 +0000 (20:35 -0700)
committerTim Otten <totten@civicrm.org>
Tue, 11 Jul 2023 03:57:25 +0000 (20:57 -0700)
ext/message_admin/ang/crmMsgadm/Workflow.js

index 5b4bb42b552be7e8643651770ae95018977db756..926f5f5e3a3c0e15117b9e41e8ecfbd2b4b37440 100644 (file)
           prefetch: function(crmApi4, crmStatus) {
             var q = crmApi4({
               records: ['MessageTemplate', 'get', {
-                select: ["id", "msg_title", "is_default", "is_active"],
+                select: ["id", "msg_title", "is_default", "is_active", "workflow_name"],
                 where: [["workflow_name", "IS NOT EMPTY"], ["is_reserved", "=", "0"]]
               }],
               translations: ['MessageTemplate', 'get', {
-                select: ["id", "msg_title", "is_default", "is_active", "tx.language:label", "tx.language"],
+                select: ["id", "msg_title", "is_default", "is_active", "workflow_name", "tx.language:label", "tx.language"],
                 join: [["Translation AS tx", "INNER", null, ["tx.entity_table", "=", "'civicrm_msg_template'"], ["tx.entity_id", "=", "id"]]],
                 where: [["workflow_name", "IS NOT EMPTY"], ["is_reserved", "=", "0"]],
                 groupBy: ["id", "tx.language"],