Commit 7cdf6c4c by 前端

Merge branch 'v3.6.0' into 'master'

合并线上版本

See merge request !24
2 parents abc1af9a 5a76be65
$imgUrl: 'https://img02.glsx.com.cn/weapp/resource/miniprogram/h5-posters/'; $imgUrl: 'https://img02.glsx.com.cn/weapp/resource/miniprogram/h5-posters/';
$v: '1.0.2'; $v: '1.0.2';
$good-color: #ffd2b2; $good-color: #ffd2b2;
.product-box {
.wrapper-good { top: 395px;
min-height: 100vh; display: inline-block;
box-sizing: border-box; background: url("#{$imgUrl}goodNews/line-bg.png?v=#{$v}");
padding-bottom: 100px; background-repeat: repeat-x;
background-image: linear-gradient(180deg, #f46538 0%, #f92b36 100%); background-size: 4px 57px;
width: auto;
// margin: 0 43px;
font-size: 23px;
color: $good-color;
line-height: 30px;
} }
.banner { .product-name {
position: relative; position: relative;
img { padding: 14px 0;
width: 100%; box-sizing: border-box;
height: 688px; div {
} // width: 100%;
.header-box { box-sizing: border-box;
position: absolute; max-width: 425px;
top: 275px; white-space: nowrap;
left: 50%; padding: 0 15px;
width: 100%; white-space: nowrap;
transform: translateX(-50%); overflow: hidden;
text-align: center; text-overflow: ellipsis;
.acitvity-box {
display: inline-block;
font-size: 26px;
padding: 6px 30px;
color: #FEEACE;
border-radius: 44px 44px 44px 44px;
background: linear-gradient(-180deg, rgba(253,243,219,100), rgba(252,234,180,100));
.activity-name {
font-size: 26px;
color: #FEEACE;
background-image: -webkit-linear-gradient(bottom,#dd0719,#ee4831,#f76a3e);
-webkit-background-clip:text;
-webkit-text-fill-color:transparent;
}
}
.merchant-name {
text-align: center;
font-size: 22px;
color: #F7432B;
margin-top: 14px;
}
} }
} }
// 员工信息 .product-icon {
.user-box { position: absolute;
position: relative; width: 30px;
height: 57px;
}
.icon-left {
left: -29px;
top: 0;
}
.icon-right {
right: -29px;
top: 0;
}
.store-name {
top: 466px;
color: $good-color;
font-size: 22px;
font-weight: 500;
width: 100%; width: 100%;
height: 719px; text-align: center;
margin-top: -120px; }
background: url("@/assets/images/goodNews/user-bg.png") no-repeat; .employee-avatar {
background-size: 100%; top: 700px;
z-index: 1; width: 124px;
.user-avatar { height: 124px;
position: absolute; border-radius: 50%;
width: 160px; }
height: 160px; .ribbon {
border-radius: 50%; top: 775px;
top: 216px; img {
left: 50%; width: 610px;
transform: translateX(-50%); height: 70px;
} }
.user-info { &-content {
position: absolute; position: relative;
top: 420px; }
&-text {
display: flex; display: flex;
align-items: baseline; bottom: 7px;
justify-content: center; color: $good-color;
width: 100%; font-size: 22px;
color: rgba(254, 234, 206, 1); height: 30px;
font-weight: 500; line-height: 30px;
font-size: 26px; span {
height: 40px; display: inline-block;
background-image:-webkit-linear-gradient(bottom,#e73507,#f6721b,#f57300); vertical-align: middle;
-webkit-background-clip:text; text-align: center;
-webkit-text-fill-color:transparent; }
.user-name { span:first-child {
color: rgba(254, 234, 206, 1); display: inline-block;
font-weight: 600; // transform: rotate(6deg);
font-size: 32px; }
margin: 0 16px; span:last-child {
display: inline-block;
// transform: rotate(-6deg);
} }
} }
.user-order { &-other-text {
position: absolute;
bottom: 100px;
left: 50%;
transform: translateX(-50%);
display: flex; display: flex;
align-items: baseline;
justify-content: center; justify-content: center;
font-size: 36px; span {
background-image:-webkit-linear-gradient(bottom,#e73507,#f6721b,#f57300); display: inline-block;
-webkit-background-clip:text; max-width: 180px;
-webkit-text-fill-color:transparent; font-weight: 800;
.order-value { white-space: nowrap;
font-style: italic; overflow: hidden;
font-size: 120px; text-overflow: ellipsis;
padding: 0 20px;
} }
} }
} &-name {
.ranking-box { flex: 1;
box-sizing: border-box; vertical-align: -webkit-baseline-middle;
width: calc(100% - 100px); // line-height: 46px;
margin: 40px 50px 0; padding: 0 12px;
padding: 16px; font-weight: 800;
border-radius: 10px 10px 10px 10px; white-space: nowrap;
background: linear-gradient(-180deg, rgba(255,169,105,100), rgba(255,137,85,100)); overflow: hidden;
.ranking-list { text-overflow: ellipsis;
width: calc(100% - 34px);
padding: 20px 17px;
border-radius: 10px 10px 10px 10px;
background: linear-gradient(-180deg, rgba(255,249,235,100), rgba(255,240,196,100));
.shop-title {
display: flex;
justify-content: center;
align-items: center;
font-size: 26px;
background-image:-webkit-linear-gradient(bottom,#e73507,#f6721b,#f57300);
-webkit-background-clip:text;
-webkit-text-fill-color:transparent;
.icon-title {
width: 17px;
height: 10px;
}
.shop-name{
margin: 0 15px;
text-overflow :ellipsis;
overflow : hidden;
white-space :nowrap;
}
}
} }
} }
.ranking { .ranking {
top: 1123px;
color: $good-color; color: $good-color;
width: 100%; width: 405px;
background-color: #860a0f;
}
.sales {
display: flex;
align-items: baseline;
top: 850px;
color: $good-color;
font-size: 30px;
font-weight: 600;
// text-shadow: 0px 2px 5px rgba(50, 0, 0, 0.3);
div {
background-image: linear-gradient(-18deg, #ffb376 0%, #ffe6af 100%);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
.number {
display: inline-block;
font-size: 100px;
flex: 1;
padding: 0 16px;
font-weight: 800;
font-style: italic;
}
} }
.table { .table {
&-box { &-box {
display: inline-block; display: inline-block;
padding-top: 20px; padding-top: 4px;
font-size: 20px; font-size: 20px;
min-height: 300px; min-height: 300px;
} }
&-header { &-header {
display: flex; display: flex;
align-items: center; align-items: center;
height: 43px; height: 45px;
color: #A95E4A; opacity: 0.7;
font-weight: 500;
border-radius: 21.5px 21.5px 21.5px 21.5px;
background: rgba(255,237,209,1);
} }
&-th, &-th,
&-td { &-td {
...@@ -169,12 +161,14 @@ $good-color: #ffd2b2; ...@@ -169,12 +161,14 @@ $good-color: #ffd2b2;
display: flex; display: flex;
align-items: center; align-items: center;
height: 40px; height: 40px;
color: #A95E4A; margin-bottom: 16px;
// margin-bottom: 16px; background-color: #830e13;
height: 60px;
border: 1px solid rgba(253,231,207,1);
border-radius: 20px; border-radius: 20px;
} }
// &-item:nth-child(odd) {
// background-color: #830e13;
// border-radius: 20px;
// }
&-avatar { &-avatar {
width: 30px; width: 30px;
height: 30px; height: 30px;
...@@ -209,7 +203,7 @@ $good-color: #ffd2b2; ...@@ -209,7 +203,7 @@ $good-color: #ffd2b2;
.ranking-bg { .ranking-bg {
width: 26px; width: 26px;
height: 26px; height: 26px;
background-color: #DF9866; background-color: #bf1c20;
border-radius: 50%; border-radius: 50%;
} }
.ranking-number { .ranking-number {
...@@ -217,7 +211,6 @@ $good-color: #ffd2b2; ...@@ -217,7 +211,6 @@ $good-color: #ffd2b2;
top: 50%; top: 50%;
left: 50%; left: 50%;
transform: translate(-50%, -50%); transform: translate(-50%, -50%);
color: #fff;
} }
.bg-top-box { .bg-top-box {
height: 1060px; height: 1060px;
...@@ -226,9 +219,118 @@ $good-color: #ffd2b2; ...@@ -226,9 +219,118 @@ $good-color: #ffd2b2;
height: 100%; height: 100%;
} }
} }
.icon-bottom { .wrapper-bg {
position: relative;
background-color: #860a0f;
padding-bottom: 90px;
.shop-title {
display: flex;
justify-content: center;
align-items: center;
font-size: 26px;
color: #ffd2b2;
margin-top: 10px;
margin-bottom: 15px;
.icon-title {
width: 17px;
height: 10px;
}
.shop-name{
margin: 0 15px;
max-width: 350px;
text-overflow :ellipsis;
overflow : hidden;
white-space :nowrap;
}
}
}
.wrapper-table {
// padding-top: 40px;
background: url("#{$imgUrl}goodNews/bg-line.png?v=#{$v}");
background-repeat: repeat-y;
background-size: 100% 10px;
text-align: center;
// margin-bottom: 90px;
margin-top: -1px;
.wrapper-header {
top: 1131px;
width: 100%;
img {
width: 100%;
}
}
.wrapper-footer {
width: 100%;
height: 110px;
img {
width: 100%;
height: 100%;
}
}
}
.table-bg {
background: url("@/assets/images/goodNews/ranking-line.png");
background-repeat: repeat-y;
background-size: 100% 10px;
}
.bg-footer {
width: 100%;
// position: relative;
// bottom: 0;
// left: 0;
// right: 0;
// height: 500px;
// z-index: -1;
.left-footer,
.right-footer {
width: 106px;
height: 500px;
position: absolute;
bottom: 0;
}
.left-footer {
left: 0;
}
.right-footer {
right: 0;
}
}
.long-ribbon {
position: absolute;
top: 222px;
width: 100%;
img {
width: 100%;
}
}
.left-ribbon {
position: absolute;
left: -4px;
top: 1070px;
width: 100%;
img {
width: 100%;
}
}
.right-ribbon {
position: absolute;
right: 0;
top: 1270px;
width: 100%;
img {
width: 100%;
}
}
.bottom-ribbon {
position: absolute; position: absolute;
bottom: 0; bottom: 0;
height: 150px;
width: 100%; width: 100%;
height: 115px; img {
width: 100%;
height: 100%;
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
* @Author: huyue * @Author: huyue
* @Date: 2022-10-10 10:54:14 * @Date: 2022-10-10 10:54:14
* @LastEditors: huyue * @LastEditors: huyue
* @LastEditTime: 2023-03-09 16:22:33 * @LastEditTime: 2023-03-14 11:00:46
*/ */
const fetchConfig = function (isEnv = true) { const fetchConfig = function (isEnv = true) {
// return window.fetch('https://oss-config.dev.glsx.com.cn/mock/618cb9331072f92988f05a23/wx/h5-config', {}).then(res => res.json()) // return window.fetch('https://oss-config.dev.glsx.com.cn/mock/618cb9331072f92988f05a23/wx/h5-config', {}).then(res => res.json())
......
...@@ -3,108 +3,160 @@ ...@@ -3,108 +3,160 @@
* @Author: huyue * @Author: huyue
* @Date: 2022-10-10 15:26:23 * @Date: 2022-10-10 15:26:23
* @LastEditors: huyue * @LastEditors: huyue
* @LastEditTime: 2023-02-15 14:43:24 * @LastEditTime: 2023-03-20 14:37:30
--> -->
<template> <template>
<div class="wrapper-good"> <div class="bg-top-box">
<div class="banner"> <img class="bg-top" :src="getImageUrl('bg-top')" alt="" />
<img :src="getImageUrl('banner')" alt="" /> <div class="product-box x-center">
<div class="header-box"> <div class="product-name">
<div class="acitvity-box"> <img
<div class="activity-name">{{ data.storeInfo!.activityName }}</div> class="icon-left product-icon"
</div> :src="getImageUrl('icon-left')"
<div class="merchant-name">{{ data.storeInfo!.merchantName }}</div> alt=""
/>
<div>{{ data.storeInfo!.activityName }}</div>
<img
class="icon-right product-icon"
:src="getImageUrl('icon-right')"
alt=""
/>
</div> </div>
</div> </div>
<div class="user-box"> <div class="store-name x-center">{{ data.storeInfo!.merchantName }}</div>
<img <img
class="user-avatar" class="employee-avatar x-center"
:src="data.storeInfo!.avatar || getImageUrl('icon-avatar')" :src="data.storeInfo!.avatar || getImageUrl('icon-avatar')"
alt="" alt=""
/> />
<div class="user-info"> <div class="ribbon x-center">
<span v-if="data.storeInfo!.type == 2">{{ <div class="ribbon-content">
data.storeInfo!.department <img :src="getImageUrl('ribbon')" alt="" />
}}</span> <div class="ribbon-text x-center">
<div class="user-name">{{ data.storeInfo!.name }}</div> <template v-if="data.storeInfo!.type == 2">
为团队助力 {{ data.storeInfo!.department }}
</div> <span class="ribbon-name">{{ data.storeInfo!.name }}</span>
<div class="user-order"> 为团队助力
第 </template>
<div class="order-value">{{ data.storeInfo!.orderCount }}</div> <template v-if="data.storeInfo!.type == 1">
单 <div class="ribbon-other-text">
<span>{{ data.storeInfo!.name }}</span
>为团队助力
</div>
</template>
</div>
</div> </div>
</div> </div>
<div <div class="sales x-center">
class="ranking-box" <div>第</div>
v-for="(i, ind) in data.storeInfo!.orderRankList" <div class="number">{{ data.storeInfo!.orderCount }}</div>
:key="ind" <div>单</div>
> </div>
<div class="ranking-list"> </div>
<div class="shop-title"> <div class="wrapper-bg">
<img class="icon-title" :src="getImageUrl('icon-title')" alt="" /> <template v-for="(i, ind) in data.storeInfo!.orderRankList">
<div class="shop-name">{{ i.goodsName }}</div> <div class="wrapper-table" v-if="i.rank.length != 0">
<img class="icon-title" :src="getImageUrl('icon-title')" alt="" /> <div class="table-bg">
</div> <div class="wrapper-header">
<div class="table-box ranking"> <img src="@/assets/images/goodNews/ranking-header.png" alt="" />
<div class="table-header">
<div class="table-th">排名</div>
<div class="table-th">头像</div>
<div class="table-th">部门</div>
<div class="table-th">姓名</div>
<div class="table-th">单量</div>
</div> </div>
<div class="table-body"> <div class="shop-title">
<div class="table-item" v-for="(j, index) in i.rank" :key="index"> <img class="icon-title" :src="getImageUrl('title-icon')" alt="" />
<template v-if="index < 3"> <div class="shop-name">{{ i.goodsName }}</div>
<div class="table-td first-ranking"> <img class="icon-title" :src="getImageUrl('title-icon')" alt="" />
<img :src="getImageUrl(data.medals![index])" alt="" /> </div>
<span class="ranking-number" style="top: 44%">{{ <div class="wrapper-content">
index + 1 <div class="table-box ranking">
}}</span> <div class="table-header">
</div> <div class="table-th">排名</div>
</template> <div class="table-th">头像</div>
<template v-else> <div class="table-th">部门</div>
<div class="table-td"> <div class="table-th">姓名</div>
<span class="ranking-bg"></span> <div class="table-th">单量</div>
<span class="ranking-number">{{ index + 1 }}</span> </div>
<div class="table-body">
<div
class="table-item"
v-for="(item, index) in i.rank"
:key="index"
>
<template v-if="index < 3">
<div class="table-td first-ranking">
<img :src="getImageUrl(data.medals![index])" alt="" />
<span class="ranking-number" style="top: 44%">{{
index + 1
}}</span>
</div>
</template>
<template v-else>
<div class="table-td">
<span class="ranking-bg"></span>
<span class="ranking-number">{{ index + 1 }}</span>
</div>
</template>
<div class="table-td">
<img
class="table-avatar"
:src="item.avator || getImageUrl('icon-avatar')"
alt=""
/>
</div>
<div class="table-td">{{ item.department }}</div>
<div class="table-td">{{ item.name }}</div>
<div class="table-td sales-number">{{ item.orderCount }}</div>
</div> </div>
</template>
<div class="table-td">
<img
class="table-avatar"
:src="j.avator || getImageUrl('icon-avatar')"
alt=""
/>
</div> </div>
<div class="table-td">{{ j.department }}</div>
<div class="table-td">{{ j.name }}</div>
<div class="table-td sales-number">{{ j.orderCount }}</div>
</div> </div>
</div> </div>
<div class="wrapper-footer">
<img src="@/assets/images/goodNews/ranking-footer.png" alt="" />
</div>
</div>
<div class="bg-footer">
<img
class="left-footer"
src="@/assets/images/goodNews/left-footer.jpg"
alt=""
/>
<img
class="right-footer"
src="@/assets/images/goodNews/right-footer.png"
alt=""
/>
</div> </div>
</div> </div>
</div> </template>
<img class="icon-bottom" :src="getImageUrl('icon-bottom')" alt="" />
</div> </div>
</template>
<div class="long-ribbon">
<img src="@/assets/images/goodNews/long-ribbon.png" alt="" />
</div>
<!-- <div class="left-ribbon">
<img :src="getImageUrl('left-ribbon')" alt="" />
</div>
<div class="right-ribbon">
<img :src="getImageUrl('right-ribbon')" alt="" />
</div> -->
<div class="bottom-ribbon">
<img src="@/assets/images/goodNews/bottom-ribbon.png" alt="" />
</div>
<div class="logo x-center">
<img :src="getImageUrl('logo', 'common')" alt="" />
</div>
</template>
<script lang="ts" setup> <script lang="ts" setup>
import { reactive, onMounted, inject } from "vue"; import { reactive, onMounted, inject } from "vue";
import { req } from "../../utils/request"; import { req } from "../../utils/request";
import { useRoute } from "vue-router"; import { useRoute } from "vue-router";
import { DataInfo, Params } from "./interface"; import { DataInfo, Params } from "./interface";
const route = useRoute(); const route = useRoute();
// 获取全局对象 // 获取全局对象
const global: any = inject("global"); const global: any = inject("global");
let query: Params = {}; let query: Params = {};
const data = reactive<Partial<DataInfo>>({ const data = reactive<Partial<DataInfo>>({
medals: ["first", "second", "third"], medals: ["first", "second", "third"],
storeInfo: {}, storeInfo: {},
}); });
const getInfo = async () => { const getInfo = async () => {
data.storeInfo = await req( data.storeInfo = await req(
"scrm.api.shopmall.activity.good.report.param", "scrm.api.shopmall.activity.good.report.param",
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!