Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
I
inspection-pad-web
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
专网
inspection-pad-web
Commits
25410e74
提交
25410e74
authored
4月 08, 2025
作者:
JaxBBLL
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix
上级
6ca835ae
显示空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
15 行增加
和
30 行删除
+15
-30
inspect.js
api/inspect.js
+7
-14
qt.vue
pages/inspectionContent/components/qt.vue
+3
-9
inspectionContentList.vue
pages/inspectionContent/inspectionContentList.vue
+1
-1
inspectionContentNew.vue
pages/inspectionContent/inspectionContentNew.vue
+3
-5
shared.js
pages/inspectionContent/shared.js
+1
-1
没有找到文件。
api/inspect.js
浏览文件 @
25410e74
import
SqlliteDbUtil
from
"@/utils/sqllitedb"
;
import
SqlliteDbUtil
from
"@/utils/sqllitedb"
;
import
table
from
"./sqllite/table.js"
;
import
table
from
"./sqllite/table.js"
;
import
{
import
{
fixNullVal
}
from
"@/utils/common"
;
fixNullVal
}
from
"@/utils/common"
;
// 巡检
// 巡检
export
default
{
export
default
{
...
@@ -18,7 +16,6 @@ export default {
...
@@ -18,7 +16,6 @@ export default {
}
finally
{
}
finally
{
await
sqllitedb
.
closeDB
();
await
sqllitedb
.
closeDB
();
}
}
},
},
async
selectDataForTime
()
{
async
selectDataForTime
()
{
let
sqllitedb
=
await
SqlliteDbUtil
.
initSqlliteDB
();
let
sqllitedb
=
await
SqlliteDbUtil
.
initSqlliteDB
();
...
@@ -32,14 +29,12 @@ export default {
...
@@ -32,14 +29,12 @@ export default {
}
finally
{
}
finally
{
await
sqllitedb
.
closeDB
();
await
sqllitedb
.
closeDB
();
}
}
},
},
async
info
(
id
)
{
async
info
(
id
)
{
let
sqllitedb
=
await
SqlliteDbUtil
.
initSqlliteDB
();
let
sqllitedb
=
await
SqlliteDbUtil
.
initSqlliteDB
();
try
{
try
{
let
sql
=
`select * from
${
table
.
inspectionRecordName
}
where id = '
${
id
}
'`
;
let
sql
=
`select * from
${
table
.
inspectionRecordName
}
where id = '
${
id
}
'`
;
let
res
=
await
sqllitedb
.
selectSQL
(
sql
);
let
res
=
await
sqllitedb
.
selectSQL
(
sql
);
debugger
;
if
(
res
&&
res
.
length
>
0
)
{
if
(
res
&&
res
.
length
>
0
)
{
return
res
[
0
];
return
res
[
0
];
}
}
...
@@ -48,7 +43,6 @@ export default {
...
@@ -48,7 +43,6 @@ export default {
}
finally
{
}
finally
{
await
sqllitedb
.
closeDB
();
await
sqllitedb
.
closeDB
();
}
}
},
},
async
remove
(
id
)
{
async
remove
(
id
)
{
if
(
!
id
)
{
if
(
!
id
)
{
...
@@ -63,7 +57,6 @@ export default {
...
@@ -63,7 +57,6 @@ export default {
}
finally
{
}
finally
{
await
sqllitedb
.
closeDB
();
await
sqllitedb
.
closeDB
();
}
}
},
},
async
saveBatch
(
list
)
{
async
saveBatch
(
list
)
{
if
(
list
.
length
===
0
)
{
if
(
list
.
length
===
0
)
{
...
@@ -90,12 +83,12 @@ export default {
...
@@ -90,12 +83,12 @@ export default {
idx
++
;
idx
++
;
}
}
column
=
column
.
endsWith
(
","
)
?
column
=
column
.
endsWith
(
","
)
column
.
substring
(
0
,
column
.
length
-
1
)
:
?
column
.
substring
(
0
,
column
.
length
-
1
)
column
;
:
column
;
values
=
values
.
endsWith
(
","
)
?
values
=
values
.
endsWith
(
","
)
values
.
substring
(
0
,
values
.
length
-
1
)
:
?
values
.
substring
(
0
,
values
.
length
-
1
)
values
;
:
values
;
let
sql
=
`insert into
${
table
.
inspectionRecordName
}
(
${
column
}
) values(
${
values
}
)`
;
let
sql
=
`insert into
${
table
.
inspectionRecordName
}
(
${
column
}
) values(
${
values
}
)`
;
let
has
=
await
this
.
info
(
data
.
id
);
let
has
=
await
this
.
info
(
data
.
id
);
...
...
pages/inspectionContent/components/qt.vue
浏览文件 @
25410e74
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
<CommonUpload
<CommonUpload
v-model=
"item.photos"
v-model=
"item.photos"
:max-count=
"9999"
:max-count=
"9999"
@
change
=
"onPhotoChange"
@
input
=
"onPhotoChange"
>
>
</CommonUpload>
</CommonUpload>
</view>
</view>
...
@@ -112,10 +112,7 @@ export default {
...
@@ -112,10 +112,7 @@ export default {
// 处理弹窗确认
// 处理弹窗确认
handlePopupConfirm
(
summary
)
{
handlePopupConfirm
(
summary
)
{
this
.
itemData
.
detail
[
this
.
currentIndex
].
conclusion
=
summary
;
// 回显到文字显示区域
this
.
itemData
.
detail
[
this
.
currentIndex
].
conclusion
=
summary
;
// 回显到文字显示区域
this
.
$emit
(
"sync"
,
{
this
.
$emit
(
"sync"
,
this
.
itemData
);
conclusion
:
summary
,
photos
:
this
.
itemData
.
detail
[
this
.
currentIndex
].
photos
,
});
},
},
// 处理】数据
// 处理】数据
getFromData
()
{
getFromData
()
{
...
@@ -163,10 +160,7 @@ export default {
...
@@ -163,10 +160,7 @@ export default {
},
},
onPhotoChange
(
val
)
{
onPhotoChange
(
val
)
{
this
.
itemData
.
detail
[
this
.
currentIndex
].
photos
=
val
;
this
.
itemData
.
detail
[
this
.
currentIndex
].
photos
=
val
;
this
.
$emit
(
"sync"
,
{
this
.
$emit
(
"sync"
,
this
.
itemData
);
conclusion
:
this
.
itemData
.
detail
[
this
.
currentIndex
].
conclusion
,
photos
:
val
,
});
},
},
},
},
};
};
...
...
pages/inspectionContent/inspectionContentList.vue
浏览文件 @
25410e74
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
<view
class=
"profile-left"
>
<view
class=
"profile-left"
>
<view
class=
"avatar"
>
<view
class=
"avatar"
>
<image
<image
src=
"@/static/img/add-img/
home1
.png"
src=
"@/static/img/add-img/
defaultAvatar
.png"
mode=
"aspectFit"
mode=
"aspectFit"
></image>
></image>
</view>
</view>
...
...
pages/inspectionContent/inspectionContentNew.vue
浏览文件 @
25410e74
...
@@ -761,12 +761,10 @@ export default {
...
@@ -761,12 +761,10 @@ export default {
this
.
switchTab
((
this
.
activeTab
+
1
)
%
this
.
tabs
.
length
);
this
.
switchTab
((
this
.
activeTab
+
1
)
%
this
.
tabs
.
length
);
},
},
setQtValue
(
data
)
{
setQtValue
(
data
)
{
console
.
log
(
"setQtValue"
,
data
);
this
.
detailsInfo
.
originData
.
forEach
((
item
)
=>
{
this
.
detailsInfo
.
originData
.
forEach
((
item
)
=>
{
if
(
item
.
details
&&
item
.
details
.
qt
&&
item
.
details
.
qt
.
detail
)
{
if
(
item
.
details
)
{
item
.
details
.
qt
.
detail
.
forEach
((
current
)
=>
{
item
.
details
.
qt
=
data
;
item
.
conclusion
=
data
.
conclusion
;
item
.
photos
=
data
.
photos
;
});
}
}
});
});
console
.
log
(
"setQtValue"
,
this
.
detailsInfo
);
console
.
log
(
"setQtValue"
,
this
.
detailsInfo
);
...
...
pages/inspectionContent/shared.js
浏览文件 @
25410e74
...
@@ -13,7 +13,7 @@ export function dataToSql(data) {
...
@@ -13,7 +13,7 @@ export function dataToSql(data) {
inspectionType
:
data
.
inspectionType
,
inspectionType
:
data
.
inspectionType
,
inspectionCode
:
data
.
inspectionCode
,
inspectionCode
:
data
.
inspectionCode
,
recordName
:
`
${
moment
().
format
(
"yyyyMMDD"
)}
-机房巡检`
,
recordName
:
`
${
moment
().
format
(
"yyyyMMDD"
)}
-机房巡检`
,
inspectionTime
:
moment
().
format
(
"yyyy-MM-DD HH:mm"
)
,
inspectionTime
:
`
${
new
Date
().
getTime
()}
`
,
isException
:
data
.
isException
,
// 是否异常:0 否 1 是 2 巡检中
isException
:
data
.
isException
,
// 是否异常:0 否 1 是 2 巡检中
userId
:
store
.
state
.
now_user
.
userId
,
userId
:
store
.
state
.
now_user
.
userId
,
userName
:
store
.
state
.
now_user
.
user
,
userName
:
store
.
state
.
now_user
.
user
,
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论