master
sws 2023-10-07 16:45:49 +08:00
parent fd3da01dc6
commit 02e7181363
18 changed files with 1123 additions and 1076 deletions

View File

@ -1135,7 +1135,7 @@ button[disabled].bg-grey {
.goods-data-grid-list .item .error-msg,
.goods-data-grid-list .item .goods-img {
height: 341rpx !important;
/* height: 341rpx !important; */
}
.goods-data-grid-list .item .error-msg {

View File

@ -2,153 +2,153 @@
*
*/
.plugins-coupon-container .item {
overflow: hidden;
height: 180rpx;
overflow: hidden;
height: 180rpx;
}
.plugins-coupon-container .v-left {
width: calc(100% - 140rpx);
padding: 30rpx 0 30rpx 20rpx;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
width: calc(100% - 140rpx);
padding: 30rpx 0 30rpx 20rpx;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
}
.plugins-coupon-container .v-left .base {
color: #D2364C;
color: #D2364C;
}
.plugins-coupon-container .v-left .base .symbol {
font-family: Verdana, Tahoma;
font-weight: 700;
font-family: Verdana, Tahoma;
font-weight: 700;
}
.plugins-coupon-container .v-left .base .price {
font-weight: 700;
font-family: arial;
font-size: 76rpx;
font-weight: 700;
font-family: arial;
font-size: 76rpx;
}
.plugins-coupon-container .v-left .base .unit {
margin-left: 5rpx;
margin-left: 5rpx;
}
.plugins-coupon-container .v-left .base .desc {
margin-left: 20rpx;
margin-left: 20rpx;
}
.plugins-coupon-container .v-left .base-tips,
.plugins-coupon-container .v-left .base-time {
margin-top: 10rpx;
margin-top: 10rpx;
}
.plugins-coupon-container .v-right {
background: #d2364c;
width: 140rpx;
height: 180rpx;
color: #fff;
font-weight: 500;
position: relative;
text-align: center;
background: #d2364c;
width: 140rpx;
height: 180rpx;
color: #fff;
font-weight: 500;
position: relative;
text-align: center;
}
.plugins-coupon-container .v-right:before {
content: '';
display: inline-block;
height: 100%;
vertical-align: middle;
content: '';
display: inline-block;
height: 100%;
vertical-align: middle;
}
.plugins-coupon-container .v-right .circle {
display: block;
position: absolute;
left: -1px;
top: -3px;
width: 3px;
height: 180rpx;
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAACpCAYAAADur4c3AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3NpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo3MjUzYzIwOS04ZWNlLTRlNTctODQ4OC01ZDExOTkwOGNkYmMiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MTM1QzgxREZGRDI5MTFFNTg3QjhGRUQ1MDY5OURERUQiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MTM1QzgxREVGRDI5MTFFNTg3QjhGRUQ1MDY5OURERUQiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChNYWNpbnRvc2gpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NTJiNzVkOGUtZDc2Yi00MzEzLWFmNmYtYTJkNTRlYTI4YTY1IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjcyNTNjMjA5LThlY2UtNGU1Ny04NDg4LTVkMTE5OTA4Y2RiYyIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pvy+vnQAAAEqSURBVHjaYvz//z8DDDAxIAFyOVeBOAHEYfyPMDsLmXMfmfMT2YADDP8h4CEQq4A4aUDMA1LNSKZDXwJxGcg1yJaWIXOeInO+IxuwA+acK0AsA+IEADEbic7hhPOAer4DcQcQMyNb2oLMeYVsADcyZwPMObuBWBTEsQFpI9E54sjO+QvEc0F+YoHKJgHxJ2TnvEM2gBmZswrmnA1AzAXiaJPhHC1k58BNQ3bBTGTOR2QD/iJzFsH8Mw/kHxBHggzn2KA7BxzWyC5Yisz5imwACmc2LLY7QbEN4nCS4ZwAIGZFds5lUEpEdsF6nKn3PTJnAsiAV0BcBsSM5GamFCDmQXYOOJ8iu2Anzrz9HKU8ABlwDYgTKcnbo0XNaFEzWtQgipqOYVLUAAQYAKPWa4c8cIHnAAAAAElFTkSuQmCC) no-repeat;
display: block;
position: absolute;
left: -1px;
top: -3px;
width: 3px;
height: 180rpx;
background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAACpCAYAAADur4c3AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA3NpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDE0IDc5LjE1MTQ4MSwgMjAxMy8wMy8xMy0xMjowOToxNSAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDo3MjUzYzIwOS04ZWNlLTRlNTctODQ4OC01ZDExOTkwOGNkYmMiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6MTM1QzgxREZGRDI5MTFFNTg3QjhGRUQ1MDY5OURERUQiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6MTM1QzgxREVGRDI5MTFFNTg3QjhGRUQ1MDY5OURERUQiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChNYWNpbnRvc2gpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NTJiNzVkOGUtZDc2Yi00MzEzLWFmNmYtYTJkNTRlYTI4YTY1IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjcyNTNjMjA5LThlY2UtNGU1Ny04NDg4LTVkMTE5OTA4Y2RiYyIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pvy+vnQAAAEqSURBVHjaYvz//z8DDDAxIAFyOVeBOAHEYfyPMDsLmXMfmfMT2YADDP8h4CEQq4A4aUDMA1LNSKZDXwJxGcg1yJaWIXOeInO+IxuwA+acK0AsA+IEADEbic7hhPOAer4DcQcQMyNb2oLMeYVsADcyZwPMObuBWBTEsQFpI9E54sjO+QvEc0F+YoHKJgHxJ2TnvEM2gBmZswrmnA1AzAXiaJPhHC1k58BNQ3bBTGTOR2QD/iJzFsH8Mw/kHxBHggzn2KA7BxzWyC5Yisz5imwACmc2LLY7QbEN4nCS4ZwAIGZFds5lUEpEdsF6nKn3PTJnAsiAV0BcBsSM5GamFCDmQXYOOJ8iu2Anzrz9HKU8ABlwDYgTKcnbo0XNaFEzWtQgipqOYVLUAAQYAKPWa4c8cIHnAAAAAElFTkSuQmCC) no-repeat;
}
.plugins-coupon-container .item-disabled .v-right {
background: #dfdfdf !important;
color: #c0c0c0 !important;
cursor: no-drop !important;
background: #dfdfdf !important;
color: #c0c0c0 !important;
cursor: no-drop !important;
}
/**
*
*/
.plugins-label {
z-index: 2;
box-sizing: border-box;
white-space: initial;
max-width: 100%;
z-index: 2;
box-sizing: border-box;
white-space: initial;
max-width: 100%;
}
.plugins-label-text {
padding: 10rpx 10rpx 0 10rpx;
padding: 10rpx 10rpx 0 10rpx;
}
.plugins-label .lv:not(:last-child) {
margin-right: 10rpx;
margin-right: 10rpx;
}
.plugins-label .lv {
margin-bottom: 10rpx;
margin-bottom: 10rpx;
}
.plugins-label-img.plugins-label-bottom-left .lv,
.plugins-label-img.plugins-label-bottom-center .lv,
.plugins-label-img.plugins-label-bottom-right .lv {
margin-bottom: 0;
margin-top: 10rpx;
margin-bottom: 0;
margin-top: 10rpx;
}
.plugins-label .lv view {
padding: 4rpx 12rpx;
-webkit-box-shadow: 0px 1px 2px -1px rgb(0 0 0 / 60%);
box-shadow: 0px 1px 2px -1px rgb(0 0 0 / 60%);
padding: 4rpx 12rpx;
-webkit-box-shadow: 0px 1px 2px -1px rgb(0 0 0 / 60%);
box-shadow: 0px 1px 2px -1px rgb(0 0 0 / 60%);
}
.plugins-label-img image {
width: 80rpx !important;
height: 80rpx !important;
width: 80rpx !important;
height: 80rpx !important;
}
.plugins-label-top-left {
left: 0;
top: 0;
left: 0;
top: 0;
}
.plugins-label-top-center {
left: 0;
top: 0;
width: 100%;
text-align: center;
left: 0;
top: 0;
width: 100%;
text-align: center;
}
.plugins-label-top-right {
top: 0;
right: 0;
top: 0;
right: 0;
}
.plugins-label-bottom-left,
.plugins-label-bottom-center,
.plugins-label-bottom-right {
bottom: calc(100% - 380rpx);
bottom: calc(100% - 380rpx);
}
.plugins-label-bottom-left {
left: 0;
left: 0;
}
.plugins-label-bottom-center {
width: 100%;
text-align: center;
width: 100%;
text-align: center;
}
.plugins-label-bottom-right {
right: 0;
right: 0;
}
/**
@ -157,24 +157,24 @@
.goods-data-rolling-list .plugins-label-bottom-left,
.goods-data-rolling-list .plugins-label-bottom-center,
.goods-data-rolling-list .plugins-label-bottom-right {
bottom: calc(100% - 240rpx) !;
bottom: calc(100% - 240rpx) !;
}
.goods-data-list .plugins-label-bottom-left,
.goods-data-list .plugins-label-bottom-center,
.goods-data-list .plugins-label-bottom-right {
bottom: 0;
bottom: 0;
}
/**
*
*/
.grayscale {
filter: grayscale(100%);
-webkit-filter: grayscale(100%);
-moz-filter: grayscale(100%);
-ms-filter: grayscale(100%);
-o-filter: grayscale(100%);
filter: grayscale(100%);
-webkit-filter: grayscale(100%);
-moz-filter: grayscale(100%);
-ms-filter: grayscale(100%);
-o-filter: grayscale(100%);
}
@ -182,12 +182,12 @@
* -
*/
.plugins-blog-list .blog-img {
width: 200rpx !important;
height: 170rpx !important;
width: 200rpx !important;
height: 170rpx !important;
}
.plugins-blog-list .base {
width: calc(100% - 220rpx);
width: calc(100% - 220rpx);
}
/*
@ -195,111 +195,111 @@
*/
.plugins-blog-rolling-list swiper,
.plugins-blog-rolling-list .item .blog-img {
height: 180rpx !important;
height: 180rpx !important;
}
.plugins-blog-rolling-list .item .blog-title {
left: 0;
bottom: 0;
width: calc(100% - 26rpx);
background-color: rgba(0, 0, 0, .5);
left: 0;
bottom: 0;
width: calc(100% - 26rpx);
background-color: rgba(0, 0, 0, .5);
}
/**
* -
*/
.plugins-blog-grid-list .item {
width: calc(50% - 10rpx);
float: left;
padding-bottom: 10rpx;
margin-bottom: 20rpx;
width: calc(50% - 10rpx);
float: left;
padding-bottom: 10rpx;
margin-bottom: 20rpx;
}
.plugins-blog-grid-list .item:nth-of-type(2n + 1) {
margin-right: 10rpx;
margin-right: 10rpx;
}
.plugins-blog-grid-list .item:nth-of-type(2n) {
margin-left: 10rpx;
margin-left: 10rpx;
}
.plugins-blog-grid-list .item .blog-img {
width: 100%;
height: 230rpx !important;
width: 100%;
/* height: 230rpx !important; */
}
/**
* -
*/
.plugins-realstore-data-list .item .address-content {
width: calc(100% - 60rpx);
width: calc(100% - 60rpx);
}
.plugins-realstore-data-list .item .icon-list {
right: 24rpx;
top: 36rpx;
right: 24rpx;
top: 36rpx;
}
.plugins-realstore-data-list .item .icon-list .icon-item {
width: 46rpx;
height: 46rpx;
width: 46rpx;
height: 46rpx;
}
.plugins-realstore-data-list .item .icon-item .badge-icon {
top: -10px;
right: 2px;
top: -10px;
right: 2px;
}
.plugins-realstore-data-list .item .icon-list .icon-item {
background: rgba(226, 44, 8, 0.08);
border-radius: 8rpx;
color: #E46248;
background: rgba(226, 44, 8, 0.08);
border-radius: 8rpx;
color: #E46248;
}
.plugins-realstore-data-list .item .icon-list .icon-item:not(:last-child) {
margin-right: 26rpx;
margin-right: 26rpx;
}
.plugins-realstore-data-list .item .logo {
width: 100rpx;
height: 100rpx !important;
width: 100rpx;
height: 100rpx !important;
}
.plugins-realstore-data-list .item .base-right {
padding-left: 14rpx;
padding-left: 14rpx;
}
.plugins-realstore-data-list .item .base-right .title {
width: calc(100% - 110rpx);
width: calc(100% - 110rpx);
}
/**
* -
*/
.plugins-shop-data-list .item .logo {
width: 100rpx;
height: 100rpx !important;
width: 100rpx;
height: 100rpx !important;
}
.plugins-shop-data-list .item .item-right-icon {
position: absolute;
right: 12px;
top: 50%;
transform: translateY(-50%);
position: absolute;
right: 12px;
top: 50%;
transform: translateY(-50%);
}
.plugins-shop-data-list .item .right-content {
padding-left: 14rpx;
margin-right: 50rpx;
padding-left: 14rpx;
margin-right: 50rpx;
}
.plugins-shop-data-list .item .auth-icon .icon {
width: 28rpx;
height: 28rpx !important;
margin-right: 10rpx;
width: 28rpx;
height: 28rpx !important;
margin-right: 10rpx;
}
.plugins-shop-data-list .item .desc {
min-height: 72rpx;
line-height: 36rpx;
min-height: 72rpx;
line-height: 36rpx;
}

View File

@ -1,95 +1,93 @@
<template>
<view>
<view v-if="(propConfig || null) != null && (propData || null) != null && propData.length > 0">
<block v-for="(floor, index) in propData" :key="index">
<block v-if="floor.blog_list.length > 0 && floor.home_data_location == propLocation">
<view class="plugins-blog" :class="floor.style_type == 2 ? 'bg-white border-radius-main padding-main spacing-mb' : ''">
<view class="spacing-nav-title flex-row align-c jc-sb text-size-xs">
<view class="title-left">
<text class="text-wrapper" :class="floor.style_type == 2 ? '' : 'title-left-border'" :style="'color:'+(floor.color || '#333')+';'">{{floor.title}}</text>
<text v-if="(floor.vice_title || null) != null" class="vice-name margin-left-sm cr-grey-9">{{floor.vice_title}}</text>
</view>
<navigator :url="floor.more_url" hover-class="none" class="arrow-right padding-right cr-grey">更多</navigator>
</view>
<view class="wh-auto oh pr">
<block v-if="floor.blog_list.length > 0">
<!-- 默认图文 -->
<block v-if="(floor.style_type || 0) == 0">
<view class="plugins-blog-list">
<view v-for="(item, index) in floor.blog_list" :key="index" class="item oh padding-main border-radius-main bg-white spacing-mb">
<navigator :url="item.url" hover-class="none">
<image class="blog-img fl radius" :src="item.cover" mode="aspectFill"></image>
<view class="base fr">
<view class="single-text text-size">{{item.title}}</view>
<view class="cr-grey-9 margin-top-sm text-size-xs">{{item.add_time_date_cn}}</view>
<view class="cr-base multi-text margin-top-sm text-size-xs">{{item.describe}}</view>
</view>
</navigator>
</view>
</view>
</block>
<!-- 九方格 -->
<block v-else-if="floor.style_type == 1">
<view class="plugins-blog-grid-list">
<view v-for="(item, index) in floor.blog_list" :key="index" class="item oh border-radius-main bg-white spacing-mb">
<navigator :url="item.url" hover-class="none">
<image class="blog-img dis-block" :src="item.cover" mode="aspectFit"></image>
<view class="base padding-horizontal-sm margin-top-sm">
<view class="goods-title multi-text margin-bottom-sm text-size-xs">{{item.title}}</view>
<view class="cr-grey text-size-xs">{{item.add_time_date_cn}}</view>
</view>
</navigator>
</view>
</view>
</block>
<!-- 滚动 -->
<view v-else-if="floor.style_type == 2" class="rolling-horizontal border-radius-main oh spacing-mb">
<view class="plugins-blog-rolling-list scroll-view-horizontal">
<swiper :vertical="false" :autoplay="(propConfig.is_home_hot_auto_play || 0) == 1" :circular="false"
:display-multiple-items="floor.blog_list.length < 3 ? floor.blog_list.length : 3" interval="3000">
<block v-for="(item, index) in floor.blog_list" :key="index">
<swiper-item>
<view class="item bg-white border-radius-main margin-right-main oh pr ht-auto pr">
<navigator :url="item.url" hover-class="none">
<image class="blog-img dis-block wh-auto" :src="item.cover" mode="aspectFill"></image>
<view class="blog-title pa single-text cr-white padding-sm text-size-xs">{{item.title}}</view>
</navigator>
</view>
</swiper-item>
</block>
</swiper>
</view>
</view>
</block>
</view>
</view>
</block>
</block>
</view>
</view>
<view>
<view v-if="(propConfig || null) != null && (propData || null) != null && propData.length > 0">
<block v-for="(floor, index) in propData" :key="index">
<block v-if="floor.blog_list.length > 0 && floor.home_data_location == propLocation">
<view class="plugins-blog" :class="floor.style_type == 2 ? 'bg-white border-radius-main padding-main spacing-mb' : ''">
<view class="spacing-nav-title flex-row align-c jc-sb text-size-xs">
<view class="title-left">
<text class="text-wrapper" :class="floor.style_type == 2 ? '' : 'title-left-border'" :style="'color:' + (floor.color || '#333') + ';'">{{ floor.title }}</text>
<text v-if="(floor.vice_title || null) != null" class="vice-name margin-left-sm cr-grey-9">{{ floor.vice_title }}</text>
</view>
<navigator :url="floor.more_url" hover-class="none" class="arrow-right padding-right cr-grey">更多</navigator>
</view>
<view class="wh-auto oh pr">
<block v-if="floor.blog_list.length > 0">
<!-- 默认图文 -->
<block v-if="(floor.style_type || 0) == 0">
<view class="plugins-blog-list">
<view v-for="(item, index) in floor.blog_list" :key="index" class="item oh padding-main border-radius-main bg-white spacing-mb">
<navigator :url="item.url" hover-class="none">
<image class="blog-img fl radius" :src="item.cover" mode="aspectFill"></image>
<view class="base fr">
<view class="single-text text-size">{{ item.title }}</view>
<view class="cr-grey-9 margin-top-sm text-size-xs">{{ item.add_time_date_cn }}</view>
<view class="cr-base multi-text margin-top-sm text-size-xs">{{ item.describe }}</view>
</view>
</navigator>
</view>
</view>
</block>
<!-- 九方格 -->
<block v-else-if="floor.style_type == 1">
<view class="plugins-blog-grid-list">
<view v-for="(item, index) in floor.blog_list" :key="index" class="item oh border-radius-main bg-white spacing-mb">
<navigator :url="item.url" hover-class="none">
<image class="blog-img dis-block" :src="item.cover" mode="widthFix"></image>
<view class="base padding-horizontal-sm margin-top-sm">
<view class="goods-title multi-text margin-bottom-sm text-size-xs">{{ item.title }}</view>
<view class="cr-grey text-size-xs">{{ item.add_time_date_cn }}</view>
</view>
</navigator>
</view>
</view>
</block>
<!-- 滚动 -->
<view v-else-if="floor.style_type == 2" class="rolling-horizontal border-radius-main oh spacing-mb">
<view class="plugins-blog-rolling-list scroll-view-horizontal">
<swiper :vertical="false" :autoplay="(propConfig.is_home_hot_auto_play || 0) == 1" :circular="false" :display-multiple-items="floor.blog_list.length < 3 ? floor.blog_list.length : 3" interval="3000">
<block v-for="(item, index) in floor.blog_list" :key="index">
<swiper-item>
<view class="item bg-white border-radius-main margin-right-main oh pr ht-auto pr">
<navigator :url="item.url" hover-class="none">
<image class="blog-img dis-block wh-auto" :src="item.cover" mode="aspectFill"></image>
<view class="blog-title pa single-text cr-white padding-sm text-size-xs">{{ item.title }}</view>
</navigator>
</view>
</swiper-item>
</block>
</swiper>
</view>
</view>
</block>
</view>
</view>
</block>
</block>
</view>
</view>
</template>
<script>
export default {
data() {
return {};
},
components: {},
props: {
propLocation: {
type: [String, Number],
default: 0
},
propConfig: {
type: [String, Object],
default: null
},
propData: {
type: Array,
default: []
}
},
methods: {}
};
export default {
data() {
return {};
},
components: {},
props: {
propLocation: {
type: [String, Number],
default: 0,
},
propConfig: {
type: [String, Object],
default: null,
},
propData: {
type: Array,
default: [],
},
},
methods: {},
};
</script>
<style>
</style>
<style></style>

View File

@ -50,157 +50,162 @@
</template>
<script>
const app = getApp();
var coupon_static_url = app.globalData.get_static_url("coupon", true);
export default {
name: "coupon-card",
props: {
propData: {
type: Object,
default: () => {
return {
// id: "0",
// //
// already_send_count: 0,
// //
// process_data: {
// type: 1, // 0
// value: 20,
// msg: "20%",
// },
// // // 2023.08.30-2023.09.1
// date: "",
// expire_tips: "",
// time_start: "",
// time_end: "",
};
const app = getApp();
var coupon_static_url = app.globalData.get_static_url('coupon', true);
export default {
name: 'coupon-card',
props: {
propData: {
type: Object,
default: () => {
return {
// id: "0",
// //
// already_send_count: 0,
// //
// process_data: {
// type: 1, // 0
// value: 20,
// msg: "20%",
// },
// // // 2023.08.30-2023.09.1
// date: "",
// expire_tips: "",
// time_start: "",
// time_end: "",
};
},
},
//
propRandom: {
type: Number,
default: 0,
},
//
propBg: {
type: String,
default: '#fff',
},
//
propIsProgress: {
type: Boolean,
default: false,
},
//
propRepeatedClaim: {
type: Boolean,
default: false,
},
//
propDisabled: {
type: Boolean,
default: false,
},
//
propIndex: {
type: Number,
default: 1,
},
// 0-1-2-3-使,4-使5-
propStatusType: {
type: Number,
default: 0,
},
// 使
propStatusOperableName: {
type: String,
default: '去使用',
},
},
//
propBg: {
type: String,
default: "#fff",
data() {
return {
coupon_static_url: coupon_static_url,
//
currency_symbol: app.globalData.data.currency_symbol,
//
home_page_url: app.globalData.data.tabbar_pages[0],
};
},
//
propIsProgress: {
type: Boolean,
default: false,
methods: {
receive(e) {
this.$emit('call-back', this.propIndex, this.propData.id);
},
},
//
propRepeatedClaim: {
type: Boolean,
default: false,
},
//
propDisabled: {
type: Boolean,
default: false,
},
//
propIndex: {
type: Number,
default: 1,
},
// 0-1-2-3-使,4-使5-
propStatusType: {
type: Number,
default: 0,
},
// 使
propStatusOperableName: {
type: String,
default: "去使用",
},
},
data() {
return {
coupon_static_url: coupon_static_url,
//
currency_symbol: app.globalData.data.currency_symbol,
//
home_page_url: app.globalData.data.tabbar_pages[0],
};
},
methods: {
receive(e) {
this.$emit("call-back", this.propIndex, this.propData.id);
},
},
};
};
</script>
<style scoped>
.coupon-card {
border-radius: 24rpx;
height: 208rpx;
}
.coupon-card {
border-radius: 24rpx;
height: 208rpx;
}
.card-left {
width: 176rpx;
padding: 24rpx 12rpx;
background: linear-gradient(95deg, #ff994b 0%, #ff6e00 100%);
}
.card-left {
width: 176rpx;
padding: 24rpx 12rpx;
background: linear-gradient(95deg, #ff994b 0%, #ff6e00 100%);
}
.card-left.failure {
background: linear-gradient(95deg, #eeeeee 0%, #fafafa 100%);
}
.card-left.failure {
background: linear-gradient(95deg, #eeeeee 0%, #fafafa 100%);
}
.card-right {
padding: 32rpx 24rpx 32rpx 46rpx;
background-color: #ffe4d1;
}
.card-right {
padding: 32rpx 24rpx 32rpx 46rpx;
background-color: #ffe4d1;
}
.card-right.failure {
background: #ffffff;
}
.card-right.failure {
background: #ffffff;
}
.card-info.failure {
padding-right: 116rpx;
}
.card-info.failure {
padding-right: 116rpx;
}
.card-btn {
width: 116rpx;
text-align: center;
padding: 6rpx 0;
background: linear-gradient(93deg, #ff9747 0%, #ff6e01 100%);
border-radius: 13px;
}
.card-btn {
width: 116rpx;
text-align: center;
padding: 6rpx 0;
background: linear-gradient(93deg, #ff9747 0%, #ff6e01 100%);
border-radius: 13px;
}
.robbed {
background: #fbd3b7;
}
.robbed {
background: #fbd3b7;
}
.received {
border-radius: 13px;
background: transparent;
}
.received {
border-radius: 13px;
background: transparent;
}
::v-deep .uni-progress-bar,
::v-deep .uni-progress-inner-bar {
border-radius: 6rpx;
}
::v-deep .uni-progress-bar,
::v-deep .uni-progress-inner-bar {
border-radius: 6rpx;
}
.card-circle-top,
.card-circle-bottom {
width: 40rpx;
height: 40rpx;
background-color: #fff;
border-radius: 50%;
position: absolute;
left: 180rpx;
z-index: 1;
}
.card-circle-top,
.card-circle-bottom {
width: 40rpx;
height: 40rpx;
background-color: #fff;
border-radius: 50%;
position: absolute;
left: 180rpx;
z-index: 1;
}
.card-circle-top {
top: -20rpx;
}
.card-circle-top {
top: -20rpx;
}
.card-circle-bottom {
bottom: -20rpx;
}
.card-circle-bottom {
bottom: -20rpx;
}
.card-image image {
width: 136rpx;
height: 108rpx;
}
.card-image image {
width: 136rpx;
height: 108rpx;
}
</style>

View File

@ -60,7 +60,7 @@
<view v-for="(item, index) in data.goods_list" :key="index" class="item oh border-radius-main bg-white oh pr spacing-mb">
<!-- 商品主体内容 -->
<view class="cp" :data-value="item.goods_url" @tap="url_event">
<image class="goods-img dis-block wh-auto" :src="item.images" mode="scaleToFill"></image>
<image class="goods-img dis-block wh-auto" :src="item.images" mode="widthFix"></image>
<view class="base padding-horizontal-main margin-top-sm">
<view class="goods-title multi-text">{{ item.title }}</view>
<view class="margin-top-sm flex-row jc-sb align-c">

View File

@ -1,87 +1,90 @@
<template>
<view>
<view class="more cr-black padding-top-main padding-bottom-sm flex-row flex-warp align-c" @tap="open_popup">
<text>更多</text>
<iconfont name="icon-fenlei-more"></iconfont>
</view>
<!-- 弹窗 -->
<component-popup :propShow="popup_status" :propIsBar="propIsBar" propPosition="top" :propMask="true" :propTop="propTop" @onclose="quick_close_event">
<view class="padding-vertical-lg">
<view class="padding-left-main padding-bottom-main">全部分类</view>
<view class="divider-b">
<slot></slot>
</view>
<view class="tc padding-top-lg" @tap="quick_close_event">
<text class="padding-right-sm">点击收起</text>
<iconfont name="icon-fenlei-top" color="#ccc"></iconfont>
</view>
</view>
</component-popup>
</view>
<view>
<view class="more cr-black padding-top-main padding-bottom-sm flex-row flex-warp align-c" :class="propClass" @tap="open_popup">
<text>更多</text>
<iconfont name="icon-fenlei-more"></iconfont>
</view>
<!-- 弹窗 -->
<component-popup :propShow="popup_status" :propIsBar="propIsBar" propPosition="top" :propMask="true" :propTop="propTop" @onclose="quick_close_event">
<view class="padding-vertical-lg">
<view class="padding-left-main padding-bottom-main">全部分类</view>
<view class="divider-b">
<slot></slot>
</view>
<view class="tc padding-top-lg" @tap="quick_close_event">
<text class="padding-right-sm">点击收起</text>
<iconfont name="icon-fenlei-top" color="#ccc"></iconfont>
</view>
</view>
</component-popup>
</view>
</template>
<script>
import componentPopup from "../popup/popup";
export default {
name: "more",
components: {
componentPopup
},
props: {
propData: {
type: Array,
default: () => {
return []
}
},
propTop: {
type: String,
default: ''
},
propStatus: {
type: Boolean,
default: false
}
},
watch: {
propStatus(newVal, oldVal) {
if (newVal !== oldVal) {
this.setData({
popup_status: newVal
});
}
}
},
data() {
return {
popup_status: false,
propIsBar: false
};
},
methods: {
//
open_popup() {
this.$emit('open-popup', true);
},
//
quick_close_event(e) {
this.$emit('open-popup', false);
},
}
}
import componentPopup from '../popup/popup';
export default {
name: 'more',
components: {
componentPopup,
},
props: {
propData: {
type: Array,
default: () => {
return [];
},
},
propTop: {
type: String,
default: '',
},
propStatus: {
type: Boolean,
default: false,
},
propClass: {
type: String,
default: '',
},
},
watch: {
propStatus(newVal, oldVal) {
if (newVal !== oldVal) {
this.setData({
popup_status: newVal,
});
}
},
},
data() {
return {
popup_status: false,
propIsBar: false,
};
},
methods: {
//
open_popup() {
this.$emit('open-popup', true);
},
//
quick_close_event(e) {
this.$emit('open-popup', false);
},
},
};
</script>
<style scoped>
.more {
width: 30rpx;
/* background-color: #fff; */
padding: 15rpx 20rpx;
position: absolute;
top: 0;
bottom: 0;
right: 0;
z-index: 101;
white-space: normal;
word-break: break-all;
}
</style>
.more {
width: 30rpx;
padding: 15rpx 20rpx;
position: absolute;
top: 0;
bottom: 0;
right: 0;
z-index: 101;
white-space: normal;
word-break: break-all;
}
</style>

View File

@ -299,6 +299,9 @@
"pages": [{
"path": "index/index",
"style": {
// #ifdef MP-WEIXIN || MP-BAIDU || MP-QQ || MP-KUAISHOU || H5 || APP
"navigationStyle": "custom",
// #endif
"navigationBarTitleText": "限时秒杀"
}
}]

View File

@ -8,7 +8,7 @@
<block v-if="is_single_page == 0">
<view class="nav-search padding-horizontal-main pr" :style="'padding-top:' + (status_bar_height + 5) + 'px;'">
<view class="goods-top-search-bg pa top-0 left-0 right-0 bottom-0 wh-auto">
<image :src="theme_static_url + 'goods-top-bg.png'" mode="top" class="wh-auto ht-auto"></image>
<image :src="theme_static_url + 'goods-top-bg.png'" mode="scaleToFill" class="wh-auto ht-auto"></image>
</view>
<block v-if="is_goods_category_search_alone == 1">
<component-search propPlaceholder="输入商品名称搜索"></component-search>
@ -338,7 +338,7 @@
</view>
</block>
<!-- 购物车底部导航 -->
<view class="botton-nav round pa oh flex-row jc-sb align-c z-i">
<view class="botton-nav round pa oh flex-row jc-sb align-c">
<view class="flex-row align-c flex-1 flex-width">
<view class="cart pr cp top-sm" @tap="cart_event">
<iconfont name="icon-applet-shop-acquiesce" size="36rpx" color="#666"></iconfont>

View File

@ -2,15 +2,11 @@
*
*/
.data-list {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
display: flex;
flex-flow: row wrap;
justify-content: space-between;
}
.data-list .item {
width: calc(50% - 10rpx);
}
.data-list .item image {
width: 100%;
width: calc(50% - 10rpx);
}

View File

@ -1,270 +1,265 @@
<template>
<view>
<view v-if="(data_base || null) != null">
<!-- 轮播 -->
<view v-if="slider_list.length > 0" class="padding-horizontal-main padding-top-main">
<component-banner :propData="slider_list" propSize="mini"></component-banner>
</view>
<view>
<view v-if="(data_base || null) != null">
<!-- 轮播 -->
<view v-if="slider_list.length > 0" class="padding-horizontal-main padding-top-main">
<component-banner :propData="slider_list" propSize="mini"></component-banner>
</view>
<!-- 分类 -->
<scroll-view v-if="(activity_category || null) != null && activity_category.length > 0" class="scroll-view-horizontal bg-white oh" scroll-x="true">
<view :class="'item cr-grey dis-inline-block padding-horizontal-main padding-top-main padding-bottom-sm ' + (nav_active_value == 0 ? 'cr-main nav-active-line bg-main-befor fw-b' : '')"
@tap="nav_event" data-value="0">全部
</view>
<block v-for="(item, index) in activity_category" :key="index">
<view
:class="'item cr-grey dis-inline-block padding-horizontal-main padding-top-main padding-bottom-sm ' + (nav_active_value == item.id ? 'cr-main nav-active-line bg-main-befor fw-b' : '')"
@tap="nav_event" :data-value="item.id">{{item.name}}</view>
</block>
</scroll-view>
<!-- 分类 -->
<scroll-view v-if="(activity_category || null) != null && activity_category.length > 0" class="scroll-view-horizontal bg-white oh" scroll-x="true">
<view :class="'item cr-grey dis-inline-block padding-horizontal-main padding-top-main padding-bottom-sm ' + (nav_active_value == 0 ? 'cr-main nav-active-line bg-main-befor fw-b' : '')" @tap="nav_event" data-value="0">全部 </view>
<block v-for="(item, index) in activity_category" :key="index">
<view :class="'item cr-grey dis-inline-block padding-horizontal-main padding-top-main padding-bottom-sm ' + (nav_active_value == item.id ? 'cr-main nav-active-line bg-main-befor fw-b' : '')" @tap="nav_event" :data-value="item.id">{{ item.name }}</view>
</block>
</scroll-view>
<!-- 列表 -->
<scroll-view :scroll-y="true" class="scroll-box scroll-box-ece-nav" @scrolltolower="scroll_lower" lower-threshold="30"
:style="slider_list.length > 0 ? 'height:calc(100vh - 320rpx);' : ''">
<view v-if="(data_list || null) != null && data_list.length > 0" class="data-list padding-horizontal-main padding-top-main oh">
<block v-for="(item, index) in data_list" :key="index">
<view class="item border-radius-main oh spacing-mb">
<navigator :url="'/pages/plugins/activity/detail/detail?id=' + item.id" hover-class="none">
<image :src="item.cover" mode="widthFix"></image>
</navigator>
</view>
</block>
</view>
<view v-else>
<!-- 提示信息 -->
<component-no-data :propStatus="data_list_loding_status" :propMsg="data_list_loding_msg"></component-no-data>
</view>
<!-- 列表 -->
<scroll-view :scroll-y="true" class="scroll-box scroll-box-ece-nav" @scrolltolower="scroll_lower" lower-threshold="30" :style="slider_list.length > 0 ? 'height:calc(100vh - 320rpx);' : ''">
<view v-if="(data_list || null) != null && data_list.length > 0" class="data-list padding-horizontal-main padding-top-main oh">
<block v-for="(item, index) in data_list" :key="index">
<view class="item oh spacing-mb">
<navigator :url="'/pages/plugins/activity/detail/detail?id=' + item.id" hover-class="none">
<image :src="item.cover" mode="widthFix" class="wh-auto border-radius-main"></image>
</navigator>
</view>
</block>
</view>
<view v-else>
<!-- 提示信息 -->
<component-no-data :propStatus="data_list_loding_status" :propMsg="data_list_loding_msg"></component-no-data>
</view>
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
</scroll-view>
</view>
</view>
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
</scroll-view>
</view>
</view>
</template>
<script>
const app = getApp();
import componentBanner from "../../../../components/slider/slider";
import componentNoData from "../../../../components/no-data/no-data";
import componentBottomLine from "../../../../components/bottom-line/bottom-line";
const app = getApp();
import componentBanner from '../../../../components/slider/slider';
import componentNoData from '../../../../components/no-data/no-data';
import componentBottomLine from '../../../../components/bottom-line/bottom-line';
export default {
data() {
return {
data_list_loding_status: 1,
data_list_loding_msg: '',
data_bottom_line_status: false,
data_is_loading: 0,
data_list: [],
data_total: 0,
data_page_total: 0,
data_page: 1,
params: null,
data_base: null,
slider_list: [],
activity_category: [],
nav_active_value: 0,
//
share_info: {}
};
},
export default {
data() {
return {
data_list_loding_status: 1,
data_list_loding_msg: '',
data_bottom_line_status: false,
data_is_loading: 0,
data_list: [],
data_total: 0,
data_page_total: 0,
data_page: 1,
params: null,
data_base: null,
slider_list: [],
activity_category: [],
nav_active_value: 0,
//
share_info: {},
};
},
components: {
componentBanner,
componentNoData,
componentBottomLine
},
props: {},
components: {
componentBanner,
componentNoData,
componentBottomLine,
},
props: {},
onLoad(params) {
this.setData({
params: params
});
onLoad(params) {
this.setData({
params: params,
});
//
this.get_data();
},
//
this.get_data();
},
//
onPullDownRefresh() {
this.setData({
data_page: 1
});
this.get_data_list(1);
},
//
onPullDownRefresh() {
this.setData({
data_page: 1,
});
this.get_data_list(1);
},
methods: {
//
get_data() {
uni.showLoading({
title: '加载中...'
});
uni.request({
url: app.globalData.get_request_url("index", "index", "activity"),
method: 'POST',
data: {},
dataType: 'json',
success: res => {
uni.hideLoading();
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
this.setData({
data_base: data.base || null,
slider_list: data.slider_list || [],
activity_category: data.activity_category || []
});
methods: {
//
get_data() {
uni.showLoading({
title: '加载中...',
});
uni.request({
url: app.globalData.get_request_url('index', 'index', 'activity'),
method: 'POST',
data: {},
dataType: 'json',
success: (res) => {
uni.hideLoading();
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
this.setData({
data_base: data.base || null,
slider_list: data.slider_list || [],
activity_category: data.activity_category || [],
});
if ((this.data_base || null) != null) {
//
this.setData({
share_info: {
title: this.data_base.seo_title || this.data_base.application_name,
desc: this.data_base.seo_desc,
path: '/pages/plugins/activity/index/index'
}
});
if ((this.data_base || null) != null) {
//
this.setData({
share_info: {
title: this.data_base.seo_title || this.data_base.application_name,
desc: this.data_base.seo_desc,
path: '/pages/plugins/activity/index/index',
},
});
//
if ((this.data_base.application_name || null) != null) {
uni.setNavigationBarTitle({
title: this.data_base.application_name
});
}
}
//
if ((this.data_base.application_name || null) != null) {
uni.setNavigationBarTitle({
title: this.data_base.application_name,
});
}
}
//
this.get_data_list(1);
} else {
this.setData({
data_list_loding_status: 0,
data_list_loding_msg: res.data.msg
});
app.globalData.showToast(res.data.msg);
}
//
this.get_data_list(1);
} else {
this.setData({
data_list_loding_status: 0,
data_list_loding_msg: res.data.msg,
});
app.globalData.showToast(res.data.msg);
}
//
app.globalData.page_share_handle(this.share_info);
},
fail: () => {
uni.hideLoading();
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2
});
app.globalData.showToast('服务器请求出错');
}
});
},
//
app.globalData.page_share_handle(this.share_info);
},
fail: () => {
uni.hideLoading();
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2,
});
app.globalData.showToast('服务器请求出错');
},
});
},
//
get_data_list(is_mandatory) {
//
if ((is_mandatory || 0) == 0) {
if (this.data_bottom_line_status == true) {
uni.stopPullDownRefresh();
return false;
}
}
//
get_data_list(is_mandatory) {
//
if ((is_mandatory || 0) == 0) {
if (this.data_bottom_line_status == true) {
uni.stopPullDownRefresh();
return false;
}
}
//
if (this.data_is_loading == 1) {
return false;
}
this.setData({
data_is_loading: 1
});
//
if (this.data_is_loading == 1) {
return false;
}
this.setData({
data_is_loading: 1,
});
// loding
uni.showLoading({
title: '加载中...'
});
// loding
uni.showLoading({
title: '加载中...',
});
//
uni.request({
url: app.globalData.get_request_url("datalist", "index", "activity"),
method: 'POST',
data: {
page: this.data_page,
category_id: this.nav_active_value || 0
},
dataType: 'json',
success: res => {
uni.hideLoading();
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
if (data.data.length > 0) {
if (this.data_page <= 1) {
var temp_data_list = data.data;
} else {
var temp_data_list = this.data_list || [];
var temp_data = data.data || [];
for (var i in temp_data) {
temp_data_list.push(temp_data[i]);
}
}
this.setData({
data_list: temp_data_list,
data_total: data.total,
data_page_total: data.page_total,
data_list_loding_status: 3,
data_page: this.data_page + 1,
data_is_loading: 0
});
//
uni.request({
url: app.globalData.get_request_url('datalist', 'index', 'activity'),
method: 'POST',
data: {
page: this.data_page,
category_id: this.nav_active_value || 0,
},
dataType: 'json',
success: (res) => {
uni.hideLoading();
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
if (data.data.length > 0) {
if (this.data_page <= 1) {
var temp_data_list = data.data;
} else {
var temp_data_list = this.data_list || [];
var temp_data = data.data || [];
for (var i in temp_data) {
temp_data_list.push(temp_data[i]);
}
}
this.setData({
data_list: temp_data_list,
data_total: data.total,
data_page_total: data.page_total,
data_list_loding_status: 3,
data_page: this.data_page + 1,
data_is_loading: 0,
});
//
this.setData({
data_bottom_line_status: (this.data_page > 1 && this.data_page > this.data_page_total)
});
} else {
this.setData({
data_list_loding_status: 0,
data_is_loading: 0
});
if (this.data_page <= 1) {
this.setData({
data_list: [],
data_bottom_line_status: false
});
}
}
} else {
this.setData({
data_list_loding_status: 0,
data_list_loding_msg: res.data.msg,
data_is_loading: 0
});
app.globalData.showToast(res.data.msg);
}
},
fail: () => {
uni.hideLoading();
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2,
data_is_loading: 0
});
app.globalData.showToast('服务器请求出错');
}
});
},
//
this.setData({
data_bottom_line_status: this.data_page > 1 && this.data_page > this.data_page_total,
});
} else {
this.setData({
data_list_loding_status: 0,
data_is_loading: 0,
});
if (this.data_page <= 1) {
this.setData({
data_list: [],
data_bottom_line_status: false,
});
}
}
} else {
this.setData({
data_list_loding_status: 0,
data_list_loding_msg: res.data.msg,
data_is_loading: 0,
});
app.globalData.showToast(res.data.msg);
}
},
fail: () => {
uni.hideLoading();
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2,
data_is_loading: 0,
});
app.globalData.showToast('服务器请求出错');
},
});
},
//
scroll_lower(e) {
this.get_data_list();
},
//
scroll_lower(e) {
this.get_data_list();
},
//
nav_event(e) {
this.setData({
nav_active_value: e.currentTarget.dataset.value || 0,
data_page: 1
});
this.get_data_list(1);
}
}
};
//
nav_event(e) {
this.setData({
nav_active_value: e.currentTarget.dataset.value || 0,
data_page: 1,
});
this.get_data_list(1);
},
},
};
</script>
<style>
@import './index.css';
</style>
@import './index.css';
</style>

