Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
P
pica.cloud.web-education-admin
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
Close sidebar
动态
分支图
统计图
创建新议题
提交
议题看板
打开侧边栏
jingqi.liu
pica.cloud.web-education-admin
提交
23ed5d5a
提交
23ed5d5a
编写于
10月 26, 2020
作者:
张平
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'dev-export-20201026' into 'release'
Dev export 20201026 商城 导出商品,订单 codereviewer:ping.zhang See merge request !225
上级
f1300a8e
e59e29c5
变更
4
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
52 行增加
和
7 行删除
+52
-7
fetch.js
src/utils/fetch.js
+1
-1
yqrangeApi.js
src/utils/yqrange/yqrangeApi.js
+21
-0
goods-manage.vue
src/views/goods/goods-manage.vue
+17
-6
order-manage.vue
src/views/goods/order-manage.vue
+13
-0
未找到文件。
src/utils/fetch.js
浏览文件 @
23ed5d5a
...
...
@@ -54,7 +54,7 @@ service.interceptors.request.use(config => {
}
if
(
process
.
env
.
BUILD_ENV
==
"development"
){
// 本地开发环境qgit
// console.log('环境变量>>>> ', process.env.BUILD_ENV);
config
.
headers
[
'token'
]
=
'
663645D26D40417AA86E5395D933E7B7
'
;
config
.
headers
[
'token'
]
=
'
C5172D7D7825463CA46752A894236AC2
'
;
// config.headers['token'] = localStorage.getItem('storageToken')
}
else
{
config
.
headers
[
'token'
]
=
localStorage
.
getItem
(
'storageToken'
)
...
...
src/utils/yqrange/yqrangeApi.js
浏览文件 @
23ed5d5a
...
...
@@ -171,4 +171,25 @@ export const getCircleDept = (params) => {
})
};
export
const
getGoodsExportUrl
=
(
params
)
=>
{
return
fetch
({
headers
,
url
:
getBaseUrl
(
'store/goods/export'
),
method
:
'post'
,
data
:
params
,
description
:
'商品导出'
,
})
};
export
const
getOrdersExportUrl
=
(
params
)
=>
{
debugger
return
fetch
({
headers
,
url
:
getBaseUrl
(
'/store/orders/admin/export'
),
method
:
'get'
,
params
:
params
,
description
:
'导出订单'
,
})
};
src/views/goods/goods-manage.vue
浏览文件 @
23ed5d5a
...
...
@@ -33,13 +33,14 @@
</el-col>
</el-row>
<el-row
:gutter=
"30"
type=
"flex"
style=
"margin-top: 10px"
>
<el-col
:span=
"1
8
"
>
<el-col
:span=
"1
2
"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"batchOpt('on')"
>
批量上架
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"batchOpt('off')"
>
批量下架
</el-button>
</el-col>
<el-col
:span=
"6"
style=
"text-align: right"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"batchOpt(3)"
>
批量导入
</el-button>
<el-col
:span=
"12"
style=
"text-align: right"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportOpt"
>
批量导出商品
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"batchOpt(3)"
>
批量导入商品
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"edit('add')"
>
新建单个商品
</el-button>
</el-col>
</el-row>
...
...
@@ -173,7 +174,7 @@
<
script
>
import
{
openLoading
,
closeLoading
}
from
"../../utils/utils"
;
import
BreadCrumb
from
"@/components/breadcrumb.vue"
;
import
{
getRangeList
,
updateRangeStatus
}
from
"../../utils/yqrange/yqrangeApi"
;
import
{
getRangeList
,
updateRangeStatus
,
getGoodsExportUrl
,
getOrdersExportUrl
}
from
"../../utils/yqrange/yqrangeApi"
;
import
{
getGoodsList
,
batchOnOff
,
uploadExcel
}
from
'@/utils/goods'
;
import
{
getBaseUrl
}
from
'@/utils/index'
var
typeList
=
[{
...
...
@@ -406,7 +407,7 @@
setTimeout
(()
=>
{
this
.
getLists
()
},
2000
)
}
})
}
...
...
@@ -524,7 +525,6 @@
this
.
getLists
();
},
handleSizeChange
(
val
)
{
this
.
searchForm
.
pageSize
=
val
;
this
.
searchForm
.
pageNo
=
1
;
...
...
@@ -534,6 +534,17 @@
this
.
searchForm
.
pageNo
=
val
;
this
.
getLists
();
},
exportOpt
()
{
const
{
goodsIdList
,
goodsType
,
goodsName
,
storeId
}
=
this
.
searchForm
;
getGoodsExportUrl
({
goodsIdList
,
goodsType
,
goodsName
,
storeId
}).
then
(
res
=>
{
if
(
res
.
code
!=
'000000'
)
{
this
.
$message
({
message
:
res
.
message
,
type
:
'error'
});
return
;
}
window
.
open
(
res
.
data
);
});
}
},
}
</
script
>
...
...
src/views/goods/order-manage.vue
浏览文件 @
23ed5d5a
...
...
@@ -29,6 +29,7 @@
<el-col
:span=
"6"
style=
"text-align: right"
>
<el-button
type=
"primary"
size=
"small"
@
click=
"searchList"
>
查询
</el-button>
<el-button
type=
"default"
size=
"small"
@
click=
"resetForm"
style=
"margin-left:0;"
>
重置
</el-button>
<el-button
type=
"primary"
size=
"small"
@
click=
"exportOrder"
>
导出订单
</el-button>
</el-col>
</el-row>
</el-form>
...
...
@@ -238,6 +239,7 @@
// import { openLoading, closeLoading } from "../../utils/utils";
import
BreadCrumb
from
"@/components/breadcrumb.vue"
;
import
SendSetDialog
from
"@/components/shop/send-set-dialog"
;
import
{
getOrdersExportUrl
}
from
"@/utils/yqrange/yqrangeApi"
;
import
{
queryOrderList
,
updateExpress
,
refundApply
}
from
"@/utils/shop"
;
import
{
toDecimal2
}
from
'@/utils'
;
...
...
@@ -489,6 +491,17 @@
}
});
},
exportOrder
()
{
const
{
goodsName
,
orderNo
,
receiver
,
orderDate
,
storeId
}
=
this
.
searchForm
;
getOrdersExportUrl
({
goodsName
,
orderNo
,
receiver
,
orderDate
,
storeId
}).
then
(
res
=>
{
if
(
res
.
code
!=
'000000'
)
{
this
.
$message
({
message
:
res
.
message
,
type
:
'error'
});
return
;
}
window
.
open
(
res
.
data
);
});
}
},
filters
:
{
toFixed2
:
function
(
value
)
{
...
...
写
预览
Markdown
格式
0%
请重试
or
附加一个文件
附加文件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录