Git Product home page Git Product logo

de-urgenta-android's Introduction

De urgenta - Android app

GitHub contributors GitHub last commit License: MPL 2.0

Check out the Wiki!

De Urgență was prototyped in Code for Romania's research project, Civic Labs.

The application aims to inform citizens about how to react to the first critical hours in a crysis situation (like that of an earthquake).

It also aims to build healthy habits that become ingrained with time, so that, when the critical moment arrives, each person knows what the key first steps to keeping themselves safe are.

Contributing | Built with | Repos and projects | Feedback | License | About Code4Ro

Contributing

This project is built by amazing volunteers and you can be one of them! Here's a list of ways in which you can contribute to this project. If you want to make any change to this repository, please make a fork first.

Help us out by testing this project. If you see something that doesn't quite work the way you expect it to, open an Issue. Make sure to describe what you expect to happen and what is actually happening in detail.

If you would like to suggest new functionality, open an Issue and mark it as a [Feature request]. Please be specific about why you think this functionality will be of use. If you can, please include some visual description of what you would like the UI to look like, if you are suggesting new UI elements.

Built with

  • Android Studio 2020.3.1
  • Android SDK 31
  • Kotlin
  • RxJava, Retrofit2
  • Koin
  • Room database
  • Firebase crashlytics, analytics & push notifications

Uses Fastlane for automating builds & releases.

Uses the MVVM architectural pattern.

To check and fix formatting issues you can use the following commands:

  • ./gradlew ktlintCheck
  • ./gradlew detekt
  • ./gradlew lint

To generate dependency updates, you can run the following command:

  • ./gradlew dU

UI design

Figma

API endpoints

Swagger

Repos and projects

Android repo
iOS repo
Web app - frontend
Web app - backend

Feedback

  • Request a new feature on GitHub.
  • Vote for popular feature requests.
  • File a bug in GitHub Issues.
  • Email us with other feedback [email protected]

License

This project is licensed under the MPL 2.0 License - see the LICENSE file for details

About Code for Romania

Started in 2016, Code for Romania is a civic tech NGO, official member of the Code for All network. We have a community of around 2.000 volunteers (developers, ux/ui, communications, data scientists, graphic designers, devops, it security and more) who work pro-bono for developing digital solutions to solve social problems. #techforsocialgood. If you want to learn more details about our projects visit our site or if you want to talk to one of our staff members, please e-mail us at [email protected].

Last, but not least, we rely on donations to ensure the infrastructure, logistics and management of our community that is widely spread across 11 timezones, coding for social change to make Romania and the world a better place. If you want to support us, you can do it here.

de-urgenta-android's People

Contributors

ancutapopescu avatar andreea-sicaru avatar aniri avatar catileptic avatar claudiubogdan avatar dekan avatar gabrielmajeri avatar ionutstoica14 avatar lukstbit avatar toaderandrei avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

de-urgenta-android's Issues

Implement layout for backpack fragments

Design main backpack fragments.

Please define related colors and text & button styles in the corresponding values files.

Clicking on the rucsacul meu option, should take the user to the next fragment. Clicking on aminteste-mi ...should take the user back to the home screen.

Add an enum for the backpack categories, as the category id should be sent to the backend when saving a new backpack item. These are:

1 - apă și alimente
2 - articole de igienă
3 - trusă de prim ajutor
4 - documente
5 - articole de supraviețuire
6 - diverse

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement course type picker fragment

Design course type picker fragment.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement layout for main courses fragment

Design main courses details fragment.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement forgot password flow

Implement the forgot password related screens.

Please define related colors and text & button styles in the corresponding values files.

image

to be added: reset password endpoint

After reseting the password, the user should be redirected to the login screen.

Link to design in Figma

Implement layout for about screen

Design about app fragment.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to design in Figma

Add layout for add backpack item fragment

Design add backpack item fragment.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement login fragment

Implement the login form screen as a fragment in the Login Activity.

Please define related colors and text & button styles in the corresponding values files.

image

