feat: 调整内层页面交互

develop2
donghao 1 year ago
parent be7474ac77
commit d6014aa998

@ -12,12 +12,6 @@
background-color: transparent; background-color: transparent;
padding-inline: 0 !important; padding-inline: 0 !important;
} }
.app_page_wrap .page_menu .ant-menu {
background-image: url(../public/home/menu_footer_bg.png);
background-repeat: no-repeat;
background-position: left bottom;
background-size: cover;
}
.app_page_wrap .page_body { .app_page_wrap .page_body {
width: calc(100vw - 200px); width: calc(100vw - 200px);
} }

@ -12,17 +12,6 @@
background-color: transparent; background-color: transparent;
padding-inline: 0 !important; padding-inline: 0 !important;
} }
.page_menu {
// menu_footer_bg.png
.ant-menu {
// background-color: red;
background-image: url(../public/home/menu_footer_bg.png);
background-repeat: no-repeat;
background-position: left bottom;
background-size: cover;
}
}
.page_body { .page_body {
width: calc(100vw - 200px); width: calc(100vw - 200px);
.body_nav_bar { .body_nav_bar {

@ -275,12 +275,12 @@
} }
/* 表单组件 */ /* 表单组件 */
.gn_form .ant-radio-button-wrapper { .gn_form .ant-radio-button-wrapper {
height: 28px;
margin-right: 12px; margin-right: 12px;
border-radius: 4px;
border-inline-start-width: 1px;
color: #666666; color: #666666;
height: 28px;
line-height: 26px; line-height: 26px;
border-radius: 4px;
border-inline-start-width: 1px;
} }
.gn_form .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled):hover::before { .gn_form .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled):hover::before {
background-color: transparent; background-color: transparent;
@ -297,10 +297,66 @@
background-color: transparent; background-color: transparent;
} }
.gn_form .ant-radio-button-checked { .gn_form .ant-radio-button-checked {
border-radius: 4px;
color: #ffffff; color: #ffffff;
background: #154ddd; background: #154ddd;
border-radius: 4px;
} }
.gn_form .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) { .gn_form .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) {
color: #ffffff; color: #ffffff;
} }
/* 树控件 */
.gn_tree_wrap .tree_node_item {
color: #333333;
}
/* tab控件 */
.gn_tabs.ant-tabs .ant-tabs-tab {
color: #666666;
}
/* ProTable ProList */
.gn_pro_table .ant-table-wrapper .ant-table-thead > tr > th,
.gn_pro_table .ant-table-wrapper .ant-table-thead > tr > td {
background: rgba(21, 77, 221, 0.1);
}
.gn_pro_table .ant-btn-link.ant-btn-dangerous,
.gn_pro_table .ant-btn-default.ant-btn-dangerous {
color: #f15d53;
}
.gn_pro_table .ant-btn-default.ant-btn-dangerous {
border-color: #f15d53;
}
.gn_pro_table .ant-table-cell .ant-btn.ant-btn-sm {
padding: 0;
}
.gn_pro_table .ant-pro-table-list-toolbar-container {
padding: 0;
}
.gn_pro_table .ant-table-wrapper .ant-table,
.gn_pro_table .ant-table-wrapper .ant-table-thead > tr > th {
color: #333333;
}
.gn_pro_table .ant-pro-table-alert {
background-color: rgba(21, 77, 221, 0.1);
border-radius: 4px;
margin-block-end: 12px;
}
.gn_pro_table .ant-pro-table-alert :where(.css-dev-only-do-not-override-1y19ift).ant-pro-table-alert-info {
color: #333333;
}
.gn_pro_list .ant-pro-checkcard {
background: transparent;
border: none !important;
}
.gn_pro_list .ant-pro-checkcard-content {
padding-inline: 0;
padding-block: 0;
}
/* 弹窗 modal */
.ant-modal .ant-modal-header {
background: transparent;
}
.ant-modal .ant-modal-content {
background: linear-gradient(to bottom, transparent 0%, white 100px, white 100%), /* 底部白色背景 */ linear-gradient(to left, #fff 0%, #ccdbff 40%, /* 第一个从左到右的渐变 */ #fff 40%, #dbe6ff 45%, /* 第二个从左到右的渐变 */ #fff 45%, #e0e9ff 68%, /* 第三个从左到右的渐变 */ #e0e9ff 68%, #e0e9ff 100%);
}
.ant-modal .ant-pro-card {
background: transparent;
}

@ -12,6 +12,8 @@
@gray_color_3: #e0e0e0; // 用于分割线色值 @gray_color_3: #e0e0e0; // 用于分割线色值
@primary_bg_color: #f5f5f5; // 主题背景色 @primary_bg_color: #f5f5f5; // 主题背景色
@shallow_primary_1: rgba(21, 77, 221, 0.1);
/* 颜色 */ /* 颜色 */
.text_color_0 { .text_color_0 {
color: #000000; color: #000000;
@ -171,6 +173,7 @@
.ant-form-item { .ant-form-item {
.ant-form-item-label > label { .ant-form-item-label > label {
color: @text_color_1; color: @text_color_1;
// font-weight: bold;
} }
.ant-input-affix-wrapper { .ant-input-affix-wrapper {
color: @text_color_1; color: @text_color_1;
@ -361,3 +364,92 @@
color: #ffffff; color: #ffffff;
} }
} }
/* 树控件 */
.gn_tree_wrap {
.tree_node_item {
color: @text_color_1;
}
}
/* tab控件 */
.gn_tabs {
&.ant-tabs .ant-tabs-tab {
color: @text_color_2;
}
}
/* ProTable ProList */
.gn_pro_table {
.ant-table-wrapper .ant-table-thead > tr > th,
.ant-table-wrapper .ant-table-thead > tr > td {
background: @shallow_primary_1;
}
.ant-btn-link.ant-btn-dangerous,
.ant-btn-default.ant-btn-dangerous {
color: @active_color_2;
}
.ant-btn-default.ant-btn-dangerous {
border-color: @active_color_2;
}
// 小尺寸按钮,统一间距 (列表操作栏位按钮)
.ant-table-cell .ant-btn.ant-btn-sm {
padding: 0;
}
// 筛选栏
.ant-pro-table-list-toolbar-container {
padding: 0;
}
.ant-table-wrapper .ant-table,
.ant-table-wrapper .ant-table-thead > tr > th {
color: @text_color_1;
}
.ant-pro-table-alert {
background-color: @shallow_primary_1;
border-radius: 4px;
margin-block-end: 12px;
:where(.css-dev-only-do-not-override-1y19ift).ant-pro-table-alert-info {
color: @text_color_1;
}
}
}
.gn_pro_list {
.ant-pro-checkcard {
background: transparent;
border: none !important;
}
.ant-pro-checkcard-content {
padding-inline: 0;
padding-block: 0;
}
}
/* 弹窗 modal */
.ant-modal {
// background: white;
.ant-modal-header {
background: transparent;
}
.ant-modal-content {
background: linear-gradient(to bottom, transparent 0%, white 100px, white 100%),
/* 底部白色背景 */
linear-gradient(
to left,
#fff 0%,
#ccdbff 40%,
/* 第一个从左到右的渐变 */ #fff 40%,
#dbe6ff 45%,
/* 第二个从左到右的渐变 */ #fff 45%,
#e0e9ff 68%,
/* 第三个从左到右的渐变 */ #e0e9ff 68%,
#e0e9ff 100%
)
// /* 第二个从左到右的渐变 */ linear-gradient(to right, white, gray) 0 80% / 100% 20%,
// /* 第三个从左到右的渐变 */ linear-gradient(to right, orange, brown) 0 100% / 100% 20%;;
}
.ant-pro-card {
background: transparent;
}
}

@ -12,6 +12,9 @@
height: 100vh; height: 100vh;
padding: 0; padding: 0;
background-color: @menubar_ThemeColor; background-color: @menubar_ThemeColor;
background-image: url(../../../public/home/menu_footer_bg.png);
background-repeat: no-repeat;
background-position: left bottom;
border-radius: 0px 0px 32px 0px; border-radius: 0px 0px 32px 0px;
// border-radius: 12px; // border-radius: 12px;
// box-shadow: 4px 0px 24px 0px rgba(0, 63, 143, 0.3); // box-shadow: 4px 0px 24px 0px rgba(0, 63, 143, 0.3);

@ -2,12 +2,12 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-03-27 16:03:20 * @Date: 2024-03-27 16:03:20
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-10 17:46:32 * @LastEditTime: 2024-05-15 15:41:57
* @FilePath: \general-ai-manage\src\components\Header\index.tsx * @FilePath: \general-ai-manage\src\components\Header\index.tsx
* @Description: layout * @Description: layout
*/ */
import { useBusinessInfo } from '@/hooks/useBusinessInfo'; import { useBusinessInfo } from '@/hooks/useBusinessInfo';
import { history, useIntl } from '@umijs/max'; import { FormattedMessage, history } from '@umijs/max';
import { ReactComponent as BusinessLogoIcon } from '/public/home/business_logo.svg'; import { ReactComponent as BusinessLogoIcon } from '/public/home/business_logo.svg';
import type { MenuProps } from 'antd'; import type { MenuProps } from 'antd';
@ -24,7 +24,6 @@ export type MenuBarProps = {
}; };
const MenuBar: React.FC<MenuBarProps> = ({ menuData, changeMenu }) => { const MenuBar: React.FC<MenuBarProps> = ({ menuData, changeMenu }) => {
const intl = useIntl();
const { getStoreBusinessInfo } = useBusinessInfo(); const { getStoreBusinessInfo } = useBusinessInfo();
const [selectedMenu, setSelectedMenu] = useState([]); const [selectedMenu, setSelectedMenu] = useState([]);
@ -133,7 +132,7 @@ const MenuBar: React.FC<MenuBarProps> = ({ menuData, changeMenu }) => {
> >
<i className={`pl-[24px] pr-[12px] iconfont ${menuItem.menuIcon}`}></i> <i className={`pl-[24px] pr-[12px] iconfont ${menuItem.menuIcon}`}></i>
<div> <div>
{intl.formatMessage({ id: `menu.${menuItem.name}`, defaultMessage: '菜单' })} <FormattedMessage id={`menu.${menuItem.name}`} defaultMessage="菜单" />
</div> </div>
</li> </li>
))} ))}

