diff --git a/src/vue-poc/app.vue b/src/vue-poc/app.vue index 37f9648..57e2780 100644 --- a/src/vue-poc/app.vue +++ b/src/vue-poc/app.vue @@ -164,7 +164,8 @@ {href: '/server/repo',text: 'Server code repository',icon: 'local_library'}, {href: '/server/websocket',text: 'Web socket',icon: 'swap_calls'}, {href: '/server/upload',text: 'Upload to server',icon: 'file_upload'}, - {href: '/server/ping',text: 'Ping',icon: 'update'} + {href: '/server/ping',text: 'Ping',icon: 'update'}, + {href: '/server/settings',text: 'Server settings',icon: 'settings_applications'} ]}, { icon: 'camera_roll', @@ -204,7 +205,7 @@ ]}, {href: '/settings',text: 'Settings',icon: 'settings' }, - {href: '/about',text: 'About (v0.3.1)' , icon: 'help' }, + {href: '/about',text: 'About (v0.3.2)' , icon: 'help' }, ] }}, diff --git a/src/vue-poc/components/filters.js b/src/vue-poc/components/filters.js index 6352e2c..7b05db1 100644 --- a/src/vue-poc/components/filters.js +++ b/src/vue-poc/components/filters.js @@ -42,4 +42,8 @@ Vue.filter('round', function(value, decimals) { value = Math.round(value * Math.pow(10, decimals)) / Math.pow(10, decimals); return value; -}); \ No newline at end of file +}); + +Vue.filter('pretty',function(value) { + return JSON.stringify(value, null, 2); +}); diff --git a/src/vue-poc/components/qd-search.vue b/src/vue-poc/components/qd-search.vue index 898ce89..da2e77d 100644 --- a/src/vue-poc/components/qd-search.vue +++ b/src/vue-poc/components/qd-search.vue @@ -8,7 +8,6 @@ autocomplete :loading="loading" clearable - cache-items :items="items2" @keyup.enter="goSearch" :search-input.sync="si" @@ -22,16 +21,18 @@ loading: false, searchItems:[], si: '', - items2:["todo","set","search"] + items2:[{text:"todo", value:"TODO"}, + {text:"set", value:"SET"}, + {"text":"search",value:"SEARCH"} + ] } }, methods: { querySelections (v) { - console.log("QQ",this.si," r:",this.$router.options.routes); this.loading = true // Simulated ajax query setTimeout(() => { - this.items2 = ["aa","bb"], + this.items2 = this.si?this.pages(this.si.toLowerCase()):[], this.loading = false }, 500) }, @@ -39,6 +40,18 @@ goSearch(){ this.$router.push({path: '/search',query: { q: this.q }}) }, + pages(typed){ + var hits=this.$router.options.routes; + console.log(hits.length,hits); + hits=hits.filter(item=>{ + if (!item.meta) return false; + var i=item.meta.title.toString().toLowerCase(); + console.log(i); + return i.indexOf(typed) !== -1}); + + console.log("pages",typed," r:",hits); + return hits.map(r=>{return {text:r.meta.title,value:r.path}}); + } }, watch: { si:function(val){ diff --git a/src/vue-poc/components/qd-table.vue b/src/vue-poc/components/qd-table.vue index d1167a7..04ed544 100644 --- a/src/vue-poc/components/qd-table.vue +++ b/src/vue-poc/components/qd-table.vue @@ -34,7 +34,15 @@ :no-data-text="noDataMsg" > @@ -47,7 +55,6 @@ default: [ { text: 'Name', - left: true, value: 'id' }, { text: 'Permission', value: 'state' } @@ -78,7 +85,7 @@ HTTP.get(this.dataUri) .then(r=>{ this.loading=false; - console.log("items",r); + console.log("items",r.data.items,"headers ",this.headers); this.items=r.data.items; }) } diff --git a/src/vue-poc/features/adminlog/logs.vue b/src/vue-poc/features/adminlog/logs.vue index 83f27fe..d542905 100644 --- a/src/vue-poc/features/adminlog/logs.vue +++ b/src/vue-poc/features/adminlog/logs.vue @@ -6,10 +6,11 @@ diff --git a/src/vue-poc/features/catalog/test/dtd/test.dtd b/src/vue-poc/features/catalog/test/dtd/test.dtd new file mode 100644 index 0000000..b8c5a00 --- /dev/null +++ b/src/vue-poc/features/catalog/test/dtd/test.dtd @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/src/vue-poc/features/catalog/test/importing.xsl b/src/vue-poc/features/catalog/test/importing.xsl new file mode 100644 index 0000000..f83c422 --- /dev/null +++ b/src/vue-poc/features/catalog/test/importing.xsl @@ -0,0 +1,9 @@ + + + + + + \ No newline at end of file diff --git a/src/vue-poc/features/catalog/test/lib/imported.xsl b/src/vue-poc/features/catalog/test/lib/imported.xsl new file mode 100644 index 0000000..901bce8 --- /dev/null +++ b/src/vue-poc/features/catalog/test/lib/imported.xsl @@ -0,0 +1,13 @@ + + + + + + + + + + \ No newline at end of file diff --git a/src/vue-poc/features/catalog/test/test.xml b/src/vue-poc/features/catalog/test/test.xml new file mode 100644 index 0000000..3a39994 --- /dev/null +++ b/src/vue-poc/features/catalog/test/test.xml @@ -0,0 +1,3 @@ + + +xsl:import by XML catalog diff --git a/src/vue-poc/features/catalog/test/test.xq b/src/vue-poc/features/catalog/test/test.xq new file mode 100644 index 0000000..5fa688d --- /dev/null +++ b/src/vue-poc/features/catalog/test/test.xq @@ -0,0 +1,3 @@ +declare variable $dir-uri as xs:string external := string(inspect:static-context((),'base-uri')); +doc('http://transpect.io/test/test.xml'), +xslt:transform(resolve-uri('test.xml', $dir-uri), resolve-uri('importing.xsl', $dir-uri)) \ No newline at end of file diff --git a/src/vue-poc/features/catalog/test/xmlcatalog/catalog.xml b/src/vue-poc/features/catalog/test/xmlcatalog/catalog.xml new file mode 100644 index 0000000..9003e02 --- /dev/null +++ b/src/vue-poc/features/catalog/test/xmlcatalog/catalog.xml @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/src/vue-poc/features/edit/tabs.vue b/src/vue-poc/features/edit/tabs.vue index efbd623..8684d2f 100644 --- a/src/vue-poc/features/edit/tabs.vue +++ b/src/vue-poc/features/edit/tabs.vue @@ -85,10 +85,29 @@ - - info - mode_edit - + + view_quilt + + View + + + mode_edit + + + Source + + + + + + info + + + Info + + + + {{ items.length }} diff --git a/src/vue-poc/features/form/forms.xqm b/src/vue-poc/features/form/forms.xqm new file mode 100644 index 0000000..14d5f4d --- /dev/null +++ b/src/vue-poc/features/form/forms.xqm @@ -0,0 +1,19 @@ +module namespace page = 'quodatum.test.schema'; + + +(:~ + : get a schema + :) +declare +%rest:GET %rest:path("/vue-poc/api/form/schema") +%output:method("json") +function page:schema() +as element(json) +{ + let $s:="schema.json" + =>resolve-uri(static-base-uri()) + =>fetch:text() + =>json:parse() + return $s/* +}; + diff --git a/src/vue-poc/features/form/formschema.vue b/src/vue-poc/features/form/formschema.vue index 79bb7ad..67544f8 100644 --- a/src/vue-poc/features/form/formschema.vue +++ b/src/vue-poc/features/form/formschema.vue @@ -2,11 +2,28 @@