spina-admin-conferences-accounts 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/MIT-LICENSE +20 -0
- data/README.md +77 -0
- data/Rakefile +32 -0
- data/app/assets/config/spina_admin_conferences_accounts_manifest.js +3 -0
- data/app/assets/javascripts/spina/admin/conferences/accounts/application.es6 +0 -0
- data/app/assets/stylesheets/spina/admin/conferences/accounts/application.css +15 -0
- data/app/controllers/spina/admin/conferences/accounts/application_controller.rb +28 -0
- data/app/controllers/spina/admin/conferences/accounts/public_users_controller.rb +59 -0
- data/app/helpers/spina/admin/conferences/accounts/application_helper.rb +13 -0
- data/app/jobs/spina/admin/conferences/accounts/application_job.rb +12 -0
- data/app/mailers/spina/admin/conferences/accounts/application_mailer.rb +14 -0
- data/app/models/spina/admin/conferences/accounts/public_user.rb +25 -0
- data/app/views/layouts/spina/admin/conferences/accounts/public_users.html.haml +10 -0
- data/app/views/spina/admin/conferences/accounts/public_users/_form.html.haml +28 -0
- data/app/views/spina/admin/conferences/accounts/public_users/_form_details.html.haml +24 -0
- data/app/views/spina/admin/conferences/accounts/public_users/_public_user.html.haml +11 -0
- data/app/views/spina/admin/conferences/accounts/public_users/edit.html.haml +1 -0
- data/app/views/spina/admin/conferences/accounts/public_users/index.html.haml +12 -0
- data/app/views/spina/admin/hooks/conferences/accounts/_head.html.haml +2 -0
- data/app/views/spina/admin/hooks/conferences/accounts/_primary_navigation.html.haml +9 -0
- data/app/views/spina/admin/hooks/conferences/accounts/_website_secondary_navigation.html.haml +0 -0
- data/config/locales/en.yml +23 -0
- data/config/routes.rb +11 -0
- data/db/migrate/20210908134233_devise_create_spina_admin_conferences_accounts_public_users.rb +49 -0
- data/lib/spina/admin/conferences/accounts/engine.rb +19 -0
- data/lib/spina/admin/conferences/accounts/version.rb +11 -0
- data/lib/spina/admin/conferences/accounts.rb +22 -0
- data/lib/tasks/spina/admin/conferences/accounts_tasks.rake +5 -0
- metadata +325 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 9db8b0cd69531b2beb8a03b8eadb95ec790c1f5c31ea0a40e5c9d11127246446
|
4
|
+
data.tar.gz: 0a14bd9eba950b256e454358301f98c8c7141b8c73648886276ccb20be2ad55e
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 983cc4080be94112aabccfd0056d01e99320c8b3dcb45effab417e74b844ced1f1f29855effac126d22a0b78e3c713f7a6bf936a97b307648fbb77d893c1ef91
|
7
|
+
data.tar.gz: 62f9f0f76ffa097fe7845f31c04c8c6c2d5b46c6ec65115bc3e5b31548d3b0ea61458172337020c8f25174e31d483943b136838b47aa1b32a35db839d85bed9d
|
data/MIT-LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright 2021 Louis Van Steene
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,77 @@
|
|
1
|
+
# Spina::Admin::Conferences::Accounts
|
2
|
+
|
3
|
+
![Rails tests](https://github.com/louis-vs/spina-admin-journal/workflows/Verify/badge.svg?branch=master&event=push)
|
4
|
+
![codecov](https://codecov.io/gh/louis-vs/spina-admin-conferences-accounts/branch/master/graph/badge.svg?token=xMLjBbQXPb)
|
5
|
+
|
6
|
+
*Accounts* is a plugin for [Spina](https://www.spinacms.com/), a content management system built in [Ruby on Rails](http://rubyonrails.org/). Designed to be used with [`spina-admin-conferences`](https://github.com/jmalcic/spina-admin-conferences) and [`spina-admin-journal`](https://github.com/louis-vs/spina-admin-journal), it provides an admin interface to manage public user accounts with [devise](https://github.com/heartcombo/devise).
|
7
|
+
|
8
|
+
## Usage
|
9
|
+
The plugin adds a single menu to Spina's primary navigation, which allows you to manage a devise user stored as `PublicUser`.
|
10
|
+
|
11
|
+
## Installation
|
12
|
+
|
13
|
+
### From scratch
|
14
|
+
Make sure you have a working installation of Ruby on Rails 6.1. You can find a setup guide [here](https://guides.rubyonrails.org/getting_started.html).
|
15
|
+
|
16
|
+
Then run:
|
17
|
+
|
18
|
+
```bash
|
19
|
+
$ rails new your-app --database=postgresql
|
20
|
+
$ cd your-app
|
21
|
+
$ bin/rails db:create
|
22
|
+
$ bin/rails active_storage:install
|
23
|
+
```
|
24
|
+
|
25
|
+
Add this line to your new application's Gemfile:
|
26
|
+
|
27
|
+
```ruby
|
28
|
+
gem 'spina', '~> 2.0'
|
29
|
+
```
|
30
|
+
|
31
|
+
And then execute:
|
32
|
+
|
33
|
+
```bash
|
34
|
+
$ bundle install
|
35
|
+
```
|
36
|
+
|
37
|
+
Run the Spina install generator:
|
38
|
+
|
39
|
+
```bash
|
40
|
+
$ bin/rails g spina:install
|
41
|
+
```
|
42
|
+
|
43
|
+
And follow the prompts. Once this is complete, follow the instructions below.
|
44
|
+
|
45
|
+
### For existing Spina installations
|
46
|
+
Add this line to your application's Gemfile:
|
47
|
+
|
48
|
+
```ruby
|
49
|
+
gem 'spina-admin-conferences-accounts', '~> 0.1'
|
50
|
+
```
|
51
|
+
|
52
|
+
And then execute:
|
53
|
+
|
54
|
+
```bash
|
55
|
+
$ bundle install
|
56
|
+
```
|
57
|
+
|
58
|
+
You'll then need to install and run the migrations for the journal:
|
59
|
+
|
60
|
+
```bash
|
61
|
+
$ bin/rails spina_admin_conferences_accounts_engine:install:migrations
|
62
|
+
$ bin/rails db:migrate
|
63
|
+
```
|
64
|
+
|
65
|
+
You can then start a local server to test that everything's working.
|
66
|
+
|
67
|
+
```bash
|
68
|
+
$ bin/rails s
|
69
|
+
```
|
70
|
+
|
71
|
+
You can manually populate the database from within the app, or alternatively you can use seed data for testing. A sample `seeds.rb` file can be found [here](../master/test/dummy/db/seeds.rb).
|
72
|
+
|
73
|
+
## Contributing
|
74
|
+
Bug reports and feature requests are welcome in the [Issues](https://github.com/louis-vs/spina-admin-journal/issues) section. Translations are also very welcome!
|
75
|
+
|
76
|
+
## License
|
77
|
+
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
data/Rakefile
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'bundler/setup'
|
4
|
+
|
5
|
+
require 'yard'
|
6
|
+
|
7
|
+
YARD::Rake::YardocTask.new(:yardoc) do |t|
|
8
|
+
t.files = ['lib/**/*.rb', 'app/**/*.rb']
|
9
|
+
end
|
10
|
+
|
11
|
+
APP_RAKEFILE = File.expand_path('test/dummy/Rakefile', __dir__)
|
12
|
+
load 'rails/tasks/engine.rake'
|
13
|
+
|
14
|
+
load 'rails/tasks/statistics.rake'
|
15
|
+
|
16
|
+
require 'bundler/gem_tasks'
|
17
|
+
|
18
|
+
require 'rake/testtask'
|
19
|
+
|
20
|
+
Rake::TestTask.new(:test) do |t|
|
21
|
+
t.libs << 'test'
|
22
|
+
t.pattern = 'test/**/*_test.rb'
|
23
|
+
t.verbose = false
|
24
|
+
end
|
25
|
+
|
26
|
+
require 'rubocop/rake_task'
|
27
|
+
|
28
|
+
RuboCop::RakeTask.new do |t|
|
29
|
+
t.options << '--parallel' if ENV['CI']
|
30
|
+
end
|
31
|
+
|
32
|
+
task default: :test
|
File without changes
|
@@ -0,0 +1,15 @@
|
|
1
|
+
/*
|
2
|
+
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
3
|
+
* listed below.
|
4
|
+
*
|
5
|
+
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
|
6
|
+
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
|
7
|
+
*
|
8
|
+
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
|
9
|
+
* compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS
|
10
|
+
* files in this directory. Styles in this file should be added after the last require_* statement.
|
11
|
+
* It is generally better to create a new file per style scope.
|
12
|
+
*
|
13
|
+
*= require_tree .
|
14
|
+
*= require_self
|
15
|
+
*/
|
@@ -0,0 +1,28 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Spina
|
4
|
+
module Admin
|
5
|
+
module Conferences
|
6
|
+
module Accounts
|
7
|
+
# Custom controller for accounts plugin. Sets the layout and adds a flash type.
|
8
|
+
class ApplicationController < AdminController
|
9
|
+
add_flash_types :success
|
10
|
+
|
11
|
+
layout :admin_layout, only: %i[new edit]
|
12
|
+
|
13
|
+
before_action :set_locale
|
14
|
+
|
15
|
+
private
|
16
|
+
|
17
|
+
def admin_layout
|
18
|
+
'spina/admin/admin'
|
19
|
+
end
|
20
|
+
|
21
|
+
def set_locale
|
22
|
+
@locale = params[:locale] || I18n.default_locale
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,59 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Spina
|
4
|
+
module Admin
|
5
|
+
module Conferences
|
6
|
+
module Accounts
|
7
|
+
# Manages user accounts in Spina admin.
|
8
|
+
class PublicUsersController < ApplicationController
|
9
|
+
before_action :set_breadcrumb
|
10
|
+
before_action :set_tabs, except: %i[index destroy]
|
11
|
+
before_action :set_user, only: %i[edit update destroy]
|
12
|
+
|
13
|
+
def index
|
14
|
+
@users = PublicUser.all
|
15
|
+
end
|
16
|
+
|
17
|
+
def edit; end
|
18
|
+
|
19
|
+
def update
|
20
|
+
if @user.update(public_user_params)
|
21
|
+
redirect_to admin_conferences_accounts_public_users_path, success: t('.saved')
|
22
|
+
else
|
23
|
+
render :edit
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
def destroy
|
28
|
+
@user.destroy
|
29
|
+
respond_to do |format|
|
30
|
+
format.html do
|
31
|
+
redirect_to admin_conferences_accounts_public_users_path, success: t('.deleted')
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
|
36
|
+
private
|
37
|
+
|
38
|
+
def public_user_params
|
39
|
+
params.require(:admin_conferences_accounts_public_user).permit(:email, :first_name, :last_name,
|
40
|
+
:institution)
|
41
|
+
end
|
42
|
+
|
43
|
+
def set_breadcrumb
|
44
|
+
add_breadcrumb PublicUser.model_name.human(count: :many), admin_conferences_accounts_public_users_path
|
45
|
+
end
|
46
|
+
|
47
|
+
def set_tabs
|
48
|
+
@tabs = %w[details]
|
49
|
+
end
|
50
|
+
|
51
|
+
def set_user
|
52
|
+
@user = PublicUser.find(params[:id])
|
53
|
+
add_breadcrumb @user.full_name
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Spina
|
4
|
+
module Admin
|
5
|
+
module Conferences
|
6
|
+
module Accounts
|
7
|
+
# User accounts
|
8
|
+
class PublicUser < ApplicationRecord
|
9
|
+
# Include default devise modules. Others available are:
|
10
|
+
# :confirmable, :lockable, :timeoutable, :trackable and :omniauthable
|
11
|
+
devise :database_authenticatable, :registerable,
|
12
|
+
:recoverable, :rememberable, :validatable,
|
13
|
+
:confirmable
|
14
|
+
|
15
|
+
validates :first_name, presence: true
|
16
|
+
validates :last_name, presence: true
|
17
|
+
|
18
|
+
def full_name
|
19
|
+
"#{first_name} #{last_name}"
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
- if @user.errors.any?
|
2
|
+
- content_for :notifications do
|
3
|
+
.notification.notification-danger.animated.fadeInRight
|
4
|
+
= icon 'exclamation'
|
5
|
+
.notification-message
|
6
|
+
= t 'spina.notifications.alert'
|
7
|
+
%small= @user.errors.full_messages.join('<br />').html_safe
|
8
|
+
= link_to '#', data: { close_notification: true } do
|
9
|
+
= icon 'cross'
|
10
|
+
|
11
|
+
= form_for @user, html: {autocomplete: "off"} do |f|
|
12
|
+
%header#header
|
13
|
+
= render partial: 'spina/admin/shared/breadcrumbs'
|
14
|
+
|
15
|
+
#header_actions
|
16
|
+
%button.button.button-primary{ type: 'submit', style: 'margin-right: 0', data: { disable_with: t('spina.pages.saving') } }
|
17
|
+
= icon 'check'
|
18
|
+
= t '.save'
|
19
|
+
|
20
|
+
.button{ style: 'margin-right: 0' }= link_to t('spina.cancel'), admin_conferences_accounts_public_users_path
|
21
|
+
|
22
|
+
%nav#secondary.tabs
|
23
|
+
%ul
|
24
|
+
- @tabs.each_with_index do |tab, i|
|
25
|
+
%li{ class: ('active' if i == 0) }
|
26
|
+
= link_to t(".#{tab}"), "##{tab}"
|
27
|
+
|
28
|
+
#details.tab-content.active= render 'form_details', f: f
|
@@ -0,0 +1,24 @@
|
|
1
|
+
.page-form
|
2
|
+
.page-form-group
|
3
|
+
.page-form-label
|
4
|
+
= Spina::Admin::Conferences::Accounts::PublicUser.human_attribute_name :email
|
5
|
+
.page-form-content
|
6
|
+
= f.text_field :email
|
7
|
+
.page-form-group
|
8
|
+
.page-form-label
|
9
|
+
= Spina::Admin::Conferences::Accounts::PublicUser.human_attribute_name :first_name
|
10
|
+
.page-form-content
|
11
|
+
= f.text_field :first_name
|
12
|
+
.page-form-group
|
13
|
+
.page-form-label
|
14
|
+
= Spina::Admin::Conferences::Accounts::PublicUser.human_attribute_name :last_name
|
15
|
+
.page-form-content
|
16
|
+
= f.text_field :last_name
|
17
|
+
.page-form-group
|
18
|
+
.page-form-label
|
19
|
+
= Spina::Admin::Conferences::Accounts::PublicUser.human_attribute_name :institution
|
20
|
+
.page-form-content
|
21
|
+
= f.text_field :institution
|
22
|
+
|
23
|
+
- unless @user.new_record?
|
24
|
+
.pull-right= link_to t('spina.permanently_delete'), admin_conferences_accounts_public_user_path(@user), method: :delete, data: { confirm: t('.delete_confirmation', name: @user.full_name) }, class: 'button button-link button-danger'
|
@@ -0,0 +1,11 @@
|
|
1
|
+
%tr
|
2
|
+
%td
|
3
|
+
= link_to public_user.email, edit_admin_conferences_accounts_public_user_path(public_user)
|
4
|
+
%td
|
5
|
+
= public_user.full_name
|
6
|
+
%td
|
7
|
+
= public_user.institution
|
8
|
+
%td.nowrap.align-right
|
9
|
+
= link_to edit_admin_conferences_accounts_public_user_path(public_user), class: 'button button-link' do
|
10
|
+
= icon 'pencil-outline'
|
11
|
+
= t '.edit'
|
@@ -0,0 +1 @@
|
|
1
|
+
= render 'form'
|
@@ -0,0 +1,12 @@
|
|
1
|
+
.well
|
2
|
+
.table-container
|
3
|
+
%table.table
|
4
|
+
%thead
|
5
|
+
%tr
|
6
|
+
%th= Spina::Admin::Conferences::Accounts::PublicUser.human_attribute_name :email
|
7
|
+
%th= t '.name'
|
8
|
+
%th= Spina::Admin::Conferences::Accounts::PublicUser.human_attribute_name :institution
|
9
|
+
%th
|
10
|
+
|
11
|
+
%tbody
|
12
|
+
= render @users, message: t('.empty')
|
@@ -0,0 +1,9 @@
|
|
1
|
+
%li{ class: ('active' if %w[public_users].include? controller_name) }
|
2
|
+
= link_to admin_conferences_accounts_public_users_path do
|
3
|
+
= icon 'users-outline'
|
4
|
+
= t 'spina.admin.conferences.accounts.navigation_title'
|
5
|
+
= icon 'caret-right'
|
6
|
+
|
7
|
+
%ul
|
8
|
+
%li{ class: ('active' if %w[public_users].include? controller_name) }
|
9
|
+
= link_to t('spina.admin.conferences.accounts.subnavigation_title'), admin_conferences_accounts_public_users_path
|
File without changes
|
@@ -0,0 +1,23 @@
|
|
1
|
+
en:
|
2
|
+
spina:
|
3
|
+
admin:
|
4
|
+
conferences:
|
5
|
+
accounts:
|
6
|
+
navigation_title: Manage Accounts
|
7
|
+
subnavigation_title: Public Users
|
8
|
+
index:
|
9
|
+
name: Name
|
10
|
+
empty: There are no public users.
|
11
|
+
form_details:
|
12
|
+
name: Name
|
13
|
+
|
14
|
+
activerecord:
|
15
|
+
models:
|
16
|
+
spina/admin/conferences/accounts/public_user:
|
17
|
+
one: Public User
|
18
|
+
other: Public Users
|
19
|
+
attributes:
|
20
|
+
spina/admin/conferences/accounts/public_user:
|
21
|
+
first_name: First Name
|
22
|
+
last_name: Last Name
|
23
|
+
institution: Institution
|
data/config/routes.rb
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
class DeviseCreateSpinaAdminConferencesAccountsPublicUsers < ActiveRecord::Migration[6.1] # :nodoc:
|
4
|
+
def change # rubocop:disable Metrics/MethodLength
|
5
|
+
create_table :spina_admin_conferences_accounts_public_users do |t|
|
6
|
+
## Database authenticatable
|
7
|
+
t.string :email, null: false, default: ''
|
8
|
+
t.string :encrypted_password, null: false, default: ''
|
9
|
+
|
10
|
+
## Recoverable
|
11
|
+
t.string :reset_password_token
|
12
|
+
t.datetime :reset_password_sent_at
|
13
|
+
|
14
|
+
## Rememberable
|
15
|
+
t.datetime :remember_created_at
|
16
|
+
|
17
|
+
## Trackable
|
18
|
+
# t.integer :sign_in_count, default: 0, null: false
|
19
|
+
# t.datetime :current_sign_in_at
|
20
|
+
# t.datetime :last_sign_in_at
|
21
|
+
# t.string :current_sign_in_ip
|
22
|
+
# t.string :last_sign_in_ip
|
23
|
+
|
24
|
+
## Confirmable
|
25
|
+
t.string :confirmation_token
|
26
|
+
t.datetime :confirmed_at
|
27
|
+
t.datetime :confirmation_sent_at
|
28
|
+
t.string :unconfirmed_email # Only if using reconfirmable
|
29
|
+
|
30
|
+
## Lockable
|
31
|
+
# t.integer :failed_attempts, default: 0, null: false # Only if lock strategy is :failed_attempts
|
32
|
+
# t.string :unlock_token # Only if unlock strategy is :email or :both
|
33
|
+
# t.datetime :locked_at
|
34
|
+
|
35
|
+
# User details
|
36
|
+
t.string :first_name, null: false, default: ''
|
37
|
+
t.string :last_name, null: false, default: ''
|
38
|
+
t.string :institution, null: false, default: ''
|
39
|
+
|
40
|
+
t.timestamps null: false
|
41
|
+
end
|
42
|
+
|
43
|
+
add_index :spina_admin_conferences_accounts_public_users, :email, unique: true
|
44
|
+
# TODO: fix these indexes! they're too long
|
45
|
+
# add_index :spina_admin_conferences_accounts_public_users, :reset_password_token, unique: true
|
46
|
+
# add_index :spina_admin_conferences_accounts_public_users, :confirmation_token, unique: true
|
47
|
+
# add_index :spina_admin_conferences_accounts_public_users, :unlock_token, unique: true
|
48
|
+
end
|
49
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Spina
|
4
|
+
module Admin
|
5
|
+
module Conferences
|
6
|
+
module Accounts
|
7
|
+
# The plugin engine. Loads the plugin in Spina.
|
8
|
+
class Engine < ::Rails::Engine
|
9
|
+
config.before_initialize do
|
10
|
+
::Spina::Plugin.register do |plugin|
|
11
|
+
plugin.name = 'conferences-accounts'
|
12
|
+
plugin.namespace = 'conferences/accounts'
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'spina'
|
4
|
+
require 'spina/admin/conferences/accounts/version'
|
5
|
+
require 'spina/admin/conferences/accounts/engine'
|
6
|
+
require 'rails-i18n'
|
7
|
+
require 'devise'
|
8
|
+
|
9
|
+
# Spina CMS.
|
10
|
+
# @see https://www.spinacms.com Spina website
|
11
|
+
module Spina
|
12
|
+
module Admin
|
13
|
+
module Conferences
|
14
|
+
# Public user account management plugin for Spina.
|
15
|
+
module Accounts
|
16
|
+
def self.table_name_prefix
|
17
|
+
'spina_admin_conferences_accounts_'
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
metadata
ADDED
@@ -0,0 +1,325 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: spina-admin-conferences-accounts
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Louis Van Steene
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2021-09-15 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: babel-transpiler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.7'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0.7'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: devise
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '4.8'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '4.8'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rails
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '6.1'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '6.1'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rails-i18n
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '6.0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '6.0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: spina
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 2.0.0
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 2.0.0
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: capybara
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '3.35'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '3.35'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: codecov
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0.4'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0.4'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: image_processing
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '1.2'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '1.2'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: minitest-rails
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '6.1'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '6.1'
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: minitest-reporters
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - "~>"
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '1.4'
|
146
|
+
type: :development
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - "~>"
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '1.4'
|
153
|
+
- !ruby/object:Gem::Dependency
|
154
|
+
name: pg
|
155
|
+
requirement: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - ">="
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: '0'
|
160
|
+
type: :development
|
161
|
+
prerelease: false
|
162
|
+
version_requirements: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - ">="
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: '0'
|
167
|
+
- !ruby/object:Gem::Dependency
|
168
|
+
name: puma
|
169
|
+
requirement: !ruby/object:Gem::Requirement
|
170
|
+
requirements:
|
171
|
+
- - "~>"
|
172
|
+
- !ruby/object:Gem::Version
|
173
|
+
version: '5.0'
|
174
|
+
type: :development
|
175
|
+
prerelease: false
|
176
|
+
version_requirements: !ruby/object:Gem::Requirement
|
177
|
+
requirements:
|
178
|
+
- - "~>"
|
179
|
+
- !ruby/object:Gem::Version
|
180
|
+
version: '5.0'
|
181
|
+
- !ruby/object:Gem::Dependency
|
182
|
+
name: rubocop
|
183
|
+
requirement: !ruby/object:Gem::Requirement
|
184
|
+
requirements:
|
185
|
+
- - "~>"
|
186
|
+
- !ruby/object:Gem::Version
|
187
|
+
version: '1.8'
|
188
|
+
type: :development
|
189
|
+
prerelease: false
|
190
|
+
version_requirements: !ruby/object:Gem::Requirement
|
191
|
+
requirements:
|
192
|
+
- - "~>"
|
193
|
+
- !ruby/object:Gem::Version
|
194
|
+
version: '1.8'
|
195
|
+
- !ruby/object:Gem::Dependency
|
196
|
+
name: rubocop-performance
|
197
|
+
requirement: !ruby/object:Gem::Requirement
|
198
|
+
requirements:
|
199
|
+
- - "~>"
|
200
|
+
- !ruby/object:Gem::Version
|
201
|
+
version: '1.8'
|
202
|
+
type: :development
|
203
|
+
prerelease: false
|
204
|
+
version_requirements: !ruby/object:Gem::Requirement
|
205
|
+
requirements:
|
206
|
+
- - "~>"
|
207
|
+
- !ruby/object:Gem::Version
|
208
|
+
version: '1.8'
|
209
|
+
- !ruby/object:Gem::Dependency
|
210
|
+
name: rubocop-rails
|
211
|
+
requirement: !ruby/object:Gem::Requirement
|
212
|
+
requirements:
|
213
|
+
- - "~>"
|
214
|
+
- !ruby/object:Gem::Version
|
215
|
+
version: '2.8'
|
216
|
+
type: :development
|
217
|
+
prerelease: false
|
218
|
+
version_requirements: !ruby/object:Gem::Requirement
|
219
|
+
requirements:
|
220
|
+
- - "~>"
|
221
|
+
- !ruby/object:Gem::Version
|
222
|
+
version: '2.8'
|
223
|
+
- !ruby/object:Gem::Dependency
|
224
|
+
name: selenium-webdriver
|
225
|
+
requirement: !ruby/object:Gem::Requirement
|
226
|
+
requirements:
|
227
|
+
- - "~>"
|
228
|
+
- !ruby/object:Gem::Version
|
229
|
+
version: '3.142'
|
230
|
+
type: :development
|
231
|
+
prerelease: false
|
232
|
+
version_requirements: !ruby/object:Gem::Requirement
|
233
|
+
requirements:
|
234
|
+
- - "~>"
|
235
|
+
- !ruby/object:Gem::Version
|
236
|
+
version: '3.142'
|
237
|
+
- !ruby/object:Gem::Dependency
|
238
|
+
name: simplecov
|
239
|
+
requirement: !ruby/object:Gem::Requirement
|
240
|
+
requirements:
|
241
|
+
- - "~>"
|
242
|
+
- !ruby/object:Gem::Version
|
243
|
+
version: '0.21'
|
244
|
+
type: :development
|
245
|
+
prerelease: false
|
246
|
+
version_requirements: !ruby/object:Gem::Requirement
|
247
|
+
requirements:
|
248
|
+
- - "~>"
|
249
|
+
- !ruby/object:Gem::Version
|
250
|
+
version: '0.21'
|
251
|
+
- !ruby/object:Gem::Dependency
|
252
|
+
name: yard
|
253
|
+
requirement: !ruby/object:Gem::Requirement
|
254
|
+
requirements:
|
255
|
+
- - "~>"
|
256
|
+
- !ruby/object:Gem::Version
|
257
|
+
version: '0.9'
|
258
|
+
type: :development
|
259
|
+
prerelease: false
|
260
|
+
version_requirements: !ruby/object:Gem::Requirement
|
261
|
+
requirements:
|
262
|
+
- - "~>"
|
263
|
+
- !ruby/object:Gem::Version
|
264
|
+
version: '0.9'
|
265
|
+
description: Implements devise accounts into SpinaCMS.
|
266
|
+
email:
|
267
|
+
- louis@lvs.me.uk
|
268
|
+
executables: []
|
269
|
+
extensions: []
|
270
|
+
extra_rdoc_files: []
|
271
|
+
files:
|
272
|
+
- MIT-LICENSE
|
273
|
+
- README.md
|
274
|
+
- Rakefile
|
275
|
+
- app/assets/config/spina_admin_conferences_accounts_manifest.js
|
276
|
+
- app/assets/javascripts/spina/admin/conferences/accounts/application.es6
|
277
|
+
- app/assets/stylesheets/spina/admin/conferences/accounts/application.css
|
278
|
+
- app/controllers/spina/admin/conferences/accounts/application_controller.rb
|
279
|
+
- app/controllers/spina/admin/conferences/accounts/public_users_controller.rb
|
280
|
+
- app/helpers/spina/admin/conferences/accounts/application_helper.rb
|
281
|
+
- app/jobs/spina/admin/conferences/accounts/application_job.rb
|
282
|
+
- app/mailers/spina/admin/conferences/accounts/application_mailer.rb
|
283
|
+
- app/models/spina/admin/conferences/accounts/public_user.rb
|
284
|
+
- app/views/layouts/spina/admin/conferences/accounts/public_users.html.haml
|
285
|
+
- app/views/spina/admin/conferences/accounts/public_users/_form.html.haml
|
286
|
+
- app/views/spina/admin/conferences/accounts/public_users/_form_details.html.haml
|
287
|
+
- app/views/spina/admin/conferences/accounts/public_users/_public_user.html.haml
|
288
|
+
- app/views/spina/admin/conferences/accounts/public_users/edit.html.haml
|
289
|
+
- app/views/spina/admin/conferences/accounts/public_users/index.html.haml
|
290
|
+
- app/views/spina/admin/hooks/conferences/accounts/_head.html.haml
|
291
|
+
- app/views/spina/admin/hooks/conferences/accounts/_primary_navigation.html.haml
|
292
|
+
- app/views/spina/admin/hooks/conferences/accounts/_website_secondary_navigation.html.haml
|
293
|
+
- config/locales/en.yml
|
294
|
+
- config/routes.rb
|
295
|
+
- db/migrate/20210908134233_devise_create_spina_admin_conferences_accounts_public_users.rb
|
296
|
+
- lib/spina/admin/conferences/accounts.rb
|
297
|
+
- lib/spina/admin/conferences/accounts/engine.rb
|
298
|
+
- lib/spina/admin/conferences/accounts/version.rb
|
299
|
+
- lib/tasks/spina/admin/conferences/accounts_tasks.rake
|
300
|
+
homepage: https://github.com/louis-vs/spina-admin-conferences-accounts
|
301
|
+
licenses:
|
302
|
+
- MIT
|
303
|
+
metadata:
|
304
|
+
homepage_uri: https://github.com/louis-vs/spina-admin-conferences-accounts
|
305
|
+
source_code_uri: https://github.com/louis-vs/spina-admin-conferences-accounts
|
306
|
+
post_install_message:
|
307
|
+
rdoc_options: []
|
308
|
+
require_paths:
|
309
|
+
- lib
|
310
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
311
|
+
requirements:
|
312
|
+
- - "~>"
|
313
|
+
- !ruby/object:Gem::Version
|
314
|
+
version: '2.7'
|
315
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
316
|
+
requirements:
|
317
|
+
- - ">="
|
318
|
+
- !ruby/object:Gem::Version
|
319
|
+
version: '0'
|
320
|
+
requirements: []
|
321
|
+
rubygems_version: 3.1.6
|
322
|
+
signing_key:
|
323
|
+
specification_version: 4
|
324
|
+
summary: Public user account plugin for Spina.
|
325
|
+
test_files: []
|