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