fix: bug#11114、10540、10783
This commit is contained in:
parent
0bef99ca88
commit
0ea4214ee3
|
@ -6,6 +6,7 @@ export const getList_api = (data:object): any =>server.get(`/notifications/_quer
|
||||||
export const getListByUnRead_api = (data: object): any => server.post(`/notifications/_query`, data)
|
export const getListByUnRead_api = (data: object): any => server.post(`/notifications/_query`, data)
|
||||||
// 修改记录状态
|
// 修改记录状态
|
||||||
export const changeStatus_api = (type: '_read' | '_unread', data: string[]): any => server.post(`/notifications/${type}`, data)
|
export const changeStatus_api = (type: '_read' | '_unread', data: string[]): any => server.post(`/notifications/${type}`, data)
|
||||||
|
export const read = (id: string): any => server.get(`notifications/${id}/read`)
|
||||||
|
|
||||||
|
|
||||||
const encodeParams = (params: Record<string, any>) => {
|
const encodeParams = (params: Record<string, any>) => {
|
||||||
|
|
|
@ -57,7 +57,7 @@ const createChart = () => {
|
||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
const myChart = echarts.init(chartRef.value as HTMLElement);
|
const myChart = echarts.init(chartRef.value as HTMLElement);
|
||||||
const sData: number[] = props.chartData.map(
|
const sData: number[] = props.chartData.map(
|
||||||
(m: any) => m.value && m.value.toFixed(2),
|
(m: any) => m.value && m.value.toFixed(0),
|
||||||
);
|
);
|
||||||
const maxY = Math.max.apply(null, sData.length ? sData : [0]);
|
const maxY = Math.max.apply(null, sData.length ? sData : [0]);
|
||||||
const options = {
|
const options = {
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
<div class="tool-item">
|
<div class="tool-item">
|
||||||
<j-popconfirm
|
<j-popconfirm
|
||||||
title="重置将断开直播, 可能会影响其他播放者"
|
title="重置将断开直播, 可能会影响其他播放者"
|
||||||
@confirm="() => handleReset"
|
@confirm="handleReset"
|
||||||
>
|
>
|
||||||
重置
|
重置
|
||||||
</j-popconfirm>
|
</j-popconfirm>
|
||||||
|
|
|
@ -27,9 +27,19 @@
|
||||||
}"
|
}"
|
||||||
>
|
>
|
||||||
<template #headerTitle>
|
<template #headerTitle>
|
||||||
|
<j-space>
|
||||||
<j-button type="primary" @click="dialogVisible = true">
|
<j-button type="primary" @click="dialogVisible = true">
|
||||||
<AIcon type="PlusOutlined" />新增
|
<AIcon type="PlusOutlined" />新增
|
||||||
</j-button>
|
</j-button>
|
||||||
|
<PermissionButton
|
||||||
|
:popConfirm="{
|
||||||
|
title: `是否批量解除绑定`,
|
||||||
|
onConfirm: () => table.unbind(),
|
||||||
|
}"
|
||||||
|
>
|
||||||
|
<AIcon type="DisconnectOutlined" />批量解绑
|
||||||
|
</PermissionButton>
|
||||||
|
</j-space>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template #status="slotProps">
|
<template #status="slotProps">
|
||||||
|
@ -159,8 +169,13 @@ const table = {
|
||||||
return getUserByRole_api(params);
|
return getUserByRole_api(params);
|
||||||
},
|
},
|
||||||
// 批量解绑
|
// 批量解绑
|
||||||
unbind: (ids: string[] = []) => {
|
unbind: (ids?: string[]) => {
|
||||||
unbindUser_api(roleId, ids).then((resp) => {
|
const data = ids ? ids : selectedRowKeys.value;
|
||||||
|
if (!data.length) {
|
||||||
|
message.warning('请勾选数据');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
unbindUser_api(roleId, data).then((resp) => {
|
||||||
if (resp.status === 200) {
|
if (resp.status === 200) {
|
||||||
message.success('操作成功');
|
message.success('操作成功');
|
||||||
table.refresh();
|
table.refresh();
|
||||||
|
@ -170,6 +185,7 @@ const table = {
|
||||||
// 刷新表格
|
// 刷新表格
|
||||||
refresh: () => {
|
refresh: () => {
|
||||||
tableRef.value.reload();
|
tableRef.value.reload();
|
||||||
|
selectedRowKeys.value = [];
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue