Commit 72c1c0eb authored by Mac's avatar Mac

1

parent e022d204
......@@ -13,6 +13,7 @@
interface msg {
Enable: number
}
......@@ -29,7 +30,15 @@
responseType: 'json',
data
})
}
}
// 获取客户标签
static async getLabelList(data: any): Promise<HttpResponse> {
return Axios('/QYWeChat/GetWeChatLableList', {
method: 'post',
responseType: 'json',
data
})
}
// 获取客户线索规则列表
static async getCustomerClueRuleList(data:any): Promise<HttpResponse> {
return Axios('QYCustomer/GetCustomerClueRuleList', {
......
......@@ -26,7 +26,7 @@
</div>
</template>
<script>
import { defineComponent, ref, onMounted} from 'vue'
import { defineComponent, ref, onMounted } from 'vue'
import customerService from '@/api/customer'
export default defineComponent({
......@@ -36,20 +36,48 @@
default: []
},
},
setup(props,ctx) {
setup(props, ctx) {
let selectList = ref(props.list)
let LableList = ref([])
const goclose = () => {
ctx.emit('close')
}
const determine = () => {
ctx.emit('submit',selectList.value)
ctx.emit('submit', selectList.value)
}
const getLabelList = () => {
customerService.getLabelList({}).then((res) => {
console.log(res)
if (res.data.Code == 1) {
LableList.value = res.data.Data
LableList.value.forEach(x => {
if (x.ChildList.length > 0) {
x.ChildList.forEach(j => {
j.chek = false;
// for (let index = 0; index < this.list.length; index++) {
// const element = this.list[index];
// if (element.Id == j.Id) {
// j.chek = true;
// break
// }
// }
})
}
})
}
})
}
onMounted(() => {//进入页面就调用
getLabelList()
})
return {
alert: ref(true),
goclose,
determine,
selectList
selectList,
getLabelList
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment