Browse Source

添加足迹页面

zyh
xuwenbo 4 years ago
parent
commit
4d25381a0c
  1. 218
      manifest.json
  2. 4
      pages/activity/GoodsGroup/index.vue
  3. 102
      pages/shop/GoodsFoot/index.vue
  4. BIN
      static/images/group_list_bg.png

218
manifest.json

@ -1,32 +1,32 @@
{ {
"name": "yshopmall", "name" : "yshop商城演示版",
"appid": "__UNI__C7A519E", "appid" : "__UNI__C7A519E",
"description": "", "description" : "",
"versionName": "1.0.0", "versionName" : "1.0.0",
"versionCode": 1, "versionCode" : 1,
"transformPx": false, "transformPx" : false,
/* 5+App */ /* 5+App */
"app-plus": { "app-plus" : {
"usingComponents": true, "usingComponents" : true,
"nvueCompiler": "uni-app", "nvueCompiler" : "uni-app",
"compilerVersion": 3, "compilerVersion" : 3,
"splashscreen": { "splashscreen" : {
"alwaysShowBeforeRender": true, "alwaysShowBeforeRender" : true,
"waiting": false, "waiting" : false,
"autoclose": true, "autoclose" : true,
"delay": 0 "delay" : 0
}, },
/* */ /* */
"modules": { "modules" : {
"OAuth": {}, "OAuth" : {},
"Payment": {}, "Payment" : {},
"Share": {} "Share" : {}
}, },
/* */ /* */
"distribute": { "distribute" : {
/* android */ /* android */
"android": { "android" : {
"permissions": [ "permissions" : [
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>", "<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>", "<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
"<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>", "<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>",
@ -52,127 +52,127 @@
] ]
}, },
/* ios */ /* ios */
"ios": {}, "ios" : {},
/* SDK */ /* SDK */
"sdkConfigs": { "sdkConfigs" : {
"oauth": { "oauth" : {
"weixin": { "weixin" : {
"appid": "wx7c84ede33062d1e4", "appid" : "wx7c84ede33062d1e4",
"appsecret": "c47ef66d3311194da44e60387d5c1abd", "appsecret" : "c47ef66d3311194da44e60387d5c1abd",
"UniversalLinks": "https://yixiang.co/app/" "UniversalLinks" : "https://yixiang.co/app/"
} }
}, },
"payment": { "payment" : {
"weixin": { "weixin" : {
"appid": "wx7c84ede33062d1e4", "appid" : "wx7c84ede33062d1e4",
"UniversalLinks": "https://yixiang.co/app/" "UniversalLinks" : "https://yixiang.co/app/"
} }
}, },
"share": { "share" : {
"weixin": { "weixin" : {
"appid": "wx7c84ede33062d1e4", "appid" : "wx7c84ede33062d1e4",
"UniversalLinks": "https://yixiang.co/app/" "UniversalLinks" : "https://yixiang.co/app/"
} }
}, },
"ad": {} "ad" : {}
}, },
"splashscreen": { "splashscreen" : {
"ios": { "ios" : {
"iphone": { "iphone" : {
"portrait-896h@3x": "unpackage/res/splash/1242+2688.png", "portrait-896h@3x" : "unpackage/res/splash/1242+2688.png",
"portrait-896h@2x": "unpackage/res/splash/828+1792.png", "portrait-896h@2x" : "unpackage/res/splash/828+1792.png",
"iphonex": "unpackage/res/splash/1125+2436.png", "iphonex" : "unpackage/res/splash/1125+2436.png",
"retina55": "unpackage/res/splash/1142+2208.png", "retina55" : "unpackage/res/splash/1142+2208.png",
"retina47": "unpackage/res/splash/750+1334.png", "retina47" : "unpackage/res/splash/750+1334.png",
"retina40": "unpackage/res/splash/640+1136.png", "retina40" : "unpackage/res/splash/640+1136.png",
"retina35": "unpackage/res/splash/640+960.png" "retina35" : "unpackage/res/splash/640+960.png"
} }
}, },
"android": { "android" : {
"hdpi": "unpackage/res/splash/480+762.png", "hdpi" : "unpackage/res/splash/480+762.png",
"xhdpi": "unpackage/res/splash/720+1242.png", "xhdpi" : "unpackage/res/splash/720+1242.png",
"xxhdpi": "unpackage/res/splash/1080+1882.png" "xxhdpi" : "unpackage/res/splash/1080+1882.png"
} }
}, },
"icons": { "icons" : {
"android": { "android" : {
"hdpi": "unpackage/res/icons/72x72.png", "hdpi" : "unpackage/res/icons/72x72.png",
"xhdpi": "unpackage/res/icons/96x96.png", "xhdpi" : "unpackage/res/icons/96x96.png",
"xxhdpi": "unpackage/res/icons/144x144.png", "xxhdpi" : "unpackage/res/icons/144x144.png",
"xxxhdpi": "unpackage/res/icons/192x192.png" "xxxhdpi" : "unpackage/res/icons/192x192.png"
}, },
"ios": { "ios" : {
"appstore": "unpackage/res/icons/1024x1024.png", "appstore" : "unpackage/res/icons/1024x1024.png",
"ipad": { "ipad" : {
"app": "unpackage/res/icons/76x76.png", "app" : "unpackage/res/icons/76x76.png",
"app@2x": "unpackage/res/icons/152x152.png", "app@2x" : "unpackage/res/icons/152x152.png",
"notification": "unpackage/res/icons/20x20.png", "notification" : "unpackage/res/icons/20x20.png",
"notification@2x": "unpackage/res/icons/40x40.png", "notification@2x" : "unpackage/res/icons/40x40.png",
"proapp@2x": "unpackage/res/icons/167x167.png", "proapp@2x" : "unpackage/res/icons/167x167.png",
"settings": "unpackage/res/icons/29x29.png", "settings" : "unpackage/res/icons/29x29.png",
"settings@2x": "unpackage/res/icons/58x58.png", "settings@2x" : "unpackage/res/icons/58x58.png",
"spotlight": "unpackage/res/icons/40x40.png", "spotlight" : "unpackage/res/icons/40x40.png",
"spotlight@2x": "unpackage/res/icons/80x80.png" "spotlight@2x" : "unpackage/res/icons/80x80.png"
}, },
"iphone": { "iphone" : {
"app@2x": "unpackage/res/icons/120x120.png", "app@2x" : "unpackage/res/icons/120x120.png",
"app@3x": "unpackage/res/icons/180x180.png", "app@3x" : "unpackage/res/icons/180x180.png",
"notification@2x": "unpackage/res/icons/40x40.png", "notification@2x" : "unpackage/res/icons/40x40.png",
"notification@3x": "unpackage/res/icons/60x60.png", "notification@3x" : "unpackage/res/icons/60x60.png",
"settings@2x": "unpackage/res/icons/58x58.png", "settings@2x" : "unpackage/res/icons/58x58.png",
"settings@3x": "unpackage/res/icons/87x87.png", "settings@3x" : "unpackage/res/icons/87x87.png",
"spotlight@2x": "unpackage/res/icons/80x80.png", "spotlight@2x" : "unpackage/res/icons/80x80.png",
"spotlight@3x": "unpackage/res/icons/120x120.png" "spotlight@3x" : "unpackage/res/icons/120x120.png"
} }
} }
} }
} }
}, },
"quickapp": {}, "quickapp" : {},
"mp-weixin": { "mp-weixin" : {
"appid": "wx604d2ea4702620d2", "appid" : "wx604d2ea4702620d2",
"setting": { "setting" : {
"urlCheck": false "urlCheck" : false
}, },
"usingComponents": true, "usingComponents" : true,
"permission": { "permission" : {
"scope.userLocation": { "scope.userLocation" : {
"desc": "你的位置信息将用于小程序位置接口的效果展示" "desc" : "你的位置信息将用于小程序位置接口的效果展示"
} }
}, },
"plugins": { "plugins" : {
"live-player-plugin": { "live-player-plugin" : {
// //
"version": "1.1.9", "version" : "1.1.9",
// appidappid // appidappid
"provider": "wx2b03c6e691cd7370" "provider" : "wx2b03c6e691cd7370"
} }
} }
}, },
"mp-alipay": { "mp-alipay" : {
"usingComponents": true "usingComponents" : true
}, },
"mp-baidu": { "mp-baidu" : {
"usingComponents": true "usingComponents" : true
}, },
"mp-toutiao": { "mp-toutiao" : {
"usingComponents": true "usingComponents" : true
}, },
"h5": { "h5" : {
"title": "yshop", "title" : "yshop",
"devServer": { "devServer" : {
"disableHostCheck": true "disableHostCheck" : true
}, },
"router": { "router" : {
"mode": "history" "mode" : "history"
}, },
"sdkConfigs": { "sdkConfigs" : {
"maps": { "maps" : {
"qqmap": { "qqmap" : {
"key": "" "key" : ""
} }
} }
}, },
"domain": "h5.yixiang.co" "domain" : "h5.yixiang.co"
} }
} }

