FHIR Chat · Repeat Timing resource for a ProcedureRequest · implementers

Stream: implementers

Topic: Repeat Timing resource for a ProcedureRequest


view this post on Zulip Raheel Sayeed (Dec 20 2017 at 20:16):

I have a ProcedureRequest that is to occur once, every week on monday or tuesday for two months
I've deduced it as following:

Timing.repeat.frequency = 1
Timing.repeat.period = 1
Timing.repeat.periodUnit = wk
Timing.repeat.dayOfWeek = mon|tue
Timing.repeat.bounds.range (those two months)

The docs say

If no days are specified, the action is assumed to happen every day as otherwise specified. The elements frequency and period cannot be used as well as dayOfWeek.

I see that either I use frequency/periodUnit or dayOfWeek but not both. This is good for the above use case.

What if there is a procedure to be done once every 6 hrs only on every monday for two months (totally arbitrary for now). How would the resource change?

view this post on Zulip Lloyd McKenzie (Dec 20 2017 at 20:40):

Actually, your first use-case can't be expressed because if you drop frequency and period and just list mon|tue, that would say "do this every Monday and Tuesday for two months". Allowing frequency with dayOfWeek would change the meaning of dayOfWeek from an "and" to an "or", which is why we prohibit that - changing the interpretation of elements is generally a bad thing. Essentially what you're looking for is an intersection between two timings - one saying "once a week" and one acting as a filter that says "only on these days". At the moment, we've said that's overly complex for core and would need to be handled by extension. If you disagree, you're welcome to submit a change request.

view this post on Zulip Raheel Sayeed (Dec 20 2017 at 21:26):

Could you elaborate on how would I handle it in the current version if at all it is possible?
I'm not sure if your implying I use two Timing resources? One as an extension in the ProcedureRequest?

view this post on Zulip Lloyd McKenzie (Dec 20 2017 at 22:22):

You'd need to use extensions on the Timing data type


Last updated: Apr 12 2022 at 19:14 UTC