import{d as e,e as a,a9 as t,r as s,aa as n,f as i,g as r,o,h as l,w as d,i as m,a as p,_ as u,aq as c,K as h,x as _,z as b}from"./index-Cg3FU-dV.js";import{_ as x}from"./uni-search-bar.CR6HHo5B.js";import{p as f}from"./paymentRecord.BdhuYcEV.js";import{c as w}from"./customerTab.DpH_ZKvN.js";import{p as g}from"./assessment.C7cFhOQt.js";import{K as j}from"./customer.DHyt6w_W.js";import{_ as I}from"./_plugin-vue_export-helper.BCo6x5W8.js";import"./uni-icons.D_sy4NxH.js";/* empty css                                                                  */import"./uni-row.DfI4R5V8.js";import"./uni-tag.YndEW7ps.js";import"./uni-dateformat.D7mTxFoD.js";import"./uni-list.B5vvSfhy.js";import"./uni-badge.AEsViQRE.js";import"./index.Dozy1JgX.js";/* empty css                                                              */const y=I(e({__name:"search",setup(e){const I=a({typeIndex:0,tabIndex:0,tabId:1,placeholder:"请输入关键字搜索",examineTabData:g,listData:[],emptyTitle:"暂无搜索结果～",where:{types:"",page:1,limit:10,status:0,time:"",name:"",date:"",no_withdraw:1}});t((e=>{const a=I.examineTabData.length-1;e.index&&(e.index>a?I.tabIndex=a:I.tabIndex=Number(e.index),I.tabId=I.examineTabData[I.tabIndex].id,I.where.status=1===I.tabId?0:"")}));const y=()=>{I.where.name="",I.listData=[]},D=()=>{u()},v=()=>{I.where.page=1,I.where.name?C(!0):y()},T=e=>{if(I.tabId===e.id||""===I.where.name)return!1;I.where.page>1&&c(),I.tabId=e.id,I.tabIndex=e.index,I.where.status=1===I.tabId?0:"",C(!0)},C=(e=!1)=>{I.where.page=1,K(e)},F=s(!1),K=(e=!1)=>{j(I.where).then((a=>{e&&(I.listData=[]),I.listData.push(...a.data.list);const t=Math.ceil(a.data.count/I.where.limit);F.value=!(I.listData.length<=0||I.where.page>=t),h()})).catch((e=>{_.error(e.message)}))};return n((()=>{F.value&&(I.where.page++,K())})),(e,a)=>{const t=b,s=i(r("uni-search-bar"),x);return o(),l(t,{class:"content"},{default:d((()=>[m(t,{class:"cr-position-header"},{default:d((()=>[m(t,{class:"status_bar"}),m(t,{class:"default-search"},{default:d((()=>[m(s,{onConfirm:v,onFocus:v,placeholder:p(I).placeholder,focus:!0,bgColor:"#F0F1F5",modelValue:p(I).where.name,"onUpdate:modelValue":a[0]||(a[0]=e=>p(I).where.name=e),onClear:y,onCancel:D},null,8,["placeholder","modelValue"])])),_:1}),m(w,{"examine-tab-data":p(I).examineTabData,onChange:T,index:p(I).tabIndex},null,8,["examine-tab-data","index"])])),_:1}),m(t,{class:"m10"},{default:d((()=>[m(f,{listData:p(I).listData,"type-index":1,"empty-title":p(I).emptyTitle},null,8,["listData","empty-title"])])),_:1})])),_:1})}}}),[["__scopeId","data-v-933ce614"]]);export{y as default};
