Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding API endpoints #423

Open
wants to merge 36 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
428c25a
Update gemfile
Shaher-11 May 11, 2021
0c06127
Add project ERD
Shaher-11 May 11, 2021
6372fb3
Update ERD
Shaher-11 May 12, 2021
ad4445b
Merge pull request #1 from Shaher-11/project_erd
Shaher-11 May 12, 2021
1d58819
Create friendship model
nikoescobal May 14, 2021
c1a5632
Setup association for friendship model
Shaher-11 May 14, 2021
b2fafc6
Fix linters
Shaher-11 May 14, 2021
6fb5faa
Set the complete association for friendhsip model
Shaher-11 May 14, 2021
88774f8
Add tests for friendhsip model
Shaher-11 May 14, 2021
da1be4c
Add tests for user model
Shaher-11 May 14, 2021
a6ad04d
Add the integration tests
Shaher-11 May 14, 2021
b32e891
Merge pull request #2 from Shaher-11/friendship
Shaher-11 May 14, 2021
a4ac04c
Add accept and decline methods.
nikoescobal May 17, 2021
c25a643
Add create_friendship and set_user methods, add before_action restric…
nikoescobal May 17, 2021
0b6f197
Merge branch 'implement-friendship' of github.com:Shaher-11/ror-socia…
Shaher-11 May 17, 2021
996ce89
Add links for friendship invitaions
Shaher-11 May 17, 2021
db3aa65
Add the helper methods for for the buttons
Shaher-11 May 17, 2021
abf2468
Set up routes for user controller actions.
nikoescobal May 19, 2021
4ddfbe9
Add validations to display friendship invitation
nikoescobal May 19, 2021
0a07a1f
Add minor styling.
nikoescobal May 19, 2021
ccd012d
Add buttons to user partial
Shaher-11 May 19, 2021
6ac6c67
Fix linters
Shaher-11 May 19, 2021
f8cc3b5
Fix the tests as well the users friendship functionality
Shaher-11 May 19, 2021
45acca7
Update the linters file
Shaher-11 May 19, 2021
d2a6d34
Enable user to see his own and friends posts as well as adding more i…
Shaher-11 May 19, 2021
5b6d9ef
Merge pull request #3 from Shaher-11/implement-friendship
Shaher-11 May 20, 2021
d17dcd3
Merge branch 'develop' of github.com:Shaher-11/ror-social-scaffold in…
Shaher-11 May 20, 2021
d69920d
Update README.md
nikoescobal May 20, 2021
db61d7d
Update README.md
nikoescobal May 20, 2021
eb56d0c
Update routes
nikoescobal Jan 6, 2022
8a14277
Add API endpoints for displaying posts and comments in json format.
nikoescobal Jan 6, 2022
2f2e41d
Add authentication
nikoescobal Jan 7, 2022
3a979ee
Fix linters
nikoescobal Jan 7, 2022
9805543
Fix double render error and post request api endpoint
nikoescobal Jan 7, 2022
9f6e919
Remove comments and unnecessary code
nikoescobal Jan 7, 2022
73f15c7
Fix rubocop errors
nikoescobal Jan 7, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/linters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
with:
ruby-version: 2.6.x
ruby-version: 3.0.x
- name: Setup Rubocop
run: |
gem install --no-document rubocop:'~>0.81.0' # https://docs.rubocop.org/en/stable/installation/
gem install --no-document rubocop -v '>= 1.0, < 2.0' # https://docs.rubocop.org/en/stable/installation/
[ -f .rubocop.yml ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/ror/.rubocop.yml
- name: Rubocop Report
run: rubocop --color
Expand All @@ -30,7 +30,7 @@ jobs:
node-version: "12.x"
- name: Setup Stylelint
run: |
npm install --save-dev stylelint@13.3.x stylelint-scss@3.17.x stylelint-config-standard@20.0.x stylelint-csstree-validator
npm install --save-dev [email protected] [email protected] stylelint-config-standard@21.x stylelint-csstree-validator@1.x
[ -f .stylelintrc.json ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/ror/.stylelintrc.json
- name: Stylelint Report
run: npx stylelint "**/*.{css,scss}"
6 changes: 4 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }

ruby '2.7.0'

# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.2.4'
# Use postgresql as the database for Active Record
Expand Down Expand Up @@ -36,15 +34,18 @@ gem 'wdm', '>= 0.1.0' if Gem.win_platform?

# Reduces boot times through caching; required in config/boot.rb
gem 'bootsnap', '>= 1.1.0', require: false
gem 'rack-cors'

gem 'devise'

group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
gem 'byebug', platforms: %i[mri mingw x64_mingw]
gem 'rspec-rails'
end

group :test do
gem 'capybara'
gem 'rspec'
end

Expand All @@ -53,6 +54,7 @@ group :development do
gem 'listen', '>= 3.0.5', '< 3.2'
gem 'web-console', '>= 3.3.0'
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
gem 'hirb'
gem 'rubocop'
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
Expand Down
Loading