ADF Module 3 | Create Application and Modules - IndianTechnoEra
Latest update Android YouTube

ADF Module 3 | Create Application and Modules

 

Module Topics

  • 3.1 Application Development Tools Overview
  • 3.2 Create a Custom Application (Tables and Data) Using Guided App Creator (GAC)
  • 3.3 Link Loaner Application to GitLab Repository
  • 3.4 Configure Application Menu, Create Files, Commit Changes


Now, let's explore various ServiceNow Application Development Tools.


ServiceNow Application Developer Tools:

Application Engine Studio (AES): This is the Integrated Development Environment (IDE) for ongoing application development. It provides a comprehensive platform for building and developing applications.

ServiceNow Studio: ServiceNow Studio offers an integrated development environment similar to an IDE. It is used for creating, reviewing, and updating application files. Studio opens whenever you edit a custom application.

Guided Application Creator (GAC): Guided Application Creator is an intuitive development interface designed for application developers. It offers a step-by-step process to guide you through initial application development.

Note: While Application Engine Studio (AES) is ideal for custom application development, you may switch to ServiceNow Studio for a more consistent development experience as you create more custom applications.


Application Engine Studio (AES) is regularly updated with new features, so stay informed about future AES releases for new capabilities. Regardless of your skill level, developers can become more productive with these tools, ensuring efficient and productive development.


ServiceNow Studio IDE:


Benefits of Studio IDE:

  • Accelerates app development from coding to deployment.
  • Provides integrated source control for Git repositories.
  • Enables collaboration among team members.
  • Offers fine-grained control for debugging code and managing source.

Guided Application Creator (GAC):

Guided Application Creator is an intuitive and guided development interface that walks users through the application creation process. It simplifies application development, making it accessible to System Administrators, Developers, and Business Analysts.


Additional ServiceNow Application Development Tools:

Integration Hub: Integration Hub is a platform application for process automation and integrations. It uses common protocols like APIs, JDBC, PowerShell, and scripting languages to interact with external platforms within ServiceNow. Integration Hub integrations are known as "spokes."


Table Builder: Table Builder is a tool for editing data tables within your application.

UI Builder: UI Builder is a drag-and-drop editor for creating and editing Agent Workspace landing pages.

Flow Designer: Flow Designer allows process owners to automate work by building multi-step flows without coding. It replaces the legacy Workflow graphical editor.

Creator Workflows: Creator Workflows empower users to build connected digital workflow applications rapidly with a low-code platform. It offers prebuilt templates, low-code tools, and modular building blocks for seamless development.


ServiceNow Store:

The ServiceNow Store is an online marketplace where you can download and install ServiceNow applications. 

These applications may be free or available for a monthly fee. 

Apps in the ServiceNow Store are certified for compliance with best practices and built on Fuji or newer ServiceNow versions. 

It offers a wide range of applications to enhance ServiceNow functionalities.



3.2 Create a Custom Application GAC

In the Guided Application Creator (GAC), developers are guided through the application creation process, and they have various options to configure their application, user roles, user experience, tables, and more. Here are the key elements and options within GAC:


Application Configuration:

Name: Define the name of the application.

Description: Add a description for the application.

Scope: Specify the application's scope. The scope value may appear as a prefix to many application artifacts and is constructed automatically.


User Roles:

Existing: Assign existing roles to the application.

Create New: Create one or more roles for the new application. It's advisable to create at least one scoped role for the scoped application.


User Experience (UX) Options:

Mobile: User-friendly experiences for users on mobile devices.

Classic: Standard experiences for lists and forms on the Now Platform. Classic is recommended as a starting point.


Designate Data Table Options:

Select an existing table without creating a custom table.

Create a custom table without selecting an existing table. This can be done through:

Uploading a spreadsheet.

Extending a table.

Creating a table from scratch.

Select an existing table and then create a custom table through the same methods mentioned above.

Field Inputs: Continue defining the table by specifying field inputs.

Table Configurations: Further define the settings of the selected or created tables.


Next Steps: After creating the basic content of the application, users can proceed with the following steps:


Studio: Continue working on the application in ServiceNow Studio.

Flow Designer: Utilize Flow Designer for process automation.

Set up another app: Begin the process of creating another application.

When choosing to work with existing tables or create custom tables, developers have multiple options to extend or create new tables based on their application needs. They can choose to extend an existing table, create a custom table without selecting an existing one, or select an existing table and then create a custom table based on it.


