-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
109 changed files
with
1,789 additions
and
71 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
let g:vigun_extra_keywords = ['test'] | ||
|
||
let g:vigun_commands = [ | ||
\ { | ||
\ 'pattern': 'test/.*_test.rb$', | ||
\ 'normal': 'rails test', | ||
\ 'debug': 'BACKTRACE=1 rails test', | ||
\ } | ||
\] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/* | ||
Place all the styles related to the matching controller here. | ||
They will automatically be included in application.css. | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/* | ||
Place all the styles related to the matching controller here. | ||
They will automatically be included in application.css. | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/* | ||
Place all the styles related to the matching controller here. | ||
They will automatically be included in application.css. | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/* | ||
Place all the styles related to the matching controller here. | ||
They will automatically be included in application.css. | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
body { | ||
background-color: #fff; | ||
color: #333; | ||
margin: 33px; | ||
} | ||
|
||
body, p, ol, ul, td { | ||
font-family: verdana, arial, helvetica, sans-serif; | ||
font-size: 13px; | ||
line-height: 18px; | ||
} | ||
|
||
pre { | ||
background-color: #eee; | ||
padding: 10px; | ||
font-size: 11px; | ||
} | ||
|
||
a { | ||
color: #000; | ||
} | ||
|
||
a:visited { | ||
color: #666; | ||
} | ||
|
||
a:hover { | ||
color: #fff; | ||
background-color: #000; | ||
} | ||
|
||
th { | ||
padding-bottom: 5px; | ||
} | ||
|
||
td { | ||
padding: 0 5px 7px; | ||
} | ||
|
||
div.field, | ||
div.actions { | ||
margin-bottom: 10px; | ||
} | ||
|
||
#notice { | ||
color: green; | ||
} | ||
|
||
.field_with_errors { | ||
padding: 2px; | ||
background-color: red; | ||
display: table; | ||
} | ||
|
||
#error_explanation { | ||
width: 450px; | ||
border: 2px solid red; | ||
padding: 7px 7px 0; | ||
margin-bottom: 20px; | ||
background-color: #f0f0f0; | ||
} | ||
|
||
#error_explanation h2 { | ||
text-align: left; | ||
font-weight: bold; | ||
padding: 5px 5px 5px 15px; | ||
font-size: 12px; | ||
margin: -7px -7px 0; | ||
background-color: #c00; | ||
color: #fff; | ||
} | ||
|
||
#error_explanation ul li { | ||
font-size: 12px; | ||
list-style: square; | ||
} | ||
|
||
label { | ||
display: block; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/* | ||
Place all the styles related to the matching controller here. | ||
They will automatically be included in application.css. | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# frozen_string_literal: true | ||
|
||
class GroupTypesController < ApplicationController | ||
before_action :set_group_type, only: %i[show edit update destroy] | ||
|
||
def index | ||
@group_types = GroupType.all | ||
end | ||
|
||
def show; end | ||
|
||
def new | ||
@group_type = GroupType.new | ||
end | ||
|
||
def edit; end | ||
|
||
def create | ||
@group_type = GroupType.new(group_type_params) | ||
|
||
if @group_type.save | ||
redirect_to @group_type, notice: 'Group type was successfully created.' | ||
else | ||
render :new | ||
end | ||
end | ||
|
||
def update | ||
if @group_type.update(group_type_params) | ||
redirect_to @group_type, notice: 'Group type was successfully updated.' | ||
else | ||
render :edit | ||
end | ||
end | ||
|
||
def destroy | ||
@group_type.destroy! | ||
redirect_to group_types_url, notice: 'Group type was successfully destroyed.' | ||
end | ||
|
||
private | ||
|
||
def set_group_type | ||
@group_type = GroupType.find(params[:id]) | ||
end | ||
|
||
def group_type_params | ||
params.require(:group_type).permit(:name) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# frozen_string_literal: true | ||
|
||
class GroupWebsitesController < ApplicationController | ||
before_action :set_group_website, only: %i[show edit update destroy] | ||
|
||
before_action :set_group | ||
|
||
def index | ||
@group_websites = @group.websites | ||
end | ||
|
||
def show; end | ||
|
||
def new | ||
@group_website = @group.websites.new | ||
end | ||
|
||
def edit; end | ||
|
||
def create | ||
@group_website = @group.websites.new(group_website_params) | ||
|
||
if @group_website.save | ||
redirect_to [@group, @group_website], notice: 'Group website was successfully created.' | ||
else | ||
render :new | ||
end | ||
end | ||
|
||
def update | ||
if @group_website.update(group_website_params) | ||
redirect_to [@group, @group_website], notice: 'Group website was successfully updated.' | ||
else | ||
render :edit | ||
end | ||
end | ||
|
||
def destroy | ||
@group_website.destroy | ||
redirect_to group_group_websites_url(@group), notice: 'Group website was successfully destroyed.' | ||
end | ||
|
||
private | ||
|
||
def set_group | ||
@group = current_user.groups.find(params['group_id']) | ||
end | ||
|
||
def set_group_website | ||
@group_website = GroupWebsite.find(params[:id]) | ||
end | ||
|
||
def group_website_params | ||
params.require(:group_website).permit(:website, :group_id) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# frozen_string_literal: true | ||
|
||
class GroupsController < ApplicationController | ||
before_action :set_group, only: %i[show edit update destroy] | ||
|
||
def index | ||
@groups = Group.all | ||
end | ||
|
||
def show; end | ||
|
||
def new | ||
@group = Group.new | ||
end | ||
|
||
def edit; end | ||
|
||
def create | ||
@group = current_user.groups.new(group_params) | ||
|
||
if @group.save | ||
redirect_to @group, notice: 'Group was successfully created.' | ||
else | ||
render :new | ||
end | ||
end | ||
|
||
def update | ||
if @group.update(group_params) | ||
redirect_to @group, notice: 'Group was successfully updated.' | ||
else | ||
render :edit | ||
end | ||
end | ||
|
||
def destroy | ||
@group.destroy | ||
redirect_to groups_url, notice: 'Group was successfully destroyed.' | ||
end | ||
|
||
private | ||
|
||
def set_group | ||
@group = Group.find(params[:id]) | ||
end | ||
|
||
def group_params | ||
params.require(:group).permit( | ||
:name, | ||
:abbreviation, | ||
:opening_hours, | ||
:contact_name, | ||
:contact_email, | ||
:contact_phone, | ||
:gdpr, | ||
:gdpr_email_verified | ||
) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# frozen_string_literal: true | ||
|
||
class InitiativeStatusesController < ApplicationController | ||
before_action :set_initiative_status, only: %i[show edit update destroy] | ||
|
||
def index | ||
@initiative_statuses = InitiativeStatus.all | ||
end | ||
|
||
def show; end | ||
|
||
def new | ||
@initiative_status = InitiativeStatus.new | ||
end | ||
|
||
def edit; end | ||
|
||
def create | ||
@initiative_status = InitiativeStatus.new(initiative_status_params) | ||
|
||
if @initiative_status.save | ||
redirect_to @initiative_status, notice: 'Initiative status was successfully created.' | ||
else | ||
render :new | ||
end | ||
end | ||
|
||
def update | ||
if @initiative_status.update(initiative_status_params) | ||
redirect_to @initiative_status, notice: 'Initiative status was successfully updated.' | ||
else | ||
render :edit | ||
end | ||
end | ||
|
||
def destroy | ||
@initiative_status.destroy | ||
redirect_to initiative_statuses_url, notice: 'Initiative status was successfully destroyed.' | ||
end | ||
|
||
private | ||
|
||
def set_initiative_status | ||
@initiative_status = InitiativeStatus.find(params[:id]) | ||
end | ||
|
||
def initiative_status_params | ||
params.require(:initiative_status).permit(:name, :description) | ||
end | ||
end |
Oops, something went wrong.