Skip to content

Install InfyHMS-SaaS Mobile App Installation

Make sure you have system requirements properly. For installation, you should have primary knowledge of Android and Kotlin application development since this app is built on these technologies.

Pre Requirement

You need to have following system requirements.

Flutter Sdk

Based on Flutter requirements. Please select the operating system on which you are installing Flutter.

Editor

You can build apps with Flutter using any text editor or integrated development environment (IDE) combined with Flutter's command-line tools.

If you prefer visual guidance, you can watch this tutorial video:

App Configuration

Change Package name

  • Select package name from manifest file.
  • Search name in around all project
  • For Search & Replace in Mac: CMD+SHIFT+F & CMD+SHIFT+R,
  • For Search & Replace in Windows: CTRL+SHIFT+F & CTRL+SHIFT+R ,
  • Replace name in all project
  • Run flutter clean and flutter pub get in the terminal

Api Configuration

To establish a connection between your HMS (Hospital Management System) website and the mobile application, you need to configure the API settings. This involves updating the base URL used for API requests. Follow the steps below to properly configure the API:

  • Change Base URL: Locate the baseUrl variable in the following files: lib/api_request/api_request.dartlib/api_request/api_request.g.dart
  • Update Base URL: Find the baseUrl variable within the file. Replace the existing value of baseUrl with your HMS website's URL, followed by /api.

1. Update AndroidManifest.xml: Change the android:host name according to your desired domain.

2. Config your info.plist file.: Set the CFBundleURLName value to match the android:host name used in the AndroidManifest.xml file.

3. Update Web Code: Modify the URL domain name in the AuthAPIController.php file located at app/Http/Controllers/API/.

  • Ensure that the same name is used consistently across these three configurations to maintain proper functionality.

Customization

App Name

  • Android: To change the app name on Android, you need to update the android:label attribute in the application tag within the AndroidManifest.xml file.
  • iOS: For iOS, you can change the app name by updating the CFBundleDisplayName value in the Info.plist file. This file is typically located within the ios/Runner directory of your Flutter project.
  • Also change title value according your app name in main.dart file Ensure consistency across both platforms to maintain a unified brand identity.
  • Ensure you've replaced your logo file with HMSSaasLogo.png image in the assets’s images folder.
  • After replacing, run the flutter pub run flutter_launcher_icons command again in the terminal to update the app logo.

App Build Process

To build your Flutter application for both Android and iOS platforms, follow these steps:

Android

  • Generate an Android APK: Run the following command in your terminal flutter build apk This command compiles your Flutter app's source code into an APK file for Android.
  • Locate the Android APK: Once the build process is complete, you can find the generated APK file in the build/app/outputs/flutter-apk/ directory of your Flutter project.
  • Test the Android APK: Before distributing your Android app, it's essential to test it thoroughly. Install the APK on an Android device or emulator to ensure that all features are functioning correctly.
  • Publish App on Playstore: Please refer this official guide from flutter to Publish app.
  • How to upload app on play store step by step.

iOS

  • Generate an iOS build: Run the following command in your terminal flutter build ios This command compiles your Flutter app's source code into an iOS build.
  • Locate the iOS build: Once the build process is complete, you can find the generated iOS build in the build/ios/ directory of your Flutter project.
  • Test the iOS build: Before distributing your iOS app, it's essential to test it thoroughly. Install the app on an iOS device or simulator to ensure that all features are functioning correctly.
  • Prepare for distribution: To distribute your iOS app, you need to sign it with a valid Apple Developer account and create the necessary provisioning profiles. Follow the instructions in the Flutter documentation for detailed guidance on code signing and distribution.
  • Flutter Tutorial - How to Publish Flutter App on App Store .

Congratulations! You have successfully built the APK for your Flutter application.

If you encounter any issues during the build process, feel to contact our support at https://infyomlabs.authordesk.app.