This repository has been archived by the owner on May 3, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
database.rules.json
69 lines (59 loc) · 2.23 KB
/
database.rules.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
{
"rules": {
"defects": {
".read": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
".write": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
"$pid": {
"$did": {
"analysed": { ".validate": "newData.isBoolean()" },
"cardId": { ".validate": "newData.isString()" },
"cardNumber": { ".validate": "newData.isNumber()" },
"creation": { ".validate": "!data.exists() && newData.isNumber()" },
"labelId": { ".validate": "newData.isString()" },
"points": { ".validate": "newData.isNumber()" },
"sprint": { ".validate": "newData.isNumber()" },
"userStory": { ".validate": "newData.isString()" }
}
}
},
"labels": {
".read": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
".write": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
"$pid": {
"$lid": {
"colour": { ".validate": "newData.isString()" },
"name": { ".validate": "newData.isString()" }
}
}
},
"projects": {
".read": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
".write": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
"$pid": {
"client": { ".validate": "newData.isString()" },
"name": { ".validate": "newData.isString()" },
"hookId": { ".validate": "!data.exists() && newData.isString()" },
"perfStyle": { ".validate": "newData.isString() && (newData.val() == 'count' || newData.val() == 'pct')" },
"standard": { ".validate": "newData.isNumber()" }
}
},
"sprints": {
".read": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
".write": "auth != null && root.child('users/'+auth.uid+'/access').val() == true",
"$pid": {
".indexOn": ["start"],
"$sid": {
"points": { ".validate": "newData.isNumber()" },
"start": { ".validate": "newData.isNumber()" }
}
}
},
"users": {
".read": false,
".write": false,
"$uid": {
"access": { ".validate": "newData.isBoolean()" }
}
}
}
}