Exemplo n.º 1
0
 def add(self):
     con = RepoManager()
     c.repTypes = con.getRepositoriesTypes()
     c.repTypes = [it() for it in c.repTypes]
     c.templates = RepositoryController.template
     c.tempSize = len(c.templates)
     return render('/repositoryAdd.mako')
Exemplo n.º 2
0
 def edit(self):
     con = RepoManager()
     c.rep = con.getRepository(request.params['name'])
     c.repTypes = con.getRepositoriesTypes()
     c.repTypes = [it() for it in c.repTypes]
     c.templates = RepositoryController.template
     c.tempSize = len(c.templates)
     return render('/repositoryEdit.mako')
Exemplo n.º 3
0
 def doAdd(self):
     con = RepoManager()
     added = IRepository()
     #potrzeba sprawdzenia czy dane sa jako tako dobre i czy w ogole sa
     added.assign(request.params['name'], request.params['url'], request.params['comment'], request.params['type'])
     if request.params['login']:
         added.setAuth(request.params['login'], request.params['password'])
     added.setTestAttributes(request.params['build_cmd'], request.params['find_tests'], request.params['run_test'])
     if 'compile' in request.params and request.params['compile'] == 'on':
         added.compileOnServer = True
     con.addRepository(added)
     c.message = 'Pomyslnie dodano repozytorium %s ' % request.params['name']
     c.link = '/repository'
     return render('/message.mako')
Exemplo n.º 4
0
 def info(self):
     tm = TasksManager()
     c.task = tm.getTask(request.params['name'])
     rm = RepoManager()
     c.info = rm.getRepository(c.task['repository'])
     return render('/taskInfo.mako')
Exemplo n.º 5
0
 def index(self):
     con = RepoManager()
     c.repTypes = con.getRepositories()
     return render('/run.mako')
Exemplo n.º 6
0
 def index(self):
     # Return a rendered template
     con = RepoManager()
     c.repos = con.getRepositories()
     return render('/repository.mako')