diff options
author | Koren Lev <korenlev@gmail.com> | 2017-09-29 01:38:18 +0300 |
---|---|---|
committer | Yaron Yogev <yaronyogev@gmail.com> | 2017-10-03 09:46:58 +0000 |
commit | d0adff06bed72f9a0edd7adccfa6a1111784bc8b (patch) | |
tree | 4b5eaf1107e6973b1eac636309a99c83074acbfc /ui/imports/api/accounts | |
parent | fbbaf20912c79bd99a5c3696850d70c11965f56b (diff) |
release 1.0 calipso for opnfv apex
Change-Id: I3e63cd27c5f4d3756e67a07c749863a68e84dde2
Signed-off-by: Koren Lev <korenlev@gmail.com>
(cherry picked from commit d32f75145676bacefde0d08a14680a5984623451)
Diffstat (limited to 'ui/imports/api/accounts')
-rw-r--r-- | ui/imports/api/accounts/methods.js | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/ui/imports/api/accounts/methods.js b/ui/imports/api/accounts/methods.js index 4e1c40a..f6c271c 100644 --- a/ui/imports/api/accounts/methods.js +++ b/ui/imports/api/accounts/methods.js @@ -11,6 +11,7 @@ import { SimpleSchema } from 'meteor/aldeed:simple-schema'; import * as R from 'ramda'; import { Roles } from 'meteor/alanning:roles'; import { Environments } from '/imports/api/environments/environments'; +import { UserSettings } from '/imports/api/user-settings/user-settings'; let userSchema = new SimpleSchema({ _id: { type: String }, @@ -48,6 +49,12 @@ export const insert = new ValidatedMethod({ addRole(viewEnvs, 'view-env', userId); addRole(editEnvs, 'edit-env', userId); + + let userSettings = UserSettings.schema.clean({}); + userSettings = R.merge(userSettings, { + user_id: userId, + }); + UserSettings.insert(userSettings); } }); @@ -58,7 +65,7 @@ export const update = new ValidatedMethod({ validate: userSchema .pick([ '_id', - // 'password', + // 'password', 'viewEnvs', 'viewEnvs.$', 'editEnvs', |