Skip to content

Background processes

BhumikaDatamatics edited this page Jun 27, 2024 · 10 revisions

Conditions on premature child profiles

Validations:

  • User can edit date of birth of the child if user has entered pregnancy details and if the expected child is born before the due date.
  • App won’t allow users to track progress in the Development tool as child is not born yet.
  • User can see the content, but all actionable items are disabled like (add growth, update measurement, add vaccination, add health check-up details).

Logic:

  • Premature Tag and Calculation – the app displays 1st month of development details if child was born 2 months earlier than the actual due date and completes 2 months. The applied age is the corrected age. (Please see Adjusted Age Calculator - Preterm Babies Corrected Age on mdapp.co)
  • Clicking on “Premature” tag on the screen informs parent about “corrected age” is applied when featuring content of Games, Development, and Child’s growth.

User-generated data

There is an option to add, update and delete various data by the user, e.g height and weight measurements of a child on a specific date. All data entered is stored in a mobile app so users can manage in online and offline mode. Below are the types of data a user can enter:

  • Child birth details
  • Growth details
  • Vaccination details
  • Milestone details
  • Health checkup details
  • Additional doctor’s visit details

Validation is required in each field to limit user input like height, weight. So, users can add realistic data for development diary tools.

Max height and weight have been set as per standard which is hard coded as per from the min-max of growth chart.

Following are data types and validation for every user input:

Child birth details

Fields Fields Type Required Validations
Child_Gender Radio Buttons Yes
Child_Name Textbox Yes Max 15 characters
DOB Date picker Yes Should be past dates and up to 72 months ago
Is_Premature checkbox No
Original_Due_Date Date picker Yes* Required if Is Premature is checked
Child Photo Image No

Pregnancy details

Fields Fields Type Required Validations
Child_Name Textbox Yes Max 15 characters
DOB Date picker Yes Should be future dates till 9 months

Growth details

Fields Fields Type Required Validations
Height Range Selector Yes Max-min as per Growth chart data based on Adjusted Age calculator - Preterm Babies. Corrected Age
Weight Range Selector Yes Max-min as per Growth chart data
Date_of_Measurement Date picker Yes Any Past date or today’s date
Place_of_Measurement Dropdown Yes
Doc_Comments Text No

Vaccination details

Fields Fields Type Required Validations
Vaccine_name Radio Yes
Date_of_Vaccination Date Picker Yes Any past date or today’s date

Vaccination reminders

Fields Fields Type Required Validations
Reminder_Date Date Picker Yes Any future date
Reminder_Time Time Picker Yes

Milestone details

Fields Fields Type Required Validations
Milestones Check box

Health checkup details

Fields Fields Type Required Validations
Date_of_Checkup Date Picker Yes Any Past date or today’s date
Child_Measured Selection Yes Yes, No options
Child_Received_vaccine Selection Yes Yes, No options
Doc_Comments Text No

Health checkup reminders

Fields Fields Type Required Validations
Reminder_Date Date Picker Yes Any future date
Reminder_Time Time Picker Yes

Please refer below details and data flow of Growth, Vaccine and Health-checkup modules.

Data object for Health Check-ups, Vaccination and Growth

data-object

Add growth measurement flow

add-measurement-flow

Edit Health Check-up and Vaccination flow

edit-vc-and-hc

Edit/Delete Growth flow

edit-growth-flow

Content Sync from CMS to app

The app’s content is downloaded during onboarding in the language selected by the user. There are 3 way the content gets updated:

  1. Onboarding on Bebbo App
  2. Periodic sync
  3. Sync from Settings
  4. Sync when Force update is triggered by CMS user

Before any of these syncs happens, the app is installed with ‘pre-populated’ content that is embedded into the app code in all languages for those who use the app offline right after installation. This content includes the following:

APIs Languages JSON Size (KB)
Country and languages list Multilingual >200
Walkthrough text Multilingual >100
App sharing text Multilingual <50
T&C, About us, Privacy policy* Multilingual <20
Development diary tool data(HC, VC, Development Period, Growth)* Multilingual >800
1 article which is linked to all categories and age periods * Multilingual >10
Static text of mobile menus & all screen labels (UI string literals) Multilingual >400
1 Games per development period - total 12 games Multilingual >30
3 milestones in each development period Multilingual >15
Taxonomy data(master data) Multilingual >200
Standard deviation 45 scenario text Multilingual >10

Data which is marked as * is updated during one of the 3 methods of syncing. All pre-populated content is updated when a new version is released. Loading screen images (Dynamic sponsors and national partner images are added in build)

