Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CivManage
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
ReactWeb5
CivManage
Commits
c18cb7e7
Commit
c18cb7e7
authored
Jul 09, 2021
by
shaoan123
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化登录界面提示
parent
e2292fa3
Pipeline
#31299
passed with stages
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
28 deletions
+29
-28
AddModal.jsx
...s/artificial/policiesIssued/predictionConfig/AddModal.jsx
+6
-6
index.js
src/pages/user/login/index.js
+3
-2
api.js
src/services/intelligence/api.js
+20
-20
No files found.
src/pages/artificial/policiesIssued/predictionConfig/AddModal.jsx
View file @
c18cb7e7
...
...
@@ -287,7 +287,7 @@ const AddModal = props => {
<
div
>
<
div
className=
{
styles
.
predict
}
></
div
>
<
Input
style=
{
{
width
:
'67.2%'
}
}
placeholder=
"请输入预测间隔"
value=
{
CycleValue
}
onChange=
{
(
value
)
=>
selectCycleValue
(
value
)
}
allowClear
/>
<
Select
style=
{
{
marginLeft
:
'1.5rem'
,
width
:
'2
8.5
%'
}
}
onChange=
{
handleIntervalType
}
value=
{
intervalType
}
>
<
Select
style=
{
{
marginLeft
:
'1.5rem'
,
width
:
'2
9
%'
}
}
onChange=
{
handleIntervalType
}
value=
{
intervalType
}
>
{
timeType
.
length
?
timeType
.
map
((
item
,
index
)
=>
{
return
<
Select
.
Option
key=
{
index
}
value=
{
item
}
>
{
item
}
</
Select
.
Option
>
})
:
''
}
</
Select
>
</
div
>
...
...
@@ -299,7 +299,7 @@ const AddModal = props => {
style=
{
{
marginLeft
:
'0.8rem'
}
}
rules=
{
[{
required
:
true
,
message
:
'请选择预测维度'
}]
}
>
<
Select
onChange=
{
selectPredictType
}
style=
{
{
width
:
'
6
rem'
}
}
>
<
Select
onChange=
{
selectPredictType
}
style=
{
{
width
:
'
8.4
rem'
}
}
>
{
PredictType
.
length
?
PredictType
.
map
((
item
,
index
)
=>
{
return
<
Select
.
Option
key=
{
index
}
value=
{
item
}
>
{
item
}
</
Select
.
Option
>
})
:
''
}
</
Select
>
</
Item
>
...
...
@@ -309,7 +309,7 @@ const AddModal = props => {
style=
{
{
marginLeft
:
'0.8rem'
}
}
rules=
{
[{
required
:
true
,
message
:
'请选择维度类别'
}]
}
>
<
Select
style=
{
{
width
:
'
6
rem'
}
}
>
<
Select
style=
{
{
width
:
'
9
rem'
}
}
>
{
commonType
.
length
?
commonType
.
map
((
item
,
index
)
=>
{
return
<
Select
.
Option
key=
{
index
}
value=
{
item
}
>
{
item
}
</
Select
.
Option
>
})
:
''
}
</
Select
>
</
Item
>
:
''
}
...
...
@@ -319,7 +319,7 @@ const AddModal = props => {
name=
"PredictCycleValue"
rules=
{
[{
required
:
true
,
message
:
'请输入预测维度值'
}]
}
>
<
Input
placeholder=
"请输入预测维度值"
style=
{
{
width
:
'
9.4
rem'
}
}
allowClear
/>
<
Input
placeholder=
"请输入预测维度值"
style=
{
{
width
:
'
12
rem'
}
}
allowClear
/>
</
Item
>
</
Row
>
<
Row
gutter=
'24'
>
...
...
@@ -329,7 +329,7 @@ const AddModal = props => {
name=
"StatisticCycle"
rules=
{
[{
required
:
true
,
message
:
'请选择预测维度'
}]
}
>
<
Select
style=
{
{
width
:
'1
6
rem'
}
}
>
<
Select
style=
{
{
width
:
'1
8
rem'
}
}
>
{
PredictType
.
length
?
PredictType
.
map
((
item
,
index
)
=>
{
return
<
Select
.
Option
key=
{
index
}
value=
{
item
}
>
{
item
}
</
Select
.
Option
>
})
:
''
}
</
Select
>
</
Item
>
...
...
@@ -339,7 +339,7 @@ const AddModal = props => {
name=
"StatisticCycleValue"
rules=
{
[{
required
:
true
,
message
:
'请输入统计维度值'
}]
}
>
<
Input
style=
{
{
width
:
'12rem'
}
}
placeholder=
"请输入统计维度值"
allowClear
/>
<
Input
style=
{
{
width
:
'1
7.
2rem'
}
}
placeholder=
"请输入统计维度值"
allowClear
/>
</
Item
>
</
Row
>
<
Item
...
...
src/pages/user/login/index.js
View file @
c18cb7e7
...
...
@@ -43,10 +43,11 @@ const Login = props => {
OMSLogin
(
loginName
,
password
,
'CivManage'
)
.
then
(
result
=>
{
const
{
data
:
{
pass
,
userMode
,
token
},
msg
,
}
=
result
;
if
(
pass
===
true
)
{
if
(
result
.
data
&&
result
.
data
.
pass
)
{
const
{
userMode
,
token
}
=
result
.
data
localStorage
.
setItem
(
'token'
,
token
?.
access_token
||
''
);
setUserMode
(
userMode
);
setLoginName
(
loginName
);
...
...
src/services/intelligence/api.js
View file @
c18cb7e7
...
...
@@ -4,79 +4,79 @@ import { CITY_SERVICE, get, PUBLISH_SERVICE, post, postForm } from '../index';
//获取任务列表
export
const
taskOptionsList
=
()
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/TaskOptionsList`
);
get
(
`
/PandaCore/OMS/AIConfig
/TaskOptionsList`
);
//获取设备类型
export
const
getIotDeviceType
=
()
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/GetIotDeviceType`
);
get
(
`
/PandaCore/OMS/AIConfig
/GetIotDeviceType`
);
//获取场景列表
export
const
algorithmList
=
()
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/AlgorithmList`
);
get
(
`
/PandaCore/OMS/AIConfig
/AlgorithmList`
);
//获取设备列表
export
const
getEquipmentInfo
=
(
query
)
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/AcrossTable/GetEquipmentInfo
?equipType=
${
query
}
`
);
get
(
`
/PandaCore/GCK/Device/DeviceTree
?equipType=
${
query
}
`
);
//获取指标列表
export
const
getQutaList
=
(
query
)
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/AcrossTable/GetQu
taList?AcountName=
${
query
.
accountName
}
&&AddrSchemeID=
${
query
.
AddrSchemeID
}
`
);
get
(
`
/PandaCore/GCK/Device/GetQuo
taList?AcountName=
${
query
.
accountName
}
&&AddrSchemeID=
${
query
.
AddrSchemeID
}
`
);
//获取场景列表
export
const
getSceneNameInfo
=
()
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/GetSceneNameInfo`
);
get
(
`
/PandaCore/OMS/AIConfig
/GetSceneNameInfo`
);
//任务添加
export
const
addTaskOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/AddTaskOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/AddTaskOptions`
,
params
);
//任务编辑
export
const
updateTaskOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/UpdateTaskOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/UpdateTaskOptions`
,
params
);
//任务删除
export
const
deleteTaskOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/DeleteTaskOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/DeleteTaskOptions`
,
params
);
//预测列表
export
const
getPredictInfo
=
()
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/GetPredictInfo`
);
get
(
`
/PandaCore/OMS/AIConfig
/GetPredictInfo`
);
//预测新增
export
const
addPredictOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/AddPredictOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/AddPredictOptions`
,
params
);
//预测编辑
export
const
editPredictOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/EditPredictOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/EditPredictOptions`
,
params
);
//预测删除
export
const
deletePredictOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/DeletePredictOptions?PredictID=
${
params
}
`
);
post
(
`
/PandaCore/OMS/AIConfig
/DeletePredictOptions?PredictID=
${
params
}
`
);
//策略下发列表
export
const
getStrategyInfo
=
()
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/GetStrategyInfo`
);
get
(
`
/PandaCore/OMS/AIConfig
/GetStrategyInfo`
);
//策略下发增加
export
const
addStrategyOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/AddStrategyOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/AddStrategyOptions`
,
params
);
//策略下发编辑
export
const
editStrategyOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/EditStrategyOptions`
,
params
);
post
(
`
/PandaCore/OMS/AIConfig
/EditStrategyOptions`
,
params
);
//策略下发删除
export
const
deleteStrategyOptions
=
(
params
)
=>
post
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/DeleteStrategyOptions?StrategyId=
${
params
}
`
);
post
(
`
/PandaCore/OMS/AIConfig
/DeleteStrategyOptions?StrategyId=
${
params
}
`
);
//获取预测设备
export
const
getPredictDevice
=
(
params
)
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge
/GetPredictDevice?DeviceType=
${
params
}
`
);
get
(
`
/PandaCore/OMS/AIConfig
/GetPredictDevice?DeviceType=
${
params
}
`
);
//获取预测指标
export
const
getPredictDevicePoint
=
(
params
)
=>
get
(
`
${
CITY_SERVICE
}
/IOTPlatform.svc/WaterAge/GetPredictDevicePoint?DeviceType=
${
params
.
deviceType
}
&DeviceCode=
${
params
.
DeviceCode
}
`
);
\ No newline at end of file
get
(
`/PandaCore/OMS/AIConfig/GetPredictDevicePoint?DeviceType=
${
params
.
deviceType
}
&DeviceCode=
${
params
.
DeviceCode
}
`
);
\ No newline at end of file
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