var r=(e,a,l)=>new Promise((d,s)=>{var p=t=>{try{i(l.next(t))}catch(o){s(o)}},u=t=>{try{i(l.throw(t))}catch(o){s(o)}},i=t=>t.done?d(t.value):Promise.resolve(t.value).then(p,u);i((l=l.apply(e,a)).next())});import{a as f}from"./index-DZZDXGB3.js";import{a as b}from"./index-BkDH5H1g.js";import{B as m}from"./index-Ctrb-9wA.js";import{at as T}from"./bootstrap-D7yvUSkm.js";import{D as c}from"./dict-enum-CaHgMaDZ.js";import{cT as n}from"../jse/index-index-BAlyf32H.js";function v(e){return[{component:"Input",fieldName:"bizId",dependencies:{triggerFields:[""],show:()=>!1}},{component:"Input",fieldName:"bizType",dependencies:{triggerFields:[""],show:()=>!1}},{fieldName:"type",label:"跟进类型",component:"Select",componentProps:{options:T(c.CRM_FOLLOW_UP_TYPE,"number")},rules:"required"},{fieldName:"nextTime",label:"下次联系时间",component:"DatePicker",componentProps:{showTime:!0,format:"YYYY-MM-DD HH:mm:ss",valueFormat:"x",placeholder:"请选择下次联系时间"},rules:"required"},{fieldName:"content",label:"跟进内容",component:"Textarea",rules:"required"},{fieldName:"picUrls",label:"图片",component:"ImageUpload"},{fieldName:"fileUrls",label:"附件",component:"FileUpload"},{fieldName:"contactIds",label:"关联联系人",component:"ApiSelect",componentProps:{api:()=>r(null,null,function*(){return e.value?(yield b({pageNo:1,pageSize:100,customerId:e.value})).list:[]}),labelField:"name",valueField:"id",mode:"multiple"}},{fieldName:"businessIds",label:"关联商机",component:"ApiSelect",componentProps:{api:()=>r(null,null,function*(){return e.value?(yield f({pageNo:1,pageSize:100,customerId:e.value})).list:[]}),labelField:"name",valueField:"id",mode:"multiple"}}]}function S(e){return[{field:"createTime",title:"创建时间",formatter:"formatDateTime"},{field:"creatorName",title:"跟进人"},{field:"type",title:"跟进类型",cellRender:{name:"CellDict",props:{type:c.CRM_FOLLOW_UP_TYPE}}},{field:"content",title:"跟进内容"},{field:"nextTime",title:"下次联系时间",formatter:"formatDateTime"},{field:"contacts",title:"关联联系人",visible:e===m.CRM_CUSTOMER,slots:{default:"contacts"}},{field:"businesses",title:"关联商机",visible:e===m.CRM_CUSTOMER,slots:{default:"businesses"}},{field:"actions",title:"操作",slots:{default:"actions"}}]}function _(){return[{field:"ownerUserName",label:"负责人"},{field:"contactLastContent",label:"最后跟进记录"},{field:"contactLastTime",label:"最后跟进时间",render:e=>n(e)},{field:"creatorName",label:"创建人"},{field:"createTime",label:"创建时间",render:e=>n(e)},{field:"updateTime",label:"更新时间",render:e=>n(e)}]}export{_ as a,v as b,S as u};