import{u as $,a as z,B as A,b as E}from"./index.ae7ce77b.js";import"./elementPlus.346c766a.js";import{d as G,q as _,r as f,al as b,am as O,j as J,w as K,a9 as r,o as h,E as v,G as a,M as t,a2 as W,a0 as F,u as o,J as k,a as g,L as s,K as w,B as H,aq as Q,ar as X}from"./vue.6daa721c.js";import{createCrudOptions as Y}from"./crud.fb2d7991.js";import Z from"./dataTendency.14ea91e8.js";import ee from"./adStruct.0684900f.js";import{a as ae,b as te,c as oe,d as se}from"./api.0f886666.js";import{SbBaseColumn as re}from"./commonTabColumn.9307c435.js";import{D as ne}from"./index.1b30f184.js";import{_ as le}from"./_plugin-vue_export-helper.c27b6911.js";import"./echarts.72dc8373.js";import"./api.cee22ac8.js";import"./enum.b537673d.js";import"./index.c2be63e9.js";import"./index.abe7750b.js";import"./dropdowndisable.88660b16.js";const ce=n=>(Q("data-v-2e7629f6"),n=n(),X(),n),ie={class:"en-text"},pe={class:"campare-switch"},me=ce(()=>g("span",null,"数据对比 ",-1)),de=G({__name:"index",setup(n){const I=_("topSearchItem"),S=_("searchType"),M=_("searchItem"),l=f("dataTendency"),V=$(),x=z(),{dateRange:y}=b(x),{profile:D}=b(V),m=f({profileId:D.value.profile_id,dateRange:y,searchItem:I,searchType:S,filterItem:M}),{crudBinding:L,crudRef:N,crudExpose:C}=A({createCrudOptions:Y,context:m}),B=O(),d=f(!1),T=c=>{B.push({name:"CampaignDetail",query:{id:c.id,campaignId:c.campaignId,tagsViewName:c.campaignName}})};return J(async()=>{C.doRefresh()}),K(m,async()=>{C.doRefresh()},{deep:!0}),(c,i)=>{const u=r("el-tab-pane"),R=r("el-tabs"),q=r("el-link"),U=r("el-tooltip"),j=r("el-switch"),P=r("fs-crud");return h(),v(o(E),{class:"fs-page-custom"},{default:a(()=>[t(P,H({ref_key:"crudRef",ref:N},o(L)),W({"header-middle":a(()=>[t(R,{modelValue:l.value,"onUpdate:modelValue":i[0]||(i[0]=e=>l.value=e),class:"chart-tabs",type:"border-card"},{default:a(()=>[t(u,{label:"数据趋势",name:"dataTendency"},{default:a(()=>[l.value==="dataTendency"?(h(),v(Z,{key:0,query:m.value,fetchCard:o(ae),"fetch-line-month":o(te),"fetch-line-week":o(oe),fetchLine:o(se)},null,8,["query","fetchCard","fetch-line-month","fetch-line-week","fetchLine"])):k("",!0)]),_:1}),t(u,{label:"广告结构",name:"adStruct"},{default:a(()=>[l.value==="adStruct"?(h(),v(ee,{key:0})):k("",!0)]),_:1}),t(u,{label:"散点视图",name:"scatterView",lazy:!0})]),_:1},8,["modelValue"])]),cell_campaignName:a(e=>[t(U,{effect:"dark",content:e.row.campaignName,placement:"top"},{default:a(()=>[t(q,{type:"primary",underline:!1,onClick:p=>T(e.row)},{default:a(()=>[g("div",ie,s(e.row.campaignName),1)]),_:2},1032,["onClick"])]),_:2},1032,["content"])]),cell_MissedImpressions:a(e=>[w(s(e.row.MissedImpressionsLower??"0")+" ~ "+s(e.row.MissedImpressionsUpper??"0"),1)]),cell_MissedClicks:a(e=>[w(s(e.row.MissedClicksLower??"0")+" ~ "+s(e.row.MissedClicksUpper??"0"),1)]),cell_MissedSales:a(e=>[w(s(e.row.MissedSalesLower??"0")+" ~ "+s(e.row.MissedSalesUpper??"0"),1)]),"toolbar-left":a(()=>[g("div",pe,[me,t(j,{modelValue:d.value,"onUpdate:modelValue":i[1]||(i[1]=e=>d.value=e),size:"small"},null,8,["modelValue"])])]),_:2},[F(Object.keys(o(re)),e=>({name:`cell_${e}`,fn:a(p=>[t(ne,{field:e,value:p.row[e],"prev-val":p.row[`prev${e}`],"gap-val":p.row[`gap${e}`],"date-range":o(y),"show-compare":d.value},null,8,["field","value","prev-val","gap-val","date-range","show-compare"])])}))]),1040)]),_:1})}}});const De=le(de,[["__scopeId","data-v-2e7629f6"]]);export{De as default};
