customizzazione SPARQL editor...
This commit is contained in:
parent
e169fbc2e2
commit
9da5a7e7ac
|
@ -327,4 +327,26 @@ const occurrenceof_clause=`{"subject": {"termType": "Variable","value": "cloccu"
|
||||||
"predicate": {"termType": "NamedNode","value": "https://dantenetwork.it/ontology/olires/current/occurrenceOf"},
|
"predicate": {"termType": "NamedNode","value": "https://dantenetwork.it/ontology/olires/current/occurrenceOf"},
|
||||||
"object": {"termType": "Variable","value": "cl"}}`
|
"object": {"termType": "Variable","value": "cl"}}`
|
||||||
|
|
||||||
|
//DEFAULT QUERY PER SPARQL EDITOR
|
||||||
|
|
||||||
|
const defaultEditorQuery=`# ESEMPIO: i periodi della Commedia con una frase con tipo sintattico 'Subordinata Causale'
|
||||||
|
|
||||||
|
PREFIX ecrm: <http://erlangen-crm.org/current/>
|
||||||
|
PREFIX syntit: <https://dantenetwork.it/ontology/syntit/current/>
|
||||||
|
PREFIX olires: <https://dantenetwork.it/ontology/olires/current/>
|
||||||
|
SELECT ?Cantica ?Canto ?Periodo ?FraseSubordinata
|
||||||
|
WHERE {
|
||||||
|
?cl syntit:hasClauseType syntit:Causale ;
|
||||||
|
ecrm:P190_has_symbolic_content ?FraseSubordinata .
|
||||||
|
?sentence a syntit:Sentence ;
|
||||||
|
syntit:hasSyntacticalComponent ?cl;
|
||||||
|
ecrm:P190_has_symbolic_content ?Periodo ;
|
||||||
|
ecrm:P148i_is_component_of ?q_canto.
|
||||||
|
?q_canto ecrm:P102_has_title ?Canto .
|
||||||
|
?cantica ecrm:P102_has_title ?Cantica;
|
||||||
|
olires:hasStructuralComponent ?q_canto.
|
||||||
|
} order by ?Cantica ?Canto
|
||||||
|
`
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -3,24 +3,20 @@
|
||||||
<head>
|
<head>
|
||||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/gitbrent/bootstrap4-toggle@3.6.1/css/bootstrap4-toggle.min.css"/>
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/gitbrent/bootstrap4-toggle@3.6.1/css/bootstrap4-toggle.min.css"/>
|
||||||
<link rel="stylesheet" href="https://code.jquery.com/ui/1.13.1/themes/base/jquery-ui.css"/>
|
<link rel="stylesheet" href="https://code.jquery.com/ui/1.13.1/themes/base/jquery-ui.css"/>
|
||||||
<link rel="stylesheet" id="style2-Boot"
|
<link rel="stylesheet" id="style2-Boot" href="../css/bootstrap.min.lida2.css"/>
|
||||||
href="../css/bootstrap.min.lida2.css">
|
<link rel="stylesheet" id="style2-Custom" href="../css/custom2_4.3.css"/>
|
||||||
<link rel="stylesheet" id="style2-Custom"
|
<link rel="stylesheet" href="../css/collapsemod.css" />
|
||||||
href="../css/custom2_4.3.css">
|
<link href="yasgui.mio.css" rel="stylesheet" type="text/css" />
|
||||||
<link rel="stylesheet" href="../css/collapsemod.css">
|
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
|
||||||
|
|
||||||
<link href="yasgui.mio.css" rel="stylesheet" type="text/css" />
|
|
||||||
|
|
||||||
<script src="https://code.jquery.com/jquery-3.6.0.js"></script>
|
|
||||||
<script
|
<script
|
||||||
src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.bundle.min.js"
|
src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.bundle.min.js"
|
||||||
integrity="sha384-fQybjgWLrvvRgtW6bFlB7jaZrFsaBXjsOMm/tB9LTS58ONXgqbR9W8oWht/amnpF"
|
integrity="sha384-fQybjgWLrvvRgtW6bFlB7jaZrFsaBXjsOMm/tB9LTS58ONXgqbR9W8oWht/amnpF"
|
||||||
crossorigin="anonymous"></script>
|
crossorigin="anonymous"></script>
|
||||||
<script src="https://code.jquery.com/ui/1.13.1/jquery-ui.js" defer></script>
|
<script src="https://code.jquery.com/ui/1.13.1/jquery-ui.js" defer></script>
|
||||||
<script
|
<script src="https://cdn.jsdelivr.net/gh/gitbrent/bootstrap4-toggle@3.6.1/js/bootstrap4-toggle.min.js"></script>
|
||||||
src="https://cdn.jsdelivr.net/gh/gitbrent/bootstrap4-toggle@3.6.1/js/bootstrap4-toggle.min.js"></script>
|
<script src="yasgui.min.js"></script>
|
||||||
<script src="yasgui.min.js"></script>
|
<script type="text/javascript" src="../js/sparqltemplates.js"></script>
|
||||||
<style>
|
<style>
|
||||||
.yasgui .autocompleteWrapper {
|
.yasgui .autocompleteWrapper {
|
||||||
display: none !important;
|
display: none !important;
|
||||||
}
|
}
|
||||||
|
@ -69,30 +65,12 @@
|
||||||
<div class="distanziatore"> </div>
|
<div class="distanziatore"> </div>
|
||||||
<div id="yasgui"></div>
|
<div id="yasgui"></div>
|
||||||
<script>
|
<script>
|
||||||
const defaultQuery=
|
|
||||||
`# ESEMPIO: i periodi della Commedia con una frase con funzione sintattica 'Subordinata Causale'
|
|
||||||
|
|
||||||
PREFIX ecrm: <http://erlangen-crm.org/current/>
|
|
||||||
PREFIX syntit: <https://dantenetwork.it/ontology/syntit/current/>
|
|
||||||
PREFIX olires: <https://dantenetwork.it/ontology/olires/current/>
|
|
||||||
SELECT ?Cantica ?Canto ?Periodo ?FraseSubordinata
|
|
||||||
WHERE {
|
|
||||||
?cl syntit:hasClauseType syntit:Causale ;
|
|
||||||
ecrm:P190_has_symbolic_content ?FraseSubordinata .
|
|
||||||
?sentence a syntit:Sentence ;
|
|
||||||
syntit:hasSyntacticalComponent ?cl;
|
|
||||||
ecrm:P190_has_symbolic_content ?Periodo ;
|
|
||||||
ecrm:P148i_is_component_of ?q_canto.
|
|
||||||
?q_canto ecrm:P102_has_title ?Canto .
|
|
||||||
?cantica ecrm:P102_has_title ?Cantica;
|
|
||||||
olires:hasStructuralComponent ?q_canto.
|
|
||||||
} order by ?Cantica ?Canto
|
|
||||||
`
|
|
||||||
const yasgui = new Yasgui(
|
const yasgui = new Yasgui(
|
||||||
document.getElementById("yasgui"),
|
document.getElementById("yasgui"),
|
||||||
{
|
{
|
||||||
yasqe : {
|
yasqe : {
|
||||||
value: defaultQuery
|
value: defaultEditorQuery
|
||||||
},
|
},
|
||||||
requestConfig : {
|
requestConfig : {
|
||||||
endpoint : "https://hdnlab1.isti.cnr.it/fuseki/commedia/query"
|
endpoint : "https://hdnlab1.isti.cnr.it/fuseki/commedia/query"
|
||||||
|
@ -101,7 +79,7 @@ WHERE {
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
console.log(yasgui.config);
|
console.log(yasgui);
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue