Merge branch 'release/2.0' of http://git.yoho.cn/fe/yoho-shop-manage into release/2.0
Showing
17 changed files
with
155 additions
and
24 deletions
1 | <template> | 1 | <template> |
2 | <Breadcrumb class="brand-curmb" v-if="showBreadcrumb"> | 2 | <Breadcrumb class="brand-curmb" v-if="showBreadcrumb"> |
3 | - <i class="iconfont icon-alignjustify" aria-hidden="true" @click="$emit('menu-trigger')"></i> | 3 | + <i class="iconfont icon-align14" aria-hidden="true" @click="$emit('menu-trigger')"></i> |
4 | <Breadcrumb-item v-bind:href="item.path" v-for="item in items" :key="item.name">{{item.name}}</Breadcrumb-item> | 4 | <Breadcrumb-item v-bind:href="item.path" v-for="item in items" :key="item.name">{{item.name}}</Breadcrumb-item> |
5 | </Breadcrumb> | 5 | </Breadcrumb> |
6 | </template> | 6 | </template> |
1 | <template> | 1 | <template> |
2 | <Row class="layout-header"> | 2 | <Row class="layout-header"> |
3 | <Col :span="12" class="brand-title"> | 3 | <Col :span="12" class="brand-title"> |
4 | - <i class="iconfont icon-alignjustify" aria-hidden="true" @click="$emit('menu-trigger')"></i> | 4 | + <i class="iconfont icon-align14" aria-hidden="true" @click="$emit('menu-trigger')"></i> |
5 | {{userInfo.name}} | 5 | {{userInfo.name}} |
6 | </Col> | 6 | </Col> |
7 | <Col :span="12" class="shop-info"> | 7 | <Col :span="12" class="shop-info"> |
@@ -23,7 +23,7 @@ export default { | @@ -23,7 +23,7 @@ export default { | ||
23 | name: 'purview-menu', | 23 | name: 'purview-menu', |
24 | data() { | 24 | data() { |
25 | return { | 25 | return { |
26 | - purviews: this.$oriPurviews, // TODO 根据用户权限,初始化菜单 | 26 | + purviews: this.$oriPurviews, |
27 | openNames: [], | 27 | openNames: [], |
28 | activeName: '' | 28 | activeName: '' |
29 | }; | 29 | }; |
@@ -47,9 +47,7 @@ export default { | @@ -47,9 +47,7 @@ export default { | ||
47 | let menu = _.find(this.$purviews, purview => purview.id === menuId); | 47 | let menu = _.find(this.$purviews, purview => purview.id === menuId); |
48 | 48 | ||
49 | if (menu) { | 49 | if (menu) { |
50 | - setTimeout(() => { | ||
51 | - this.$router.push(menu.menu_url); | ||
52 | - }, 100); | 50 | + this.$router.push(menu.menu_url); |
53 | } | 51 | } |
54 | } | 52 | } |
55 | }, | 53 | }, |
@@ -75,10 +73,6 @@ $collapseLeftBorder: 2px; | @@ -75,10 +73,6 @@ $collapseLeftBorder: 2px; | ||
75 | } | 73 | } |
76 | } | 74 | } |
77 | 75 | ||
78 | -.ivu-menu-item-group-title { | ||
79 | - color: #9ea7b4 !important; | ||
80 | -} | ||
81 | - | ||
82 | .ivu-menu-submenu-title { | 76 | .ivu-menu-submenu-title { |
83 | .collapse { | 77 | .collapse { |
84 | display: none; | 78 | display: none; |
@@ -122,11 +116,12 @@ $collapseLeftBorder: 2px; | @@ -122,11 +116,12 @@ $collapseLeftBorder: 2px; | ||
122 | } | 116 | } |
123 | 117 | ||
124 | .ivu-menu { | 118 | .ivu-menu { |
119 | + background: #313540 !important; | ||
125 | display: none; | 120 | display: none; |
126 | position: absolute; | 121 | position: absolute; |
127 | top: 49px; | 122 | top: 49px; |
128 | left: $collapseWidth - $collapseLeftBorder; | 123 | left: $collapseWidth - $collapseLeftBorder; |
129 | - z-index: 2; | 124 | + z-index: 999; |
130 | width: $collapseMenuWidth; | 125 | width: $collapseMenuWidth; |
131 | } | 126 | } |
132 | } | 127 | } |
@@ -8,7 +8,7 @@ | @@ -8,7 +8,7 @@ | ||
8 | 8 | ||
9 | <layout-action> | 9 | <layout-action> |
10 | <Button type="error" @click="onClickCreate" :disabled="this.selection.length === 0">发货</Button> | 10 | <Button type="error" @click="onClickCreate" :disabled="this.selection.length === 0">发货</Button> |
11 | - <Button type="primary" @click="back">返回发货入库列表</Button> | 11 | + <Button type="primary" @click="$router.go(-1)">返回发货入库列表</Button> |
12 | </layout-action> | 12 | </layout-action> |
13 | 13 | ||
14 | <layout-list> | 14 | <layout-list> |
@@ -85,14 +85,14 @@ export default { | @@ -85,14 +85,14 @@ export default { | ||
85 | return this.search(); | 85 | return this.search(); |
86 | }, | 86 | }, |
87 | getParams() { | 87 | getParams() { |
88 | - let params = _.toPairs(Object.assign(this.query, { | 88 | + let params = Object.assign(this.query, { |
89 | maxSortId: _.get(this.category, '[0].value'), | 89 | maxSortId: _.get(this.category, '[0].value'), |
90 | middleSortId: _.get(this.category, '[1].value'), | 90 | middleSortId: _.get(this.category, '[1].value'), |
91 | smallSortId: _.get(this.category, '[2].value') | 91 | smallSortId: _.get(this.category, '[2].value') |
92 | - }, this.pageData)); | 92 | + }, this.pageData); |
93 | 93 | ||
94 | delete params.total; | 94 | delete params.total; |
95 | - return _.fromPairs(params.filter(item => item[1])); | 95 | + return _.pickBy(params, val => val); |
96 | }, | 96 | }, |
97 | reset() { | 97 | reset() { |
98 | this.category = []; | 98 | this.category = []; |
1 | import overview from './overview-iframe'; | 1 | import overview from './overview-iframe'; |
2 | -import sale from './sale'; | 2 | +import sale from './sale-iframe'; |
3 | +import outinstore from './outinstore-iframe'; | ||
4 | +import stock from './stock-iframe'; | ||
3 | 5 | ||
4 | export default { | 6 | export default { |
5 | overview, | 7 | overview, |
6 | - sale | 8 | + sale, |
9 | + outinstore, | ||
10 | + stock | ||
7 | }; | 11 | }; |
app/pages/statistics/stock-iframe/index.js
0 → 100644
app/pages/statistics/stock-iframe/stock.vue
0 → 100644
@@ -5,12 +5,10 @@ let exportExpress = { | @@ -5,12 +5,10 @@ let exportExpress = { | ||
5 | "computed": false, | 5 | "computed": false, |
6 | "key": { | 6 | "key": { |
7 | "type": "Identifier", | 7 | "type": "Identifier", |
8 | - "name": "b" | ||
9 | }, | 8 | }, |
10 | "kind": "init", | 9 | "kind": "init", |
11 | "value": { | 10 | "value": { |
12 | "type": "Identifier", | 11 | "type": "Identifier", |
13 | - "name": "b" | ||
14 | } | 12 | } |
15 | }; | 13 | }; |
16 | 14 |
@@ -5,20 +5,17 @@ let importExress = { | @@ -5,20 +5,17 @@ let importExress = { | ||
5 | "type": "ImportDefaultSpecifier", | 5 | "type": "ImportDefaultSpecifier", |
6 | "local": { | 6 | "local": { |
7 | "type": "Identifier", | 7 | "type": "Identifier", |
8 | - "name": "b" | ||
9 | } | 8 | } |
10 | } | 9 | } |
11 | ], | 10 | ], |
12 | "source": { | 11 | "source": { |
13 | "type": "Literal", | 12 | "type": "Literal", |
14 | - "value": "./b", | ||
15 | - "raw": "'./b'" | ||
16 | } | 13 | } |
17 | }; | 14 | }; |
18 | 15 | ||
19 | module.exports = (name) => { | 16 | module.exports = (name) => { |
20 | importExress.specifiers[0].local.name = name; | 17 | importExress.specifiers[0].local.name = name; |
21 | - importExress.source.value.raw = importExress.source.value = `./${name}`; | 18 | + importExress.source.raw = importExress.source.value = `./${name}`; |
22 | 19 | ||
23 | return importExress; | 20 | return importExress; |
24 | }; | 21 | }; |
build/code/template/edit/_pageName_.vue
0 → 100644
1 | +<template> | ||
2 | + <layout-body> | ||
3 | + <Form :label-width="100" ref="form1" :model="modelData" :rules="ruleValidate"> | ||
4 | + <Form-item label="字段1名称:" prop="field1"> | ||
5 | + <Input v-model="modelData.field1" placeholder="请输入..." style="width: 400px;" /> | ||
6 | + </Form-item> | ||
7 | + <Form-item label="字段2名称:" prop="field2"> | ||
8 | + <Input v-model="modelData.field2" placeholder="请输入..." style="width: 400px;" /> | ||
9 | + </Form-item> | ||
10 | + <Form-item label="字段3:" prop="field3"> | ||
11 | + <radio-season v-model="modelData.field3"></radio-season> | ||
12 | + </Form-item> | ||
13 | + <Form-item label="字段4:" prop="field4"> | ||
14 | + <select-season v-model="modelData.field4"></select-season> | ||
15 | + </Form-item> | ||
16 | + <Form-item label="图片:" prop="img"> | ||
17 | + <div class="upload-item"> | ||
18 | + <div class="upload-item-img"> | ||
19 | + <drag-file-upload bucket="yhb-img01" @success="uploadImageSuccess" @remove="uploadImageRemove"> | ||
20 | + </drag-file-upload> | ||
21 | + </div> | ||
22 | + </div> | ||
23 | + </Form-item> | ||
24 | + <Form-item label="简介:" prop="intro"> | ||
25 | + <editor :content="modelData.intro" @change="editorChange" :z-index="2"> | ||
26 | + </editor> | ||
27 | + </Form-item> | ||
28 | + <Form-item> | ||
29 | + <Button type="primary" @click="submit">保存</Button> | ||
30 | + </Form-item> | ||
31 | + </Form> | ||
32 | + </layout-body> | ||
33 | +</template> | ||
34 | + | ||
35 | +<script> | ||
36 | +import {RadioSeason} from 'components/radio'; | ||
37 | +import {SelectSeason} from 'components/select'; | ||
38 | + | ||
39 | +export default { | ||
40 | + data() { | ||
41 | + return { | ||
42 | + modelData: { | ||
43 | + field1: '', | ||
44 | + field2: '', | ||
45 | + field3: '', | ||
46 | + field4: '', | ||
47 | + img: '', | ||
48 | + intro: '' | ||
49 | + }, | ||
50 | + ruleValidate: { | ||
51 | + field1: [ | ||
52 | + { required: true, message: '字段不能为空', trigger: 'blur' } | ||
53 | + ], | ||
54 | + field2: [ | ||
55 | + { required: true, message: '字段不能为空', trigger: 'blur' }, | ||
56 | + ], | ||
57 | + field3: [ | ||
58 | + { required: true, message: '请选择季节', trigger: 'change' } | ||
59 | + ], | ||
60 | + field4: [ | ||
61 | + { required: true, message: '请选择季节', trigger: 'change' } | ||
62 | + ], | ||
63 | + img: [ | ||
64 | + { required: true, message: '请上传图片' }, | ||
65 | + ], | ||
66 | + intro: [ | ||
67 | + { required: true, message: '请填写备注', trigger: 'change' } | ||
68 | + ] | ||
69 | + } | ||
70 | + }; | ||
71 | + }, | ||
72 | + methods: { | ||
73 | + editorChange: function(content) { | ||
74 | + this.modelData.intro = content; | ||
75 | + }, | ||
76 | + uploadImageSuccess: function(attach, file) { | ||
77 | + this.modelData.img = file.url; | ||
78 | + }, | ||
79 | + uploadImageRemove: function() { | ||
80 | + this.modelData.img = ''; | ||
81 | + }, | ||
82 | + submit: function() { | ||
83 | + this.$refs.form1.validate((valid) => { | ||
84 | + if (valid) { | ||
85 | + this.$Message.success('提交成功!'); | ||
86 | + } else { | ||
87 | + this.$Message.error('表单验证失败!'); | ||
88 | + } | ||
89 | + }); | ||
90 | + } | ||
91 | + }, | ||
92 | + components: { | ||
93 | + RadioSeason, | ||
94 | + SelectSeason | ||
95 | + } | ||
96 | +}; | ||
97 | +</script> |
-
Please register or login to post a comment