Browse Source

feat: integrate template api

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/760/head
Pranav C 3 years ago
parent
commit
d3a08af923
  1. 92
      packages/nc-gui/components/templates/categories.vue
  2. 60
      packages/nc-gui/components/templates/detailed.vue
  3. 68
      packages/nc-gui/components/templates/editor.vue
  4. 74
      packages/nc-gui/components/templates/list.vue
  5. 81
      packages/nc-gui/components/templates/templates.1.js
  6. 62
      packages/nc-gui/components/templates/templates.2.js
  7. 62
      packages/nc-gui/components/templates/templates.3.js
  8. 62
      packages/nc-gui/components/templates/templates.4.js
  9. 62
      packages/nc-gui/components/templates/templates.5.js
  10. 26
      packages/nc-gui/components/templates/templates.categories.js
  11. 61
      packages/nc-gui/components/templates/templates.js
  12. 38
      packages/nc-gui/components/templates/templates.list.js
  13. 2
      packages/nc-gui/layouts/default.vue
  14. 3
      packages/nc-gui/nuxt.config.js

92
packages/nc-gui/components/templates/categories.vue

@ -1,42 +1,76 @@
<template> <template>
<v-list dense height="20px"> <div class="h-100">
<v-list-item dense> <v-list dense>
<v-list-item-subtitle> <v-list-item dense>
<span class="caption">Categories</span> <v-list-item-subtitle>
</v-list-item-subtitle> <span class="caption" @click="counterLoc++">Categories</span>
</v-list-item> </v-list-item-subtitle>
<v-list-item-group v-model="category">
<v-list-item v-for="c in categories" :key="c.title" :value="c.title" dense>
<v-list-item-title>
<span
:class="{'font-weight-black' : category === c.title } "
>
{{
c.title
}}<span />
</span>
</v-list-item-title>
</v-list-item> </v-list-item>
</v-list-item-group> <v-list-item-group v-model="category">
</v-list> <v-list-item v-for="c in categories" :key="c.category" :value="c.category" dense>
<v-list-item-title>
<span
:class="{'font-weight-black' : category === c.category } "
>
{{
c.category
}}
</span> <span class="grey--text ">({{ c.count }})</span>
</v-list-item-title>
</v-list-item>
</v-list-item-group>
</v-list>
<v-btn
v-if="counter > 4"
color="primary"
outlined
@click="showTemplateEditor"
>
Add new template
</v-btn>
</div>
</template> </template>
<script> <script>
import categories from './templates.categories' // import categories from './templates.categories'
export default { export default {
name: "categories", name: 'Categories',
props:{value:String}, props: { value: String, counter: Number },
data:()=>({ data: () => ({
categories categories: []
}), }),
computed:{ computed: {
category:{ category: {
get(){ get() {
return this.value; return this.value
}, },
set(v){ set(v) {
this.$emit('input', v) this.$emit('input', v)
} }
},
counterLoc: {
get() {
return this.counter
},
set(v) {
this.$emit('update:counter', v)
}
}
},
created() {
this.loadCategories()
},
methods: {
async loadCategories() {
try {
const res = await this.$axios.get(`${process.env.NC_API_URL}/api/v1/nc/templates/categories`)
this.categories = res.data
} catch (e) {
console.log(e)
}
},
showTemplateEditor() {
this.$emit('showTemplateEditor')
} }
} }
} }

60
packages/nc-gui/components/templates/detailed.vue

