Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-customization-system
/
micro-trialrun
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit c47c7e73
authored
Jun 06, 2022
by
张杰
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
v1.7.1版本需求
1 parent
4cd402a7
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
71 additions
and
78 deletions
src/common/index.js
src/styles/hadoop.scss
src/views/alarmCenter/offline.vue
src/views/vehicleManage/vehicleList.vue
src/common/index.js
View file @
c47c7e7
...
@@ -127,6 +127,42 @@ let currentWeek = {
...
@@ -127,6 +127,42 @@ let currentWeek = {
},
},
}
}
// 最近一天不在线
let
latelyOneDay
=
{
text
:
"近1天不在线"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD HH:mm:ss"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
1
)
.
format
(
"YYYY-MM-DD HH:mm:ss"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
}
// 最近三天不在线
let
latelyThreeDay
=
{
text
:
"近3天不在线"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD HH:mm:ss"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
3
)
.
format
(
"YYYY-MM-DD HH:mm:ss"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
}
// 最近7天不在线
let
latelySevenDay
=
{
text
:
"近7天不在线"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD HH:mm:ss"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
7
)
.
format
(
"YYYY-MM-DD HH:mm:ss"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
}
// 警情中心-围栏报警
// 警情中心-围栏报警
export
const
fenceShortcuts
=
[
export
const
fenceShortcuts
=
[
allDays
,
allDays
,
...
@@ -183,3 +219,18 @@ export const staticReportCarShortcuts = [
...
@@ -183,3 +219,18 @@ export const staticReportCarShortcuts = [
currentMonth
,
currentMonth
,
lastMonth
lastMonth
]
]
// 离线报警-离线时间
export
const
offlineShortcuts
=
[
latelyOneDay
,
latelyThreeDay
,
latelySevenDay
]
// 离线报警-激活时间
export
const
offlineActiveShortcuts
=
[
allDays
,
nearly3Days
,
nearly7Days
,
currentMonth
]
src/styles/hadoop.scss
View file @
c47c7e7
...
@@ -40,6 +40,9 @@
...
@@ -40,6 +40,9 @@
.data_picker
{
.data_picker
{
width
:
240px
;
width
:
240px
;
}
}
.datatime_picker
{
width
:
360px
;
}
.mr5
{
.mr5
{
margin-right
:
5px
;
margin-right
:
5px
;
}
}
...
...
src/views/alarmCenter/offline.vue
View file @
c47c7e7
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
<div
class=
"search_box"
>
<div
class=
"search_box"
>
<el-form
:inline=
"true"
size=
"small"
>
<el-form
:inline=
"true"
size=
"small"
>
<el-form-item
label=
"离线时间:"
>
<el-form-item
label=
"离线时间:"
>
<el-date-picker
v-model=
"searchForm.offDate"
type=
"date
range"
class=
"data_picker"
unlink-panels
range-separator=
"~"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
value-format=
"yyyy-MM-dd"
:picker-options=
"offPickerOptions
"
>
<el-date-picker
v-model=
"searchForm.offDate"
type=
"date
timerange"
class=
"datatime_picker"
unlink-panels
range-separator=
"~"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
value-format=
"yyyy-MM-dd HH:mm:ss"
:picker-options=
"offPickerOptions"
@
change=
"onChangeDate
"
>
</el-date-picker>
</el-date-picker>
</el-form-item>
</el-form-item>
<el-form-item
label=
"激活区间:"
>
<el-form-item
label=
"激活区间:"
>
...
@@ -87,8 +87,8 @@ import moment from "moment";
...
@@ -87,8 +87,8 @@ import moment from "moment";
import
GlsxOrganization
from
"@/components/glsx-organization"
;
import
GlsxOrganization
from
"@/components/glsx-organization"
;
import
{
GETOFFLINESEARCH
,
ALARM_OFFLINE_EXPORT
}
from
"@/services/alarmCenter"
;
import
{
GETOFFLINESEARCH
,
ALARM_OFFLINE_EXPORT
}
from
"@/services/alarmCenter"
;
import
{
deepClone
,
showToast
}
from
"@/utils/util"
;
import
{
deepClone
,
showToast
}
from
"@/utils/util"
;
import
store
from
"@/store
"
;
import
{
offlineShortcuts
,
offlineActiveShortcuts
}
from
"@/common
"
;
import
qs
from
'qs'
import
qs
from
"qs"
;
export
default
{
export
default
{
components
:
{
components
:
{
GlsxOrganization
,
GlsxOrganization
,
...
@@ -106,78 +106,10 @@ export default {
...
@@ -106,78 +106,10 @@ export default {
showResult
:
false
,
showResult
:
false
,
loading
:
false
,
loading
:
false
,
offPickerOptions
:
{
offPickerOptions
:
{
shortcuts
:
[
shortcuts
:
offlineShortcuts
,
{
text
:
"近1天不在线"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
1
)
.
format
(
"YYYY-MM-DD"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
{
text
:
"近3天不在线"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
3
)
.
format
(
"YYYY-MM-DD"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
{
text
:
"近7天不在线"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
7
)
.
format
(
"YYYY-MM-DD"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
],
},
},
pickerOptions
:
{
pickerOptions
:
{
shortcuts
:
[
shortcuts
:
offlineActiveShortcuts
,
{
text
:
"全部"
,
onClick
(
picker
)
{
const
end
=
""
;
const
start
=
""
;
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
{
text
:
"近3天"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
3
)
.
format
(
"YYYY-MM-DD"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
{
text
:
"近7天"
,
onClick
(
picker
)
{
const
end
=
moment
().
format
(
"YYYY-MM-DD"
);
const
start
=
moment
()
.
day
(
moment
().
day
()
-
7
)
.
format
(
"YYYY-MM-DD"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
{
text
:
"本月"
,
onClick
(
picker
)
{
const
start
=
moment
().
add
(
"month"
,
0
).
format
(
"YYYY-MM"
)
+
"-01"
;
const
end
=
moment
().
format
(
"YYYY-MM-DD"
);
picker
.
$emit
(
"pick"
,
[
start
,
end
]);
},
},
],
},
},
filterVisible
:
false
,
filterVisible
:
false
,
orgInfo
:
{},
orgInfo
:
{},
...
@@ -186,10 +118,12 @@ export default {
...
@@ -186,10 +118,12 @@ export default {
};
};
},
},
created
()
{
created
()
{
let
end
=
moment
().
format
(
"YYYY-MM-DD"
);
let
end
=
moment
().
format
(
"YYYY-MM-DD"
)
+
" 23:59:59"
;
let
start
=
moment
()
let
start
=
moment
()
.
day
(
moment
().
day
()
-
3
)
.
day
(
moment
().
day
()
-
3
)
.
format
(
"YYYY-MM-DD"
);
.
format
(
"YYYY-MM-DD"
)
+
" 00:00:00"
;
console
.
log
(
start
+
"--"
+
end
);
this
.
$set
(
this
.
searchForm
,
"offDate"
,
[
start
,
end
]);
this
.
$set
(
this
.
searchForm
,
"offDate"
,
[
start
,
end
]);
this
.
getList
();
this
.
getList
();
},
},
...
@@ -285,9 +219,14 @@ export default {
...
@@ -285,9 +219,14 @@ export default {
//let a = window.location.origin;
//let a = window.location.origin;
let
path
=
`/oEshield#/monitor/activeLocation?
${
qs
.
stringify
(
oParams
)}
`
;
let
path
=
`/oEshield#/monitor/activeLocation?
${
qs
.
stringify
(
oParams
)}
`
;
this
.
$root
.
parentCommon
.
setBreadCrumbs
(
path
);
this
.
$root
.
parentCommon
.
setBreadCrumbs
(
path
);
window
.
open
(
path
)
window
.
open
(
path
)
;
//history.pushState(oParams, "报警位置点", path);
//history.pushState(oParams, "报警位置点", path);
},
},
onChangeDate
(
e
){
console
.
log
(
e
)
}
},
},
};
};
</
script
>
</
script
>
...
...
src/views/vehicleManage/vehicleList.vue
View file @
c47c7e7
...
@@ -103,7 +103,7 @@
...
@@ -103,7 +103,7 @@
</el-table-column>
</el-table-column>
<el-table-column
label=
"激活时间"
prop=
"activateTime"
show-overflow-tooltip
></el-table-column>
<el-table-column
label=
"激活时间"
prop=
"activateTime"
show-overflow-tooltip
></el-table-column>
<el-table-column
label=
"设备状态"
prop=
"deviceStateStr"
show-overflow-tooltip
>
<el-table-column
label=
"设备状态"
prop=
"deviceStateStr"
show-overflow-tooltip
>
<
template
slot-scope=
"{row}"
>
{{
row
.
deviceStateStr
||
'--'
}}
</
template
>
<
!-- <template slot-scope="{row}">{{row.deviceStateStr||'--'}}</template> --
>
</el-table-column>
</el-table-column>
<el-table-column
label=
"特殊状态"
prop=
"specialState"
show-overflow-tooltip
></el-table-column>
<el-table-column
label=
"特殊状态"
prop=
"specialState"
show-overflow-tooltip
></el-table-column>
<el-table-column
label=
"是否结清"
prop=
"settleFlag"
show-overflow-tooltip
>
<el-table-column
label=
"是否结清"
prop=
"settleFlag"
show-overflow-tooltip
>
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment