Skip to content

Conversation

@yihyang
Copy link

@yihyang yihyang commented Sep 30, 2019

Issue: #738

Screenshot:

Screenshot 2020-05-17 at 11 31 30 PM

@matyikriszta
Copy link
Contributor

@yihyang thanks for the PR, please give me a few days to review it, I'll try to get to it this week

Copy link
Contributor

@notapatch notapatch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @yihyang

re "trust me I'm a programmer". Don't need to trust you as your pull request say you're a programmer. The code was immaculate. 👍

I'm a contributor - I can't approve your work and I don't know anymore about the issue than I've read. These are just my opinions. If you don't agree with them feel free to ignore. You've already met the maintainer @matyikriszta.

  1. I would squash the commits - I think it just makes it more difficult seeing the changes - I agree with all of the code climate changes.

  2. The grammar change throughout the test file (see other comment).

  3. The UX changes are listed below

    1. Margin between links
    2. Active links on the index to the item
    3. Toggling active/not-active with checkbox

1 margin between links

The links need a bit more margin between the links (see below).
spacing


2. Active links on the index to the item

I expect that indexes link through to the actual items - am I missing the link below?
inactive


3. Toggling active/not-active with checkbox

Isn't "Active?" and actions normally combined into a checkbox? (see below)
checkbox

👍

assert_chapters_exist_on_page(inactive_chapters)
end

scenario 'an admin can filter and view only active chapters' do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"filter and view" => "filter to view"

Personally, I would have written "an admin can view only active chapters" the filter is an implementation detail which is already implied - I don't have strong view on this.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @notapatch thanks for the suggestions, I have updated it in 91c732d

@yihyang yihyang force-pushed the feature/chapters_index_page branch from 0c3dec6 to f2d1698 Compare May 17, 2020 14:13
@yihyang
Copy link
Author

yihyang commented May 17, 2020

Hi @matyikriszta @notapatch , sorry for the late reply. I hope that everyone is safe during this times. I have updated the PR as per suggestion, please have a look, thanks!

@@ -0,0 +1,15 @@
module WaitForAjax
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notapatch
Copy link
Contributor

Hi @yihyang

@despo, the project owner, is active but I don't know the project's priorities as codebar has had to pivot to online workshops which has led to a lot of code changes. I hope she has the time.🤞

Copy link
Member

@despo despo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yihyang thanks for the PR. I left some feedback.

@chapter.update(update_active_params)

head :ok
end
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we stick to standard rails CRUD operations and reuse update to achieve this instead. The active param can just be part of chapter_params and the existing update method could be used to achieve the same thing.

.large-1.columns
= check_box_tag :chapter_active, 'true', chapter.active?, class: 'chapter_active', data: { 'chapter-id': chapter.id, }

- content_for :page_footer do
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't mind having javascript available as well, however it should be optional and not the default. Also, a confirmation button to verify disabling chapters before any actions take place.

@@ -0,0 +1,45 @@
%section#banner
.row
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a .row in foundation should contain column elements, so here there should be a large-12.columns to achieve correct alignment.

 
= link_to t('.view_inactive_chapters'), admin_chapters_path(active: false)
.row
%hr
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

similar to the comment above, as a row is made up of column elements, hr should be within a .large-12.columns

config/routes.rb Outdated
resources :member_notes, only: [:create]

resources :chapters, only: %i[index new create show edit update] do
member do
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this can be removed as per comments added above


background { login_as_admin(member) }

scenario "an admin can view all chapters and it's information" do
Copy link
Member

@despo despo May 17, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you please update to ...all chapters and their information

@github-actions
Copy link

github-actions bot commented Dec 3, 2020

This PR has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the Stale label Dec 3, 2020
@github-actions
Copy link

github-actions bot commented Jan 3, 2021

Closing as stale.

@github-actions github-actions bot closed this Jan 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants