mirror of https://github.com/openspug/spug
fix issues
parent
502557c95a
commit
5f828b30ad
|
@ -45,7 +45,7 @@ class TaskIndex extends React.Component {
|
||||||
<Form layout="vertical">
|
<Form layout="vertical">
|
||||||
<Form.Item required label="目标主机">
|
<Form.Item required label="目标主机">
|
||||||
{store.host_ids.length > 0 && (
|
{store.host_ids.length > 0 && (
|
||||||
<Alert style={{width: 200}} type="info" message={`已选择 ${store.host_ids.length} 台`}/>
|
<Alert style={{width: 200}} type="info" message={`已选择 ${store.host_ids.length} 台主机`}/>
|
||||||
)}
|
)}
|
||||||
</Form.Item>
|
</Form.Item>
|
||||||
<Button
|
<Button
|
||||||
|
|
|
@ -2,6 +2,7 @@ import React, { useEffect, useState } from 'react';
|
||||||
import { observer } from 'mobx-react';
|
import { observer } from 'mobx-react';
|
||||||
import { Modal, Row, Col, Tree, Table, Button, Alert } from 'antd';
|
import { Modal, Row, Col, Tree, Table, Button, Alert } from 'antd';
|
||||||
import store from './store';
|
import store from './store';
|
||||||
|
import styles from './index.module.less';
|
||||||
|
|
||||||
export default observer(function (props) {
|
export default observer(function (props) {
|
||||||
const [loading, setLoading] = useState(false);
|
const [loading, setLoading] = useState(false);
|
||||||
|
@ -65,6 +66,7 @@ export default observer(function (props) {
|
||||||
<Modal
|
<Modal
|
||||||
visible={[undefined, true].includes(props.visible)}
|
visible={[undefined, true].includes(props.visible)}
|
||||||
width={1000}
|
width={1000}
|
||||||
|
className={styles.selector}
|
||||||
title={props.title || '主机列表'}
|
title={props.title || '主机列表'}
|
||||||
onOk={handleSubmit}
|
onOk={handleSubmit}
|
||||||
confirmLoading={loading}
|
confirmLoading={loading}
|
||||||
|
@ -88,6 +90,8 @@ export default observer(function (props) {
|
||||||
<Table
|
<Table
|
||||||
rowKey="id"
|
rowKey="id"
|
||||||
dataSource={dataSource}
|
dataSource={dataSource}
|
||||||
|
pagination={false}
|
||||||
|
scroll={{y: 480}}
|
||||||
onRow={record => {
|
onRow={record => {
|
||||||
return {
|
return {
|
||||||
onClick: () => handleClickRow(record)
|
onClick: () => handleClickRow(record)
|
||||||
|
|
|
@ -24,4 +24,8 @@
|
||||||
:global(.ant-descriptions-item-content) {
|
:global(.ant-descriptions-item-content) {
|
||||||
padding: 4px 16px !important;
|
padding: 4px 16px !important;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.selector :global(.ant-modal-footer) {
|
||||||
|
border-top: none
|
||||||
}
|
}
|
|
@ -4,7 +4,7 @@
|
||||||
* Released under the AGPL-3.0 License.
|
* Released under the AGPL-3.0 License.
|
||||||
*/
|
*/
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { Drawer, Breadcrumb, Table, Divider, Switch, Button, Progress, Modal, message } from 'antd';
|
import { Drawer, Breadcrumb, Table, Switch, Progress, Modal, message } from 'antd';
|
||||||
import {
|
import {
|
||||||
DeleteOutlined,
|
DeleteOutlined,
|
||||||
DownloadOutlined,
|
DownloadOutlined,
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
*/
|
*/
|
||||||
import React, { useEffect, useState } from 'react';
|
import React, { useEffect, useState } from 'react';
|
||||||
import { observer } from 'mobx-react';
|
import { observer } from 'mobx-react';
|
||||||
import { Tabs, Tree, Button, Spin } from 'antd';
|
import { Tabs, Tree, Spin } from 'antd';
|
||||||
import { FolderOutlined, FolderOpenOutlined, CloudServerOutlined } from '@ant-design/icons';
|
import { FolderOutlined, FolderOpenOutlined, CloudServerOutlined } from '@ant-design/icons';
|
||||||
import { NotFound, AuthButton } from 'components';
|
import { NotFound, AuthButton } from 'components';
|
||||||
import Terminal from './Terminal';
|
import Terminal from './Terminal';
|
||||||
|
|
Loading…
Reference in New Issue