To decide whether to extend an existing table or create a new one, developers should consider factors like the similarity of fields needed, the use of sample or seeded data, and whether they prefer to script application behaviors themselves or utilize existing scripts and workflow activities. Tables that can be extended must have the Extensible option selected, and it's not possible to extend system or database view tables.


Lab 3.2 Create an Application 

Lab Goal

This lab will show you how to do the following;

Create an application using Guided Application Creator (GAC)


A. Creating the Application

1. In the Application Navigator, navigate to System Applications > Studio.

2. Select the "Create Application" button.

3. Select the "Let's get started" button.

4. Configure the application:

  • Name: Loaner Request
  • Description: App to track loaner phones, laptops, and corporate assets
  • Advanced settings: Scoped [selected]
  • Scope: (automatically populated, calculated in class instances)

5. Select the "Create" button.

B. Creating an Application Role

It is recommended to create at least one scoped user role for an application. Next, you will create a loaner request user role for the Loaner Request application.

1. Select the "Create new role" link, and name the new role: "loaner_request_user," then select the "Create" button.

Make a note of the role name, then select the "Continue" button.


C. Selecting the User Experience (UX)

Notice the two different UX formats available. For the scope of this course, Classic format will be used, as you will be working with forms and lists.

1. Select "Classic," then select the "Continue" button.

D. Creating a Table

When designing an application, you must decide if you will extend an existing table or create a new one. Here are some requirements for the Loaner Request application to help drive your decision:

  • Each loaner request will have multiple tasks.
  • You will use a flow to manage the process associated with it.
  • Users will fill out a form to obtain access to loaner equipment.
  • The loaner requests have a check-out date/time and a return date/time.
  • The request form will contain a field that is a choice list for selecting the type of item being reserved (laptop, projector, mobile phone).
  • The request form will contain both a short description field and a description field.
  • The request form will contain a requestor field.

Consider these partial listings of fields from some commonly used ServiceNow tables

cmdb_ci

  • manufacturer
  • serial_number
  • model_id
  • asset

task

  • number
  • requested_by
  • state
  • assigned_to

sys_user

  • user_name
  • department
  • email
  • mobile_phone

Based on the requirements, table snippets, and your experience with ServiceNow, you should extend an existing ServiceNow table for the Loaner Request application. Here are the steps you can follow:

1. Select the "Create new table" button.

2. Notice the three options for creating a table, and select "Extend a table."

3. In the "Select table to extend" drop-down field, select the "Task" table, then select the "Continue" button.

4. For the purposes of this course, skip the field inputs and select the "Continue" button since you will add fields in a later module.


E. Now, let's configure the extended table:

Configure your new extended table:

  • Table Label: Loaner Request
  • Name: (this field auto-populates)

2. Select the "Auto-number" option and configure the numbering:

  • Prefix: LNR
  • Number: 2000
  • Number of digits: 6

3. Select the "Manage access" drop-down at the bottom of the page and notice the access permissions for the loaner request user role, then select "Continue."

4. Your table is ready! Select the "Continue" button.

You will be taken back to the data table screen, and the Loaner Request table should be listed.


5. Select the "Done with tables" button.

6. Now it's time to customize your app. Select the "Start" button.

7. After reviewing the fields, select the "Create" button.

8. Select the "Done with apps" button.


F. Configure application access in Studio:

1. Select the "Go to Studio" link.

2. Open the Loaner Request Application. 