4
pages/activity/GoodsGroup/index.vue

@ -4,7 +4,7 @@
<scroll-view class="scroll-box" scroll-y enable-back-to-top scroll-with-animation @scrolltolower="loadMore"> <scroll-view class="scroll-box" scroll-y enable-back-to-top scroll-with-animation @scrolltolower="loadMore">
<view class="group-wrap"> <view class="group-wrap">
<view class="group-head x-bc"> <view class="group-head x-bc">
<text class="group-head__title">爆款推荐</text> <text class="group-head__title">爆款拼团</text>
<text class="group-head__notice">省钱省心限时拼</text> <text class="group-head__notice">省钱省心限时拼</text>
</view> </view>
<view class="group-box"> <view class="group-box">
@ -129,7 +129,7 @@ export default {
<style lang="scss"> <style lang="scss">
.group-wrap { .group-wrap {
background: url('~@/static/images/group_list_bg.png') no-repeat; background: url('~@/static/images/index-bg.png') no-repeat;
background-size: 100% 374rpx; background-size: 100% 374rpx;
} }
.group-head { .group-head {

102
pages/shop/GoodsFoot/index.vue

@ -0,0 +1,102 @@
<template>
<view ref="container">
<view class="collectionGoods" v-if="collectProductList.length > 0">
<view
class="item acea-row row-between-wrapper"
v-for="(item, collectProductListIndex) in collectProductList"
:key="collectProductListIndex"
@click="goGoodsCon(item)"
>
<view class="pictrue">
<image :src="item.image" />
</view>
<view class="text acea-row row-column-between">
<view class="infor line1">{{ item.storeName }}</view>
<view class="acea-row row-between-wrapper">
<view class="money font-color-red">{{ item.price }}</view>
<view class="delete" @tap.stop="delCollection(collectProductListIndex)">删除</view>
</view>
</view>
</view>
</view>
<Loading :loaded="loadend" :loading="loading"></Loading>
<view
class="noCommodity"
style="background-color:#fff;"
v-if="collectProductList.length < 1 && page > 1"
>
<view class="noPictrue">
<image src="@/static/images/noCollection.png" class="image" />
</view>
<Recommend></Recommend>
</view>
</view>
</template>
<script>
import Recommend from "@/components/Recommend";
import { getCollectUser, getCollectDel } from "@/api/user";
import Loading from "@/components/Loading";
export default {
name: "GoodsCollection",
components: {
Recommend,
Loading
},
props: {},
data: function() {
return {
page: 1,
limit: 20,
type:'foot',
collectProductList: [],
loadTitle: "",
loading: false,
loadend: false
};
},
mounted: function() {
this.get_user_collect_product();
},
onReachBottom() {
!this.loading && this.get_user_collect_product();
},
methods: {
goGoodsCon(item) {
this.$yrouter.push({
path: "/pages/shop/GoodsCon/index",
query: { id: item.pid }
});
},
get_user_collect_product: function() {
let that = this;
if (that.loading) return; //false
if (that.loadend) return; //false
that.loading = true;
getCollectUser(that.page, that.limit,that.type).then(res => {
that.loading = false;
//apply();js;
that.collectProductList.push.apply(that.collectProductList, res.data);
that.loadend = res.data.length < that.limit; //
that.page = that.page + 1;
});
},
//
delCollection: function(index) {
let that = this,
id = that.collectProductList[index].pid,
category = that.collectProductList[index].category;
getCollectDel(id, category).then(function() {
uni.showToast({
title: "删除成功",
icon: "success",
duration: 2000,
complete: () => {
that.collectProductList.splice(index, 1);
that.$set(that, "collectProductList", that.collectProductList);
}
});
});
}
}
};
</script>

BIN
static/images/group_list_bg.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

Loading…
Cancel
Save