Fetch customized user inputs, store them globally at the app leve | Community | Zoho Projects

Fetch customized user inputs, store them globally at the app leve | Community | Zoho Projects

This data storage concept enables you to store data related to your extension for both entity properties and extension properties.

In our previous piece, we looked at how to store data for entities using entity properties. In this post, we'll look at an example of using extension properties effectively. Extension properties enable you to record data for an app in its entirety. Refer to this article on the limitations of extension properties for additional details.

Scenario

Let's say that as a developer you want to gather feedback/reviews through your extension. In general, reviews and feedback help you gain insights into users' perspectives.

When designing a review/feedback template, using a standard question with predefined options will restrict the feedback/review process to certain specific standards/requirements. However, your clients may use Zoho Projects to manage a variety of businesses, each with its own set of processes tailored to the needs of that company.

What can you do to standardize and streamline this process for all clients?
It would be beneficial to create a standard feedback/review template for your customers and then enable them to customize the question and its options to meet their own company feedback requirements.

Goal: Create a generic feedback/review template that enables clients to provide their personalized inputs to customize the review/feedback question per their company needs.

Solution

To accomplish this goal, we'll incorporate both entity and app data storage—as well as a few other capabilities—into our extension. Let's look at the features and steps we'll be taking to develop this example.
  • First, we must gather the question and options that the user wants for their feedback/review form. To accomplish this, we can create a bottom navigation bar widget called "Feedback or Review template settings" that enables the user to provide their personalized feedback/review question along with its options as input. We can accomplish this using the widgets approach explained earlier in this post.
  • Next, we must save the values the user provides for the question and options. We can accomplish this by using the data storage extension properties, which will store the data and make it available across the app/extension. (Now that we have the values stored for the entire extension/app, we can retrieve the data and access it across the necessary entities.)
  • In our example, we want to collect feedback/reviews from users for the tasks and issues entities. For this, we can create a widget called "Feedback or Review" in the details page of the task and issue entities, respectively.
  • In this widget, we must populate the question with the options the user previously provided as part of the "Feedback or Review template settings" widget. We can accomplish this by retrieving the previously saved details and displaying them in the relevant entities (tasks and issues, in our example).
  • Once we've displayed the question and options to the user, they can select an option to provide feedback or a review for the entity they're working on.
  • Furthermore, we can save the user's option selection and associate it with the entity. This will enable us to display the previously selected option for that question each time the user accesses the "Feedback or Review" widget, which we can accomplish using the data storage-entity properties concept.
Required components
  • An extension configuration process includes the following:
    • Creating an extension.
    • Configuring the plugin manifest.
    • Setting up the widget code.
  • Bottom navigation bar widget (top_band): Enables the user to input their customized values for the feedback/review template's question and its options.
  • Task details tab widget (task_tab)/Issue details tab (issue_tab): Enables us to fetch and display the value the user enters for the feedback/review template in the respective entities.
Let's explore these components now.

Extension configuration

Extension creation: We've created a new extension for Zoho Projects. Learn more about the steps to create an extension.
                                                                  

Plugin-manifest.json configuration: Once we created the extension, we configured the plugin-manifest.json file to include the widgets. For a more detailed understanding of how to configure the plugin-manifest.json file, refer to our earlier post.

For our extension use case, the plugin-manifest.json file is configured as shown in the screenshot below.

Note: We'll have to set the storage key to true in order for storage space to be allocated in the Zoho Projects product for this extension. By default, the value will be false.
                                                

Setting up the widget code

Now that we've set up the other components, let's move on to writing our widget code and incorporating the data storage feature.

Feedback or Review template settings widget (Bottom navigation bar - top_band) - Enables us to gather personalized user input for the feedback/review template. Please find the index.html code snippet attached in the post.
  • In the code snippet above for the bottom navigation bar widget, the user is presented with two text boxes: one for entering their customized question for feedback/review and the other for entering their customized options, each separated by a comma.
