示例#1
0
文件: tasks.py 项目: toirl/plorma
def _add_estimatelog(task):
    for sprint in task.sprints:
        nlog = Estimatelog()
        nlog.estimate = sprint.estimate
        nlog.date = datetime.date.today()
        sprint.estimatelog.append(nlog)
    return task
示例#2
0
文件: sprints.py 项目: toirl/plorma
def update_callback(request, sprint):
    for log in sprint.estimatelog:
        if log.date == datetime.date.today():
            log.estimate = sprint.estimate
            return sprint
    nlog = Estimatelog()
    nlog.estimate = sprint.estimate
    nlog.date = datetime.date.today()
    sprint.estimatelog.append(nlog)