(If it didn't open automatically, select and open the Loaner Request application from the "Select Application" dialog box.)


3. In the Application Explorer, navigate to "Data Model" > "Tables" > "Loaner Request," then select the "Application Access" tab.

4. In the main ServiceNow browser window (not the Studio browser window), select the User menu:

5. Select Elevate role:

In this section, you've elevated your role to "security_admin." Here's what you can do next:

6.Select the "security_admin" checkbox, then select "Update."

7. Notice the red bar across the header and the red circle around the user menu, indicating an elevated user role. Then, select the "User" menu:

8. Observe the elevated "security_admin" indicator.


G. Now, let's view the scope:

1. In the main ServiceNow browser window (not the Studio browser window), select and observe the "Scope Selection Menu" button.

2. Hover over the "Scope Selection Menu" to see your current Application scope and your current Update set.

3. Click the Application scope: "Loaner Request" right-facing arrow to view additional scope options.

4. Notice the options to open the Scope list and open the Scope record.

5. Open and view the Scope record.


This should help you explore the scope settings and access control related to the "Loaner Request" application. Make notes for further discussion or consideration.


3. Link Loaner Application to GitLab Repository

User Story:

As an Application Developer, the need to link to a Git repository is essential for efficient source control and tracking file changes.


Git Overview:

Git is a cloud-based source control management system that supports the coordination of work among developers during software development.

Its goals include speed, data integrity, and support for distributed, non-linear workflows.


Linking to Git:

Git uses repositories and branching to manage source code.

Various tools like GitLab, GitHub, Gitorious, Bitbucket, and others can be used.

The process involves creating a repository in the chosen Git tool, opening the application in ServiceNow Studio, configuring the source control link (repository URL, username, and password), and then linking the application to the source control.


Git Repository Overview:

Git Repository: A collection of files in a Git database.

SN App Repository: A database containing ServiceNow apps.

Key Git terms include Commit, Stash, Merge, Branch, Fork, Tag, Version, Publish, Import, and Link.


Branching in Git:

Branches allow different versions of a repository to be worked on simultaneously.

Creating a branch is useful for developing new versions of an existing application.

By default, Git repositories have a branch named "master" considered the definitive branch.

It's essential to choose the appropriate branch when working with Git.


Stashing in Git:

Stashes are locally stored sets of changes used to move changes between branches.

Stashes can be applied to any branch, including the branch from which the stash was created.

Creating a stash takes all local changes; it's not possible to select specific changes to stash.

Conflicts may arise when applying stashes, and these conflicts must be resolved.

The Action options for conflicts include "Take Stashed Changes" and "Discard Stashed Changes."


Module 3 Labs:

Lab 3.3 focuses on linking a Loaner Application to a GitLab repository.


Lab Goal

This lab will show you how to do the following:

• Link the application to a GitLab repository.


A. Linking to a GitLab Repository

1. Create a GitLab Account (if you don't have one):

If you don't have a GitLab account, open a new browser tab or window and go to GitLab Pricing. You can register for a "Free-forever" individual user account.

2. Sign In to GitLab (if you already have an account):

If you already have a GitLab account, open a new browser tab or window and sign in at GitLab Sign In with your credentials.


Next, you will create a new repository:

1. Go to the GitLab Project Welcome Screen:

Visit GitLab Project Welcome Screen.

2. Create a Project:

  • Select "Create a project."

3. Configure the Repository:

  • Choose "Create blank project."
  • Configure the repository with the following settings:
    • Project name: adf_loaner_request
    • Visibility Level: Private
    • Initialize repository with a README: [uncheck]
  • Select "Create project."

Now, you will Clone the repository and copy the repository URL:

1. Select the Clone button dropdown:

  • Copy the "Clone with HTTPS URL."

2. Return to the main ServiceNow browser window.

3. Set Up a Favorite Credential:

  • In the main ServiceNow browser window, navigate to "Connections & Credentials > Credentials."
  • Set a favorite for easy access.

Next, create a new credential for GitLab:

1. Select the "New" button.

2. Choose "Basic Auth Credentials."

3. Configure the Basic Auth Credentials:

  • Name: GitLab
  • User name: Your GitLab user name
  • Password: Your GitLab password
  • Active: Checked

4. Click "Submit."

Now, you will link the Loaner Request application to the GitLab repository:

1. Open Source Control > Link to Source Control:

2. Configure the Link to Source Control form:

  • URL: Paste the repository URL copied from GitLab.
  • Credential: GitLab
  • Branch: master

3. Select "Link to Source Control."

Once the link is successfully committed, select "Close."

1. Return to the GitLab browser window and refresh the adf_loaner_request project page.

  • Take note of how many commits have been done.
  • Observe how many branches are present.

2. Verify the master branch is selected in the branch drop-down menu.

3. Open the <sys_id> folder:

4. Open the file with the name sys_app_<sys_id>.

  • Describe in your own words what the file contains.

5. Return to the Loaner Request project by selecting the Project module from the top left frame.

Congratulations, you have completed the lab!






Post a Comment

Feel free to ask your query...
Cookie Consent
We serve cookies on this site to analyze traffic, remember your preferences, and optimize your experience.
Oops!
It seems there is something wrong with your internet connection. Please connect to the internet and start browsing again.
AdBlock Detected!
We have detected that you are using adblocking plugin in your browser.
The revenue we earn by the advertisements is used to manage this website, we request you to whitelist our website in your adblocking plugin.
Site is Blocked
Sorry! This site is not available in your country.