Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-customer-new-master
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
lanbaoming
jiedao-app-customer-new-master
Commits
705399ca
Commit
705399ca
authored
Jan 14, 2025
by
Smile
Committed by
wux
Jan 21, 2025
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
任务88:客户端改造,版本强制更新,当用户未安装最新版本,更新弹窗无法关闭,但是添加了退出应用按钮
parent
40b8e5a5
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
4 deletions
+29
-4
index.vue
src/pages/index/index.vue
+13
-2
login.vue
src/pages/login/login.vue
+13
-2
notices.js
src/static/lang/en/notices.js
+1
-0
notices.js
src/static/lang/fr/notices.js
+1
-0
notices.js
src/static/lang/zh/notices.js
+1
-0
No files found.
src/pages/index/index.vue
View file @
705399ca
...
...
@@ -219,6 +219,9 @@
<view
class=
"ad-btn"
@
click=
"toupdate"
>
<view>
{{ $lang.lang.notices.update }}
</view>
</view>
<view
class=
"ad-btn"
v-if=
"forceUpdate"
@
click=
"toCloseApp"
>
<view>
{{ $lang.lang.notices.closeApp }}
</view>
</view>
<view
v-if=
"!forceUpdate"
class=
"ad-btn"
@
click=
"closeVe"
>
<view>
{{ $lang.lang.notices.close }}
</view>
</view>
...
...
@@ -358,13 +361,13 @@ export default {
var
dtask
=
plus
.
downloader
.
createDownload
(
that
.
appUrl
,
{},
(
d
,
status
)
=>
{
uni
.
hideLoading
()
if
(
status
==
200
)
{
that
.
closeVe
()
//
that.closeVe()
that
.
showdownLine
=
false
console
.
log
(
'
下载成功安装:
'
+
d
.
filename
)
plus
.
runtime
.
install
(
d
.
filename
)
}
else
{
that
.
showdownLine
=
false
that
.
closeVe
()
//
that.closeVe()
plus
.
nativeUI
.
alert
(
that
.
$lang
.
lang
.
notices
.
failDown
)
}
})
...
...
@@ -581,6 +584,14 @@ export default {
this
.
$refs
.
vepopup
.
close
()
// this.getUserInfo()
},
toCloseApp
()
{
if
(
platform
==
'
ios
'
)
{
//ios使用原来的quit()方法失效
plus
.
ios
.
import
(
"
UIApplication
"
).
sharedApplication
().
performSelector
(
"
exit
"
)
}
else
{
plus
.
runtime
.
quit
();
}
},
getBanner
()
{
this
.
$request
.
get
(
'
/app-api/ecw/banner/page
'
,
{
page
:
1
,
rows
:
20
,
status
:
0
})
...
...
src/pages/login/login.vue
View file @
705399ca
...
...
@@ -140,6 +140,9 @@
<view
class=
"ad-btn"
@
click=
"toupdate"
>
<view>
{{
$lang
.
lang
.
notices
.
update
}}
</view>
</view>
<view
class=
"ad-btn"
v-if=
"forceUpdate"
@
click=
"toCloseApp"
>
<view>
{{
$lang
.
lang
.
notices
.
closeApp
}}
</view>
</view>
<view
v-if=
"!forceUpdate"
class=
"ad-btn"
@
click=
"closeVe"
>
<view>
{{
$lang
.
lang
.
notices
.
close
}}
</view>
</view>
...
...
@@ -377,13 +380,13 @@ export default {
var
dtask
=
plus
.
downloader
.
createDownload
(
that
.
appUrl
,
{},
(
d
,
status
)
=>
{
uni
.
hideLoading
()
if
(
status
==
200
)
{
that
.
closeVe
()
//
that.closeVe()
that
.
showdownLine
=
false
console
.
log
(
'
下载成功安装:
'
+
d
.
filename
)
plus
.
runtime
.
install
(
d
.
filename
)
}
else
{
that
.
showdownLine
=
false
that
.
closeVe
()
//
that.closeVe()
plus
.
nativeUI
.
alert
(
that
.
$lang
.
lang
.
notices
.
failDown
)
}
})
...
...
@@ -446,6 +449,14 @@ export default {
closeVe
()
{
this
.
$refs
.
vepopup
.
close
()
},
toCloseApp
()
{
let
platform
=
uni
.
getSystemInfoSync
().
platform
.
toLocaleLowerCase
()
if
(
platform
==
'
ios
'
)
{
plus
.
ios
.
import
(
"
UIApplication
"
).
sharedApplication
().
performSelector
(
"
exit
"
)
}
else
{
plus
.
runtime
.
quit
();
}
},
// 获取个人信息
async
getUserInfo
()
{
try
{
...
...
src/static/lang/en/notices.js
View file @
705399ca
...
...
@@ -108,6 +108,7 @@ export default {
"
intNotice5
"
:
"
Value>0
"
,
"
easyPass
"
:
"
Your password is too simple, please change your password
"
,
"
update
"
:
"
Update now
"
,
"
closeApp
"
:
"
Close the app
"
,
"
close
"
:
"
Close
"
,
"
newVersion
"
:
"
New Version update
"
,
"
nowVersion
"
:
"
NowVersion
"
,
...
...
src/static/lang/fr/notices.js
View file @
705399ca
...
...
@@ -108,6 +108,7 @@ export default {
"
intNotice5
"
:
"
valeur > 0
"
,
"
easyPass
"
:
"
Votre mot de passe est trop simple, veuillez le modifier
"
,
"
update
"
:
"
mettre à jour maintenant
"
,
"
closeApp
"
:
"
Fermer l'application
"
,
"
close
"
:
"
fermer
"
,
"
newVersion
"
:
"
mise à jour de la nouvelle version
"
,
"
nowVersion
"
:
"
version actuelle
"
,
...
...
src/static/lang/zh/notices.js
View file @
705399ca
...
...
@@ -108,6 +108,7 @@ export default {
"
intNotice5
"
:
"
货值必须大于0
"
,
"
easyPass
"
:
"
您的密码过于简单,请前往修改密码
"
,
"
update
"
:
"
立即更新
"
,
"
closeApp
"
:
"
关闭应用
"
,
"
close
"
:
"
关闭弹窗
"
,
"
newVersion
"
:
"
新版本更新
"
,
"
nowVersion
"
:
"
当前版本号
"
,
...
...
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