@ -2,53 +2,81 @@
<v-container class="py-0"> <v-container class="py-0">
<div class="d-flex"> <div class="d-flex">
<v-navigation-drawer height="calc(100vh - 40px)"> <v-navigation-drawer height="calc(100vh - 40px)">
<categories @input="v => $emit('load-category', v)"/> <categories ref="cat" :counter.sync="counter" @input="v => $emit('load-category', v)" />
</v-navigation-drawer> </v-navigation-drawer>
<v-container v-if="templateData" fluid style="height: calc(100vh - 40px ); overflow: auto"> <v-container v-if="templateData" fluid style="height: calc(100vh - 40px ); overflow: auto">
<v-img <v-img
:src="templateData.thumbnail" :src="templateData.image_url || `https://picsum.photos/200/300?${id}`"
height="200px" height="200px"
/> />
<div class="d-flex align-center mt-10"> <div class="d-flex align-center mt-10">
<h2 class="display-2 font-weight-bold my-0 flex-grow-1"> <h2 class="display-2 font-weight-bold my-0 flex-grow-1">
{{ templateData.title }} {{ templateData.title }}
</h2> </h2>
<v-btn class="primary" x-large @click="useTemplate">Use template</v-btn> <v-btn class="primary" x-large @click="useTemplate">
Use template
</v-btn>
</div> </div>
<p class="caption mt-10"> <p class="caption mt-10">
{{ templateData.description }} {{ templateData.description }}
</p> </p>
<templat-editor
<templat-editor view-mode :templateData="templateData"></templat-editor> :id="templateId"
:view-mode="counter < 5 && viewMode"
:template-data.sync="templateData"
@saved="onSaved"
/>
</v-container> </v-container>
</div> </div>
</v-container> </v-container>
</template> </template>
<script> <script>
import categories from '~/components/templates/templates.categories' import TemplatEditor from '~/components/templates/editor'
import TemplatEditor from "~/components/templates/editor"; import Categories from '~/components/templates/categories'
import Categories from "~/components/templates/categories";
export default { export default {
name: 'ProjectTemplateDetailed', name: 'ProjectTemplateDetailed',
components: {Categories, TemplatEditor}, components: { Categories, TemplatEditor },
props: { props: {
modal: Boolean, id: [String, Number] modal: Boolean,
viewMode: Boolean,
id: [String, Number]
},
data: () => ({ templateData: null, counter: 0 }),
computed: {
templateId() {
return this.modal ? this.id : this.$route.params.id
}
},
mounted() {
this.loadTemplateData()
}, },
data: () => ({categories, templateData: null}), methods: {
async mounted() { async loadTemplateData() {
this.templateData = (await import(`./templates.${this.modal ? this.id : this.$route.params.id}`)).default try {
}, methods: { const res = await this.$axios.get(`${process.env.NC_API_URL}/api/v1/nc/templates/${this.templateId}`)
const data = res.data
this.templateData = JSON.parse(data.template)
} catch (e) {
console.log(e)
}
},
useTemplate() { useTemplate() {
if (this.modal) { if (this.modal) {
this.$emit('import', this.templateData) this.$emit('import', this.templateData)
} }
},
async onSaved() {
await this.loadTemplateData()
if (this.$refs.cat) {
await this.$refs.cat.loadCategories()
}
this.$emit('saved')
} }
} }
} }
</script> </script>

68
packages/nc-gui/components/templates/editor.vue

@ -45,8 +45,8 @@
mdi-plus mdi-plus
</v-icon> </v-icon>
<!-- <v-btn outlined small class='mr-1' @click='submitTemplate'> Submit Template</v-btn>--> <!-- <v-btn outlined small class='mr-1' @click='submitTemplate'> Submit Template</v-btn>-->
<v-btn color="primary" outlined small class="mr-1" @click="projectTemplateCreate"> <v-btn color="primary" outlined small class="mr-1" @click="saveTemplate">
{{ updateFilename ? 'Update' : 'Create' }} {{ id || localId ? 'Update' : 'Create' }}
Template Template
</v-btn> </v-btn>
</v-toolbar> </v-toolbar>
@ -373,7 +373,7 @@
<div class="mt-10"> <div class="mt-10">
<v-text-field <v-text-field
ref="project" ref="project"
v-model="project.name" v-model="project.title"
class="caption" class="caption"
outlined outlined
dense dense
@ -408,16 +408,17 @@
outlined outlined
dense dense
label="Project Tags" label="Project Tags"
@click="counter++"
/> />
</div> </div>
<v-text-field v-if="counter > 4" v-model="token" outlined dense label="Token" />
</div> </div>
</v-card-text> </v-card-text>
</v-card> </v-card>
</v-col> </v-col>
</v-row> </v-row>
</v-form> </v-form>
<github-config v-if="githubConfigForm" class="mx-auto mt-10 mb-4" />
</v-container> </v-container>
<v-dialog v-model="createTablesDialog" max-width="500"> <v-dialog v-model="createTablesDialog" max-width="500">
@ -506,10 +507,12 @@ export default {
name: 'TemplateEditor', name: 'TemplateEditor',
components: {}, components: {},
props: { props: {
id: [Number, String],
viewMode: Boolean, viewMode: Boolean,
templateData: Object templateData: Object
}, },
data: () => ({ data: () => ({
localId: null,
valid: false, valid: false,
url: '', url: '',
githubConfigForm: false, githubConfigForm: false,
@ -541,7 +544,8 @@ export default {
LinkToAnotherRecord: 'blue lighten-5', LinkToAnotherRecord: 'blue lighten-5',
Rollup: 'pink lighten-5', Rollup: 'pink lighten-5',
Lookup: 'green lighten-5' Lookup: 'green lighten-5'
} },
counter: 0
}), }),
computed: { computed: {
@ -857,34 +861,6 @@ export default {
document.body.removeChild(el) document.body.removeChild(el)
this.$toast.success('Successfully copied JSON data to clipboard!').goAway(3000) this.$toast.success('Successfully copied JSON data to clipboard!').goAway(3000)
}, },
async submitTemplate() {
try {
this.copyJSON()
this.$toast.info('Initing Github for template').goAway(3000)
// const res = await axios.get('https://hookb.in/K3k2OOeN01fPMK88MMwb', el.value);
const res = await this.$axios.post('https://nocodb.com/api/v1/projectTemplateCreate', this.projectTemplate)
console.log(res)
this.$toast.success('Inited Github successfully').goAway(3000)
window.open(res.data.path, '_blank')
} catch (e) {
console.log(e)
this.$toast.error('Some error occurred').goAway(3000)
}
},
async template() {
//
// this.$axios({
// method:'post',
// url:'https://nocodb.com/api/api/v1/projectTemplateCreate',
// data:{
// name:'test_name'
// }
// }).then(res => {
// console.log(res.data)
// }).catch(e => console.log(e.message))
},
openUrl() { openUrl() {
window.open(this.url, '_blank') window.open(this.url, '_blank')
}, },
@ -1026,6 +1002,30 @@ export default {
accord.focus() accord.focus()
accord.scrollIntoView() accord.scrollIntoView()
}) })
},
async saveTemplate() {
try {
if (this.id || this.localId) {
await this.$axios.put(`${process.env.NC_API_URL}/api/v1/nc/templates/${this.id || this.localId}`, this.projectTemplate, {
params: {
token: this.token
}
})
this.$toast.success('Template updated successfully').goAway(3000)
} else {
const res = await this.$axios.post(`${process.env.NC_API_URL}/api/v1/nc/templates`, this.projectTemplate, {
params: {
token: this.token
}
})
this.localId = res.data.id
this.$toast.success('Template updated successfully').goAway(3000)
}
this.$emit('saved')
} catch (e) {
this.$toast.error(e.message).goAway(3000)
}
} }
} }

74
packages/nc-gui/components/templates/list.vue

