Attask-通过API更新隐藏的项目属性 [英] Attask - Update hidden project properties through API

查看:89
本文介绍了Attask-通过API更新隐藏的项目属性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有许多项目字段要通过API更新,这些字段在Workfront UI中不可见.我通过对项目ID进行GET来获取这些属性.我需要更新的几个字段是-previousStatus,categoryID,resourcePoolID,scheduleID,eac等.请注意,我的extRefID为null.
我已经试过了-

I have a number of project fields to be updated via API, which are not visible in workfront UI. I fetch these properties by doing a GET of the project ID. Few fields to name that I need to update are - previousStatus, categoryID, resourcePoolID, scheduleID, eac and others. Please note my extRefID is null.
I have tried this -

 https://abc.attasksandbox.com/attask/api/project/57--b8477f7?DE:project={previousStatus:EST}&apiKey=759--ux&method=put

还有这个

https://xyz.attasksandbox.com/attask/api/project/57d6--f7?DE=previousStatus:EST&apiKey=759--xu&method=put

还有这个

https://xyz.attasksandbox.com/attask/api/project/57--f7?updates={"previousStatus":"EST"}&apiKey=7--xuk&method=put

和JSON修改如下

https://xyz.attasksandbox.com/attask/api/project/57--f7&apiKey=7--xuk&method=put

正文为

{
    Project: [ 
        { 
            previousStatus: "EST"
        } 
    ] 
}

,但似乎没有任何效果.我收到第三次呼叫的响应代码200,但previousStatus仍未更新. 对于其他电话,我得到:

but nothing seems to work. I get response code 200 for 3rd call, but previousStatus is still not updated. For other calls I get:

找不到具有主键值的参数\"previousStatus \""

"Parameter with primary key value(s) \"previousStatus\" not found"

如果可以的话,有人可以建议正确的方法吗?预先感谢!

Can any one please suggest the right approach if it's achievable? Thanks in advance!

推荐答案

大多数字段可以并且应该使用API​​进行设置,但是其中某些字段仍在计算中,因此无法直接设置.以前的状态与它所说的完全一样,它是通过更改项目的状态自动设置的.如果项目是CUR并更改为CPL,则因为以前处于CUR状态,所以previousStatus将是CUR.用于报告或审核,以确保过程合规.

Most of the those fields can and should be set using the API, but some of them are still calculated and therefore can not be set directly. Previous Status is exactly what it says, it is autoset by changing the status of the project. If the project was CUR and changed to CPL then the previousStatus would be CUR because it was previously in the CUR status. This is used for reports or audits to ensure process compliance.

EAC也是根据任务和项目属性自动计算的.

EAC is also auto calculated from the tasks and project attributes.

应注意,categoryID是旧术语,此后已在UI中将其重新标记为Forms.因此,您将转到安装程序"并从那里获取ID.您必须在项目上至少有一个表单才能设置后续的自定义表单值.通过使用API​​的v5并设置categoryIDs集合,您可能拥有不止1个.

It should be noted that categoryID is the legacy term and they have since be relabeled in the UI as Forms. So you would go to Setup and grab the ID from there. You must have at least one form on the project to set the subsequent custom form values. You may have more than 1 by using v5 of the API and setting the categoryIDs collection.

CompanyID,ScheduleID,ResourcePoolID等都可以设置而没有问题.

CompanyID, ScheduleID, ResourcePoolID etc are all settable without a problem.

如果您无法在用户界面中进行设置,那么您也可能无法在API中进行设置.对此的一个例外是extRefID,它不容易在UI中设置,但打算在API中设置.

If you can't set it in the UI you probably can't set it in the API either. The one exception to this is the extRefID which is not easily settable in the UI, but is intended to be set in the API.

这篇关于Attask-通过API更新隐藏的项目属性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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