修改bug

This commit is contained in:
wangyilin 2024-09-24 15:20:05 +08:00
parent 7f4bfc710f
commit 376197bfa7
4 changed files with 37 additions and 27 deletions

View File

@ -54,5 +54,4 @@ export default defineAppConfig({
}, },
] ]
} }
}) })

View File

@ -2,12 +2,12 @@ import {createApp} from 'vue'
import App from '@/App.vue' import App from '@/App.vue'
import '@/reset.css' import '@/reset.css'
import './index.css' import './index.css'
// iconfont css
import "@/assets/iconfont/iconfont.css";
// 公共样式 // 公共样式
import '@/assets/scss/common.scss' import '@/assets/scss/common.scss'
import '@/assets/scss/myAntD.scss' import '@/assets/scss/myAntD.scss'
// iconfont css
import "@/assets/iconfont/iconfont.css";
// vue Router // vue Router
import router from "@/router"; import router from "@/router";
// pinia stores // pinia stores

View File

@ -126,17 +126,17 @@ const columns: TableProps['columns'] = [
dataIndex:'isRecruitSecurity', dataIndex:'isRecruitSecurity',
title: '是否自招保安', title: '是否自招保安',
customRender: ({text}) => <a-tag>{text?.label}</a-tag>, customRender: ({text}) => <a-tag>{text?.label}</a-tag>,
width:100 width:120
}, },
{ {
dataIndex:'idNumber', dataIndex:'idNumber',
title: '件号', title: '保安服务许可证',
width:170 width:170
}, },
{ {
dataIndex:'serviceArea', dataIndex:'serviceArea',
title:'服务区域面积', title:'服务区域面积',
width:100 width:120
}, },
{ {
dataIndex:'buildingTotal', dataIndex:'buildingTotal',
@ -151,17 +151,17 @@ const columns: TableProps['columns'] = [
{ {
dataIndex:'staffTotal', dataIndex:'staffTotal',
title:'工作人员数量', title:'工作人员数量',
width:100 width:120
}, },
{ {
dataIndex:'securityUserTotal', dataIndex:'securityUserTotal',
title:'保安人员数量', title:'保安人员数量',
width:100 width:120
}, },
{ {
dataIndex:'createUserName', dataIndex:'createUserName',
title:'创建人名称', title:'创建人名称',
width:100 width:110
}, },
{ {
dataIndex: 'createTime', dataIndex: 'createTime',
@ -190,7 +190,7 @@ const columns: TableProps['columns'] = [
message.success(resp.message) message.success(resp.message)
await tableRef.value?.requestGetTableData() await tableRef.value?.requestGetTableData()
}}> }}>
<a-button type="primary" danger>删除</a-button> <a-button danger>删除</a-button>
</a-popconfirm> </a-popconfirm>
<a-button type="primary" onClick={ async ()=>{ <a-button type="primary" onClick={ async ()=>{
// console.log(record) // console.log(record)
@ -275,6 +275,7 @@ const formItemOptions = ref<FormProMaxItemOptions<serviceProjectSaveOrUpdatePara
enterprisesUnitId:{ enterprisesUnitId:{
type:'select', type:'select',
label:'企事业单位', label:'企事业单位',
required: true,
options:enterprisesUnitIdList, options:enterprisesUnitIdList,
componentsProps:{ componentsProps:{
allowClear:true, allowClear:true,
@ -316,7 +317,7 @@ const formItemOptions = ref<FormProMaxItemOptions<serviceProjectSaveOrUpdatePara
}, },
idNumber: { idNumber: {
type: 'input', type: 'input',
label: '件号', label: '保安服务许可证',
componentsProps:{ componentsProps:{
disabled:idNumberDisabled as any disabled:idNumberDisabled as any
} }

View File

@ -96,21 +96,31 @@ const columns: TableProps['columns'] = [
</a-popconfirm> </a-popconfirm>
</a-space> </a-space>
} }
return <a-space > return (
<a-button record.isEnable.value === 0?<a-button
type="primary" danger
className={record.isEnable.value === 0 ? 'btn-danger' : 'btn-success'} onClick={async () => {
onClick={async () => { const resp = await api.post('/management/disableOrEnableMiniProgramUser', {
const resp = await api.post('/management/disableOrEnableMiniProgramUser', { dataId: record.snowFlakeId,
dataId: record.snowFlakeId, unitOptType: UNIT_TYPE.security
unitOptType: UNIT_TYPE.security })
}) message.success(resp.message)
message.success(resp.message) await tableRef.value?.requestGetTableData()
await tableRef.value?.requestGetTableData() }}
}} >{record.isEnable.value === 0 ? '禁用' : '启用'}
>{record.isEnable.value === 0 ? '禁用' : '启用'} </a-button>:<a-button
</a-button> type="primary"
</a-space> onClick={async () => {
const resp = await api.post('/management/disableOrEnableMiniProgramUser', {
dataId: record.snowFlakeId,
unitOptType: UNIT_TYPE.security
})
message.success(resp.message)
await tableRef.value?.requestGetTableData()
}}
>{record.isEnable.value === 0 ? '禁用' : '启用'}
</a-button>
)
} }
}, },
] ]