Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
DoorLock
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
felix
DoorLock
Commits
c6e15c32
Commit
c6e15c32
authored
Jan 12, 2018
by
朱建香
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2018/01/12 19:14
1.notify组件优化 2.关联开锁ID也页面html添加
parent
37ec32c1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
8 deletions
+29
-8
dev/src/view/c_android-notify.vue
+27
-8
web/view/doorlockUsers/addUnlockInfo.html
+2
-0
No files found.
dev/src/view/c_android-notify.vue
View file @
c6e15c32
...
...
@@ -78,21 +78,28 @@
endSetting
:
Vue
.
t
(
'androidNotify.endSetting'
),
toAppIndex
:
Vue
.
t
(
'androidNotify.toIndex'
),
notifyState
:
false
,
// 当前是否开启了通知
gotoIndex
:
this
.
toIndex
,
// 处理点击到index按钮事件
isKnow
:
iot
.
native
.
isNotifycationOpen
(),
//是否需要显示 我已阅读
isToIndex
:
false
,
// 是否需要显示去首页按钮
//
notifyState:false, // 当前是否开启了通知
//
gotoIndex:this.toIndex,// 处理点击到index按钮事件
//
isKnow:iot.native.isNotifycationOpen(),//是否需要显示 我已阅读
//
isToIndex:false,// 是否需要显示去首页按钮
isStep1Finish
:
iot
.
native
.
isNotifycationOpen
(),
//是否需要显示步骤1的勾
isStep2Finish
:
false
,
//是否需要显示步骤2的勾
isStep3Finish
:
false
,
//是否需要显示步骤3的勾
isToSetting
:
!
iot
.
native
.
isNotifycationOpen
(),
//是否需要显示去设置按钮
setp1Active
:
'active'
,
setp1Active
:
null
,
setp2Active
:
null
,
// 默认为灰色 不显示active
setp3Active
:
null
,
notifyState
:
false
,
// 当前是否开启了通知
gotoIndex
:
this
.
toIndex
,
// 处理点击到index按钮事件
isKnow
:
iot
.
native
.
isNotifycationOpen
(),
//是否需要显示 我已阅读
isToIndex
:
false
,
// 是否需要显示去首页按钮
}
},
mounted
:
function
()
{
console
.
log
(
"notifyState:"
+
iot
.
native
.
isNotifycationOpen
())
this
.
setp1Active
=
this
.
isStep1Finish
?
"active changeBorder"
:
null
;
this
.
setp2Active
=
this
.
isStep1Finish
?
"active changeBorder"
:
null
;
console
.
log
(
"notifyState:"
+
iot
.
native
.
isNotifycationOpen
());
onTest
(
this
);
// 监听程序恢复前台
document
.
addEventListener
(
"resume"
,
()
=>
{
onAppReume
(
this
);
...
...
@@ -116,6 +123,10 @@
}
};
function
onTest
(
self
){
console
.
log
(
self
.
isStep1Finish
);
console
.
log
(
self
.
setp2Active
);
}
function
openNotify
(
self
)
{
console
.
log
(
"去开启"
);
iot
.
native
.
toNotifycationSetting
(
"notify"
);
...
...
@@ -125,7 +136,7 @@
function
IKonw
(
self
){
console
.
log
(
"点击了我已阅读"
);
self
.
isStep2Finish
=
true
;
// 点击阅读后显示步骤2的勾
self
.
setp2Active
=
"active changeBorder"
;
// 点击阅读后显示步骤2的字体亮度调高
//
self.setp2Active = "active changeBorder";// 点击阅读后显示步骤2的字体亮度调高
self
.
setp3Active
=
"active"
;
// 同时步骤3的字体亮度也调高
self
.
isStep3Finish
=
true
;
// 步骤3的勾勾选
self
.
isToIndex
=
true
;
//显示去首页按钮
...
...
@@ -140,7 +151,15 @@
function
onAppReume
(
self
){
let
notifyState
=
iot
.
native
.
isNotifycationOpen
();
console
.
log
(
"notifyState:"
+
notifyState
);
if
(
notifyState
)
{
self
.
setp2Active
=
"active changeBorder"
;}
if
(
notifyState
)
{
self
.
setp2Active
=
"active changeBorder"
;
}
else
{
// 恢复默认
self
.
setp2Active
=
null
;
self
.
setp3Active
=
null
;
self
.
isStep2Finish
=
false
;
self
.
isStep3Finish
=
false
;
self
.
isToIndex
=
false
;
}
self
.
isStep1Finish
=
iot
.
native
.
isNotifycationOpen
();
// 再次判断当前通知是否开启
self
.
isToSetting
=
!
iot
.
native
.
isNotifycationOpen
();
// 再次判断是否需要显示去设置按钮
self
.
isKnow
=
iot
.
native
.
isNotifycationOpen
(),
// 再次判断是否需要显示 我已阅读
...
...
web/view/doorlockUsers/addUnlockInfo.html
View file @
c6e15c32
...
...
@@ -37,10 +37,12 @@
<p
class=
"title"
>
{{ $t('addUnlockInfo.opendoorRecord') }}
</p>
<u-select
ref=
"uselect"
:value=
"recordSelectIndex"
:init-param=
"componentsConfig.recordSelect.initParam"
v-on:u-select-change=
"onRecordSelectChange(arguments[0])"
></u-select>
<div
class=
"position"
>
<p
class=
"tip"
>
{{ $t('addUnlockInfo.tip') }}
</p>
<u-switch
:value=
"valueSetHijack"
v-show=
"recordSelectList.length && selectedMode == 2"
:init-param=
"componentsConfig.setHijackSwitch.initParam"
v-on:u-switch-tap=
"onSetHijackTap(arguments[0])"
></u-switch>
</div>
</div>
<u-button
:init-param=
"componentsConfig.addButton.initParam"
:disabled=
"!recordSelectList.length"
v-on:u-button-tap=
"onAddButtonTap"
></u-button>
</div>
<transition
name=
"fade"
>
...
...
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