|
a/scripts/teamforge-import.py |
|
b/scripts/teamforge-import.py |
|
... |
|
... |
297 |
private = (data.access_level == 'private')
|
297 |
private = (data.access_level == 'private')
|
298 |
log.debug('Creating %s private=%s' % (shortname, private))
|
298 |
log.debug('Creating %s private=%s' % (shortname, private))
|
299 |
one_admin = [u.userName for u in data.admins if u.status == 'Active'][0]
|
299 |
one_admin = [u.userName for u in data.admins if u.status == 'Active'][0]
|
300 |
project = nbhd.register_project(shortname,
|
300 |
project = nbhd.register_project(shortname,
|
301 |
get_user(one_admin),
|
301 |
get_user(one_admin),
|
|
|
302 |
project_name=data.data.title,
|
302 |
private_project=private)
|
303 |
private_project=private)
|
303 |
project.notifications_disabled = True
|
304 |
project.notifications_disabled = True
|
304 |
project.name = data.data.title
|
|
|
305 |
project.short_description = data.data.description
|
305 |
project.short_description = data.data.description
|
306 |
project.last_updated = datetime.strptime(data.data.lastModifiedDate, '%Y-%m-%d %H:%M:%S')
|
306 |
project.last_updated = datetime.strptime(data.data.lastModifiedDate, '%Y-%m-%d %H:%M:%S')
|
307 |
M.main_orm_session.flush(project)
|
307 |
M.main_orm_session.flush(project)
|
308 |
# TODO: push last_updated to gutenberg?
|
308 |
# TODO: push last_updated to gutenberg?
|
309 |
# TODO: try to set createdDate?
|
309 |
# TODO: try to set createdDate?
|