- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我正在通过 Ruby 使用 Rally API ( http://developer.help.rallydev.com/ruby-toolkit-rally-rest-api-json )。我想查询投资组合项目的属性(字段?)。我有工作代码,例如这工作正常(虽然它似乎显示名称,而不是 ID——我期待类似“T30”的东西,但它显示“这是我的倡议的名称”):
pi_query.order = "FormattedID Asc"
通过反复试验,我也看到了
pi_query.order = "Name Asc"
也可以。我的问题:我可以在这里使用什么值?我已经找了几个小时了。 Name、FormattedID 和 Description 有效; parent 没有。我找不到引用文档。
(我正在尝试编写一个显示投资组合项目的自定义报告,这是一种更具可读性的方式——主题、倡议和功能以某种我可以打印的嵌套方式显示。Rally 中的投资组合层次结构应用程序不提供可打印的 View ,所以我希望为它编写一个快速脚本。我不需要太多,主要是名称,以及它是主题、倡议还是功能。像这样:)
T30 My first theme
I65 The first initiative
F44 The first feature under that
F45 Another feature
I66 Another initiative
T31 My second theme
I67 Yet another initiative
最佳答案
我找到了。这是文档的正确链接:
https://rally1.rallydev.com/slm/doc/webservice/
如果您单击左侧的“AllowedAttributeValue”,您将获得一个属性列表。按 Ctrl-F 并搜索“投资组合”。当您进入标题为“Portfolio Item (non-creatable type)”的主标题时,会出现一个用于“获取完整对象”和“美化 JSON 输出”的复选框。检查两者,然后点击下方的“查询”按钮。您将在新窗口中获得一个对象模型。
在这个新窗口中,您可以看到所有有效属性。例如,搜索“Parent”,您可以看到 Parent 散列的有效值。其中一个键是 _refObjectName,它为您提供父节点的名称。
这是一个工作示例,它查询计划并显示他们的名字和他们 parent 的名字。
require 'rally_api'
config = {:base_url => "https://rally1.rallydev.com/slm"}
config[:username] = "REPLACE"
config[:password] = "REPLACE"
config[:workspace] = "REPLACE"
config[:project] = "REPLACE"
@rally = RallyAPI::RallyRestJson.new(config)
pi_query = RallyAPI::RallyQuery.new()
pi_query.type = "portfolioitem/initiative"
pi_query.fetch = "Name,FormattedID,Description,PortfolioItemTypeName,Parent"
pi_query.project_scope_up = true
pi_query.project_scope_down = true
pi_query.order = "FormattedID Asc"
pi_results = @rally.find(pi_query)
pi_results.each do |result|
parent_name = (result.Parent == nil)? "" : "has parent \"" + result.Parent["_refObjectName"] + "\""
puts result.FormattedID + " " + result.Name + " " + parent_name
end
关于ruby - 集会 API : documentation list of fields for portfolio items?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16869602/
我正在尝试计算 iFrame 的高度,但不明白为什么 document.body.offsetHeight + document.body.bottomMargin 不等于 document.docu
我正在使用 Node/Mongoose/MongoDB 并尝试构建一个轮询应用程序。一个关键需求是跟踪单个用户对同一民意调查的响应如何随时间变化(他们一遍又一遍地进行同一民意调查)。 我有一个用户模型
首先,我不是普通的博主,我很困惑。如果我的问题不符合要求,请指导我。我会努力改进的。 我已提交 Microsoft Code Review 的 Microsoft CRM 插件。我是 JavaScri
谁能解释为什么使用类似的东西: gci -force "\\computername\c$\users\username\Documents" -recurse 或者 gci -force "\\co
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, over
这个问题已经有答案了: What is the (function() { } )() construct in JavaScript? (28 个回答) 已关闭 6 年前。 说实话,一开始我以为我可
document.getElementsByTagName("*") 适用于 IE/Firefox/Opera,但不适用于 Chrome 和 Safari。 document.all 适用于 IE/C
这个问题在这里已经有了答案: What is the difference between Document and document in JavaScript? (2 个答案) 关闭 8 年前。
我以某种方式发现将事件监听器添加到文档的行为有点奇怪。虽然向 HTMLElements 添加监听器工作正常,但向文档添加监听器不起作用。但奇怪的是,使用 jQuery 可以让它工作。 那么有人可以解释
谁能告诉我这两个 JavaScript 命令之间的区别? 这两个跨主要浏览器的兼容性是什么?我知道 documentElement 与大多数浏览器兼容。 谢谢 最佳答案 document.docume
什么时候应该使用 document.all 与 document.getElementById? 最佳答案 document.all 是 Microsoft 对 W3C 标准的专有扩展。 getEle
当升级到 react-native 0.61.2 时,这个问题出现了。我做到了从手机中删除了 apk 和自动链接使用 react-native link 然后 react-native run-and
当升级到 react-native 0.61.2 时,这个问题出现了。我做到了从手机中删除了 apk 和自动链接使用 react-native link 然后 react-native run-and
我将收到 tungstenite::Message ,它将包含来自客户端的bson文档。我可以将tungstenite::Message转换为Vec,但是如何在服务器端将其转换回 bson::docu
我这里有一个简单的疑问: 文档对象范围位于浏览器选项卡内:我的意思是如果我设置document.tab1 ='tab1' 在一个浏览器选项卡中 它在其他选项卡中不可用。 但是 document.coo
我经常使用并看到推荐的 dom 访问结构,例如这样动态地将内容添加到页面: loader = document.createElement('script'); loader.src = "myurl
我对 JQuery 还很陌生。我正在使用this JQuery 函数在元素上显示工具提示。 我根据我的需要(在这个社区的帮助下)以这种方式编辑了代码: $(document).ready(functi
我想知道哪个是运行js代码的正确方法,该代码根据窗口高度计算垂直菜单的高度并按时设置,不晚不早。 我正在使用 document.ready 但它并没有真正帮助我解决这个问题,它有时没有设置,我必须重新
我正在浏览一个 js 文件并发现这个声明var dataobj=document.all? document.all.id_name : document.getElementById("id_nam
想知道何时使用,这适用于什么浏览器? if (document.all&&document.getElementById) { // Some code block } 最佳答案 我认为没有任何重要的
我是一名优秀的程序员,十分优秀!