import{a as V,B,b as C}from"./index.ad3efb29.js";import"./elementPlus.4833989a.js";import{createCrudOptions as R}from"./crud.1c8a2f6d.js";import{d as x,ay as y,r as c,j as b,w as D,ai as m,o as k,M as $,O as r,U as t,aa as G,a8 as I,u as o,D as O,a as d,K as P}from"./vue.adf17aba.js";import{BaseColumn as U}from"./commonTabColumn.c5d53eee.js";import{D as j}from"./index.04a874bc.js";import{_ as M}from"./index.vue_vue_type_script_setup_true_lang.3fa6db13.js";import"./echarts.72dc8373.js";import"./_plugin-vue_export-helper.c27b6911.js";const N={class:"campare-switch"},q=d("span",null,"数据对比 ",-1),Q=x({__name:"index",props:{adGroupId:{}},setup(i){const f=i,_=V(),{dateRange:a}=y(_),u=c({adGroupId:f.adGroupId,dateRange:a}),{crudBinding:v,crudRef:w,crudExpose:p}=B({createCrudOptions:R,context:u}),n=c(!1);return b(async()=>{p.doRefresh()}),D(u,async()=>{p.doRefresh()},{deep:!0}),(z,s)=>{const h=m("el-switch"),g=m("fs-crud");return k(),$(o(C),{class:"fs-page-custom"},{default:r(()=>[t(g,P({ref_key:"crudRef",ref:w},o(v)),G({"search-left":r(()=>[t(M,{modelValue:o(a),"onUpdate:modelValue":s[0]||(s[0]=e=>O(a)?a.value=e:null)},null,8,["modelValue"])]),"toolbar-left":r(()=>[d("div",N,[q,t(h,{modelValue:n.value,"onUpdate:modelValue":s[1]||(s[1]=e=>n.value=e),size:"small"},null,8,["modelValue"])])]),_:2},[I(Object.keys(o(U)),e=>({name:`cell_${e}`,fn:r(l=>[t(j,{field:e,value:l.row[e],"prev-val":l.row[`prev${e}`],"gap-val":l.row[`gap${e}`],"date-range":o(a),"show-compare":n.value},null,8,["field","value","prev-val","gap-val","date-range","show-compare"])])}))]),1040)]),_:1})}}});export{Q as default};
