Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
gl_tape
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
3
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit d4763275
authored
Apr 08, 2024
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
添加页面
1 parent
87f7f087
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
203 additions
and
24 deletions
api/module/common.js
pages.json
pages/detail/detail.vue
pages/home/home.vue
router/index.js
router/modules/routes.js
api/module/common.js
View file @
d476327
...
@@ -8,4 +8,10 @@ module.exports = {
...
@@ -8,4 +8,10 @@ module.exports = {
...
data
,
...
data
,
})
})
},
},
findSoureList
(
data
)
{
return
http
.
post
({
method
:
'dj.api.smartcarlife.recepiton.soure.findSoureList'
,
...
data
,
})
}
}
}
\ No newline at end of file
\ No newline at end of file
pages.json
View file @
d476327
...
@@ -17,6 +17,13 @@
...
@@ -17,6 +17,13 @@
}
}
},
},
{
{
"path"
:
"pages/detail/detail"
,
"style"
:
{
"navigationBarTitleText"
:
""
,
"enablePullDownRefresh"
:
false
}
},
{
"path"
:
"pages/order/order"
,
"path"
:
"pages/order/order"
,
"style"
:
{
"style"
:
{
"navigationBarTitleText"
:
""
,
"navigationBarTitleText"
:
""
,
...
...
pages/detail/detail.vue
0 → 100644
View file @
d476327
<!--
* @Description:
* @Author: huyue
* @Date: 2024-04-08 11:30:30
* @LastEditors: huyue
* @LastEditTime: 2024-04-08 13:44:50
-->
<
template
>
<view>
详情页
<button
@
click=
"open"
>
打开弹窗
</button>
<uni-popup
ref=
"popup"
type=
"bottom"
background-color=
"#fff"
border-radius=
"10px 10px 0 0"
>
<view>
<view
class=
""
>
付款二维码
</view>
</view>
</uni-popup
>
</view>
</
template
>
<
script
>
export
default
{
data
()
{
return
{};
},
onLoad
(
options
)
{
console
.
log
(
options
,
"=="
);
// const text = options.text
// uni.setNavigationBarTitle({
// title: text
// });
},
methods
:
{
open
()
{
// 通过组件定义的ref调用uni-popup方法 ,如果传入参数 ,type 属性将失效 ,仅支持 ['top','left','bottom','right','center']
this
.
$refs
.
popup
.
open
(
"top"
);
},
},
};
</
script
>
<
style
scoped
lang=
"scss"
>
</
style
>
pages/home/home.vue
View file @
d476327
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
* @Author: huyue
* @Author: huyue
* @Date: 2024-04-07 14:39:40
* @Date: 2024-04-07 14:39:40
* @LastEditors: huyue
* @LastEditors: huyue
* @LastEditTime: 2024-04-08
09:45:47
* @LastEditTime: 2024-04-08
11:44:51
-->
-->
<
template
>
<
template
>
<view
class=
"container"
>
<view
class=
"container"
>
...
@@ -20,13 +20,13 @@
...
@@ -20,13 +20,13 @@
</view>
</view>
<view
class=
"left-footer"
>
<view
class=
"left-footer"
>
<view
class=
"logout"
>
<view
class=
"logout"
>
<
image
class=
"icon-logout"
src=
"../../static/images/
home/icon-logout.png"
mode=
"scaleToFill"
/>
<
glsx-image
class=
"icon-logout"
src=
"
home/icon-logout.png"
mode=
"scaleToFill"
/>
<view>
退出
</view>
<view>
退出
</view>
</view>
</view>
<view
class=
"store-addr"
>
<view
class=
"store-addr"
>
<image
<
glsx-
image
class=
"icon-addr"
class=
"icon-addr"
src=
"
../../static/images/
home/icon-addr.png"
src=
"home/icon-addr.png"
mode=
"scaleToFill"
mode=
"scaleToFill"
/>
/>
<view
class=
"addr-text"
>
东莞问界交付中心
</view>
<view
class=
"addr-text"
>
东莞问界交付中心
</view>
...
@@ -35,14 +35,62 @@
...
@@ -35,14 +35,62 @@
</view>
</view>
<view
class=
"right-side"
>
<view
class=
"right-side"
>
<!-- 右侧内容 -->
<!-- 右侧内容 -->
<text>
右侧内容
</text>
<view
class=
"home-title"
>
客户接待
</view>
<view
class=
"start"
>
<glsx-image
class=
"icon-start"
src=
"home/icon-handshake.png"
mode=
"scaleToFill"
/>
<view
class=
"start-text"
>
开始接待
</view>
</view>
<!-- 各模块入口list -->
<view
class=
"module-list"
>
<view
class=
"module-item"
v-for=
"item in moduleList"
:key=
"item.id"
@
click=
"toDetail(item)"
>
<image
class=
"module-img"
:src=
"item.picUrl"
mode=
"scaleToFill"
/>
<view
class=
"module-name"
>
{{
item
.
name
}}
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
export
default
{
export
default
{
data
()
{
data
()
{
return
{};
return
{
moduleList
:
[
{
id
:
1
,
name
:
'问界交车告知书'
,
picUrl
:
'../../static/logo.png'
},
{
id
:
2
,
name
:
'商城延保价格明细'
,
picUrl
:
'../../static/logo.png'
},
{
id
:
3
,
name
:
'保修升级告知书'
,
picUrl
:
'../../static/logo.png'
},
{
id
:
4
,
name
:
'问界三包政策'
,
picUrl
:
'../../static/logo.png'
},
{
id
:
5
,
name
:
'整车质保升级政策'
,
picUrl
:
'../../static/logo.png'
},
{
id
:
6
,
name
:
'历史成交客户'
,
picUrl
:
'../../static/logo.png'
}
]
};
},
},
onLoad
(
options
)
{
onLoad
(
options
)
{
const
text
=
options
.
text
;
const
text
=
options
.
text
;
...
@@ -50,6 +98,14 @@ export default {
...
@@ -50,6 +98,14 @@ export default {
title
:
text
,
title
:
text
,
});
});
},
},
methods
:
{
toDetail
(
item
)
{
// this.$Router.push({name:'detail'})
uni
.
navigateTo
({
url
:
`../detail/detail?id=
${
item
.
id
}
`
})
}
},
};
};
</
script
>
</
script
>
<
style
scoped
lang=
"scss"
>
<
style
scoped
lang=
"scss"
>
...
@@ -125,5 +181,51 @@ export default {
...
@@ -125,5 +181,51 @@ export default {
.right-side
{
.right-side
{
flex
:
1
;
flex
:
1
;
background-color
:
#FFFFFF
;
background-color
:
#FFFFFF
;
padding
:
0
60
rpx
;
.home-title
{
margin
:
26
rpx
auto
;
text-align
:
center
;
}
.start
{
width
:
100%
;
height
:
196
rpx
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
background-image
:
linear-gradient
(
90deg
,
#48A6FF
0%
,
#2C66F7
100%
);
border-radius
:
40
rpx
;
margin
:
40
rpx
0
60
rpx
;
.icon-start
{
width
:
72
rpx
;
height
:
72
rpx
;
margin-right
:
20
rpx
;
}
.start-text
{
font-weight
:
600
;
font-size
:
48
rpx
;
color
:
#FFFFFF
;
line-height
:
44
rpx
;
}
}
.module-list
{
display
:
flex
;
flex-wrap
:
wrap
;
.module-item
{
margin-right
:
60
rpx
;
.module-img
{
width
:
324
rpx
;
height
:
324
rpx
;
border-radius
:
16
rpx
;
mix-blend-mode
:
multiply
;
}
.module-name
{
font-weight
:
500
;
font-size
:
28
rpx
;
color
:
#292D33
;
text-align
:
center
;
}
}
}
}
}
</
style
>
</
style
>
\ No newline at end of file
\ No newline at end of file
router/index.js
View file @
d476327
import
modules
from
'./modules'
/*
import
Vue
from
'vue'
* @Description:
import
Router
from
'@/plugin/uni-simple-router/index.js'
* @Author: huyue
* @Date: 2024-04-07 18:15:11
* @LastEditors: huyue
* @LastEditTime: 2024-04-08 11:11:15
*/
// import modules from './modules'
// import Vue from 'vue'
// import Router from '@/plugin/uni-simple-router/index.js'
Vue
.
use
(
Router
)
//
Vue.use(Router)
//初始化
//
//
初始化
const
router
=
new
Router
({
//
const router = new Router({
encodeURI
:
true
,
//
encodeURI:true,
routes
:
[...
modules
]
//路由表
//
routes: [...modules]//路由表
});
//
});
const
whiteList
=
[
'/pages/common/login'
]
//全局路由前置守卫
router
.
beforeEach
((
to
,
from
,
next
)
=>
{
next
()
})
// 全局路由后置守卫
router
.
afterEach
((
to
,
from
)
=>
{
console
.
log
(
"afterEach"
)
});
\ No newline at end of file
\ No newline at end of file
// const whiteList = ['/pages/common/login']
// //全局路由前置守卫
// router.beforeEach((to, from, next) => {
// next()
// })
// // 全局路由后置守卫
// router.afterEach((to, from) => {
// console.log("afterEach")
// });
\ No newline at end of file
\ No newline at end of file
router/modules/routes.js
View file @
d476327
const
routes
=
[
const
routes
=
[
{
{
path
:
"/pages/home/home"
,
name
:
'home'
,
meta
:
{
title
:
'客户接待'
,
},
},
{
path
:
"/pages/common/login"
,
path
:
"/pages/common/login"
,
name
:
'login'
,
name
:
'login'
,
meta
:
{
meta
:
{
title
:
'登录'
,
title
:
'登录'
,
},
},
},
},
{
path
:
"/pages/detail/detail"
,
name
:
'detail'
,
meta
:
{
title
:
'详情'
,
},
},
]
]
export
default
routes
export
default
routes
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
Attach a file
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 post a comment