Howdy!! Im taking my first steps with SENAITE, so far loving it.
I wanted to ask for some directions with two modifications I would need to make to the system to be usable in my situation.
1- Making Client SID obligatory at sample registration.
2- Edit the Sample reports to use the Client SID instead of the internal sample ID.
We want to keep the internal IDs strictly for internal use. Client sample ID should be the only identificatory information of the sample in the report, and for that I would need to make it Required at sample logging.
Its there an easy way to achieve this? I would gladly take any recommendations on the best way to achieve this.
Thanks to all of you in advance.
The “easy” way…
-
Modify senaite.core/src/bika/lims/content/analysisrequest.py, lines 837-852 define the Client Sample ID. I think you just need to add the required=1 attribute or parameter to make it a required field on the sample addition form.
-
Modify the report template in senaite.impress/src/senaite/impress/analysisrequest/templates/summary.pt. I created a new table row like:
<tr>
<td class="label" i18n:translate="">Client SID</td>
<td tal:content="model/ClientSampleID"></td>
</tr>
However, this is not the “right” or “best” way. Ideally, you would create your own addon and use adapters, extenders, overrides or something of that nature. I am NOT a developer and have been struggling with Senaite for months now. I would highly recommended @ramonski 's senaite.starter package to help with some of the foundational concepts.
1 Like
Thank you for the answer, that’s already very useful to me. I will checkout the package you mentioned!