@ -1,12 +1,21 @@
<template> <template>
<v-container v-if="!modal || selectedId === null " class="py-0"> <v-container v-if="newEditor || !modal || selectedId === null " class="py-0">
<div class="d-flex"> <div class="d-flex">
<v-navigation-drawer height="calc(100vh - 40px)"> <v-navigation-drawer height="calc(100vh - 40px)">
<categories v-model="category"></categories> <categories
ref="cat"
v-model="category"
:counter.sync="counter"
@input="newEditor=false"
@showTemplateEditor="newEditor = true"
/>
</v-navigation-drawer> </v-navigation-drawer>
<v-container fluid style="height: calc(100vh - 40px ); overflow: auto"> <template-editor v-if="newEditor" style="width:100%" @saved="onSaved" />
<v-container v-else fluid style="height: calc(100vh - 40px); overflow: auto">
<v-row <v-row
v-if="templateList && templateList.length"> v-if="templateList && templateList.length"
class="align-stretch"
>
<v-col <v-col
v-for="(template,i) in templateList" v-for="(template,i) in templateList"
:key="i" :key="i"
@ -19,10 +28,11 @@
@click="openTemplate(template.id)" @click="openTemplate(template.id)"
> >
<v-card <v-card
height="100%"
class="mx-auto" class="mx-auto"
> >
<v-img <v-img
:src="template.thumbnail" :src="template.image_url || `https://picsum.photos/200/300?${template.id}`"
height="200px" height="200px"
/> />
@ -39,40 +49,66 @@
</v-col> </v-col>
</v-row> </v-row>
<div v-else class="d-flex justify-center mt-10 "> <div v-else class="d-flex justify-center mt-10 ">
<v-alert class="flex-shrink-1" type="info" outlined dense > <v-alert class="flex-shrink-1" type="info" outlined dense>
No templates found No templates found
</v-alert> </v-alert>
</div> </div>
</v-container> </v-container>
</div> </div>
</v-container> </v-container>
<project-template-detailed v-else @load-category="v =>{ category = v; selectedId = null }" :id="selectedId" :modal="modal" v-on="$listeners" /> <project-template-detailed
v-else
:id="selectedId"
:counter="counter"
:modal="modal"
:view-mode="counter < 5"
@saved="onSaved"
@load-category="v =>{ category = v; selectedId = null }"
v-on="$listeners"
/>
</template> </template>
<script> <script>
import templateList from './templates.list' // import templateList from './templates.list'
import ProjectTemplateDetailed from '~/components/templates/detailed' import ProjectTemplateDetailed from '~/components/templates/detailed'
import Categories from "~/components/templates/categories"; import Categories from '~/components/templates/categories'
import TemplateEditor from '~/components/templates/editor'
export default { export default {
name: 'ProjectTemplates', name: 'ProjectTemplates',
components: {Categories, ProjectTemplateDetailed }, components: { TemplateEditor, Categories, ProjectTemplateDetailed },
props: { props: {
modal: Boolean modal: Boolean
}, },
data: () => ({ data: () => ({
category: null, category: null,
selectedId: null selectedId: null,
templateListLoc: [],
counter: 0,
newEditor: false
}), }),
computed: { computed: {
templateList() { templateList() {
return templateList.filter(t => !this.category || t.category === this.category) return this.templateListLoc.filter(t => !this.category || t.category === this.category)
} }
}, },
created() {
this.loadTemplates()
},
methods: { methods: {
async loadTemplates() {
try {
const res = await this.$axios.get(`${process.env.NC_API_URL}/api/v1/nc/templates`)
this.templateListLoc = res.data.data
} catch (e) {
console.log(e)
}
},
getShortDescription(str) { getShortDescription(str) {
if (str.length < 200) { return str } if (str.length < 200) {
return str
}
return `${str.slice(0, 200)}...` return `${str.slice(0, 200)}...`
}, },
openTemplate(id) { openTemplate(id) {
@ -81,13 +117,19 @@ export default {
} else { } else {
this.$router.push(`/project/templates/${id}`) this.$router.push(`/project/templates/${id}`)
} }
},
async onSaved() {
await this.loadTemplates()
if (this.$refs.cat) {
await this.$refs.cat.loadCategories()
}
} }
} }
} }
</script> </script>
<style scoped> <style scoped>
/deep/ .v-list-item{ /deep/ .v-list-item {
min-height: 30px; min-height: 30px;
} }
</style> </style>

