Giter VIP home page Giter VIP logo

sos's Introduction

SOS Angola

https://sos.ao

Requirements

Software Version Description
Ruby 2.7.1 Ruby Programming Language
PostgreSQL 12.x or higher Relational Database System
Nodejs Latest LTS version JavaScript Runtime
Yarn 1.22.x or < 2 Javascript Package Manager

Install Dependencies

Backend

$ bundle install

Frontend

$ yarn install

Setup Database

SOS Angola project uses PostgreSQL as a relational database system. After install PostgreSQL locally, you can create database and tables structures as follows.

Start creating the database (First time):

$ bundle exec rails db:create

Run all pending migrations:

$ bundle exec rails db:migrate

Running the application locally

You need to setup a local hostnames that points to 127.0.0.1.

sos.local -> 127.0.0.1
app.sos.local -> 127.0.0.1
api.sos.local -> 127.0.0.1

Backend

$ bundle exec rails s -b 0.0.0.0

Frontend

$ bin/webpack-dev-server

Running test suite and Linters

Backend

$ bundle exec rspec

$ bundle exec rubocop

Frontend

Contributing / Participation

Contibutions are welcome!

Note please that following is strongly requested:

  • All changes must be submitted through PRs.
  • Create only one PR per feature, bug fix or improvement.
  • Document your PR properly in commits and PR
  • Add tests for your changes and make sure they don't break existing tests.
  • Run code linters (rubocop for Ruby, Prettier/ESLint for JavaScript) before submit your PR.

sos's People

Contributors

josecage avatar psantos10 avatar renovate-bot avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

sos's Issues

Volunteer Model

Fields

  • Fullname
  • Email
  • Phone
  • Password
  • Types of available to provide
  • Province
  • County (Munícipio)

[Backend] - Endpoint to Register new Help

Endpoint:

POST /api/helps

Example Body:

{
  help: {
    help_type: "donation_food_clothes"
    title: "Need help with food for my children",
    description: "We don't have anything to give my children to eat. Please any kind of help will be appreciated",
    fullname: "Jane Doe",
    email: "[email protected]",
    cellphone: "924323233",
     alternative_cellphone: "994323233",
     province: "Luanda",
     county: "Belas",
     district: "Kilamba",
     neighborhood: "Kilamba",
     address: "Rua XYZ, Edificio K, Nº 130 - 2º Andar ESQ"
  }
}

Returns:

Code: 201

Created Object

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • Update dependency active_model_serializers to v0.10.13
  • Update dependency bcrypt to v3.1.19
  • Update dependency bulma-switch to v2.0.4
  • Update dependency ruby to v2.7.8
  • Update dependency spring to v2.1.1
  • Update dependency will_paginate to v3.3.1
  • Update dependency annotate to v3.2.0
  • Update dependency bootsnap to v1.16.0
  • Update dependency brakeman to v4.10.1
  • Update dependency database_cleaner-active_record to v1.99.0
  • Update dependency factory_bot_rails to v6.2.0
  • Update dependency faker to v2.23.0
  • Update dependency jbuilder to v2.11.5
  • Update dependency listen to v3.8.0
  • Update dependency pg to v1.5.4
  • Update dependency prop-types to v15.8.1
  • Update dependency rack-attack to v6.7.0
  • Update dependency rails to '~> 6.1.0', '>= 6.1.7.6'
  • Update dependency rspec-rails to v4.1.2
  • Update dependency rubocop to v0.93.1
  • Update dependency rubocop-performance to v1.19.1
  • Update dependency rubocop-rails to v2.21.1
  • Update dependency rubocop-rspec to v1.44.1
  • Update dependency shoulda-matchers to v4.5.1
  • Update dependency simplecov to v0.22.0
  • Update dependency spring-watcher-listen to '~> 2.1.0'
  • Update dependency web-console to v4.2.1
  • Update dependency webpacker to v5.4.4
  • Update postgres Docker tag to v12.16
  • Update actions/checkout action to v4
  • Update dependency @rails/actioncable to v7
  • Update dependency @rails/activestorage to v7
  • Update dependency @rails/ujs to v7
  • Update dependency brakeman to v6
  • Update dependency faker to v3
  • Update dependency prettier to v3
  • Update dependency rails to v7
  • Update dependency react-redux to v8
  • Update dependency react-router-dom to v6
  • Update dependency rspec-rails to v6
  • Update dependency rubocop to v1
  • Update dependency rubocop-rspec to v2
  • Update dependency ruby to v3
  • Update dependency spring to v4
  • Update dependency webpack-dev-server to v4
  • Update dependency will_paginate to v4
  • Update postgres Docker tag to v16
  • 🔐 Create all rate-limited PRs at once 🔐

