Giter Club home page Giter Club logo

skunkworks-bat's Introduction

ODK-X Notify (Mobile)

Platform License

This project is under development.

ODK-X Notify has 2 components: a desktop application and a mobile application.

The mobile application an Android app for field workers that receives notifications sent by their supervisors through the ODK-X Notify desktop application. ODK-X Notify uses Firebase Cloud Messaging for receiving notifications. It is part of ODK-X, a free and open-source set of tools which help organizations author, field, and manage mobile data collection solutions. Learn more about the Open Data Kit project and its history here and read about example ODK deployments here.

Setting up your development environment

  1. Download and install Git and add it to your PATH

  2. Download and install Android Studio

  3. Fork the collect project (why and how to fork)

  4. Clone your fork of the project locally. At the command line:

     git clone https://github.com/YOUR-GITHUB-USERNAME/skunkworks-bat
    

If you prefer not to use the command line, you can use Android Studio to create a new project from version control using https://github.com/YOUR-GITHUB-USERNAME/skunkworks-bat.

  1. Open the project in the folder of your clone from Android Studio.
  2. Create a Firebase project and add the google-services.json file in your android app module root directory. Step by step instructions for creating a Firebase project can be found here.
  3. To run the project, click on the green arrow at the top of the screen. The emulator is very slow so we generally recommend using a physical device when possible.
  4. Add the google-services.json file (obtained in step 2) in your phone's external storage at the following location: /opendatakit/default/config/assets/google-services.json.

Prerequisites

ODK-X Services is needed to be installed in the device for the app to work. The application sync user's infromation from ODK Services.

How to contribute

If you’re new to ODK-X you can check out the documentation:

Once you’re up and running, you can choose an issue to start working on from here: 

Issues tagged as good first issue should be a good place to start.

Pull requests are welcome, though please submit them against the development branch. We prefer verbose descriptions of the change you are submitting. If you are fixing a bug please provide steps to reproduce it or a link to a an issue that provides that information. If you are submitting a new feature please provide a description of the need or a link to a forum discussion about it.

Links for users

This document is aimed at helping developers and technical contributors. For information on how to get started as a user of ODK-X, see our online documentation, or to learn more about the Open Data Kit project, visit https://odk-x.org.

skunkworks-bat's People

Contributors

ak8527 avatar codeknight3 avatar dreamyphobic avatar iamvasuh avatar jbeorse avatar laddha-adi avatar linl33 avatar maprehensive avatar shubhamr837 avatar thesherrinford avatar udhay24 avatar wbrunette avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

skunkworks-bat's Issues

FirebaseApp has not been initialized properly.

W/System.err: java.io.FileNotFoundException:/storage/emulated/0/opendatakit/default/config/assets/google-services.json (No such file or directory)
W/System.err: at java.io.FileInputStream.open0(Native Method)
at java.io.FileInputStream.open(FileInputStream.java:200)
at java.io.FileInputStream.(FileInputStream.java:150)
at org.odk.odknotifications.Activities.MainActivity.loadJSONFromAsset(MainActivity.java:134)
at org.odk.odknotifications.Activities.MainActivity.readConfigFile(MainActivity.java:457)
at org.odk.odknotifications.Activities.MainActivity.requestStoragePermission(MainActivity.java:494)
at org.odk.odknotifications.Activities.MainActivity.onCreate(MainActivity.java:97)

Starting issue:

It shows on starting please add odk dependencies to continue.
Nothing like that is mentioned in readme.

Home Screen is empty.

Current Behaviour
Home screen shows nothing for now.

Expected Behaviour
I think there should be a list of all the notifications on the home screen with an option to filter w.r.t group and also an option to sort according to our need.

Add issue and PR template

Currently, there is no issue and PR template
Add issue and PR template like odk collect

Other Information

please have a look here for the template of odk collect

Add permissions requests

Currently the user must open Services first to grant permissions. This app should handle its permissions requests.

Application crashes when account is not configured and sync button from the menu is clicked

Android Device Used:
Xiaomi Redmi Note 5, Android Api 27.
Problem Description
When odk services isn't configured the sync button causes application to crash instead of an error message.
Steps To Reproduce

  1. Download the ODK notify App on your android Device.
  2. Make sure you havent configured the server in Odk services application . If configured remove the configuration.
  3. Open the application and select the Sync Option from the menu.
    Expected Behaviour
    Sync is not possible Without Server configuration, so the option should be disabled .
    . Gif image attached

20191107_101103

Application Crashes on selecting sync option from menu .

Application Crashes on selecting sync from menu when sync endpoint is not configured and firebase is configured .
steps to reproduce -:

1 . configure firebase and download the google-services.json file

2 . manually add the google-services.json file to its location .

3 . open the app , the sync button gets enabled as the google-services.json file is found ,
click on the sync button the application would crash .

Migrating to AndroidX from support lib

@jbeorse can we migrate to androidX since android support lib is deprecated, as the android documentation says

You can continue to use the support library. Historical artifacts (those versioned 27 and earlier, and packaged as android.support.*) will remain available on Google Maven. However, all new library development will occur in the AndroidX library.

We recommend using the AndroidX libraries in all new projects. You should also consider migrating existing projects to AndroidX as well.

New Notification does'nt appear in application when application is open.

When the application is open and a new notification is received the notification is delivered but in the application it is not visible .
The application has to be closed and opened again for the new notification to appear .

Steps to reproduce :-
1 . open the application ( configured firebase and synced ).
2 . send a notification .
3 . close and open the application again .

after the 3rd step the notification would be visible in the application but it would not be visible in step 2 after receiving the notification .

Show a message when there's no notification present on Home screen

Issue

Home screen appears empty when there's no notification present as shown below in given screenshot.

Annotation 2020-03-17 130129

Expected

It should display some message like "No Data available" or "No Notifications Received Yet" something like that. For example, see the below screenshot:

Annotation 2020-03-17 130129

FirebaseApp still getting initialized twice.

Steps to reproduce:
Assuming that google-servies.json is located at the correct place.

  1. Open the app and make sure it doesn't show any warning.
  2. Click on Scan QR button.
  3. After scanning code, the app is reopened by intent through the link.
  4. Here, the app crashes because of twice initialization of FirebaseApp.

SavedInstances method doesn't work because here the app has reopened, it isn't able to fetch the value of hasbeenInitialized boolean.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.