code cleanup
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<v-app>
|
||||
<v-navigation-drawer app v-model="showNav">
|
||||
<v-app dark>
|
||||
<v-navigation-drawer app clipped mini-variant v-model="showNav">
|
||||
<v-list>
|
||||
<v-list-tile>
|
||||
<v-list-tile-title>
|
||||
@@ -24,7 +24,7 @@
|
||||
</v-list>
|
||||
</v-navigation-drawer>
|
||||
|
||||
<v-toolbar app>
|
||||
<v-toolbar app clipped-left>
|
||||
<v-toolbar-side-icon
|
||||
@click.stop="showNav = !showNav"
|
||||
></v-toolbar-side-icon>
|
||||
|
||||
@@ -108,7 +108,8 @@ const mountEndPoint = function(url) {
|
||||
delete (id) {
|
||||
return _request.delete(url + id + '/')
|
||||
},
|
||||
options() { return _request.options(url) }
|
||||
options() { return _request.options(url) },
|
||||
list () { return _request.get( url ) }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import api from '../../api.js'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@@ -31,15 +33,13 @@ export default {
|
||||
}
|
||||
},
|
||||
created: function() {
|
||||
const vm = this;
|
||||
fetch('http://localhost:8000/api/recips/')
|
||||
.then((response) => response.json())
|
||||
.then(function(data) {
|
||||
api.recipes.list()
|
||||
.then(data => {
|
||||
for (var idx in data) {
|
||||
var obj = data[idx];
|
||||
vm.content[parseInt(obj.category)].push(obj);
|
||||
this.content[parseInt(obj.category)].push(obj);
|
||||
}
|
||||
});
|
||||
})
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -1,11 +1,6 @@
|
||||
<template>
|
||||
<section>
|
||||
<v-img
|
||||
:src="require('../assets/logo.svg')"
|
||||
class="ma-3"
|
||||
contain
|
||||
height="200"
|
||||
></v-img>
|
||||
<h6 class="title">Home</h6>
|
||||
</section>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
<template>
|
||||
<HelloWorld />
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import HelloWorld from '../components/HelloWorld'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
HelloWorld
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -1 +1 @@
|
||||
{"status":"done","publicPath":"http://localhost:8080/","chunks":{"main":[{"name":"main.js","publicPath":"http://localhost:8080/main.js","path":"/home/artus/Documents/cookAssistant/frontend/dist/main.js"}]}}
|
||||
{"status":"done","publicPath":"http://localhost:8080/","chunks":{"null":[{"name":"0.js","publicPath":"http://localhost:8080/0.js","path":"/home/artus/Documents/cookAssistant/frontend/dist/0.js"}],"app":[{"name":"app.js","publicPath":"http://localhost:8080/app.js","path":"/home/artus/Documents/cookAssistant/frontend/dist/app.js"},{"name":"app.bb93e89c95f5e29b766f.hot-update.js","publicPath":"http://localhost:8080/app.bb93e89c95f5e29b766f.hot-update.js","path":"/home/artus/Documents/cookAssistant/frontend/dist/app.bb93e89c95f5e29b766f.hot-update.js"}]}}
|
||||
Reference in New Issue
Block a user