Remove isEnabled for model, adapter and enforcer, improve UI

This commit is contained in:
Yang Luo
2023-08-18 19:22:47 +08:00
parent a41f6880a2
commit abfc464155
11 changed files with 40 additions and 94 deletions

View File

@ -13,7 +13,7 @@
// limitations under the License.
import React from "react";
import {Button, Card, Col, Input, Row, Select, Switch} from "antd";
import {Button, Card, Col, Input, Row, Select} from "antd";
import * as ModelBackend from "./backend/ModelBackend";
import * as OrganizationBackend from "./backend/OrganizationBackend";
import * as Setting from "./Setting";
@ -161,16 +161,6 @@ class ModelEditPage extends React.Component {
</div>
</Col>
</Row>
<Row style={{marginTop: "20px"}} >
<Col style={{marginTop: "5px"}} span={(Setting.isMobile()) ? 19 : 2}>
{Setting.getLabel(i18next.t("general:Is enabled"), i18next.t("general:Is enabled - Tooltip"))} :
</Col>
<Col span={1} >
<Switch checked={this.state.model.isEnabled} onChange={checked => {
this.updateModelField("isEnabled", checked);
}} />
</Col>
</Row>
</Card>
);
}