Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
user
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
hooloo
mp
user
Commits
d242a2c7
Commit
d242a2c7
authored
Jul 07, 2022
by
宋冰琦
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改首页头图
parent
e1a512ac
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
47 additions
and
7 deletions
+47
-7
components/ImageLoader/index.vue
+27
-0
pages/menu/menu.vue
+9
-4
pages/mine/mine.vue
+6
-1
request/index.js
+3
-0
request/order/index.js
+2
-2
No files found.
components/ImageLoader/index.vue
0 → 100644
View file @
d242a2c7
<
template
>
<view>
<image
class=
"default-img"
:style=
"
{'height':!loadOver?height:0,'width':!loadOver?width:0}" :src="defaultSrc"/>
<image
class=
"real-img"
@
load=
"loadOverFunction"
:style=
"
{'height':loadOver?height:0,'width':loadOver?width:0}" :src="realSrc" />
</view>
</
template
>
<
script
>
export
default
{
props
:[
'defaultSrc'
,
'realSrc'
,
'width'
,
'height'
],
data
(){
return
{
loadOver
:
false
}
},
methods
:
{
loadOverFunction
(){
this
.
loadOver
=
true
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
</
style
>
\ No newline at end of file
pages/menu/menu.vue
View file @
d242a2c7
<
template
>
<
template
>
<view
class=
"menu-box"
>
<view
class=
"menu-box"
>
<view
class=
"menu-banner"
:style=
"
{'height':buied?'360rpx':'450rpx'}">
<view
class=
"menu-banner"
:style=
"
{'height':buied?'360rpx':'450rpx'}">
<image
:src=
"img?img:'../../static/imgs/shouyezhanweitu.png'"
/>
<image
:src=
"img"
/>
<!--
<ImageLoader
:defaultSrc=
"'../../static/imgs/shouyezhanweitu.png'"
:realSrc=
"img"
width=
"100%"
height=
"400rpx"
/>
-->
<!--
<video
autoplay
muted
loop
:controls=
"false"
:enable-progress-gesture=
"false"
objectFit=
'cover'
src=
"http://songclound.oss-cn-hongkong.aliyuncs.com/2022/06/27/71d36be0ed966.mp4"
/>
-->
<!--
<video
autoplay
muted
loop
:controls=
"false"
:enable-progress-gesture=
"false"
objectFit=
'cover'
src=
"http://songclound.oss-cn-hongkong.aliyuncs.com/2022/06/27/71d36be0ed966.mp4"
/>
-->
<view
class=
"shop-info"
:style=
"'top:100rpx'"
>
<view
class=
"shop-info"
:style=
"'top:100rpx'"
>
<view
class=
"shop-box"
>
<view
class=
"shop-box"
>
...
@@ -55,13 +56,12 @@
...
@@ -55,13 +56,12 @@
style=
"background:#fff;width: 200px;height: 200px; display:block; left:-800rpx;position:absolute;"
/>
style=
"background:#fff;width: 200px;height: 200px; display:block; left:-800rpx;position:absolute;"
/>
<show-toast
ref=
"toast"
/>
<show-toast
ref=
"toast"
/>
<taBar
select=
"0"
></taBar>
<taBar
select=
"0"
></taBar>
<!--
<TestPopup
/>
-->
<ShopCar
ref=
"shopbar"
/>
<ShopCar
ref=
"shopbar"
/>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
MenuAssembly
from
'@/components/menuAssembly'
import
MenuAssembly
from
'@/components/menuAssembly'
import
TestPopup
from
'@/components/TestPopup
/index.vue'
import
ImageLoader
from
'@/components/ImageLoader
/index.vue'
import
AreaPicker
from
'@/components/AreaPicker/index.vue'
import
AreaPicker
from
'@/components/AreaPicker/index.vue'
import
User
from
'@/request/user'
import
User
from
'@/request/user'
import
ShopCar
from
'../../components/shopCar/shopCar.vue'
import
ShopCar
from
'../../components/shopCar/shopCar.vue'
...
@@ -73,7 +73,7 @@ import Order from '@/request/order'
...
@@ -73,7 +73,7 @@ import Order from '@/request/order'
import
OrderQrCode
from
'@/components/OrderQrCode'
import
OrderQrCode
from
'@/components/OrderQrCode'
import
QRCode
from
'@/utils/qrCode'
import
QRCode
from
'@/utils/qrCode'
export
default
{
export
default
{
components
:
{
ShopCar
,
MenuAssembly
,
OrderQrCode
,
AreaPicker
,
TestPopup
},
components
:
{
ShopCar
,
MenuAssembly
,
OrderQrCode
,
AreaPicker
,
ImageLoader
},
data
()
{
data
()
{
return
{
return
{
shopInfo
:
{
name
:
'请选择'
},
// 店铺信息
shopInfo
:
{
name
:
'请选择'
},
// 店铺信息
...
@@ -94,7 +94,12 @@ export default {
...
@@ -94,7 +94,12 @@ export default {
},
},
},
},
created
()
{
created
()
{
let
platform
=
uni
.
getSystemInfoSync
().
platform
;
if
(
platform
==
'android'
){
this
.
img
=
'../../static/imgs/shouyezhanweitu.png'
}
else
{
this
.
img
=
'https://s3.bmp.ovh/imgs/2022/07/02/2cfab823b35322e3.gif'
this
.
img
=
'https://s3.bmp.ovh/imgs/2022/07/02/2cfab823b35322e3.gif'
}
},
},
onLoad
:
async
function
()
{
onLoad
:
async
function
()
{
uni
.
getSetting
({
uni
.
getSetting
({
...
...
pages/mine/mine.vue
View file @
d242a2c7
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
<!--
<image
class=
"logImg"
src=
"/static/imgs/hooloo.png"
></image>
-->
<!--
<image
class=
"logImg"
src=
"/static/imgs/hooloo.png"
></image>
-->
<!--
<view
class=
"logText"
>
未 来 咖 啡
</view>
-->
<!--
<view
class=
"logText"
>
未 来 咖 啡
</view>
-->
</view>
</view>
<image
:src=
"img
?img:'../../static/imgs/wodezhanweitu.png'
"
/>
<image
:src=
"img"
/>
<!--
<video
class=
"video"
autoplay
muted
loop
:controls=
"false"
:enable-progress-gesture=
"false"
objectFit=
'cover'
src=
"http://songclound.oss-cn-hongkong.aliyuncs.com/2022/06/27/e6582afb60924.mp4"
></video>
-->
<!--
<video
class=
"video"
autoplay
muted
loop
:controls=
"false"
:enable-progress-gesture=
"false"
objectFit=
'cover'
src=
"http://songclound.oss-cn-hongkong.aliyuncs.com/2022/06/27/e6582afb60924.mp4"
></video>
-->
<view
class=
"mod11"
>
<view
class=
"mod11"
>
<view
class=
"avatar"
>
<view
class=
"avatar"
>
...
@@ -100,7 +100,12 @@ export default {
...
@@ -100,7 +100,12 @@ export default {
this
.
loginInfo
=
loginInfo
this
.
loginInfo
=
loginInfo
})
})
}
}
let
platform
=
uni
.
getSystemInfoSync
().
platform
;
if
(
platform
==
'android'
){
this
.
img
=
'../../static/imgs/wodezhanweitu.png'
}
else
{
this
.
img
=
'https://s3.bmp.ovh/imgs/2022/07/05/1768111c5c7f5300.gif'
this
.
img
=
'https://s3.bmp.ovh/imgs/2022/07/05/1768111c5c7f5300.gif'
}
},
},
data
()
{
data
()
{
return
{
return
{
...
...
request/index.js
View file @
d242a2c7
...
@@ -25,11 +25,14 @@ module.exports = (vm) => {
...
@@ -25,11 +25,14 @@ module.exports = (vm) => {
// 请求拦截
// 请求拦截
uni
.
$u
.
http
.
interceptors
.
request
.
use
(
uni
.
$u
.
http
.
interceptors
.
request
.
use
(
(
config
)
=>
{
(
config
)
=>
{
const
{
noLoading
=
false
}
=
config
.
params
// 可使用async await 做异步操作
// 可使用async await 做异步操作
if
(
!
noLoading
){
uni
.
showLoading
({
uni
.
showLoading
({
title
:
'加载中'
,
title
:
'加载中'
,
mask
:
true
,
mask
:
true
,
});
});
}
let
Authorization
=
uni
.
getStorageSync
(
`Authorization`
);
let
Authorization
=
uni
.
getStorageSync
(
`Authorization`
);
const
configUrl
=
[
const
configUrl
=
[
'/weixin/login'
,
'/weixin/login'
,
...
...
request/order/index.js
View file @
d242a2c7
...
@@ -2,7 +2,7 @@ export default {
...
@@ -2,7 +2,7 @@ export default {
getMyOrder
()
{
getMyOrder
()
{
return
uni
.
$u
.
http
return
uni
.
$u
.
http
.
get
(
'/app/getMyOrder'
,
{
.
get
(
'/app/getMyOrder'
,
{
params
:
{},
params
:
{
noLoading
:
true
},
})
})
.
then
((
res
)
=>
res
)
.
then
((
res
)
=>
res
)
.
catch
((
err
)
=>
{
.
catch
((
err
)
=>
{
...
@@ -68,7 +68,7 @@ export default {
...
@@ -68,7 +68,7 @@ export default {
getHomeOrder
(
params
)
{
getHomeOrder
(
params
)
{
return
uni
.
$u
.
http
return
uni
.
$u
.
http
.
get
(
`/app/getHomeOrder?shopId=
${
params
.
shopId
}
`
,
{
.
get
(
`/app/getHomeOrder?shopId=
${
params
.
shopId
}
`
,
{
params
:
{},
params
:
{
noLoading
:
true
},
})
})
.
then
((
res
)
=>
res
)
.
then
((
res
)
=>
res
)
.
catch
((
err
)
=>
{
.
catch
((
err
)
=>
{
...
...
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