Note: User interface string literals stay embedded in app build for all languages.

Dynamic data which are downloaded via APIs (from CMS)

  1. Static page content
  2. Basic Pages (Terms and Conditions, About us, Privacy Policy and Survey links)
  3. Category and tags listing with all taxonomy data
  4. FAQ content
  5. Daily notification data
  6. All games details
  7. Articles for all child’s age period and all articles related to Growth, Development tool(milestone), Vaccination, Health Check-up
  8. Content for Tools - Growth, Development(milestones), Vaccination, Health Check-up - All age data is downloaded.

1. Onboarding on Bebbo App

Mobile application will download data on the app start on the below different screens.

1) Loading screen 1 - After country selection screen

When user select country and language confirm, Mobile app will download data from below apis.

  • basic-pages - Static page content like privacy policy, terms and condition, about us
  • taxonomies - Category and tags listing with all taxonomy data

2) Loading screen 2 - After terms and condition screen

When user accept terms and condition and proceed further at that time Mobile app will download data from below apis.

  • video-articles - Video Article data used in development tool and milestone videos
  • daily-homescreen-messages - Daily notification data for home screen
  • activities - All games details
  • surveys - Survey details
  • faqs - FAQ content
  • milestones - List of all milestones
  • child-development-data - Child development data
  • vaccinations - list of vaccine data
  • health_check_ups - List of Health checkup records
  • standard_deviation - 45 growth scenarios

3) Loading screen 3 - After adding Childs and proceed towards

  • articles - Articles for all child’s age periods from all categories.

{{bebboURL}}/api/articles/{{languageId}}?childAge=all&childGender=all&parentGender=all&category=all

2.Periodic sync

Mobile applications will download data periodically (monthly and weekly) when the user starts the app on a good network.

Mobile apps should only download data periodically to reduce mobile app bandwidth and mobile app loading time. For the few APIs as specified below, only delta data will be downloaded. Mobile app will keep record of the datetime when the last time api called. Datetime will be used as parameter when next time the same api will be called. Kindly refer below api for more details.

{{bebboURL}}/api/articles/{{languageId}}?childAge=all&childGender=all&parentGender=all&category=all&**datetime=2023-12-05 19:39**

API capabilities

The size of API files is very small in KBs, and large size API will only provide delta content hence for users with good bandwidth, the content should be refreshed from setting screen on user demand.

On the mobile side, APIs are divided into different groups which will sync data periodically as per different terms.

Weekly:

  • Category and tags listing with other taxonomy
  • FAQ content
  • All game details
  • All Articles data for all categories and all age periods
  • Video Articles

Monthly:

  • Static page content (About US, T&C, PP)
  • Daily notification data
  • Development diary tool data - growth (standard deviation), development tool(milestone)m development period, vaccination, health checkup - All age data will be downloaded.
Frequency API Size (kb) Delta download
Weekly articles 1mb to 2 mb Yes
Weekly video-articles 56.2 Yes
Monthly basic-pages 8.59 No
Monthly daily-homescreen-messages 5.75 No
Monthly milestones 12.06 No
Weekly faqs 51.92 Yes
Weekly taxonomies 30 No
Monthly child-development-data 3.73 No
Monthly vaccinations 2.28 No
Weekly activities 145.3 Yes
Monthly health-checkup-data 1.4 No
Monthly standard_deviation 2.99 No

Note: surveys and check-update apis are called every time on app start.

3. Sync from Settings

Download update

Content is updated when the ‘Download update’ button is tapped and confirmed. It only downloads content for all age period period and only delta content for the few APIs (article, games, video article, FAQ). When the download is complete, the user sees a message that updates were successful. If the download was interrupted, the user sees a notice and a prompt to retry downloading.

Download all data

Download all button allows users to download all articles for all age groups and all images for the respective articles in mobile for offline app usage. Images are downloaded as per data saver mode values.

  • If Data Saver Mode is turned ON the setting screen, app does not download images.
  • If Data Saver Mode is turned OFF on the setting screen, app download images.

Considering Data Saver Mode OFF, if low bandwidth detected then the app prompts the user to enable it for good performance.

Considering Data Saver Mode ON, but good bandwidth detected then the app prompts the user to disable it, so images are downloaded.

On first download all, it downloads all child group data, but when user downloads all data again at that time only updated delta is downloaded for a few APIs (article, games, video article, FAQ).

4. Force Update

