소스 검색

fix: #8589 修复设备 子设备批量解绑未勾选提示

jackhoo_98 3 년 전
부모
커밋
c26189d087
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      src/pages/device/Instance/Detail/ChildDevice/index.tsx

+ 1 - 0
src/pages/device/Instance/Detail/ChildDevice/index.tsx

@@ -231,6 +231,7 @@ const ChildDevice = (props: Props) => {
               <Popconfirm
                 key="unbind"
                 onConfirm={async () => {
+                  if (bindKeys.length === 0) return onlyMessage('请先勾选数据!', 'error');
                   const resp = await service.unbindBatchDevice(InstanceModel.detail.id!, bindKeys);
                   if (resp.status === 200) {
                     onlyMessage('操作成功!');