Commit e2d9033b by 匡雅琴

调用接口

1 parent 031f8236
...@@ -15,11 +15,11 @@ ...@@ -15,11 +15,11 @@
<GLButton type="primary" :size="size" icon="el-icon-plus" fn="新建客户群发" @click="btnClick('create', 1)">新建群发</GLButton> <GLButton type="primary" :size="size" icon="el-icon-plus" fn="新建客户群发" @click="btnClick('create', 1)">新建群发</GLButton>
<div class="text">企业统一选择要发送的客户,由添加客户的成员确认后发送给客户,消息内容仅管理员和负责人可创建。</div> <div class="text">企业统一选择要发送的客户,由添加客户的成员确认后发送给客户,消息内容仅管理员和负责人可创建。</div>
<div class="renew"> <div class="renew">
<div style="cursor:pointer;" @click="refreshData('1')"> <div style="cursor:pointer;" @click="refreshData('1')">
<i class="el-icon-refresh-right"></i> <i class="el-icon-refresh-right"></i>
<span style="margin-right: 8px;">更新数据</span> <span style="margin-right: 8px;">更新数据</span>
</div> </div>
<span style="color: #999;" v-if="time">更新于 {{time}}</span> <span style="color: #999;" v-if="time">更新于 {{ time }}</span>
</div> </div>
</div> </div>
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
...@@ -54,11 +54,11 @@ ...@@ -54,11 +54,11 @@
<GLButton type="primary" :size="size" fn="新建客户群群发" icon="el-icon-plus" @click="btnClick('create', 2)">新建群发</GLButton> <GLButton type="primary" :size="size" fn="新建客户群群发" icon="el-icon-plus" @click="btnClick('create', 2)">新建群发</GLButton>
<div class="text">管理员或负责人统一创建内容,群主收到通知后,可选择他管理的客户群并群发。</div> <div class="text">管理员或负责人统一创建内容,群主收到通知后,可选择他管理的客户群并群发。</div>
<div class="renews"> <div class="renews">
<div style="cursor:pointer;" @click="refreshData('2')"> <div style="cursor:pointer;" @click="refreshData('2')">
<i class="el-icon-refresh-right"></i> <i class="el-icon-refresh-right"></i>
<span style="margin-right: 8px;">更新数据</span> <span style="margin-right: 8px;">更新数据</span>
</div> </div>
<span style="color: #999;" v-if="times">更新于 {{times}}</span> <span style="color: #999;" v-if="times">更新于 {{ times }}</span>
</div> </div>
</div> </div>
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
...@@ -97,8 +97,8 @@ export default { ...@@ -97,8 +97,8 @@ export default {
} }
return { return {
timeId: Function, timeId: Function,
time:'', time: '',
times:'', times: '',
ATT_TYPE, ATT_TYPE,
activeIndex: 1, activeIndex: 1,
// 表格按钮 // 表格按钮
...@@ -336,9 +336,10 @@ export default { ...@@ -336,9 +336,10 @@ export default {
}, },
mounted() { mounted() {
// this.wxTips() // this.wxTips()
this.refreshData(this.activeIndex)
}, },
watch: { watch: {
activeIndex (newVal,oldVal) { activeIndex(newVal, oldVal) {
if (newVal == 2) { if (newVal == 2) {
this.times = dayjs(new Date().getTime()).format('YYYY-MM-DD HH:mm:ss') this.times = dayjs(new Date().getTime()).format('YYYY-MM-DD HH:mm:ss')
} else if (newVal == 1) { } else if (newVal == 1) {
...@@ -354,12 +355,12 @@ export default { ...@@ -354,12 +355,12 @@ export default {
clearTimeout(this.timeId) clearTimeout(this.timeId)
this.timeId = setTimeout(() => { this.timeId = setTimeout(() => {
this.$apis.customerTransform.renewDetailList({}).then(res => { this.$apis.customerTransform.renewDetailList({}).then(res => {
if(res.code == '0'){ if (res.code == '0') {
if(type == 1) { if (type == 1) {
this.time = res.data.createdTime this.time = res.data.createdTime
this.$refs.customer.refreshTable() this.$refs.customer.refreshTable()
} else if(type == 2) { } else if (type == 2) {
this.times = res.data.createdTime this.times = res.data.createdTime
this.$refs.customerGroup.refreshTable() this.$refs.customerGroup.refreshTable()
} }
} }
...@@ -495,12 +496,13 @@ export default { ...@@ -495,12 +496,13 @@ export default {
color: #999; color: #999;
margin-left: 20px; margin-left: 20px;
} }
.renew,.renews { .renew,
.renews {
display: flex; display: flex;
position: absolute; position: absolute;
right: 44px; right: 44px;
font-size: 14px; font-size: 14px;
color: #5850FF color: #5850ff;
} }
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!