There is a small API providing information about whether the app must update data. In the CMS, there is a flag that can be set/unset by CMS admin. If it is true then the mobile app must update mobile data, if it is false, then the mobile app can perform sync as per defined periodicity.

Modes of operation for mobile app

Full offline mode

App works with data available in offline Realm DB. All the screens and functionality are working in offline mode with available child data.

  • No network at first time user opens the app.

Multilingual data are saved in mobile incase after installation of mobile app user opens the app in offline mode. Users can see Prepopulated data which is saved in mobile apps and see the app content and details. Those details are limited. In offline mode users is notified that they have open applications offline with limited content, mobile app requires network connection to download new data.

  • No network on next time:

Previously downloaded content is saved on mobile DB. Mobile app displays the same available content on screens. If images are already cached or available on mobile is displayed. New images won't be downloaded.

Low bandwidth (data saver mode)

If a user has enabled data saver mode from the setting, the mobile app does not download images when users traverse to different screens.

Considering data saver mode OFF, if low bandwidth detected then the app prompts the user to enable it for good performance.

Considering data saver mode ON, but good bandwidth detected then the app prompts the user to disable it, so images are downloaded.

If the user wants to download images in data saver mode, then they can disable data saver mode from setting.

In React Native, mobile app detects low bandwidth as per below network types and connections using network libraries, accordingly mobile apps perform as per options.

Describes the current type of network connection. Possible values of network type:

Value Is low bandwidth Platform Description
none NA Android, iOS No network connection is active
unknown Yes Android, iOS The network state could not or has yet to be determined
cellular Partially Android, iOS Active network over cellular
wifi No Android, iOS Active network over Wifi
bluetooth Yes Android Active network over Bluetooth
ethernet No Android Active network over wired ethernet
wimax No Android Active network over WiMax
vpn Yes Android Active network over VPN
other Yes Android, iOS Active network over another type of network

Describes the current generation of the cellular connection. Possible values of cellular connection:

Value Is low bandwidth Description
null NA Either we are not currently connected to a cellular network or type could not be determined
2g Yes Currently connected to a 2G cellular network. Includes CDMA, EDGE, GPRS, and IDEN type connections
3g Yes Currently connected to a 3G cellular network. Includes EHRPD, EVDO, HSPA, HSUPA, HSDPA, and UTMS type connections
4g No Currently connected to a 4G cellular network. Includes HSPAP and LTE type connections

Good bandwidth

First time app starts using a good network.

Mobile app will download data as per user preference about language, country and added child data if good network is detected. That will help users to view personalized content.

Please note images download or synchronization will be made available only for users with bandwidth as downloading the images will be very heavy and not advisable for this scenario.

Next time app opens using a good bandwidth.

Data Saver Mode has been disabled from the setting the mobile app will download images when users traverse to different screens.

Considering Data Saver Mode ON, but good bandwidth detected then the app will prompt the user to disable it so images will download.

Mobile app installed and launched next time.

Mobile app will only check for the Survey API and force update API. If the Survey API has data, then the mobile app will process the data and save in mobile app for further use. If force update on CMS is turned on for that country, then updated data will be downloaded in the mobile app.

app-launch-flow

Monthly or weekly data sync is scheduled during app launch.

app-launch-weekly-sync

Other scenarios

When user adds another child

ONLINE - mobile app downloads article data for a newly added child.

OFFLINE - mobile app saves child data, but related data will be downloaded once the app is online. App will remind users to connect to the internet to download child age related data.

Editing child profile

When user updates any child details like date of birth or original due date, and data is not matched with the current development period, then new data will be downloaded as per new age. If development period will be the same after updating date of birth:

  • No need to download content. The same development period data is already there in the app.
  • No need to clean up development period data.
Child data in Tools and Articles DOB Original Due Date IsPremature ChildGender ParentGender
Entered Growth details Yes Yes* No No No
Entered Vaccination Details Yes No No No No
Entered Vaccination Reminder Yes No No No No
EnteredMilestone details No No No No No
EnteredHealth checkup details Yes No No No No
EnteredHealth checkup Reminder Yes No No No No
Entered Additional doctor Visit Details Yes No No No No
Article Data - Download No No No No No

Above table shows which field update impacts the entered data in the mobile app if development period is different after updating the child and parents’ details:

“Yes” means need to clean up previous data.

“No” means no impact on the details when a field gets updated.

  • Mobile app saves child data, but related data will be downloaded once the app is online.
  • App will remind users to connect to the internet to download child age related data.
  • Once user becomes online, the app downloads child age related content.