Site

14 views
Skip to first unread message

richard...@ymail.com

unread,
Nov 1, 2024, 12:01:43 PMNov 1
to QATrack+
Hello
We have treatment units over different sites in QATrack+. Is there a way you can ascertain which Site in QATrack+ you are in such as a META value?
I wish to read a value (pressure) that will vary depending on which site you are located and don't want to duplicate all the tests for this.
Thanks

Randle Taylor

unread,
Nov 1, 2024, 12:05:24 PMNov 1
to richard...@ymail.com, QATrack+
Hi Richard,

You can do something like:

from qatrack.units.models import Unit
site = Unit.objects.get(number=META['unit_number']).site.name
if site == "Some Site Name":
   # do something


Hope that helps,
Randy

--
You received this message because you are subscribed to the Google Groups "QATrack+" group.
To unsubscribe from this group and stop receiving emails from it, send an email to qatrack+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/qatrack/89c600e9-04d8-429f-9fa2-a56bc1426854n%40googlegroups.com.
Message has been deleted

richard...@ymail.com

unread,
Nov 1, 2024, 9:38:56 PMNov 1
to QATrack+
Hi Randy
Thanks for all your help again.
Richard

Reply all
Reply to author
Forward
0 new messages