Commit 72c1c0eb authored by Mac's avatar Mac

1

parent e022d204
...@@ -13,6 +13,7 @@ ...@@ -13,6 +13,7 @@
interface msg { interface msg {
Enable: number Enable: number
} }
...@@ -29,7 +30,15 @@ ...@@ -29,7 +30,15 @@
responseType: 'json', responseType: 'json',
data data
}) })
} }
// 获取客户标签
static async getLabelList(data: any): Promise<HttpResponse> {
return Axios('/QYWeChat/GetWeChatLableList', {
method: 'post',
responseType: 'json',
data
})
}
// 获取客户线索规则列表 // 获取客户线索规则列表
static async getCustomerClueRuleList(data:any): Promise<HttpResponse> { static async getCustomerClueRuleList(data:any): Promise<HttpResponse> {
return Axios('QYCustomer/GetCustomerClueRuleList', { return Axios('QYCustomer/GetCustomerClueRuleList', {
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
</div> </div>
</template> </template>
<script> <script>
import { defineComponent, ref, onMounted} from 'vue' import { defineComponent, ref, onMounted } from 'vue'
import customerService from '@/api/customer' import customerService from '@/api/customer'
export default defineComponent({ export default defineComponent({
...@@ -36,20 +36,48 @@ ...@@ -36,20 +36,48 @@
default: [] default: []
}, },
}, },
setup(props,ctx) { setup(props, ctx) {
let selectList = ref(props.list) let selectList = ref(props.list)
let LableList = ref([])
const goclose = () => { const goclose = () => {
ctx.emit('close') ctx.emit('close')
} }
const determine = () => { 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 { return {
alert: ref(true), alert: ref(true),
goclose, goclose,
determine, 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