mks_auth 1.0.7 → 1.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/mks/auth/application_controller.rb +1 -0
- data/app/controllers/mks/auth/users_controller.rb +4 -8
- data/lib/mks/auth/version.rb +1 -1
- data/spec/controllers/mks/auth/users_controller_spec.rb +23 -0
- data/spec/dummy/log/development.log +172 -0
- data/spec/dummy/log/test.log +1800 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4bdc0cf512e5d2a6de283112393abb047c798ebef5d266f60229e2ec121cf22a
|
4
|
+
data.tar.gz: 9a00a2b3526c773f56d591125d4d9d55c79193182b0e352360275a8842fdf94e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5e6d94b2e805928d8b9502811a3adf8b10379ef7ea3180e081b279753318c65b1fe59716739e97aa54e6163c41dd9c1a293116d4dba24fb7ad5901c935b0bd5e
|
7
|
+
data.tar.gz: bc573590f04e6135a4dbcc067b74d90e5a44a2378767ffe8c307868140411f997eb1e589686b92d8c0eb8bb7587c7d9b221a14e88c67e7ccf98bbb84afdaa204
|
@@ -35,22 +35,18 @@ module Mks
|
|
35
35
|
app_module = ApplicationModule.find_by(code: app_code)
|
36
36
|
@user.application_modules = [app_module]
|
37
37
|
if @user.save
|
38
|
-
|
38
|
+
render json: Mks::Common::MethodResponse.success_response(@user)
|
39
39
|
else
|
40
|
-
|
41
|
-
response = { success: false, errors: errors }
|
40
|
+
render json: Mks::Common::MethodResponse.failure_response(@user), status: :uprocessable_entity
|
42
41
|
end
|
43
|
-
render json: response
|
44
42
|
end
|
45
43
|
|
46
44
|
def update
|
47
45
|
if @user.update(user_params)
|
48
|
-
|
46
|
+
render json: Mks::Common::MethodResponse.success_response(@user)
|
49
47
|
else
|
50
|
-
|
51
|
-
response = { success: false, errors: errors }
|
48
|
+
render json: Mks::Common::MethodResponse.failure_response(@user), status: :unprocessable_entity
|
52
49
|
end
|
53
|
-
render json: response
|
54
50
|
end
|
55
51
|
|
56
52
|
def login
|
data/lib/mks/auth/version.rb
CHANGED
@@ -39,6 +39,29 @@ module Mks
|
|
39
39
|
end
|
40
40
|
end
|
41
41
|
|
42
|
+
describe 'POST #create' do
|
43
|
+
it 'creates a new user' do
|
44
|
+
app_module = create(:application_module, code: 'DUMMY')
|
45
|
+
u = create(:user, application_modules: [app_module])
|
46
|
+
token = Mks::Auth::TokenAuth.issue(name: u.full_name, email: u.email, id: u.id)
|
47
|
+
request.headers['Authorization'] = "Bearer #{token}"
|
48
|
+
|
49
|
+
user = {
|
50
|
+
first_name: 'test user',
|
51
|
+
last_name: 'test user',
|
52
|
+
email: 'test@test.com',
|
53
|
+
password: 'test123',
|
54
|
+
password_confirmation: 'test123'
|
55
|
+
}
|
56
|
+
|
57
|
+
count = User.count
|
58
|
+
post :create, params: { user: user }
|
59
|
+
result = JSON(response.body)
|
60
|
+
expect(result['success']).to be_truthy
|
61
|
+
expect(User.count).to eq count + 1
|
62
|
+
end
|
63
|
+
end
|
64
|
+
|
42
65
|
describe 'POST #save_selected_roles' do
|
43
66
|
it 'saves selected user roles' do
|
44
67
|
app_module = create(:application_module, code: 'DUMMY')
|
@@ -14008,3 +14008,175 @@ FOREIGN KEY ("user_id")
|
|
14008
14008
|
[1m[35m (0.5ms)[0m [1m[35mBEGIN[0m
|
14009
14009
|
[1m[36mActiveRecord::InternalMetadata Update (0.8ms)[0m [1m[33mUPDATE "ar_internal_metadata" SET "value" = $1, "updated_at" = $2 WHERE "ar_internal_metadata"."key" = $3[0m [["value", "test"], ["updated_at", "2018-07-27 07:48:39.435950"], ["key", "environment"]]
|
14010
14010
|
[1m[35m (1.3ms)[0m [1m[35mCOMMIT[0m
|
14011
|
+
[1m[35m (1.7ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14012
|
+
[1m[35m (0.7ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1[0m [["key", "environment"]]
|
14013
|
+
[1m[35m (0.7ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14014
|
+
[1m[35m (0.5ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1[0m [["key", "environment"]]
|
14015
|
+
[1m[35m (0.6ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14016
|
+
[1m[35m (0.6ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1[0m [["key", "environment"]]
|
14017
|
+
[1m[35m (119.9ms)[0m [1m[35mDROP DATABASE IF EXISTS "construction_test"[0m
|
14018
|
+
[1m[35m (354.6ms)[0m [1m[35mCREATE DATABASE "construction_test" ENCODING = 'utf8'[0m
|
14019
|
+
[1m[35mSQL (0.6ms)[0m [1m[35mCREATE EXTENSION IF NOT EXISTS "plpgsql"[0m
|
14020
|
+
[1m[35m (0.8ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_application_modules" CASCADE[0m
|
14021
|
+
[1m[35m (11.9ms)[0m [1m[35mCREATE TABLE "mks_auth_application_modules" ("id" bigserial primary key, "code" character varying NOT NULL, "name" character varying NOT NULL, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14022
|
+
[1m[35m (0.5ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_menus" CASCADE[0m
|
14023
|
+
[1m[35m (7.0ms)[0m [1m[35mCREATE TABLE "mks_auth_menus" ("id" bigserial primary key, "text" character varying NOT NULL, "icon_cls" character varying, "class_name" character varying, "location" character varying, "parent_id" integer, "application_module_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14024
|
+
[1m[35m (3.5ms)[0m [1m[35mCREATE INDEX "index_mks_auth_menus_on_application_module_id" ON "mks_auth_menus" ("application_module_id")[0m
|
14025
|
+
[1m[35m (5.4ms)[0m [1m[35mCREATE INDEX "index_mks_auth_menus_on_parent_id" ON "mks_auth_menus" ("parent_id")[0m
|
14026
|
+
[1m[35m (0.9ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_menus_user_roles" CASCADE[0m
|
14027
|
+
[1m[35m (5.2ms)[0m [1m[35mCREATE TABLE "mks_auth_menus_user_roles" ("id" bigserial primary key, "menu_id" bigint, "user_role_id" bigint)[0m
|
14028
|
+
[1m[35m (3.7ms)[0m [1m[35mCREATE INDEX "index_mks_auth_menus_user_roles_on_menu_id_and_user_role_id" ON "mks_auth_menus_user_roles" ("menu_id", "user_role_id")[0m
|
14029
|
+
[1m[35m (0.5ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_user_roles" CASCADE[0m
|
14030
|
+
[1m[35m (6.4ms)[0m [1m[35mCREATE TABLE "mks_auth_user_roles" ("id" bigserial primary key, "name" character varying NOT NULL, "application_module_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14031
|
+
[1m[35m (3.4ms)[0m [1m[35mCREATE INDEX "index_mks_auth_user_roles_on_application_module_id" ON "mks_auth_user_roles" ("application_module_id")[0m
|
14032
|
+
[1m[35m (0.6ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_users" CASCADE[0m
|
14033
|
+
[1m[35m (6.8ms)[0m [1m[35mCREATE TABLE "mks_auth_users" ("id" bigserial primary key, "first_name" character varying NOT NULL, "last_name" character varying NOT NULL, "email" character varying NOT NULL, "active" boolean DEFAULT TRUE NOT NULL, "password_digest" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14034
|
+
[1m[35m (0.6ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_users_application_modules" CASCADE[0m
|
14035
|
+
[1m[35m (1.8ms)[0m [1m[35mCREATE TABLE "mks_auth_users_application_modules" ("user_id" bigint, "application_module_id" bigint)[0m
|
14036
|
+
[1m[35m (3.3ms)[0m [1m[35mCREATE INDEX "am_on_users_indx" ON "mks_auth_users_application_modules" ("user_id", "application_module_id")[0m
|
14037
|
+
[1m[35m (0.5ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_users_user_roles" CASCADE[0m
|
14038
|
+
[1m[35m (1.8ms)[0m [1m[35mCREATE TABLE "mks_auth_users_user_roles" ("user_id" bigint, "user_role_id" bigint)[0m
|
14039
|
+
[1m[35m (4.8ms)[0m [1m[35mCREATE INDEX "index_mks_auth_users_user_roles_on_user_id_and_user_role_id" ON "mks_auth_users_user_roles" ("user_id", "user_role_id")[0m
|
14040
|
+
[1m[35m (3.2ms)[0m [1m[35mALTER TABLE "mks_auth_menus" ADD CONSTRAINT "fk_rails_e5dd25fcb5"
|
14041
|
+
FOREIGN KEY ("application_module_id")
|
14042
|
+
REFERENCES "mks_auth_application_modules" ("id")
|
14043
|
+
[0m
|
14044
|
+
[1m[35m (2.3ms)[0m [1m[35mALTER TABLE "mks_auth_menus" ADD CONSTRAINT "fk_rails_826b2757bc"
|
14045
|
+
FOREIGN KEY ("parent_id")
|
14046
|
+
REFERENCES "mks_auth_menus" ("id")
|
14047
|
+
[0m
|
14048
|
+
[1m[35m (2.3ms)[0m [1m[35mALTER TABLE "mks_auth_menus_user_roles" ADD CONSTRAINT "fk_rails_1807c05e36"
|
14049
|
+
FOREIGN KEY ("menu_id")
|
14050
|
+
REFERENCES "mks_auth_menus" ("id")
|
14051
|
+
[0m
|
14052
|
+
[1m[35m (2.4ms)[0m [1m[35mALTER TABLE "mks_auth_menus_user_roles" ADD CONSTRAINT "fk_rails_c24fca59c0"
|
14053
|
+
FOREIGN KEY ("user_role_id")
|
14054
|
+
REFERENCES "mks_auth_user_roles" ("id")
|
14055
|
+
[0m
|
14056
|
+
[1m[35m (2.1ms)[0m [1m[35mALTER TABLE "mks_auth_user_roles" ADD CONSTRAINT "fk_rails_b0b293e4e2"
|
14057
|
+
FOREIGN KEY ("application_module_id")
|
14058
|
+
REFERENCES "mks_auth_application_modules" ("id")
|
14059
|
+
[0m
|
14060
|
+
[1m[35m (2.2ms)[0m [1m[35mALTER TABLE "mks_auth_users_application_modules" ADD CONSTRAINT "fk_rails_b100f8542c"
|
14061
|
+
FOREIGN KEY ("application_module_id")
|
14062
|
+
REFERENCES "mks_auth_application_modules" ("id")
|
14063
|
+
[0m
|
14064
|
+
[1m[35m (2.4ms)[0m [1m[35mALTER TABLE "mks_auth_users_application_modules" ADD CONSTRAINT "fk_rails_1010e0182a"
|
14065
|
+
FOREIGN KEY ("user_id")
|
14066
|
+
REFERENCES "mks_auth_users" ("id")
|
14067
|
+
[0m
|
14068
|
+
[1m[35m (2.1ms)[0m [1m[35mALTER TABLE "mks_auth_users_user_roles" ADD CONSTRAINT "fk_rails_3dae904cd8"
|
14069
|
+
FOREIGN KEY ("user_role_id")
|
14070
|
+
REFERENCES "mks_auth_user_roles" ("id")
|
14071
|
+
[0m
|
14072
|
+
[1m[35m (2.1ms)[0m [1m[35mALTER TABLE "mks_auth_users_user_roles" ADD CONSTRAINT "fk_rails_7cc19890aa"
|
14073
|
+
FOREIGN KEY ("user_id")
|
14074
|
+
REFERENCES "mks_auth_users" ("id")
|
14075
|
+
[0m
|
14076
|
+
[1m[35m (7.1ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" character varying NOT NULL PRIMARY KEY)[0m
|
14077
|
+
[1m[35m (1.9ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14078
|
+
[1m[35m (2.1ms)[0m [1m[32mINSERT INTO "schema_migrations" (version) VALUES (20180201104912)[0m
|
14079
|
+
[1m[35m (1.6ms)[0m [1m[32mINSERT INTO "schema_migrations" (version) VALUES
|
14080
|
+
(20161029065810),
|
14081
|
+
(20161029065959),
|
14082
|
+
(20161029070807),
|
14083
|
+
(20161029071047),
|
14084
|
+
(20161029072256),
|
14085
|
+
(20161029074023);
|
14086
|
+
|
14087
|
+
[0m
|
14088
|
+
[1m[35m (8.6ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" character varying NOT NULL PRIMARY KEY, "value" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14089
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.6ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1 LIMIT $2[0m [["key", "environment"], ["LIMIT", 1]]
|
14090
|
+
[1m[35m (0.6ms)[0m [1m[35mBEGIN[0m
|
14091
|
+
[1m[36mActiveRecord::InternalMetadata Create (1.0ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "key"[0m [["key", "environment"], ["value", "development"], ["created_at", "2018-07-27 08:13:53.659484"], ["updated_at", "2018-07-27 08:13:53.659484"]]
|
14092
|
+
[1m[35m (1.2ms)[0m [1m[35mCOMMIT[0m
|
14093
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.6ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1 LIMIT $2[0m [["key", "environment"], ["LIMIT", 1]]
|
14094
|
+
[1m[35m (0.6ms)[0m [1m[35mBEGIN[0m
|
14095
|
+
[1m[36mActiveRecord::InternalMetadata Update (0.8ms)[0m [1m[33mUPDATE "ar_internal_metadata" SET "value" = $1, "updated_at" = $2 WHERE "ar_internal_metadata"."key" = $3[0m [["value", "test"], ["updated_at", "2018-07-27 08:13:53.666723"], ["key", "environment"]]
|
14096
|
+
[1m[35m (1.3ms)[0m [1m[35mCOMMIT[0m
|
14097
|
+
[1m[35m (1.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14098
|
+
[1m[35m (0.7ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1[0m [["key", "environment"]]
|
14099
|
+
[1m[35m (0.7ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14100
|
+
[1m[35m (0.6ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1[0m [["key", "environment"]]
|
14101
|
+
[1m[35m (0.8ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14102
|
+
[1m[35m (0.6ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1[0m [["key", "environment"]]
|
14103
|
+
[1m[35m (123.8ms)[0m [1m[35mDROP DATABASE IF EXISTS "construction_test"[0m
|
14104
|
+
[1m[35m (328.1ms)[0m [1m[35mCREATE DATABASE "construction_test" ENCODING = 'utf8'[0m
|
14105
|
+
[1m[35mSQL (0.7ms)[0m [1m[35mCREATE EXTENSION IF NOT EXISTS "plpgsql"[0m
|
14106
|
+
[1m[35m (0.8ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_application_modules" CASCADE[0m
|
14107
|
+
[1m[35m (11.0ms)[0m [1m[35mCREATE TABLE "mks_auth_application_modules" ("id" bigserial primary key, "code" character varying NOT NULL, "name" character varying NOT NULL, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14108
|
+
[1m[35m (0.7ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_menus" CASCADE[0m
|
14109
|
+
[1m[35m (7.0ms)[0m [1m[35mCREATE TABLE "mks_auth_menus" ("id" bigserial primary key, "text" character varying NOT NULL, "icon_cls" character varying, "class_name" character varying, "location" character varying, "parent_id" integer, "application_module_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14110
|
+
[1m[35m (3.3ms)[0m [1m[35mCREATE INDEX "index_mks_auth_menus_on_application_module_id" ON "mks_auth_menus" ("application_module_id")[0m
|
14111
|
+
[1m[35m (3.7ms)[0m [1m[35mCREATE INDEX "index_mks_auth_menus_on_parent_id" ON "mks_auth_menus" ("parent_id")[0m
|
14112
|
+
[1m[35m (0.6ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_menus_user_roles" CASCADE[0m
|
14113
|
+
[1m[35m (6.2ms)[0m [1m[35mCREATE TABLE "mks_auth_menus_user_roles" ("id" bigserial primary key, "menu_id" bigint, "user_role_id" bigint)[0m
|
14114
|
+
[1m[35m (3.1ms)[0m [1m[35mCREATE INDEX "index_mks_auth_menus_user_roles_on_menu_id_and_user_role_id" ON "mks_auth_menus_user_roles" ("menu_id", "user_role_id")[0m
|
14115
|
+
[1m[35m (0.6ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_user_roles" CASCADE[0m
|
14116
|
+
[1m[35m (6.3ms)[0m [1m[35mCREATE TABLE "mks_auth_user_roles" ("id" bigserial primary key, "name" character varying NOT NULL, "application_module_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14117
|
+
[1m[35m (3.2ms)[0m [1m[35mCREATE INDEX "index_mks_auth_user_roles_on_application_module_id" ON "mks_auth_user_roles" ("application_module_id")[0m
|
14118
|
+
[1m[35m (0.7ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_users" CASCADE[0m
|
14119
|
+
[1m[35m (6.4ms)[0m [1m[35mCREATE TABLE "mks_auth_users" ("id" bigserial primary key, "first_name" character varying NOT NULL, "last_name" character varying NOT NULL, "email" character varying NOT NULL, "active" boolean DEFAULT TRUE NOT NULL, "password_digest" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14120
|
+
[1m[35m (0.6ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_users_application_modules" CASCADE[0m
|
14121
|
+
[1m[35m (1.9ms)[0m [1m[35mCREATE TABLE "mks_auth_users_application_modules" ("user_id" bigint, "application_module_id" bigint)[0m
|
14122
|
+
[1m[35m (3.7ms)[0m [1m[35mCREATE INDEX "am_on_users_indx" ON "mks_auth_users_application_modules" ("user_id", "application_module_id")[0m
|
14123
|
+
[1m[35m (0.6ms)[0m [1m[35mDROP TABLE IF EXISTS "mks_auth_users_user_roles" CASCADE[0m
|
14124
|
+
[1m[35m (1.7ms)[0m [1m[35mCREATE TABLE "mks_auth_users_user_roles" ("user_id" bigint, "user_role_id" bigint)[0m
|
14125
|
+
[1m[35m (3.3ms)[0m [1m[35mCREATE INDEX "index_mks_auth_users_user_roles_on_user_id_and_user_role_id" ON "mks_auth_users_user_roles" ("user_id", "user_role_id")[0m
|
14126
|
+
[1m[35m (3.2ms)[0m [1m[35mALTER TABLE "mks_auth_menus" ADD CONSTRAINT "fk_rails_e5dd25fcb5"
|
14127
|
+
FOREIGN KEY ("application_module_id")
|
14128
|
+
REFERENCES "mks_auth_application_modules" ("id")
|
14129
|
+
[0m
|
14130
|
+
[1m[35m (3.8ms)[0m [1m[35mALTER TABLE "mks_auth_menus" ADD CONSTRAINT "fk_rails_826b2757bc"
|
14131
|
+
FOREIGN KEY ("parent_id")
|
14132
|
+
REFERENCES "mks_auth_menus" ("id")
|
14133
|
+
[0m
|
14134
|
+
[1m[35m (2.8ms)[0m [1m[35mALTER TABLE "mks_auth_menus_user_roles" ADD CONSTRAINT "fk_rails_1807c05e36"
|
14135
|
+
FOREIGN KEY ("menu_id")
|
14136
|
+
REFERENCES "mks_auth_menus" ("id")
|
14137
|
+
[0m
|
14138
|
+
[1m[35m (2.6ms)[0m [1m[35mALTER TABLE "mks_auth_menus_user_roles" ADD CONSTRAINT "fk_rails_c24fca59c0"
|
14139
|
+
FOREIGN KEY ("user_role_id")
|
14140
|
+
REFERENCES "mks_auth_user_roles" ("id")
|
14141
|
+
[0m
|
14142
|
+
[1m[35m (2.5ms)[0m [1m[35mALTER TABLE "mks_auth_user_roles" ADD CONSTRAINT "fk_rails_b0b293e4e2"
|
14143
|
+
FOREIGN KEY ("application_module_id")
|
14144
|
+
REFERENCES "mks_auth_application_modules" ("id")
|
14145
|
+
[0m
|
14146
|
+
[1m[35m (2.4ms)[0m [1m[35mALTER TABLE "mks_auth_users_application_modules" ADD CONSTRAINT "fk_rails_b100f8542c"
|
14147
|
+
FOREIGN KEY ("application_module_id")
|
14148
|
+
REFERENCES "mks_auth_application_modules" ("id")
|
14149
|
+
[0m
|
14150
|
+
[1m[35m (2.6ms)[0m [1m[35mALTER TABLE "mks_auth_users_application_modules" ADD CONSTRAINT "fk_rails_1010e0182a"
|
14151
|
+
FOREIGN KEY ("user_id")
|
14152
|
+
REFERENCES "mks_auth_users" ("id")
|
14153
|
+
[0m
|
14154
|
+
[1m[35m (2.5ms)[0m [1m[35mALTER TABLE "mks_auth_users_user_roles" ADD CONSTRAINT "fk_rails_3dae904cd8"
|
14155
|
+
FOREIGN KEY ("user_role_id")
|
14156
|
+
REFERENCES "mks_auth_user_roles" ("id")
|
14157
|
+
[0m
|
14158
|
+
[1m[35m (2.2ms)[0m [1m[35mALTER TABLE "mks_auth_users_user_roles" ADD CONSTRAINT "fk_rails_7cc19890aa"
|
14159
|
+
FOREIGN KEY ("user_id")
|
14160
|
+
REFERENCES "mks_auth_users" ("id")
|
14161
|
+
[0m
|
14162
|
+
[1m[35m (6.0ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" character varying NOT NULL PRIMARY KEY)[0m
|
14163
|
+
[1m[35m (1.2ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
14164
|
+
[1m[35m (1.6ms)[0m [1m[32mINSERT INTO "schema_migrations" (version) VALUES (20180201104912)[0m
|
14165
|
+
[1m[35m (1.2ms)[0m [1m[32mINSERT INTO "schema_migrations" (version) VALUES
|
14166
|
+
(20161029065810),
|
14167
|
+
(20161029065959),
|
14168
|
+
(20161029070807),
|
14169
|
+
(20161029071047),
|
14170
|
+
(20161029072256),
|
14171
|
+
(20161029074023);
|
14172
|
+
|
14173
|
+
[0m
|
14174
|
+
[1m[35m (5.8ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" character varying NOT NULL PRIMARY KEY, "value" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)[0m
|
14175
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.7ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1 LIMIT $2[0m [["key", "environment"], ["LIMIT", 1]]
|
14176
|
+
[1m[35m (0.9ms)[0m [1m[35mBEGIN[0m
|
14177
|
+
[1m[36mActiveRecord::InternalMetadata Create (1.1ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "key"[0m [["key", "environment"], ["value", "development"], ["created_at", "2018-07-27 08:21:59.090286"], ["updated_at", "2018-07-27 08:21:59.090286"]]
|
14178
|
+
[1m[35m (1.4ms)[0m [1m[35mCOMMIT[0m
|
14179
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.6ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = $1 LIMIT $2[0m [["key", "environment"], ["LIMIT", 1]]
|
14180
|
+
[1m[35m (0.7ms)[0m [1m[35mBEGIN[0m
|
14181
|
+
[1m[36mActiveRecord::InternalMetadata Update (0.9ms)[0m [1m[33mUPDATE "ar_internal_metadata" SET "value" = $1, "updated_at" = $2 WHERE "ar_internal_metadata"."key" = $3[0m [["value", "test"], ["updated_at", "2018-07-27 08:21:59.098379"], ["key", "environment"]]
|
14182
|
+
[1m[35m (1.4ms)[0m [1m[35mCOMMIT[0m
|