View File

@ -1,202 +1,201 @@
<template>
<view>
<view v-if="(data_base || null) != null">
<view class="pr">
<!-- 分类 -->
<scroll-view v-if="(brand_category_list || null) != null && brand_category_list.length > 0" class="nav-list scroll-view-horizontal bg-white oh" scroll-x="true">
<view class="flex-row flex-nowrap align-c">
<block v-for="(item, index) in brand_category_list" :key="index">
<view class="item flex-col align-c text-size-xss" @tap="nav_event" :data-value="item.id">
<image :src="item.icon" mode="aspectFit"></image>
<view class="padding-left-sm padding-right-sm round" :class="nav_active_value == item.id ? 'bg-main cr-white' : ''">
{{item.name}}
</view>
</view>
</block>
</view>
</scroll-view>
<component-nav-more :prop-status="popupStatus" @open-popup="open_popup_event">
<view class="nav-list-more">
<view class="flex-row flex-warp align-c">
<block v-for="(item, index) in brand_category_list" :key="index">
<view class="item flex-col align-c text-size-xss" @tap="nav_event" :data-value="item.id">
<image :src="item.icon" mode="aspectFit"></image>
<view class="padding-left-sm padding-right-sm round" :class="nav_active_value == item.id ? 'bg-main cr-white' : ''">
{{item.name}}
</view>
</view>
</block>
</view>
</view>
</component-nav-more>
</view>
<view>
<view v-if="(data_base || null) != null">
<view class="pr">
<!-- 分类 -->
<scroll-view v-if="(brand_category_list || null) != null && brand_category_list.length > 0" class="nav-list scroll-view-horizontal bg-white oh" scroll-x="true">
<view class="flex-row flex-nowrap align-c">
<block v-for="(item, index) in brand_category_list" :key="index">
<view class="item flex-col align-c text-size-xss" @tap="nav_event" :data-value="item.id">
<image :src="item.icon" mode="aspectFit"></image>
<view class="padding-left-sm padding-right-sm round" :class="nav_active_value == item.id ? 'bg-main cr-white' : ''">
{{ item.name }}
</view>
</view>
</block>
</view>
</scroll-view>
<component-nav-more prop-class="bg-white" :prop-status="popupStatus" @open-popup="open_popup_event">
<view class="nav-list-more">
<view class="flex-row flex-warp align-c">
<block v-for="(item, index) in brand_category_list" :key="index">
<view class="item flex-col align-c text-size-xss" @tap="nav_event" :data-value="item.id">
<image :src="item.icon" mode="aspectFit"></image>
<view class="padding-left-sm padding-right-sm round" :class="nav_active_value == item.id ? 'bg-main cr-white' : ''">
{{ item.name }}
</view>
</view>
</block>
</view>
</view>
</component-nav-more>
</view>
<!-- 列表 -->
<view v-if="(brand_list || null) != null && brand_list.length > 0" class="data-list padding-horizontal-main padding-top-main oh">
<block v-for="(item, index) in brand_list" :key="index">
<view v-if="(item.is_not_show || 0) == 0" class="item border-radius-main bg-white oh spacing-mb">
<navigator :url="'/pages/goods-search/goods-search?brand=' + item.id" hover-class="none">
<image :src="item.logo" mode="aspectFit"></image>
<view class="padding-main tc">
<view class="single-text fw-b cr-base">{{item.name}}</view>
</view>
</navigator>
</view>
</block>
</view>
<!-- 列表 -->
<view v-if="(brand_list || null) != null && brand_list.length > 0" class="data-list padding-horizontal-main padding-top-main oh">
<block v-for="(item, index) in brand_list" :key="index">
<view v-if="(item.is_not_show || 0) == 0" class="item border-radius-main bg-white oh spacing-mb">
<navigator :url="'/pages/goods-search/goods-search?brand=' + item.id" hover-class="none">
<image :src="item.logo" mode="aspectFit"></image>
<view class="padding-main tc">
<view class="single-text fw-b cr-base">{{ item.name }}</view>
</view>
</navigator>
</view>
</block>
</view>
<!-- 提示信息 -->
<component-no-data :propStatus="data_list_loding_status"></component-no-data>
<!-- 提示信息 -->
<component-no-data :propStatus="data_list_loding_status"></component-no-data>
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
</view>
</view>
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
</view>
</view>
</template>
<script>
const app = getApp();
import componentNoData from "../../../../components/no-data/no-data";
import componentBottomLine from "../../../../components/bottom-line/bottom-line";
import componentNavMore from "../../../../components/nav-more/nav-more";
const app = getApp();
import componentNoData from '../../../../components/no-data/no-data';
import componentBottomLine from '../../../../components/bottom-line/bottom-line';
import componentNavMore from '../../../../components/nav-more/nav-more';
export default {
data() {
return {
data_bottom_line_status: false,
data_list_loding_status: 1,
data_list_loding_msg: '',
params: null,
data_base: null,
brand_list: [],
brand_category_list: [],
nav_active_value: 0,
//
share_info: {},
popupStatus: false,
};
},
export default {
data() {
return {
data_bottom_line_status: false,
data_list_loding_status: 1,
data_list_loding_msg: '',
params: null,
data_base: null,
brand_list: [],
brand_category_list: [],
nav_active_value: 0,
//
share_info: {},
popupStatus: false,
};
},
components: {
componentNoData,
componentBottomLine,
componentNavMore
},
props: {},
components: {
componentNoData,
componentBottomLine,
componentNavMore,
},
props: {},
onLoad(params) {
this.setData({
params: params
});
},
onLoad(params) {
this.setData({
params: params,
});
},
onShow() {
this.get_data();
},
onShow() {
this.get_data();
},
//
onPullDownRefresh() {
this.get_data();
},
//
onPullDownRefresh() {
this.get_data();
},
methods: {
//
get_data() {
uni.request({
url: app.globalData.get_request_url("index", "index", "brand"),
method: 'POST',
data: {},
dataType: 'json',
success: res => {
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
var brand_list = data.brand_list || [];
this.setData({
data_base: data.base || null,
brand_list: brand_list,
brand_category_list: data.brand_category_list || [],
data_list_loding_msg: '',
data_list_loding_status: brand_list.length > 0 ? 3 : 0,
data_bottom_line_status: brand_list.length > 0
});
methods: {
//
get_data() {
uni.request({
url: app.globalData.get_request_url('index', 'index', 'brand'),
method: 'POST',
data: {},
dataType: 'json',
success: (res) => {
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
var brand_list = data.brand_list || [];
this.setData({
data_base: data.base || null,
brand_list: brand_list,
brand_category_list: data.brand_category_list || [],
data_list_loding_msg: '',
data_list_loding_status: brand_list.length > 0 ? 3 : 0,
data_bottom_line_status: brand_list.length > 0,
});
//
this.setData({
share_info: {
title: this.data_base.seo_title || this.data_base.application_name,
desc: this.data_base.seo_desc,
path: '/pages/plugins/brand/index/index'
}
});
//
this.setData({
share_info: {
title: this.data_base.seo_title || this.data_base.application_name,
desc: this.data_base.seo_desc,
path: '/pages/plugins/brand/index/index',
},
});
//
this.nav_active_handle();
//
this.nav_active_handle();
//
app.globalData.page_share_handle(this.share_info);
} else {
this.setData({
data_bottom_line_status: false,
data_list_loding_status: 2,
data_list_loding_msg: res.data.msg
});
}
},
fail: () => {
uni.stopPullDownRefresh();
this.setData({
data_bottom_line_status: false,
data_list_loding_status: 2,
data_list_loding_msg: '服务器请求出错'
});
app.globalData.showToast('服务器请求出错');
}
});
},
//
app.globalData.page_share_handle(this.share_info);
} else {
this.setData({
data_bottom_line_status: false,
data_list_loding_status: 2,
data_list_loding_msg: res.data.msg,
});
}
},
fail: () => {
uni.stopPullDownRefresh();
this.setData({
data_bottom_line_status: false,
data_list_loding_status: 2,
data_list_loding_msg: '服务器请求出错',
});
app.globalData.showToast('服务器请求出错');
},
});
},
//
nav_event(e) {
this.setData({
nav_active_value: e.currentTarget.dataset.value || 0,
popupStatus: false
});
this.nav_active_handle();
},
//
open_popup_event(e) {
this.setData({
popupStatus: e
});
},
//
nav_event(e) {
this.setData({
nav_active_value: e.currentTarget.dataset.value || 0,
popupStatus: false,
});
this.nav_active_handle();
},
//
open_popup_event(e) {
this.setData({
popupStatus: e,
});
},
//
nav_active_handle() {
var value = this.nav_active_value;
var temp_brand_list = this.brand_list;
var count = 0;
for (var i in temp_brand_list) {
if (value == 0) {
temp_brand_list[i]['is_not_show'] = 0;
count++;
} else {
var is_not_show = temp_brand_list[i]['brand_category_ids'].indexOf(value) == -1 ? 1 : 0;
temp_brand_list[i]['is_not_show'] = is_not_show;
if (is_not_show == 0) {
count++;
}
}
}
//
nav_active_handle() {
var value = this.nav_active_value;
var temp_brand_list = this.brand_list;
var count = 0;
for (var i in temp_brand_list) {
if (value == 0) {
temp_brand_list[i]['is_not_show'] = 0;
count++;
} else {
var is_not_show = temp_brand_list[i]['brand_category_ids'].indexOf(value) == -1 ? 1 : 0;
temp_brand_list[i]['is_not_show'] = is_not_show;
if (is_not_show == 0) {
count++;
}
}
}
this.setData({
brand_list: temp_brand_list,
data_list_loding_status: count > 0 ? 3 : 0,
data_bottom_line_status: count > 0
});
}
}
};
this.setData({
brand_list: temp_brand_list,
data_list_loding_status: count > 0 ? 3 : 0,
data_bottom_line_status: count > 0,
});
},
},
};
</script>
<style>
@import './index.css';
</style>
@import './index.css';
</style>

