Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
I
inspection-pad-web
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
专网
inspection-pad-web
Commits
c9f2531d
提交
c9f2531d
authored
4月 09, 2025
作者:
BaoChunXian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat: 井道巡检状态修改
上级
25dc648d
显示空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
47 行增加
和
47 行删除
+47
-47
dialog.vue
pages/shaftInspection/model/dialog.vue
+9
-24
shaftInspectionList.vue
pages/shaftInspection/shaftInspectionList.vue
+8
-3
shared.js
pages/shaftInspection/shared.js
+17
-7
dict.js
utils/dict.js
+13
-13
没有找到文件。
pages/shaftInspection/model/dialog.vue
浏览文件 @
c9f2531d
...
...
@@ -83,21 +83,6 @@ export default {
this
.
init
()
},
},
// async mounted() {
// const temp = [];
// this.list.forEach((item) => {
// temp.push(...(item.list || []));
// });
// console.log("this.list", this.list);
// console.log("temp", temp);
// this.notSynchronizationList = temp.filter(
// (item) => item.synchronization == 0 && item.isSign === true
// );
// getAllInspections().then((res) => {
// this.allList = res;
// });
// },
methods
:
{
init
()
{
const
temp
=
[];
...
...
@@ -159,11 +144,11 @@ export default {
let
timeStr
=
moment
().
format
(
"yyyy_MM_DD_hh_mm_ss"
);
const
JFXJ_DATA
=
notSynchronizationList
.
filter
((
item
)
=>
item
.
inspectionType
==
1
)
.
map
((
item
)
=>
{
return
item
;
});
// 机房数据类型是 1
//
const JFXJ_DATA = notSynchronizationList
//
.filter((item) => item.inspectionType == 1)
//
.map((item) => {
//
return item;
//
}); // 机房数据类型是 1
const
JDXJ_DATA
=
notSynchronizationList
.
filter
((
item
)
=>
item
.
inspectionType
==
2
)
...
...
@@ -175,10 +160,10 @@ export default {
this
.
loading
=
true
;
const
tmepList
=
[];
if
(
JFXJ_DATA
.
length
)
{
let
JFXJ_DATA_FILE_NAME
=
`
${
userName
}
_JFXJ_
${
timeStr
}
.txt`
;
tmepList
.
push
(
this
.
packedData
(
JFXJ_DATA
,
JFXJ_DATA_FILE_NAME
));
}
//
if (JFXJ_DATA.length) {
//
let JFXJ_DATA_FILE_NAME = `${userName}_JFXJ_${timeStr}.txt`;
//
tmepList.push(this.packedData(JFXJ_DATA, JFXJ_DATA_FILE_NAME));
//
}
JDXJ_DATA
.
forEach
((
item
,
index
)
=>
{
let
JDXJ_DATA_FILE_NAME
=
`
${
userName
}
_JDXJ_
${
timeStr
}
_
${
index
}
.txt`
;
...
...
pages/shaftInspection/shaftInspectionList.vue
浏览文件 @
c9f2531d
...
...
@@ -120,7 +120,8 @@
v-if=
"position.status == 2"
class=
"iconfont icon-shibai1"
></text>
<text
class=
"status-text"
>
{{
position
.
statusLable
}}
</text>
<text
v-if=
"position.isSubmit === 0"
class=
"status-text"
>
草稿
</text>
<text
v-else
class=
"status-text"
>
{{
position
.
statusLable
}}
</text>
</view>
<view
class=
"info-line"
>
<text
class=
"info-text"
...
...
@@ -182,7 +183,8 @@
v-if=
"position.status == 2"
class=
"iconfont icon-shibai1"
></text>
<text
class=
"status-text"
>
{{
position
.
statusLable
}}
</text>
<text
v-if=
"position.isSubmit === 0"
class=
"status-text"
>
草稿
</text>
<text
v-else
class=
"status-text"
>
{{
position
.
statusLable
}}
</text>
</view>
<view
class=
"info-line"
>
<text
class=
"info-text"
...
...
@@ -389,7 +391,10 @@ export default {
}
this
.
inspectionCode
=
detailsInfo
.
inspectionCode
;
// this.cardsInfo = this.tabList = detailsInfo.originData;
this
.
isSubmit
=
this
.
detailsInfo
.
isSubmit
;
this
.
isSubmit
=
this
.
detailsInfo
.
originData
.
reduce
((
acc
,
cur
)
=>
{
acc
.
push
(...
cur
.
position
)
return
acc
},
[]).
every
(
pos
=>
pos
.
isSubmit
===
''
||
pos
.
isSubmit
===
1
);
this
.
isSign
=
!!
this
.
detailsInfo
.
signImg
;
this
.
cardsInfo
.
forEach
((
item
)
=>
{
this
.
tabs
.
push
(
item
.
name
);
...
...
pages/shaftInspection/shared.js
浏览文件 @
c9f2531d
...
...
@@ -3,18 +3,29 @@ import store from "@/store";
// 将现有机房巡检数据转换为SQL数据所需要格式
export
function
dataToSql
(
data
)
{
let
synFlag
=
0
;
if
(
data
.
isSubmit
==
0
)
{
synFlag
=
0
;
let
synFlag
=
0
,
isException
=
data
.
isException
;
// 是否有草稿状态的井道
let
hasDraft
;
hasDraft
=
!
(
data
.
originData
.
reduce
((
acc
,
cur
)
=>
{
acc
.
push
(...
cur
.
position
)
return
acc
},
[]).
every
(
pos
=>
pos
.
isSubmit
===
''
||
pos
.
isSubmit
===
1
))
if
(
data
.
synchronization
===
1
)
{
synFlag
=
1
;
}
else
{
synFlag
=
data
.
synchronization
;
if
(
hasDraft
)
{
synFlag
=
2
isException
=
2
}
else
{
synFlag
=
0
}
}
const
send
=
{
inspectionType
:
data
.
inspectionType
,
inspectionCode
:
data
.
inspectionCode
,
recordName
:
`
${
moment
().
format
(
"yyyyMMDD"
)}
-井道巡检`
,
inspectionTime
:
moment
().
format
(
"yyyy-MM-DD HH:mm"
),
isException
:
data
.
isException
,
// 是否异常:0 否 1 是 2 巡检中
isException
:
isException
,
// 是否异常:0 否 1 是 2 巡检中
userId
:
store
.
state
.
now_user
.
userId
,
userName
:
store
.
state
.
now_user
.
user
,
synFlag
:
synFlag
,
// 0.未同步,1.已同步,2.编辑
...
...
@@ -42,11 +53,10 @@ export function sqlToData(sqlData) {
synchronization
=
sqlData
.
synFlag
;
}
const
originData
=
JSON
.
parse
(
sqlData
.
inspectionData
||
"{}"
);
console
.
log
(
originData
)
const
inspectedItems
=
originData
.
reduce
((
acc
,
cur
)
=>
{
acc
.
push
(...
cur
.
position
)
return
acc
},
[]).
filter
((
item
)
=>
item
.
status
==
1
||
item
.
status
==
2
)
},
[]).
filter
((
item
)
=>
(
item
.
status
==
1
||
item
.
status
==
2
)
&&
item
.
isSubmit
!==
0
)
console
.
log
(
inspectedItems
)
// 获取已经巡检过的数量
...
...
utils/dict.js
浏览文件 @
c9f2531d
...
...
@@ -1085,7 +1085,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1105,7 +1105,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1125,7 +1125,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1145,7 +1145,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1165,7 +1165,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
//数据
isSubmit
:
0
,
//提交状态
isSubmit
:
''
,
//提交状态
},
{
createBy
:
"admin"
,
...
...
@@ -1185,7 +1185,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1205,7 +1205,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1225,7 +1225,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1245,7 +1245,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1265,7 +1265,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1285,7 +1285,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1305,7 +1305,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
{
createBy
:
"admin"
,
...
...
@@ -1325,7 +1325,7 @@ export const pad_2_1_floor = {
default
:
false
,
statusLable
:
"未巡检"
,
details
:
[],
isSubmit
:
0
,
isSubmit
:
''
,
},
],
};
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论