Browse Source

合并冲突

master
Gaoxs 4 years ago
parent
commit
85b69722e3
  1. 2
      components/OrderGoods.vue
  2. 38
      components/Recommend.vue
  3. 2
      manifest.json
  4. 12
      pages/Loading/index.vue
  5. 36
      pages/home/components/Banner.vue
  6. 1
      pages/shop/GoodsCon/index.vue
  7. 69
      pages/shop/GoodsList/index.vue
  8. 2
      unpackage/resources/__UNI__C7A519E/www/__uniappopenlocation.js
  9. 2
      unpackage/resources/__UNI__C7A519E/www/__uniapppicker.js
  10. 8
      unpackage/resources/__UNI__C7A519E/www/app-config-service.js
  11. 4
      unpackage/resources/__UNI__C7A519E/www/app-service.js
  12. 2
      unpackage/resources/__UNI__C7A519E/www/app-view.js
  13. 2
      unpackage/resources/__UNI__C7A519E/www/manifest.json
  14. BIN
      unpackage/resources/__UNI__C7A519E/www/static/icon-cart-hot.png
  15. BIN
      unpackage/resources/__UNI__C7A519E/www/static/icon-class-hot.png
  16. BIN
      unpackage/resources/__UNI__C7A519E/www/static/icon-home-hot.png
  17. BIN
      unpackage/resources/__UNI__C7A519E/www/static/icon-user-hot.png
  18. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/dfh.png
  19. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/dfk.png
  20. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/dpj.png
  21. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/dsh.png
  22. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/group.png
  23. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/h5.png
  24. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/index-bg.png
  25. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/integralbg.jpg
  26. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/light.png
  27. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/news.png
  28. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/pricetitle.jpg
  29. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/promotionBg.png
  30. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/public.png
  31. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/record1.png
  32. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/record2.png
  33. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/record3.png
  34. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/record4.png
  35. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/redBg.png
  36. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/sh.png
  37. BIN
      unpackage/resources/__UNI__C7A519E/www/static/images/writeOffBg.jpg
  38. 2
      unpackage/resources/__UNI__C7A519E/www/view.css
  39. 4
      unpackage/resources/__UNI__C7A519E/www/view.umd.min.js

2
components/OrderGoods.vue

@ -16,7 +16,7 @@
v-if="cart.productInfo.attrInfo"
>{{ cart.productInfo.attrInfo.sku }}</view>
<view class="money font-color-red">{{ cart.truePrice }}</view>
<view class="evaluate" v-if="evaluate == 3" @click="routerGo(cart)">评价</view>
<view class="evaluate" v-if="evaluate == 3 && cart.isReply==0" @click="routerGo(cart)">评价</view>
</view>
</view>
</view>

38
components/Recommend.vue

