Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mingPayMobile
Overview
Overview
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
fengzhaoyu
mingPayMobile
Commits
e98ae274
Commit
e98ae274
authored
Nov 28, 2019
by
fengzhaoyu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
访客“
git push git push origin dev git add . git commit -m访客修复“
parent
60aa7fdf
Show whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
79 additions
and
39 deletions
+79
-39
http.js
API/http.js
+4
-1
allowanceList.js
pages/allowanceList/allowanceList.js
+1
-0
historyVistiors.acss
pages/historyVistiors/historyVistiors.acss
+7
-1
historyVistiors.axml
pages/historyVistiors/historyVistiors.axml
+2
-1
historyVistiors.js
pages/historyVistiors/historyVistiors.js
+1
-3
historyVistiors.json
pages/historyVistiors/historyVistiors.json
+2
-2
reservations.acss
pages/reservations/reservations.acss
+7
-6
reservations.axml
pages/reservations/reservations.axml
+2
-1
reservations.js
pages/reservations/reservations.js
+24
-13
visitors.acss
pages/visitors/visitors.acss
+3
-0
visitors.axml
pages/visitors/visitors.axml
+1
-1
visitors.js
pages/visitors/visitors.js
+15
-6
visitorsDetail.acss
pages/visitorsDetail/visitorsDetail.acss
+7
-1
visitorsDetail.json
pages/visitorsDetail/visitorsDetail.json
+2
-2
socket.js
utils/socket.js
+1
-1
No files found.
API/http.js
View file @
e98ae274
...
...
@@ -28,10 +28,13 @@ const $http = (url, data, type, loadingType) => {
data
:
data
,
success
:
function
(
res
)
{
if
(
res
.
data
.
code
==
0
||
res
.
data
.
resultCode
===
0
)
{
console
.
log
(
1111
)
return
resolve
(
res
.
data
.
data
)
dd
.
hideLoading
()
}
else
if
(
res
.
data
.
code
==
401
)
{
console
.
log
(
222
)
dd
.
removeStorageSync
({
key
:
'token'
})
dd
.
hideLoading
()
dd
.
redirectTo
({
...
...
@@ -80,6 +83,7 @@ const $http = (url, data, type, loadingType) => {
fail
:
function
(
err
)
{
dd
.
hideLoading
()
if
(
err
.
status
==
426
)
{
console
.
log
(
1121229383
)
dd
.
removeStorageSync
({
key
:
'token'
})
dd
.
redirectTo
({
url
:
'/pages/reTry/reTry'
...
...
@@ -143,7 +147,6 @@ const $http = (url, data, type, loadingType) => {
})
},
fail
:
function
(
err
)
{
debugger
if
(
err
.
status
==
426
)
{
dd
.
hideLoading
()
dd
.
removeStorageSync
({
...
...
pages/allowanceList/allowanceList.js
View file @
e98ae274
...
...
@@ -8,6 +8,7 @@ Page({
currentPage
:
1
,
pageNumber
:
10
,
totalCount
:
''
},
onLoad
(
query
)
{
dd
.
setNavigationBar
({
title
:
'津贴列表'
});
...
...
pages/historyVistiors/historyVistiors.acss
View file @
e98ae274
...
...
@@ -101,7 +101,7 @@
width: 40rpx;
height: 40rpx;
border-radius: 50%;
border: 2rpx solid #
DADADE
;
border: 2rpx solid #
3296FA
;
text-align: center;
line-height: 40rpx;
color: white;
...
...
@@ -196,3 +196,8 @@
line-height: 96rpx;
color: white;
}
.empty {
height: 160rpx;
width: 750rpx;
background: #fafafa;
}
\ No newline at end of file
pages/historyVistiors/historyVistiors.axml
View file @
e98ae274
...
...
@@ -22,11 +22,12 @@
</view>
<view>
<view class="time">
2019-10-27 17:41
{{item.startTime.allTime}}
</view>
<view class="byVisitor">被访人:{{item.byVisitorName}}</view>
</view>
</view>
<view class="empty"></view>
<view class="button">
<view onTap="confirm">确认选择</view>
</view>
...
...
pages/historyVistiors/historyVistiors.js
View file @
e98ae274
...
...
@@ -35,7 +35,6 @@ create.Page({
$http
.
$http
(
'/admin/visitor/getRecordList'
,
data
,
'post'
).
then
(
res
=>
{
let
dataList
=
res
.
records
;
let
dataListSource
=
_that
.
data
.
dataList
;;
console
.
log
(
dataList
.
length
)
if
(
dataList
.
length
>
0
)
{
dataList
.
forEach
((
item
,
index
)
=>
{
if
(
new
Date
(
item
.
endTime
.
replace
(
/
\-
/g
,
"/"
)).
getTime
()
<
new
Date
().
getTime
())
{
...
...
@@ -81,14 +80,13 @@ create.Page({
minute
:
minute
.
toString
().
length
>
1
?
minute
:
'0'
+
minute
,
yearMonthDate
:
`
${
year
}
年
${
month
.
toString
().
length
>
1
?
month
:
'0'
+
month
}
月
${
date
.
toString
().
length
>
1
?
date
:
'0'
+
date
}
日`
,
hourMinute
:
`
${
hour
.
toString
().
length
>
1
?
hour
:
'0'
+
hour
}
:
${
minute
.
toString
().
length
>
1
?
minute
:
'0'
+
minute
}
`
,
allTime
:
`
${
year
}
年
${
month
.
toString
().
length
>
1
?
month
:
'0'
+
month
}
月
${
date
.
toString
().
length
>
1
?
date
:
'0'
+
date
}
日
${
hour
.
toString
().
length
>
1
?
hour
:
'0'
+
hour
}
:
${
minute
.
toString
().
length
>
1
?
minute
:
'0'
+
minute
}
分
`
allTime
:
`
${
year
}
-
${
month
.
toString
().
length
>
1
?
month
:
'0'
+
month
}
-
${
date
.
toString
().
length
>
1
?
date
:
'0'
+
date
}
${
hour
.
toString
().
length
>
1
?
hour
:
'0'
+
hour
}
:
${
minute
.
toString
().
length
>
1
?
minute
:
'0'
+
minute
}
`
}
},
onLoad
(
query
)
{
dd
.
setNavigationBar
({
title
:
'历史访客'
,
});
console
.
log
(
this
.
store
.
data
.
visitorPeer
)
this
.
setData
({
index
:
query
.
index
,
dataList
:
[]
...
...
pages/historyVistiors/historyVistiors.json
View file @
e98ae274
{}
\ No newline at end of file
{
"pullRefresh"
:
false
}
\ No newline at end of file
pages/reservations/reservations.acss
View file @
e98ae274
...
...
@@ -34,7 +34,6 @@
.visitorName {
padding: 0 32rpx;
width: 684rpx;
height: 112rpx;
line-height: 112rpx;
background: white;
...
...
@@ -65,6 +64,7 @@
}
.visitorInput input {
padding: 0;
letter-spacing: -0.48rpx;
display: inline-block;
vertical-align: middle;
...
...
@@ -171,12 +171,12 @@
}
.purposeContent {
text-indent: 4rpx;
width: 50%;
color: #191F25;
opacity: 0.8rpx;
letter-spacing: -0.48rpx;
font-size: 30rpx;
margin-left: 55rpx;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
...
...
@@ -210,7 +210,7 @@
}
.inputPurpose {
width:
49
0rpx;
width:
51
0rpx;
float: right;
height: 110rpx;
line-height: 110rpx;
...
...
@@ -219,6 +219,7 @@
}
.inputPurpose input {
padding: 0;
font-size: 30rpx;
line-height: 110rpx;
vertical-align: middle;
...
...
@@ -245,13 +246,12 @@
}
.addressDetail {
width:
482rpx
;
width:
50%
;
height: auto;
line-height: 40rpx;
font-size: 30rpx;
color: #191F25;
opacity: 0.8;
margin-left: 20rpx;
display: -webkit-box;
overflow: hidden;
text-overflow: ellipsis;
...
...
@@ -387,8 +387,9 @@
align-items: center;
}
.ccPeople view {
.ccPeople view
,.ccPeople image
{
position: relative;
line-height: 100rpx;
height: 100rpx;
width: 100rpx;
border-radius: 50%;
...
...
pages/reservations/reservations.axml
View file @
e98ae274
...
...
@@ -121,7 +121,8 @@
</view>
<view class="ccPeople" a:if='{{copyPerson.length}}'>
<view a:for="{{copyPerson}}" a:for-index="index" a:for-item="item">
{{item.name.substring(item.name.length-2)}}
<image a:if="{{item.avatar}}" mode="scaleToFill" src="{{item.avatar || '../../../assets/avatar.png'}}"/>
<view a:else="{{!item.avatar}}">{{item.name.substring(item.name.length - 2,item.name.length)}}</view>
<text class="iconshanchu iconfont ccPeopleShanChu" data-index='{{index}}' onTap="deleateCcPeople"></text>
</view>
</view>
...
...
pages/reservations/reservations.js
View file @
e98ae274
...
...
@@ -25,8 +25,7 @@ create.Page({
visitorPurpose
:
''
,
// 访客手动输入的目的
visitorNode
:
''
,
// 访客的备注
isPackUp
:
false
,
// 是否收起更多消息
formValidation
:
false
,
selectVisitors
:
''
formValidation
:
false
},
onLoad
(
query
)
{
console
.
log
(
'onload'
)
...
...
@@ -105,12 +104,12 @@ create.Page({
console
.
log
(
_that
.
store
.
data
.
visitorPeer
[
event
.
currentTarget
.
dataset
.
index
-
1
])
_that
.
store
.
data
.
visitorPeer
[
event
.
currentTarget
.
dataset
.
index
-
1
].
name
=
event
.
detail
.
value
_that
.
store
.
data
.
visitorPeer
[
event
.
currentTarget
.
dataset
.
index
-
1
].
index
=
event
.
currentTarget
.
dataset
.
index
_that
.
update
_that
.
update
()
break
;
case
"visitorPeerPhone"
:
_that
.
store
.
data
.
visitorPeer
[
event
.
currentTarget
.
dataset
.
index
-
1
].
phone
=
event
.
detail
.
value
_that
.
store
.
data
.
visitorPeer
[
event
.
currentTarget
.
dataset
.
index
-
1
].
index
=
event
.
currentTarget
.
dataset
.
index
_that
.
update
_that
.
update
()
console
.
log
(
_that
.
store
.
data
.
visitorPeer
[
event
.
currentTarget
.
dataset
.
index
-
1
])
break
;
case
"visitorNode"
:
...
...
@@ -135,6 +134,8 @@ create.Page({
// 点击外部联系人
externalContactSelect
(
event
)
{
const
_that
=
this
_that
.
store
.
data
.
selectVisitors
=
false
_that
.
update
()
dd
.
chooseExternalUsers
({
title
:
'外部联人'
,
multiple
:
false
,
//是否多选 true多选,false单选,默认是单选
...
...
@@ -161,11 +162,17 @@ create.Page({
},
// 点击历史访客
historyVistiorsSelect
(
event
)
{
const
_that
=
this
_that
.
store
.
data
.
selectVisitors
=
false
_that
.
update
()
dd
.
navigateTo
({
url
:
`./../historyVistiors/historyVistiors?index=
${
this
.
data
.
index
}
`
});
},
// 点击手机通讯录
phoneAddressBookSelect
()
{
const
_that
=
this
_that
.
store
.
data
.
selectVisitors
=
false
_that
.
update
()
dd
.
choosePhonebook
({
title
:
'手机通讯录'
,
multiple
:
false
,
//是否多选: true多选 false单选; 默认true
...
...
@@ -252,8 +259,7 @@ create.Page({
content
:
'最多可选取6人'
,
buttonText
:
'确定'
})
}
},
}
},
// 周知人去重
duplicateRemoval
(
person
)
{
let
obj
=
{};
...
...
@@ -348,6 +354,11 @@ create.Page({
dd
.
alert
({
content
:
'结束时间不能早于开始时间'
,
buttonText
:
'确定'
})
return
}
else
if
(
new
Date
(
this
.
data
.
endTime
.
replace
(
/
\-
/g
,
"/"
)).
getTime
()
<
new
Date
().
getTime
())
{
dd
.
alert
({
content
:
'结束时间不能早于当前时间'
,
buttonText
:
'确定'
})
return
}
else
if
(
this
.
data
.
visitorPurpose
.
length
>
20
)
{
dd
.
alert
({
content
:
'来访目的的长度小于20个字符'
,
buttonText
:
'确定'
})
return
...
...
@@ -361,7 +372,7 @@ create.Page({
return
}
else
if
(
mobile
)
{
return
dd
.
alert
({
content
:
'访客手机号不能为空且长度小于1
0
个字符'
,
buttonText
:
'确定'
})
return
dd
.
alert
({
content
:
'访客手机号不能为空且长度小于1
1
个字符'
,
buttonText
:
'确定'
})
}
else
if
(
this
.
data
.
defaultAddress
==
''
)
{
return
dd
.
alert
({
content
:
'请选择或添加到访地址'
,
buttonText
:
'确定'
})
...
...
@@ -501,12 +512,12 @@ create.Page({
onShow
()
{
// 页面显示
// 关闭遮照层
cons
ole
.
log
(
this
.
store
.
data
)
this
.
store
.
data
.
selectVisitors
=
false
;
this
.
update
()
this
.
setData
({
selectVisitors
:
this
.
store
.
data
.
selectVisitors
})
cons
t
_that
=
this
setTimeout
(
function
(
res
)
{
_that
.
store
.
data
.
selectVisitors
=
false
;
_that
.
update
()
},
0.1
)
},
onHide
()
{
// 页面隐藏
...
...
pages/visitors/visitors.acss
View file @
e98ae274
...
...
@@ -184,10 +184,13 @@
.appointment {
padding: 16rpx 36rpx;
background: white;
position: absolute;
position: fixed;
bottom: 0;
left: 0;
right: 0;
transform: translateZ(0);
-webkit-transform: translateZ(0);
}
.appointmentButton {
...
...
pages/visitors/visitors.axml
View file @
e98ae274
...
...
@@ -7,7 +7,7 @@
<text>{{todayVisit}}</text>位访客,到访
<text>{{arrivedVisit}}</text>位
</view>
<view class="nullImage" a:if="{{
dataList.length === 0
}}">
<view class="nullImage" a:if="{{
isNull
}}">
<image mode="scaleToFill" src="../../../assets/noPermission.png"/>
<text>当前暂无访客记录</text>
</view>
...
...
pages/visitors/visitors.js
View file @
e98ae274
...
...
@@ -9,7 +9,8 @@ Page({
totalCount
:
''
,
overdue
:
false
,
todayVisit
:
0
,
arrivedVisit
:
0
arrivedVisit
:
0
,
isNull
:
true
// 列表默认为空
},
arriveStaus
(
self
)
{
const
_that
=
this
...
...
@@ -33,7 +34,7 @@ Page({
currentPage
:
1
})
this
.
visitorList
(
this
.
data
.
type
)
this
.
arriveStaus
(
this
.
data
.
typ
)
this
.
arriveStaus
(
this
.
data
.
typ
e
)
},
visitorList
(
type
)
{
const
_that
=
this
...
...
@@ -45,7 +46,6 @@ Page({
$http
.
$http
(
'/admin/visitor/getRecordList'
,
data
,
'post'
).
then
(
res
=>
{
let
dataList
=
res
.
records
;
let
dataListSource
=
_that
.
data
.
dataList
;;
console
.
log
(
dataList
.
length
)
if
(
dataList
.
length
>
0
)
{
dataList
.
forEach
((
item
,
index
)
=>
{
if
(
new
Date
(
item
.
endTime
.
replace
(
/
\-
/g
,
"/"
)).
getTime
()
<
new
Date
().
getTime
())
{
...
...
@@ -68,7 +68,15 @@ Page({
let
totalCount
=
Math
.
ceil
(
parseInt
(
res
.
total
)
/
_that
.
data
.
pageSize
)
_that
.
setData
({
dataList
:
dataList
,
totalCount
:
totalCount
totalCount
:
totalCount
,
isNull
:
false
})
}
else
{
_that
.
setData
({
dataList
:
[],
totalCount
:
1
,
isNull
:
true
})
}
})
...
...
@@ -117,7 +125,7 @@ Page({
this
.
resetData
()
dd
.
setNavigationBar
({
title
:
'智能访客'
});
this
.
visitorList
(
1
)
this
.
arriveStaus
(
0
)
this
.
arriveStaus
(
1
)
},
onReady
()
{
...
...
@@ -155,8 +163,9 @@ Page({
overdue
:
false
,
})
this
.
visitorList
(
this
.
data
.
type
)
this
.
arriveStaus
(
1
)
dd
.
stopPullDownRefresh
()
this
.
arriveStaus
()
},
onShareAppMessage
()
{
// 返回自定义分享信息
...
...
pages/visitorsDetail/visitorsDetail.acss
View file @
e98ae274
...
...
@@ -238,12 +238,17 @@ image {
.participatorUserList {
display: flex;
margin-top: 14rpx
;
flex-wrap: wrap
;
margin-left: 52rpx;
color: #000000;
font-size: 30rpx;
}
.participatorUserList:nth-child(6) {
margin-right: 0
}
.participatorUserListname {
margin-right: 20rpx;
margin-top: 14rpx;
}
\ No newline at end of file
pages/visitorsDetail/visitorsDetail.json
View file @
e98ae274
{}
\ No newline at end of file
{
"pullRefresh"
:
false
}
\ No newline at end of file
utils/socket.js
View file @
e98ae274
...
...
@@ -35,7 +35,7 @@ var webSocket = {
socketClose
=
false
socketMsgQueue
=
[]
dd
.
connectSocket
({
url
:
`wss://
mingpay-websocket.mingwork.com
/v1/mingpaywebsocket?param=
${
dd
.
corpId
}
_
${
dd
.
getStorageSync
({
key
:
'userId'
}).
data
}
`
,
url
:
`wss://
gateway-beta.mingwork.com/mingpay-phone-websocket
/v1/mingpaywebsocket?param=
${
dd
.
corpId
}
_
${
dd
.
getStorageSync
({
key
:
'userId'
}).
data
}
`
,
// url: `ws://192.168.1.102:8400/v1/mingpaywebsocket?param=${dd.corpId}_${dd.getStorageSync({ key: 'userId' }).data}`,
data
:
{
userType
:
0
...
...
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