81
packages/nc-gui/components/templates/templates.1.js

@ -1,81 +0,0 @@
const templates = {
title: 'Art Gallery Management',
thumbnail: 'https://picsum.photos/200/300?1',
tables: [
{
tn: 'blog',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
},
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [
{
tn: 'comment',
_cn: 'title3'
}
],
manyToMany: [
{
rtn: 'tag',
_cn: 'title4'
}
],
v: [
{
_cn: 'comments_count',
rl: {
rltn: 'comment',
rlcn: 'body',
type: 'hm',
fn: 'count'
}
}
]
},
{
tn: 'comment',
columns: [
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [],
manyToMany: [],
v: [
{
_cn: 'blog_title',
lk: {
ltn: 'blog',
type: 'bt',
lcn: 'title'
}
}
]
},
{
tn: 'tag',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
}
],
hasMany: [],
manyToMany: [],
v: []
}
],
category: 'test',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}
export default templates

62
packages/nc-gui/components/templates/templates.2.js

@ -1,62 +0,0 @@
const templates = {
title: 'Digital video production',
thumbnail: 'https://picsum.photos/200/300?2',
tables: [
{
tn: 'blog',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
},
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [
{
tn: 'comment',
_cn: 'title3'
}
],
manyToMany: [
{
rtn: 'tag',
_cn: 'title4'
}
],
v: []
},
{
tn: 'comment',
columns: [
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [],
manyToMany: [],
v: []
},
{
tn: 'tag',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
}
],
hasMany: [],
manyToMany: [],
v: []
}
],
category: 'test',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}
export default templates

62
packages/nc-gui/components/templates/templates.3.js

@ -1,62 +0,0 @@
const templates = {
title: 'Content calendar',
thumbnail: 'https://picsum.photos/200/300?3',
tables: [
{
tn: 'blog',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
},
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [
{
tn: 'comment',
_cn: 'title3'
}
],
manyToMany: [
{
rtn: 'tag',
_cn: 'title4'
}
],
v: []
},
{
tn: 'comment',
columns: [
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [],
manyToMany: [],
v: []
},
{
tn: 'tag',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
}
],
hasMany: [],
manyToMany: [],
v: []
}
],
category: 'test',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}
export default templates

62
packages/nc-gui/components/templates/templates.4.js

@ -1,62 +0,0 @@
const templates = {
title: 'Event Marketing',
thumbnail: 'https://picsum.photos/200/300?3',
tables: [
{
tn: 'blog',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
},
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [
{
tn: 'comment',
_cn: 'title3'
}
],
manyToMany: [
{
rtn: 'tag',
_cn: 'title4'
}
],
v: []
},
{
tn: 'comment',
columns: [
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [],
manyToMany: [],
v: []
},
{
tn: 'tag',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
}
],
hasMany: [],
manyToMany: [],
v: []
}
],
category: 'test',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}
export default templates

62
packages/nc-gui/components/templates/templates.5.js

@ -1,62 +0,0 @@
const templates = {
title: 'Wedding Planning',
thumbnail: 'https://picsum.photos/200/300?5',
tables: [
{
tn: 'blog',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
},
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [
{
tn: 'comment',
_cn: 'title3'
}
],
manyToMany: [
{
rtn: 'tag',
_cn: 'title4'
}
],
v: []
},
{
tn: 'comment',
columns: [
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [],
manyToMany: [],
v: []
},
{
tn: 'tag',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
}
],
hasMany: [],
manyToMany: [],
v: []
}
],
category: 'test',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}
export default templates

26
packages/nc-gui/components/templates/templates.categories.js

@ -1,26 +0,0 @@
const categories = [
{ title: 'Content production' },
{ title: 'Featured' },
{ title: 'Creative' },
{ title: 'Event Planning' },
{ title: 'Everyday Life' },
{ title: 'Groups, Clubs & Hobbies' },
{ title: 'HR & Recruiting' },
{ title: 'Legal' },
{ title: 'Local Business' },
{ title: 'Marketing' },
{ title: 'Nonprofit' },
{ title: 'Personal' },
{ title: 'PR & Communications' },
{ title: 'Product, design, and UX' },
{ title: 'Project Management' },
{ title: 'Publishing' },
{ title: 'Real Estate' },
{ title: 'Remote work' },
{ title: 'Sales & Customers' },
{ title: 'Software Development' },
{ title: 'Startup' },
{ title: 'Venture Capital' }
]
export default categories

61
packages/nc-gui/components/templates/templates.js

@ -1,61 +0,0 @@
const templates = {
title: 'Project name',
tables: [
{
tn: 'blog',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
},
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [
{
tn: 'comment',
_cn: 'title3'
}
],
manyToMany: [
{
rtn: 'tag',
_cn: 'title4'
}
],
v: []
},
{
tn: 'comment',
columns: [
{
cn: 'body',
uidt: 'LongText'
}
],
hasMany: [],
manyToMany: [],
v: []
},
{
tn: 'tag',
columns: [
{
cn: 'title',
uidt: 'SingleLineText'
}
],
hasMany: [],
manyToMany: [],
v: []
}
],
category: 'test',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}
export default templates

38
packages/nc-gui/components/templates/templates.list.js

@ -1,38 +0,0 @@
const templatesList = [{
id: 1,
title: 'Art Gallery Management',
category: 'Creative',
thumbnail: 'https://picsum.photos/200/300?1',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}, {
id: 2,
title: 'Digital video production',
category: 'Creative',
thumbnail: 'https://picsum.photos/200/300?2',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}, {
id: 3,
title: 'Content calendar',
category: 'Creative',
thumbnail: 'https://picsum.photos/200/300?3',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}, {
id: 4,
title: 'Event Marketing',
category: 'Event Planning',
thumbnail: 'https://picsum.photos/200/300?4',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}, {
id: 5,
title: 'Wedding Planning',
category: 'Event Planning',
thumbnail: 'https://picsum.photos/200/300?5',
tags: 'a,b,c',
description: 'I\'m a thing. But, like most politicians, he promised more than he could deliver. You won\'t have time for sleeping, soldier, not with all the bed making you\'ll be doing. Then we\'ll go with that data file! Hey, you add a one and two zeros to that or we walk!'
}]
export default templatesList

2
packages/nc-gui/layouts/default.vue

@ -44,7 +44,7 @@
{{ ghStarText }} {{ ghStarText }}
</gh-btns-star> </gh-btns-star>
<a class="align-self-center caption font-weight-bold ml-1 mr-2 white--text" href="https://docs.nocodb.com" target="_blank">Docs</a> <a class="align-self-center caption font-weight-bold ml-1 mr-2 white--text" href="https://docs.nocodb.com" target="_blank">Docs</a>
<templates-modal class="align-self-center" /> <templates-modal v-if="isDashboard" class="align-self-center" />
</v-toolbar-items> </v-toolbar-items>
<!-- <template v-if="!isThisMobile "> <!-- <template v-if="!isThisMobile ">

3
packages/nc-gui/nuxt.config.js

@ -209,7 +209,8 @@ export default {
'material-design-icons-iconfont/dist/material-design-icons.css' 'material-design-icons-iconfont/dist/material-design-icons.css'
], ],
env: { env: {
EE: !!process.env.EE EE: !!process.env.EE,
NC_API_URL: 'http://localhost:3000'
}, },
pwa: { pwa: {
workbox: { workbox: {

Loading…
Cancel
Save