On 10/19/2020 10:46 PM, [email protected] wrote:
To call the sparql motion function I use the ui:createLink function in
which I provide an id (sms name), ui:servlet="sparqlmotion" and I
added arg:projectGraph, which contains the current graph (gained using
the ?projectGraph).
This calls the script, but from sparql motion I can't access the
arg:projectGraph value (containing urn:x-evn-master:XY).
I would need to see more details. It sounds OK, assuming you have
something like <ui:createLink arg:projectGraph="{= ?projectGraph }" ...
/>. You may want to make sure that the outer ?projectGraph variable
actually has a value, see https://uispin.org/ui.html#debugging
Holger
Op maandag 19 oktober 2020 om 14:23:56 UTC+2 schreef Holger Knublauch:
On 19/10/2020 9:34 pm, [email protected] wrote:
Hi Holger,
It is indeed a subclass of teamwork:ProjectTabs, the
?projectGraph variable works perfectly.
Is there perhaps a similair easy way of using this value (e.g.
urn:x-evn-master:someGraph) in a sparql motion script called from
the ui:prototype?
I guess you need to pass this value of ?projectGraph into the SM
script as an argument of your choice. How do you invoke the SM
script from the prototype? Is it a (SPIN) function with
spl:Argument constraints?
Holger
Regards,
Sjoerd
Op zaterdag 17 oktober 2020 om 03:19:34 UTC+2 schreef Holger
Knublauch:
Hi Sjoerd,
the currently active query graph in SWP can be queried using
the SPARQL function ui:currentQueryGraph().
In your example, shouldn't the Tab be a subclass of
teamwork:ProjectTabs instead? In that case, you can access
the current project graph using the variable ?projectGraph
(like urn:x-evn-master:XY) in the ui:prototype.
Holger
On 10/16/2020 10:51 PM, [email protected] wrote:
Hi all,
I've build a small SWP page which shows in EDG as an
additional tab of asset collections (a subclass of
teamwork:Tabs containing a ui:prototype).
From this page I'm able to call different Sparql Motion
scripts which manipulate the asset I have open at that
moment. However, I'd prefer not to hardcode in my SWP or in
my Sparql motion the graph to update. Ideally I'd like the
SWP to 'know' which graph I on at that moment and parse this
to the Sparql motion script. This would allow me to reuse a
script for different datagraphs and use the current graph as
a variable in SPARQL statements.
I thought I could grab the projectGraph attribute from the
URL in EDG which has the current datagraph as its value.
This works using JavaScript, but I can't figure it out using
SWP, nor can I parse my JS variable into my SWP.
Is there a way to either use a JS function in my SWP
prototype, or is there a SWP function which allows me to get
the currently open graph?
Regards,
Sjoerd
--
You received this message because you are subscribed to the
Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails
from it, send an email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/217f25d1-0b84-4903-b292-9560d470c984n%40googlegroups.com
<https://groups.google.com/d/msgid/topbraid-users/217f25d1-0b84-4903-b292-9560d470c984n%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the
Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it,
send an email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/e03d7d12-ef75-4e39-bf09-05708fa6976an%40googlegroups.com
<https://groups.google.com/d/msgid/topbraid-users/e03d7d12-ef75-4e39-bf09-05708fa6976an%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google
Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected]
<mailto:[email protected]>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/04c5f7e7-57c9-4153-9047-b9e99560028bn%40googlegroups.com
<https://groups.google.com/d/msgid/topbraid-users/04c5f7e7-57c9-4153-9047-b9e99560028bn%40googlegroups.com?utm_medium=email&utm_source=footer>.
--
You received this message because you are subscribed to the Google Groups "TopBraid
Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/topbraid-users/202ecc32-d480-3878-6f3e-b1d05fc2bdbe%40topquadrant.com.