@ -19,6 +19,9 @@
box-shadow: none; box-shadow: none;
/* 去掉聚焦时的阴影效果 */ /* 去掉聚焦时的阴影效果 */
} }
.base_tree_wrap .ant-tree .ant-tree-switcher .ant-tree-switcher-icon {
font-size: 12px;
}
.base_tree_wrap .tree_node_1 { .base_tree_wrap .tree_node_1 {
width: 100%; width: 100%;
margin: 12px 0; margin: 12px 0;
@ -35,6 +38,7 @@
} }
.base_tree_wrap .tree_node_1:hover, .base_tree_wrap .tree_node_1:hover,
.base_tree_wrap .ant-tree-treenode-selected { .base_tree_wrap .ant-tree-treenode-selected {
font-weight: bold;
color: #154ddd; color: #154ddd;
background: rgba(21, 77, 221, 0.1); background: rgba(21, 77, 221, 0.1);
border-radius: 8px; border-radius: 8px;

@ -16,6 +16,9 @@
box-shadow: none; /* 去掉聚焦时的阴影效果 */ box-shadow: none; /* 去掉聚焦时的阴影效果 */
} }
} }
.ant-tree .ant-tree-switcher .ant-tree-switcher-icon {
font-size: 12px;
}
.tree_node_1 { .tree_node_1 {
width: 100%; width: 100%;
@ -36,6 +39,7 @@
.tree_node_1:hover, .tree_node_1:hover,
.ant-tree-treenode-selected { .ant-tree-treenode-selected {
color: #154ddd; color: #154ddd;
font-weight: bold;
background: rgba(21, 77, 221, 0.1); background: rgba(21, 77, 221, 0.1);
border-radius: 8px; border-radius: 8px;
} }

@ -1,5 +1,5 @@
import { formatTreeValByKey } from '@/utils/baseTree'; import { formatTreeValByKey } from '@/utils/baseTree';
import { DeleteFilled, SearchOutlined } from '@ant-design/icons'; import { SearchOutlined } from '@ant-design/icons';
import { Button, Form, Input, Modal, Tree } from 'antd'; import { Button, Form, Input, Modal, Tree } from 'antd';
import _debounce from 'lodash/debounce'; import _debounce from 'lodash/debounce';
import React, { useEffect, useState } from 'react'; import React, { useEffect, useState } from 'react';
@ -171,7 +171,8 @@ const BaseTree: React.FC<BaseTreeProps> = (props) => {
props.handleDelete(node); props.handleDelete(node);
}} }}
> >
<DeleteFilled /> <i className="iconfont icon-delete text_active_2"></i>
{/* <DeleteFilled /> */}
</span> </span>
) : ( ) : (
<></> <></>
@ -186,7 +187,7 @@ const BaseTree: React.FC<BaseTreeProps> = (props) => {
}, [props.treeData]); }, [props.treeData]);
return ( return (
<div className="base_tree_wrap"> <div className="base_tree_wrap gn_tree_wrap">
{!props?.hideInSearch ? ( {!props?.hideInSearch ? (
<ProForm className="tree_search_form" submitter={false}> <ProForm className="tree_search_form" submitter={false}>
<ProFormText <ProFormText
@ -206,23 +207,25 @@ const BaseTree: React.FC<BaseTreeProps> = (props) => {
) : ( ) : (
<></> <></>
)} )}
<Tree <div style={{ maxHeight: 'calc(100vh - 210px)', overflowY: 'auto', overflowX: 'hidden' }}>
defaultExpandAll <Tree
onSelect={(selectedKeys, info) => { defaultExpandAll
console.log('selected', selectedKeys); onSelect={(selectedKeys, info) => {
props.selectTree(selectedKeys, info); console.log('selected', selectedKeys);
}} props.selectTree(selectedKeys, info);
titleRender={(node) => { }}
if (node.title) { titleRender={(node) => {
return renderTreeItem(node); if (node.title) {
} return renderTreeItem(node);
return renderAddAction(node); }
}} return renderAddAction(node);
{...defaultProps} }}
> {...defaultProps}
{renderTreeNodes(currTreeData)} >
</Tree> {renderTreeNodes(currTreeData)}
<div className="tree_node_1">{renderAddAction()}</div> </Tree>
<div className="tree_node_1">{renderAddAction()}</div>
</div>
{/* <div onClick={handleAddNode}>添加一级节点</div> */} {/* <div onClick={handleAddNode}>添加一级节点</div> */}
{/* TODO 使用ProForm */} {/* TODO 使用ProForm */}

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-26 11:11:05 * @Date: 2024-04-26 11:11:05
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-04-29 16:26:05 * @LastEditTime: 2024-05-15 14:12:06
* @FilePath: \general-ai-manage\src\components\Tree\src\deviceGroupTree.tsx * @FilePath: \general-ai-manage\src\components\Tree\src\deviceGroupTree.tsx
* @Description: * @Description:
* @ * @
@ -52,7 +52,7 @@ const DeviceGroupTree: React.FC<DeviceGroupTreeProps> = (props) => {
key={node?.key || 'add'} key={node?.key || 'add'}
> >
<PlusCircleOutlined /> <PlusCircleOutlined />
<span className="pl-[10px]"> {node?.key ? '添加子节点' : '添加节点'} </span> <span className="pl-[8px]"> {node?.key ? '添加子节点' : '添加节点'} </span>
</div> </div>
); );
}} }}

