init
This commit is contained in:
53
src/api/cai/userCall.js
Normal file
53
src/api/cai/userCall.js
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
// 查询通话记录列表
|
||||||
|
export function listUserCall(query) {
|
||||||
|
return request({
|
||||||
|
url: '/cai/userCall/list',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查询通话记录详细
|
||||||
|
export function getUserCall(id) {
|
||||||
|
return request({
|
||||||
|
url: '/cai/userCall/' + id,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getUserCallByTraceId(traceId) {
|
||||||
|
return request({
|
||||||
|
url: '/cai/userCall/trace',
|
||||||
|
method: 'get',
|
||||||
|
params: {traceId:traceId}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// 新增通话记录
|
||||||
|
export function addUserCall(data) {
|
||||||
|
return request({
|
||||||
|
url: '/cai/userCall',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 修改通话记录
|
||||||
|
export function updateUserCall(data) {
|
||||||
|
return request({
|
||||||
|
url: '/cai/userCall',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除通话记录
|
||||||
|
export function delUserCall(id) {
|
||||||
|
return request({
|
||||||
|
url: '/cai/userCall/' + id,
|
||||||
|
method: 'delete'
|
||||||
|
})
|
||||||
|
}
|
||||||
@@ -197,6 +197,11 @@ export const accountTypeList = [
|
|||||||
]
|
]
|
||||||
// 0=文本消息,1=图片消息,2=语音消息,3=视频消息,4=发送地理位置消息,6=发送文件消息,10=发送提示消息,100=发送第三方自定义消息
|
// 0=文本消息,1=图片消息,2=语音消息,3=视频消息,4=发送地理位置消息,6=发送文件消息,10=发送提示消息,100=发送第三方自定义消息
|
||||||
|
|
||||||
|
export const deleteFlagList = [
|
||||||
|
{ value: 0, label: '正常',listClass: listClass.primary},
|
||||||
|
{ value: 1, label: '删除',listClass: listClass.danger},
|
||||||
|
]
|
||||||
|
|
||||||
export const imTypeList = [
|
export const imTypeList = [
|
||||||
{ value: 0, label: '文本消息'},
|
{ value: 0, label: '文本消息'},
|
||||||
{ value: 1, label: '图片消息'},
|
{ value: 1, label: '图片消息'},
|
||||||
@@ -207,3 +212,15 @@ export const imTypeList = [
|
|||||||
{ value: 10, label: '发送提示消息'},
|
{ value: 10, label: '发送提示消息'},
|
||||||
{ value: 100, label: '发送第三方自定义消息'},
|
{ value: 100, label: '发送第三方自定义消息'},
|
||||||
]
|
]
|
||||||
|
|
||||||
|
export const userCallStatusList = [
|
||||||
|
{ value: 0, label: '创建通话', listClass: listClass.info},
|
||||||
|
{ value: 1, label: '呼叫方连接上', listClass: listClass.info},
|
||||||
|
{ value: 2, label: '呼叫方取消通话', listClass: listClass.warning},
|
||||||
|
{ value: 3, label: '接收方连接上', listClass: listClass.info},
|
||||||
|
{ value: 4, label: '收到通话未接听', listClass: listClass.warning},
|
||||||
|
{ value: 5, label: '超时未接听', listClass: listClass.warning},
|
||||||
|
{ value: 6, label: '接收方已拒绝', listClass: listClass.danger},
|
||||||
|
{ value: 7, label: '已接听', listClass: listClass.primary},
|
||||||
|
{ value: 8, label: '通话结束', listClass: listClass.primary},
|
||||||
|
]
|
||||||
|
|||||||
@@ -139,7 +139,7 @@ export default {
|
|||||||
handleInfo(row){
|
handleInfo(row){
|
||||||
this.accountChangeInfoVisible = true
|
this.accountChangeInfoVisible = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.accountChangeInfo.init(row.id)
|
this.$refs.accountChangeInfo.init(row.userId)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
/** 查询用户账户列表 */
|
/** 查询用户账户列表 */
|
||||||
|
|||||||
@@ -91,6 +91,7 @@
|
|||||||
<recharge-order-info v-if="rechargeOrderInfoVisible" ref="rechargeOrderInfo" />
|
<recharge-order-info v-if="rechargeOrderInfoVisible" ref="rechargeOrderInfo" />
|
||||||
<user-gift-info v-if="userGiftInfoVisible" ref="userGiftInfo" />
|
<user-gift-info v-if="userGiftInfoVisible" ref="userGiftInfo" />
|
||||||
<guard-log-info v-if="guardLogInfoVisible" ref="guardLogInfo"/>
|
<guard-log-info v-if="guardLogInfoVisible" ref="guardLogInfo"/>
|
||||||
|
<user-call-info v-if="userCallInfoVisible" ref="userCallInfo" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -100,15 +101,17 @@ import {accountTypeList, yesOrNoList} from "@/constant/statusMap";
|
|||||||
import RechargeOrderInfo from "@/views/cai/rechargeOrder/recharge-order-info";
|
import RechargeOrderInfo from "@/views/cai/rechargeOrder/recharge-order-info";
|
||||||
import UserGiftInfo from "@/views/cai/userGift/user-gift-info";
|
import UserGiftInfo from "@/views/cai/userGift/user-gift-info";
|
||||||
import GuardLogInfo from "@/views/cai/guardLog/guard-log-info";
|
import GuardLogInfo from "@/views/cai/guardLog/guard-log-info";
|
||||||
|
import UserCallInfo from "@/views/cai/userCall/user-call-info";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "AccountChangeLog",
|
name: "AccountChangeLog",
|
||||||
components: {
|
components: {
|
||||||
RechargeOrderInfo,UserGiftInfo,GuardLogInfo
|
RechargeOrderInfo,UserGiftInfo,GuardLogInfo,UserCallInfo
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
accountTypeList,yesOrNoList,
|
accountTypeList,yesOrNoList,
|
||||||
|
userCallInfoVisible: false,
|
||||||
rechargeOrderInfoVisible: false,
|
rechargeOrderInfoVisible: false,
|
||||||
userGiftInfoVisible: false,
|
userGiftInfoVisible: false,
|
||||||
guardLogInfoVisible: false,
|
guardLogInfoVisible: false,
|
||||||
@@ -192,14 +195,20 @@ export default {
|
|||||||
})
|
})
|
||||||
break;
|
break;
|
||||||
case "VIDEO":
|
case "VIDEO":
|
||||||
|
this.userCallInfoVisible = true
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.userCallInfo.traceIdInit(row.traceId)
|
||||||
|
})
|
||||||
break;
|
break;
|
||||||
case "WITHDRAW":
|
case "WITHDRAW":
|
||||||
/*this.rechargeOrderInfoVisible = true
|
/*this.rechargeOrderInfoVisible = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.rechargeOrderInfo.traceIdInit(row.traceId)
|
this.$refs.rechargeOrderInfo.traceIdInit(row.traceId)
|
||||||
})*/
|
})*/
|
||||||
|
this.$modal.msgWarning("无关联记录");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
this.$modal.msgSuccess("无关联记录");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
229
src/views/cai/userCall/index.vue
Normal file
229
src/views/cai/userCall/index.vue
Normal file
@@ -0,0 +1,229 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
|
||||||
|
<el-form-item label="房间号" prop="id">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.id"
|
||||||
|
placeholder="请输入房间号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="拨打方蜜瓜号" prop="fromUsercode">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.usercode"
|
||||||
|
placeholder="请输入拨打方蜜瓜号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="接收方蜜瓜号" prop="toUsercode">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.mobile"
|
||||||
|
placeholder="请输入接收方蜜瓜号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="状态" prop="status">
|
||||||
|
<el-select v-model="queryParams.status" placeholder="状态" clearable size="small">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in userCallStatusList"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="链路号" prop="traceId">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.traceId"
|
||||||
|
placeholder="请输入链路号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</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-row :gutter="10" class="mb8">
|
||||||
|
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" :data="userCallList" @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">
|
||||||
|
<el-table-column label="蜜瓜号" align="center" prop="fromUsercode" />
|
||||||
|
<el-table-column label="手机号" align="center" prop="fromMobile" width="120" />
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="接收方" align="center">
|
||||||
|
<el-table-column label="蜜瓜号" align="center" prop="fromUsercode" />
|
||||||
|
<el-table-column label="头像" align="center" prop="fromAvatar">
|
||||||
|
<template v-slot="scope">
|
||||||
|
<image-avatar :src="scope.row.fromAvatar"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="状态" align="center" prop="status" width="120">
|
||||||
|
<template v-slot="scope">
|
||||||
|
<cai-dict-tag :options="userCallStatusList" :value="scope.row.status"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="开始时间" align="center" prop="beginTime" width="160"/>
|
||||||
|
<el-table-column label="结束时间" align="center" prop="endTime" width="160" />
|
||||||
|
<el-table-column label="通话时长" align="center" prop="callTime" :formatter="callTimeFormatter"/>
|
||||||
|
<el-table-column label="单价" align="center" prop="callPrice" />
|
||||||
|
<el-table-column label="金额" align="center" prop="callAmount" />
|
||||||
|
<el-table-column label="删除状态" align="center" prop="deleteFlag" >
|
||||||
|
<template v-slot="scope">
|
||||||
|
<cai-dict-tag :options="deleteFlagList" :value="scope.row.deleteFlag"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="链路号" align="center" prop="traceId" show-overflow-tooltip/>
|
||||||
|
<el-table-column label="创建时间" align="center" prop="createTime" width="160" />
|
||||||
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="140" fixed="right">
|
||||||
|
<template v-slot="scope">
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-info"
|
||||||
|
@click="handleInfo(scope.row)"
|
||||||
|
>详情</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-info"
|
||||||
|
v-if="scope.row.traceId"
|
||||||
|
@click="handleConsumerLog(scope.row)"
|
||||||
|
>分销
|
||||||
|
</el-button>
|
||||||
|
<!-- <el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-edit"
|
||||||
|
@click="handleUpdate(scope.row)"
|
||||||
|
v-hasPermi="['cai:userCall:edit']"
|
||||||
|
>修改</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"
|
||||||
|
/>
|
||||||
|
<consume-log-info v-if="consumeLogInfoVisible" ref="consumeLogInfo" />
|
||||||
|
<user-call-info v-if="userCallInfoVisible" ref="userCallInfo" />
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {listUserCall} from "@/api/cai/userCall";
|
||||||
|
import ConsumeLogInfo from "@/views/cai/consumeLog/consume-log-info";
|
||||||
|
import UserCallInfo from "@/views/cai/userCall/user-call-info";
|
||||||
|
import {deleteFlagList, userCallStatusList} from "@/constant/statusMap";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "UserCall",
|
||||||
|
components:{
|
||||||
|
ConsumeLogInfo,UserCallInfo
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
userCallStatusList,deleteFlagList,
|
||||||
|
consumeLogInfoVisible: false,
|
||||||
|
userCallInfoVisible: false,
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 通话记录表格数据
|
||||||
|
userCallList: [],
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
id: undefined,
|
||||||
|
fromUsercode: undefined,
|
||||||
|
toUsercode: undefined,
|
||||||
|
status: undefined,
|
||||||
|
deleteFlag: undefined,
|
||||||
|
},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
|
||||||
|
callTimeFormatter(row,column){
|
||||||
|
let callTime = row.callTime;
|
||||||
|
if(!callTime){
|
||||||
|
return "00:00:00"
|
||||||
|
}
|
||||||
|
const hour = parseInt(callTime / 3600) % 24;
|
||||||
|
const minute = parseInt((callTime % 3600) / 60);
|
||||||
|
const second = callTime % 60;
|
||||||
|
return [hour, minute, second].map(function(item) {
|
||||||
|
return item < 10 ? '0' + item : item;
|
||||||
|
}).join(':');
|
||||||
|
},
|
||||||
|
/** 查询通话记录列表 */
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
listUserCall(this.queryParams).then(response => {
|
||||||
|
this.userCallList = response.rows;
|
||||||
|
this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
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
|
||||||
|
},
|
||||||
|
handleConsumerLog(row) {
|
||||||
|
this.consumeLogInfoVisible = true
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.consumeLogInfo.traceIdInit(row.traceId)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
handleInfo(row){
|
||||||
|
this.userCallInfoVisible = true
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.userCallInfo.init(row.id)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
/** 修改按钮操作 */
|
||||||
|
handleUpdate(row) {
|
||||||
|
},
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
135
src/views/cai/userCall/user-call-info.vue
Normal file
135
src/views/cai/userCall/user-call-info.vue
Normal file
@@ -0,0 +1,135 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog title="通话记录详情" :close-on-click-modal="false" :visible.sync="open" width="1200px" append-to-body>
|
||||||
|
<el-descriptions :contentStyle="CS" :label-style="LS " class="margin-top" :column="3" size="medium" border>
|
||||||
|
<el-descriptions-item label="房间号">
|
||||||
|
{{info.id}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="状态">
|
||||||
|
<cai-dict-tag :options="userCallStatusList" :value="info.status"/>
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="删除状态">
|
||||||
|
<cai-dict-tag :options="deleteFlagList" :value="info.deleteFlag"/>
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="拨打方ID">
|
||||||
|
{{info.fromUid}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="拨打方蜜瓜号">
|
||||||
|
{{info.fromUsercode}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="拨打方头像">
|
||||||
|
<image-avatar :src="info.fromAvatar"/>
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="接收方ID">
|
||||||
|
{{info.toUid}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="接收方蜜瓜号">
|
||||||
|
{{info.toUsercode}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="接收方头像">
|
||||||
|
<image-avatar :src="info.toAvatar"/>
|
||||||
|
</el-descriptions-item>
|
||||||
|
|
||||||
|
<el-descriptions-item label="创建时间">
|
||||||
|
{{info.createTime}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="开始时间">
|
||||||
|
{{info.beginTime}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="结束时间">
|
||||||
|
{{info.endTime}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
|
||||||
|
<el-descriptions-item label="通话时长">
|
||||||
|
{{callTimeFormatter(info.callTime)}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="通话单价">
|
||||||
|
{{info.callPrice}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="通话金额">
|
||||||
|
{{info.callAmount}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
|
||||||
|
<el-descriptions-item label="客户对女神的评分">
|
||||||
|
{{info.callScore}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="女神对客户的评分">
|
||||||
|
{{info.userScore}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="链路号">
|
||||||
|
{{info.traceId}}
|
||||||
|
</el-descriptions-item>
|
||||||
|
</el-descriptions>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {deleteFlagList, userCallStatusList} from '@/constant/statusMap'
|
||||||
|
import {getUserCall, getUserCallByTraceId} from "@/api/cai/userCall";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "UserInfo",
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
userCallStatusList,deleteFlagList,
|
||||||
|
CS: {
|
||||||
|
'text-align': 'center', //文本居中
|
||||||
|
'min-width': '250px', //最小宽度
|
||||||
|
'word-break': 'break-all' //过长时自动换行
|
||||||
|
},
|
||||||
|
LS: {
|
||||||
|
// 'color': '#000',
|
||||||
|
'text-align': 'center',
|
||||||
|
// 'font-weight': '600',
|
||||||
|
'height': '40px',
|
||||||
|
// 'background-color': 'rgba(255, 97, 2, 0.1)',
|
||||||
|
'min-width': '110px',
|
||||||
|
'word-break': 'keep-all'
|
||||||
|
},
|
||||||
|
open:false,
|
||||||
|
info:{},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
init(id){
|
||||||
|
this.open = true;
|
||||||
|
getUserCall(id).then(response => {
|
||||||
|
this.info = response.data;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
traceIdInit(traceId){
|
||||||
|
this.open = true;
|
||||||
|
getUserCallByTraceId(traceId).then(response => {
|
||||||
|
this.info = response.data;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
callTimeFormatter(callTime){
|
||||||
|
if(!callTime){
|
||||||
|
return "00:00:00"
|
||||||
|
}
|
||||||
|
const hour = parseInt(callTime / 3600) % 24;
|
||||||
|
const minute = parseInt((callTime % 3600) / 60);
|
||||||
|
const second = callTime % 60;
|
||||||
|
return [hour, minute, second].map(function(item) {
|
||||||
|
return item < 10 ? '0' + item : item;
|
||||||
|
}).join(':');
|
||||||
|
},
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.el-row {
|
||||||
|
margin-bottom: -15px;
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap
|
||||||
|
}
|
||||||
|
|
||||||
|
/* .el-card {
|
||||||
|
min-width: 100%;
|
||||||
|
height: 80%; // 高度要设置百分比才可以
|
||||||
|
margin-right: 20px;
|
||||||
|
transition: all .5s;
|
||||||
|
}*/
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user