【问题标题】:Rally 2.1 SDK - Filtering User Stories by IterationsRally 2.1 SDK - 按迭代过滤用户故事
【发布时间】:2018-06-01 18:24:21
【问题描述】:

是否可以根据开始迭代和结束迭代之间的迭代来过滤用户故事。我能够过滤从开始迭代向前和结束迭代向后的所有用户故事,但是当我在我的商店对象中使用“.and”过滤器时出现错误。

 var StartDateFilter = Ext.create('Rally.data.QueryFilter', {
        property: 'Iteration',
        operator: '>=',
        value: StartIteration
    });


    var UserStoryFilter = StartDateFilter.and(Ext.create(
        'Rally.data.wsapi.Filter', {
            property: 'Iteration',
            operator: '<=', // combines the the iterations so it receives all iterations in between 
            value: EndIteration
    }));


    var UserStoryFilter = StartDateFilter.and(EndDateFilter);


    this.defectStore = Ext.create('Rally.data.wsapi.Store', {
        model: 'User Story', 
        autoLoad: true,                         
        pageSize: 1000,
        filters : UserStoryFilter,

        listeners: {
            load: function(myStore, myData) {
                console.log(myData); 
            },
            scope: this                         
        },
        fetch: ['CreationDate','FormattedID', 'Name', 'PlanEstimate', 'Feature', 'PortfolioItem', 'Milestones','Parent','Children']
        });

【问题讨论】:

    标签: javascript json sdk rally


    【解决方案1】:

    你不能像你一样直接使用它,但你应该可以做类似的事情......

    var filters = [
        {
            property: 'Iteration.StartDate',
            operator: '>=',
            value: '2018-05-01' //iso formatted iteration start date
        },
        {
            property: 'Iteration.EndDate',
            operator: '<=',
            value: '2018-06-30' //iso formatted iteration end date
        },
    ];
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-03-04
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多