Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
tianhong2.1xcx
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
xinzhedeai
tianhong2.1xcx
Commits
2b3f20c1
Commit
2b3f20c1
authored
May 08, 2025
by
xinzhedeai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
天虹小程序 init lcl-v1 可用版
parent
6a1334d6
Pipeline
#507
failed with stages
Changes
7
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
58 additions
and
21 deletions
+58
-21
dangeredit.js
pages/dangeredit/dangeredit.js
+2
-0
dangerregister.js
pages/dangerregister/dangerregister.js
+44
-9
dangerregister.wxml
pages/dangerregister/dangerregister.wxml
+6
-2
enterprise.wxss
pages/enterprise/enterprise.wxss
+3
-7
home.wxml
pages/home/home.wxml
+1
-1
project.config.json
project.config.json
+1
-1
project.private.config.json
project.private.config.json
+1
-1
No files found.
pages/dangeredit/dangeredit.js
View file @
2b3f20c1
...
...
@@ -276,6 +276,7 @@ Page({
delete
formData
.
imgrecturl
delete
formData
.
hdFilePath
delete
formData
.
rectFilePath
delete
formData
.
entryDate
if
(
!
formData
.
hdInspectDate
)
{
delete
formData
.
hdInspectDate
}
...
...
@@ -350,6 +351,7 @@ Page({
delete
formData
.
imgrecturl
delete
formData
.
hdFilePath
delete
formData
.
rectFilePath
delete
formData
.
entryDate
if
(
!
formData
.
hdInspectDate
)
{
delete
formData
.
hdInspectDate
}
...
...
pages/dangerregister/dangerregister.js
View file @
2b3f20c1
...
...
@@ -70,14 +70,22 @@ Page({
recDeadLine
:
''
,
// 整改评价
recEvaluation
:
''
,
//录入日期
entryDate
:
'
xcx
'
,
},
/**
* 生命周期函数--监听页面加载
*/
onLoad
:
function
(
options
)
{
this
.
data
.
companyId
=
app
.
globalData
.
currentEnter
.
companyId
console
.
log
(
this
.
data
,
this
.
data
.
comment
,
11111111111111
)
this
.
data
.
companyId
=
app
.
globalData
.
currentEnter
.
companyId
;
console
.
log
(
this
.
formatDate
())
const
hdInspect
=
this
.
formatDate
()
this
.
setData
({
hdInspectDate
:
hdInspect
})
},
/**
...
...
@@ -91,6 +99,7 @@ Page({
* 生命周期函数--监听页面显示
*/
onShow
:
function
()
{
wx
.
setNavigationBarTitle
({
title
:
'
新增隐患
'
,
})
...
...
@@ -152,6 +161,28 @@ Page({
*/
onShareAppMessage
:
function
()
{
},
formatDate
()
{
const
date
=
new
Date
();
const
year
=
date
.
getFullYear
();
const
month
=
String
(
date
.
getMonth
()
+
1
).
padStart
(
2
,
"
0
"
);
const
day
=
String
(
date
.
getDate
()).
padStart
(
2
,
"
0
"
);
const
hours
=
String
(
date
.
getHours
()).
padStart
(
2
,
'
0
'
);
const
minutes
=
String
(
date
.
getMinutes
()).
padStart
(
2
,
'
0
'
);
const
seconds
=
String
(
date
.
getSeconds
()).
padStart
(
2
,
'
0
'
);
return
`
${
year
}
-
${
month
}
-
${
day
}
${
hours
}
:
${
minutes
}
:
${
seconds
}
`
;
},
formatDate1
()
{
const
date
=
new
Date
();
const
year
=
date
.
getFullYear
();
const
month
=
String
(
date
.
getMonth
()
+
1
).
padStart
(
2
,
'
0
'
);
const
day
=
String
(
date
.
getDate
()).
padStart
(
2
,
'
0
'
);
const
hours
=
String
(
date
.
getHours
()).
padStart
(
2
,
'
0
'
);
const
minutes
=
String
(
date
.
getMinutes
()).
padStart
(
2
,
'
0
'
);
const
seconds
=
String
(
date
.
getSeconds
()).
padStart
(
2
,
'
0
'
);
return
`
${
year
}
-
${
month
}
-
${
day
}
${
hours
}
:
${
minutes
}
:
${
seconds
}
`
;
},
//安全类别
chooseSecType
(
e
){
...
...
@@ -270,7 +301,7 @@ Page({
this
.
setData
({
hdName
:
this
.
data
.
hdName
,
basis
:
this
.
data
.
secCheckDiscover
[
event
.
detail
.
value
].
basis
,
suggestion
:
this
.
data
.
secCheckDiscover
[
event
.
detail
.
value
].
suggestion
//
suggestion: this.data.secCheckDiscover[event.detail.value].suggestion
})
},
/**
...
...
@@ -397,7 +428,12 @@ Page({
},
// 提交隐患
submitDanger
()
{
console
.
log
(
this
.
data
.
comment
,
this
.
data
.
imgrecturl
,
'
this.data.comment
'
)
const
entryDate
=
this
.
formatDate1
()
this
.
setData
({
entryDate
:
entryDate
})
console
.
log
(
this
.
data
,
'
this.data
'
)
if
(
this
.
data
.
comment
===
""
||
this
.
data
.
comment
===
undefined
||
this
.
data
.
comment
===
null
||
this
.
data
.
comment
.
trim
().
length
===
0
||
/^
\r
*$/
.
test
(
this
.
data
.
comment
))
{
wx
.
showToast
({
title
:
'
未填写隐患描述
'
,
...
...
@@ -443,7 +479,7 @@ Page({
delete
formData
.
comment
}
if
(
formData
.
hdInspectDate
)
{
formData
.
hdInspectDate
+=
'
00:00:00
'
formData
.
hdInspectDate
}
else
{
delete
formData
.
hdInspectDate
}
...
...
@@ -454,7 +490,7 @@ Page({
delete
formData
.
hdRectificationDate
}
console
.
log
(
formData
,
'
formData
'
)
wx
.
uploadFile
({
filePath
:
this
.
data
.
hdFilePath
,
name
:
'
hdPic
'
,
...
...
@@ -516,7 +552,7 @@ Page({
delete
formData
.
hdFilePath
delete
formData
.
rectFilePath
if
(
formData
.
hdInspectDate
)
{
formData
.
hdInspectDate
+=
'
00:00:00
'
formData
.
hdInspectDate
}
else
{
delete
formData
.
hdInspectDate
}
...
...
@@ -539,7 +575,6 @@ Page({
},
data
:
this
.
formatFormData
(
formData
),
success
:
(
res
)
=>
{
console
.
log
(
res
,
'
上传成功了吗afhdhsfhhdsfhadsf
'
)
if
(
res
.
statusCode
===
201
)
{
wx
.
showToast
({
title
:
'
上传成功
'
,
...
...
pages/dangerregister/dangerregister.wxml
View file @
2b3f20c1
...
...
@@ -3,11 +3,15 @@
<view class="danger-form-wrapper">
<view class="danger-check-date">
<text>检查日期:</text>
<picker class="danger-pick-date" mode="date" value="{{hdInspectDate}}" bindchange="selectCheckDate">
<
!-- <
picker class="danger-pick-date" mode="date" value="{{hdInspectDate}}" bindchange="selectCheckDate">
<view class="current-picker">
当前选择: {{hdInspectDate}}
</view>
</picker>
</picker> -->
<view class="current-picker">
{{hdInspectDate}}
</view>
</view>
<view class="danger-expert">
...
...
pages/enterprise/enterprise.wxss
View file @
2b3f20c1
...
...
@@ -65,13 +65,9 @@
box-shadow: 1rpx 2rpx 2rpx 2rpx #eee, -1rpx -1rpx 0.5rpx 0.5rpx #eee;
}
.company-name {
display: flex;
font-size: 36rpx;
line-height: 29rpx;
height: 50rpx;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
justify-content: start;
}
.company-per {
margin-top: 15rpx;
...
...
pages/home/home.wxml
View file @
2b3f20c1
...
...
@@ -17,7 +17,7 @@
<view class="info-card-icon law-icon"></view>
</view>
<view class="info-card info-right advice-wrapper" bindtap="linkToAdvice">
<view class="info-card-title">
通知公告
</view>
<view class="info-card-title">
重要工作部署
</view>
<view class="info-card-icon advice-icon"></view>
</view>
</view>
...
...
project.config.json
View file @
2b3f20c1
...
...
@@ -44,7 +44,7 @@
},
"compileType"
:
"miniprogram"
,
"libVersion"
:
"2.18.0"
,
"appid"
:
"wx
e009b5c8f819efb8
"
,
"appid"
:
"wx
1f2b920d2d2232e0
"
,
"projectname"
:
"%E5%A4%A9%E5%BC%98%E8%B4%A8%E9%87%8F%E6%A3%80%E6%B5%8B"
,
"condition"
:
{
"search"
:
{
...
...
project.private.config.json
View file @
2b3f20c1
...
...
@@ -7,7 +7,7 @@
"list"
:
[
{
"name"
:
"pages/person/person"
,
"pathName"
:
"pages/
person/person
"
,
"pathName"
:
"pages/
dangerregister/dangerregister
"
,
"query"
:
""
,
"launchMode"
:
"default"
,
"scene"
:
null
...
...
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