Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_web
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pseer
gxpt_web
Commits
bf6aa666
Commit
bf6aa666
authored
Mar 21, 2024
by
YG8999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
人工退款记录
parent
d124bd38
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
351 additions
and
0 deletions
+351
-0
artificial.js
src/api/system/artificial.js
+44
-0
index.vue
src/views/system/artificial/index.vue
+307
-0
No files found.
src/api/system/artificial.js
0 → 100644
View file @
bf6aa666
import
request
from
'@/utils/request'
// 查询订单人工退款记录列表
export
function
listArtificial
(
query
)
{
return
request
({
url
:
'/system/artificial/list'
,
method
:
'get'
,
params
:
query
})
}
// 查询订单人工退款记录详细
export
function
getArtificial
(
id
)
{
return
request
({
url
:
'/system/artificial/'
+
id
,
method
:
'get'
})
}
// 新增订单人工退款记录
export
function
addArtificial
(
data
)
{
return
request
({
url
:
'/system/artificial'
,
method
:
'post'
,
data
:
data
})
}
// 修改订单人工退款记录
export
function
updateArtificial
(
data
)
{
return
request
({
url
:
'/system/artificial'
,
method
:
'put'
,
data
:
data
})
}
// 删除订单人工退款记录
export
function
delArtificial
(
id
)
{
return
request
({
url
:
'/system/artificial/'
+
id
,
method
:
'delete'
})
}
src/views/system/artificial/index.vue
0 → 100644
View file @
bf6aa666
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"120px"
>
<el-form-item
label=
"订单号"
prop=
"orderNo"
>
<el-input
v-model=
"queryParams.orderNo"
placeholder=
"请输入退款订单号"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"是否使用优惠券"
prop=
"isCoupon"
>
<el-select
v-model=
"queryParams.isCoupon"
placeholder=
"请选择"
>
<el-option
v-for=
"item in options"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item
label=
"是否退优惠券"
prop=
"isRefundCoupon"
>
<el-select
v-model=
"queryParams.isRefundCoupon"
placeholder=
"请选择"
>
<el-option
v-for=
"item in options"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item
label=
"是否生成保洁"
prop=
"isClean"
>
<el-select
v-model=
"queryParams.isClean"
placeholder=
"请选择"
>
<el-option
v-for=
"item in options"
:key=
"item.value"
:label=
"item.label"
:value=
"item.value"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
icon=
"el-icon-search"
size=
"mini"
@
click=
"handleQuery"
>
搜索
</el-button>
<el-button
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<el-table
v-loading=
"loading"
:data=
"artificialList"
@
selection-change=
"handleSelectionChange"
>
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
-->
<!--
<el-table-column
label=
"主键"
align=
"center"
prop=
"id"
/>
-->
<el-table-column
label=
"退款订单号"
align=
"center"
prop=
"orderNo"
width=
"210px"
/>
<el-table-column
label=
"是否使用优惠券"
align=
"center"
prop=
"isCoupon"
:formatter=
"(row) => filedFormatter(row.isCoupon)"
/>
<el-table-column
label=
"订单支付金额(元)"
align=
"center"
prop=
"orderAmount"
/>
<el-table-column
label=
"订单退款金(元)"
align=
"center"
prop=
"refundAmount"
/>
<el-table-column
label=
"是否退优惠券"
align=
"center"
prop=
"isRefundCoupon"
:formatter=
"(row) => filedFormatter(row.isRefundCoupon)"
/>
<el-table-column
label=
"是否生成保洁"
align=
"center"
prop=
"isClean"
:formatter=
"(row) => filedFormatter(row.isClean)"
/>
<el-table-column
label=
"优惠券id"
align=
"center"
prop=
"couponId"
/>
<el-table-column
label=
"优惠券类型"
align=
"center"
prop=
"couponType"
>
<template
slot-scope=
"scope"
>
<dict-tag
:options=
"dict.type.store_coupon_type"
:value=
"scope.row.couponType"
/>
</
template
>
</el-table-column>
<el-table-column
label=
"退款时间"
align=
"center"
prop=
"createTime"
width=
"180"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
createTime
,
'{y
}
-{m
}
-{d
}
{h
}
:{i
}
:{s
}
'
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<!--
<
el
-
table
-
column
label
=
"备注"
align
=
"center"
prop
=
"remark"
/>-->
<!--
<
el
-
table
-
column
label
=
"操作"
align
=
"center"
class
-
name
=
"small-padding fixed-width"
>-->
<!--
<
template
slot
-
scope
=
"scope"
>-->
<!--
<
el
-
button
-->
<!--
size
=
"mini"
-->
<!--
type
=
"text"
-->
<!--
icon
=
"el-icon-edit"
-->
<!--
@
click
=
"handleUpdate(scope.row)"
-->
<!--
v
-
hasPermi
=
"['system:artificial:edit']"
-->
<!--
>
修改
<
/el-button>--
>
<!--
<
el
-
button
-->
<!--
size
=
"mini"
-->
<!--
type
=
"text"
-->
<!--
icon
=
"el-icon-delete"
-->
<!--
@
click
=
"handleDelete(scope.row)"
-->
<!--
v
-
hasPermi
=
"['system:artificial:remove']"
-->
<!--
>
删除
<
/el-button>--
>
<!--
<
/template>--
>
<!--
<
/el-table-column>--
>
<
/el-table
>
<
pagination
v
-
show
=
"total>0"
:
total
=
"total"
:
page
.
sync
=
"queryParams.pageNum"
:
limit
.
sync
=
"queryParams.pageSize"
@
pagination
=
"getList"
/>
<!--
添加或修改订单人工退款记录对话框
-->
<!--
<
el
-
dialog
:
title
=
"title"
:
visible
.
sync
=
"open"
width
=
"500px"
append
-
to
-
body
>-->
<!--
<
el
-
form
ref
=
"form"
:
model
=
"form"
:
rules
=
"rules"
label
-
width
=
"80px"
>-->
<!--
<
el
-
form
-
item
label
=
"退款订单号"
prop
=
"orderNo"
>-->
<!--
<
el
-
input
v
-
model
=
"form.orderNo"
placeholder
=
"请输入退款订单号"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"是否使用优惠券"
prop
=
"isCoupon"
>-->
<!--
<
el
-
input
v
-
model
=
"form.isCoupon"
placeholder
=
"请输入是否使用优惠券"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"优惠券id"
prop
=
"couponId"
>-->
<!--
<
el
-
input
v
-
model
=
"form.couponId"
placeholder
=
"请输入优惠券id"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"订单支付金额"
prop
=
"orderAmount"
>-->
<!--
<
el
-
input
v
-
model
=
"form.orderAmount"
placeholder
=
"请输入订单支付金额"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"订单退款金额"
prop
=
"refundAmount"
>-->
<!--
<
el
-
input
v
-
model
=
"form.refundAmount"
placeholder
=
"请输入订单退款金额"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"是否退优惠券"
prop
=
"isRefundCoupon"
>-->
<!--
<
el
-
input
v
-
model
=
"form.isRefundCoupon"
placeholder
=
"请输入是否退优惠券"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"是否生成保洁"
prop
=
"isClean"
>-->
<!--
<
el
-
input
v
-
model
=
"form.isClean"
placeholder
=
"请输入是否生成保洁"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
el
-
form
-
item
label
=
"备注"
prop
=
"remark"
>-->
<!--
<
el
-
input
v
-
model
=
"form.remark"
placeholder
=
"请输入备注"
/>-->
<!--
<
/el-form-item>--
>
<!--
<
/el-form>--
>
<!--
<
div
slot
=
"footer"
class
=
"dialog-footer"
>-->
<!--
<
el
-
button
type
=
"primary"
@
click
=
"submitForm"
>
确
定
<
/el-button>--
>
<!--
<
el
-
button
@
click
=
"cancel"
>
取
消
<
/el-button>--
>
<!--
<
/div>--
>
<!--
<
/el-dialog>--
>
<
/div
>
<
/template
>
<
script
>
import
{
listArtificial
,
getArtificial
,
delArtificial
,
addArtificial
,
updateArtificial
}
from
"@/api/system/artificial"
;
export
default
{
name
:
"Artificial"
,
dicts
:
[
'store_coupon_type'
],
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 订单人工退款记录表格数据
artificialList
:
[],
// 弹出层标题
title
:
""
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
orderNo
:
null
,
isCoupon
:
null
,
couponId
:
null
,
orderAmount
:
null
,
refundAmount
:
null
,
isRefundCoupon
:
null
,
isClean
:
null
,
couponType
:
null
,
}
,
// 表单参数
form
:
{
}
,
// 表单校验
rules
:
{
orderNo
:
[
{
required
:
true
,
message
:
"退款订单号不能为空"
,
trigger
:
"blur"
}
],
isCoupon
:
[
{
required
:
true
,
message
:
"是否使用优惠券不能为空"
,
trigger
:
"blur"
}
],
refundAmount
:
[
{
required
:
true
,
message
:
"订单退款金额不能为空"
,
trigger
:
"blur"
}
],
}
,
options
:
[{
value
:
'1'
,
label
:
'是'
}
,
{
value
:
'0'
,
label
:
'否'
}
]
}
;
}
,
created
()
{
this
.
getList
();
}
,
methods
:
{
/** 查询订单人工退款记录列表 */
getList
()
{
this
.
loading
=
true
;
listArtificial
(
this
.
queryParams
).
then
(
response
=>
{
this
.
artificialList
=
response
.
rows
;
this
.
total
=
response
.
total
;
this
.
loading
=
false
;
}
);
}
,
// 取消按钮
cancel
()
{
this
.
open
=
false
;
this
.
reset
();
}
,
// 表单重置
reset
()
{
this
.
form
=
{
id
:
null
,
orderNo
:
null
,
isCoupon
:
null
,
couponId
:
null
,
orderAmount
:
null
,
refundAmount
:
null
,
isRefundCoupon
:
null
,
isClean
:
null
,
couponType
:
null
,
createBy
:
null
,
createTime
:
null
,
updateBy
:
null
,
updateTime
:
null
,
remark
:
null
}
;
this
.
resetForm
(
"form"
);
}
,
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
;
this
.
getList
();
}
,
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
"queryForm"
);
this
.
handleQuery
();
}
,
// 多选框选中数据
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
id
)
this
.
single
=
selection
.
length
!==
1
this
.
multiple
=
!
selection
.
length
}
,
filedFormatter
(
value
)
{
return
value
===
1
?
'是'
:
'否'
;
}
,
// /** 新增按钮操作 */
// handleAdd()
{
// this.reset();
// this.open = true;
// this.title = "添加订单人工退款记录";
//
}
,
// /** 修改按钮操作 */
// handleUpdate(row)
{
// this.reset();
// const id = row.id || this.ids
// getArtificial(id).then(response =>
{
// this.form = response.data;
// this.open = true;
// this.title = "修改订单人工退款记录";
//
}
);
//
}
,
// /** 提交按钮 */
// submitForm()
{
// this.$refs["form"].validate(valid =>
{
// if (valid)
{
// if (this.form.id != null)
{
// updateArtificial(this.form).then(response =>
{
// this.$modal.msgSuccess("修改成功");
// this.open = false;
// this.getList();
//
}
);
//
}
else
{
// addArtificial(this.form).then(response =>
{
// this.$modal.msgSuccess("新增成功");
// this.open = false;
// this.getList();
//
}
);
//
}
//
}
//
}
);
//
}
,
// /** 删除按钮操作 */
// handleDelete(row)
{
// const ids = row.id || this.ids;
// this.$modal.confirm('是否确认删除订单人工退款记录编号为"' + ids + '"的数据项?').then(function()
{
// return delArtificial(ids);
//
}
).
then
(()
=>
{
// this.getList();
// this.$modal.msgSuccess("删除成功");
//
}
).
catch
(()
=>
{
}
);
//
}
,
// /** 导出按钮操作 */
// handleExport()
{
// this.download('system/artificial/export',
{
// ...this.queryParams
//
}
,
`artificial_${new Date().getTime()
}
.xlsx`
)
//
}
}
}
;
<
/script
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment