How to customize the tickets module for the ASAP iOS SDK?

How to customize the tickets module for the ASAP iOS SDK?

These methods help you configure the Submit Ticket form in the way you want it to be on the ASAP help widget.

Hiding fields in the Submit Ticket form

The Submit Ticket form in your ASAP help widget displays the same fields configured in the ticket layout on your Zoho Desk portal.

To hide any fields in the form, use the setFieldsListTobeShown method:

Swift

  1. ZDPortalSubmitTicket.setFieldsListTobeShown(fields: <#T##[ZDVisibleTicketField]#>)

Objective-C

  1. [ZDPortalSubmitTicket setFieldsListTobeShownWithFields:<#(NSArray<ZDVisibleTicketField *> * _Nonnull)#>]
Here, ZDVisibleTicketField is an object that has three main properties:

1. departmentId: String - ID of the department in which you want to configure the Ticket Fields. 

2. layoutId: String - ID of the particular layout for which you want to configure the Ticket Fields. 

3. fieldNames: Array<String> - Name of the ticket fields you want to show in your ticket layout.

After you include this method, the form displays only the fields you passed.

Notes
However, remember that mandatory fields are hidden even if you do not pass their names in the method.

Hiding mandatory fields in the Submit Ticket form 

If you want to hide a mandatory field in the form, you can do so, provided the field's value is pre-filled. To do this, you must use the preFillTicketFields method. The preFillTicketFields method proves helpful when populating fields with values, such as auto-generated IDs or device OS versions.

To use this method, you must pass the list of PreFillTicketField objects and the departmentId key, depending on the help widget's department mapping:

Swift

  1. ZDPortalSubmitTicket.preFillTicketFields(forForms: <#[ZDCustomizedTicketForm]#>)

Objective-C

  1. [ZDPortalSubmitTicket preFillTicketFieldsForForms:<#[ZDCustomizedTicketForm]#>];

The ZDCustomizedTicketForm is an object that has three main properties: 


1. departmentId: String - ID of the department in which you want to configure the Ticket Fields. 

2. layoutId: String - ID of the particular layout for which you want to configure the Ticket Fields. 

3. customizedFields: Array<ZDCustomizedTicketField> - List of field objects to prefill the Ticket Fields.


The ZDCustomizedTicketField is an object that contains three main properties:

1. fieldNames: String - the APIName of the ticket field. You can retrieve the APIName of each field using the getTicketForm() method.
2. value: String - the format is mentioned below.
  1. Pass the values allowed as a comma(,) separated string for multi-select fields.
  2. Pass one of the values allowed as a string for pick list fields.
    For date fields, pass the value as a string in the MM/dd/yyyy format.
  3. For dateTime fields, pass the value as a string in the MM-dd-yyyy hh: mm aa format.
  4. For Boolean fields, pass a String value("true"/"false").
  5. For all other field types, pass the values as string objects.
  6. Make sure that the values you pass here are the max length and decimal restrictions defined for the field.
3. isEditable: Bool - Key that defines if the value in the field is editable or not.
NotesFor more details, check the sample here.

Submit a Ticket event with a subscription

To subscribe your app to the Submit Ticket event, use the following method, which involves an event callback:

Swift

  1. ZDPortalSubmitTicket.getCallbackOnCreateTicket
    { ticket in
    // will get ticket object on success
    }
    onError:
    { error in
    // will get error on failure
    }

Objective-C

  1. [ZDPortalSubmitTicket getCallbackOnCreateTicketWithCompletion:^(ZDPTicket * ticket)
    {
    // will get ticket object on success
    } onError:^(NSError * error)
    {
    // will get error on failure
    }];
Notes
All ticket details are sent to your app if an authenticated user submits a ticket. Only the ticket number is sent if a guest user submits a ticket.

Custom-configuring Ticket actions

Users can perform various actions, including replying to, commenting, and closing tickets.

The following method helps you define which actions must be allowed and which must be disallowed when users access the ticket submission screen on the ASAP help widget:

Swift

  1. ZDPTicketConfiguration.configure.isAddTicketAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isReplyAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCommentAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCommentEditAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isTicketUpdateAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCommentDeleteAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCustomerHappinessThreadAllowed = <#Bool#>

Objective-C

  1. ZDPTicketConfiguration.configure.isAddTicketAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isReplyAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCommentAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCommentEditAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isTicketUpdateAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCommentDeleteAllowed = <#Bool#>
    ZDPTicketConfiguration.configure.isCustomerHappinessThreadAllowed = <#Bool#>

Updating user details

The following API helps update the details of users added to your help desk portal:

Swift

  1. import ZohoDeskPortalAPIKit
        ...
        var body = [String : Any]()
        body["displayName"] = "displayName"
        body["mobile"] = "123456"

    ZohoDeskPortalSDK.updateUserInformation(with: body)
    { profile, error in
    // on success only profile will return a value, error will return nil
    // on failure only error will return a value, profile will return nil
    }

Objective-C

  1. NSMutableDictionary * body = [NSMutableDictionary new];
        [body setObject:@"displayName" forKey:@"displayName"];
        [body setObject:@"123456" forKey:@"mobile"];
        [ZohoDeskPortalSDK updateUserInformationWith:body onCompletion:
    ^(Profile * profile, NSError * error)
    {
        // on success only profile will return a value, error will return nil
        // on failure only error will return a value, profile will return nil
    }];

Params

Dictionary [String: Any] data - Key and value pair.

The following keys are included:
  1. X
  2. Phone
  3. Facebook
  4. Name
  5. displayName
  6. mobile
  7. country locale
  8. timeZone

      Create. Review. Publish.

      Write, edit, collaborate on, and publish documents to different content management platforms.

      Get Started Now


        Access your files securely from anywhere

          Zoho CRM Training Programs

          Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.

          Zoho CRM Training
            Redefine the way you work
            with Zoho Workplace

              Zoho DataPrep Personalized Demo

              If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.

              Zoho CRM Training

                Create, share, and deliver

                beautiful slides from anywhere.

                Get Started Now


                  Zoho Sign now offers specialized one-on-one training for both administrators and developers.

                  BOOK A SESSION







                              Quick LinksWorkflow AutomationData Collection
                              Web FormsEnterpriseOnline Data Collection Tool
                              Embeddable FormsBankingBegin Data Collection
                              Interactive FormsWorkplaceData Collection App
                              CRM FormsCustomer ServiceAccessible Forms
                              Digital FormsMarketingForms for Small Business
                              HTML FormsEducationForms for Enterprise
                              Contact FormsE-commerceForms for any business
                              Lead Generation FormsHealthcareForms for Startups
                              Wordpress FormsCustomer onboardingForms for Small Business
                              No Code FormsConstructionRSVP tool for holidays
                              Free FormsTravelFeatures for Order Forms
                              Prefill FormsNon-Profit
                              Intake FormsLegalMobile App
                              Form DesignerHRMobile Forms
                              Card FormsFoodOffline Forms
                              Assign FormsPhotographyMobile Forms Features
                              Translate FormsReal EstateKiosk in Mobile Forms
                              Electronic Forms
                              Drag & drop form builder

                              Notification Emails for FormsAlternativesSecurity & Compliance
                              Holiday FormsGoogle Forms alternative GDPR
                              Form to PDFJotform alternativeHIPAA Forms
                              Email FormsEncrypted Forms

                              Secure Forms

                              WCAG

                                      Create. Review. Publish.

                                      Write, edit, collaborate on, and publish documents to different content management platforms.

                                      Get Started Now




                                                        You are currently viewing the help pages of Qntrl’s earlier version. Click here to view our latest version—Qntrl 3.0's help articles.




                                                            Manage your brands on social media


                                                              • Desk Community Learning Series


                                                              • Digest


                                                              • Functions


                                                              • Meetups


                                                              • Kbase


                                                              • Resources


                                                              • Glossary


                                                              • Desk Marketplace


                                                              • MVP Corner


                                                              • Word of the Day


                                                              • Ask the Experts


                                                                Zoho Sheet Resources

                                                                 

                                                                    Zoho Forms Resources


                                                                      Secure your business
                                                                      communication with Zoho Mail


                                                                      Mail on the move with
                                                                      Zoho Mail mobile application

                                                                        Stay on top of your schedule
                                                                        at all times


                                                                        Carry your calendar with you
                                                                        Anytime, anywhere




                                                                              Zoho Sign Resources

                                                                                Sign, Paperless!

                                                                                Sign and send business documents on the go!

                                                                                Get Started Now




                                                                                        Zoho TeamInbox Resources





                                                                                                  Zoho DataPrep Demo

                                                                                                  Get a personalized demo or POC

                                                                                                  REGISTER NOW


                                                                                                    Design. Discuss. Deliver.

                                                                                                    Create visually engaging stories with Zoho Show.

                                                                                                    Get Started Now









                                                                                                                        • Related Articles

                                                                                                                        • Introducing ASAP iOS SDK

                                                                                                                          This document pertains explicitly to help widgets created using the updated new ASAP Setup. Please note that if you are using an older version of ASAP, the help widgets will be read-only. To enable the new ASAP widgets on your App, use the latest ...
                                                                                                                        • Introducing ASAP React Native SDK

                                                                                                                          Please note that if you are using an older version of ASAP, the help widgets will be read-only. To enable the new ASAP widgets on your app, use the latest ASAP React-Native SDK 3.0.0. You can use the ASAP React-Native SDK ...
                                                                                                                        • Introducing ASAP Flutter Apps SDK

                                                                                                                          This document pertains explicitly to help widgets created using the updated new ASAP Setup. If you are using an older version of ASAP, the help widgets will be read-only. To enable the new ASAP widgets on your App, use the latest ASAP Flutter Plugin ...
                                                                                                                        • Working with the ASAP SDK for React Native

                                                                                                                          The ASAP SDK for mobile provides easy access to help end-users of your React Native app. Using this SDK, you can create and customize a help widget that resides within your app and provides end-users with easy access to the Help Center services: • ...
                                                                                                                        • How to customize the tickets module for the ASAP Android SDK?

                                                                                                                          The ticket module in Zoho Desk manages all customer support requests or inquiries. Each Ticket includes the customer's name, email, phone number, and issue. The ticket module also offers automated ticket assignment, escalation, and SLA management to ...
                                                                                                                          Wherever you are is as good as
                                                                                                                          your workplace

                                                                                                                            Resources

                                                                                                                            Videos

                                                                                                                            Watch comprehensive videos on features and other important topics that will help you master Zoho CRM.



                                                                                                                            eBooks

                                                                                                                            Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho CRM.



                                                                                                                            Webinars

                                                                                                                            Sign up for our webinars and learn the Zoho CRM basics, from customization to sales force automation and more.



                                                                                                                            CRM Tips

                                                                                                                            Make the most of Zoho CRM with these useful tips.



                                                                                                                              Zoho Show Resources