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
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
|
# Django settings for gnowsys-ndf project.
from django.conf import global_settings
# from django.conf.global_settings import TEMPLATE_CONTEXT_PROCESSORS
from django.utils.translation import ugettext
import os
DEBUG = True
# ALLOWED_HOSTS = ["127.0.0.1"]
TEMPLATE_DEBUG = DEBUG
DEBUG_PROPAGATE_EXCEPTIONS = DEBUG
BENCHMARK = "ON"
LANGUAGES = (('en', 'English'), ('hi', 'Hindi'))
"""
('mr', 'Marathi'),('mun','Munda'),('mni','Manipuri'),('ori','Oriya'),
('pi','Pali'),('raj','Rajasthani'),('lah','Lahnda'),('gu','Gujarati'),
('ks','Kashmiri'), ('kok','Konkani'), ('kha','Khasi'), ('dra','Dravidian'),
('gon','Gondi'), ('bra','Braj'), ('mi','Malayalam'), ('mai','Maithili'),
('mag','Magahi'), ('lus','Lushai'), ('bh','Bihari'), ('kru','Kurukh'),
('awa','Awadhi'),('sa','Sanskrit'),('sat','Santali'), ('him','Himachali'),
('sd','Sindhi'), ('af', 'Afrikaans'), ('as','Assamese'),('ar', 'Arabic'),
('az', 'Azerbaijani'), ('bg', 'Bulgarian'), ('be', 'Belarusian'),
('bn', 'Bengali'), ('br', 'Breton'), ('bs', 'Bosnian'), ('ca', 'Catalan'),
('bho','Bhojpuri'), ('cs', 'Czech'), ('cy', 'Welsh'), ('da', 'Danish'),
('de', 'German'), ('el', 'Greek'), ('en-gb', 'British English'),
('eo', 'Esperanto'), ('es', 'Spanish'), ('es-ar', 'Argentinian Spanish'),
('es-mx', 'Mexican Spanish'), ('es-ni', 'Nicaraguan Spanish'),
('es-ve', 'Venezuelan Spanish'), ('et', 'Estonian'), ('eu', 'Basque'),
('fa', 'Persian'), ('fi', 'Finnish'), ('fr', 'French'), ('fy-nl', 'Frisian'),
('ga', 'Irish'), ('gl', 'Galician'), ('he', 'Hebrew'),('hr', 'Croatian'),
('hu', 'Hungarian'), ('ia', 'Interlingua'), ('id', 'Indonesian'),
('is', 'Icelandic'), ('it', 'Italian'), ('ja', 'Japanese'), ('ka', 'Georgian'),
('kk', 'Kazakh'), ('km', 'Khmer'), ('kn', 'Kannada'), ('ko', 'Korean'),
('lb', 'Luxembourgish'), ('lt', 'Lithuanian'), ('lv', 'Latvian'),
('mk', 'Macedonian'), ('ml', 'Malayalam'), ('mn', 'Mongolian'),
('my', 'Burmese'), ('nb', 'Norwegian Bokmal'), ('ne', 'Nepali'),
('nl', 'Dutch'), ('nn', 'Norwegian Nynorsk'), ('os', 'Ossetic'),
('pa', 'Punjabi'), ('pl', 'Polish'), ('pt', 'Portuguese'),
('pt-br', 'Brazilian Portuguese'), ('ro', 'Romanian'), ('ru', 'Russian'),
('sk', 'Slovak'), ('sl', 'Slovenian'), ('sq', 'Albanian'), ('sr', 'Serbian'),
('sr-latn', 'Serbian Latin'), ('sv', 'Swedish'), ('sw', 'Swahili'),
('ta', 'Tamil'), ('te', 'Telugu'), ('th', 'Thai'), ('tr', 'Turkish'),
('tt', 'Tatar'), ('udm', 'Udmurt'), ('uk', 'Ukrainian'), ('ur', 'Urdu'),
('vi', 'Vietnamese'), ('zh-cn', 'Simplified Chinese'), ('zh-tw', 'Traditional Chinese'))
"""
EXTRA_LANG_INFO = {
'mr': {
'bidi': True, # right-to-left
'code': 'mr',
'name': 'Marathi',
'name_local': 'Marathi'
},
'mun': {
'bidi': True, # right-to-left
'code': 'mun',
'name': 'Munda',
'name_local': 'Munda'
},
'mni': {
'bidi': True, # right-to-left
'code': 'ug',
'name': 'Manipuri',
'name_local': 'Manipuri'
},
'ori': {
'bidi': True, # right-to-left
'code': 'ori',
'name': 'Oriya',
'name_local': 'Oriya'
},
'mr': {
'bidi': True, # right-to-left
'code': 'mr',
'name': 'Marathi',
'name_local': 'Marathi'
},
'pi': {
'bidi': True, # right-to-left
'code': 'pi',
'name': 'Pali',
'name_local': 'Pali'
},
'raj': {
'bidi': True, # right-to-left
'code': 'raj',
'name': 'Rajasthani',
'name_local': 'Rajasthani'
},
'sa': {
'bidi': True, # right-to-left
'code': 'sa',
'name': 'Sanskrit',
'name_local': 'Sanskrit'
},
'sat': {
'bidi': True, # right-to-left
'code': 'sat',
'name': 'Santali',
'name_local': 'Santali'
},
'sd': {
'bidi': True, # right-to-left
'code': 'sa',
'name': 'Sindhi',
'name_local': 'Sindhi'
},
'as': {
'bidi': True, # right-to-left
'code': 'as',
'name': 'Assamese',
'name_local': 'Assamese'
},
'awa': {
'bidi': True, # right-to-left
'code': 'awa',
'name': 'Awadhi',
'name_local': 'Awadhi'
},
'bho': {
'bidi': True, # right-to-left
'code': 'bho',
'name': 'Bhojpuri',
'name_local': 'Bhojpuri'
},
'bh': {
'bidi': True, # right-to-left
'code': 'bh',
'name': 'Bihari',
'name_local': 'Bihari'
},
'bra': {
'bidi': True, # right-to-left
'code': 'bho',
'name': 'Braj',
'name_local': 'Braj'
},
'gon': {
'bidi': True, # right-to-left
'code': 'gon',
'name': 'Gondi',
'name_local': 'Gondi'
},
'dra': {
'bidi': True, # right-to-left
'code': 'bho',
'name': 'Dravidian',
'name_local': 'Dravidian'
},
'gu': {
'bidi': True, # right-to-left
'code': 'gu',
'name': 'Gujarati',
'name_local': 'Gujarati'
},
'him': {
'bidi': True, # right-to-left
'code': 'him',
'name': 'Himachali',
'name_local': 'Himachali'
},
'ks': {
'bidi': True, # right-to-left
'code': 'ks',
'name': 'Kashmiri',
'name_local': 'Kashmiri'
},
'kha': {
'bidi': True, # right-to-left
'code': 'kha',
'name': 'Khasi',
'name_local': 'Khasi'
},
'kok': {
'bidi': True, # right-to-left
'code': 'kok',
'name': 'Konkani',
'name_local': 'Konkani'
},
'kru': {
'bidi': True, # right-to-left
'code': 'kru',
'name': 'Kurukh',
'name_local': 'Kurukh'
},
'lah': {
'bidi': True, # right-to-left
'code': 'lah',
'name': 'Lahnda',
'name_local': 'Lahnda'
},
'lus': {
'bidi': True, # right-to-left
'code': 'lus',
'name': 'Lushai',
'name_local': 'Lushai'
},
'mag': {
'bidi': True, # right-to-left
'code': 'mag',
'name': 'Magahi',
'name_local': 'Magahi'
},
'mai': {
'bidi': True, # right-to-left
'code': 'mai',
'name': 'Maithili',
'name_local': 'Maithili'
},
'mi': {
'bidi': True, # right-to-left
'code': 'mi',
'name': 'Malayalam',
'name_local': 'Malayalam'
},
}
# Add custom languages not provided by Django
import django.conf.locale
LANG_INFO = dict(django.conf.locale.LANG_INFO.items() + EXTRA_LANG_INFO.items())
django.conf.locale.LANG_INFO = LANG_INFO
# Languages using BiDi (right-to-left) layout
# LANGUAGES_BIDI = global_settings.LANGUAGES_BIDI + ("mni",)
# #SMTP setting for sending mail (Using python default SMTP server)
EMAIL_USE_TLS = False
EMAIL_HOST = 'localhost'
EMAIL_PORT = 1025
EMAIL_HOST_USER = ''
EMAIL_HOST_PASSWORD = ''
DEFAULT_FROM_EMAIL = 'testing@example.com'
# SMTP setting for sending mail (Using gmail SMTP server)
# EMAIL_USE_TLS = True
# EMAIL_HOST = 'smtp.gmail.com'
# EMAIL_PORT = 587
# EMAIL_HOST_USER = 'yourcompletegmailaddr'
# EMAIL_HOST_PASSWORD = 'yourpassword'
# strength of a password
PASSWORD_MIN_LENGTH = 8
PASSWORD_COMPLEXITY = { # You can ommit any or all of these for no limit for that particular set
"UPPER": 1, # Uppercase
"LOWER": 1, # Lowercase
"DIGITS": 1, # Digits
}
ADMINS = (
# ('Your Name', 'your_email@example.com'),
)
MANAGERS = ADMINS
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'example-sqlite3.db',
},
'mongodb': {
'ENGINE': 'django_mongokit.mongodb',
'NAME': 'studio-dev',
'USER': '',
'PASSWORD': '',
'HOST': '',
'PORT': '',
},
}
# Local time zone for this installation. Choices can be found here:
# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
# although not all choices may be available on all operating systems.
# In a Windows environment this must be set to your system time zone.
USE_TZ = True
TIME_ZONE = 'Asia/Kolkata'
# Language code for this installation. All choices can be found here:
# http://www.i18nguy.com/unicode/language-identifiers.html
LANGUAGE_CODE = 'de'
SITE_ID = 1
# If you set this to False, Django will make some optimizations so as not
# to load the internationalization machinery.
USE_I18N = True
# Setting system's default encoding to 'utf-8'
# By defalut, it's 'ascii'
# Comes handy while writing unicode text into a file
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
# If you set this to False, Django will not format dates, numbers and
# calendars according to the current locale.
USE_L10N = True
# If you set this to False, Django will not use timezone-aware datetimes.
USE_TZ = True
# Django-provide base translation in django/conf/locale.
LOCALE_PATHS = (os.path.join(os.path.dirname(__file__), '..','conf/locale/'),)
# Absolute filesystem path to the directory that will hold user-uploaded files.
# Example: "/home/media/media.lawrence.com/media/"
MEDIA_ROOT = ''
# URL that handles the media served from MEDIA_ROOT. Make sure to use a
# trailing slash.
# Examples: "http://media.lawrence.com/media/", "http://example.com/media/"
MEDIA_URL = '/media/'
# Absolute path to the directory static files should be collected to.
# Don't put anything in this directory yourself; store your static files
# in apps' "static/" subdirectories and in STATICFILES_DIRS.
# Example: "/home/media/media.lawrence.com/static/"
STATIC_ROOT = '/static'
# URL prefix for static files.
# Example: "http://media.lawrence.com/static/"
STATIC_URL = '/static/'
# Additional locations of static files
STATICFILES_DIRS = (
# Put strings here, like "/home/html/static" or "C:/www/django/static".
# Always use forward slashes, even on Windows.
# Don't forget to use absolute paths, not relative paths.
)
# List of finder classes that know how to find static files in
# various locations.
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
'django.contrib.staticfiles.finders.FileSystemFinder',
# 'django.contrib.staticfiles.finders.DefaultStorageFinder',
)
# Make this unique, and don't share it with anybody.
SECRET_KEY = '7st0sdv&7yw*eh)zmaz8#t48nr$&ql#ow=$0l^#b_b&$9c*$4c'
# List of callables that know how to import templates from various sources.
TEMPLATE_LOADERS = (
'django.template.loaders.filesystem.Loader',
'django.template.loaders.app_directories.Loader',
# 'django.template.loaders.eggs.Loader',
)
MIDDLEWARE_CLASSES = (
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.locale.LocaleMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
# 'django.middleware.activeuser_middleware.ActiveUserMiddleware', #for online_users
# 'online_status.middleware.OnlineStatusMiddleware', #for online_users
'django.contrib.messages.middleware.MessageMiddleware',
'pagination.middleware.PaginationMiddleware',
# 'django.middleware.cache.UpdateCacheMiddleware',
# 'django.middleware.cache.FetchFromCacheMiddleware',
# Uncomment the next line for simple clickjacking protection:
# 'django.middleware.clickjacking.XFrameOptionsMiddleware',
)
# AUTH_PROFILE_MODULE = 'gnowsys_ndf.ndf.models.UserProfile'
ROOT_URLCONF = 'gnowsys_ndf.ndf.urls'
# Python dotted path to the WSGI application used by Django's runserver.
WSGI_APPLICATION = 'gnowsys_ndf.wsgi.application'
TEMPLATE_DIRS = (
# Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
# Always use forward slashes, even on Windows.
# Don't forget to use absolute paths, not relative paths.
)
TEMPLATE_CONTEXT_PROCESSORS = (
'django.contrib.auth.context_processors.auth',
'django.core.context_processors.i18n',
'django.core.context_processors.request',
'django.core.context_processors.static',
# 'django.core.context_processors.csrf',
)
INSTALLED_APPS = (
'gnowsys_ndf.ndf',
'django.contrib.auth',
'django.contrib.admin',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.messages',
'django.contrib.staticfiles',
'gnowsys_ndf.benchmarker',
'registration',
'djangoratings',
'notification',
'pagination',
'captcha',
# 'gnowsys_ndf.mobwrite', #textb
# 'south', #textb
# 'django_extensions', #textb
# 'reversion', #textb
# 'django.contrib.flatpages', #textb
# 'online_status', #for online_users
# 'endless_pagination',
'jsonrpc',
'registration_email',
'memcache_admin',
)
AUTHENTICATION_BACKENDS = (
'registration_email.auth.EmailBackend',
)
ACCOUNT_ACTIVATION_DAYS = 2 # Two days for activation.
# A sample logging configuration. The only tangible logging
# performed by this configuration is to send an email to
# the site admins on every HTTP 500 error when DEBUG=False.
# See http://docs.djangoproject.com/en/dev/topics/logging for
# more details on how to customize your logging configuration.
LOGGING = {
'version': 1,
'disable_existing_loggers': False,
'filters': {
'require_debug_false': {
'()': 'django.utils.log.RequireDebugFalse'
}
},
'handlers': {
'mail_admins': {
'level': 'ERROR',
'filters': ['require_debug_false'],
'class': 'django.utils.log.AdminEmailHandler'
}
},
'loggers': {
'django.request': {
'handlers': ['mail_admins'],
'level': 'ERROR',
'propagate': True,
},
}
}
LOGIN_REDIRECT_URL = "/"
# Absolute filesystem path to the project's base directory,
# i.e. having settings.py file
# Example: "/.../project-name/app-name/"
PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__))
# Binary - Only meant for RelationType's document to represent
# Binary relationship, especially defined to differentiate
# from other relationship(s), i.e. Triadic, etc.
# Example (Binary): A >> son-of >> [B]
# Example (Triadic): A >> teaches-course-in-college >> [Course, College]
META_TYPE = [
u"GAPP", u"factory_types", u"Mapping_relations", u"Binary", u"Triadic"
]
GSTUDIO_GROUP_AGENCY_TYPES = [
"Other", "Partner", "GovernmentAgency", "NGO", "College", "University",
"School", "Institution", "Project", "SpecialInterestGroup"
]
GSTUDIO_AUTHOR_AGENCY_TYPES = [
"Student", "Teacher", "TeacherTrainer", "Faculty", "Researcher", "Other"
]
# Varible to toggle the visibility of author_agency_type field of Author
# class in User-registration template (shown as Occupation)
GSTUDIO_REGISTRATION_AUTHOR_AGENCY_TYPE = True
# Varible to toggle the visibility of group_affiliation field of Author
# class in User-registration template (shown as Organization)
GSTUDIO_REGISTRATION_AFFILIATION = True
# Built-in GAPPS list
# ONLY TO BE EDITED - in case of adding new built-in GAPPS
GAPPS = [
u"Page", u"File", u"Group", u"Image", u"Video", u"Forum", u"Quiz",
u"Course", u"Module", u"Batch", u"Task", u"WikiData", u"Topics",
u"E-Library", u"Meeting", u"Bib_App", u"Observation", u"Event", u"E-Book"
]
# This holds the list of stable GAPPS
# ONLY TO BE EDITED in local_settings file
# In order to edit (redorderig purpose or adding new ones) this list,
# please make use of local_settings file
GSTUDIO_WORKING_GAPPS = [
u"Page", u"File", u"E-Library", u"Forum", u"Task", u"Topics",
u"Course", u"Observation", u"Event"
]
# This is to be used for listing default GAPPS on gapps-menubar/gapps-iconbar
# if not set by specific group
# DON'T EDIT this variable here.
# ONLY TO BE EDITED in local_settings file
GSTUDIO_DEFAULT_GAPPS_LIST = []
GSTUDIO_USER_GAPPS_LIST = ['Page', 'File']
# Defined all site specific variables
GSTUDIO_ORG_NAME = '''<p>
A project of <a href="http://lab.gnowledge.org/" target="_blank">{% trans "Gnowledge Lab" %}</a> at the <a href="http://www.hbcse.tifr.res.in" target="_blank">Homi Bhabha Centre for Science Education (HBCSE)</a>, <a href="http://www.tifr.res.in" target="_blank">Tata Institute of Fundamental Research (TIFR), India</a>.
</p>'''
GSTUDIO_SITE_LOGO = "/static/ndf/css/themes/metastudio/logo.svg"
GSTUDIO_COPYRIGHT = ""
GSTUDIO_GIT_REPO = "https://github.com/gnowledge/gstudio"
GSTUDIO_SITE_PRIVACY_POLICY = ""
GSTUDIO_SITE_TERMS_OF_SERVICE = ""
GSTUDIO_SITE_DEFAULT_LANGUAGE = u"en"
GSTUDIO_SITE_ABOUT = ""
GSTUDIO_SITE_POWEREDBY = ""
GSTUDIO_SITE_CONTACT = ""
GSTUDIO_SITE_PARTNERS = ""
GSTUDIO_SITE_GROUPS = ""
GSTUDIO_ORG_LOGO = ""
GSTUDIO_SITE_ORG = ""
GSTUDIO_SITE_CONTRIBUTE = ""
GSTUDIO_SITE_VIDEO = "pandora_and_local" # possible values are 'local','pandora' and 'pandora_and_local'
GSTUDIO_SITE_LANDING_PAGE = "udashboard" # possible values are 'home' and 'udashboard'
GSTUDIO_SITE_HOME_PAGE = None # it is url rendered on template. e.g: "/welcome". Default is: "/home"
GSTUDIO_SITE_NAME = "metaStudio" # holds the name of site. e.g: "NROER, "tiss" etc. (Override it in local_settings)
# GSTUDIO_SITE_EDITOR = "orgitdown" #possible values are 'aloha'and 'orgitdown'
# Visibility for 'Create Group'
CREATE_GROUP_VISIBILITY = True
EMACS_INIT_FILE_PATH = "~/.emacs"
###########################################################################
"""Settings for org-editor-content-to-html
Default settings required for uploading org-editor content into
exported html form
"""
from django.conf import settings
MARKUP_LANGUAGE = getattr(settings, 'GSTUDIO_MARKUP_LANGUAGE', 'html')
MARKDOWN_EXTENSIONS = getattr(settings, 'GSTUDIO_MARKDOWN_EXTENSIONS', '')
WYSIWYG_MARKUP_MAPPING = {
'textile': 'markitup',
'markdown': 'markitup',
'restructuredtext': 'markitup',
'html': 'tinymce' in settings.INSTALLED_APPS and 'tinymce' or 'wymeditor'}
WYSIWYG = getattr(settings, 'GSTUDIO_WYSIWYG',
WYSIWYG_MARKUP_MAPPING.get(MARKUP_LANGUAGE))
###########################################################################
"""Revision Control System (RCS) Configuration
It operates only on single files; and hence used in this project
to keep track of history of each document belonging to different
collections (models).
"""
# Indicates list of collection-names whose documents' history has to be
# maintained.
VERSIONING_COLLECTIONS = ['AttributeTypes', 'RelationTypes',
'GSystemTypes', 'GSystems']
# Absolute filesystem path to the directory that will hold all rcs-files
# (history-files corresponding to every json-file created for each document)
RCS_REPO_DIR = os.path.join(PROJECT_ROOT, "ndf/rcs-repo")
# Indicates the "hash-level-number", i.e the number of sub-directories that
# will be created for the corresponding document under it's
# collection-directory; in order to store json-files in an effective manner
RCS_REPO_DIR_HASH_LEVEL = 3
GSTUDIO_RESOURCES_EDUCATIONAL_USE = ["Images", "Audios", "Videos", "Interactives", "Documents", "eBooks", "Maps", "Events", "Publications"]
GSTUDIO_RESOURCES_INTERACTIVITY_TYPE = ["Active", "Expositive", "Mixed"]
GSTUDIO_RESOURCES_EDUCATIONAL_ALIGNMENT = ["NCF", "State", "All"]
GSTUDIO_RESOURCES_EDUCATIONAL_LEVEL = ["Primary", "Upper Primary", "Secondary", "Senior Secondary", "Tertiary"]
GSTUDIO_RESOURCES_EDUCATIONAL_SUBJECT = ["Language", "Mathematics", "Environmental Studies", "Science", "Chemistry", "Physics", "Biology", "Social Science", "History", "Geography", "Political Science", "Economics", "Sociology", "Psychology", "Commerce", "Business Studies", "Accountancy"]
GSTUDIO_RESOURCES_CURRICULAR = ["True", "False"]
GSTUDIO_RESOURCES_AUDIENCE = ["Teachers", "Students", "Teacher educators"]
GSTUDIO_RESOURCES_TEXT_COMPLEXITY = ["Easy", "Moderately Easy", "Intermediate", "Moderately Hard", "Hard"]
GSTUDIO_RESOURCES_LANGUAGES = ["English", "Gujarati", "Hindi", "Manipuri", "Marathi", "Mizo", "Telugu"]
GSTUDIO_RESOURCES_AGE_RANGE = ["5-10", "11-20", "21-30", "31-40", "41 and above"]
GSTUDIO_RESOURCES_TIME_REQUIRED = ["0-2M", "2-5M", "5-15M", "15-45M"]
GSTUDIO_RESOURCES_AGE_RANGE = ["5-10", "11-20", "21-30", "31-40", "41 and above"]
GSTUDIO_RESOURCES_READING_LEVEL = []
GSTUDIO_TASK_TYPES = ["Bug", "Feature", "Support", "UI Feature", "Moderation", "Other"]
GSTUDIO_NROER_MENU = [{"Repository": []}, {"Partners": ["States", "Institutions", "Individuals"]}, {"Groups":["Teachers", "Interest Groups", "Schools"]}]
GSTUDIO_NROER_GAPPS = [{"Curated Zone": "topics"}, {"eBooks": "e-book"}, {"eCourses": "course"}, {"Events": "event"}, {"eLibrary": "e-library"}]
GSTUDIO_NROER_MENU_MAPPINGS = {
"States": "State Partner", "Institutions": "Institutional Partner", "Individuals": "Individual Partner",
"Teachers": "Teachers", "Interest Groups": "Interest Groups", "Schools": "Schools"
}
GSTUDIO_RESOURCES_CREATION_RATING = 5
GSTUDIO_RESOURCES_REGISTRATION_RATING = 5
GSTUDIO_RESOURCES_REPLY_RATING = 2
# the level of moderation means level of sub mode group hierarchy
GSTUDIO_GROUP_MODERATION_LEVEL = 1
# allowed moderation levels
GSTUDIO_ALLOWED_GROUP_MODERATION_LEVELS = [1, 2, 3]
GSTUDIO_LICENCE = ["CC BY-SA", "CC BY", "CC BY-NC-SA", "CC BY-NC-ND", "CC BY-ND", "PUBLIC-DOMAIN", "FDL (FREE DOCUMENTATION LICENSE)", "OTHERS"]
try:
from local_settings import *
# print "Local settings applied"
except:
# print "Default settings applied"
pass
# #textb
# import warnings
# warnings.filterwarnings(
# 'error', r"DateTimeField received a naive datetime",
# RuntimeWarning, r'django\.db\.models\.fields')
# #textb
########################################### for online_users_ramk
# cache implementation with memcached and python-memcached binding:
CACHES = {
'default': {
'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
'LOCATION': '127.0.0.1:11211',
'TIMEOUT': 300, # 60 * 5 = 300 seconds or 5 minutes
}
}
#USER_ONLINE_TIMEOUT = 300
#USER_LASTSEEN_TIMEOUT = 60 * 60 * 24 * 7
# USERS_ONLINE__TIME_IDLE = 300
# USERS_ONLINE__TIME_OFFLINE = 10
#USERS_ONLINE__CACHE_PREFIX_USER
#USERS_ONLINE__CACHE_USERS
WETUBE_USERNAME = "glab"
WETUBE_PASSWORD = "gl@b$@)we!ube"
#Captcha settings
CAPTCHA_CHALLENGE_FUNCT = 'captcha.helpers.math_challenge'
CAPTCHA_NOISE_FUNCTIONS = ('captcha.helpers.noise_arcs','captcha.helpers.noise_null')
|