Commit 4595a973 by 李伟康

fix(styles): 精灵图添加新图标

1 parent f9e311b0

3.22 MB | W: | H:

3.23 MB | W: | H:

assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -7,8 +7,7 @@ ...@@ -7,8 +7,7 @@
<view class="header-item follower-col">跟进人</view> <view class="header-item follower-col">跟进人</view>
<view class="header-item action-col">操作</view> <view class="header-item action-col">操作</view>
</view> </view>
<scroll-view class="table-body" scroll-y>
<view class="table-body">
<view v-for="(item, index) in tableData" :key="index" class="table-row"> <view v-for="(item, index) in tableData" :key="index" class="table-row">
<view class="row-item customer-col"> <view class="row-item customer-col">
<view class="customer-info"> <view class="customer-info">
...@@ -40,20 +39,27 @@ ...@@ -40,20 +39,27 @@
<view class="row-item follower-col"> <view class="row-item follower-col">
<text>{{ item.follower }}</text> <text>{{ item.follower }}</text>
<view v-if="type == 1" class="date">{{ item.orderDate }}</view>
</view> </view>
<view class="row-item action-col"> <view class="row-item action-col">
<view class="action-btn primary-btn">推送运营任务</view> <view class="action-btn primary-btn" v-if="type == 0">推送运营任务</view>
<view class="action-btn secondary-btn">查看任务记录</view> <view class="action-btn secondary-btn">查看任务记录</view>
</view> </view>
</view> </view>
</view> </scroll-view>
</view> </view>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
export default { export default {
name: 'Table', name: 'Table',
props: {
type: {
type: Number,
default: 0
}
},
data() { data() {
return { return {
tableData: [ tableData: [
...@@ -121,6 +127,19 @@ export default { ...@@ -121,6 +127,19 @@ export default {
tags: ['11111111111111111111111111111111111111111111111', '环保意识强', '中高预算', '35-28岁', '高意向客户', 'sdjkfhsdkfh', 'jjddjdjdj'], tags: ['11111111111111111111111111111111111111111111111', '环保意识强', '中高预算', '35-28岁', '高意向客户', 'sdjkfhsdkfh', 'jjddjdjdj'],
hasMoreTags: false, hasMoreTags: false,
follower: '刘芳' follower: '刘芳'
},
{
avatar: '陈',
name: '陈**',
carModel: '比亚迪唐',
phone: '134****7890',
customerGroup: '陈女士4659-客户优惠活动服务群新能源...',
status: '战败',
statusClass: 'failed',
orderDate: '2022-09-18',
tags: ['新能源车购买', '家庭用车', '预算充足', '28-25岁', '低意向客户'],
hasMoreTags: false,
follower: '王伟'
} }
] ]
} }
...@@ -170,9 +189,8 @@ export default { ...@@ -170,9 +189,8 @@ export default {
<style scoped lang='scss'> <style scoped lang='scss'>
.table { .table {
width: 100%; width: 100%;
height: 100%;
background-color: #ffffff; background-color: #ffffff;
border-radius: 16rpx;
overflow: hidden;
.table-header { .table-header {
display: flex; display: flex;
...@@ -182,6 +200,7 @@ export default { ...@@ -182,6 +200,7 @@ export default {
color: #6C6F75; color: #6C6F75;
font-weight: 500; font-weight: 500;
height: 72rpx; height: 72rpx;
border-radius: 16rpx;
.header-item { .header-item {
text-align: center; text-align: center;
...@@ -210,6 +229,8 @@ export default { ...@@ -210,6 +229,8 @@ export default {
} }
.table-body { .table-body {
height: calc(100% - #{toRpx(72)});
.table-row { .table-row {
display: flex; display: flex;
align-items: center; align-items: center;
...@@ -354,6 +375,10 @@ export default { ...@@ -354,6 +375,10 @@ export default {
font-size: 26rpx; font-size: 26rpx;
color: #292D33; color: #292D33;
text-align: center; text-align: center;
.date{
color: #999EA8;
margin-top: 20rpx;
}
} }
&.action-col { &.action-col {
...@@ -365,17 +390,22 @@ export default { ...@@ -365,17 +390,22 @@ export default {
padding: 0 32rpx; padding: 0 32rpx;
.action-btn { .action-btn {
padding: 12rpx 24rpx; padding: 0 24rpx;
border-radius: 8rpx; border-radius: 8rpx;
font-size: 24rpx; font-size: 24rpx;
text-align: center; text-align: center;
cursor: pointer; cursor: pointer;
transition: all 0.2s; transition: all 0.2s;
height: 56rpx;
line-height: 56rpx;
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: center;
&.primary-btn { &.primary-btn {
background-color: #2C66F70D; background-color: #2C66F70D;
color: #2C66F7; color: #2C66F7;
border: 1rpx solid #2C66F71A; border: 2rpx solid #2C66F71A;
&:active { &:active {
background-color: #D4E4FF; background-color: #D4E4FF;
...@@ -385,7 +415,7 @@ export default { ...@@ -385,7 +415,7 @@ export default {
&.secondary-btn { &.secondary-btn {
background-color: #FFFFFF; background-color: #FFFFFF;
color: #292D33; color: #292D33;
border: 1rpx solid #DCE1E6; border: 2rpx solid #DCE1E6;
&:active { &:active {
background-color: #F5F7FA; background-color: #F5F7FA;
......
<template> <template>
<view class="customer-box"> <view class="customer-box">
<view class="tips flex">今日任务({{ toDay }}) <view class="tips flex">
<view class="today flex">
<view class="sprite-icon icon-customer-sop-1"></view>
今日任务({{ toDay }})
</view>
<view class="text">根据SOP策略生成营销任务,请及时推送客户</view> <view class="text">根据SOP策略生成营销任务,请及时推送客户</view>
</view> </view>
<view class="tabs-box">tabs</view> <view class="tabs-box flex">
<template v-for="(tab, index) in tabs">
<view :class="['tab flex', { active: index === tabIndex }]" :key="index" @click="changeTab(index)">
<view
:class="['sprite-icon', index === tabIndex ? `icon-customer-sop-${index + 2}-a` : `icon-customer-sop-${index + 2}`]">
</view>
{{ tab }}
</view>
</template>
</view>
<view class="customer-content"> <view class="customer-content">
<Table /> <Table :type="tabIndex" />
</view> </view>
</view> </view>
</template> </template>
...@@ -17,22 +30,39 @@ export default { ...@@ -17,22 +30,39 @@ export default {
components: { Table }, components: { Table },
data() { data() {
return { return {
tabIndex: 0,
tabs: ['待执行推送客户(12)', '近7日已推送客户(18)'],
toDay: dayjs().format('MM-DD') toDay: dayjs().format('MM-DD')
} }
}, },
watch: {}, watch: {},
computed: {}, computed: {},
mounted() { }, mounted() {
methods: {}
},
methods: {
/**
* 切换标签
* @param {number} index
*/
changeTab(index) {
if (index == this.tabIndex) return
this.tabIndex = index
}
}
} }
</script> </script>
<style scoped lang='scss'> <style scoped lang='scss'>
.customer-box { .customer-box {
width: 100%; width: 100%;
height: 100%; height: 100%;
padding: 32rpx 40rpx; padding: 32rpx 40rpx 0;
box-sizing: border-box; box-sizing: border-box;
.sprite-icon {
margin-right: 8rpx;
}
.tips { .tips {
height: 64rpx; height: 64rpx;
background: #2C66F70D; background: #2C66F70D;
...@@ -45,5 +75,31 @@ export default { ...@@ -45,5 +75,31 @@ export default {
margin-left: auto; margin-left: auto;
} }
} }
.tabs-box {
display: flex;
margin: 28rpx 0;
gap: 28rpx;
.tab {
height: 64rpx;
padding: 0 32rpx;
border-radius: 16rpx;
background: #F2F2F2;
font-size: 28rpx;
color: #292D33;
justify-content: center;
transition: all 0.2s ease-in-out;
}
.tab.active {
background: #2C66F71A;
color: #2C66F7;
}
}
.customer-content {
height: calc(100% - #{toRpx(184)});
}
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
const target = ['ip', 'dev', 'uat', 'prod', 'beta'] const target = ['ip', 'dev', 'uat', 'prod', 'beta']
const index = 3 const index = 2
/** /**
* *
0本地 0本地
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!