【问题标题】:VSTS REST API - Get list of Items changed after specified dateVSTS REST API - 获取指定日期后更改的项目列表
【发布时间】:2018-06-20 19:48:32
【问题描述】:

在 vsts rest API 中,我可以获得在指定日期之前更改的项目列表:

http://server:8080/tfs/ProjName/_apis/tfvc/items?versionDescriptor.versionType=date&versionDescriptor.version=2018-06-12T00:00&scopePath=$/Path

但是我如何才能获得在此日期之后更改的项目列表?

【问题讨论】:

    标签: tfs azure-devops tfvc


    【解决方案1】:

    不,我们无法直接通过 REST API 获取指定日期之后的项目列表。

    但是,您可以运行 REST API 两次以获取特定日期之前的项目列表,然后将它们进行比较以检索不同日期之间的项目列表。

    例如:

    1. 获取日期2018-05-12之前的物品列表:

      GET http://server:8080/tfs/ProjName/_apis/tfvc/items?versionDescriptor.versionType=date&versionDescriptor.version=2018-05-12T00:00&scopePath=$/Path
      
    2. 获取日期2018-06-21之前的物品列表:

      GET http://server:8080/tfs/ProjName/_apis/tfvc/items?versionDescriptor.versionType=date&versionDescriptor.version=2018-06-21T00:00&scopePath=$/Path
      
    3. 比较以上回复中的项目,您可以得到 日期2018-05-12之后的项目列表

    【讨论】:

      猜你喜欢
      • 2016-06-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多