4

I want to use YouTrack for Key-Account-Management.

There is one Epic and for each key account (customer) one sub-issue.

I want to talk to each key account roughly every 6 months.

Is there a way to hide or snooze an issue for some time.

The issue should be like resolved for some months, and then come back if the snooze time has expired.

How to do this with youtrack?

guettli
  • 25,042
  • 81
  • 346
  • 663

1 Answers1

3

The issue should be like resolved for some months

It seems that one can simply resolve the issue to accomplish it. The tricky part is to reopen them automatically in 6 months. The following workflow rule can reopen YouTrack issues by timer:

var entities = require('@jetbrains/youtrack-scripting-api/entities');
var workflow = require('@jetbrains/youtrack-scripting-api/workflow');

exports.rule = entities.Issue.onSchedule({
  title: workflow.i18n('Reopen issues in 6 months'),
  search: '#Resolved',    // Narrow the search to specify which issues are affected
  cron: '0 0 0 ? * * *',  // Fires once a day
  guard: function(ctx) {
    // If an issue was in a resolved state for half a year already...
    return Date.now() - ctx.issue.resolved < 15552000000;
  },
  action: function(ctx) {
    // ... then reopen it
    ctx.issue.State = ctx.State.Open;
  },
  requirements: {
    State: {
      type: entities.State.fieldType,
      Open: {}
    }
  }
});
Jk1
  • 11,233
  • 9
  • 54
  • 64
  • I guess it works. But the timedelta is fixed. `+Nx` would be great. With x being d for days , w for weeks, m for months would be great. "d" should be the default and optional. – guettli Jun 04 '19 at 07:06
  • Related: https://softwarerecs.stackexchange.com/questions/62192/inbox-zero-for-android – guettli Jun 04 '19 at 07:06
  • I fail to see how this is related, since the solution provided here is YouTrack specific. – Jk1 Jun 04 '19 at 08:00
  • I have a goal called "zero inbox". There are several inboxes: Issues in youtrack, issues on github, mails, notes on paper, ... – guettli Jun 04 '19 at 08:10
  • Can't help you with that. The solution above is designed to handle issues in YouTrack bug tracking system only. – Jk1 Jun 04 '19 at 09:33