소스 검색

# Feature/196, 198, 199 Grouping users
* Fix userGroup model.
* Fix userGroupRelation model.

Tatsuya Ise 8 년 전
부모
커밋
07a070733d
2개의 변경된 파일1개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      lib/models/userGroup.js
  2. 0 1
      lib/models/userGroupRelation.js

+ 1 - 1
lib/models/userGroup.js

@@ -14,7 +14,7 @@ module.exports = function(crowi) {
   userGroupSchema = new mongoose.Schema({
     userGroupId: String,
     image: String,
-    name: { type: String, required: true, unique: true, index: true },
+    name: { type: String, required: true, unique: true },
     createdAt: { type: Date, default: Date.now },
   });
   userGroupSchema.plugin(mongoosePaginate);

+ 0 - 1
lib/models/userGroupRelation.js

@@ -14,7 +14,6 @@ module.exports = function(crowi) {
     createdAt: { type: Date, default: Date.now },
   });
   userGroupRelationSchema.plugin(mongoosePaginate);
-  userGroupRelationSchema.plugin(uniqueValidator);
 
   // すべてのグループ所属関係を取得
   userGroupRelationSchema.statics.findAllRelation = function() {