@ -183,32 +183,6 @@ ol {
background: url('../public/home/business_arrow.svg') no-repeat; background: url('../public/home/business_arrow.svg') no-repeat;
background-size: cover; background-size: cover;
} }
/* ProTable ProList */
.gn_pro_table .ant-table-wrapper .ant-table-thead > tr > th,
.gn_pro_table .ant-table-wrapper .ant-table-thead > tr > td {
background: rgba(21, 77, 221, 0.1);
}
.gn_pro_table .ant-btn-link.ant-btn-dangerous,
.gn_pro_table .ant-btn-default.ant-btn-dangerous {
color: #e80d0d;
}
.gn_pro_table .ant-btn-default.ant-btn-dangerous {
border-color: #e80d0d;
}
.gn_pro_table .ant-table-cell .ant-btn.ant-btn-sm {
padding: 0;
}
.gn_pro_table .ant-pro-table-list-toolbar-container {
padding: 0;
}
.gn_pro_list .ant-pro-checkcard {
background: transparent;
border: none !important;
}
.gn_pro_list .ant-pro-checkcard-content {
padding-inline: 0;
padding-block: 0;
}
/* 主题样式 */ /* 主题样式 */
.ant-btn-primary, .ant-btn-primary,
.ant-btn-primary:not(:disabled):not(.ant-btn-disabled):hover { .ant-btn-primary:not(:disabled):not(.ant-btn-disabled):hover {

@ -226,41 +226,6 @@ ol {
} }
} }
/* ProTable ProList */
.gn_pro_table {
.ant-table-wrapper .ant-table-thead > tr > th,
.ant-table-wrapper .ant-table-thead > tr > td {
background: rgba(21, 77, 221, 0.1);
}
.ant-btn-link.ant-btn-dangerous,
.ant-btn-default.ant-btn-dangerous {
color: #e80d0d;
}
.ant-btn-default.ant-btn-dangerous {
border-color: #e80d0d;
}
// 小尺寸按钮,统一间距 (列表操作栏位按钮)
.ant-table-cell .ant-btn.ant-btn-sm {
padding: 0;
}
// 筛选栏
.ant-pro-table-list-toolbar-container {
padding: 0;
}
}
.gn_pro_list {
.ant-pro-checkcard {
background: transparent;
border: none !important;
}
.ant-pro-checkcard-content {
padding-inline: 0;
padding-block: 0;
}
}
/* 主题样式 */ /* 主题样式 */
.ant-btn-primary, .ant-btn-primary,
.ant-btn-primary:not(:disabled):not(.ant-btn-disabled):hover { .ant-btn-primary:not(:disabled):not(.ant-btn-disabled):hover {

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-01 11:20:09 * @Date: 2024-04-01 11:20:09
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-07 14:54:37 * @LastEditTime: 2024-05-15 16:02:24
* @FilePath: \uighur-recognition-web2\src\locales\zh-CN\menu.ts * @FilePath: \uighur-recognition-web2\src\locales\zh-CN\menu.ts
* @Description: ,`customMade`, koroFileHeader : https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: ,`customMade`, koroFileHeader : https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
@ -66,4 +66,12 @@ export default {
'menu.business-model-index': '业务模型', 'menu.business-model-index': '业务模型',
'menu.business-server-state': '服务器状态', 'menu.business-server-state': '服务器状态',
'menu.business-device-state': '设备状态', 'menu.business-device-state': '设备状态',
// 'home-business-project': '企业项目',
// 'model-index': '模型管理',
// 'model-runtime-lib': '模型运行库',
// 'business-info-index': '企业信息',
// 'business-device-group': '节点设置',
// 'business-model-index': '业务模型',
// 'business-server-state': '服务器状态',
// 'business-device-state': '设备状态',
}; };

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-10 17:21:34 * @Date: 2024-04-10 17:21:34
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-14 16:40:35 * @LastEditTime: 2024-05-14 17:05:30
* @FilePath: \general-ai-manage\src\locales\zh-CN\model.ts * @FilePath: \general-ai-manage\src\locales\zh-CN\model.ts
* @Description: * @Description:
*/ */
@ -33,8 +33,6 @@ export const model_index: { [key: string]: string } = {
'model_index.create.form.rule.required.industry': '请选择行业分类', 'model_index.create.form.rule.required.industry': '请选择行业分类',
'model_index.create.form.remark': '备注', 'model_index.create.form.remark': '备注',
'model_index.create.form.rule.required.remark': '请填写备注', 'model_index.create.form.rule.required.remark': '请填写备注',
// 'model_detail.version.table.list.action.defaultVersion': '设为默认'
}; };
// 模型运行库 // 模型运行库
export const model_runtimeLib: { [key: string]: string } = { export const model_runtimeLib: { [key: string]: string } = {
@ -77,7 +75,6 @@ export const model_version: { [key: string]: string } = {
'model_detail.version.form.required.name': '请填写版本号', 'model_detail.version.form.required.name': '请填写版本号',
'model_detail.version.form.remark': '备注', 'model_detail.version.form.remark': '备注',
'model_detail.version.list.table.form.rule.required.name': '请填写版本号', 'model_detail.version.list.table.form.rule.required.name': '请填写版本号',
'model_detail.version.table.list.tag.defaultVersion': '默认版本', 'model_detail.version.table.list.tag.defaultVersion': '默认版本',
'model_detail.version.table.list.title': '版本列表', 'model_detail.version.table.list.title': '版本列表',
'model_detail.version.table.list.action.add': '新建版本信息', 'model_detail.version.table.list.action.add': '新建版本信息',
@ -135,69 +132,3 @@ export const base_model: { [key: string]: string } = {
'base_model.form.remark': '备注', 'base_model.form.remark': '备注',
'base_model.list.table.form.rule.required.name': '请填写版本号', 'base_model.list.table.form.rule.required.name': '请填写版本号',
}; };
export const server_state: { [key: string]: string } = {
'server_state.table.list.name': '服务器名称',
'server_state.table.list.userName': '用户名',
'server_state.table.list.ip': 'IP',
'server_state.table.list.pwd': '密码',
'server_state.table.list.defaultPort': '默认端口',
'server_state.table.list.parameter': '服务器参数',
'server_state.table.list.publicKeyString': '公钥字符串',
'server_state.table.list.connectivityTesting': '连通性测试',
'server_state.table.list.isEnable': '是否启用',
'server_state.table.list.remark': '备注',
'server_state.table.list.createTime': '创建时间',
'server_state.table.list.updateTime': '更新时间',
'server_state.table.rule.required.modelFkId': '模型为必填项',
'server_state.table.rule.required.path': '模型地址为必填项',
'server_state.table.list.add': '新建服务器',
'server_state.table.list.editor': '编辑服务器',
'server_state.table.list.update': '更新模型版本',
};
// 未启用
export const business_image: { [key: string]: string } = {
'resource.business_image.table.list.id': 'ID',
'resource.business_image.table.list.name': '镜像名称',
'resource.business_image.table.list.version': '镜像版本',
'resource.business_image.table.list.projectFkId': '项目',
'resource.business_image.table.list.path': '镜像地址',
'resource.business_image.table.list.startCode': '启动代码',
'resource.business_image.table.list.config': '配置',
'resource.business_image.table.list.configHash': '配置hash',
'resource.business_image.table.list.remark': '备注',
'resource.business_image.table.list.createTime': '创建时间',
'resource.business_image.table.list.updateTime': '更新时间',
'resource.business_image.table.rule.required.name': '镜像名称为必填项',
'resource.business_image.table.rule.required.version': '镜像版本为必填项',
'resource.business_image.table.rule.required.projectFkId': '项目为必填项',
'resource.business_image.table.list.add': '新建业务镜像',
'resource.business_image.table.list.update': '更新业务镜像',
};
export const model_category: { [key: string]: string } = {
'resource.model_category.table.list.id': 'ID',
'resource.model_category.table.list.name': '类别名称',
'resource.model_category.table.list.code': '类别代码',
'resource.model_category.table.list.remark': '备注',
'resource.model_category.table.list.createTime': '创建时间',
'resource.model_category.table.list.updateTime': '更新时间',
'resource.model_category.table.rule.required.name': '类别名称为必填项',
'resource.model_category.table.rule.required.code': '类别代码为必填项',
'resource.model_category.table.list.add': '新建模型类别',
'resource.model_category.table.list.update': '更新模型类别',
};
export const model_image: { [key: string]: string } = {
'resource.model_image.table.list.id': 'ID',
'resource.model_image.table.list.name': '镜像名称',
'resource.model_image.table.list.modelVersionFkId': '模型版本',
'resource.model_image.table.list.path': '镜像地址',
'resource.model_image.table.list.startCode': '启动代码',
'resource.model_image.table.list.remark': '备注',
'resource.model_image.table.list.createTime': '创建时间',
'resource.model_image.table.list.updateTime': '更新时间',
'resource.model_image.table.rule.required.name': '镜像名称为必填项',
'resource.model_image.table.rule.required.modelVersionFkId': '模型版本为必填项',
'resource.model_image.table.list.add': '新建模型镜像',
'resource.model_image.table.list.update': '更新模型镜像',
};

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-05-09 15:21:03 * @Date: 2024-05-09 15:21:03
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-10 14:51:36 * @LastEditTime: 2024-05-14 17:04:43
* @FilePath: \general-ai-platform-web\src\locales\zh-CN\server.ts * @FilePath: \general-ai-platform-web\src\locales\zh-CN\server.ts
* @Description: ,`customMade`, koroFileHeader : https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: ,`customMade`, koroFileHeader : https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-05-10 10:47:45 * @Date: 2024-05-10 10:47:45
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-13 16:13:55 * @LastEditTime: 2024-05-15 15:35:20
* @FilePath: \general-ai-platform-web\src\pages\Business\BusinessState\deviceSate.tsx * @FilePath: \general-ai-platform-web\src\pages\Business\BusinessState\deviceSate.tsx
* @Description: * @Description:
* @ * @
@ -33,7 +33,7 @@ const DeviceSate: React.FC = () => {
// 列表 // 列表
const [serverList, setServerList] = useState<Record<string, any>[]>([]); // 列表数据 const [serverList, setServerList] = useState<Record<string, any>[]>([]); // 列表数据
const [currentRow, setCurrentRow] = useState<Record<string, any>>(); const [currentRow, setCurrentRow] = useState<Record<string, any>>();
const [currentPageSize, setCurrentPageSize] = useState<number>(8); const [currentPageSize, setCurrentPageSize] = useState<number>(12);
const [currentPage, setCurrentPage] = useState<number>(1); const [currentPage, setCurrentPage] = useState<number>(1);
const [total, setTotal] = useState<number>(1); const [total, setTotal] = useState<number>(1);
@ -208,7 +208,6 @@ const DeviceSate: React.FC = () => {
onFinish={async (values) => { onFinish={async (values) => {
console.log(values, 'filter_finish_values'); console.log(values, 'filter_finish_values');
setQuerysData(() => values); setQuerysData(() => values);
return true; return true;
}} }}
> >
@ -251,37 +250,39 @@ const DeviceSate: React.FC = () => {
changeTabMode(key); changeTabMode(key);
}} }}
></Tabs> ></Tabs>
<ProList<any> <div style={{ maxHeight: 'calc(100vh - 240px)', overflowY: 'auto', overflowX: 'hidden' }}>
className="gn_pro_list" <ProList<any>
ghost={true} className="gn_pro_list"
rowKey={'id'} ghost={true}
itemCardProps={{ rowKey={'id'}
ghost: true, itemCardProps={{
bodyStyle: { padding: 0, margin: 0 }, ghost: true,
}} bodyStyle: { padding: 0, margin: 0 },
cardProps={{ }}
bodyStyle: { cardProps={{
background: 'transparent', bodyStyle: {
margin: '-4px 0', background: 'transparent',
}, margin: '-4px 0',
}} },
pagination={{ }}
...proTablePaginationOptions, pagination={{
page: currentPage, ...proTablePaginationOptions,
pageSize: currentPageSize, page: currentPage,
total: total || 0, // 指定总条目数 pageSize: currentPageSize,
onChange: (page, pageSize) => { total: total || 0, // 指定总条目数
setCurrentPageSize(pageSize); onChange: (page, pageSize) => {
setCurrentPage(page); setCurrentPageSize(pageSize);
}, setCurrentPage(page);
}} },
rowSelection={false} }}
grid={{ gutter: 16, xs: 1, md: 2, lg: 3, xl: 4, xxl: 5 }} rowSelection={false}
metas={{ grid={{ gutter: 16, xs: 1, md: 2, lg: 3, xl: 4, xxl: 5 }}
content: {}, metas={{
}} content: {},
dataSource={serverList} }}
/> dataSource={serverList}
/>
</div>
</div> </div>
</ProCard> </ProCard>

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-05-07 13:38:03 * @Date: 2024-05-07 13:38:03
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-13 11:30:19 * @LastEditTime: 2024-05-15 16:30:02
* @FilePath: \general-ai-platform-web\src\pages\Business\BusinessState\index.tsx * @FilePath: \general-ai-platform-web\src\pages\Business\BusinessState\index.tsx
* @Description: businessStatebs * @Description: businessStatebs
* @ * @
@ -29,7 +29,7 @@ const BusinessState: React.FC = () => {
// 列表 // 列表
const [serverList, setServerList] = useState<Record<string, any>[]>([]); // 列表数据 const [serverList, setServerList] = useState<Record<string, any>[]>([]); // 列表数据
const [currentRow, setCurrentRow] = useState<Record<string, any>>(); const [currentRow, setCurrentRow] = useState<Record<string, any>>();
const [currentPageSize, setCurrentPageSize] = useState<number>(8); const [currentPageSize, setCurrentPageSize] = useState<number>(12);
const [currentPage, setCurrentPage] = useState<number>(1); const [currentPage, setCurrentPage] = useState<number>(1);
const [total, setTotal] = useState<number>(1); const [total, setTotal] = useState<number>(1);
const [createModalOpen, setCreateModalOpen] = useState<boolean>(false); const [createModalOpen, setCreateModalOpen] = useState<boolean>(false);
@ -187,37 +187,39 @@ const BusinessState: React.FC = () => {
} }
></CommButton> ></CommButton>
</div> </div>
<ProList<any> <div style={{ maxHeight: 'calc(100vh - 210px)', overflowY: 'auto', overflowX: 'hidden' }}>
className="gn_pro_list" <ProList<any>
ghost={true} className="gn_pro_list"
rowKey={'id'} ghost={true}
itemCardProps={{ rowKey={'id'}
ghost: true, itemCardProps={{
bodyStyle: { padding: 0, margin: 0 }, ghost: true,
}} bodyStyle: { padding: 0, margin: 0 },
cardProps={{ }}
bodyStyle: { cardProps={{
background: 'transparent', bodyStyle: {
margin: '-4px 0', background: 'transparent',
}, margin: '-4px 0',
}} },
pagination={{ }}
...proTablePaginationOptions, pagination={{
page: currentPage, ...proTablePaginationOptions,
pageSize: currentPageSize, page: currentPage,
total: total || 0, // 指定总条目数 pageSize: currentPageSize,
onChange: (page, pageSize) => { total: total || 0, // 指定总条目数
setCurrentPageSize(pageSize); onChange: (page, pageSize) => {
setCurrentPage(page); setCurrentPageSize(pageSize);
}, setCurrentPage(page);
}} },
rowSelection={false} }}
grid={{ gutter: 16, xs: 1, md: 2, lg: 3, xl: 4, xxl: 5 }} rowSelection={false}
metas={{ grid={{ gutter: 16, xs: 1, md: 2, lg: 3, xl: 4, xxl: 5 }}
content: {}, metas={{
}} content: {},
dataSource={serverList} }}
/> dataSource={serverList}
/>
</div>
</div> </div>
</ProCard> </ProCard>
<CreateServerForm <CreateServerForm

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-30 10:02:29 * @Date: 2024-04-30 10:02:29
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-04-30 10:37:48 * @LastEditTime: 2024-05-15 15:11:00
* @FilePath: \general-ai-platform-web\src\pages\Business\DeviceGroup\components\alarmSetForm.tsx * @FilePath: \general-ai-platform-web\src\pages\Business\DeviceGroup\components\alarmSetForm.tsx
* @Description: * @Description:
* @ * @
@ -28,23 +28,7 @@ const AlarmSetForm: React.FC<AlarmSetFormProps> = (props) => {
// const [initialValues, setInitialValues] = useState<Record<string, any>>({}); // const [initialValues, setInitialValues] = useState<Record<string, any>>({});
function fetchInitialValues() { function fetchInitialValues() {}
// setInitialValues({
// type: '2',
// ways: [
// {
// label: '短信',
// value: [],
// isChecked: [],
// },
// {
// label: '邮件',
// value: [],
// isChecked: [],
// },
// ]
// });
}
useEffect(() => { useEffect(() => {
fetchInitialValues(); fetchInitialValues();
}, []); }, []);
@ -109,7 +93,7 @@ const AlarmSetForm: React.FC<AlarmSetFormProps> = (props) => {
disabled={!isChecked?.length} disabled={!isChecked?.length}
request={async () => { request={async () => {
// const resp = await postCurrentIP(); // const resp = await postCurrentIP();
const resp = ['test001', 'test002', 'test003']; const resp = ['用户A', '用户B', '用户C'];
return resp?.map((v: any) => { return resp?.map((v: any) => {
return { return {
label: v, label: v,

@ -95,6 +95,7 @@ const CreateModelParams: React.FC<CreateModelParamsProps> = (props) => {
} }
}, []); }, []);
return ( return (
// TODO stepForm 中上传文件新增参数与UI图不一致
<StepsForm<{ <StepsForm<{
name: string; name: string;
}> }>
@ -246,8 +247,8 @@ const CreateModelParams: React.FC<CreateModelParamsProps> = (props) => {
{() => { {() => {
return ( return (
<> <>
<ProFormText key="name" name="name" label="键名" /> <ProFormText width={268} key="name" name="name" label="键名" />
<ProFormText key="default" name="default" label="默认值" /> <ProFormText width={268} key="default" name="default" label="默认值" />
</> </>
); );
}} }}

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-08 16:57:30 * @Date: 2024-04-08 16:57:30
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-10 17:28:39 * @LastEditTime: 2024-05-15 15:01:35
* @FilePath: \general-ai-manage\src\pages\Project\BusinessProject\components\detailServerState.tsx * @FilePath: \general-ai-manage\src\pages\Project\BusinessProject\components\detailServerState.tsx
* @Description: * @Description:
* @ * @
@ -13,7 +13,7 @@ import { ProCard, ProColumns, ProDescriptions, ProTable } from '@ant-design/pro-
import { FormattedMessage, useIntl } from '@umijs/max'; import { FormattedMessage, useIntl } from '@umijs/max';
import { Modal } from 'antd'; import { Modal } from 'antd';
import { useEffect, useRef, useState } from 'react'; import { useEffect, useRef, useState } from 'react';
import { proFormMaxModelWidth } from '../../../../../config/defaultForm'; import { proFormSmallModelWidth } from '../../../../../config/defaultForm';
type ModelDeployConfigProps = { type ModelDeployConfigProps = {
info: Record<string, any>; info: Record<string, any>;
@ -110,7 +110,7 @@ const ModelDeployConfig: React.FC<ModelDeployConfigProps> = ({ info, detailOpen,
return ( return (
<Modal <Modal
width={proFormMaxModelWidth} width={proFormSmallModelWidth}
title={`${intl.formatMessage({ title={`${intl.formatMessage({
id: 'business_model.table.list.action.config', id: 'business_model.table.list.action.config',
defaultMessage: '配置参数', defaultMessage: '配置参数',

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-30 10:02:29 * @Date: 2024-04-30 10:02:29
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-13 10:44:23 * @LastEditTime: 2024-05-15 14:24:43
* @FilePath: \general-ai-platform-web\src\pages\Business\DeviceGroup\components\modelSetting.tsx * @FilePath: \general-ai-platform-web\src\pages\Business\DeviceGroup\components\modelSetting.tsx
* @Description: * @Description:
* @ * @
@ -192,7 +192,7 @@ const ModelSetting: React.FC<ModelSettingProps> = () => {
bodyStyle: { bodyStyle: {
padding: 0, padding: 0,
margin: 0, margin: 0,
height: 'calc(100vh - 400px)', height: 'calc(100vh - 420px)',
overflow: 'scroll', overflow: 'scroll',
}, },
}} }}

@ -2,7 +2,7 @@
* @Author: donghao donghao@supervision.ltd * @Author: donghao donghao@supervision.ltd
* @Date: 2024-04-22 15:23:36 * @Date: 2024-04-22 15:23:36
* @LastEditors: donghao donghao@supervision.ltd * @LastEditors: donghao donghao@supervision.ltd
* @LastEditTime: 2024-05-10 17:29:38 * @LastEditTime: 2024-05-15 11:44:01
* @FilePath: \general-ai-platform-web\src\pages\Business\DeviceGroup\index.tsx * @FilePath: \general-ai-platform-web\src\pages\Business\DeviceGroup\index.tsx
* @Description: deviceGroupdg * @Description: deviceGroupdg
* @ * @
@ -34,7 +34,7 @@ const DeviceGroup: React.FC = () => {
const [createModalOpen, setCreateModalOpen] = useState<boolean>(false); // 创建新增窗口是否打开 const [createModalOpen, setCreateModalOpen] = useState<boolean>(false); // 创建新增窗口是否打开
// 切换模块 // 切换模块
const [tabKey, setTabKey] = useState<string>(deviceGroupEnums[1].key); const [tabKey, setTabKey] = useState<string>(deviceGroupEnums[0].key);
const [tabs] = useState<any>([...deviceGroupEnums]); const [tabs] = useState<any>([...deviceGroupEnums]);
const changeTabMode = (key: string) => { const changeTabMode = (key: string) => {
setTabKey(key); setTabKey(key);
@ -55,7 +55,6 @@ const DeviceGroup: React.FC = () => {
const handleCreateModal = () => { const handleCreateModal = () => {
setCreateModalOpen(!createModalOpen); setCreateModalOpen(!createModalOpen);
}; };
// 节点信息展示 // 节点信息展示
// 切换 // 切换

@ -37,7 +37,7 @@ const AlgorithmCard: React.FC<AlgorithmCardProps> = ({ info }) => {
<div> <div>
<div className="flex items-center mb-[12px] "> <div className="flex items-center mb-[12px] ">
<span <span
className="pr-[16px] head3 single_line w-[150px]" className="pr-[16px] head3 single_line max-w-[150px]"
style={{ style={{
color: token.colorPrimary, color: token.colorPrimary,
}} }}

@ -33,7 +33,6 @@ const BusinessInfo: React.FC = () => {
const [detailInfo, setDetailInfo] = useState<Record<string, any>>({}); const [detailInfo, setDetailInfo] = useState<Record<string, any>>({});
const { getStoreBusinessInfo } = useBusinessInfo(); const { getStoreBusinessInfo } = useBusinessInfo();
const [updateModalOpen, setUpdateModalOpen] = useState<boolean>(false); const [updateModalOpen, setUpdateModalOpen] = useState<boolean>(false);
// 未启用 // 未启用
/** /**
* @en-US International configuration * @en-US International configuration

@ -127,7 +127,7 @@ const Login: React.FC = () => {
let localData = getAllRouteNameTile(menusData, ''); let localData = getAllRouteNameTile(menusData, '');
let localRes: any = {}; let localRes: any = {};
localData.forEach((v) => { localData.forEach((v) => {
localRes[`menu${v.name}`] = v.title; localRes[`menu.${v.name}`] = v.title;
}); });
console.log(localRes); console.log(localRes);
addLocale('zh-CN', localRes, { addLocale('zh-CN', localRes, {

Loading…
Cancel
Save