IBM Maximo Anywhere Version 7 Release 6 Configuring Maximo Anywhere IBM Note Before using this information and the product it supports, read the information in “Notices” on page 31. This edition applies to version 7, release 6, modification 0 of IBM Maximo Anywhere and to all subsequent releases and modifications until otherwise indicated in new editions. © Copyright IBM Corporation 2013, 2016. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Configuring Maximo Anywhere . . . . . 1 Application definition files. . . . . . . . . . 1 Data resources in the application definition . . . . 3 Enabling the Anywhere Administration application . 6 Modifying apps with the Anywhere Administration application . . . . . . . . . . . . . . . 7 Defining work list queries . . . . . . . . . . 8 Creating queries in Maximo Asset Management . 8 Creating OSLC resource queries . . . . . . . 9 Adding queries to mobile apps . . . . . . . 10 Configuring blind and non-blind counts . . . . . 12 Specifying criteria for retrieving lookup data . . . 13 Configuring page sizes for retrieving data . . . . 14 Failure reporting implementation in Maximo Anywhere . . . . . . . . . . . . . . . 15 Configuring maps . . . . . . . . . . . . 16 Map positioning information . . . . . . . 16 Service addresses . . . . . . . . . . 17 Enabling the auto-locate cron task . . . . . . 18 Cron task system properties . . . . . . . 19 Configuring access to a map service provider . . 19 © Copyright IBM Corp. 2013, 2016 Enabling the map view . . . . . . . . Adding maps to iOS devices . . . . . Activating GPS . . . . . . . . . . Configuring route lines . . . . . . . Configuring zoom levels . . . . . . . Enabling Real Signature for Maximo Anywhere mobile apps . . . . . . . . . . . . . Recording signatures with Real Signature . . . Activating bar code scans. . . . . . . . . Connecting Bluetooth bar code scanners to mobile apps . . . . . . . . . . . . . . . . Enabling encryption of the local data store . . . Changing the heartbeat interval . . . . . . Attachments properties . . . . . . . . . Timeout properties . . . . . . . . . . . . . . . . 20 22 22 23 23 . 24 . 25 . 26 . . . . . 26 27 27 28 29 Notices . . . . . . . . . . . . . . 31 Trademarks . . . . . . . . . . . . . Terms and conditions for product documentation. IBM Online Privacy Statement . . . . . . . . 33 . 33 . 34 iii iv Configuring Maximo Anywhere Configuring Maximo Anywhere You can configure Maximo Anywhere to suit the business needs of your organization. You can define work list queries and other settings for retrieving data from the server. You can enable maps, attachments, bar code scans, and data encryption. Configuration settings can apply at an application or system level. Application definition files An application definition is an XML file that defines the user interface and data resources of a Maximo Anywhere mobile app. You can configure the app by editing the application definition, or, if it is enabled, the Anywhere Administration application. Maximo Anywhere includes mobile apps that are built and deployed to the mobile workforce to support business operations. Mobile apps You can make the following changes to all mobile apps: v Specify the queries that determine which work list records can be retrieved from the server v Define the lookup data that can be retrieved from the server v Restrict access to the status change feature by user group v Enable encryption of the local data store for the app v Define the frequency with which local data changes are sent by the app to the server v Define the timeout value for requests that are issued by the app to the server You can make the following changes to the Asset Audit app: v Enable bar code scans You can make the following changes to the Asset Data Manager app: v Enable bar code scans You can make the following changes to the Inspection app: v Enable the map view v Enable bar code scans v Enable attachments v Enable GPS v Record and store signatures with either electronic signature or Real Signature You can make the following changes to the Issues and Returns app: v Enable bar code scans You can make the following changes to the Physical Count app: v Enable bar code scans You can make the following changes to the Service Request app: © Copyright IBM Corp. 2013, 2016 1 v Enable bar code scans You can make the following changes to the Transfers and Receiving app: v Enable bar code scans You can make the following changes to the Work Execution app: v Enable the map view v Enable bar code scans v Enable attachments v Enable GPS v Record and store signatures with either electronic signature or Real Signature The application definition for a mobile app is in the application root directory and has the name app.xml. Table 1. Directories for the app.xml files App Directory Maximo Anywhere Asset Audit app install_home\MaximoAnywhere\apps\ AssetAudit\artifact Maximo Anywhere Asset Data Manager app install_home\MaximoAnywhere\apps\ AssetDataManager\artifact Maximo Anywhere Inspection app install_home\MaximoAnywhere\apps\ Inspection\artifact Maximo Anywhere Issues and Returns app install_home\MaximoAnywhere\apps\ IssuesReturns\artifact Maximo Anywhere Physical Count app install_home\MaximoAnywhere\apps\ PhysicalCount\artifact Maximo Anywhere Service Request app install_home\MaximoAnywhere\apps\ ServiceRequest\artifact Maximo Anywhere Transfers and Receiving app install_home\MaximoAnywhere\apps\ TransfersReceiving\artifact Maximo Anywhere Work Approval app install_home\MaximoAnywhere\apps\ WorkApproval\artifact Maximo® Anywhere Work Execution app install_home\MaximoAnywhere\apps\ WorkExecution\artifact After you change an application definition, you must build and deploy the app. If you use the Anywhere Administration application, building and deploying the app is not required. Depending on the type of change, the updated app is delivered to users as a new app version or as a direct update: v If the change includes new or updated native code, you must deploy the app as a new app version. For example, when you enable the map view or bar code scans, native code is added to the app during the build process. Users must download and install the new app version from the server. v If the change includes updated web resources, you can deploy the app without changing the app version. Users can accept the change as a direct update of the app version that is installed on their devices. The application definition for mobile apps includes an attribute, requiredRole, that specifies which user group in the provider application is authorized to use the application. This attribute references one of the predefined user groups that are 2 Configuring Maximo Anywhere deployed during installation to the provider application environment. At run time, only users that belong to the specified user group can log in to the app. For example, the requiredRole attribute in the application definition for the Work Execution app references the ANYWHERE_TECHNICIAN security group in Maximo Asset Management. Only users that belong to the ANYWHERE_TECHNICIAN security group can log in to the Work Execution app. Structure of application definition files The <app> XML element is the root element of an application definition file. The <app> element has three child elements that define the basic structure of the application definition. <ui> element Contains the specifications for the views in the mobile app, including views for the work list, record details, lookups, and dialog boxes. <data> element Contains the specifications for the data resources that are used by the app, including work list, lookup, and system resources. <messages> element Contains messages that are displayed on the user interface and recorded in the app log. Related concepts: “Data resources in the application definition” The data that is used in a mobile app is specified in the application definition in the form of OSLC resources. Resources are categorized as primary, supporting, lookup, or system resources. These categories determine how the resources are specified in the application definition and how they are managed at run time. Related tasks: “Enabling the Anywhere Administration application” on page 6 By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. Data resources in the application definition The data that is used in a mobile app is specified in the application definition in the form of OSLC resources. Resources are categorized as primary, supporting, lookup, or system resources. These categories determine how the resources are specified in the application definition and how they are managed at run time. An OSLC resource represents a business, configuration, or domain object that belongs to the provider application. A resource is defined in the provider application by a shape document that describes the structure of the resource and all possible properties. The resource is published for integration by an OSLC object structure. The resource is registered with a service provider that specifies and manages the data operations that are available for the resource to consumer applications. In Maximo Anywhere, where mobile apps act as consumers, the application definition specifies the resources that are used by the mobile application. The Configuring Maximo Anywhere 3 <data> XML element contains the specifications for all resources. The main characteristics of a resource are defined by the attributes of the root element, <resource>. Table 2. Attributes of the <resource> element Attribute Specifies Usage providedBy The service provider that is used for data operations on this resource. Required for primary, lookup, and system resources. A service provider reference is required for resources that are retrieved from the provider application as independent entities. The service provider specifies whether data for the resource can be updated, created, or deleted by the consumer application. For the primary resource, the service provider also specifies which queries are available to consumer applications. describedBy The shape document that defines the resource. Required for primary, lookup, and system resources. The specifications for these resources in the application definition must conform to the shape document definition. name A unique name that is used for references to this resource in the application definition. Required for all resources. pageSize The number of resource instances Required for primary, lookup, and that can be retrieved at a time from system resources. the provider application. If, during query execution, the number of matching resource instances exceeds the page size value, the value is used to break down the result set into subsets that are retrieved in successive calls. additional Data Whether the resource is a lookup resource. Required with a value of true for all lookup resources. isSystem Whether the resource is a system resource. Required with a value of true for all system resources. The following example shows the attributes that define the primary resource, workOrder, in the application definition for the Work Execution app: <resource providedBy="/oslc/sp/WorkManagement" describedBy="http://jazz.net/ns/ism/work/smarter_physical_infrastructure#WorkOrder" name="workOrder" pageSize="100" [...]> The following example shows the attributes that define a lookup data resource, additionalasset, in the application definition for the Work Execution app: <resource providedBy="/oslc/sp/AssetManagement" describedBy="http://open-services.net/ns/asset#Asset" name="additionalasset" pageSize="1000" additionalData="true"> 4 Configuring Maximo Anywhere The <resource> element is parent to the <attributes> element. This element contains a list of attributes that specify the resource data that is used by the mobile app. The attributes that are listed correspond to properties that are defined by the resource shape document in the provider application. Primary resource The primary resource represents the top-level object in the work list record. The primary resource can be a parent to one or more supporting resources. A supporting resource represents a child object in the work list record. The primary resource can have a one-to-one or a one-to-many relationship with a supporting resource. When a one-to-many relationship exists between the primary and supporting resources, the data for the supporting resource is rendered as a list of child objects in the work list record. For example, the work order is the primary resource in work list records for the Work Execution app. The work order resource can be related to supporting resources such as asset, location, task, and labor. A work order can have a single main asset or location and multiple tasks and labor assignments. Tasks and labor assignments are displayed as lists within the work order. In the application definition, primary and supporting resources are defined as separate entities. The primary resource has the following characteristics: v References to the service provider and shape document for the primary resource in the provider application. v A list of the queries that are used during run time to retrieve work list records from the server. The list is contained in the <queryBases> element. v A page size value that specifies the maximum number of work list records that can be retrieved in each request. v Simple and complex attributes for the properties of the primary resource as defined in the shape document. Simple attributes represent data that is local to the primary resource. Complex attributes refer to supporting resources. A supporting resource includes simple attributes for data that belongs to the supporting resource but is used in the work list record. Supporting resources are dependent on the primary resource to which they are related. Unlike the primary resource, supporting resources are not retrieved independently from the provider application and do not require references to a service provider and shape document. Lookup resources During run time, users can change supporting data in the work list record in accordance with business rules and application capabilities. Many changes involve the use of a lookup control to reference and select data that is external to the work list record. Examples of lookup data include the assets, tools, and materials that can be added to a work order. Users must download lookup data to make it available in the mobile app. Locally stored lookup data can be refreshed be on demand. Lookup objects are represented in the application definition as lookup resources. A lookup resource has the following characteristics: v An additionalData attribute with a value of true. Configuring Maximo Anywhere 5 v References to the service provider and shape document for the lookup resource in the provider application. v A page size value that specifies the maximum number of records that can be retrieved in each request. v Simple attributes for the properties of the lookup resource as defined in the shape document. System resources A system resource represents an object that is external to the work list record but is required to support system operations in the mobile app. For example, the following resources are classed as system resources for the Work Execution app: v The domain value lists that are used to change work order status and other work list record attributes. v The labor and labor craft resources for the current user that are required for labor reporting. v Labor timer settings that are active in the provider application and are required for local validation of labor transactions. System data is automatically downloaded when a user first logs in to the application. If the download fails, the user cannot log in. Locally stored system data is refreshed whenever the user refreshes lookup data. In the application definition, a system resource has an isSystem attribute with a value of true. Other characteristics are the same as the characteristics of the lookup resource. Enabling the Anywhere Administration application By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. Before you begin From Maximo Asset Management, in the System Properties application, specify the host name value for the mxe.oslc.webappurl property. The mxe.oslc.webappurl property defines the public URL to find the OSLC resources. The default URL is http://localhost/maximo/oslc/. About this task You enable the Anywhere Administration application by setting the si.adminmode property in the worklight.properties file. After the Anywhere Administration application is enabled, you must load data into this application. You must load data any time that you add data resources to the provided Maximo Anywhere apps, remove data resources from the apps, or create custom apps. You run an Ant script utility to load the data into the Anywhere Administration application. The utility is named admin-config-loader.xml and is in the MaximoAnywhere folder. Data resources, such as provided queries and map settings, that are set in the app.xml file are ignored in favor of any data resources set by using the Anywhere Administration application. 6 Configuring Maximo Anywhere Procedure 1. From the worklight.properties file in the MaximoAnywhere\server\conf folder, locate the si.adminmode property and set this property to true. 2. Run the build all command, which is build.cmd on Windows or build.sh on UNIX and Linux systems. The .apk or .ipa artifact file is generated, and all distributable files for the Maximo Anywhere project are deployed to MobileFirst Server. 3. Deploy the project WAR file to MobileFirst Server. a. From the Server Configuration Tool, select Replace the project WAR file of a deployed runtime. b. Complete the steps in the wizard. 4. Optional: To run the import utility in a development environment, specify the user name and password as arguments for the file. a. In MobileFirst Studio, add the admin-config-loader.xml Ant file to the Ant view. b. Right-click on the admin-config-loader.xml Ant file and select Run as > Ant Build. c. On the Main tab, add the user name and password for the adapter in the Arguments field. -Dadapter.connection.user=<user_name> -Dadapter.connection.password=<password> 5. Load data into the Anywhere Administration application. Environment Action In a development environment in MobileFirst Studio Run the admin-config-loader.xml file from the Ant view. In a production environment Run this command: ant -f admin-config-loader.xml allApps The allApps parameter searches all the application folders for the provided Maximo Anywhere apps and any apps that you created. 6. From Maximo Asset Management, in the Security Groups application, open ANYWHERE_INSPECTOR. 7. In the Applications tab, find the Anywhere Administration application and grant rights to it. 8. Access the Anywhere Administration application from the Integration module within Maximo Asset Management. Related information: MobileFirst Server Configuration Tool Modifying apps with the Anywhere Administration application When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Configuring Maximo Anywhere 7 Before you begin Enable the Anywhere Administration application. About this task When you define data resources, such as work list queries and map settings, in the Anywhere Administration application, these resources override any provided resources that are set in the app.xml file. Procedure 1. Access the Anywhere Administration application from the Integration module within Maximo Asset Management and select the Maximo Anywhere app that you want to modify. 2. Select the tab for the type of data that you are changing: Tab Data List Data Work list queries Lookup Data Downloaded Settings Maps 3. Optional: To set the group for a data resource, in the row for that resource, select the Detail Menu icon, and pick a group from the list. 4. To create a new query, click New Row and create a query. To modify an existing query, select the Detail Menu icons for that row, and pick new values for the query. 5. Optional: To see a list of all the global properties that can be modified for the Maximo Anywhere mobile apps, click Anywhere Global Properties. Group settings are not enabled for these properties. 6. On your mobile device, log out of the modified app and then log back in to it again to see the configuration changes in that app. Defining work list queries The work list queries that you define for a mobile app determine which records can be retrieved from the server by mobile users. You create custom queries in Maximo Asset Management. You implement these queries in the mobile app by updating the application definition and deploying a new application version. You can also implement these queries by using the Anywhere Administration application if it is enabled. Creating queries in Maximo Asset Management When you create queries in Maximo Asset Management, you specify search criteria that suit the requirements of the target user groups in Maximo Anywhere. About this task You create work list queries in the Maximo application that authorizes access to the primary resource for the mobile app. The authorizing application must be registered with the object structure for the primary resource. For example, the primary resource in the Maximo Anywhere Work Execution app is the work order. In Maximo Asset Management, the Work Order Tracking application is registered 8 Configuring Maximo Anywhere as the authorizing application for the oslcwodetail object structure and work order resource. Therefore, you create queries for the Work Execution app in the Work Order Tracking application. The queries that you create in the Maximo application must be saved and marked public. Public queries are automatically added to the service provider that manages the associated resource data. These queries are implemented and used by consumers such as mobile applications to retrieve data from the provider application. The search criteria that you define for a query determine the search results that are returned during run time. The actual result set for individual users can be different depending on their access rights in Maximo Asset Management. For example, a user belongs to a security group that is authorized to see work orders for the Site A, but not Site B. When this user runs a query in the app to retrieve all work orders in the preventive maintenance backlog, work orders for Site A, but not for Site B, are downloaded to the device. The search criteria can include constants that are resolved dynamically when the query is executed in Maximo Asset Management. The result set is filtered by the value that is returned for the resolved constant. For example, the default query, WORKIOWN, for the Work Execution app includes a constant, :USER. When the query is executed, this constant is resolved to return all work orders that are owned by the current user. Procedure 1. In Maximo Asset Management, open the application that authorizes access to the primary resource for the mobile application. 2. On the List tab, click Advanced Search, use one of the available options to specify the search criteria, and click Find. Verify that the query returns the expected search results. 3. Click Save Query and specify a name that uniquely identifies the query. The query name cannot include any spaces. 4. Select Public. 5. Click OK. What to do next Use the query name that you specified in Maximo Asset Management to add the query to the application definition for the mobile application. Creating OSLC resource queries In Maximo Asset Management, an OSLC resource can be associated with an application through the object structure. The public queries that you create are added to the service provider as query capabilities for the resource. You can use the defined queries to access the OSLC resource. If you support multiple versions of a Maximo application that uses the same resource, you can define the resource queries for each version of the application. Before you begin You can add queries for the following apps: v Asset Audit v Asset Data Manager Configuring Maximo Anywhere 9 v Inspection v Service Request v Work Approval v Work Execution You cannot add queries for the following apps: v Issues and Returns v Physical Count v Transfers and Receiving About this task You can enable resource queries from a saved query of an application or by defining a query by using an automation script. Procedure 1. In the OSLC Resources application, select the OSLC resource. 2. From the Select Action menu, select Resource Query Definition. 3. Specify the query for the resource. Query Action For a query that is saved in the application Specify the application and the query or copy all public queries that are associated with the application. For a query that is created from an automated script Specify the name of the query script. 4. Specify the unique URI name that is used by the query and save the record. 5. In the System Properties application, specify the host name value for the mxe.oslc.webappurl property. The mxe.oslc.webappurl property defines the public URL to find the OSLC resources. The default URL is http://localhost/maximo/oslc/. 6. Import the updated OSLC resource from Maximo Asset Management into Maximo Anywhere. The OSLC resource is imported to Resource Description Framework (RDF) files. What to do next Add the OSLC resource query and URI to the app.xml file for the mobile app. Related information: Importing OSLC resources to Maximo Anywhere Adding queries to mobile apps To enable mobile users to retrieve work list records from the server, you must add at least one query to each mobile app. You add queries to a mobile app by including them in the application definition file. You can also add queries by using the Anywhere Administration application if it is enabled. Before you begin You can add queries for the following apps: v Asset Audit 10 Configuring Maximo Anywhere v Asset Data Manager v Inspection v Service Request v Work Approval v Work Execution You cannot add queries for the following apps: v Issues and Returns v Physical Count v Transfers and Receiving The queries that you want to implement in the mobile application must be saved as public queries in Maximo Asset Management. About this task In the application definition, you add queries to the specifications for the work list view and the primary resource. Each query must correspond to, and have the same name as, a public query in Maximo Asset Management. The public query, in turn, corresponds to a query in the service provider for the primary resource. Each application definition includes three system queries, Records Created Locally, Records with Errors, and Search Results, that are used for system functions in the mobile app. You must not remove or modify the code for these queries. Procedure 1. In the MaximoAnywhere\apps\app_name\artifact directory, open the app.xml file with an XML editor. 2. Add a query to the work list view. The work list view is the first view that is defined in the UI section of the application definition. a. In the <queries> element for the work list view, add a child element called <query>. b. Use the queryBase attribute to specify the name of the public query in Maximo Asset Management. The query name is case sensitive. c. Use the label attribute to specify the query label that is displayed in the work list menu. d. Optional: To define this query as the default query for the work list view, specify the query label as the value of the label attribute for the parent <view> element. In this example, three queries are added to the work list view for the Work Execution app: <view id="WorkExecution.WorkItemsView" label="Work I Own" saveonshow="true" <queries resource="workOrder"> <query label="Work I Own" queryBase name="WorkIOwn"> <query label="Assigned to My Labor" queryBase name="WorkforMyLabor"> <query label="Work Assigned to My Crew" queryBase name="WorkforMyCrew"> <...> </queries> <...> </view> 3. Add the query that you specified in step 2 to the primary resource. The primary resource is the first resource that is defined in the data section of the application definition. Configuring Maximo Anywhere 11 a. In the <queryBases> element for the primary resource, add a child element called queryBase. b. Use the name attribute to specify the name of the public query in Maximo. The query name is case sensitive. c. Use the queryUri attribute to specify how to retrieve the query records from Maximo. In this example, three queries are added to the primary resource, workOrder, for the Work Execution app: <resource providedBy="/oslc/sp/WorkManagement" describedBy="http://jazz.net/ns/ism/work/ smarter_physical_infrastucture#WorkOrder" name="workOrder" pageSize="100" class="application.business.WorkOrderObject"> <...> <queryBases> <queryBase name="WorkIOwn" queryUri="/oslc/os/oslcwodetail?savedQuery=WorkIOwn"> <queryBase name="WorkforMyLabor" queryUri="/oslc/os/oslcwodetail?savedQuery=WorkforMyLabor"> <queryBase name="WorkforMyCrew" queryUri="/oslc/os/oslcwodetail?savedQuery=WorkforMyCrew"> </queryBases> <...> </resource> 4. Save the file. 5. Build and deploy the application. What to do next Log in to the application and check that the queries that you added appear in the work list menu. Verify that the result set is the same when you run the query in the provider application and in the mobile app. Related concepts: “Data resources in the application definition” on page 3 The data that is used in a mobile app is specified in the application definition in the form of OSLC resources. Resources are categorized as primary, supporting, lookup, or system resources. These categories determine how the resources are specified in the application definition and how they are managed at run time. Configuring blind and non-blind counts Counts for the Physical Count app are either blind or non-blind. Blind counts are the default. To create blind counts or change non-blind counts into blind counts, you edit the app.xml file. You can also create these counts by using the Anywhere Administration application if it is enabled. About this task In a blind count, the app requires a numeric value for the item's balance that corresponds to what is in the inventory. In a non-blind count, the app requires a numeric value only if the current balance for that item differs from what is in the inventory. If the query base is not defined in the blindCountQueryBases section of the app.xml file, then the count is a non-blind count. Procedure To create a blind count or change a non-blind count into a blind count: 1. In the app.xml file, create a local attribute for the count. 12 Configuring Maximo Anywhere 2. Add the local attribute to the list of query bases in the blind count section. To change the count from a blind count to a non-blind count: 3. Remove the local attribute for the count from the list of query bases in the blind count section of the app.xml file. Example The following example of a blind count section of an app.xml file includes a list of blind count query bases: <!-- BlindCount QueryBases --> <resource name="blindCountQueryBases"> <attributes> <localAttribute name="getCentralStoreroom" dataType="boolean" /> <localAttribute name="getAtlantaStoreroom" dataType="boolean" /> </attributes> <whereClause /> </resource> Related tasks: “Enabling the Anywhere Administration application” on page 6 By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. “Modifying apps with the Anywhere Administration application” on page 7 When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Specifying criteria for retrieving lookup data To narrow the scope of the query for a lookup resource, you can add a WHERE clause to the resource in the application definition file. You can also add these WHERE clauses by using the Anywhere Administration application if it is enabled. The criteria in the WHERE clause are resolved dynamically when lookup data is retrieved from the provider application. About this task By default, the query for a lookup resource retrieves all records, or instances of the resource, that are available in the provider application. Depending on the requirements of your mobile app users, you might want to filter the result set to match custom criteria. You specify those criteria by adding a WHERE clause to the lookup resource in the application definition file. The application definition file for a mobile app can include predefined WHERE clauses for lookup and system resources. The criteria that are expressed in a predefined WHERE clause are required by the mobile app to support system operations and must not be modified. However, you can add additional criteria to predefined WHERE clauses by using the and operator to add custom criteria. Maximo Anywhere supports the OSLC WHERE clause. The criteria in an OSLC WHERE clause have a standard format that comprises an attribute, an operator, and a constant. For example, the following WHERE clause can be added to the additionallocations lookup resource to retrieve locations in SITE A only: <whereClause clause="spi:siteid=’SITE A’" /> Configuring Maximo Anywhere 13 The where clause includes the following items: siteid An attribute of the additionallocations lookup resource. = A comparison operator that expresses equality. No spaces are allowed before or after comparison operators. SITE A A constant that expresses the site value criteria for matching location records. The criteria in a WHERE clause are typically based on attributes of the lookup resource to which the WHERE clause applies. However, a WHERE clause can also include criteria that are based on system resource attributes. For example, the following WHERE clause finds the mylaborcraftrate resource for the labor record that is associated with the current user. The labor record for the current user is given as [${mylabor.laborcode}], where laborcode is an attribute of the mylabor system resource. spi:defaultcraft is an attribute of the mylaborcraftrate system resource: <whereClause clause="spi:laborcode in [${mylabor.laborcode}] and spi:defaultcraft=1" /> You must not create circular references in WHERE clauses that use attributes from other resources. For example, if the WHERE clause for resource A uses an attribute from resource B, the where clause for resource B must not use an attribute from resource A. The application XSD cannot validate the content of the <whereClause> element. If you add WHERE clauses to the lookup resources in an application definition file, you must test the updated runtime application before you deploy it to a production environment. Procedure 1. In the MaximoAnywhere\apps\app_name\artifact directory, open the app.xml file. In the data section of the file, locate the resource that you want to configure. 2. In the <whereClause> element, specify the criteria as the value of the clause attribute and save the file. 3. Build and deploy the application. Related tasks: “Enabling the Anywhere Administration application” on page 6 By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. “Modifying apps with the Anywhere Administration application” on page 7 When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Configuring page sizes for retrieving data To increase or reduce the number of records that are retrieved from the server at a time, you can configure the page size for primary, lookup, and system resources. 14 Configuring Maximo Anywhere About this task The page size of a data resource in the application definition file defines the number of records that are retrieved from the server at a time. If the size of the result set exceeds the page size value, the result set is divided into subsets that are retrieved as separate pages in successive requests. You can specify different values for individual resources: v The page size for the primary resource determines the number of work list records that can be retrieved in a results page when users select a work list query in a mobile app. The default page size for primary resources is 100. v The page size for a lookup or system resource determines the number of records that can be retrieved in a results page for that resource type when users download or refresh lookup data on mobile devices. The default page size for most lookup and system resources is 1000. By reducing the page size, you can improve the response time for the retrieval of data. By increasing the page size, you can reduce the number of requests that are issued by the application to retrieve the full result set. Procedure 1. In the MaximoAnywhere\apps\app_name\artifact directory, open the app.xml file. 2. In the data section of the file, update the value of the pageSize attribute for the resource or resources that you want to configure. pageSize is an attribute of the root element of the resource. 3. Save the file. 4. Build and deploy the application. Failure reporting implementation in Maximo Anywhere By default, the query that downloads failure data retrieves all records or instances of the resource that are available in the provider application. Depending on the requirements of your mobile app users, you might want to filter the result set to match custom criteria. To narrow the scope of the query for failure data, you can add a WHERE clause to the queryBases element in the application definition file (app.xml). The criteria in the WHERE clause are resolved dynamically when lookup data is retrieved from the provider application. For example, you can download work orders with failure codes that are assigned to a specific organization. If the organization that is specified for work orders in Maximo Asset Management contains the word ORG A, then only the work orders for that organization are downloaded. To limit the records that are downloaded, add the following to the end of the queryBases section: <whereClause clause="spi_wm:orgid=’ORG A’"/> In the application definition file, there are several queryBases sections of code. The queryBases section that you must modify is located within the following code: <resource providedBy="/oslc/sp/SmarterPhysicalInfrastructure" describedBy="http://jazz.net/ns/ism/asset/smarter_physical_infrastructure#FailureList" name="failureListResource" pageSize="1000" additionalData="true"> Configuring Maximo Anywhere 15 Configuring maps Mobile workers can use the map view in the Maximo Anywhere Work Execution application and the Maximo Anywhere Inspection application to check the geographical location of work orders. To make the map view available, you must prepare the Maximo Anywhere environment and configure the application. Map positioning information Positioning information is the geographical coordinate data that is used to determine the location of a work order and add a position marker to the map. When a work order in the enterprise system contains positioning information, such as a service address, that information is provided to the IBM® Maximo Anywhere Work Execution and IBM Maximo Anywhere Inspection apps when the work order is downloaded. If work orders in the enterprise system do not have positioning information, you need to configure the information on the enterprise system. Coordinates or work order positioning information is downloaded from the map service provider to the enterprise system environment. Directions and a route to work orders on the mobile worker's current work list are available when the mobile device is configured with a map service provider. If your enterprise system includes IBM Maximo Spatial Asset Management, positioning information is obtained from work order objects that are linked to a map feature. If Maximo Spatial Asset Management is not in your environment, positioning information is obtained by using non-linked objects. A non-linked object is a work order object that is not linked to a map feature. Non-linked objects therefore provide static geographic coordinate data that you must manually add and store in the service address object. Work order objects that can contain positioning information are work order, service address, asset, and location. When Maximo Spatial Asset Management is available, positioning information is obtained by using linked objects. A linked object is an object in a work order that is linked to a map feature in the designated GIS. A linked object can be the work order object itself, or the associated service address, asset, or location. The link between the object and the map feature enables the auto-locate function to dynamically obtain geographic coordinate data from the GIS when the cron task runs. If you do not use Maximo Spatial Asset Management, positioning information comes from static geographic coordinate data that is added and stored in the service address object. The static geographic coordinate data must be manually added into the Service Address application in Maximo Asset Management. The static geographic coordinate data can also be bulk loaded or migrated into the Integration Framework application in Maximo Asset Management. For offline Esri maps, you need to set up the TPK files for the geographic areas of your organization’s work orders. The service address coordinate system must match the coordinate system that is used to create the offline map. The auto-locate function determines the geographical location of a record by processing the available positioning information in a defined sequence. The sequence is work order linked object, work order X/Y coordinates, work order 16 Configuring Maximo Anywhere linked service address, work order service address X/Y coordinates, work order linked asset, work order asset X/Y coordinates, work order linked location, and work order location X/Y coordinates. You schedule the automatic location of work orders by using the cron task, WoAutoLocateCronTask. The following diagram shows the flow of data between the Maximo Anywhere app on the mobile device, the enterprise system, and the map service provider (Esri ArcGIS server). To provide a route and directions, Maximo Anywhere must be configured to use a map service provider. Esri ArcGIS server Directions Coordinates Enterprise system Mobile device Maximo Anywhere app Cron task Maximo Anywhere map plugin (native code) Data (OSLC) Offline map (TPK file) MobileFirst Server Data (JSON over HTTP) Adapter Map service provider API (Esri Android SDK) Data is downloaded from the enterprise system environment by way of MobileFirst Server to the mobile device. The exchange of data is represented in the diagram by OSLC, between the enterprise system environment and the MobileFirst Server, and by JSON over HTTP, between the MobileFirst Server and the mobile device. Related tasks: “Enabling the auto-locate cron task” on page 18 Maximo Anywhere provides a cron task, WoAutoLocateCronTask, that is set up to run the auto-locate function. By default, the cron task is not enabled because map support is optional in Maximo Anywhere. If you enable map capabilities, you must enable the cron task. Related information: Automatic location search order process for work orders Service addresses Service addresses in the enterprise system can provide map positioning information. If you do not use Maximo Spatial Asset Management, you can use the Service Address application to provide positioning information. Configuring Maximo Anywhere 17 The Maximo Service Address application is licensed with Maximo Anywhere. If you have Maximo Spatial Asset Management, when you install Maximo Anywhere, the version of the Service Address application in Maximo Asset Management is upgraded to the Maximo Spatial Asset Management version. The upgraded version of the Service Address application supports linked objects that include map positioning information. The service address object in the Service Address application includes X/Y coordinate fields for positioning information. This positioning information can be manually added into the application. In addition, when Maximo Spatial Asset Management is installed and linked to the Esri ArcGIS server, the map feature linked objects can be used to obtain positioning information. The Service Address application can be configured with either latitude and longitude fields or X/Y coordinate fields. However, to support map capabilities in Maximo Anywhere, the application must be configured with X/Y coordinate fields. The service address coordinate system that is used for work orders and related objects must match the coordinate system that is used to create the offline maps (TPK files). In addition, the service address coordinate system must match the map that is set up in the Esri ArcGIS server. Enabling the auto-locate cron task Maximo Anywhere provides a cron task, WoAutoLocateCronTask, that is set up to run the auto-locate function. By default, the cron task is not enabled because map support is optional in Maximo Anywhere. If you enable map capabilities, you must enable the cron task. About this task The auto-locate function in Maximo Asset Management updates or adds positioning information to work orders. This positioning information is used in the Maximo Anywhere Work Execution and Maximo Anywhere Inspection apps to plot work order locations on the map view. The WoAutoLocateCronTask runs the auto-locate function. This cron task includes two cron task instances: v By default, the WoAutoLocateInstance instance selects work orders that have a scheduled or target start date that occurs within two days of the current time. Schedule this instance to run every 24 hours so that positioning information is updated or added to all work orders that are due to start within two days. v By default, the EmergentWoTask instance selects work orders that were approved or started in the 5-minute period before the current time. Schedule this instance with the frequency that work orders might be approved or started so that positioning information is updated or added to these work orders. You can change the work order selection criteria for both cron task instances by modifying the WO_WHERECLAUSE parameter. For the EmergentWoTask instance, you can modify the EMERG_WO_TIME parameter. Procedure 1. In the Cron Task Setup application in Maximo Asset Management, open the WoAutoLocateCronTask record. 2. Define the settings for each cron task instance: 18 Configuring Maximo Anywhere a. Set a schedule for the cron task instance. At a minimum, the value of the EMERG_WO_TIME parameter should equal the number of minutes set in the schedule. This parameter acquires all work orders that were modified from the time the schedule runs, to twice the value of this parameter. For example, if this parameter is set to 5 minutes, all work orders that were modified in the previous 10 minutes are acquired. b. Specify a user with the necessary privileges, such as maxadmin. The user must have access for the actions that the cron task performs. c. Select the Active and Keep History check boxes. d. In the Max Number of History Records field, enter 1000. e. Optional: To change the criteria for work order selection, update the WO_WHERECLAUSE parameter. 3. From the Select Action menu, select Reload Request. 4. Select the cron task, and click OK. Cron task system properties The WoAutoLocateCronTask cron task instances have two associated system properties. To change the value of a property, use the System Properties application of Maximo Asset Management. Table 3. Cron task system properties Property Description Default value mxe.plussng.max.recs.returned. arcgis.server The maximum number of records that 1000 are returned by the Esri ArcGIS server at one time. The value is the lowest number of records that is allowed for a client to receive from any map services that are used by Maximo Spatial Asset Management in the Esri ArcGIS server. This system property applies only if Maximo Spatial Asset Management is deployed to the enterprise system environment. mxe.plussng.cron.max.autoloc. grp.objects The maximum number of work orders with location objects to be processed at one time. The value limits the query that is set up for the auto-locate cron task instances if the query returns large numbers of work orders with location objects. 2000 Configuring access to a map service provider A map service provider is required for providing routing and driving directions to work orders in the map view. The configuration information is valid for all apps that include the map view and that are deployed in the current environment. Before you begin Both the mobile device and the Esri ArcGIS server should be configured for secure communication. Configuring Maximo Anywhere 19 About this task Information that is used to access the Esri ArcGIS server is not added to the worklight.properties file by default because map support in Maximo Anywhere is optional. You configure this authentication information by editing this file. When an app with the map view is started, information is transferred to the app so that the mobile workers can use the routing service. Procedure 1. From the maximoanywhere_home\MaximoAnywhere\server\conf directory, edit the worklight.properties file and set the following properties: Property Description si.map.esri.authentication.isEnabled Enables authentication to the Esri ArcGIS server. Set this property to 1 to enable authentication. si.map.esri.username The user name that is used to access the routing service on the Esri ArcGIS server. si.map.esri.password The password that is used to access the routing service on the Esri ArcGIS server. si.map.esri.routeService The secure URL of the routing service on the Esri ArcGIS server. Set this property to, for example, https://route.arcgis.com/arcgis/ rest/services/World/Route/NAServer/ Route_World 2. Save and close the file. 3. Optional: Encrypt the worklight.properties file by using the encrypt.bat file encryption process. The si.map.esri.password.enc property contains an encryption value similar to HhMEhpY3f6F6rlJQ17qwbw\=\=. 4. Build and deploy the application. 5. Restart MobileFirst Server. Related concepts: Deploying applications to the server Related information: Android developer help Esri ArcGIS server help Storing properties in encrypted format Enabling the map view The map view provides mobile workers with the geographical location of work orders in their current work list. Before mobile workers can get directions in the Work Execution and Inspection apps, the map view must be enabled. Before you begin For the Esri map service provider, you must have a license from Esri. For offline maps: v 20 You must create maps that are compatible with and supported by the Esri map service provider. Configuring Maximo Anywhere v The mobile devices that use the map view must have enough space for the offline map (TPK) files, which can exceed 1 GB. About this task The map view is disabled by default because map support in Maximo Anywhere is optional. Enabling the map view displays the map view icon in the work list. The work list corresponds to the work order position markers in the map view. When you enable the map view, the updated app must be deployed as a new app version. Users must download and install the new app version from the server. You must choose to use either offline maps or online maps, you cannot use both. For offline maps, the location and name of the TPK file must be specified. For online maps, the providerUrl attribute must be specified. Procedure 1. From the maximoanywhere_home\MaximoAnywhere\apps\app_name directory, edit the app-feature.properties file and set the property map.enabled=true. 2. Save and close the file. 3. From the maximoanywhere_home\MaximoAnywhere\apps\WorkExecution\artifact directory, edit the app.xml and update the attribute for the map control. You can also update the attribute by using the Anywhere Administration application if it is enabled. a. For offline maps, update the LocalMapUrl attribute with the location and name of the TPK file on the mobile device. Also, for iOS devices, update the iosMapAccessMethod attribute to use either the Documents folder or the bundle. v For Android devices, this is androidLocalMapUrl="file://folder_path/ map_file_name.tpk". v For iOS devices, this is iosLocalMapUrl="file://folder_path/ map_file_name.tpk". You must also enter either useDocumentsFolder or useBundle for the iosMapAccessMethod attribute. b. For online maps, set the providerUrl attribute. The value can be any valid ArcGIS tile service. If you do not set the providerUrl attribute, the user-defined TPK file is used. In the providerUrl attribute, the type of map is specified, for example, World_Topo_Map: providerUrl="http://server.arcgisonline.com/ArcGIS/rest/services/ World_Topo_Map/MapServer/tile/{z}/{y}/{x}" 4. Save and close the file. 5. Build and deploy the application. What to do next Activate GPS Related concepts: Deploying applications to the server Related information: Enabling the Anywhere Administration application By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. Configuring Maximo Anywhere 21 Modifying apps with the Anywhere Administration application When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Adding maps to iOS devices To use maps on iOS devices, you either add the map file to the Work Execution and Inspection apps or download the map file to the device by using iTunes. Before you begin Create the maps that you need to add to the Work Execution app or the Inspection app. Enable the map view on the iOS device by updating the app.xml file to specify the name of the map and how to access the map file. About this task Adding the map file to the Work Execution app or the Inspection app before you deploy the app ensures that the same map file is deployed to all devices that download the app. When you provide an updated version of the map file and redeploy the app, the change is applied to all devices. Alternatively, if you add a map file to the device by using iTunes, different maps are used in the Work Execution app or Inspection app for individual devices. This method is useful if mobile workers operate in different geographical areas. Procedure v To add the same map file to the Work Execution app or Inspection app for all devices, copy the map file to the MaximoAnywhere\apps\app_name\iphone\native\ Resources\ISIImage.bundle\map_file_name.tpk directory and build and deploy the app. v To add a map file from any workstation to an individual device, copy the map to the device by sharing files in iTunes. Activating GPS Maximo Anywhere uses global positioning system (GPS) data to determine the geographical location of mobile workers and work orders. GPS is also needed to add position markers to the map view. Before you begin The map view must be enabled. About this task GPS is disabled by default because map support in Maximo Anywhere is optional. Procedure 1. From the maximoanywhere_home\MaximoAnywhere\apps\app_name directory, edit the app-feature.properties file and set the property gps.enabled=true. 2. Save and close the file. 3. Build and deploy the application. 22 Configuring Maximo Anywhere Related concepts: Deploying applications to the server Configuring route lines When the map view is enabled, you can control the color, transparency, and width of the route lines between markers. You can configure the route lines by using the Anywhere Administration application if it is enabled. About this task To change the color, transparency, and width of the route lines, you edit the worklight.properties file in the MaximoAnywhere\server\conf folder. The default width is 5. The default color is blue with 50 percent transparency (7F0000FF). The value for setting the color and transparency of the route lines is AARRGGBB. The AA value sets the level of transparency. The combined RRGGBB values set the color, where RR is red, GG is green, and BB is blue. Procedure 1. In the worklight.properties file, edit the si.map.directionsPathWidth property to change the width of the route lines. To change the color and transparency, edit the si.map.directionsPathColor property. 2. Build and deploy the application. Related information: Calculating the color and width values for map route lines Hex values for colors Enabling the Anywhere Administration application By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. Modifying apps with the Anywhere Administration application When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Configuring zoom levels When the map view is enabled, you can control the zoom level of the online maps. You can configure zoom levels by using the Anywhere Administration application if it is enabled. About this task To change the zoom level, you edit the worklight.properties file in the MaximoAnywhere\server\conf folder. The default value is 19. The default value, 19, is valid for the default URL for the Esri online maps that are configured in the app.xml file: providerUrl="http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/ MapServer/tile/{z}/{y}/{x}" The app.xml file is in the following directory: MaximoAnywhere\apps\app_name\ artifact . Configuring Maximo Anywhere 23 Other URLs have different valid zoom levels. In the default URL, the type of map is specified, in this case World_Topo_Map. If you want to use a different map type, change the type of map in the URL. For example, to see ocean basemaps, change the URL to specify Ocean_Basemap: http://server.arcgisonline.com/ArcGIS/rest/services/Ocean_Basemap/MapServer/ tile/{z}/{y}/{x} If you have other types of maps that are defined on your server, change the first part of the URL, using the pattern: tile/{z}/{y}/{x}, for example: http://myownserver.com/myUrlForBaseMaps/myBaseMapType/tile/{z}/{y}/{x} Procedure 1. In the worklight.properties file, edit the si.map.openLayers.maxZoom property to change the zoom level for the online maps. 2. Build and deploy the application. Related information: ESRI URL providers Enabling the Anywhere Administration application By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. Modifying apps with the Anywhere Administration application When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Enabling Real Signature for Maximo Anywhere mobile apps Real Signature is a platform-level feature for the Maximo Anywhere mobile apps that enables users to record images of signatures that are related to work orders or items. Signatures are stored with related work order or item data, and a signature can be accessed from the related work order or item details page. About this task By default, Real Signature is enabled for the IBM Maximo Anywhere Work Execution and IBM Maximo Anywhere Inspection mobile apps. Real Signature must be manually enabled for all other apps. The following options are available for how Real Signature is viewed within the apps: Dialog view When dialog view is enabled, and you access Real Signature within an app, the window for recording signatures appears as a pop-up window over the main screen. Signature view When signature view is enabled, and you access Real Signature within an app, the window for recording signatures replaces the main screen. You enable each view by using the following platform-level handlers: v To enable in the signature view, use the launchSignatureView handler, which is function(eventContext, callback, callbackParam). 24 Configuring Maximo Anywhere v To enable in the dialog view, use the launchSignatureDialog handler, which is function(eventContext, callback, callbackParam). The following parameters are used in both handlers: eventContext The context of the UI. The context can be associated with different kinds of items, including a menu item, button, or image. callback The function that you want to call when the signature is saved. callbackParam The parameters that you want to pass when the signature is saved. You can also customize Real Signature to enable specific business processes. To enable these customizations, use the _setBusinessContext handler, which is function(customDescription). For example, by including the handler, you can specify that signatures are taken when items are issued to Jim, a specific user. The specified context is automatically added to the attachment description of a signature that is recorded within that context. For example, when Jim accepts an issued item, his signature is recorded with the attachment description, Signature is taken when an item is issued to Jim. Procedure 1. In the maximoanywhere_home\MaximoAnywhere\apps\app_name\artifact directory, access the app.xml file for the application in which you are enabling Real Signature. 2. In the app.xml file, define the attachment resource as a main resource, and ensure that an attachment attribute is set for the attachment resource. 3. Add the signature view as part of a menu item. 4. Save and close the file. Recording signatures with Real Signature You can record and store images of signatures in Maximo Anywhere mobile apps. After a signature is recorded, it can be retrieved from the attachment list of the signature's associated work order or item. About this task A signature that is recorded in Real Signature includes the following elements: v The date and time of the signature. v Optionally, the context of the signature. v Optionally, the name of the person who signed the signature. Each signature is stored as an image and as part of an attachment object. The attachment description is automatically populated with the signature, and the date and the time of the signature. A default name is also given to the image. The signatures can be recorded in both connected and disconnected mode, but the signatures cannot be modified after they are recorded. Configuring Maximo Anywhere 25 Procedure 1. In an app where Real Signature is enabled, open the details page for a work order or item. 2. Select Capture Signature and add the signature in the Capture Real Signature view. Optionally, enter the name of the person who signed the signature. 3. Click Save. Activating bar code scans When bar code scans are activated, mobile device users can scan bar codes to review work order details. About this task By default, bar code scanning is turned off, but it can be turned on in the app-feature.properties file. When you activate bar code scans, the updated app must be deployed as a new app version. Users must download and install the new app version from the server. Procedure 1. Open the app-feature.properties file in the MaximoAnywhere\apps\app_name folder, locate the barcode.enabled property, and set this property to true. 2. Build and deploy the application. Related information: Deploying applications to the server Connecting Bluetooth bar code scanners to mobile apps To use a Bluetooth bar code scanner with a mobile app, you must pair the scanner to the device and then connect the scanner to the app. About this task To connect the scanner to the app, you scan characters at the beginning and end of an item bar code to separate bar codes from one another. The bar codes for these characters are provided in the scanner manufacturer's instructions. Otherwise, the app ignores scanned data. Procedure 1. Pair the bar code scanner to the device by following the scanner manufacturer's instructions. 2. Connect the scanner to the app: a. Add the prefix by scanning the bar codes that represent the opening bracket, [. b. Add the first suffix by scanning the bar codes that represent the backslash, \. c. Add the second suffix by scanning the bar codes that represent the closing bracket, ]. 3. To automatically reconnect if the device goes offline, scan the bar code for reconnecting the device. The bar code is provided in the scanner manufacturer's instructions. 26 Configuring Maximo Anywhere Enabling encryption of the local data store You enable data encryption at the level of the Maximo Anywhere project. When encryption is enabled, the data store that is created on the device for each mobile app is automatically encrypted. About this task You enable or disable data encryption by using the encryption setting in the build.properties file for the Maximo Anywhere project. The active setting applies to all applications that are then built and deployed for the project. By enabling data encryption, you increase the level of protection for application data that is stored on the device. However, the performance of the application might deteriorate because of the time that is required by the encryption and decryption processes. When you disable data encryption, the locally stored login password is still secured. By default, data encryption is disabled. At run time, you cannot convert the local data store from an encrypted format to a non-encrypted format and vice versa. If the data encryption setting changes between app updates, you must clear the cache and data for the current app version, uninstall the current version, and then install the updated version. When you clear app data, any unsynchronized data is lost. When you install and log in to the updated version of the app, the local data store is created in the format that corresponds to the active setting. Procedure 1. Open the build.properties file in the MaximoAnywhere folder. 2. Set the enableDataEncryption property. 3. Save and close the file. 4. Build and deploy the applications. Changing the heartbeat interval You can change the frequency of the heartbeat signal that is sent by active Maximo Anywhere apps to MobileFirst Server. About this task At run time, a Maximo Anywhere app generates a heartbeat signal at a frequency that is defined at system level. The signal is used to determine whether the app is connected to MobileFirst Server. If connectivity is confirmed, the app uploads local data changes that are not yet saved to the server. The frequency of the heartbeat therefore determines the frequency of the automatic upload. You define the frequency of the heartbeat signal by specifying the interval between successive signals in worklight.properties file for the Maximo Anywhere project. The active setting applies to all applications that are built and deployed for the project. The default heartbeat interval is 1200 seconds (20 minutes). A lower value reduces the battery life of devices on which the Maximo Anywhere apps run. Configuring Maximo Anywhere 27 Procedure 1. Open the worklight.properties file in the maximoanywhere_home\ MaximoAnywhere\server\conf directory. 2. In the si.device.heartbeat.timeInterval property, specify the value of the heartbeat interval in seconds. 3. Save and close the file. 4. Build and deploy the applications. Attachments properties The app-feature.properties file contains the property that enables attachments. The download and upload of attachments, the maximum size, and the location of attachments are controlled by properties in the worklight.properties file. You can also enable attachments by using the Anywhere Administration application if it is enabled. To enable attachments, edit the app-feature.properties file in the MaximoAnywhere\apps\app_name folder to set the attachments.enabled property to true. Attachments are enabled by default for apps that support attachments. To change the value of an attachment property, edit the worklight.properties file in the maximoanywhere_home\MaximoAnywhere\server\conf directory. 28 Default value Property Description si.device.downloadAttachments WithBulkDownload When the condition is true, attachments on work true orders are downloaded with a work list. App users can override the default value of this property by clearing the Download attachments with work list check box on the Settings view in the Maximo Anywhere Work Execution app. si.device.onlyBulkDownloadPrint WithReportAttachments By default, attachments that can be printed are downloaded with a work list. You can override the default by going to Maximo Asset Management and clearing the check box in the Print attached document with report if printable type option in the Attachment Properties window. Attachments can still be downloaded manually. true si.att.proxy.maxfilesize Controls the maximum size of an attachment that can be downloaded with a work list. You can change the default to a higher or to a lower number. 5242880 (5 MB) si.attach.uploadmaxsize Controls the maximum size of an attachment that can be uploaded with a work record. You can change the default to a higher or to a lower number. If you use Maximo Asset Management as a backend server, ensure that the attachment document property mxe.doclink.maxfilesize setting is equal to or greater than the setting for si.attach.uploadmaxsize. 10 MB si.attachment.basedirectory Controls the location of the base directory for attachments. If a mobile device is shared, attachments are added to multiple user directories, with one directory per user. All of the user directories are located under the base directory. To free up the space that is taken up by attachments, delete the attachments within the user directories or delete the default directory. anywhere Configuring Maximo Anywhere Default value Property Description si.attach.doclink.doctypes.defpath The default directory where attachments are stored. The directory name must match the directory set in the mxe.doclink.doctypes.defpath property and the mxe.doclink.path01 property of Maximo Asset Management. The directory must be accessible from both the application server and from the web server. If you have a multiple server environment, you must share this directory and use it on all of the relevant servers. DOCLINKS Related tasks: “Enabling the Anywhere Administration application” on page 6 By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. “Modifying apps with the Anywhere Administration application” on page 7 When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Timeout properties Both the amount of time allowed before a request times out and the amount of wait time before requests can be reissued after a timeout is controlled by properties in the worklight.properties file. You can also configure these timeout properties by using the Anywhere Administration application if it is enabled. The following examples describe the default behavior for requests that timeout in the Maximo Anywhere Work Execution app: v You attempt to access MobileFirst Server. A request timeout occurs, and you cannot reissue the request for 60 seconds. v You attempt to connect to the adapter. The request times out after 3 seconds. v You attempt to download large amounts of data. The request times out after 6 minutes. To change the value of a property, edit the worklight.properties file in the maximoanywhere_home\MaximoAnywhere\server\conf directory. Default value Property Description si.device.connectivity. timeout.interval The wait time between attempts to access 60000 ms MobileFirst Server. Specify 0 if you do not want an interval. If MobileFirst Server does not respond, an error is returned to the app. si.device.connectivity. timeout The amount of time allowed before the request to connect to the adapter times out. 3000 ms si.device.connectivity. timeout.stablepagination The amount of time allowed before the request to download large amounts of data such as lookup data times out. 360000 ms Related tasks: Configuring Maximo Anywhere 29 “Enabling the Anywhere Administration application” on page 6 By default, the Anywhere Administration application is disabled. When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. “Modifying apps with the Anywhere Administration application” on page 7 When you use the Anywhere Administration application to modify mobile apps, you do not need to rebuild and deploy the apps. When you define the group that can see the modifications to the apps, different users can see different types of data. Related information: Deploying applications to the server 30 Configuring Maximo Anywhere Notices This information was developed for products and services offered in the US. This material might be available from IBM in other languages. However, you may be required to own a copy of the product or product version in that language in order to access it. IBM may not offer the products, services, or features discussed in this document in other countries. Consult your local IBM representative for information on the products and services currently available in your area. Any reference to an IBM product, program, or service is not intended to state or imply that only that IBM product, program, or service may be used. Any functionally equivalent product, program, or service that does not infringe any IBM intellectual property right may be used instead. However, it is the user's responsibility to evaluate and verify the operation of any non-IBM product, program, or service. IBM may have patents or pending patent applications covering subject matter described in this document. The furnishing of this document does not grant you any license to these patents. You can send license inquiries, in writing, to: IBM Director of Licensing IBM Corporation North Castle Drive, MD-NC119 Armonk, NY 10504-1785 US For license inquiries regarding double-byte character set (DBCS) information, contact the IBM Intellectual Property Department in your country or send inquiries, in writing, to: Intellectual Property Licensing Legal and Intellectual Property Law IBM Japan Ltd. 19-21, Nihonbashi-Hakozakicho, Chuo-ku Tokyo 103-8510, Japan INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some jurisdictions do not allow disclaimer of express or implied warranties in certain transactions, therefore, this statement may not apply to you. This information could include technical inaccuracies or typographical errors. Changes are periodically made to the information herein; these changes will be incorporated in new editions of the publication. IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this publication at any time without notice. Any references in this information to non-IBM websites are provided for convenience only and do not in any manner serve as an endorsement of those © Copyright IBM Corp. 2013, 2016 31 websites. The materials at those websites are not part of the materials for this IBM product and use of those websites is at your own risk. IBM may use or distribute any of the information you provide in any way it believes appropriate without incurring any obligation to you. Licensees of this program who wish to have information about it for the purpose of enabling: (i) the exchange of information between independently created programs and other programs (including this one) and (ii) the mutual use of the information which has been exchanged, should contact: IBM Director of Licensing IBM Corporation North Castle Drive, MD-NC119 Armonk, NY 10504-1785 US Such information may be available, subject to appropriate terms and conditions, including in some cases, payment of a fee. The licensed program described in this document and all licensed material available for it are provided by IBM under terms of the IBM Customer Agreement, IBM International Program License Agreement or any equivalent agreement between us. The performance data and client examples cited are presented for illustrative purposes only. Actual performance results may vary depending on specific configurations and operating conditions. Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not tested those products and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products. This information is for planning purposes only. The information herein is subject to change before the products described become available. This information contains examples of data and reports used in daily business operations. To illustrate them as completely as possible, the examples include the names of individuals, companies, brands, and products. All of these names are fictitious and any similarity to actual people or business enterprises is entirely coincidental. COPYRIGHT LICENSE: This information contains sample application programs in source language, which illustrate programming techniques on various operating platforms. You may copy, modify, and distribute these sample programs in any form without payment to IBM, for the purposes of developing, using, marketing or distributing application programs conforming to the application programming interface for the operating platform for which the sample programs are written. These examples have not been thoroughly tested under all conditions. IBM, therefore, cannot guarantee or imply reliability, serviceability, or function of these programs. The sample 32 Configuring Maximo Anywhere programs are provided "AS IS", without warranty of any kind. IBM shall not be liable for any damages arising out of your use of the sample programs. Trademarks IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the web at "Copyright and trademark information" at www.ibm.com/legal/copytrade.shtml. Java and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle and/or its affiliates. Linux is a trademark of Linus Torvalds in the United States, other countries, or both. Microsoft, Windows, Windows NT, and the Windows logo are trademarks of Microsoft Corporation in the United States, other countries, or both. UNIX is a registered trademark of The Open Group in the United States and other countries. Terms and conditions for product documentation Permissions for the use of these publications are granted subject to the following terms and conditions. Applicability These terms and conditions are in addition to any terms of use for the IBM website. Personal use You may reproduce these publications for your personal, noncommercial use provided that all proprietary notices are preserved. You may not distribute, display or make derivative work of these publications, or any portion thereof, without the express consent of IBM. Commercial use You may reproduce, distribute and display these publications solely within your enterprise provided that all proprietary notices are preserved. You may not make derivative works of these publications, or reproduce, distribute or display these publications or any portion thereof outside your enterprise, without the express consent of IBM. Rights Except as expressly granted in this permission, no other permissions, licenses or rights are granted, either express or implied, to the publications or any information, data, software or other intellectual property contained therein. Notices 33 IBM reserves the right to withdraw the permissions granted herein whenever, in its discretion, the use of the publications is detrimental to its interest or, as determined by IBM, the above instructions are not being properly followed. You may not download, export or re-export this information except in full compliance with all applicable laws and regulations, including all United States export laws and regulations. IBM MAKES NO GUARANTEE ABOUT THE CONTENT OF THESE PUBLICATIONS. THE PUBLICATIONS ARE PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO IMPLIED WARRANTIES OF MERCHANTABILITY, NON-INFRINGEMENT, AND FITNESS FOR A PARTICULAR PURPOSE. IBM Online Privacy Statement IBM Software products, including software as service solutions, (“Software Offerings”) may use cookies or other technologies to collect product usage information, to help improve the end user experience, to tailor interactions with the end user or for other purposes. In many cases no personally identifiable information is collected by the Software Offerings. Some of our Software Offerings can help enable you to collect personally identifiable information. If this Software Offering uses cookies to collect personally identifiable information, specific information about this offering’s use of cookies is set forth below. Depending upon the configurations deployed, this Software Offering may use session and persistent cookies that collect each user’s name, user name, password, or other personally identifiable information for purposes of session management, authentication, single sign-on configuration or other usage tracking or functional purposes. These cookies can be disabled, but disabling them will also likely eliminate the functionality they enable. If the configurations deployed for this Software Offering provide you as customer the ability to collect personally identifiable information from end users via cookies and other technologies, you should seek your own legal advice about any laws applicable to such data collection, including any requirements for notice and consent. For more information about the use of various technologies, including cookies, for these purposes, see IBM’s Privacy Policy at http://www.ibm.com/privacy and IBM's Online Privacy Statement at http://www.ibm.com/privacy/details in the section entitled “Cookies, Web Beacons and Other Technologies” and the "IBM Software Products and Software-as-a-Service Privacy Statement" at http://www.ibm.com/software/info/product-privacy. 34 Configuring Maximo Anywhere Notices 35 IBM® Printed in USA