Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dlink
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhaowei
dlink
Commits
559622d8
Unverified
Commit
559622d8
authored
Mar 13, 2022
by
aiwenmo
Committed by
GitHub
Mar 13, 2022
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #182 from zhu-mingye/dev
前端优化 pom优化
parents
3d107f05
3f97ca5e
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
60 additions
and
27 deletions
+60
-27
pom.xml
dlink-admin/pom.xml
+0
-17
config.dev.ts
dlink-web/config/config.dev.ts
+25
-2
config.ts
dlink-web/config/config.ts
+25
-2
package.json
dlink-web/package.json
+7
-1
AlertGroupForm.tsx
dlink-web/src/pages/AlertGroup/components/AlertGroupForm.tsx
+3
-5
No files found.
dlink-admin/pom.xml
View file @
559622d8
...
...
@@ -141,23 +141,6 @@
<groupId>
com.dlink
</groupId>
<artifactId>
dlink-gateway
</artifactId>
</dependency>
<!--<dependency>
<groupId>com.dlink</groupId>
<artifactId>dlink-metadata-mysql</artifactId>
</dependency>
<dependency>
<groupId>com.dlink</groupId>
<artifactId>dlink-metadata-doris</artifactId>
</dependency>
<dependency>
<groupId>com.dlink</groupId>
<artifactId>dlink-metadata-phoenix</artifactId>
</dependency>
<dependency>
<groupId>org.apache.phoenix</groupId>
<artifactId>phoenix-core</artifactId>
<version>4.14.2-HBase-1.4</version>
</dependency>-->
</dependencies>
<build>
<plugins>
...
...
dlink-web/config/config.dev.ts
View file @
559622d8
// https://umijs.org/config/
import
{
defineConfig
}
from
'umi'
;
import
{
defineConfig
}
from
'umi'
;
const
HappyPack
=
require
(
'happypack'
);
const
happyThreadPool
=
HappyPack
.
ThreadPool
({
size
:
require
(
'os'
).
cpus
().
length
})
const
TerserPlugin
=
require
(
'terser-webpack-plugin'
);
export
default
defineConfig
({
plugins
:
[
...
...
@@ -12,7 +16,26 @@ export default defineConfig({
babelPlugins
:
[],
babelOptions
:
{},
},
chainWebpack
:
(
memo
,
{
webpack
})
=>
{
memo
.
plugin
(
'HappyPack'
).
use
(
HappyPack
,
[{
id
:
'js'
,
loaders
:
[
'babel-loader'
],
threadPool
:
happyThreadPool
,
},
memo
.
plugin
(
'TerserPlugin'
).
use
(
TerserPlugin
,
[{
parallel
:
require
(
'os'
).
cpus
().
length
-
1
,
terserOptions
:
{
compress
:
{
inline
:
false
},
mangle
:
{
safari10
:
true
}
}
}])
])
}
/*webpack5: {
// lazyCompilation
: {},
//
: {},
},*/
});
dlink-web/config/config.ts
View file @
559622d8
// https://umijs.org/config/
import
{
defineConfig
}
from
'umi'
;
import
{
join
}
from
'path'
;
import
{
defineConfig
}
from
'umi'
;
import
{
join
}
from
'path'
;
import
defaultSettings
from
'./defaultSettings'
;
import
proxy
from
'./proxy'
;
import
routes
from
'./routes'
;
const
HappyPack
=
require
(
'happypack'
);
const
happyThreadPool
=
HappyPack
.
ThreadPool
({
size
:
require
(
'os'
).
cpus
().
length
})
const
TerserPlugin
=
require
(
'terser-webpack-plugin'
);
const
{
REACT_APP_ENV
}
=
process
.
env
;
export
default
defineConfig
({
...
...
@@ -69,4 +73,23 @@ export default defineConfig({
projectName
:
'swagger'
,
},
],
chainWebpack
:
(
memo
,
{
webpack
})
=>
{
memo
.
plugin
(
'HappyPack'
).
use
(
HappyPack
,
[{
id
:
'js'
,
loaders
:
[
'babel-loader'
],
threadPool
:
happyThreadPool
,
},
memo
.
plugin
(
'TerserPlugin'
).
use
(
TerserPlugin
,
[{
parallel
:
require
(
'os'
).
cpus
().
length
-
1
,
terserOptions
:
{
compress
:
{
inline
:
false
},
mangle
:
{
safari10
:
true
}
}
}])
])
}
});
dlink-web/package.json
View file @
559622d8
...
...
@@ -87,7 +87,10 @@
"react-monaco-editor"
:
"^0.43.0"
,
"sql-formatter"
:
"^4.0.2"
,
"umi"
:
"^3.5.0"
,
"umi-serve"
:
"^1.9.10"
"umi-serve"
:
"^1.9.10"
,
"happypack"
:
"^5.0.1"
,
"terser-webpack-plugin"
:
"^4.2.3"
,
"hap-toolkit"
:
"^1.9.8"
},
"devDependencies"
:
{
"@ant-design/pro-cli"
:
"^2.0.2"
,
...
...
@@ -122,6 +125,9 @@
"puppeteer-core"
:
"^8.0.0"
,
"stylelint"
:
"^13.0.0"
,
"swagger-ui-react"
:
"^3.52.3"
,
"hap-toolkit"
:
"^1.9.8"
,
"happypack"
:
"^5.0.1"
,
"terser-webpack-plugin"
:
"^4.2.3"
,
"typescript"
:
"^4.2.2"
},
"engines"
:
{
...
...
dlink-web/src/pages/AlertGroup/components/AlertGroupForm.tsx
View file @
559622d8
import
React
,
{
use
Effect
,
use
State
}
from
'react'
;
import
{
Form
,
Button
,
Input
,
Modal
,
Select
,
Tag
,
Switch
}
from
'antd'
;
import
React
,
{
useState
}
from
'react'
;
import
{
Button
,
Form
,
Input
,
Modal
,
Select
,
Switch
,
Tag
}
from
'antd'
;
import
{
AlertGroupTableListItem
}
from
"@/pages/AlertGroup/data"
;
import
{
JarStateType
}
from
"@/pages/Jar/model"
;
import
{
connect
}
from
"umi"
;
import
{
StateType
}
from
"@/pages/FlinkSqlStudio/model"
;
import
{
AlertStateType
}
from
"@/pages/AlertInstance/model"
;
import
{
AlertInstanceTableListItem
}
from
"@/pages/AlertInstance/data"
;
import
{
buildFormData
,
getFormData
}
from
"@/pages/AlertGroup/function"
;
...
...
@@ -69,7 +67,7 @@ const AlertGroupForm: React.FC<AlertGroupFormProps> = (props) => {
<
Form
.
Item
name=
"alertInstanceIds"
label=
"报警实例"
help=
"请选择报警组实例"
rules=
{
[{
required
:
true
,
message
:
'请选择报警组实例!'
}]
}
>
<
Select
mode=
"multiple"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment