Skip to content

Commit

Permalink
new
Browse files Browse the repository at this point in the history
  • Loading branch information
liangxiaojuan committed Dec 28, 2016
1 parent 571af75 commit 4e2dd31
Show file tree
Hide file tree
Showing 7 changed files with 1,426 additions and 32 deletions.
4 changes: 2 additions & 2 deletions config/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ module.exports = {
env: require('./prod.env'),
index: path.resolve(__dirname, '../dist/index.html'),
assetsRoot: path.resolve(__dirname, '../dist'),
assetsSubDirectory: 'static',
assetsPublicPath: '/',
assetsSubDirectory: './static',
assetsPublicPath: './',
productionSourceMap: true,
// Gzip off by default as many popular static hosts such as
// Surge or Netlify already gzip all static assets for you.
Expand Down
Binary file added dist.zip
Binary file not shown.
21 changes: 12 additions & 9 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
</div>
<!-- 头部 -->
<keep-alive>
<router-view :seller="seller" ></router-view>
<router-view :seller="seller"></router-view>
</keep-alive>


Expand All @@ -33,7 +33,8 @@
<script type="text/ecmascript-6">
import header from './components/header/header.vue';
import {urlParse} from 'common/js/util';
const ERR_OK = 0;
import data from 'common/json/data.json';
// const ERR_OK = 0;
export default {
data() {
return {
Expand All @@ -46,13 +47,15 @@
};
},
created() {
this.$http.get('/api/seller?id=' + this.seller.id).then((response) => {
response = response.body;
if (response.errno === ERR_OK) {
this.seller = response.data;
this.seller = Object.assign({}, this.seller, response.data);
}
});
// this.$http.get('/api/seller?id=' + this.seller.id).then((response) => {
// response = response.body;
// if (response.errno === ERR_OK) {
// this.seller = response.data;
// this.seller = Object.assign({}, this.seller, response.data);
// }
// });
this.seller = data.seller;
},
components: {
'v-header': header
Expand Down
Loading

0 comments on commit 4e2dd31

Please sign in to comment.