Fix upload button name Added link task and taskareamaster
@@ -60,6 +60,7 @@ class Tasks(Base): | |||||
closed = Column(Integer, default=0) | closed = Column(Integer, default=0) | ||||
name = Column(Unicode(80)) | name = Column(Unicode(80)) | ||||
description = Column(UnicodeText) | description = Column(UnicodeText) | ||||
area = relationship(TasksArea, backref=backref("tasks") ) | |||||
@classmethod | @classmethod | ||||
def by_id(cls, id): | def by_id(cls, id): | ||||
@@ -11,6 +11,10 @@ | |||||
<!-- The default timeline stylesheet --> | <!-- The default timeline stylesheet --> | ||||
<link rel="stylesheet" href="/vendor/timeline/css/timeline.css" /> | <link rel="stylesheet" href="/vendor/timeline/css/timeline.css" /> | ||||
</%def> | </%def> | ||||
<div class="pull-right"> | |||||
Synchronisez votre calendrier avec <a href="/2015/JM2L.ics">le fichier ical JM2L 2015</a> | |||||
</div> | |||||
<br> | |||||
<div id="timeline" style="margin-left: -50px;display:block;"></div> | <div id="timeline" style="margin-left: -50px;display:block;"></div> | ||||
<div class="clearfix"> </div> | <div class="clearfix"> </div> | ||||
<div style="top:500px;position: relative"> | <div style="top:500px;position: relative"> | ||||
@@ -41,5 +41,5 @@ DicForm = { | |||||
<input type="submit" class="btn btn-primary" value="Valider"></input> | <input type="submit" class="btn btn-primary" value="Valider"></input> | ||||
</form> | </form> | ||||
% if 'uid' in form._fields.keys(): | % if 'uid' in form._fields.keys(): | ||||
${helpers.uploader("tasks", form.uid.data, u"Attachement" )} | |||||
${helpers.uploader("tasks", form.uid.data, u"une pièce jointe" )} | |||||
%endif | %endif |
@@ -301,7 +301,7 @@ def tasks(request): | |||||
DBSession.merge(Task) | DBSession.merge(Task) | ||||
else: | else: | ||||
DBSession.add(Task) | DBSession.add(Task) | ||||
return HTTPFound(location=request.route_url('list_task')) | |||||
return HTTPFound(location=request.route_url('list_task')+"#"+slugify(Task.area.name)) | |||||
return {'form':form } | return {'form':form } | ||||
@@ -336,7 +336,7 @@ def action_task(request): | |||||
Task.closed = False | Task.closed = False | ||||
DBSession.merge(Task) | DBSession.merge(Task) | ||||
request.session.flash('Task was successfully closed!') | request.session.flash('Task was successfully closed!') | ||||
return HTTPFound(location=request.route_url('list_task')) | |||||
return HTTPFound(location=request.route_url('list_task')+"#"+slugify(Task.area.name)) | |||||
## =-=- Here, We handle HTTP requests - User Logged Part -=-= | ## =-=- Here, We handle HTTP requests - User Logged Part -=-= | ||||