|
@@ -67,7 +67,12 @@
|
|
|
@change="handleTableChange"
|
|
|
>
|
|
|
<template #bodyCell="{ column, record }">
|
|
|
- <template v-if="column.key === 'actions'">
|
|
|
+ <Flex v-if="column.key === 'nickname'" gap="small">
|
|
|
+ <WechatOutlined :style="{ fontSize: '20px', color: '#00BB29' }" />
|
|
|
+ <span>{{ record.nickname }}</span>
|
|
|
+ <Tag :color="record.status === 1 ? 'green' : 'red'">{{ record.status === 1 ? '在线' : '离线' }}</Tag>
|
|
|
+ </Flex>
|
|
|
+ <!-- <template v-else-if="column.key === 'actions'">
|
|
|
<Popconfirm
|
|
|
title="确定要设定发送人吗?"
|
|
|
@confirm="() => confirmSend(record.id)"
|
|
@@ -86,7 +91,7 @@
|
|
|
取消设置
|
|
|
</Button>
|
|
|
</Popconfirm>
|
|
|
- </template>
|
|
|
+ </template> -->
|
|
|
</template>
|
|
|
</Table>
|
|
|
</div>
|
|
@@ -114,7 +119,7 @@
|
|
|
import { useGo } from '/@/hooks/web/usePage';
|
|
|
import { PageEnum } from '@/enums/pageEnum';
|
|
|
import dayjs from 'dayjs';
|
|
|
- import { Form, Input, FormItem, Radio, Button, DatePicker, Modal, Alert, Table, Popconfirm, Spin,} from 'ant-design-vue';
|
|
|
+ import { Form, Input, FormItem, Radio, Button, DatePicker, Modal, Alert, Table, Popconfirm, Spin, Tag, Flex } from 'ant-design-vue';
|
|
|
import { useStore } from '../stores/index';
|
|
|
|
|
|
let stageList = ref([]);
|
|
@@ -149,30 +154,34 @@
|
|
|
current: 1,
|
|
|
});
|
|
|
|
|
|
- function handleSaveDraft() {
|
|
|
- console.log('点击草稿状态');
|
|
|
- go(PageEnum.SOP_LIST);
|
|
|
- }
|
|
|
- async function confirmSend(id) {
|
|
|
- if (!selectedRowKeys.value.includes(id)) {
|
|
|
- selectedRowKeys.value.push(id);
|
|
|
- }
|
|
|
- console.log('发送按钮', rowSelection, selectedRowKeys.value);
|
|
|
- }
|
|
|
+ // function handleSaveDraft() {
|
|
|
+ // console.log('点击草稿状态');
|
|
|
+ // go(PageEnum.SOP_LIST);
|
|
|
+ // }
|
|
|
+ // async function confirmSend(id) {
|
|
|
+ // if (!selectedRowKeys.value.includes(id)) {
|
|
|
+ // selectedRowKeys.value.push(id);
|
|
|
+ // }
|
|
|
+ // console.log('发送按钮', rowSelection, selectedRowKeys.value);
|
|
|
+ // }
|
|
|
|
|
|
- async function confirmCancel(id) {
|
|
|
- const index = selectedRowKeys.value.indexOf(id);
|
|
|
- if (index > -1) {
|
|
|
- selectedRowKeys.value.splice(index, 1);
|
|
|
- }
|
|
|
- console.log('取消按钮', rowSelection, selectedRowKeys.value);
|
|
|
- }
|
|
|
+ // async function confirmCancel(id) {
|
|
|
+ // const index = selectedRowKeys.value.indexOf(id);
|
|
|
+ // if (index > -1) {
|
|
|
+ // selectedRowKeys.value.splice(index, 1);
|
|
|
+ // }
|
|
|
+ // console.log('取消按钮', rowSelection, selectedRowKeys.value);
|
|
|
+ // }
|
|
|
|
|
|
let rowSelection = reactive({
|
|
|
selectedRowKeys: selectedRowKeys.value,
|
|
|
onChange: (newSelectedRowKeys) => {
|
|
|
selectedRowKeys.value = newSelectedRowKeys;
|
|
|
},
|
|
|
+ getCheckboxProps: (record) => ({
|
|
|
+ disabled: record.status === 0, // Column configuration not to be checked
|
|
|
+ // name: record.name,
|
|
|
+ })
|
|
|
});
|
|
|
|
|
|
watch(selectedRowKeys, (newVal) => {
|
|
@@ -223,32 +232,32 @@
|
|
|
title: '社交昵称',
|
|
|
dataIndex: 'nickname',
|
|
|
key: 'nickname',
|
|
|
- customRender: ({ record }) => {
|
|
|
- return h('span', [
|
|
|
- h(WechatOutlined, {
|
|
|
- style: { marginRight: '8px', fontSize: '20px', color: '#00BB29' },
|
|
|
- }), // 使用微信图标
|
|
|
- record.nickname,
|
|
|
- h(
|
|
|
- 'span',
|
|
|
- {
|
|
|
- style:
|
|
|
- 'margin-left: 8px; color: #13ce66;background-color: #e7faf0;display:inline-block;border:1px solid #d0f5e0;line-height:22px;padding: 0px 8px;border-radius: 4px;font-size: 12px;',
|
|
|
- },
|
|
|
- '在线',
|
|
|
- ),
|
|
|
- ]);
|
|
|
- },
|
|
|
+ // customRender: ({ record }) => {
|
|
|
+ // return h('span', [
|
|
|
+ // h(WechatOutlined, {
|
|
|
+ // style: { marginRight: '8px', fontSize: '20px', color: '#00BB29' },
|
|
|
+ // }), // 使用微信图标
|
|
|
+ // record.nickname,
|
|
|
+ // h(
|
|
|
+ // 'span',
|
|
|
+ // {
|
|
|
+ // style:
|
|
|
+ // 'margin-left: 8px; color: #13ce66;background-color: #e7faf0;display:inline-block;border:1px solid #d0f5e0;line-height:22px;padding: 0px 8px;border-radius: 4px;font-size: 12px;',
|
|
|
+ // },
|
|
|
+ // '在线',
|
|
|
+ // ),
|
|
|
+ // ]);
|
|
|
+ // },
|
|
|
},
|
|
|
{
|
|
|
title: '社交账号',
|
|
|
dataIndex: 'account',
|
|
|
key: 'account',
|
|
|
},
|
|
|
- {
|
|
|
- title: '操作',
|
|
|
- key: 'actions',
|
|
|
- },
|
|
|
+ // {
|
|
|
+ // title: '操作',
|
|
|
+ // key: 'actions',
|
|
|
+ // },
|
|
|
];
|
|
|
|
|
|
async function handlePublish() {
|
|
@@ -533,4 +542,4 @@
|
|
|
position: absolute;
|
|
|
left: 0;
|
|
|
}
|
|
|
-</style>
|
|
|
+</style>
|