|
a/Allura/allura/controllers/project.py |
|
b/Allura/allura/controllers/project.py |
|
... |
|
... |
167 |
if project_name:
|
167 |
if project_name:
|
168 |
c.project.name = project_name
|
168 |
c.project.name = project_name
|
169 |
if project_description:
|
169 |
if project_description:
|
170 |
c.project.short_description = project_description
|
170 |
c.project.short_description = project_description
|
171 |
ming.orm.ormsession.ThreadLocalORMSession.flush_all()
|
171 |
ming.orm.ormsession.ThreadLocalORMSession.flush_all()
|
|
|
172 |
offset = c.project.ordered_mounts(include_search=True)[-1]['ordinal'] + 1
|
172 |
for i, tool in enumerate(kw):
|
173 |
for i, tool in enumerate(kw):
|
173 |
if kw[tool]:
|
174 |
if kw[tool]:
|
174 |
c.project.install_app(tool, ordinal=i)
|
175 |
c.project.install_app(tool, ordinal=i+offset)
|
175 |
flash('Welcome to the SourceForge Beta System! '
|
176 |
flash('Welcome to the SourceForge Beta System! '
|
176 |
'To get started, fill out some information about your project.')
|
177 |
'To get started, fill out some information about your project.')
|
177 |
redirect(c.project.script_name + 'admin/overview')
|
178 |
redirect(c.project.script_name + 'admin/overview')
|
178 |
|
179 |
|
179 |
@expose()
|
180 |
@expose()
|
|
... |
|
... |
255 |
require_access(c.project, 'read')
|
256 |
require_access(c.project, 'read')
|
256 |
|
257 |
|
257 |
@expose()
|
258 |
@expose()
|
258 |
@with_trailing_slash
|
259 |
@with_trailing_slash
|
259 |
def index(self, **kw):
|
260 |
def index(self, **kw):
|
260 |
if c.project.app_instance('home'):
|
261 |
mount = c.project.first_mount('read')
|
261 |
redirect('home/')
|
262 |
if mount is not None:
|
|
|
263 |
if 'ac' in mount:
|
|
|
264 |
redirect(mount['ac'].options.mount_point + '/')
|
|
|
265 |
elif 'sub' in mount:
|
|
|
266 |
redirect(mount['sub'].url())
|
262 |
elif c.project.app_instance('profile'):
|
267 |
elif c.project.app_instance('profile'):
|
263 |
redirect('profile/')
|
268 |
redirect('profile/')
|
264 |
else:
|
269 |
else:
|
265 |
redirect(c.project.app_configs[0].options.mount_point + '/')
|
270 |
redirect(c.project.app_configs[0].options.mount_point + '/')
|
266 |
|
271 |
|