From 392845583ebea5413827785641a2674c8956f584 Mon Sep 17 00:00:00 2001 From: Jenny Schweers Date: Tue, 14 Jan 2025 14:06:41 -0500 Subject: [PATCH 1/6] Added explicit dependencies to app_manager/js/modules/case_list_setting --- .../static/app_manager/js/modules/case_list_setting.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/corehq/apps/app_manager/static/app_manager/js/modules/case_list_setting.js b/corehq/apps/app_manager/static/app_manager/js/modules/case_list_setting.js index 71194eb70610..f95b694fbdb3 100644 --- a/corehq/apps/app_manager/static/app_manager/js/modules/case_list_setting.js +++ b/corehq/apps/app_manager/static/app_manager/js/modules/case_list_setting.js @@ -1,4 +1,10 @@ -hqDefine("app_manager/js/modules/case_list_setting", function () { +hqDefine("app_manager/js/modules/case_list_setting", [ + 'jquery', + 'underscore', +], function ( + $, + _ +) { function getLabel(slug) { return $('.case-list-setting-label[data-slug="' + slug + '"]'); } function getShow(slug) { return $('.case-list-setting-show[data-slug="' + slug + '"]'); } function getMedia(slug) { return $('.case-list-setting-media[data-slug="' + slug + '"]'); } From fc57e7bfde2dc083e02180838aca667bf2d51355 Mon Sep 17 00:00:00 2001 From: Jenny Schweers Date: Tue, 14 Jan 2025 14:07:35 -0500 Subject: [PATCH 2/6] Added explicit dependencies to app_manager/js/modules/shadow_module_settings --- .../app_manager/js/modules/shadow_module_settings.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/corehq/apps/app_manager/static/app_manager/js/modules/shadow_module_settings.js b/corehq/apps/app_manager/static/app_manager/js/modules/shadow_module_settings.js index 365463004248..952facb740a3 100644 --- a/corehq/apps/app_manager/static/app_manager/js/modules/shadow_module_settings.js +++ b/corehq/apps/app_manager/static/app_manager/js/modules/shadow_module_settings.js @@ -1,4 +1,10 @@ -hqDefine('app_manager/js/modules/shadow_module_settings', function () { +hqDefine('app_manager/js/modules/shadow_module_settings', [ + 'knockout', + 'underscore', +], function ( + ko, + _, +) { const module = { /** From 6f02c94b758ffc6dce27fc07cb62254ddb23bc7e Mon Sep 17 00:00:00 2001 From: Jenny Schweers Date: Wed, 15 Jan 2025 11:58:32 -0500 Subject: [PATCH 3/6] Added explicit dependencies to app_manager/js/section_changer --- .../app_manager/static/app_manager/js/section_changer.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/corehq/apps/app_manager/static/app_manager/js/section_changer.js b/corehq/apps/app_manager/static/app_manager/js/section_changer.js index c1fcb7f1d50d..fd74fcd5676e 100644 --- a/corehq/apps/app_manager/static/app_manager/js/section_changer.js +++ b/corehq/apps/app_manager/static/app_manager/js/section_changer.js @@ -32,7 +32,11 @@ * When the user shows or hides a section, that preference is stored in localStorage. */ -hqDefine("app_manager/js/section_changer", function () { +hqDefine("app_manager/js/section_changer", [ + 'jquery', +], function ( + $ +) { // Determine key for localStorage // page is something like "module-view" // section is something like "logic" From eb7e5f2d1c0cf06a17ec7522621979b1b9d14f08 Mon Sep 17 00:00:00 2001 From: Jenny Schweers Date: Mon, 20 Jan 2025 18:05:56 -0500 Subject: [PATCH 4/6] Added explicit dependencies to app_manager/js/forms/custom_instances --- .../static/app_manager/js/forms/custom_instances.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/corehq/apps/app_manager/static/app_manager/js/forms/custom_instances.js b/corehq/apps/app_manager/static/app_manager/js/forms/custom_instances.js index 7ddcf26a147f..3a7df2e4c35f 100644 --- a/corehq/apps/app_manager/static/app_manager/js/forms/custom_instances.js +++ b/corehq/apps/app_manager/static/app_manager/js/forms/custom_instances.js @@ -1,7 +1,8 @@ -"use strict"; -hqDefine('app_manager/js/forms/custom_instances', function () { - 'use strict'; - +hqDefine("app_manager/js/forms/custom_instances", [ + "knockout", +], function ( + ko, +) { var customInstance = function (instanceId, instancePath) { var self = {}; self.instanceId = ko.observable(instanceId || ''); From 1a88351fe90ae3a1fe95c849c97cabc2f59b18a5 Mon Sep 17 00:00:00 2001 From: Jenny Schweers Date: Mon, 20 Jan 2025 18:15:08 -0500 Subject: [PATCH 5/6] Added explicit dependencies to app_manager/js/details/filter --- .../app_manager/static/app_manager/js/details/filter.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/corehq/apps/app_manager/static/app_manager/js/details/filter.js b/corehq/apps/app_manager/static/app_manager/js/details/filter.js index 79551376d0f6..33f9e1d19db3 100644 --- a/corehq/apps/app_manager/static/app_manager/js/details/filter.js +++ b/corehq/apps/app_manager/static/app_manager/js/details/filter.js @@ -1,3 +1,8 @@ +hqDefine("app_manager/js/details/filter", [ + "knockout", +], function ( + ko, +) { /** * Model for the case list filter, which has a button to * "Add Filter" when there's no filter, and when clicked @@ -6,7 +11,6 @@ * @param filterText Initial text of the filter * @param saveButton Save button for case list config */ -hqDefine("app_manager/js/details/filter", function () { return function (filterText, saveButton) { var self = {}; self.filterText = ko.observable(typeof filterText === "string" && filterText.length > 0 ? filterText : ""); From 59fb2daa75b49b1f4bceb5f7ce80a6958866bef5 Mon Sep 17 00:00:00 2001 From: Jenny Schweers Date: Mon, 20 Jan 2025 18:15:27 -0500 Subject: [PATCH 6/6] Added explicit dependencies to app_manager/js/details/fixture_select --- .../static/app_manager/js/details/fixture_select.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/corehq/apps/app_manager/static/app_manager/js/details/fixture_select.js b/corehq/apps/app_manager/static/app_manager/js/details/fixture_select.js index 3d6e504cc31f..577b14459b5f 100644 --- a/corehq/apps/app_manager/static/app_manager/js/details/fixture_select.js +++ b/corehq/apps/app_manager/static/app_manager/js/details/fixture_select.js @@ -1,7 +1,11 @@ /** * Model for Lookup Table Case Selection in case list configuration. */ -hqDefine("app_manager/js/details/fixture_select", function () { +hqDefine("app_manager/js/details/fixture_select", [ + "knockout", +], function ( + ko, +) { return function (init) { var self = {}; self.active = ko.observable(init.active); @@ -17,4 +21,4 @@ hqDefine("app_manager/js/details/fixture_select", function () { }); return self; }; -}); \ No newline at end of file +});