View File

@ -4,11 +4,11 @@
<image class="wh-auto dis-block border-radius-main" :src="data_base.banner_images" mode="widthFix" :data-value="data_base.url || ''" @tap="url_event"></image>
</view>
<view class="plugins-coupon-container">
<scroll-view scroll-y class="coupon-content bg-white">
<scroll-view scroll-y class="coupon-content bg-white pr">
<!-- 优惠劵列表 -->
<view v-if="data_list.length > 0" class="flex-col">
<block v-for="(item, index) in data_list" :key="index">
<component-poupon-card :prop-data="item" :prop-status-type="item.status_type" :prop-status-operable-name="item.status_operable_name" :prop-index="index" propIsProgress @call-back="coupon_receive_event"></component-poupon-card>
<component-coupon-card :prop-data="item" :prop-status-type="item.status_type" :prop-status-operable-name="item.status_operable_name" :prop-index="index" propIsProgress @call-back="coupon_receive_event"></component-coupon-card>
</block>
</view>
<view v-else>
@ -31,7 +31,7 @@
const app = getApp();
import componentNoData from '../../../../components/no-data/no-data';
import componentBottomLine from '../../../../components/bottom-line/bottom-line';
import componentPouponCard from '@/components/coupon-card/coupon-card.vue';
import componentCouponCard from '@/components/coupon-card/coupon-card.vue';
export default {
data() {
@ -53,7 +53,7 @@
components: {
componentNoData,
componentBottomLine,
componentPouponCard,
componentCouponCard,
},
props: {},
@ -209,6 +209,7 @@
data_list: temp_list,
});
}
this.get_data_list();
} else {
if (app.globalData.is_login_check(res.data, this, 'coupon_receive_event')) {
app.globalData.showToast(res.data.msg);

View File

@ -1,6 +1,10 @@
/**
*
*/
.title {
width: 142rpx;
}
.nav_seckill .item {
width: 176rpx;
padding: 26rpx 0;

View File

@ -1,37 +1,53 @@
<template>
<view>
<view v-if="(data_base || null) != null" :style="seckill_bg">
<!-- 秒杀时段 -->
<scroll-view :scroll-x="true" :scroll-with-animation="true" :scroll-into-view="'one-nav-item-'+nav_active_index" class="top-nav-scroll wh-auto bg-main">
<view class="nav_seckill flex-row flex-nowrap cr-white">
<view v-for="(item, index) in periods_list" :key="index" class="item tc cp text-size-xss" :class="nav_active_index === index ? 'active' : ''" :id="'one-nav-item-'+index"
:data-index="index" :data-text="item.time.time_first_text" :data-status="item.time.status" @tap="nav_event">
<view class="time text-size-lg">{{item.name}}</view>
<view class="state text-size-xs round" :class="nav_active_index === index ? 'cr-main' : ''">{{item.time.msg}}</view>
<view v-if="(data_base || null) != null">
<view class="bg-red" :style="'padding-top:' + (status_bar_height > 0 ? status_bar_height + 5 : 10) + 'px;' + seckill_bg">
<!-- 返回 -->
<!-- #ifdef MP-WEIXIN || MP-QQ || MP-KUAISHOU || H5 || APP -->
<view v-if="is_realstore_top_nav_back == 1" class="nav-back padding-horizontal-main padding-top-sm round va-m cr-white flex-row">
<iconfont name="icon-tongyong-fanhui" size="40rpx" @tap="top_nav_left_back_event"></iconfont>
<view class="flex-1 tc">
<image :src="seckill_title_url" mode="widthFix" class="title pr top-sm"></image>
</view>
</view>
</scroll-view>
<!-- 秒杀时段 -->
<scroll-view :scroll-x="true" :scroll-with-animation="true" :scroll-into-view="'one-nav-item-' + nav_active_index" class="top-nav-scroll wh-auto">
<view class="nav_seckill flex-row flex-nowrap cr-white">
<view
v-for="(item, index) in periods_list"
:key="index"
class="item tc cp text-size-xss"
:class="nav_active_index === index ? 'active' : ''"
:id="'one-nav-item-' + index"
:data-index="index"
:data-text="item.time.time_first_text"
:data-status="item.time.status"
@tap="nav_event"
>
<view class="time text-size-lg">{{ item.name }}</view>
<view class="state text-size-xs round" :class="nav_active_index === index ? 'cr-main' : ''">{{ item.time.msg }}</view>
</view>
</view>
</scroll-view>
</view>
<view class="padding-horizontal-main padding-top-main">
<!-- 基础信息倒计时 -->
<view class="oh spacing-mb flex-row jc-sb align-c">
<view>
<text :class="'va-m text-size-xs fw-b cr-blak '+(is_valid == 1 ? 'cr-base' : 'cr-red')">{{time_first_text}}</text>
<text :class="'va-m text-size-xs fw-b cr-blak ' + (is_valid == 1 ? 'cr-base' : 'cr-red')">{{ time_first_text }}</text>
<view v-if="is_valid == 1" class="dis-inline-block va-m margin-left-sm">
<component-countdown :propHour="time.hours" :propMinute="time.minutes" :propSecond="time.seconds"
:prop-time-background-color="seckill_status === 1 ? '#E22C08': '#333333'"></component-countdown>
<component-countdown :propHour="time.hours" :propMinute="time.minutes" :propSecond="time.seconds" :prop-time-background-color="seckill_status === 1 ? '#E22C08' : '#333333'"></component-countdown>
</view>
</view>
<view class="text-size-xs cr-blak" @tap="quick_open_event">
活动规则
<iconfont v-if="(data_base.content_notice || null) != null && data_base.content_notice.length > 0" name="icon-miaosha-hdgz" size="26rpx" class="margin-left-xs pr top-xs"
color="#999"></iconfont>
<iconfont v-if="(data_base.content_notice || null) != null && data_base.content_notice.length > 0" name="icon-miaosha-hdgz" size="26rpx" class="margin-left-xs pr top-xs" color="#999"></iconfont>
</view>
</view>
<!-- 商品 -->
<view v-if="goods.length > 0">
<component-goods-list :propData="{style_type: 1, goods_list: goods}" :propCurrencySymbol="currency_symbol" :prop-grid-btn-config="gridBtnConfig"
:prop-is-open-grid-btn-set="isOpenGridBtnSet" propPriceField="seckill_min_price"></component-goods-list>
<component-goods-list :propData="{ style_type: 1, goods_list: goods }" :propCurrencySymbol="currency_symbol" :prop-grid-btn-config="gridBtnConfig" :prop-is-open-grid-btn-set="isOpenGridBtnSet" propPriceField="seckill_min_price"></component-goods-list>
</view>
<view v-else>
<!-- 提示信息 -->
@ -42,12 +58,11 @@
<!-- 结尾 -->
<component-bottom-line :propStatus="data_bottom_line_status"></component-bottom-line>
<!-- 弹窗 -->
<component-popup v-if="(data_base.content_notice || null) != null && data_base.content_notice.length > 0" :propShow="popup_status" :propIsBar="propIsBar" propPosition="bottom"
@onclose="quick_close_event">
<component-popup v-if="(data_base.content_notice || null) != null && data_base.content_notice.length > 0" :propShow="popup_status" :propIsBar="propIsBar" propPosition="bottom" @onclose="quick_close_event">
<view class="rule">
<view class="title cr-black text-size-md fw-b margin-bottom-main tc">活动规则</view>
<scroll-view :scroll-y="true" class="item">
<view v-for="(item, index) in data_base.content_notice" :key="index" class="cr-grey text-size-md">{{item}}</view>
<view v-for="(item, index) in data_base.content_notice" :key="index" class="cr-grey text-size-md">{{ item }}</view>
</scroll-view>
<button type="default" class="bg-main cr-white round text-size-md pa bottom-0 left-0 right-0" @tap="quick_close_event"></button>
</view>
@ -61,16 +76,20 @@
</template>
<script>
const app = getApp();
import componentCountdown from "../../../../components/countdown/countdown";
import componentNoData from "../../../../components/no-data/no-data";
import componentBottomLine from "../../../../components/bottom-line/bottom-line";
import componentGoodsList from "../../../../components/goods-list/goods-list";
import componentPopup from "../../../../components/popup/popup";
import componentCountdown from '../../../../components/countdown/countdown';
import componentNoData from '../../../../components/no-data/no-data';
import componentBottomLine from '../../../../components/bottom-line/bottom-line';
import componentGoodsList from '../../../../components/goods-list/goods-list';
import componentPopup from '../../../../components/popup/popup';
var seckill_static_url = app.globalData.get_static_url('seckill', true);
export default {
data() {
return {
status_bar_height: parseInt(app.globalData.get_system_info('statusBarHeight', 0)),
//
is_realstore_top_nav_back: app.globalData.data.is_realstore_top_nav_back || 0,
seckill_bg: 'background: url(' + seckill_static_url + 'header-bg.png) top/100% no-repeat;',
seckill_title_url: seckill_static_url + 'seckill-title.png',
data_bottom_line_status: false,
data_list_loding_status: 1,
data_list_loding_msg: '',
@ -99,7 +118,7 @@
gridBtnConfig: {
name: '即将开抢',
disabled: true,
}
},
};
},
components: {
@ -107,7 +126,7 @@
componentNoData,
componentBottomLine,
componentGoodsList,
componentPopup
componentPopup,
},
props: {},
onLoad() {},
@ -125,20 +144,20 @@
seckill_status(val) {
if (val === 0) {
let newData = {
name: '即将开抢'
}
name: '即将开抢',
};
this.setData({
gridBtnConfig: Object.assign({}, gridBtnConfig, newData),
});
} else if (val === 2) {
let newData = {
name: '已结束'
}
name: '已结束',
};
this.setData({
gridBtnConfig: Object.assign({}, gridBtnConfig, newData),
});
}
}
},
},
methods: {
//
@ -154,22 +173,22 @@
//
get_data() {
uni.request({
url: app.globalData.get_request_url("index", "index", "seckill"),
url: app.globalData.get_request_url('index', 'index', 'seckill'),
method: 'POST',
data: {},
dataType: 'json',
success: res => {
success: (res) => {
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
var data_base = data.config || null;
var current = data.current || null;
var time = (current == null) ? null : current.time || null;
var goods = (current == null) ? [] : (current.goods || []);
var is_valid = (time == null) ? 0 : (time.status == 1 ? 1 : 0);
var time = current == null ? null : current.time || null;
var goods = current == null ? [] : current.goods || [];
var is_valid = time == null ? 0 : time.status == 1 ? 1 : 0;
if (goods.length > 0) {
for (var i in goods) {
goods[i]['price_icon'] = (is_valid == 1) ? (current.goods_detail_icon || '秒杀价') : '';
goods[i]['price_icon'] = is_valid == 1 ? current.goods_detail_icon || '秒杀价' : '';
}
}
this.setData({
@ -184,22 +203,22 @@
is_valid: is_valid,
data_list_loding_msg: '',
data_list_loding_status: 0,
data_bottom_line_status: (goods.length > 0)
data_bottom_line_status: goods.length > 0,
});
if ((this.data_base || null) != null) {
//
//
this.setData({
share_info: {
title: this.data_base.seo_title || this.data_base.application_name,
desc: this.data_base.seo_desc,
path: '/pages/plugins/seckill/index/index',
img: ((this.slider || null) != null && this.slider.length > 0) ? this.slider[0]['images_url'] : ''
}
img: (this.slider || null) != null && this.slider.length > 0 ? this.slider[0]['images_url'] : '',
},
});
//
if ((this.data_base.application_name || null) != null) {
uni.setNavigationBarTitle({
title: this.data_base.application_name
title: this.data_base.application_name,
});
}
}
@ -207,7 +226,7 @@
this.setData({
data_bottom_line_status: false,
data_list_loding_status: 2,
data_list_loding_msg: res.data.msg
data_list_loding_msg: res.data.msg,
});
}
//
@ -218,10 +237,10 @@
this.setData({
data_bottom_line_status: false,
data_list_loding_status: 2,
data_list_loding_msg: '服务器请求出错'
data_list_loding_msg: '服务器请求出错',
});
app.globalData.showToast('服务器请求出错');
}
},
});
},
nav_event(e) {
@ -239,18 +258,29 @@
//
quick_open_event(e) {
this.setData({
popup_status: true
popup_status: true,
});
},
//
quick_close_event(e) {
this.setData({
popup_status: false
popup_status: false,
});
},
}
//
top_nav_left_back_event(e) {
var pages = getCurrentPages();
if (pages.length <= 1) {
uni.switchTab({
url: app.globalData.data.tabbar_pages[0],
});
} else {
uni.navigateBack();
}
},
},
};
</script>
<style scoped>
@import './index.css';
</style>
</style>

