fix: 修改搜索传参、弹窗按钮中文

This commit is contained in:
blp 2023-02-02 14:32:29 +08:00
parent ff87cb9b6d
commit af2136a033
8 changed files with 42 additions and 45 deletions

View File

@ -5,6 +5,8 @@
width="1100px" width="1100px"
:visible="true" :visible="true"
title="选择设备" title="选择设备"
okText="确定"
cancelText="取消"
@ok="handleOk" @ok="handleOk"
@cancel="handleCancel" @cancel="handleCancel"
:confirmLoading="btnLoading" :confirmLoading="btnLoading"
@ -12,8 +14,9 @@
<div style="margin-top: 10px"> <div style="margin-top: 10px">
<Search <Search
:columns="columns" :columns="columns"
target="iot-card-management-search" target="iot-card-bind-device"
@search="handleSearch" @search="handleSearch"
type="simple"
/> />
<JTable <JTable
ref="bindDeviceRef" ref="bindDeviceRef"
@ -121,9 +124,8 @@ const columns = [
}, },
]; ];
const handleSearch = (params: any) => { const handleSearch = (e: any) => {
console.log(params); params.value = e;
params.value = params;
}; };
const onSelectChange = (record: any) => { const onSelectChange = (record: any) => {

View File

@ -4,6 +4,8 @@
:maskClosable="false" :maskClosable="false"
:visible="true" :visible="true"
title="导出" title="导出"
okText="确定"
cancelText="取消"
@ok="handleOk" @ok="handleOk"
@cancel="handleCancel" @cancel="handleCancel"
> >

View File

@ -4,6 +4,8 @@
:maskClosable="false" :maskClosable="false"
:visible="true" :visible="true"
title="导入" title="导入"
okText="确定"
cancelText="取消"
@ok="handleCancel" @ok="handleCancel"
@cancel="handleCancel" @cancel="handleCancel"
> >

View File

@ -4,6 +4,8 @@
width="600px" width="600px"
:visible="true" :visible="true"
:title="type === 'add' ? '新增' : '编辑'" :title="type === 'add' ? '新增' : '编辑'"
okText="确定"
cancelText="取消"
@ok="handleOk" @ok="handleOk"
@cancel="handleCancel" @cancel="handleCancel"
:confirmLoading="btnLoading" :confirmLoading="btnLoading"

View File

@ -1,6 +1,6 @@
<!-- 物联卡管理 --> <!-- 物联卡管理 -->
<template> <template>
<page-container class="container"> <page-container>
<Search <Search
:columns="columns" :columns="columns"
target="iot-card-management-search" target="iot-card-management-search"
@ -124,10 +124,7 @@
</slot> </slot>
</template> </template>
<template #content> <template #content>
<h3 <h3 class="card-item-content-title">
class="card-item-content-title"
@click.stop="handleView(slotProps.id)"
>
{{ slotProps.id }} {{ slotProps.id }}
</h3> </h3>
<a-row> <a-row>
@ -553,6 +550,8 @@ const getActions = (
popConfirm: data.deviceId popConfirm: data.deviceId
? { ? {
title: '确认解绑设备?', title: '确认解绑设备?',
okText: '确定',
cancelText: '取消',
onConfirm: async () => { onConfirm: async () => {
unbind(data.id).then((resp: any) => { unbind(data.id).then((resp: any) => {
if (resp.status === 200) { if (resp.status === 200) {
@ -599,6 +598,8 @@ const getActions = (
: data.cardStateType?.value === 'deactivate' : data.cardStateType?.value === 'deactivate'
? '确认复机?' ? '确认复机?'
: '确认停用?', : '确认停用?',
okText: '确定',
cancelText: '取消',
onConfirm: async () => { onConfirm: async () => {
if (data.cardStateType?.value === 'toBeActivated') { if (data.cardStateType?.value === 'toBeActivated') {
changeDeploy(data.id).then((resp) => { changeDeploy(data.id).then((resp) => {
@ -633,6 +634,8 @@ const getActions = (
}, },
popConfirm: { popConfirm: {
title: '确认删除?', title: '确认删除?',
okText: '确定',
cancelText: '取消',
onConfirm: async () => { onConfirm: async () => {
const resp: any = await del(data.id); const resp: any = await del(data.id);
if (resp.status === 200) { if (resp.status === 200) {
@ -648,9 +651,8 @@ const getActions = (
]; ];
}; };
const handleSearch = (params: any) => { const handleSearch = (e: any) => {
console.log(params); params.value = e;
params.value = params;
}; };
const onSelectChange = (keys: string[], rows: []) => { const onSelectChange = (keys: string[], rows: []) => {
@ -671,13 +673,6 @@ const handleClick = (dt: any) => {
} }
}; };
/**
* 查看
*/
const handleView = (id: string) => {
message.warn(id + '暂未开发');
};
/** /**
* 新增 * 新增
*/ */
@ -792,25 +787,19 @@ const handelRemove = async () => {
</script> </script>
<style scoped lang="less"> <style scoped lang="less">
.container { .flow-text {
.search {
width: calc(100% - 330px);
}
.flow-text {
font-size: 20px; font-size: 20px;
font-weight: 600; font-weight: 600;
} }
.progress-text {
.progress-text {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
} }
:deep(.ant-progress-inner) { :deep(.ant-progress-inner) {
border-radius: 0px; border-radius: 0px;
} }
:deep(.ant-progress-bg) { :deep(.ant-progress-bg) {
border-radius: 0px; border-radius: 0px;
}
} }
</style> </style>

View File

@ -289,9 +289,8 @@ const getActions = (
]; ];
}; };
const handleSearch = (params: any) => { const handleSearch = (e: any) => {
console.log(params); params.value = e;
params.value = params;
}; };
/** /**

View File

@ -4,6 +4,8 @@
width="600px" width="600px"
:visible="true" :visible="true"
title="充值" title="充值"
okText="确定"
cancelText="取消"
@ok="handleOk" @ok="handleOk"
@cancel="handleCancel" @cancel="handleCancel"
:confirmLoading="btnLoading" :confirmLoading="btnLoading"

View File

@ -151,9 +151,8 @@ const getActions = (data: Partial<Record<string, any>>): ActionsType[] => {
]; ];
}; };
const handleSearch = (params: any) => { const handleSearch = (e: any) => {
console.log(params); params.value = e;
params.value = params;
}; };
/** /**