➤ The app.store method in the extension properties is used to store this data against the extension in the form of key-value pairs.
➤ The values for the question and options are constructed as a JSON object and then stored against the key "storedappvalue" using the app.store method.
Note: For user-entered options separated by a comma, these options are converted to an array using the split() method, with the comma serving as the criteria, and then stored against the key.
➤ Finally, when the values are successfully stored after clicking the Add button, the zohoprojects.invoke method is used, and the user is notified with the alert "Data added".
  • Additionally, every time this widget loads, the data stored at the app level in the key "storedappvalue" is obtained using the app.retrieve method.
  • From this retrieved value, any previously stored data against the key "storedappvalue" is removed using the app.remove method.
  • This is done because whenever a user wishes to change their feedback/review question and options, the new data will be added and stored against the key as well. Since we require the newly entered values to be displayed as part of our "Feedback or Review" widget in the tasks and issues entities, the previously stored data is removed, and the new values entered are stored against the key upon clicking on the Add button.

Feedback or Review widget (task details tab - task_tab) - Displays the feedback question and options and enables the user to provide feedback for the entity they're working on. Please find the Taskfeedback.html code snippet attached in the post.
  • In the code snippet above—for task/issue details tab—we're first retrieving the value stored against the extension (in the bottom-band navigation bar) by invoking the app.retrieve method using the key "storedappvalue".
  • From this retrieved value, we fetch the question and its options. The options for the question are displayed in the widget in radio button format, which enables the user to choose one option for the feedback/review question.
  • Once the user chooses an option and clicks the Save button, the data is saved using the entity properties in data storage feature.
➤ Here, the selected review option (selectedreview) value and its index position (selectedoptionnumber) in the radio button element are stored using the entity.store method. We use entity storage here since this value chosen is specific to the entity the user is working on.
  • Every time the widget loads, the chosen value stored using the entity.store method is retrieved using the entity.retrieve method and checked against the radio element options. This allows the chosen value to be enabled and displayed to the user every time the widget loads.
We can use the same snippet across the issue entity as well.

Now that we've completed the setup for both the widgets and have all the extension components ready, let's go ahead and see the output.

Sample output:
                                                

This example demonstrates how to efficiently use data storage for extension properties. The data stored against an extension/app can be retrieved across multiple entities to perform logical functions. Additionally, in this example, we also witnessed code reusability across multiple entities. You may enhance this example by incorporating more than one feedback/review question.

In this way, you can use extension properties to store data across an extension/app. We hope you found this information useful. Follow this space for more insights!

Sign up for a Zoho Developer account and start developing extensions for Zoho Projects using Sigma.