View File

@ -40,7 +40,7 @@
}
.signin-btn .content {
width: 216rpx;
min-width: 216rpx;
padding: 12rpx 48rpx;
display: inline-flex;
justify-content: center;
@ -170,4 +170,19 @@
bottom: -150rpx;
left: 50%;
transform: translateX(-50%);
}
/**
*
*/
@media only screen and (min-width:960px) {
.signin-btn .content {
font-size: 64rpx;
border-radius: 128rpx;
padding: 24rpx 168rpx;
}
.signin-btn {
margin: -240rpx;
}
}

View File

@ -1,6 +1,6 @@
<template>
<view class="signin-container">
<view v-if="(data || null) != null">
<view v-if="(data || null) != null" class="pr">
<image :src="signin_static_url + 'signin-bg.png'" mode="widthFix" class="signin-bg"></image>
<view class="signin-opration-group pa right-0 flex-col cr-white">
<view v-if="(data_base.is_share || 0) == 1" class="share oh flex-row">

View File

@ -2,54 +2,52 @@
*
*/
.base .item .item-icon {
width: 35rpx;
height: 35rpx !important;
width: 35rpx;
height: 35rpx !important;
}
.base .item .status {
color: #999;
color: #999;
}
.base .item .status-0 {
color: #0e90d2;
color: #0e90d2;
}
.base .item .status-1 {
color: #5eb95e;
color: #5eb95e;
}
.base .item .status-2 {
color: #F37B1D;
color: #F37B1D;
}
/**
*
*/
.nav {
position: fixed;
left: 0;
bottom: 20rpx;
padding-bottom: 20rpx;
}
.nav button image {
width: 32rpx;
height: 32rpx !important;
width: 32rpx;
height: 32rpx !important;
}
.nav button.share-friend-submit,
.nav button.share-poster-submit {
width: calc(30% - 20rpx);
width: calc(30% - 20rpx);
}
.nav button.share-friend-submit {
background: #1bad18;
background: #1bad18;
}
.nav button.share-poster-submit {
background: #6367f0;
background: #6367f0;
}
.nav button.player-submit {
width: calc(40% - 40rpx);
background: #d2364c;
width: calc(40% - 40rpx);
background: #d2364c;
}

