mirror of
https://github.com/documize/community.git
synced 2025-07-24 23:59:47 +02:00
Add factories
This commit is contained in:
parent
7e4ed6545b
commit
663995b60d
5 changed files with 58 additions and 6 deletions
4
app/mirage/factories/document.js
Normal file
4
app/mirage/factories/document.js
Normal file
|
@ -0,0 +1,4 @@
|
|||
import { Factory } from 'ember-cli-mirage';
|
||||
|
||||
export default Factory.extend({
|
||||
});
|
8
app/mirage/factories/folder-permission.js
Normal file
8
app/mirage/factories/folder-permission.js
Normal file
|
@ -0,0 +1,8 @@
|
|||
import { Factory, faker } from 'ember-cli-mirage';
|
||||
|
||||
export default Factory.extend({
|
||||
"folderId": faker.list.cycle("VzMuyEw_3WqiafcG", "VzMygEw_3WrtFzto"),
|
||||
"userId": faker.list.cycle("VzMuyEw_3WqiafcE", "VzMuyEw_3WqiafcE"),
|
||||
"canView": true,
|
||||
"canEdit": true
|
||||
});
|
13
app/mirage/factories/organization.js
Normal file
13
app/mirage/factories/organization.js
Normal file
|
@ -0,0 +1,13 @@
|
|||
import { Factory } from 'ember-cli-mirage';
|
||||
|
||||
export default Factory.extend({
|
||||
"id": "VzMuyEw_3WqiafcD",
|
||||
"created": "2016-05-11T15:08:24Z",
|
||||
"revised": "2016-05-23T11:23:20Z",
|
||||
"title": "EmberSherpa",
|
||||
"message": "This Documize instance contains all our team documentation",
|
||||
"url": "",
|
||||
"domain": "",
|
||||
"email": "brizdigital@gmail.com",
|
||||
"allowAnonymousAccess": false
|
||||
});
|
|
@ -1,19 +1,19 @@
|
|||
// Copyright 2016 Documize Inc. <legal@documize.com>. All rights reserved.
|
||||
//
|
||||
// This software (Documize Community Edition) is licensed under
|
||||
// This software (Documize Community Edition) is licensed under
|
||||
// GNU AGPL v3 http://www.gnu.org/licenses/agpl-3.0.en.html
|
||||
//
|
||||
// You can operate outside the AGPL restrictions by purchasing
|
||||
// Documize Enterprise Edition and obtaining a commercial license
|
||||
// by contacting <sales@documize.com>.
|
||||
// by contacting <sales@documize.com>.
|
||||
//
|
||||
// https://documize.com
|
||||
|
||||
import Mirage, { faker } from 'ember-cli-mirage';
|
||||
|
||||
export default Mirage.Factory.extend({
|
||||
"folderId": faker.list.cycle('V0Vy5Uw_3QeDAMW9', 'VzMuyEw_3WqiafcG', 'VzMygEw_3WrtFzto', 'VzMygEw_3WrtFzto'),
|
||||
"userId": faker.list.cycle('VzMuyEw_3WqiafcE', 'VzMuyEw_3WqiafcE', 'VzMuyEw_3WqiafcE', ''),
|
||||
"folderId": faker.list.cycle('V0Vy5Uw_3QeDAMW9', 'VzMuyEw_3WqiafcG', 'VzMygEw_3WrtFzto', 'VzMygEw_3WrtFzto', "VzMygEw_3WrtFzto"),
|
||||
"userId": faker.list.cycle('VzMuyEw_3WqiafcE', 'VzMuyEw_3WqiafcE', 'VzMuyEw_3WqiafcE', '', 0),
|
||||
"canView": true,
|
||||
"canEdit": faker.list.cycle(true, true, true, false)
|
||||
});
|
||||
"canEdit": faker.list.cycle(true, true, true, false, false)
|
||||
});
|
||||
|
|
27
app/mirage/factories/user.js
Normal file
27
app/mirage/factories/user.js
Normal file
|
@ -0,0 +1,27 @@
|
|||
import { Factory, faker } from 'ember-cli-mirage';
|
||||
|
||||
export default Factory.extend({
|
||||
"id": faker.list.cycle("VzMyp0w_3WrtFztq", "VzMuyEw_3WqiafcE"),
|
||||
"created": faker.list.cycle("2016-05-11T13:24:55Z", "2016-05-11T15:08:24Z"),
|
||||
"revised": faker.list.cycle("2016-05-11T13:33:47Z", "2016-05-11T15:08:24Z"),
|
||||
"firstname": faker.list.cycle("Len", "Lennex"),
|
||||
"lastname": faker.list.cycle("Random", "Zinyando"),
|
||||
"email": faker.list.cycle("zinyando@gmail.com", "brizdigital@gmail.com"),
|
||||
"initials": faker.list.cycle("LR", "LZ"),
|
||||
"active": true,
|
||||
"editor": true,
|
||||
"admin": faker.list.cycle(false, true),
|
||||
"accounts": [{
|
||||
"id": faker.list.cycle("VzMyp0w_3WrtFztr", "VzMuyEw_3WqiafcF"),
|
||||
"created": faker.list.cycle("2016-05-11T13:24:55Z", "2016-05-11T15:08:24Z"),
|
||||
"revised": faker.list.cycle("2016-05-11T13:24:55Z", "2016-05-11T15:08:24Z"),
|
||||
"admin": faker.list.cycle(false, true),
|
||||
"editor": faker.list.cycle(true, true),
|
||||
"userId": faker.list.cycle("VzMyp0w_3WrtFztq", "VzMuyEw_3WqiafcE"),
|
||||
"orgId": faker.list.cycle("VzMuyEw_3WqiafcD", "VzMuyEw_3WqiafcD"),
|
||||
"company": "EmberSherpa",
|
||||
"title": "EmberSherpa",
|
||||
"message": "This Documize instance contains all our team documentation",
|
||||
"domain": ""
|
||||
}]
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue