Skip to content

Commit

Permalink
Feature/fix resource addition #11 (#19)
Browse files Browse the repository at this point in the history
Fix resource adding
  • Loading branch information
Michiel Leyman committed Aug 26, 2017
1 parent 177233d commit 76834b3
Show file tree
Hide file tree
Showing 10 changed files with 19 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@ test/unit/coverage
*.ntvs*
*.njsproj
*.sln

.env
2 changes: 1 addition & 1 deletion build/dev-server.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ var path = require('path')
var express = require('express')
var webpack = require('webpack')
var proxyMiddleware = require('http-proxy-middleware')
var webpackConfig = process.env.NODE_ENV === 'testing' || 'production'
var webpackConfig = process.env.NODE_ENV === 'testing' || process.env.NODE_ENV === 'production'
? require('./webpack.prod.conf')
: require('./webpack.dev.conf')

Expand Down
3 changes: 3 additions & 0 deletions build/webpack.base.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ module.exports = {
entry: {
app: './src/main.js'
},
node: {
fs: 'empty'
},
output: {
path: config.build.assetsRoot,
filename: '[name].js',
Expand Down
3 changes: 2 additions & 1 deletion config/dev.env.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@ var merge = require('webpack-merge')
var prodEnv = require('./prod.env')

module.exports = merge(prodEnv, {
NODE_ENV: '"development"'
NODE_ENV: '"development"',
PRISMA_API_URL: `"${process.env.PRISMA_API_URL}"`
})
1 change: 1 addition & 0 deletions config/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// see http://vuejs-templates.github.io/webpack for documentation.
require('dotenv').config()
var path = require('path')

module.exports = {
Expand Down
5 changes: 5 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"dependencies": {
"@websanova/vue-auth": "^2.16.3-beta",
"axios": "^0.16.2",
"dotenv": "^4.0.0",
"element-ui": "^1.4.3",
"vue": "^2.3.3",
"vue-axios": "^2.0.2",
Expand Down
3 changes: 2 additions & 1 deletion src/components/album/Album.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export default {
};
},
mounted() {
if (!this.album.heritage[0]) return;
if (!this.album.heritage || !this.album.heritage[0]) return;
const coverSource = this.album.heritage[0].asset_name;
if (!coverSource) return;
api.getProtectedImage(coverSource).then((response) => {
Expand Down Expand Up @@ -94,6 +94,7 @@ export default {
display: flex;
align-items: center;
justify-content: center;
overflow: hidden;
}
.album a {
Expand Down
2 changes: 1 addition & 1 deletion src/pages/Login.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
</header>
<form>
<el-input placeholder="Email" v-model="email"></el-input>
<el-input placeholder="Password" v-model="password"></el-input>
<el-input type="password" placeholder="Password" v-model="password"></el-input>
<el-button type="primary" @click="login">Log in</el-button>
<!-- <button @click="login" v-if="!$auth.check()">Login</button> -->
</form>
Expand Down
1 change: 1 addition & 0 deletions src/pages/Story.vue
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ export default {
.then((res) => {
const amountOfHeritage = this.album.heritage.length;
this.album.heritage[amountOfHeritage - 1].asset_name = res.data.meta.location;
this.ftue = false;
})
.catch((err) => {
console.log(err);
Expand Down

0 comments on commit 76834b3

Please sign in to comment.