View File

@ -28,7 +28,7 @@
</view>
<!-- 导航 -->
<view class="nav wh-auto oh bottom-line-exclude flex-row jc-sb">
<view class="bottom-fixed nav wh-auto oh bottom-line-exclude flex-row jc-sb">
<button class="share-friend-submit fl cr-white text-size-sm round" type="default" hover-class="none" open-type="share">
<image class="item-icon va-m margin-right-sm" :src="static_url + 'nav-share-friend-icon.png'" mode="widthFix"></image>
<text class="va-m">分享</text>
@ -53,169 +53,169 @@
</view>
</template>
<script>
const app = getApp();
import componentNoData from "../../../../components/no-data/no-data";
import componentBottomLine from "../../../../components/bottom-line/bottom-line";
const app = getApp();
import componentNoData from '../../../../components/no-data/no-data';
import componentBottomLine from '../../../../components/bottom-line/bottom-line';
var static_url = app.globalData.get_static_url("weixinliveplayer", true);
export default {
data() {
return {
static_url: static_url + "app/",
params: null,
data_list_loding_status: 1,
data_list_loding_msg: "",
data_bottom_line_status: false,
detail: null,
//
share_info: {},
};
},
components: {
componentNoData,
componentBottomLine,
},
props: {},
onLoad(params) {
this.setData({
params: app.globalData.launch_params_handle(params),
});
this.init();
},
onShow() {},
//
onPullDownRefresh() {
this.init();
},
methods: {
init() {
uni.showLoading({
title: "加载中...",
});
this.setData({
var static_url = app.globalData.get_static_url('weixinliveplayer', true);
export default {
data() {
return {
static_url: static_url + 'app/',
params: null,
data_list_loding_status: 1,
data_list_loding_msg: '',
data_bottom_line_status: false,
detail: null,
//
share_info: {},
};
},
components: {
componentNoData,
componentBottomLine,
},
props: {},
onLoad(params) {
this.setData({
params: app.globalData.launch_params_handle(params),
});
uni.request({
url: app.globalData.get_request_url("detail", "search", "weixinliveplayer"),
method: "POST",
data: {
id: this.params.id,
},
dataType: "json",
success: (res) => {
uni.hideLoading();
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
this.setData({
detail: data.data || null,
data_list_loding_status: 3,
data_bottom_line_status: true,
data_list_loding_msg: "",
});
this.init();
},
if ((this.detail || null) != null) {
//
onShow() {},
//
onPullDownRefresh() {
this.init();
},
methods: {
init() {
uni.showLoading({
title: '加载中...',
});
this.setData({
data_list_loding_status: 1,
});
uni.request({
url: app.globalData.get_request_url('detail', 'search', 'weixinliveplayer'),
method: 'POST',
data: {
id: this.params.id,
},
dataType: 'json',
success: (res) => {
uni.hideLoading();
uni.stopPullDownRefresh();
if (res.data.code == 0) {
var data = res.data.data;
this.setData({
share_info: {
title: this.detail.seo_title || this.detail.name,
desc: this.detail.seo_desc,
path: "/pages/plugins/weixinliveplayer/detail/detail",
query: "id=" + this.detail.id,
img: this.detail.share_img,
},
detail: data.data || null,
data_list_loding_status: 3,
data_bottom_line_status: true,
data_list_loding_msg: '',
});
//
uni.setNavigationBarTitle({
title: this.detail.name,
if ((this.detail || null) != null) {
//
this.setData({
share_info: {
title: this.detail.seo_title || this.detail.name,
desc: this.detail.seo_desc,
path: '/pages/plugins/weixinliveplayer/detail/detail',
query: 'id=' + this.detail.id,
img: this.detail.share_img,
},
});
//
uni.setNavigationBarTitle({
title: this.detail.name,
});
}
} else {
this.setData({
data_list_loding_status: 2,
data_bottom_line_status: false,
data_list_loding_msg: res.data.msg,
});
app.globalData.showToast(res.data.msg);
}
} else {
//
app.globalData.page_share_handle(this.share_info);
},
fail: () => {
uni.hideLoading();
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2,
data_bottom_line_status: false,
data_list_loding_msg: res.data.msg,
data_list_loding_msg: '服务器请求出错',
});
app.globalData.showToast(res.data.msg);
}
//
app.globalData.page_share_handle(this.share_info);
},
fail: () => {
uni.hideLoading();
uni.stopPullDownRefresh();
this.setData({
data_list_loding_status: 2,
data_bottom_line_status: false,
data_list_loding_msg: "服务器请求出错",
});
app.globalData.showToast("服务器请求出错");
},
});
},
//
detail_images_view_event(e) {
var value = e.currentTarget.dataset.value || null;
if (value != null) {
uni.previewImage({
current: value,
urls: [value],
app.globalData.showToast('服务器请求出错');
},
});
}
},
},
//
player_event(e) {
var params = encodeURIComponent(
JSON.stringify({
type: "detail",
})
);
uni.navigateTo({
url: `plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=${this.detail.roomid}&custom_params=${params}`,
});
},
//
detail_images_view_event(e) {
var value = e.currentTarget.dataset.value || null;
if (value != null) {
uni.previewImage({
current: value,
urls: [value],
});
}
},
//
share_poster_event() {
uni.showLoading({
title: "生成中...",
});
uni.request({
url: app.globalData.get_request_url("poster", "index", "weixinliveplayer"),
method: "POST",
data: {
id: this.detail.id,
},
dataType: "json",
success: (res) => {
uni.hideLoading();
if (res.data.code == 0) {
uni.previewImage({
current: res.data.data,
urls: [res.data.data],
});
} else {
app.globalData.showToast(res.data.msg);
}
},
fail: () => {
uni.hideLoading();
app.globalData.showToast("服务器请求出错");
},
});
//
player_event(e) {
var params = encodeURIComponent(
JSON.stringify({
type: 'detail',
})
);
uni.navigateTo({
url: `plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=${this.detail.roomid}&custom_params=${params}`,
});
},
//
share_poster_event() {
uni.showLoading({
title: '生成中...',
});
uni.request({
url: app.globalData.get_request_url('poster', 'index', 'weixinliveplayer'),
method: 'POST',
data: {
id: this.detail.id,
},
dataType: 'json',
success: (res) => {
uni.hideLoading();
if (res.data.code == 0) {
uni.previewImage({
current: res.data.data,
urls: [res.data.data],
});
} else {
app.globalData.showToast(res.data.msg);
}
},
fail: () => {
uni.hideLoading();
app.globalData.showToast('服务器请求出错');
},
});
},
},
},
};
};
</script>
<style>
@import "./detail.css";
@import './detail.css';
</style>