Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
U
uni-app-ddh-shop
Project
Project
Details
Activity
Releases
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
zhanhai
uni-app-ddh-shop
Commits
23be374d
Commit
23be374d
authored
Nov 11, 2024
by
caimeng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.0.5发布生产
parent
4c031cd0
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
34 additions
and
25 deletions
+34
-25
api.js
config/api.js
+2
-2
index.vue
pages/agreement/index.vue
+2
-11
index.vue
pages/index/index.vue
+9
-6
index.vue
pages/init/index.vue
+1
-2
index.vue
pages/starPage/index.vue
+1
-0
web.vue
pages/web/web.vue
+11
-0
websrc.vue
pages/web/websrc.vue
+8
-4
No files found.
config/api.js
View file @
23be374d
...
...
@@ -22,7 +22,7 @@ const BASE = {
prod
:
{
common
:
"https://api.yyhock.com"
,
event
:
'https://event.jqtianxia.com'
,
h5
:
'https://ddang.rockstect.com/
index
.html#/'
h5
:
'https://ddang.rockstect.com/
v1.0.5
.html#/'
}
}
let
env
=
process
.
env
.
VUE_APP_BASE_NODE_ENV
...
...
@@ -38,7 +38,7 @@ let env = process.env.VUE_APP_BASE_NODE_ENV
*/
// #ifdef APP-PLUS
env
=
"
stest
"
;
env
=
"
prod
"
;
// #endif
const
api
=
{
...
...
pages/agreement/index.vue
View file @
23be374d
...
...
@@ -32,7 +32,6 @@
</
template
>
<
script
>
import
{
ininIndex
,
initApp
,
initSettings
}
from
'@/utils/index'
export
default
{
name
:
"Agreement"
,
data
()
{
...
...
@@ -48,10 +47,7 @@ export default {
}
}
},
async
onLoad
()
{
await
ininIndex
()
await
initApp
()
await
initSettings
()
``
async
onShow
()
{
await
this
.
init
()
},
methods
:
{
...
...
@@ -141,12 +137,7 @@ export default {
})
}
},
async
onShow
()
{
await
this
.
init
()
await
ininIndex
()
await
initApp
()
await
initSettings
()
}
}
</
script
>
...
...
pages/index/index.vue
View file @
23be374d
...
...
@@ -56,7 +56,7 @@
<scroll-view
class=
'box-at-home'
scroll-y=
"true"
refresher-default-style=
"none"
@
scrolltoupper=
"toupperTop"
@
scrolltolower=
"lowerMore"
>
<view
class=
'main-box'
v-show=
"IndexList && IndexList.length > 0"
>
<view
class=
'box-item'
v-for=
"
item in IndexList"
:key=
"item.id
"
@
click=
"goDetail(item)"
>
<view
class=
'box-item'
v-for=
"
(item,index) in IndexList"
:key=
"index
"
@
click=
"goDetail(item)"
>
<view
class=
'item-top'
>
<image
:src=
"item.goodsImage"
class=
'top-img'
></image>
<i
class=
'top-icon'
></i>
...
...
@@ -91,13 +91,12 @@
<
script
>
import
{
isLogin
,
switchShowTabbar
,
ininIndex
}
from
'@/utils/index'
const
cacheIndexData
=
uni
.
getStorageSync
(
'dataIndex'
)
?
JSON
.
parse
(
uni
.
getStorageSync
(
'dataIndex'
))
:
null
;
const
indexGoods
=
uni
.
getStorageSync
(
'indexGoods'
)
?
JSON
.
parse
(
uni
.
getStorageSync
(
'indexGoods'
))
:
[];
export
default
{
data
()
{
return
{
IndexList
:
indexGoods
,
index
:
cacheIndexData
,
hotList
:
[
{
title
:
'浏览量'
,
id
:
0
},
{
title
:
'价格'
,
id
:
1
},
...
...
@@ -107,7 +106,7 @@ export default {
showUP
:
false
,
headerHeight
:
0
,
scrollTop
:
0
,
IndexList
:
[],
pageNum
:
1
,
...
...
@@ -190,7 +189,8 @@ export default {
const
self
=
this
uni
.
getSystemInfo
({
success
:
(
res
)
=>
{
const
appVersion
=
res
.
appVersion
console
.
log
(
res
,
'系统信息'
)
const
appVersion
=
res
.
appWgtVersion
let
platform
=
res
.
platform
;
// 获取本机版本号
let
type
;
...
...
@@ -310,6 +310,9 @@ export default {
}
else
{
self
.
IndexList
=
records
}
uni
.
setStorageSync
(
'indexGoods'
,
JSON
.
stringify
(
self
.
IndexList
))
self
.
hasNextPage
=
hasNextPage
self
.
loadFlag
=
false
}).
catch
(
err
=>
{
...
...
pages/init/index.vue
View file @
23be374d
...
...
@@ -3,8 +3,7 @@
<
script
>
export
default
{
async
onLoad
()
{
const
appStart
=
uni
.
getStorageSync
(
'appStart'
)
console
.
log
(
appStart
,
'ri '
)
const
appStart
=
uni
.
getStorageSync
(
'appStart'
)
if
(
appStart
)
{
uni
.
switchTab
({
url
:
"/pages/index/index"
...
...
pages/starPage/index.vue
View file @
23be374d
...
...
@@ -34,6 +34,7 @@ export default {
await
ininIndex
()
await
initSettings
()
await
initApp
()
if
(
uni
.
getStorageSync
(
'APP-SETTING'
))
this
.
init
()
},
methods
:
{
init
()
{
...
...
pages/web/web.vue
View file @
23be374d
...
...
@@ -92,6 +92,10 @@ export default {
},
onHide
()
{
// uni.removeStorageSync('hasRefresh')
const
user_info_obj
=
uni
.
getStorageSync
(
'user_info_obj'
)?
JSON
.
parse
(
uni
.
getStorageSync
(
'user_info_obj'
)):{}
user_info_obj
.
refreshIndex
=
false
uni
.
setStorageSync
(
'user_info_obj'
,
JSON
.
stringify
(
user_info_obj
));
},
onShow
()
{
...
...
@@ -126,8 +130,15 @@ export default {
},
400
)
}
},
onUnload
()
{
uni
.
$off
(
'loadingSubnvue'
);
//移除监听配置的原生子窗体
},
methods
:
{
...
...
pages/web/websrc.vue
View file @
23be374d
...
...
@@ -88,11 +88,15 @@ export default {
}
},
onUnload
()
{
console
.
log
(
'onUnload=+++++++++++'
)
const
wv
=
this
.
$scope
.
$getAppWebview
();
console
.
log
(
wv
,
'WebView '
)
wv
.
clear
()
wv
.
close
()
if
(
wv
){
wv
.
clear
()
wv
.
close
()
}
const
user_info_obj
=
uni
.
getStorageSync
(
'user_info_obj'
)?
JSON
.
parse
(
uni
.
getStorageSync
(
'user_info_obj'
)):{}
user_info_obj
.
refreshIndex
=
true
uni
.
setStorageSync
(
'user_info_obj'
,
JSON
.
stringify
(
user_info_obj
));
},
methods
:
{
handleMessage
(
e
)
{
...
...
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