bullet_train 1.1.1 → 1.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/controllers/concerns/account/teams/controller_base.rb +4 -13
- data/app/controllers/concerns/account/users/controller_base.rb +1 -0
- data/app/controllers/concerns/controllers/base.rb +2 -2
- data/app/models/concerns/users/base.rb +1 -0
- data/config/locales/en/teams.en.yml +5 -1
- data/config/locales/en/users.en.yml +10 -2
- data/lib/bullet_train/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 900a416d92d49a556a9724c2cc3ee3c45ebea3e76b2c2d11cf53fcdfef728cb4
|
4
|
+
data.tar.gz: 13fc0d4b2fb24253d37ce6bcfb5f3f959356b5d71c59ea3811952139337c56f8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 224cb043db7a958c081f4b2df5f03ca8de76e39be57150e83f04978953d6988caf666069f7649ea3dd528b460cb7ea97d363fddf81fd7c002528288f132778fc
|
7
|
+
data.tar.gz: 474e9b7e9fc40a886d1b43e69c562ce0aec7970c974c4e2a53b7c38627af422e4595c55d9a902fe39525de800a94b88988c4467d877f1eb606b48ff3a641a901
|
@@ -18,6 +18,10 @@ module Account::Teams::ControllerBase
|
|
18
18
|
# for magic locales.
|
19
19
|
@child_object = @team
|
20
20
|
end
|
21
|
+
|
22
|
+
private
|
23
|
+
|
24
|
+
include strong_parameters_from_api
|
21
25
|
end
|
22
26
|
|
23
27
|
# GET /teams
|
@@ -124,17 +128,4 @@ module Account::Teams::ControllerBase
|
|
124
128
|
def process_params(strong_params)
|
125
129
|
raise "It looks like you've removed `process_params` from your controller. This will break Super Scaffolding."
|
126
130
|
end
|
127
|
-
|
128
|
-
# Never trust parameters from the scary internet, only allow the white list through.
|
129
|
-
def team_params
|
130
|
-
strong_params = params.require(:team).permit(
|
131
|
-
:name,
|
132
|
-
:time_zone,
|
133
|
-
:locale,
|
134
|
-
*permitted_fields,
|
135
|
-
*permitted_arrays,
|
136
|
-
)
|
137
|
-
|
138
|
-
process_params(strong_params)
|
139
|
-
end
|
140
131
|
end
|
@@ -55,6 +55,7 @@ module Account::Users::ControllerBase
|
|
55
55
|
end
|
56
56
|
|
57
57
|
# Never trust parameters from the scary internet, only allow the white list through.
|
58
|
+
# TODO Update this to use `include strong_parameters_from_api`.
|
58
59
|
def user_params
|
59
60
|
# TODO enforce permissions on updating the user's team name.
|
60
61
|
strong_params = params.require(:user).permit(
|
@@ -134,9 +134,9 @@ module Controllers::Base
|
|
134
134
|
def process_params(strong_params)
|
135
135
|
end
|
136
136
|
|
137
|
-
def delegate_json_to_api
|
137
|
+
def delegate_json_to_api(&block)
|
138
138
|
respond_to do |format|
|
139
|
-
format.html
|
139
|
+
format.html(&block)
|
140
140
|
format.json { render "#{params[:controller].gsub(/^account\//, "api/#{BulletTrain::Api.current_version}/")}/#{params[:action]}" }
|
141
141
|
end
|
142
142
|
end
|
@@ -20,6 +20,7 @@ module Users::Base
|
|
20
20
|
has_many :memberships, dependent: :destroy
|
21
21
|
has_many :scaffolding_absolutely_abstract_creative_concepts_collaborators, through: :memberships
|
22
22
|
has_many :teams, through: :memberships
|
23
|
+
has_many :collaborating_users, through: :teams, source: :users
|
23
24
|
belongs_to :current_team, class_name: "Team", optional: true
|
24
25
|
accepts_nested_attributes_for :current_team
|
25
26
|
|
@@ -60,8 +60,11 @@ en:
|
|
60
60
|
heading: *locale
|
61
61
|
# 🚅 super scaffolding will insert new fields above this line.
|
62
62
|
created_at:
|
63
|
-
_: &created_at
|
63
|
+
_: &created_at Signed Up At
|
64
64
|
heading: *created_at
|
65
|
+
updated_at:
|
66
|
+
_: &updated_at Updated At
|
67
|
+
heading: *updated_at
|
65
68
|
_: &self
|
66
69
|
name:
|
67
70
|
label: Your Team Name
|
@@ -84,3 +87,4 @@ en:
|
|
84
87
|
locale: *locale
|
85
88
|
# 🚅 super scaffolding will insert new activerecord attributes above this line.
|
86
89
|
created_at: *created_at
|
90
|
+
updated_at: *updated_at
|
@@ -27,6 +27,10 @@ en:
|
|
27
27
|
notifications:
|
28
28
|
updated: User was successfully updated.
|
29
29
|
fields: &fields
|
30
|
+
id:
|
31
|
+
_: &id Team ID
|
32
|
+
label: *id
|
33
|
+
heading: *id
|
30
34
|
name:
|
31
35
|
heading: Name
|
32
36
|
first_name:
|
@@ -64,8 +68,11 @@ en:
|
|
64
68
|
help: By default the interface language will adjust based on each team's language setting, but you can set a global personal preference for your account here.
|
65
69
|
# 🚅 super scaffolding will insert new fields above this line.
|
66
70
|
created_at:
|
67
|
-
_: &created_at Signed Up
|
71
|
+
_: &created_at Signed Up At
|
68
72
|
heading: *created_at
|
73
|
+
updated_at:
|
74
|
+
_: &updated_at Updated At
|
75
|
+
heading: *updated_at
|
69
76
|
# this is how we define customizations to fields for a specific namespace.
|
70
77
|
_: &self
|
71
78
|
email:
|
@@ -105,6 +112,7 @@ en:
|
|
105
112
|
time_zone: *time_zone
|
106
113
|
locale: *locale
|
107
114
|
# 🚅 super scaffolding will insert new activerecord attributes above this line.
|
108
|
-
created_at: *created_at
|
109
115
|
password: *password
|
110
116
|
password_confirmation: *password_confirmation
|
117
|
+
created_at: *created_at
|
118
|
+
updated_at: *updated_at
|
data/lib/bullet_train/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bullet_train
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Culver
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-09-
|
11
|
+
date: 2022-09-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: standard
|