Edited/Blocked

These updates have been manually edited so Renovate will no longer make changes. To discard all commits and start over, click on a checkbox.

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

bundler
Gemfile
  • ruby 2.7.1
  • rails '~> 6.0.3', '>= 6.0.3.2'
  • pg '>= 0.18', '< 2.0'
  • puma '~> 4.1'
  • sass-rails '>= 6'
  • webpacker '~> 5.0'
  • turbolinks '~> 5'
  • jbuilder '~> 2.7'
  • active_model_serializers '~> 0.10.10'
  • bcrypt '~> 3.1.13'
  • rack-attack '~> 6.2', '>= 6.2.2'
  • will_paginate '~> 3.3'
  • bootsnap '>= 1.4.2'
  • byebug undefined
  • pry-rails undefined
  • factory_bot_rails undefined
  • faker undefined
  • rspec-rails '~> 4.0'
  • annotate '~> 3.1', '>= 3.1.1'
  • brakeman undefined
  • listen '~> 3.2'
  • web-console '>= 3.3.0'
  • spring undefined
  • spring-watcher-listen '~> 2.0.0'
  • rubocop undefined
  • rubocop-performance undefined
  • rubocop-rails undefined
  • rubocop-rspec undefined
  • database_cleaner-active_record '~> 1.8'
  • shoulda-matchers '~> 4.3'
  • simplecov undefined
github-actions
.github/workflows/ci.yml
  • actions/checkout v2
  • actions/setup-ruby v1
  • postgres 12.2-alpine
npm
package.json
  • @babel/preset-react 7.10.1
  • @rails/actioncable 6.0.3
  • @rails/activestorage 6.0.3
  • @rails/ujs 6.0.3
  • @rails/webpacker 5.1.1
  • @reduxjs/toolkit 1.3.6
  • axios 0.19.2
  • babel-plugin-transform-react-remove-prop-types 0.4.24
  • bulma 0.9.0
  • bulma-steps 2.2.1
  • bulma-switch 2.0.0
  • connected-react-router 6.8.0
  • prop-types 15.7.2
  • react 16.13.1
  • react-dom 16.13.1
  • react-js-pagination 3.0.3
  • react-redux 7.2.0
  • react-router-dom 5.2.0
  • redux 4.0.5
  • turbolinks 5.2.0
  • prettier 2.0.5
  • webpack-dev-server 3.11.0
ruby-version
.ruby-version

  • Check this box to trigger a request for Renovate to run again on this repository

[Frontend] - Fix navigation link to homepage

As we already have the site name as a navbar link I think we don't need need to add "Página Inicial" again linking to the same page.

The goal is to keep only the site name linking to homepage route.

[Backend] - Endpoint to List all help requests

Endpoint:

GET /api/helps

Return
HTTP code: 200

JSON Response:

[
     {id: 1, title: "Help 1", description: "Help 1 Needed", ...},
     {id: 2, title: "Help 2", description: "Help 2 Needed", ...}
  ]

User Model

Users who manage the system

Fields:

  • Name
  • Email
  • Password
  • Phone number

Privacy Page

/politica-de-privacidade

Page with privacy policy text

[Backend] - Endpoint to Register new Volunteer

Endpoint:

POST /api/volunteers/create

Example Body:

{
  volunteer: {
    fullname: "John Doe",
    email: "[email protected]",
    password: "secret$123",
    cellphone: "924323232",
     province: "Luanda",
     county: "Belas"
     types_of_availability: "donation_food_clothes, psychological_support"
  }
}

Returns:

Code: 201

Created Object

Sugestão de mudanças conceituais

Ainda estou criando meu ambiente de desenvolvimento em ruby/rails e aproveitei ir pensando no workflow. Do jeito que está hoje a base do sistema, acredito que precisa de algumas mudanças:

  1. As pessoas que realmente precisam de ajuda, não têm condições de ter acesso ao um PC com internet para submeter os seus pedidos de ajuda. Então acredito que será algo mais do tipo: "pessoas que identificaram necessitados ou necessidades'. Significa que o formulário deve ser ajustado para indicar onde, o quê ou quem precisa de ajuda (não a pessoa que está preenchendo o formulário).
  2. A parte de 'Os pedidos de ajuda serão analisados pelos nossos colaboradores voluntários antes de serem publicados.' devem ser as instituições de caridade já existentes, que terão a plataforma para identificar os mais necessitados e focalizar seus esforços neles.

Help Model

Fields:

  • Help Type
  • Title
  • Description
  • Fullname
  • Email
  • Phone number
  • Alternative phone number
  • Province
  • County (Munícipio)
  • District
  • Neighborhood
  • Street
  • Number
  • Status (pending, active, inactive, deleted)

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.