to be added: login endpoint

After a successful login, the user should be redirected to the onboarding activity if onboarding was not completed and to the main activity otherwise.

User data (name, access token) should be saved in shared preferences.

Link to design in Figma

Replace `kotlin-android-extensions` Gradle plugin with View Binding and `kotlin-parcelize`

Building the project in Android Studio produces warnings such as:

The 'kotlin-android-extensions' Gradle plugin is deprecated. Please use this migration guide (https://goo.gle/kotlin-android-extensions-deprecation) to start working with View Binding (https://developer.android.com/topic/libraries/view-binding) and the 'kotlin-parcelize' plugin.

According to this Android Developers Blog post, the old kotlin-android-extensions will be removed in a Kotlin release during or after September 2021, so we should update our dependencies before then.

Implement layout for backpack items list

Design backpack items list fragment.

Please define related colors and text & button styles in the corresponding values files.

If the items list is empty, show an empty state message.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Clarification for password reset

@aniri Is the backend completely implemented for resetting the password?

I see the endpoint /auth/request-reset-password which has a correspondence to a screen in the application (02.2) , but this endpoint seem to just send a reset email.

For screen 02.3 I'm assuming that we should hit endpoint /auth/reset-password, but what should we use for userId and resetToken if the previous endpoint doesn't return anything?

Any thoughts on this?

Design home screen

Design home screen for main activity.

Please define related colors and text & button styles in the corresponding values files.

image

Please use navigation drawer and material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :)

Link to design in Figma

[BUG] Map jumps back to current location after search

Steps to reproduce:

  • go to configure addresses
  • the map will center on your current location
  • search for an address -> the map moves to the new address
  • wait a few seconds
  • the map jumps back to the users current location

Expected behaviour:

  • the map should not jump back to the current user location

Implement proper error handling mechanism

Implement an easy to use error handling mechanism.

Should support displaying snackbars and dialogs. Check the design in Figma for hints on how to design them, but follow the android material design guidelines for them.

These should be displayed easily in case of validation or api errors.

Redirect to login in case auth errors are received from the api. The rest of the api errors should be displayed in a dialog. TBD: api error format

Also, for certain requests, a snackbar error should be shown in case the user attempts to make the api call but is not connected to the internet.

Implement the course details screen

Design course details fragment. All the info to be displayed with be returned by the api.

The inscrie-te button will open the browser to a certain url from the course properties.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Fix app navigation

Navigation should work from onboading screen, main screen and menu.

Currently not all screens are reachable from all of the above options.

To be fixed in this issue -> navigation from side menu and home screen:

Onboarding screen:
image

Side menu:
image
items to be fixed:

  • emergency backpacks - should navigate to the same screen backpacks screen that is currently available only from onboarding

Home screen:
image
items to be fixed:

  • grupul de urgenta - should navigate to the same screen as from the emergency groups menu item
  • rucsacul de urgenta - should navigate to the same screen backpacks screen that is currently available only from onboarding

Implement add new group member

Depends on #58 and #60

Adding a new member should only be allowed from the edit group screen:
image

Please add proper permission handling for requesting access to contacts.

After clicking the add new member option and allowing access to contacts, the list of contacts should be displayed, similar to:
image

The button at the bottom of the screen is not needed, only the buttons next to each contact should be added. Pressing the button should open the send sms app with a custom text pre-filled (the text should be extracted in the strings file).

To be implemented in the future, after backend is ready: the link to be added in the sms should be retrieved form the backend.

Implement add new group member functionality. Link to API in swagger

Please define related colors and text & button styles in the corresponding values files.

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Implement edit group fragment

Depends on #58

Design edit group fragment.

image

Please ignore the "Invitație trimisă" link for now.

The API calls for editing a group are implemented. Link to API in swagger

Please complete ui navigation between fragments.

Please define related colors and text & button styles in the corresponding values files.

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Implement add new address flow fragments

Implement the add address flow as reusable fragments.