SEE ALSO



    Access your files securely from anywhere



                      Zoho Developer Community




                                              • Desk Community Learning Series


                                              • Digest


                                              • Functions


                                              • Meetups


                                              • Kbase


                                              • Resources


                                              • Glossary


                                              • Desk Marketplace


                                              • MVP Corner


                                              • Word of the Day


                                              • Ask the Experts





                                                        Manage your brands on social media



                                                              Zoho TeamInbox Resources



                                                                  Zoho CRM Plus Resources

                                                                    Zoho Books Resources


                                                                      Zoho Subscriptions Resources

                                                                        Zoho Projects Resources


                                                                          Zoho Sprints Resources


                                                                            Qntrl Resources


                                                                              Zoho Creator Resources



                                                                                  Zoho CRM Resources

                                                                                  • CRM Community Learning Series

                                                                                    CRM Community Learning Series


                                                                                  • Kaizen

                                                                                    Kaizen

                                                                                  • Functions

                                                                                    Functions

                                                                                  • Meetups

                                                                                    Meetups

                                                                                  • Kbase

                                                                                    Kbase

                                                                                  • Resources

                                                                                    Resources

                                                                                  • Digest

                                                                                    Digest

                                                                                  • CRM Marketplace

                                                                                    CRM Marketplace

                                                                                  • MVP Corner

                                                                                    MVP Corner





                                                                                      Design. Discuss. Deliver.

                                                                                      Create visually engaging stories with Zoho Show.

                                                                                      Get Started Now


                                                                                        Zoho Show Resources


                                                                                          Zoho Writer Writer

                                                                                          Get Started. Write Away!

                                                                                          Writer is a powerful online word processor, designed for collaborative work.

                                                                                            Zoho CRM コンテンツ








                                                                                              Nederlandse Hulpbronnen


                                                                                                  ご検討中の方




                                                                                                        • Recent Topics

                                                                                                        • Unexpected Error in Reports (Pivot Chart, Pivot Table)

                                                                                                          Dear Zoho Support Team, I am facing an issue while creating reports (Pivot Chart, Pivot Table, etc.) in Zoho Creator. When I try to access the report, I receive an unexpected error, and an alert message saying "Undefined" appears with the loading UI.
                                                                                                        • Access invoice custom modules data from API

                                                                                                          Hi, I am using $url = "https://www.zohoapis.eu/invoice/v3/invoices"; $opts = ["http" => [method" => "GET",header" => [ "Authorization: Zoho-oauthtoken $accessToken", "X-com-zoho-invoice-organizationid: $orgId" ] ] ]; From my app to retrieve the invoices,
                                                                                                        • Using IMAP configuration for shared email inboxes

                                                                                                          Our customer service team utilizes shared email boxes to allow multiple people to view and handle incoming customer requests. For example, the customer sends an email to info@xxxx.com and multiple people can view it and handle the request. How can I configure
                                                                                                        • Zoho CRM and Google Sync - delete Contacts?

                                                                                                          If I delete a contact in Zoho CRM, will it also be deleted in Google contacts?
                                                                                                        • Customize the ticket ID for enhanced ticket tracking

                                                                                                          Hello everyone, Ticket IDs in Zoho Desk are the unique reference numbers that are assigned to tickets when they're created. Agents generally use the ticket ID to locate a particular ticket and to reference a ticket in conversations and feeds. When customers
                                                                                                        • For Each (Desk Ticket) Loop

                                                                                                          What I need is some sort of "for each" loop functionality in Flow, this doesn't seem to be a thing, but I'm wondering if someone found some sort of workaround? Here's the whole situation: I have a Flow, which is supposed to be triggered by a custom field
                                                                                                        • Turn off/Disable Lead Approval

                                                                                                          Is there a way to disable the need to approve leads? I thought there was but I can't find any reference to it in help, etc. We don't need an approval process for incoming leads at the moment. Thanks.
                                                                                                        • Change colour on task lists?

                                                                                                          I have many task lists on my project boards, since they are all the same colour they blend in with each other. Is there a way to change the colour of these task lists in the list view?
                                                                                                        • Zoho Flow Doesn't Detect Desk Ticket Custom Field Change

                                                                                                          I have a Flow that is configured to be triggered when a custom field on a ticket changes. I also have a Schedule in Desk that runs a script that changes the custom field. When I change the custom field manually in the Desk interface, the Flow runs as
                                                                                                        • invokeURL to change custom field

                                                                                                          I have a deluge script that currently runs as a Schedule. It works exactly as intended, however I've recently been informed by Zoho that there's some mechanism in place to block changes made by a script when it runs on a schedule from being detected by
                                                                                                        • Currency transition

                                                                                                          We are using Zoho CRM in Curacao, Dutch Caribbean. Our currency is currently the ANG. Curacao will be transition ing from using the ANG (Antillean Guilder) to using the XCG currency (Caribbean Guilder) on March 31st 2025, see: https://www.mcb-bank.com/caribbean-guilder.
                                                                                                        • Email transfer to projects

                                                                                                          We are unable to add comment/map documents to this task. WHY DID THIS HAPPEN? The possible reasons are : 1. Email ID not confirmed. To confirm use the link http://zohosso.wiki.zoho.com/#resendconfirmation 2. You do not have permission to add comment/
                                                                                                        • Stop adding Default ID column to xls exports

                                                                                                          When anything is exported to xls, Zoho adds a column with an ID.  WE DO NOT WANT THIS COLUMN.  We use an automated report to a team.  We have our own tracking number.  1. This makes the report messy, it just pushes OUR data off to the right.  2. We have
                                                                                                        • Este domínio já está associado a esta conta

                                                                                                          Fui fazer meu cadastro na zoho e quando digitei meu domínio recebi essa mensagem que meu domínio estava associado a uma conta que eu nem faço idéia de quem seja. Como que faço pra resolver isso? Atenciosamente, Anderson Souza.
                                                                                                        • Transferring Attachments from Lead to Account

                                                                                                          Hi All, I'm trying to create a function that will transfer attachments in leads to the newly created account. I know there's an option to choose where the attachments go when you click the standard convert button but we have a high volume of conversions
                                                                                                        • New Line in Double Optin Email

                                                                                                          Hello, is it possible to add new lines to the double optin email? This is necessary to add legal informations to the mail, which would look very messy if it is all in one line. Thank you in advance Carsten
                                                                                                        • Cursor Keeps Disappearing in the Email Fields

                                                                                                          I did the recent update to the Zoho desktop app - I'm on PC Windows 11. My cursor keeps disappearing when I try to type in the "To" "CC" "Subject" boxes and typing in the body of the email. I've been trying to just tab through the sections instead of
                                                                                                        • Hourly Permission not getting Calculated

                                                                                                          That is our settings The total calculation should be from 9:37 AM to 3:37 PM, but the hourly permission isn't getting calculated The last entry is hourly permission, it's not
                                                                                                        • Client Script field.setCriteria need the list of possible operators for criteria or the opposite of "equal"

                                                                                                          The gist is to just filter the lookup the countries not listed in the multiselect field. I've been using a client script and this time I would like to set this criteria for the lookup: op.setCriteria("((Specialty_Requirement:equals:" + spec + ")and(Countries_Excluded:not_equal:"
                                                                                                        • Highlight a candidate who is "off limits"

                                                                                                          Hello: Is there a way to highlight a candidate who is "off limits"?  I would like to have the ability to make certain candidate and / or Client records highlighted in RED or something like that.   This would be used for example when we may have placed a candidate somewhere and we want everyone in our company to quickly and easily see that they are off limits.  The same would apply when we want to put a client or former client off limits so no one recruits out of there. How can this be done? Cheers,
                                                                                                        • old invoices (Exchange rate)

                                                                                                          We have been facing an issue and searching for a solution for over a month. Issue: Previously, the exchange rate in Zoho Books and Zoho CRM was incorrect, and invoices were being recorded in Zoho CRM with the wrong exchange rate. After adjusting the exchange
                                                                                                        • Zoho Mail Android app update - View emails shared via Permalink on the app.

                                                                                                          Hello everyone! In the latest version(v2.8.2) of the Zoho Mail Android app update, we have brought in support to access the emails shared via permalink within the app. Earlier, when you click the permalink of an email, you'll be redirected to a mobile
                                                                                                        • How to download Renamed File that already updated to Zoho Creator.

                                                                                                          Hi members, I construct a button with report workflow. link = "https://creatorexport.zoho.com" + zoho.appuri + "report_link_name/File_upload/image-download/" + input.File_upload; openUrl(link,"new window"); This script able to download the file. But I
                                                                                                        • Email signature duplicate

                                                                                                          Hi, For a few weeks, opening the email writer would show an error. After clicking ok, the signature would change slighty (font size, I believe). After that it worked fine, so we thought nothing of it. However, now it no longer shows the error puts the
                                                                                                        • Set a global default filter to All Candidates view

                                                                                                          Hi, Is it possible to set a global filter to the All Candidates view? As a use case would be for off-limit candidates. These are those who are off limits due to previous bad client feedback on performance/behaviour. Ideal use case would be to set these
                                                                                                        • Merge Join PDFs Zoho Creator

                                                                                                          Hi all, I have a field where users upload PDF, is it possible to join those pdfs into one with a function or something? Regards.
                                                                                                        • Custom Sign-in and Sign-out

                                                                                                          I've had a number of users ask me "how do I sign-out" when the sign-out link is clearly on the upper right of the page. To make it more obvious, you can use this bit of code to make a sign-out button on the top of any HTML view. You can customize the serviceurl as needed. <a class="zc-formbutton" style="padding: 5px;font-size:12px;" href="https://accounts.zoho.com/logout?serviceurl=https://creator.zoho.com/<%=zoho.adminuser%>/<%=zoho.appname%>/">Sign-Out</a> And since we're on this topic, you can
                                                                                                        • Tip 26: How to hide the "Submit" button from a form

                                                                                                          Hi everyone, Hope you're staying safe and working from home. We are, too. By now, we at Zoho are all very much accustomed to the new normal—working remotely. Today, we're back with yet another simple but interesting tip--how to hide the Submit button from your forms. In certain scenarios, you may want to hide the submit button from a form until all the fields are filled in.  Use case In this tip, we'll show you how to hide the Submit button while the user is entering data into the form, and then
                                                                                                        • Disappearing Mouse cursor in Zoho Mail / Windows 11 (Chrome + Edge)

                                                                                                          I'm seeing an issue when writing mails with the light theme with the mouse cursor being white and the document area also being white - making it nearly impossible to see the mouse cursor. I see the problem on Windows 11 under Chrome and Edge. (Yet to
                                                                                                        • Introducing Dark Mode / Light Mode : A New Look For Your CRM

                                                                                                          Hello Users, We are excited to announce a highly anticipated feature - the launch of Day, Night and Auto Mode implementation in Zoho CRM's NextGen user interface! This feature is designed to provide a visually appealing and comfortable experience for
                                                                                                        • People 5.0 widget and API questions

                                                                                                          While creating Widget for People 5 I found couple issues that I can’t find answer on my own: 1) How to get leave requests according to this API https://www.zoho.com/people/api/get-records-v2.html. I tried: requestData = { "url": "https://people.zoho.eu/api/v2/leavetracker/leaves/records",
                                                                                                        • Enhancements for Creator in Mobile Browsers and PWAs

                                                                                                          ZC Team, Lady & Gentlemen! This enhancement has been awaited for a thousand years, and it has made my day! It now appears more "enterprise" and no longer a jerk.
                                                                                                        • Zoho CRM Functions 53: Automatically name your Deals during lead conversion.

                                                                                                          Welcome back everyone! Last week's function was about automatically updating the recent Event date in the Accounts module. This week, it's going to be about automatically giving a custom Deal name whenever a lead is converted. Business scenario Deals are the most important records in CRM. After successful prospecting, the sales cycle is followed by deal creation, follow-up, and its subsequent closure. Being a critical function of your sales cycle, it's good to follow certain best practices. One such
                                                                                                        • Perfomance Management - Zoho People

                                                                                                          Hi team, I am looking for performance management data such as KRA, goals, feedback, appraisals, etc., in Zoho Analytics. However, I am unable to find these metrics while editing the setup. Could you please confirm whether these fields are available in
                                                                                                        • Client Script - Updating Field Value in Detail Page of a Lead

                                                                                                          Hello, I'm trying to use Client Script To enrich some data of the Lead when one of my User fill the "City" field in the detail page of the Lead. This is my Script: log (value); var response = ZDK.Apps.CRM.Functions.execute("getInfoCitta", { "nomeCitta":
                                                                                                        • Sales Returns - Repairand Return

                                                                                                          Hi Inventory Team, I'm working with a client on an Inventory implementation project and they have shared this use case with me. Some items may be returned by the customer, then returned to the vendor for repairs, received from the vendor and shipped back
                                                                                                        • Zoho One and Zoho Learn

                                                                                                          Is Zoho Learn going to become part of Zoho One? If not, why not? Also, if not, what is the closest product offered in the One bundle which is comparable to Zoho Learn? Please help me understand the overall relationship between Zoho Learn and Zoho One.
                                                                                                        • Creating task at someones date of birth

                                                                                                          Hi, I want to create a workflow which creates a task at someones date of birth. How can I do this?
                                                                                                        • Client scripts for Zoho Books ?

                                                                                                          Good day everyone, I am looking for a way to be able to interact with the Quotes and Invoices as they are being created. Think of it like Zoho client script in Zoho CRM. But for the life of me I dont see a way to do this. The issue with having function
                                                                                                        • Desk Contact Name > split to First and Last name

                                                                                                          I am new to Zoho and while setting up the Desk and Help Center, I saw that new tickets created or submitted from the Help Center used the Contact Name field. This would create a new Contact but put the person's name in the Last Name field only. The First
                                                                                                        • Next Page