edit
This commit is contained in:
parent
fcf256ea16
commit
adcf52bbac
|
@ -74,6 +74,12 @@ export function merchantDeleteApi(id) {
|
||||||
export function merchantDeleteForm(id) {
|
export function merchantDeleteForm(id) {
|
||||||
return request.get(`system/merchant/delete/${id}/form`)
|
return request.get(`system/merchant/delete/${id}/form`)
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* @description 商户列表 -- 缴费(表单)
|
||||||
|
*/
|
||||||
|
export function merchantPayForm(id) {
|
||||||
|
return request.get(`margin/offline_money/${id}/form`)
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* @description 商户列表 -- 修改开启状态
|
* @description 商户列表 -- 修改开启状态
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -166,13 +166,14 @@ export function cancelOrderStatusFilter(status) {
|
||||||
|
|
||||||
export function orderPayType(type) {
|
export function orderPayType(type) {
|
||||||
const typeMap = {
|
const typeMap = {
|
||||||
'0': '余额支付',
|
'0': '消费券支付',
|
||||||
'1': '微信支付',
|
'1': '微信支付',
|
||||||
'2': '小程序',
|
'2': '小程序',
|
||||||
'3': '微信支付',
|
'3': '微信支付',
|
||||||
'4': '支付宝',
|
'4': '支付宝',
|
||||||
'5': '支付宝扫码',
|
'5': '支付宝扫码',
|
||||||
'6': '微信扫码'
|
'6': '微信扫码',
|
||||||
|
'7': '铸源星支付'
|
||||||
}
|
}
|
||||||
return typeMap[type]
|
return typeMap[type]
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,31 @@ export function parseTime(time, cFormat) {
|
||||||
})
|
})
|
||||||
return time_str
|
return time_str
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* @param {json} json
|
||||||
|
* @returns {string}
|
||||||
|
*/
|
||||||
|
export function syntaxHighlight(json) {
|
||||||
|
if (typeof json != 'string') {
|
||||||
|
json = JSON.stringify(json, undefined, 2);
|
||||||
|
}
|
||||||
|
json = json.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>');
|
||||||
|
return json.replace(/("(\\u[a-zA-Z0-9]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)/g, function (match) {
|
||||||
|
var cls = 'number';
|
||||||
|
if (/^"/.test(match)) {
|
||||||
|
if (/:$/.test(match)) {
|
||||||
|
cls = 'key';
|
||||||
|
} else {
|
||||||
|
cls = 'string';
|
||||||
|
}
|
||||||
|
} else if (/true|false/.test(match)) {
|
||||||
|
cls = 'boolean';
|
||||||
|
} else if (/null/.test(match)) {
|
||||||
|
cls = 'null';
|
||||||
|
}
|
||||||
|
return '<span class="' + cls + '">' + match + '</span>';
|
||||||
|
});
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* @param {number} time
|
* @param {number} time
|
||||||
* @param {string} option
|
* @param {string} option
|
||||||
|
|
|
@ -236,6 +236,7 @@
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
<span v-if="merData.is_margin != 0">
|
<span v-if="merData.is_margin != 0">
|
||||||
<el-input
|
<el-input
|
||||||
|
:disabled="true"
|
||||||
v-model="merData.margin"
|
v-model="merData.margin"
|
||||||
placeholder="请填写保证金"
|
placeholder="请填写保证金"
|
||||||
style="width:120px;margin-left: 8px;"
|
style="width:120px;margin-left: 8px;"
|
||||||
|
@ -260,6 +261,7 @@
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
<span v-if="merData.is_service != 0">
|
<span v-if="merData.is_service != 0">
|
||||||
<el-input
|
<el-input
|
||||||
|
:disabled="true"
|
||||||
v-model="merData.service_cost"
|
v-model="merData.service_cost"
|
||||||
placeholder="请填写技术服务费"
|
placeholder="请填写技术服务费"
|
||||||
style="width:120px;margin-left: 8px;"
|
style="width:120px;margin-left: 8px;"
|
||||||
|
@ -284,6 +286,7 @@
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
<span v-if="merData.is_goods != 0">
|
<span v-if="merData.is_goods != 0">
|
||||||
<el-input
|
<el-input
|
||||||
|
:disabled="true"
|
||||||
v-model="merData.goods_cost"
|
v-model="merData.goods_cost"
|
||||||
placeholder="请填写上架费"
|
placeholder="请填写上架费"
|
||||||
style="width:120px;margin-left: 8px;"
|
style="width:120px;margin-left: 8px;"
|
||||||
|
|
|
@ -201,7 +201,7 @@
|
||||||
<el-table-column prop="sort" label="排序" min-width="100" />
|
<el-table-column prop="sort" label="排序" min-width="100" />
|
||||||
<el-table-column prop="mark" label="备注" min-width="200" />
|
<el-table-column prop="mark" label="备注" min-width="200" />
|
||||||
|
|
||||||
<el-table-column label="操作" min-width="150" fixed="right">
|
<el-table-column label="操作" min-width="180" fixed="right">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="tableFrom.status === '1'"
|
v-if="tableFrom.status === '1'"
|
||||||
|
@ -210,6 +210,7 @@
|
||||||
@click="onLogo(scope.row.mer_id)"
|
@click="onLogo(scope.row.mer_id)"
|
||||||
>登录</el-button>
|
>登录</el-button>
|
||||||
<el-button type="text" size="small" @click="onEdit(scope.row.mer_id)">编辑</el-button>
|
<el-button type="text" size="small" @click="onEdit(scope.row.mer_id)">编辑</el-button>
|
||||||
|
<el-button type="text" size="small" @click="setPayment(scope.row.mer_id)">缴费</el-button>
|
||||||
<el-button type="text" size="small" @click="onDetails(scope.row.mer_id)">详情</el-button>
|
<el-button type="text" size="small" @click="onDetails(scope.row.mer_id)">详情</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="tableFrom.status === '0'"
|
v-if="tableFrom.status === '0'"
|
||||||
|
@ -259,6 +260,7 @@ import {
|
||||||
merchantCountApi,
|
merchantCountApi,
|
||||||
merchantIsCloseApi,
|
merchantIsCloseApi,
|
||||||
getstoreTypeApi,
|
getstoreTypeApi,
|
||||||
|
merchantPayForm,
|
||||||
getMerCateApi, marginDeductionForm
|
getMerCateApi, marginDeductionForm
|
||||||
} from "@/api/merchant";
|
} from "@/api/merchant";
|
||||||
import merDetail from './handle/merDetails.vue';
|
import merDetail from './handle/merDetails.vue';
|
||||||
|
@ -460,6 +462,10 @@ export default {
|
||||||
closeDrawer() {
|
closeDrawer() {
|
||||||
this.drawer = false;
|
this.drawer = false;
|
||||||
},
|
},
|
||||||
|
// 缴费
|
||||||
|
setPayment(id){
|
||||||
|
this.$modalForm(merchantPayForm(id)).then(() => this.getList(""));
|
||||||
|
},
|
||||||
// 删除
|
// 删除
|
||||||
handleDelete(id) {
|
handleDelete(id) {
|
||||||
this.$modalForm(merchantDeleteForm(id)).then(() => this.getList(""));
|
this.$modalForm(merchantDeleteForm(id)).then(() => this.getList(""));
|
||||||
|
|
|
@ -105,9 +105,10 @@
|
||||||
class="selWidth"
|
class="selWidth"
|
||||||
@change="getList(1),getCardList()"
|
@change="getList(1),getCardList()"
|
||||||
>
|
>
|
||||||
<el-option label="余额" value="0" />
|
<el-option label="消费券" value="0" />
|
||||||
<el-option label="微信" value="1" />
|
<el-option label="微信" value="1" />
|
||||||
<el-option label="支付宝" value="2" />
|
<el-option label="支付宝" value="2" />
|
||||||
|
<el-option label="铸源星" value="7" />
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="发货方式:" prop="filter_delivery">
|
<el-form-item label="发货方式:" prop="filter_delivery">
|
||||||
|
@ -280,7 +281,7 @@
|
||||||
<p v-if="scope.row.finalOrder">尾款:{{ scope.row.finalOrder.pay_price }}</p>
|
<p v-if="scope.row.finalOrder">尾款:{{ scope.row.finalOrder.pay_price }}</p>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="支付类型" min-width="80">
|
<el-table-column label="支付方式" min-width="80">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span v-if="scope.row.paid === 1">{{ scope.row.pay_type | orderPayType }}</span>
|
<span v-if="scope.row.paid === 1">{{ scope.row.pay_type | orderPayType }}</span>
|
||||||
<span v-else>--</span>
|
<span v-else>--</span>
|
||||||
|
|
|
@ -66,6 +66,20 @@
|
||||||
clearable
|
clearable
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="支付方式:" prop="pay_type">
|
||||||
|
<el-select
|
||||||
|
v-model="tableFrom.pay_type"
|
||||||
|
clearable
|
||||||
|
placeholder="请选择"
|
||||||
|
class="selWidth"
|
||||||
|
@change="getList(1)"
|
||||||
|
>
|
||||||
|
<el-option label="消费券" value="0" />
|
||||||
|
<el-option label="微信" value="1" />
|
||||||
|
<el-option label="支付宝" value="2" />
|
||||||
|
<el-option label="铸源星" value="7" />
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" size="small" @click="getList(1)">搜索</el-button>
|
<el-button type="primary" size="small" @click="getList(1)">搜索</el-button>
|
||||||
<el-button size="small" @click="searchReset()">重置</el-button>
|
<el-button size="small" @click="searchReset()">重置</el-button>
|
||||||
|
@ -117,6 +131,12 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="refund_price" label="退款金额" min-width="130" />
|
<el-table-column prop="refund_price" label="退款金额" min-width="130" />
|
||||||
|
<el-table-column label="支付方式" min-width="80">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span v-if="scope.row.paid === 1">{{ scope.row.pay_type | orderPayType }}</span>
|
||||||
|
<span v-else>--</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="nickname" label="商品信息" min-width="330">
|
<el-table-column prop="nickname" label="商品信息" min-width="330">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<div
|
<div
|
||||||
|
@ -139,6 +159,7 @@
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column prop="serviceScore" label="订单状态" min-width="250">
|
<el-table-column prop="serviceScore" label="订单状态" min-width="250">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span style="display: block">{{ scope.row.status | orderRefundFilter }}</span>
|
<span style="display: block">{{ scope.row.status | orderRefundFilter }}</span>
|
||||||
|
@ -229,7 +250,8 @@ export default {
|
||||||
date: "",
|
date: "",
|
||||||
page: 1,
|
page: 1,
|
||||||
limit: 20,
|
limit: 20,
|
||||||
is_trader: ''
|
is_trader: '',
|
||||||
|
pay_type:''
|
||||||
},
|
},
|
||||||
orderChartType: {},
|
orderChartType: {},
|
||||||
timeVal: [],
|
timeVal: [],
|
||||||
|
|
|
@ -5,6 +5,15 @@
|
||||||
<el-form-item label="管理员ID:" prop="admin_id">
|
<el-form-item label="管理员ID:" prop="admin_id">
|
||||||
<el-input v-model="tableFrom.admin_id" placeholder="请输入" class="selWidth" @keyup.enter.native="getList(1)" />
|
<el-input v-model="tableFrom.admin_id" placeholder="请输入" class="selWidth" @keyup.enter.native="getList(1)" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="权限名称:" prop="menu_name">
|
||||||
|
<el-input v-model="tableFrom.menu_name" placeholder="请输入" class="selWidth" @keyup.enter.native="getList(1)" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="请求:" prop="route">
|
||||||
|
<el-input v-model="tableFrom.route" placeholder="请输入" class="selWidth" @keyup.enter.native="getList(1)" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="关键字:" prop="route">
|
||||||
|
<el-input v-model="tableFrom.keyword" placeholder="请输入" class="selWidth" @keyup.enter.native="getList(1)" />
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="请求方式:" prop="method">
|
<el-form-item label="请求方式:" prop="method">
|
||||||
<el-select v-model="tableFrom.method" placeholder="请选择" clearable class="selWidth">
|
<el-select v-model="tableFrom.method" placeholder="请选择" clearable class="selWidth">
|
||||||
<el-option v-for="item in importanceOptions" :key="item" :label="item" :value="item" />
|
<el-option v-for="item in importanceOptions" :key="item" :label="item" :value="item" />
|
||||||
|
@ -76,6 +85,11 @@
|
||||||
label="操作时间"
|
label="操作时间"
|
||||||
min-width="120"
|
min-width="120"
|
||||||
/>
|
/>
|
||||||
|
<el-table-column label="操作" min-width="60" fixed="right">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button type="text" size="small" @click="onDetails(scope.row)">详情</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<div class="block">
|
<div class="block">
|
||||||
<el-pagination
|
<el-pagination
|
||||||
|
@ -89,12 +103,25 @@
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
<el-dialog
|
||||||
|
title="详情"
|
||||||
|
:visible.sync="dialogVisible"
|
||||||
|
width="50%"
|
||||||
|
top="4vh"
|
||||||
|
>
|
||||||
|
<pre v-html="preInfo"></pre>
|
||||||
|
<span slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="dialogVisible = false">取 消</el-button>
|
||||||
|
<el-button type="primary" @click="dialogVisible = false">确 定</el-button>
|
||||||
|
</span>
|
||||||
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import { adminLogApi } from '@/api/setting'
|
import { adminLogApi } from '@/api/setting'
|
||||||
|
import { syntaxHighlight } from '@/utils/index'
|
||||||
export default {
|
export default {
|
||||||
name: 'SystemLog',
|
name: 'SystemLog',
|
||||||
data() {
|
data() {
|
||||||
|
@ -105,15 +132,20 @@ export default {
|
||||||
data: [],
|
data: [],
|
||||||
total: 0
|
total: 0
|
||||||
},
|
},
|
||||||
|
dialogVisible: false,
|
||||||
timeVal: [],
|
timeVal: [],
|
||||||
section_time: [],
|
section_time: [],
|
||||||
importanceOptions: ['POST', 'DELETE'],
|
importanceOptions: ['POST', 'DELETE'],
|
||||||
|
preInfo:'',
|
||||||
tableFrom: {
|
tableFrom: {
|
||||||
page: 1,
|
page: 1,
|
||||||
limit: 20,
|
limit: 20,
|
||||||
admin_id: '',
|
admin_id: '',
|
||||||
method: '',
|
method: '',
|
||||||
date: ''
|
date: '',
|
||||||
|
menu_name:'',
|
||||||
|
route:'',
|
||||||
|
keyword:''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -150,6 +182,14 @@ export default {
|
||||||
this.tableFrom.limit = val
|
this.tableFrom.limit = val
|
||||||
this.getList(1)
|
this.getList(1)
|
||||||
},
|
},
|
||||||
|
// 详情
|
||||||
|
onDetails(row){
|
||||||
|
this.dialogVisible = true
|
||||||
|
console.log(Object.keys(JSON.parse(row.input)).length)
|
||||||
|
|
||||||
|
let info = Object.keys(JSON.parse(row.input)).length?syntaxHighlight(JSON.parse(row.input)):'无'
|
||||||
|
this.preInfo = info
|
||||||
|
},
|
||||||
onChange(e) {
|
onChange(e) {
|
||||||
if (e == null) {
|
if (e == null) {
|
||||||
this.tableFrom.section_startTime = ''
|
this.tableFrom.section_startTime = ''
|
||||||
|
|
Loading…
Reference in New Issue