Mobile agent Doubt
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā09-19-2024 03:34 AM
Hi my requirement is In mobile agent there's a state field by default needs to display 2 values(In stock and deploy)and other fields needs to be hidden the below client script is working good in desktop but in mobile agent not working as excepted
(function onLoad() {
var allowedStates = [6, 1]; // 6 = 'In Stock', 1 = 'Deployed'
var allStateValues = [2, 6, 9, 1, 10, 3, 7, 8, 11]; //state values;
for (var i = 0; i < allStateValues.length; i++) {
var state1 = allStateValues[i];
if (allowedStates.indexOf(state1) === -1) {
g_form.removeOption('state', state1);
}
}
})();
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā09-19-2024 07:05 AM
Hi @Bruce lee ,
To make a Catalog Client Script work in both desktop and mobile views (including mobile agent), you need to adjust the UI Type of the script and ensure it's optimized for mobile.
Steps to Address Your Requirement:
Set UI Type to "All" in the Catalog Client Script:
- When you create the Catalog Client Script, youāll notice an option called UI Type.
- By default, it may be set to Desktop, but you can change it to All to ensure the script works for both desktop and mobile.
- Navigate to the Catalog Client Script and set UI Type to All.
Please Make the Changes and if the Issue is Resolved , Please mark as Helpful and accept the Solution
Thanks Regards
Badrinarayan