@ -6,13 +6,11 @@
<text class="iconfont icon-zhuangshixian lefticon"></text>
</view>
<view class="recommendList acea-row row-between-wrapper">
<view
@click="routerGo(item)"
class="item"
v-for="(item, recommendIndex) in hostProduct"
:key="recommendIndex"
>
<view class="pictrue"><image :src="item.image" class="image" /></view>
<view @click="routerGo(item)" class="item" v-for="(item, recommendIndex) in hostProduct"
:key="recommendIndex">
<view class="pictrue">
<image :src="item.image" class="image" />
</view>
<view class="name line1">{{ item.storeName }}</view>
<view class="money font-color-red">
@ -24,14 +22,25 @@
</view>
</template>
<script>
import { getHostProducts } from '@/api/store';
import {
getHostProducts
} from '@/api/store';
import Loading from '@/components/Loading';
export default {
name: 'Recommend',
props: {},
props: {
recommendLoading: Boolean
},
components: {
Loading
},
watch: {
recommendLoading(nextLoading) {
if (nextLoading) {
this.hostProducts()
}
}
},
data: function () {
return {
hostProduct: [],
@ -47,7 +56,12 @@ export default {
},
methods: {
routerGo(item) {
this.$yrouter.push({ path: '/pages/shop/GoodsCon/index', query: { id: item.id } });
this.$yrouter.push({
path: '/pages/shop/GoodsCon/index',
query: {
id: item.id
}
});
},
hostProducts: function () {
let that = this;
@ -60,11 +74,9 @@ export default {
that.hostProduct.push.apply(that.hostProduct, res.data);
that.loadend = res.data.length < that.limit; //
that.page = that.page + 1;
this.$emit('changeRecommendLoading', false)
});
}
},
onReachBottom() {
!this.loading && this.hostProducts();
}
};
</script>

2
manifest.json

@ -2,7 +2,7 @@
"name" : "yshopmall",
"appid" : "__UNI__C7A519E",
"description" : "",
"versionName" : "1.0.0",
"versionName" : "1.0.1",
"versionCode" : 1,
"transformPx" : false,
/* 5+App */

12
pages/Loading/index.vue

@ -47,12 +47,12 @@
cookie.set("spread", urlSpread);
}
}
// if (this.$deviceType == "app" || this.$deviceType == "weixinh5") {
// this.$yrouter.switchTab({
// path: "/pages/home/index"
// });
// return;
// }
if (this.$deviceType == "app" || this.$deviceType == "weixinh5") {
this.$yrouter.switchTab({
path: "/pages/home/index"
});
return;
}
if (this.$store.getters.token) {
// token
console.log('登录状态存在,直接进页面')

36
pages/home/components/Banner.vue

@ -41,46 +41,14 @@
let item = this.detail[this.swiperCurrent];
//
let bgcolor = item.bgcolor;
// #ifdef APP-PLUS
that.$set(item, 'bgcolor', '#c40414');
that.$emit('getbgcolor', '#c40414');
// #endif
// #ifndef APP-PLUS
//
if (bgcolor === '') {
let ctx = uni.createCanvasContext('colorThief', that);
if (0 === that.webviewId || ctx.webviewId === that.webviewId) {
that.webviewId = ctx.webviewId;
uni.getImageInfo({
src: item.pic,
success: function (image) {
ctx.drawImage(image.path, 0, 0, image.width, image.height);
ctx.draw(true, function (e) {
uni.canvasGetImageData({
canvasId: 'colorThief',
x: 0,
y: 0,
width: parseInt(image.width),
height: parseInt(image.height),
success(res) {
let bgcolor = colorThief(res.data)
.color()
.getHex();
that.$set(item, 'bgcolor', bgcolor);
that.$emit('getbgcolor', bgcolor);
}
},
that
);
});
}
});
}
that.$set(item, 'bgcolor', '#c40414');
that.$emit('getbgcolor', '#c40414');
} else {
that.$set(item, 'bgcolor', bgcolor);
that.$emit('getbgcolor', bgcolor);
}
// #endif
},
swiperChange(e) {

1
pages/shop/GoodsCon/index.vue

@ -308,6 +308,7 @@
},
computed: mapGetters(["isLogin", "location"]),
mounted: function () {
this.$store.commit("get_to", "goodcon");
let url = handleQrCode();
if (!url) {
url = handleUrlParam(getCurrentPageUrlWithArgs())

69
pages/shop/GoodsList/index.vue

@ -3,22 +3,14 @@
<form @submit.prevent="submitForm">
<view class="search bg-color-red acea-row row-between-wrapper">
<view class="input acea-row row-between-wrapper">
<text class="iconfont icon-sousuo"></text>
<input placeholder="搜索商品信息" v-model="where.keyword" />
<text class="iconfont icon-sousuo" @click="submitForm"></text>
</view>
<view
class="iconfont"
:class="Switch === true ? 'icon-pailie' : 'icon-tupianpailie'"
@click="switchTap"
></view>
<view class="iconfont" :class="Switch === true ? 'icon-pailie' : 'icon-tupianpailie'" @click="switchTap"></view>
</view>
</form>
<view class="nav acea-row row-middle">
<view
class="item"
:class="title ? 'font-color-red' : ''"
@click="set_where(0)"
>{{ title ? title : "默认" }}</view>
<view class="item" :class="title ? 'font-color-red' : ''" @click="set_where(0)">{{ title ? title : "默认" }}</view>
<view class="item" @click="set_where(1)">
价格
<image src="@/static/images/horn.png" v-if="price === 0" />
@ -34,19 +26,9 @@
<!-- down -->
<view class="item" :class="nows ? 'font-color-red' : ''" @click="set_where(3)">新品</view>
</view>
<view
class="list acea-row row-between-wrapper"
:class="Switch === true ? '' : 'on'"
ref="container"
>
<view
@click="goGoodsCon(item)"
class="item"
:class="Switch === true ? '' : 'on'"
v-for="(item, productListIndex) in productList"
:key="productListIndex"
:title="item.storeName"
>
<view class="list acea-row row-between-wrapper" :class="Switch === true ? '' : 'on'" ref="container">
<view @click="goGoodsCon(item)" class="item" :class="Switch === true ? '' : 'on'"
v-for="(item, productListIndex) in productList" :key="productListIndex" :title="item.storeName">
<view class="pictrue" :class="Switch === true ? '' : 'on'">
<image :src="item.image" :class="Switch === true ? '' : 'on'" />
</view>
@ -64,21 +46,20 @@
</view>
</view>
<Loading :loaded="loadend" :loading="loading"></Loading>
<view
class="noCommodity"
style="background-color: #fff;"
v-if="productList.length === 0 && where.page > 1"
>
<view class="noCommodity" style="background-color: #fff;" v-if="productList.length === 0 && where.page > 1">
<view class="noPictrue">
<image src="@/static/images/noGood.png" class="image" />
</view>
</view>
<Recommend v-if="productList.length === 0 && where.page > 1"></Recommend>
<Recommend v-if="productList.length === 0 && where.page > 1" :recommendLoading="recommendLoading"
@changeRecommendLoading="changeRecommendLoading"></Recommend>
</view>
</template>
<script>
import Recommend from "@/components/Recommend";
import { getProducts } from "@/api/store";
import {
getProducts
} from "@/api/store";
import Loading from "@/components/Loading";
export default {
@ -113,7 +94,8 @@ export default {
loadend: false,
price: 0,
stock: 0,
nows: false
nows: false,
recommendLoading: false
};
},
watch: {
@ -139,11 +121,16 @@ export default {
}
},
mounted: function () {
const { s = "", id = 0, title = "" } = this.$yroute.query;
const {
s = "", id = 0, title = ""
} = this.$yroute.query;
this.where.keyword = s;
this.updateTitle();
this.get_product_list();
},
onReachBottom() {
this.recommendLoading = true;
!this.loading && this.get_product_list();
},
onHide() {
@ -167,10 +154,15 @@ export default {
// this.nows = fals;
},
methods: {
changeRecommendLoading(recommendLoading) {
this.recommendLoading = recommendLoading
},
goGoodsCon(item) {
this.$yrouter.push({
path: "/pages/shop/GoodsCon/index",
query: { id: item.id }
query: {
id: item.id
}
});
},
updateTitle() {
@ -180,9 +172,10 @@ export default {
var that = this;
this.setWhere();
// if (to.name !== "GoodsList") return;
const { s = "", id = 0, title = "" } = this.$yroute.query;
const {
s = "", id = 0, title = ""
} = this.$yroute.query;
if (s !== this.where.keyword || id !== this.where.sid) {
this.where.keyword = s;
this.loadend = false;
this.loading = false;
this.where.page = 1;
@ -214,7 +207,9 @@ export default {
let that = this;
switch (index) {
case 0:
return that.$yrouter.push({ path: "/pages/shop/GoodsClass/index" });
return that.$yrouter.push({
path: "/pages/shop/GoodsClass/index"
});
case 1:
if (that.price === 0) that.price = 1;
else if (that.price === 1) that.price = 2;

2
unpackage/resources/__UNI__C7A519E/www/__uniappopenlocation.js

File diff suppressed because one or more lines are too long

2
unpackage/resources/__UNI__C7A519E/www/__uniapppicker.js

File diff suppressed because one or more lines are too long

8
unpackage/resources/__UNI__C7A519E/www/app-config-service.js

File diff suppressed because one or more lines are too long

4
unpackage/resources/__UNI__C7A519E/www/app-service.js

File diff suppressed because one or more lines are too long

2
unpackage/resources/__UNI__C7A519E/www/app-view.js

File diff suppressed because one or more lines are too long

2
unpackage/resources/__UNI__C7A519E/www/manifest.json

@ -1 +1 @@
{"@platforms":["android","iPhone","iPad"],"id":"__UNI__C7A519E","name":"yshopmall","version":{"name":"1.0.0","code":1},"description":"","launch_path":"__uniappview.html","developer":{"name":"","email":"","url":""},"permissions":{"OAuth":{},"Payment":{},"Share":{},"UniNView":{"description":"UniNView原生渲染"}},"plus":{"useragent":{"value":"uni-app","concatenate":true},"splashscreen":{"target":"id:1","autoclose":true,"waiting":true,"delay":0},"popGesture":"close","launchwebview":{"id":"1","kernel":"WKWebview"},"statusbar":{"immersed":"supportedDevice","style":"dark","background":"#F8F8F8"},"usingComponents":true,"nvueCompiler":"uni-app","compilerVersion":3,"allowsInlineMediaPlayback":true,"safearea":{"background":"#ffffff","bottom":{"offset":"auto"}},"uni-app":{"compilerVersion":"2.6.8","control":"uni-v3","nvueCompiler":"uni-app","renderer":"auto","nvue":{"flex-direction":"column"},"nvueLaunchMode":"normal"},"tabBar":{"color":"#282828","selectedColor":"#00c17b","borderStyle":"rgba(0,0,0,0.4)","backgroundColor":"#ffffff","height":"50px","fontSize":"10px","iconWidth":"24px","spacing":"3px","list":[{"pagePath":"pages/home/index","iconPath":"static/icon-home.png","selectedIconPath":"static/icon-home-hot.png","text":"首页"},{"pagePath":"pages/shop/GoodsClass/index","iconPath":"static/icon-class.png","selectedIconPath":"static/icon-class-hot.png","text":"分类"},{"pagePath":"pages/shop/ShoppingCart/index","iconPath":"static/icon-cart.png","selectedIconPath":"static/icon-cart-hot.png","text":"购物车"},{"pagePath":"pages/user/User/index","iconPath":"static/icon-user.png","selectedIconPath":"static/icon-user-hot.png","text":"我的"}]},"launch_path":"__uniappview.html"}}
{"@platforms":["android","iPhone","iPad"],"id":"__UNI__C7A519E","name":"yshopmall","version":{"name":"1.0.0","code":1},"description":"","launch_path":"__uniappview.html","developer":{"name":"","email":"","url":""},"permissions":{"OAuth":{},"Payment":{},"Share":{},"UniNView":{"description":"UniNView原生渲染"}},"plus":{"useragent":{"value":"uni-app","concatenate":true},"splashscreen":{"target":"id:1","autoclose":true,"waiting":false,"delay":0},"popGesture":"close","launchwebview":{"id":"1","kernel":"WKWebview"},"statusbar":{"immersed":"supportedDevice","style":"dark","background":"#F8F8F8"},"usingComponents":true,"nvueCompiler":"uni-app","compilerVersion":3,"allowsInlineMediaPlayback":true,"safearea":{"background":"#ffffff","bottom":{"offset":"auto"}},"uni-app":{"compilerVersion":"2.8.3","control":"uni-v3","nvueCompiler":"uni-app","renderer":"auto","nvue":{"flex-direction":"column"},"nvueLaunchMode":"normal"},"tabBar":{"color":"#282828","selectedColor":"#eb3729","borderStyle":"rgba(0,0,0,0.4)","backgroundColor":"#ffffff","height":"50px","fontSize":"10px","iconWidth":"24px","spacing":"3px","list":[{"pagePath":"pages/home/index","iconPath":"static/icon-home.png","selectedIconPath":"static/icon-home-hot.png","text":"首页"},{"pagePath":"pages/shop/GoodsClass/index","iconPath":"static/icon-class.png","selectedIconPath":"static/icon-class-hot.png","text":"分类"},{"pagePath":"pages/shop/ShoppingCart/index","iconPath":"static/icon-cart.png","selectedIconPath":"static/icon-cart-hot.png","text":"购物车"},{"pagePath":"pages/user/User/index","iconPath":"static/icon-user.png","selectedIconPath":"static/icon-user-hot.png","text":"我的"}]},"launch_path":"__uniappview.html"}}

BIN
unpackage/resources/__UNI__C7A519E/www/static/icon-cart-hot.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/icon-class-hot.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/icon-home-hot.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/icon-user-hot.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/dfh.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 2.2 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/dfk.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/dpj.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/dsh.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/group.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/h5.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.9 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/index-bg.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.0 KiB

After

Width:  |  Height:  |  Size: 4.8 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/integralbg.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/light.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

After

Width:  |  Height:  |  Size: 46 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/news.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.5 KiB

After

Width:  |  Height:  |  Size: 18 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/pricetitle.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

After

Width:  |  Height:  |  Size: 17 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/promotionBg.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.8 KiB

After

Width:  |  Height:  |  Size: 16 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/public.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.5 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/record1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/record2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/record3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/record4.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/redBg.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/sh.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 4.1 KiB

BIN
unpackage/resources/__UNI__C7A519E/www/static/images/writeOffBg.jpg

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.9 KiB

After

Width:  |  Height:  |  Size: 8.2 KiB

2
unpackage/resources/__UNI__C7A519E/www/view.css

File diff suppressed because one or more lines are too long

4
unpackage/resources/__UNI__C7A519E/www/view.umd.min.js vendored

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save