/
app.js
164 lines (158 loc) · 4.23 KB
/
app.js
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
define(function () {
var appConfig = {};
// default configuration
appConfig.api = {
name: 'Local',
url: 'http://localhost:8080/WebAPI/'
};
appConfig.cacheSources = false;
appConfig.pollInterval = 60000;
appConfig.cohortComparisonResultsEnabled = false;
appConfig.userAuthenticationEnabled = false;
appConfig.plpResultsEnabled = false;
appConfig.useExecutionEngine = false;
appConfig.viewProfileDates = false;
appConfig.enableCosts = false;
appConfig.supportUrl = "https://github.com/ohdsi/atlas/issues";
appConfig.supportMail = "atlasadmin@your.org";
appConfig.feedbackContacts = 'For access or questions concerning the Atlas application please contact:';
appConfig.feedbackCustomHtmlTemplate = '';
appConfig.companyInfoCustomHtmlTemplate = '';
appConfig.showCompanyInfo = true;
appConfig.defaultLocale = "en";
appConfig.authProviders = [
{
"name": "Windows",
"url": "user/login/windows",
"ajax": true,
"icon": "fab fa-windows"
},
{
"name": "Kerberos",
"url": "user/login/kerberos",
"ajax": true,
"icon": "fab fa-windows"
},
{
"name": "OpenID",
"url": "user/login/openid",
"ajax": false,
"icon": "fab fa-openid"
},
{
"name": "Google",
"url": "user/oauth/google",
"ajax": false,
"icon": "fab fa-google"
},
{
"name": "Facebook",
"url": "user/oauth/facebook",
"ajax": false,
"icon": "fab fa-facebook-f"
},
{
"name": "Github",
"url": "user/oauth/github",
"ajax": false,
"icon": "fab fa-github"
},
{
"name": "DB",
"url": "user/login/db",
"ajax": true,
"icon": "fa fa-database",
"isUseCredentialsForm":true
},
{
"name": "LDAP",
"url": "user/login/ldap",
"ajax": true,
"icon": "fa fa-cubes",
"isUseCredentialsForm": true
},
{
"name": "SAML",
"url": "user/login/saml",
"ajax": false,
"icon": "fab fa-openid"
},
{
"name": "Active Directory LDAP",
"url": "user/login/ad",
"ajax": true,
"icon": "fa fa-cubes",
"isUseCredentialsForm": true
}
];
appConfig.strictXSSOptions = {
whiteList: [],
};
appConfig.xssOptions = {
"whiteList": {
"a": ["href", "class", "data-bind", "data-toggle", "aria-expanded"],
"button": ["class", "type", "data-toggle", "aria-expanded"],
"span": ["class", "data-bind"],
"i": ["class", "id", "aria-hidden"],
"div": ["class", "style", "id"],
"option": ["value"],
"input": ["type", "class"],
"ui": ["class"],
"path": ["d", "class"],
"br": "",
"li": ["class", "title"],
"ul": ["class"]
},
"stripIgnoreTag": true,
"stripIgnoreTagBody": ['script'],
};
appConfig.cemOptions = {
"evidenceLinkoutSources": ["medline_winnenburg","splicer"],
"sourceRestEndpoints": {
"medline_winnenburg": "https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esummary.fcgi?db=pubmed&id={@ids}&retmode=json&tool=ohdsi_atlas&email=admin@ohdsi.org",
},
"externalLinks": {
"medline_winnenburg": "https://www.ncbi.nlm.nih.gov/pubmed/{@id}",
"splicer": "https://dailymed.nlm.nih.gov/dailymed/drugInfo.cfm?setid={@id}"
},
};
appConfig.enableTermsAndConditions = true;
appConfig.webAPIRoot = appConfig.api.url;
// todo: move "userAuthenticationEnabled", "plpResultsEnabled", etc into the object
appConfig.features = {
locationDistance: false,
};
appConfig.externalLibraries = [];
appConfig.commonDataTableOptions = {
pageLength: {
ONLY_5: 5,
XS: 5,
S: 10,
M: 25,
L: 50,
},
lengthMenu: {
ONLY_5: [[5], ['5']],
XS: [
[5, 10],
['5', '10'],
],
S: [
[10, 15, 20, 25, 50, -1],
['10', '15', '20', '25', '50', 'All'],
],
M: [
[10, 25, 50, 100, -1],
['10', '25', '50', '100', 'All'],
],
L: [
[25, 50, 75, 100, -1],
['25', '50', '75', '100', 'All'],
],
}
};
appConfig.enablePersonCount = true;
// "Tagging" section is hidden by default
appConfig.enableTaggingSection = false;
return appConfig;
});