diff --git a/App.vue b/App.vue
index dc7413f..bd2b1f9 100644
--- a/App.vue
+++ b/App.vue
@@ -1,11 +1,8 @@
diff --git a/pages/CommodityDetails/CommodityDetails.vue b/pages/CommodityDetails/CommodityDetails.vue
index 1cbe8fb..ad71832 100644
--- a/pages/CommodityDetails/CommodityDetails.vue
+++ b/pages/CommodityDetails/CommodityDetails.vue
@@ -6,27 +6,25 @@
-
+
+
-
+
- {{item.goodsName}}
-
-
- 200{{item.goodsUnit}}
+ {{goodsDetailslist.goodsName}}
- ¥{{item.goodsPrice}}
+ ¥{{goodsPrice}} 起
-
+
已选
- 酒精棉片 8盒×1
+ {{updata.goodsAttributeName}}
@@ -55,45 +53,55 @@
图文服务
-
+
立即购买
-
+
-
+
- 酒精棉片 200片
+ {{goodsDetailslist.goodsName}}
- ¥36.0
+ ¥{{updata.goodsPrice}}
-
- 酒精棉片 8盒
+
+ {{item.attributeDetailsName}}
+
-
+
-
+
立即购买
@@ -106,33 +114,115 @@
goodsDetails
} from '@/api/CommodityDetails/CommodityDetails.js'
import baseurl from '@/api/baseurl.js'
-
export default {
data() {
return {
- goodsDetails:[],
- goodsInfoId:"1",
+ baseurl: '', //url
+ goodsPrice: '', //页面价格
+ goodsDetailslist: [], //商品list
+ goodDetailsLists: [], //提前预备商品规格数组
buyshow: false, //立即购买遮罩层开关
- //轮播内容
- info: [{
- content: '内容 A'
- }],
+ info: [{}],
current: 0, //轮播初始下标
mode: 'dot', //轮播点样式
swiperDotIndex: 0, //轮播可视图
number: 1, //数量
+ updata: { //订单
+ goodsPrice: 0.00,
+ goodsName: "",
+ goodsAttributeName: '',
+ goodsCount: 1,
+ nurseStationId: '',
+ img: '',
+ totalprice: null,
+ }
};
},
-
- onLoad(options) {
- //获取传值
- console.log(options)
- this.goodsDetailsinfo()
- // this.title = options.title
- this.goodsInfoId = options.goodsInfoId
- // this.goodsListinfo()
- },
methods: {
+ //立即购买跳转确认订单页面
+ tapbuy() {
+ this.updata.totalprice = (this.updata.goodsPrice * this.updata.goodsCount).toFixed(2)
+ console.log(this.updata)
+ },
+ // tapbuy() {
+ // this.goodsDetailslist.goodDetailsLists.forEach(e => {
+ // e.goodAttributeDetailsLists.forEach(el => {
+ // if (el.isActive == true) {
+ // this.updata.goodsAttributeName += el.attributeDetailsName + ' '
+ // this.updata.totalprice = (this.updata.goodsPrice * this.updata.goodsCount)
+ // .toFixed(2)
+ // }
+ // })
+ // })
+ // },
+ //选择商品
+ isActivegoods(item) {
+ this.updata.goodsPrice = 0
+ this.updata.goodsAttributeName = ''
+ if (item.isActive == true) {
+ this.goodDetailsLists.forEach(e => {
+ e.isActive = false
+ })
+ } else {
+ this.goodDetailsLists.forEach(e => {
+ e.isActive = false
+ })
+ item.isActive = true
+ this.updata.goodsAttributeName = item.attributeDetailsName
+ this.updata.goodsPrice = item.goodsPrice
+ this.updata.goodsPrice = this.updata.goodsPrice.toFixed(2)
+ }
+ },
+
+ // isActivegoods(item, bitem) {
+ // if (item.attributeName.includes('服务')) {} else {
+ // if (bitem.isActive == true) {
+ // item.goodAttributeDetailsLists.forEach(e => {
+ // e.isActive = false
+ // })
+ // } else {
+ // item.goodAttributeDetailsLists.forEach(e => {
+ // e.isActive = false
+ // })
+ // bitem.isActive = true
+ // }
+ // }
+ // this.updata.goodsPrice = 0
+ // this.updata.goodsAttributeName = ''
+ // this.goodsDetailslist.goodDetailsLists.forEach(e => {
+ // e.goodAttributeDetailsLists.forEach(el => {
+ // if (el.isActive == true) {
+ // this.updata.goodsPrice += el.goodsPrice
+ // this.updata.goodsAttributeName += el.attributeDetailsName + ' '
+ // }
+ // })
+ // })
+ // this.updata.goodsPrice = this.updata.goodsPrice.toFixed(2)
+ // },
+ // 查询商品详细信息
+ goodsDetailsinfo(goodsInfoId) {
+ goodsDetails(goodsInfoId).then(res => {
+ res.data[0].goodDetailsLists.forEach(e => {
+ e.isActive = false
+ })
+ this.goodsDetailslist = res.data[0]
+ this.updata.goodsName = this.goodsDetailslist.goodsName
+ this.updata.nurseStationId = this.goodsDetailslist.nurseStationId
+ this.updata.img = this.goodsDetailslist.goodsPictureUrl
+ this.goodDetailsLists = res.data[0].goodDetailsLists
+ // res.data[0].goodDetailsLists.forEach(e => {
+ // e.goodAttributeDetailsLists.forEach(el => {
+ // el.isActive = false
+ // el.goodsPrice = Number(el.goodsPrice)
+ // })
+ // })
+ // this.goodsDetailslist = res.data[0]
+ // this.updata.goodsName = this.goodsDetailslist.goodsName
+ // this.updata.nurseStationId = this.goodsDetailslist.nurseStationId
+ // this.updata.img = this.goodsDetailslist.goodsPictureUrl
+ // this.goodDetailsLists = res.data[0].goodDetailsLists
+ })
+ },
//滑动轮播切换
change(e) {
this.current = e.detail.current;
@@ -141,234 +231,15 @@
clickItem(e) {
this.swiperDotIndex = e
},
- // 查询商品详细信息
- goodsDetailsinfo(){
- goodsDetails(this.goodsInfoId).then(res => {
- // res.data.forEach(e => {
- // e.goodsCatrgoryPicture = baseurl + e.goodsCatrgoryPicture
- // })
- this.goodsDetails = res.data
- console.log(this.goodsDetails)
- })
- }
- }
+ },
+ onLoad(options) { //获取传值
+ this.goodsPrice = options.goodsPrice //页面价格
+ this.baseurl = baseurl;
+ this.goodsDetailsinfo(options.goodsInfoId)
+ },
}
diff --git a/pages/CommodityDetails/CommodityDetailsstyle.scss b/pages/CommodityDetails/CommodityDetailsstyle.scss
new file mode 100644
index 0000000..3f4eeb5
--- /dev/null
+++ b/pages/CommodityDetails/CommodityDetailsstyle.scss
@@ -0,0 +1,246 @@
+.app {
+ .mask {
+ .PurchasePage {
+ position: fixed;
+ bottom: 0;
+ width: 100%;
+ background: #FFFFFF;
+ border-radius: 30rpx 30rpx 0px 0px;
+ font-size: 36rpx;
+ padding-bottom: 20rpx;
+
+ .close {
+ width: 31rpx;
+ height: 31rpx;
+ position: absolute;
+ top: 2%;
+ right: 2%;
+ }
+
+ .topcontent {
+ width: 90%;
+ margin: 0 auto;
+ padding-bottom: 24rpx;
+ border-bottom: 1rpx solid #D8D4D4;
+ position: relative;
+
+ .price {
+ color: #D43953;
+ position: absolute;
+ top: 60%;
+ left: 37%;
+ }
+
+ .title {
+ font-size: 36rpx;
+ position: absolute;
+ top: 12%;
+ left: 38%;
+ font-weight: 600;
+ width: 58%;
+ height: 85rpx;
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 2;
+ overflow: hidden;
+ }
+
+ .image {
+ width: 215rpx;
+ height: 215rpx;
+ background: rgba(150, 147, 148, 0.21);
+ margin: 35rpx 0 0 0;
+
+ image {
+ width: 201rpx;
+ height: 201rpx;
+ margin: 7rpx 0 0 7rpx;
+ }
+
+ }
+ }
+
+ .buy {
+ width: 60%;
+ height: 71rpx;
+ background: #4C7BC9;
+ color: #FFFFFF;
+ text-align: center;
+ line-height: 71rpx;
+ border-radius: 26rpx;
+ margin: 40rpx 0 0 20%;
+ }
+
+ .bottomcontent {
+ margin-top: 34rpx;
+ padding-bottom: 35rpx;
+
+ .header {
+ display: inline-block;
+ vertical-align: middle;
+ }
+
+ .number {
+ display: inline-block;
+ position: absolute;
+ right: 10%;
+ }
+ }
+
+ .centercontent {
+ margin-top: 34rpx;
+ font-size: 36rpx;
+ .header {
+ margin-bottom: 20rpx;
+ }
+ .productmodel {
+ font-size: 24rpx;
+ display: inline-block;
+ width: 30%;
+ height: 60rpx;
+ border: 1rpx solid #D8D4D4;
+ line-height: 60rpx;
+ border-radius: 25rpx;
+ text-align: center;
+ margin: 15rpx 10rpx 0 0;
+ }
+
+ .Productmodel {
+ font-size: 24rpx;
+ display: inline-block;
+ width: 30%;
+ height: 60rpx;
+ background: #ECF1FA;
+ border: 1rpx solid #4C7BC9;
+ line-height: 60rpx;
+ border-radius: 25rpx;
+ color: #4C7BC9;
+ text-align: center;
+ margin: 15rpx 10rpx 0 0;
+ }
+ }
+ }
+ }
+
+ .Purchasecolumn {
+ width: 100%;
+ height: 110rpx;
+ background: #FFFFFF;
+ position: fixed;
+ bottom: 0;
+
+ .buy {
+ width: 263rpx;
+ height: 80rpx;
+ background: #4C7BC9;
+ border-radius: 25rpx;
+ font-size: 38rpx;
+ color: #FFFFFF;
+ line-height: 80rpx;
+ text-align: center;
+ position: absolute;
+ right: 5%;
+ top: 15rpx;
+ }
+ }
+
+ .common {
+ padding-left: 5%;
+ }
+
+ .choice,
+ .Discount,
+ .service {
+ height: 80rpx;
+ background: #FFFFFF;
+ box-shadow: 0px 9px 31px 9px rgba(0, 0, 0, 0.03);
+ font-size: 34rpx;
+ line-height: 80rpx;
+ margin-bottom: 15rpx;
+ position: relative;
+
+ image {
+ width: 17rpx;
+ height: 26rpx;
+ position: absolute;
+ right: 5%;
+ top: 50%;
+ transform: translateY(-50%);
+ }
+
+ .content {
+ width: 65%;
+ display: inline-block;
+ position: absolute;
+ left: 25%;
+ text-overflow: ellipsis;
+ overflow: hidden;
+ white-space: nowrap;
+ color: #000111;
+ }
+
+ .selected {
+ color: #969394;
+ display: inline-block;
+ }
+ }
+
+ .picture {
+ background: #FFFFFF;
+ box-shadow: 0px 9px 31px 9px rgba(0, 0, 0, 0.03);
+ position: relative;
+ padding-bottom: 110rpx;
+
+ .selected {
+ padding: 20rpx 0 0 5%;
+ color: #969394;
+ display: inline-block;
+ }
+
+ image {
+ margin-top: 20rpx;
+ height: 850rpx;
+ width: 100%;
+ }
+ }
+
+ .service {
+ height: 130rpx;
+ line-height: 65rpx;
+
+ .content {
+ display: inline-block;
+ position: absolute;
+ left: 25%;
+ }
+
+ .selected {
+ color: #969394;
+ display: inline-block;
+ }
+ }
+
+ .Commodity {
+ background: #FFFFFF;
+ margin: 15rpx 0 15rpx 0;
+ box-shadow: 0rpx 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
+ font-size: 36rpx;
+ line-height: 60rpx;
+
+ .name,
+ .number {
+ width: 100%;
+ display: inline-block;
+ line-height: 50rpx;
+ }
+
+ .price {
+ color: #D43953;
+ line-height: 70rpx;
+ }
+
+ .number {
+ padding-left: 30rpx;
+ }
+ }
+ }
\ No newline at end of file
diff --git a/pages/InformationFilling/InformationFilling.vue b/pages/InformationFilling/InformationFilling.vue
index 9cd9d5f..c120d8e 100644
--- a/pages/InformationFilling/InformationFilling.vue
+++ b/pages/InformationFilling/InformationFilling.vue
@@ -112,7 +112,7 @@
height: 373rpx;
background: #FFFFFF;
box-shadow: 0rpx 9rpx 3r1px 9rpx rgba(0, 0, 0, 0.03);
- border-radius: 20px;
+ border-radius: 20rpx;
margin: 0 auto;
display: block;
font-size: 36rpx;
@@ -147,7 +147,7 @@
background: #FFFFFF;
font-size: 36rpx;
box-shadow: 0px 9px 31px 9px rgba(0, 0, 0, 0.03);
- border-radius: 20px;
+ border-radius: 20rpx;
margin-top: 15rpx;
font-size: 36rpx;
@@ -159,8 +159,8 @@
width: 99%;
height: 105rpx;
background: #FFFFFF;
- box-shadow: 0px 9px 31px 9px rgba(0, 0, 0, 0.03);
- border-radius: 20px;
+ box-shadow: 0px 9rpx 31rpx 9px rgba(0, 0, 0, 0.03);
+ border-radius: 20rpx;
margin-top: 15rpx;
font-size: 36rpx;
diff --git a/pages/ProductList/ProductList.vue b/pages/ProductList/ProductList.vue
index 9ce3df1..b5c8e7c 100644
--- a/pages/ProductList/ProductList.vue
+++ b/pages/ProductList/ProductList.vue
@@ -2,14 +2,16 @@
-
+
- {{item.goodsName}} 1{{item.goodsUnit}}
+ {{item.goodsName}}
¥{{item.goodsPrice}}
+
+
@@ -22,44 +24,59 @@
export default {
data() {
return {
+ baseurl: '',
title: '医路优品', //导航栏标题
pageNum: 1,
- pageSize: 999,
- goodsCategoryId:"",
- goodsList:[],
+ pageSize: 10,
+ goodsCategoryId: '', //请求值
+ goodsList: [], //商品列表list
+ total: 0, //list总长度
};
},
- onReady() {
- //更改导航栏文字
+ onLoad(options) { //获取传值
+ this.title = options.title //导航栏标题
+ this.goodsCategoryId = options.goodsCategoryId //请求id
+ this.baseurl = baseurl;
+ this.goodsListinfo(this.pageSize, this.pageNum, options.goodsCategoryId)
+ },
+ methods: {
+ // 查询商品列表
+ goodsListinfo(pageSize, pageNum, goodsCategoryId) {
+ goodsList(pageSize, pageNum, goodsCategoryId).then(res => {
+ res.rows.forEach(e => {
+ this.goodsList.push(e)
+ })
+ this.total = res.total
+ })
+ },
+ //跳转详情页
+ goCommodityDetails(item) {
+ uni.navigateTo({
+ url: `/pages/CommodityDetails/CommodityDetails?goodsPrice=${item.goodsPrice}&goodsInfoId=${item.goodsInfoId}`
+ })
+ },
+ },
+ onReady() { //更改导航栏文字
uni.setNavigationBarTitle({
title: this.title,
});
},
- onLoad(options) {
- //获取传值
- console.log(options)
- this.title = options.title
- this.goodsCategoryId = options.goodsCategoryId
- this.goodsListinfo()
- },
- methods: {
- // 查询商品列表
- goodsListinfo(){
- goodsList(this.patientId).then(res => {
- res.data.forEach(e => {
- e.goodsPictureUrl = baseurl + e.goodsPictureUrl
- })
- this.goodsList = res.data
- console.log(this.goodsCategoryList)
- })
- },
- //跳转详情页
- goCommodityDetails() {
- uni.navigateTo({
- url: '/pages/CommodityDetails/CommodityDetails'
- })
- },
+ onReachBottom() { //下滑加载
+ if (this.goodsList.length >= this.total) {} else {
+ this.pageNum++;
+ this.goodsListinfo(this.pageSize, this.pageNum, this.goodsCategoryId)
+ }
},
+ onPullDownRefresh() { //下拉刷新
+ this.pageNum = 1;
+ goodsList(this.pageSize, this.pageNum, this.goodsCategoryId).then(res => {
+ this.goodsList = res.rows
+ this.total = res.total
+ })
+ setTimeout(function() {
+ uni.stopPullDownRefresh();
+ }, 1000);
+ }
}
@@ -93,6 +110,9 @@
color: #000000;
line-height: 69rpx;
padding-left: 20rpx;
+ text-overflow: ellipsis;
+ overflow: hidden;
+ white-space: nowrap;
}
image {
diff --git a/pages/appointmenttime/appointmenttime.vue b/pages/appointmenttime/appointmenttime.vue
index c9e511f..ef770e1 100644
--- a/pages/appointmenttime/appointmenttime.vue
+++ b/pages/appointmenttime/appointmenttime.vue
@@ -353,7 +353,6 @@
.Consumablespackage {
width: 94%;
height: 188rpx;
- ;
margin: 10rpx auto;
padding: 3%;
font-size: 35rpx;
diff --git a/pages/doctorslist/doctorslist.scss b/pages/doctorslist/doctorslist.scss
new file mode 100644
index 0000000..e6d3388
--- /dev/null
+++ b/pages/doctorslist/doctorslist.scss
@@ -0,0 +1,60 @@
+.app {
+ .visual {
+ text-align: center;
+ width: 94%;
+ margin: 0 auto;
+ background-color: #F4F5F7;
+ padding-top: 20rpx;
+ display: flex;
+
+ .list {
+ width: 72%;
+ background: #FFFFFF;
+ box-shadow: 0px 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
+ border-radius: 0px 20rpx 20rpx 0px;
+ padding-bottom: 100rpx;
+
+ .information {
+ width: 90%;
+ position: relative;
+ margin: 37rpx auto 0;
+ padding-bottom: 60rpx;
+ border-bottom: 1rpx solid #D8D4D4;
+
+ .name {
+ font-size: 36rpx;
+ position: absolute;
+ left: 45%;
+ top: 10%;
+ }
+
+ .image {
+ width: 135rpx;
+ height: 138rpx;
+ background: #BFBFBF;
+ border-radius: 25rpx;
+ margin-left: 6%;
+ }
+ }
+ }
+
+ .department {
+ width: 28%;
+
+ .item {
+ line-height: 100rpx;
+ width: 100%;
+ height: 100rpx;
+ background: #ffffff;
+ box-shadow: 0px 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
+ border-radius: 20rpx 0px 0px 20rpx;
+ margin-bottom: 6rpx;
+ }
+
+ .departmentitem {
+ background: #4C7BC9;
+ color: #ffffff;
+ }
+ }
+ }
+ }
\ No newline at end of file
diff --git a/pages/doctorslist/doctorslist.vue b/pages/doctorslist/doctorslist.vue
index e3a5133..6aa4050 100644
--- a/pages/doctorslist/doctorslist.vue
+++ b/pages/doctorslist/doctorslist.vue
@@ -48,64 +48,5 @@
diff --git a/pages/homepage/homepage.vue b/pages/homepage/homepage.vue
index 7548e43..937ddcd 100644
--- a/pages/homepage/homepage.vue
+++ b/pages/homepage/homepage.vue
@@ -13,29 +13,31 @@
就医
-
-
-
- 健康知识
-
-
-
+
国家老年病中心
-
+
体卫融合
-
+
+
+
+ 专病管理
+
+
+
+
+
+ 商城
+
-
-
@@ -45,6 +47,12 @@
return {};
},
methods: {
+ //跳转商城页面
+ goshopping() {
+ uni.navigateTo({
+ url: '/pages/shopping/shopping'
+ })
+ },
//跳转就医页面
gomedicine() {
uni.navigateTo({
@@ -57,48 +65,21 @@
diff --git a/pages/login/login.scss b/pages/login/login.scss
new file mode 100644
index 0000000..129c14f
--- /dev/null
+++ b/pages/login/login.scss
@@ -0,0 +1,89 @@
+ .app {
+ font-family: DengXian;
+ color: #C3C1C1;
+ font-weight: 400;
+
+ .switch {
+ text-align: center;
+ height: 100rpx;
+ color: #46ABD7;
+ position: absolute;
+ top: 67%;
+ left: 10%;
+ }
+
+ .loginbtn {
+ width: 80%;
+ height: 100rpx;
+ text-align: center;
+ line-height: 100rpx;
+ background: #4C7BC9;
+ border-radius: 51rpx;
+ font-size: 41rpx;
+ color: #FFFFFF;
+ position: absolute;
+ top: 57%;
+ left: 10%;
+ }
+
+ .loginphone {
+ background-color: #fff;
+ width: 80%;
+ height: 162rpx;
+ position: absolute;
+ left: 10%;
+ top: 23%;
+
+ input {
+ font-size: 45rpx;
+ color: #000000;
+ }
+
+ ::v-deep .uni-input-placeholder {
+ padding-left: 40rpx;
+ font-size: 41rpx;
+ font-weight: 400;
+ color: #C3C1C1;
+ }
+
+ .phone {
+ padding-left: 40rpx;
+ height: 100%;
+ box-shadow: 0px 9px 31px 9px rgba(0, 0, 0, 0.03);
+ }
+ }
+
+ .logincode {
+ position: absolute;
+ left: 10%;
+
+ .obtaincode {
+ text-align: center;
+ font-size: 37rpx;
+ color: #4C7BC9;
+ line-height: 162rpx;
+ position: absolute;
+ left: 65%;
+ top: 0%;
+ }
+
+ ::v-deep .u-input__input {
+ padding-left: 20rpx;
+ color: #000000;
+ font-size: 42rpx;
+ font-weight: 400;
+ height: 100%;
+ }
+ }
+
+ .title {
+ height: 50rpx;
+ font-size: 52rpx;
+ font-weight: bold;
+ color: #000000;
+ line-height: 44rpx;
+ position: absolute;
+ top: 13%;
+ left: 13%;
+ }
+ }
\ No newline at end of file
diff --git a/pages/login/login.vue b/pages/login/login.vue
index 6ffa40e..0c424da 100644
--- a/pages/login/login.vue
+++ b/pages/login/login.vue
@@ -257,93 +257,5 @@
diff --git a/pages/register/register.scss b/pages/register/register.scss
new file mode 100644
index 0000000..32f04f5
--- /dev/null
+++ b/pages/register/register.scss
@@ -0,0 +1,80 @@
+ .app {
+ font-family: DengXian;
+ color: #C3C1C1;
+ font-weight: 400;
+
+ .switch {
+ text-align: center;
+ line-height: 60rpx;
+ color: #46ABD7;
+ position: absolute;
+ top: 66%;
+ left: 10%;
+ }
+
+ .loginbtn {
+ width: 80%;
+ height: 100rpx;
+ text-align: center;
+ line-height: 100rpx;
+ background: #4C7BC9;
+ border-radius: 51rpx;
+ font-size: 41rpx;
+ color: #FFFFFF;
+ position: absolute;
+ top: 57%;
+ left: 10%;
+ }
+
+ .loginphone {
+ background-color: #fff;
+ width: 80%;
+ height: 162rpx;
+ position: absolute;
+ left: 10%;
+ top: 23%;
+
+ input {
+ font-size: 40rpx;
+ color: #000000;
+ }
+
+ ::v-deep .uni-input-placeholder {
+ padding-left: 40rpx;
+ font-size: 41rpx;
+ font-weight: 400;
+ color: #C3C1C1;
+ }
+
+ .phone {
+ padding-left: 40rpx;
+ height: 100%;
+ box-shadow: 0px 9px 31px 9px rgba(0, 0, 0, 0.03);
+ }
+ }
+
+ .logincode {
+ position: absolute;
+ left: 10%;
+
+ ::v-deep .u-input__input {
+ padding-left: 20rpx;
+ color: #000000;
+ font-size: 41rpx;
+ font-weight: 400;
+ height: 100%;
+ }
+
+ }
+
+ .title {
+ height: 50rpx;
+ font-size: 52rpx;
+ font-weight: bold;
+ color: #000000;
+ line-height: 44rpx;
+ position: absolute;
+ top: 13%;
+ left: 13%;
+ }
+ }
\ No newline at end of file
diff --git a/pages/register/register.vue b/pages/register/register.vue
index f89c1b3..7038504 100644
--- a/pages/register/register.vue
+++ b/pages/register/register.vue
@@ -61,84 +61,5 @@
diff --git a/pages/shopping/shopping.vue b/pages/shopping/shopping.vue
index 55665fe..053c5bc 100644
--- a/pages/shopping/shopping.vue
+++ b/pages/shopping/shopping.vue
@@ -3,13 +3,12 @@
-
-
+
{{item.goodsCategoryName}}
-
+
@@ -22,13 +21,16 @@
export default {
data() {
return {
- pageNum: 1,
- pageSize: 999,
- goodsCategoryList: [],
- listcolor: ['#00C176', '#D43953', '#E1AE3C', '#4C7BC9', '#00C176'],
+ baseurl: '', //url
+ pageNum: 1, //页
+ pageSize: 10, //列
+ total: 0, //list总长度
+ goodsCategoryList: [], //商品列表list
+ listcolor: ['#00C176', '#D43953', '#E1AE3C', '#4C7BC9', '#00C176', '#D43953', '#E1AE3C', '#4C7BC9'], //颜色随动
};
},
- onLoad(options) {
+ onLoad(options) { //初始化加载
+ this.baseurl = baseurl
this.goodsCategory()
},
methods: {
@@ -41,14 +43,31 @@
},
//获取商城信息
goodsCategory() {
- goodsCategoryList(this.pageSize, this.pageNum, ).then(res => {
- res.data.forEach(e => {
- e.goodsCatrgoryPicture = baseurl + e.goodsCatrgoryPicture
+ goodsCategoryList(this.pageSize, this.pageNum).then(res => {
+ res.rows.forEach(e => {
+ this.goodsCategoryList.push(e)
})
- this.goodsCategoryList = res.data
+ this.total = res.total
})
}
},
+ onReachBottom() { //下滑加载
+ if (this.goodsCategoryList.length >= this.total) {} else {
+ this.pageNum++;
+ this.goodsCategory()
+ }
+ },
+ onPullDownRefresh() { //下拉刷新
+ // console.log('refresh');
+ this.pageNum = 1;
+ goodsCategoryList(this.pageSize, this.pageNum).then(res => {
+ this.goodsCategoryList = res.rows
+ this.total = res.total
+ })
+ setTimeout(function() {
+ uni.stopPullDownRefresh();
+ }, 1000);
+ }
}
diff --git a/pages/startup/startup.vue b/pages/startup/startup.vue
index 9caa18d..22d79db 100644
--- a/pages/startup/startup.vue
+++ b/pages/startup/startup.vue
@@ -35,7 +35,7 @@
height: 200rpx;
position: absolute;
left: 25%;
- top:28%;
+ top: 28%;
}
.title {
diff --git a/pages/u-picker/style.components.scss b/pages/u-picker/style.components.scss
deleted file mode 100644
index 6835876..0000000
--- a/pages/u-picker/style.components.scss
+++ /dev/null
@@ -1,7 +0,0 @@
-// 定义混入指令,用于在非nvue环境下的flex定义,因为nvue没有display属性,会报错
-@mixin vue-flex($direction: row) {
- /* #ifndef APP-NVUE */
- display: flex;
- flex-direction: $direction;
- /* #endif */
-}
\ No newline at end of file
diff --git a/static/hdpi.png b/static/hdpi.png
new file mode 100644
index 0000000..d363ed9
Binary files /dev/null and b/static/hdpi.png differ
diff --git a/static/shopping.png b/static/shopping.png
new file mode 100644
index 0000000..936f8f9
Binary files /dev/null and b/static/shopping.png differ
diff --git a/static/shoppingcs.png b/static/shoppingcs.png
deleted file mode 100644
index c049cde..0000000
Binary files a/static/shoppingcs.png and /dev/null differ
diff --git a/static/shoppings.png b/static/shoppings.png
deleted file mode 100644
index b24c1cc..0000000
Binary files a/static/shoppings.png and /dev/null differ
diff --git a/static/shoppingw.png b/static/shoppingw.png
deleted file mode 100644
index 30ba05b..0000000
Binary files a/static/shoppingw.png and /dev/null differ
diff --git a/static/spjtcs.png b/static/spjtcs.png
deleted file mode 100644
index 28aae15..0000000
Binary files a/static/spjtcs.png and /dev/null differ
diff --git a/static/tpcs.png b/static/tpcs.png
deleted file mode 100644
index 4d14233..0000000
Binary files a/static/tpcs.png and /dev/null differ
diff --git a/static/xhdpi.png b/static/xhdpi.png
new file mode 100644
index 0000000..bce48e8
Binary files /dev/null and b/static/xhdpi.png differ
diff --git a/static/xxhdpi.png b/static/xxhdpi.png
new file mode 100644
index 0000000..8ff18aa
Binary files /dev/null and b/static/xxhdpi.png differ