Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-convertor-view
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
station
amos-convertor-view
Commits
1db97b33
Commit
1db97b33
authored
Jun 16, 2020
by
单奇雲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
2e6c15ca
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
80 additions
and
46 deletions
+80
-46
point.scss
src/styles/view/biz/point/point.scss
+11
-0
CommonTable.js
src/view/bizview/common/table/CommonTable.js
+2
-2
FireEquipmentModel.js
...tLedger/FireResources/FireEquipment/FireEquipmentModel.js
+2
-2
index.js
...view/equipmentLedger/FireResources/FireEquipment/index.js
+1
-1
FireTruckDetailInfo.js
...mentLedger/FireResources/FireTruck/FireTruckDetailInfo.js
+12
-7
fireTruckModel.js
...equipmentLedger/FireResources/FireTruck/fireTruckModel.js
+13
-10
index.js
.../bizview/equipmentLedger/FireResources/FireTruck/index.js
+5
-3
fireFoam.js
...izview/equipmentLedger/FireResources/fireFoam/fireFoam.js
+4
-0
FireStationMatches.js
...Ledger/FireResources/matchEquipment/FireStationMatches.js
+6
-5
CurDangerCount.js
src/view/bizview/task/CurDangerCount.js
+24
-16
No files found.
src/styles/view/biz/point/point.scss
View file @
1db97b33
...
...
@@ -10,6 +10,7 @@
margin
:
10px
;
.point-statistics
{
position
:
relative
;
float
:
left
;
width
:
18%
;
height
:
100%
;
...
...
@@ -43,6 +44,15 @@
font-weight
:
bold
;
}
}
.point-statistics-label
{
position
:
absolute
;
text-align
:
center
;
font-size
:
20px
;
top
:
40%
;
right
:
40%
;
}
}
.point-month-ins
{
...
...
@@ -572,6 +582,7 @@
height
:
100%
;
.ant-table-scroll
{
overflow
:
hidden
;
height
:
100%
;
.ant-table-body
{
...
...
src/view/bizview/common/table/CommonTable.js
View file @
1db97b33
...
...
@@ -76,10 +76,10 @@ class CommonTable extends Component {
*/
getHeader
=
()
=>
{
return
<
div
>
<
Button
onClick
=
{
this
.
onAddClick
}
icon
=
"add"
>
<
Button
onClick
=
{
this
.
onAddClick
}
disabled
=
{
!
this
.
props
.
editable
}
icon
=
"add"
>
添加
<
/Button
>
<
Button
onClick
=
{
this
.
onDelClick
}
icon
=
"remove"
>
<
Button
onClick
=
{
this
.
onDelClick
}
disabled
=
{
!
this
.
props
.
editable
}
icon
=
"remove"
>
删除
<
/Button
>
<
/div>
;
...
...
src/view/bizview/equipmentLedger/FireResources/FireEquipment/FireEquipmentModel.js
View file @
1db97b33
...
...
@@ -247,9 +247,9 @@ class FireEquipmentModel extends Component {
onChange
=
{
e
=>
this
.
onSelectChange
(
'riskSourceId'
,
e
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
区域
<
/span>} field="productionArea" {...formItemLayout}
>
{
/*
<FormItem label={<span>区域</span>} field="productionArea" {...formItemLayout}>
<Input className="risk_factor_input" required value={form.productionArea} onChange={e => this.onInputChange('productionArea', e.target.value)} />
<
/FormItem
>
</FormItem>
*/
}
<
FormItem
label
=
{
<
span
>
房间号
<
/span>} field="room" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
room
}
onChange
=
{
e
=>
this
.
onInputChange
(
'room'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
...
...
src/view/bizview/equipmentLedger/FireResources/FireEquipment/index.js
View file @
1db97b33
...
...
@@ -376,7 +376,7 @@ class FireEquipmentView extends Component {
this
.
editCancel
();
},
error
=>
{
AmosAlert
.
error
(
'错误'
,
'保存失败'
);
AmosAlert
.
error
(
'错误'
,
error
||
'保存失败'
);
}
);
}
else
{
...
...
src/view/bizview/equipmentLedger/FireResources/FireTruck/FireTruckDetailInfo.js
View file @
1db97b33
...
...
@@ -34,20 +34,22 @@ class FireTruckDetailInfo extends Component {
imgFiles
:
[],
previewVisible
:
false
,
previewImage
:
''
,
isDisabled
:
false
isDisabled
:
false
,
editable
:
false
};
}
componentDidMount
()
{
let
{
fireCarId
}
=
this
.
props
.
location
.
state
||
{};
let
{
fireCarId
,
editable
}
=
this
.
props
.
location
.
state
||
{};
this
.
setState
({
editable
});
fireCarId
&&
this
.
getFireTruckData
(
fireCarId
);
}
componentWillReceiveProps
(
nextProps
)
{
if
(
nextProps
&&
nextProps
.
location
.
state
)
{
let
{
fireCarId
}
=
nextProps
.
location
.
state
||
{};
let
{
fireCarId
,
editable
}
=
nextProps
.
location
.
state
||
{};
fireCarId
&&
this
.
getFireTruckData
(
fireCarId
);
this
.
setState
({
imgFiles
:
[]
});
this
.
setState
({
imgFiles
:
[]
,
editable
});
}
}
...
...
@@ -265,9 +267,12 @@ class FireTruckDetailInfo extends Component {
<div className="fire-resource-truck-detail-button">
<Button icon={<BizIcon icon="fanhui" />} transparent onClick={() => this.goBack()} />
<div className="fire-resource-commit-button">
<Button icon="ok" disabled={isDisabled || editable} onClick={() => this.submitData()} transparent>
{
editable &&
<Button icon="ok" disabled={isDisabled} onClick={() => this.submitData()} transparent>
提交
</Button>
}
</div>
</div>
<div className="fire-resource-truck-detail-info-content">
...
...
@@ -289,11 +294,11 @@ class FireTruckDetailInfo extends Component {
</div>
<div className="fire-truck-performance2">
<div className="fire-truck-performance-title">车辆基本信息</div>
<FireTruckModel truckInfo={truckInfo} updateFireCarState={this.updateFireCarState} ref={model => (this.model = model)} />
<FireTruckModel truckInfo={truckInfo}
editable={editable}
updateFireCarState={this.updateFireCarState} ref={model => (this.model = model)} />
</div>
<div className="fire-truck-performance3">
<div className="fire-truck-performance-title">车辆性能信息</div>
<CommonTable tableData={dataList} onChangeTableValues={this.onChangeTableValues} columns={this.fireTruckTableColumns()} />
<CommonTable tableData={dataList}
editable={editable}
onChangeTableValues={this.onChangeTableValues} columns={this.fireTruckTableColumns()} />
</div>
</div>
</div>
...
...
src/view/bizview/equipmentLedger/FireResources/FireTruck/fireTruckModel.js
View file @
1db97b33
...
...
@@ -115,7 +115,7 @@ class FireTruckModel extends Component {
<
Form
model
=
{
form
}
rules
=
{
rules
}
ref
=
{
component
=>
this
.
form
=
component
}
>
<
div
className
=
'important-equipment-edit'
>
<
FormItem
label
=
{
<
span
>
车辆名称
<
/span>} field="name" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
name
}
onChange
=
{
e
=>
this
.
onInputChange
(
'name'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
name
}
onChange
=
{
e
=>
this
.
onInputChange
(
'name'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
部门
<
/span>} field="deptId" {...formItemLayout}
>
<
Select
...
...
@@ -126,13 +126,14 @@ class FireTruckModel extends Component {
defaultOption
=
{
<
Option
value
=
{
-
1
}
>
{
'请选择'
}
<
/Option>
}
value
=
{
form
.
deptId
}
onChange
=
{
e
=>
this
.
onSelectChange
(
'deptId'
,
e
)}
disabled
=
{
!
this
.
props
.
editable
}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
发动机号
<
/span>} field="engineNum" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
engineNum
}
onChange
=
{
e
=>
this
.
onInputChange
(
'engineNum'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
engineNum
}
onChange
=
{
e
=>
this
.
onInputChange
(
'engineNum'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
车辆状态
<
/span>} field="state" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
state
}
onChange
=
{
e
=>
this
.
onInputChange
(
'state'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
state
}
onChange
=
{
e
=>
this
.
onInputChange
(
'state'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
所属区域
<
/span>} field="riskSourceId" {...formItemLayout}
>
...
...
@@ -144,11 +145,12 @@ class FireTruckModel extends Component {
placeholder
=
"请选择"
value
=
{
form
.
riskSourceId
}
onChange
=
{
e
=>
this
.
onSelectChange
(
'riskSourceId'
,
e
)}
disabled
=
{
!
this
.
props
.
editable
}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
3
维坐标
<
/span>} field="position3d" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
position3d
}
onChange
=
{
e
=>
this
.
onInputChange
(
'position3d'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
position3d
}
onChange
=
{
e
=>
this
.
onInputChange
(
'position3d'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
3
维楼层
<
/span>} field="floor3d" {...formItemLayout}
>
<
Select
...
...
@@ -158,28 +160,29 @@ class FireTruckModel extends Component {
value
=
{
form
.
floor3d
}
renderOption
=
{
item
=>
<
Option
value
=
{
item
.
id
}
>
{
item
.
name
}
<
/Option>
}
onChange
=
{
e
=>
this
.
onInputChange
(
'floor3d'
,
e
)}
disabled
=
{
!
this
.
props
.
editable
}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
是否室内
<
/span>} field="isIndoor" {...formItemLayout}
>
<
RadioGroup
defaultValue
=
{
form
.
isIndoor
}
value
=
{
form
.
isIndoor
}
onChange
=
{
e
=>
this
.
onInputChange
(
'isIndoor'
,
e
)}
>
<
RadioGroup
defaultValue
=
{
form
.
isIndoor
}
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
isIndoor
}
onChange
=
{
e
=>
this
.
onInputChange
(
'isIndoor'
,
e
)}
>
<
Radio
value
=
{
false
}
>
否
<
/Radio
>
<
Radio
value
=
{
true
}
>
是
<
/Radio
>
<
/RadioGroup
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
车牌号
<
/span>} field="carNum" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
carNum
}
onChange
=
{
e
=>
this
.
onInputChange
(
'carNum'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
carNum
}
onChange
=
{
e
=>
this
.
onInputChange
(
'carNum'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
车辆类别
<
/span>} field="type" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
type
}
onChange
=
{
e
=>
this
.
onInputChange
(
'type'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
type
}
onChange
=
{
e
=>
this
.
onInputChange
(
'type'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
厂牌型号
<
/span>} field="model" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
model
}
onChange
=
{
e
=>
this
.
onInputChange
(
'model'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
model
}
onChange
=
{
e
=>
this
.
onInputChange
(
'model'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
国别
<
/span>} field="country" {...formItemLayout}
>
<
Input
className
=
"risk_factor_input"
required
value
=
{
form
.
country
}
onChange
=
{
e
=>
this
.
onInputChange
(
'country'
,
e
.
target
.
value
)}
/
>
<
Input
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
country
}
onChange
=
{
e
=>
this
.
onInputChange
(
'country'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
FormItem
label
=
{
<
span
>
备注
<
/span>} field="remark" {...formItemLayout}
>
<
TextArea
rows
=
{
10
}
cols
=
{
20
}
className
=
"risk_factor_input"
required
value
=
{
form
.
remark
}
onChange
=
{
e
=>
this
.
onInputChange
(
'remark'
,
e
.
target
.
value
)}
/
>
<
TextArea
rows
=
{
10
}
cols
=
{
20
}
className
=
"risk_factor_input"
required
disabled
=
{
!
this
.
props
.
editable
}
value
=
{
form
.
remark
}
onChange
=
{
e
=>
this
.
onInputChange
(
'remark'
,
e
.
target
.
value
)}
/
>
<
/FormItem
>
<
/div
>
<
/Form
>
...
...
src/view/bizview/equipmentLedger/FireResources/FireTruck/index.js
View file @
1db97b33
...
...
@@ -115,7 +115,7 @@ class FireTruckView extends Component {
onDetailClick
=
record
=>
{
let
path
=
{
pathname
:
fireTruckInfoPath
,
state
:
{
fireCarId
:
record
.
id
}
state
:
{
fireCarId
:
record
.
id
,
editable
:
false
}
};
browserHistory
.
push
(
path
);
};
...
...
@@ -186,7 +186,7 @@ class FireTruckView extends Component {
add
()
{
let
path
=
{
pathname
:
fireTruckInfoPath
,
state
:
{
toolbarFlag
:
0
}
state
:
{
toolbarFlag
:
0
,
editable
:
true
}
};
browserHistory
.
push
(
path
);
};
...
...
@@ -207,7 +207,9 @@ class FireTruckView extends Component {
pathname
:
fireTruckInfoPath
,
state
:
{
toolbarFlag
:
1
,
fireCarId
:
fireCarId
}
fireCarId
:
fireCarId
,
editable
:
true
}
};
browserHistory
.
push
(
path
);
}
...
...
src/view/bizview/equipmentLedger/FireResources/fireFoam/fireFoam.js
View file @
1db97b33
...
...
@@ -349,10 +349,14 @@ class FireFoamable extends Component {
body
:
formData
})
.
then
(
e
=>
{
if
(
e
.
status
===
200
){
AmosAlert
.
success
(
'提示'
,
'保存成功'
);
this
.
cancel
();
// this.getFireStationData(this.pageConfig);
this
.
state
.
reload
();
}
else
{
AmosAlert
.
error
(
'错误'
,
'保存失败,请检查编号是否重复!'
);
}
})
.
catch
(
e
=>
{
AmosAlert
.
error
(
'错误'
,
'保存失败'
);
...
...
src/view/bizview/equipmentLedger/FireResources/matchEquipment/FireStationMatches.js
View file @
1db97b33
...
...
@@ -22,6 +22,7 @@ const matchEquipmentTableColumns = self => {
return
[
{
title
:
'序号'
,
width
:
'5%'
,
render
:
(
text
,
record
,
index
)
=>
`
${
index
+
1
}
`
},
{
...
...
@@ -34,7 +35,7 @@ const matchEquipmentTableColumns = self => {
title
:
'名称'
,
dataIndex
:
'name'
,
key
:
'name'
,
width
:
'1
5
%'
width
:
'1
0
%'
},
// {
// title: '厂商',
...
...
@@ -53,13 +54,13 @@ const matchEquipmentTableColumns = self => {
title
:
'类型'
,
dataIndex
:
'equip_type'
,
key
:
'equip_type'
,
width
:
'1
5
%'
width
:
'1
0
%'
},
{
title
:
'所属区域'
,
dataIndex
:
'riskSourceName'
,
key
:
'riskSourceName'
,
width
:
'
15
%'
width
:
'
20
%'
},
{
title
:
'楼层'
,
...
...
@@ -71,7 +72,7 @@ const matchEquipmentTableColumns = self => {
title
:
'房间'
,
dataIndex
:
'room'
,
key
:
'room'
,
width
:
'1
5
%'
width
:
'1
0
%'
},
{
title
:
'数量'
,
...
...
@@ -83,7 +84,7 @@ const matchEquipmentTableColumns = self => {
title
:
'单位'
,
dataIndex
:
'unit'
,
key
:
'unit'
,
width
:
'
6
%'
width
:
'
5
%'
}
];
};
...
...
src/view/bizview/task/CurDangerCount.js
View file @
1db97b33
...
...
@@ -50,22 +50,22 @@ class CurDangerCount extends Component {
itemStyle
:
{
normal
:
{
label
:
{
show
:
tru
e
,
position
:
'center'
,
formatter
:
function
(
params
)
{
let
name
=
params
.
name
;
if
(
name
===
'处理中'
)
{
return
'{a|'
+
params
.
value
+
'}'
+
'
\
r
\
n'
+
'{a|'
+
params
.
name
+
'}'
;
}
else
{
return
''
;
}
},
rich
:
{
a
:
{
fontSize
:
'20'
,
color
:
'black'
//'#ffffff'
}
}
show
:
fals
e
,
//
position: 'center',
//
formatter: function(params) {
//
let name = params.name;
//
if (name === '处理中') {
//
return '{a|' + params.value + '}' + '\r\n' + '{a|' + params.name + '}';
//
} else {
//
return '';
//
}
//
},
//
rich: {
//
a: {
//
fontSize: '20',
//
color: 'black' //'#ffffff'
//
}
//
}
},
labelLine
:
{
show
:
false
...
...
@@ -103,6 +103,7 @@ class CurDangerCount extends Component {
timeOut
=
e
.
value
;
}
});
const
processing
=
data
&&
data
.
find
(
e
=>
e
.
name
===
'处理中'
);
return
(
<
div
className
=
"point-statistics"
>
<
div
className
=
"point-statistics-title"
>
当前隐患治理情况
<
/div
>
...
...
@@ -110,6 +111,13 @@ class CurDangerCount extends Component {
<
div
className
=
"point-statistics-concent"
>
已超时:
<
span
>
{
timeOut
}
<
/span
>
<
/div
>
{
processing
&&
processing
.
value
>
0
&&
<
div
className
=
"point-statistics-label"
>
{
processing
.
value
}
<
br
/>
{
processing
.
name
}
<
/div
>
}
<
/div
>
);
}
...
...
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