如何设置任务的计划完成日期? [英] How do I Set the Planned Completion Date on a Task?

查看:231
本文介绍了如何设置任务的计划完成日期?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图弄清楚如何在创建或更新任务时设置计划的完成日期.任务的结果始终是计划的CompletionDate等于创建项目的日期.

I'm trying to figure out how to set the planned completion date when creating or updating a task. Tasks always result with a plannedCompletionDate equal to the day the project was created.

我使用了几种不同的dateTime格式,但是它从未改变.这是我使用过的两个没有引发错误的东西:

I have used a few different dateTime formats, but it never changes. These are the two I've used that didn't throw an error:

2015-05-02T08:00:00:000-0500
2015-05-02

但是,即使没有错误,也没有变化.

However, even though there was no error, there was no change either.

我在另一篇文章中看到用户正在搜索查询中使用$$TODAY-25d,所以我以为可以尝试,但仍然出现错误

I saw in another post that a user was using $$TODAY-25d in a search query, so I thought I'd try that, but I still got the error

日期格式与公认的日期格式不符

Date format does not match a recognized date format

包含任务的项目的状态为"IDEA".我不确定这是否会影响通过API设置任务的plannedCompletionDate,所以我以为以防万一.

The project containing the task has a status of 'IDEA'. I'm not sure if this affects being able to set the plannedCompletionDate of the task via the API or not, so I thought I'd mention it just in case.

推荐答案

您使用的日期格式是正确的,但是您需要记住,时间轴引擎的所有规则也适用于API.这意味着前辈和任务约束会影响任务上的日期.如果要将任务固定在某个日期,则需要使用FIXT,MSO或MFO taskConstraint.

The date format you are using is correct, but you need to remember that all the rules of the timeline engine also apply to the APIs. This means that predecessors and task constraints affect the dates on the tasks. If you would like to pin the task to a certain date you would need to use a FIXT, MSO, or MFO taskConstraint.

/api/task/abc123?method=POST&sessionID=abc123&plannedCompletionDate=2015-05-02T08:00:00:000-0500&taskConstraint=MFO...

以某种方式,您已经设置了日期,因此它不会引发错误,但是项目随后重新计算了时间轴,并将其重新更改为之前的日期. taskConstraint将强制其遵循您输入的日期.

It a way, you have been setting the date, hence it doesn't throw an error, but the project then recalculates the timeline and changes it right back to what it was before. The taskConstraint will force it to follow the date you put in.

这篇关于如何设置任务的计划完成日期?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