Use them in the Onboarding Activity:

  • the first time the user selects the option to add a new address, the flow should start with the address type set to home
  • after adding the new address, the screen with the list of added addresses should be displayed with the option to add another address
  • the following time the user chooses to add a new address, the address type picker should be displayed first ( depends on #12 )

The addresses should also be stored locally after the success response from the backend.

In case there is no internet connection when the user tries to save the address, an error should be displayed ( depends on #8 )

Please define related colors and text & button styles in the corresponding values files.

Some basic scaffolding was added, but it needs to be cleaned up.

Map provider: here maps
to be added: save address endpoint

image

Link to design in Figma

Setup for main activity navigation menu

Design main menu and setup for navigation between the main activity fragments.

Please define related colors and text & button styles in the corresponding values files.

image

Please use navigation drawer and material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :)

Link to design in Figma

Standardise layouts across different app screens

The https://www.figma.com/file/d6n3MPVRWbL5jP2NmvW96b/De_Urgenta?node-id=1466%3A530 has some parts that need to be adjusted in order to make the app respect the android material guidelines.

We could:

  • use the app bar to display all screen headers / titles
  • replace the x button with a more common < in the appbar for back navigation between fragments
  • replace images with proper vector icons (we should request all needed icons on slack)
  • standardise colors and text sizes fixed in #85

Implement add group fragment

Design add group fragment.

Prepare setup for api call and ui navigation between fragments.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement courses search results screen

Implement the courses search results fragment.

This screen will show up after the user selects a course city and type and presses the view course button (#32).

This screen should only show the search results, please ignore the dropdowns from the figma design.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement layout for groups landing page

Design first add group fragment.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to API in swagger

Link to design in Figma

Implement groups list fragment

Design group list fragment.

image

When opening the screen, all groups will be stacked. When clicking on a group name, the group members list should be retrieved from the api and expanded.

The numbers in parentheses after the group name are: the number of group members / maximum group members allowed (depends on code4romania/de-urgenta-backend#68)

GET /groups/my

GET /group/{groupId}/members

An "add new group" button / link is missing from the UI. Please add one :)

The API calls for getting the group list and group members list are implemented. Link to API in swagger

Please complete ui navigation between fragments. The groups list should open from the main menu & home screen.

Please define related colors and text & button styles in the corresponding values files.

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Implement main settings fragment

Design settings fragment.

Selecting the Raporteaza o problema option should open the email app to compose a new email. The to address should be pre-filled with a value stored in the properties files.

Please define related colors and text & button styles in the corresponding values files.

image

Please use material design guidelines for android. The figma design is a bit ios oriented, it needs a bit of adapting for android :) For example, the title should be placed in the action bar with a back button instead of the X.

Link to design in Figma

Implement add meeting point flow

Implement the add meeting point flow in onboarding.

This flow is very similar to the one for addresses. Please reuse as much as possible from #13

The addresses should also be stored locally after the success response from the backend.

In case there is no internet connection when the user tries to save the address, an error should be displayed ( depends on #8 )

Please define related colors and text & button styles in the corresponding values files.

Some basic scaffolding was added, but it needs to be cleaned up.

Map provider: here maps
to be added: save meeting point endpoint

image

Link to design in Figma

[BUG] Cleanup check location permissions flow

The location permissions should be required when loading and using the map (add addresses feature).

Sometimes the go to settings dialog seems to show up twice even if I click ok.

After I refused the locations permission, nothing happens when I try to navigate to configure addresses. The permission should be requested again and the user should be informed that the permission is mandatory for configuring addresses.

Implement backpack items expiration check service

Some items in the backpacks have expiration dates set for them. We need a service that will check daily if any of the items has expired. In case one of the items has expired, a dialog should be shown to inform the user.

To be decided: how often should we send reminders? What text should be displayed in the reminders?

Implement onboarding landing page

Implement the onboarding landing page as a fragment in the Onboarding Activity.

Please define related colors and text & button styles in the corresponding values files.

Some basic scaffolding was added, but it needs to be cleaned up.

image

Link to design in Figma

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.