Closed sujaypatil96 closed 2 years ago
This seems like a simple way to control sections shown in DH. It won't be awkward down the line, i.e. if there is a need to position those classes under some other "is a" parent?
We can run with this for now, I'll approve.
Oh, I just had another thought - should we be doing this server side in linkml.py? Do we need those classes on the browser side as components of a template, just not visible? That would be easy to arrange in script/data-harmonizer/index.js
@ddooley: ah, I had the very same question yesterday. So the LinkML model has the information we need, including the interfaces or templates that we're hiding. So if at some point we need that information we can get it from the model directly, rather than loading all the information in the browser and then selectively hiding? I think our objective should be to program in such a way as to reduce the performance load on the browser?
I think it would be better if classes like "quantity value" remained in the spec sent to DH in the browser, and we try to have code that makes use of the innards of such things.
see also #282
@ddooley: sure, either works. I'm happy to close PR #295 in favour of one that implements equivalent logic in index.js
.
Ok, I've done the show/hide in latest commit of linkml_datastructure. You could close #295 then. It does modify linkml.py a little bit to add the extra information to menu.js since that's only consumed by toolbar code.
Also, I just added one more commit to generalize the mixs_sv to schema_spec , and to remove an unnecessary "quantity value" clause.
Awesome, I saw the commits on linkml-datastructure. Everything looks good Damion. This issue is ready to be closed, along with PR #295.
There are several templates that appear in the template dropdown. We however want to hide certain ones and make only certain others visible to users. One way to implement the ones to be hidden, for our use case, is to filter out only those templates that are sub classes of the
dh_interface
class.Perhaps we should come up with a more generic filter in the future?