You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

2 line
3.9 KiB

  1. import{j as k,k as h,s as j,c as o,a as t,F as b,u as C,b as i,w as c,x as l,y as L,d as B,e as N,o as a,t as v,i as d,R as r}from"./index-5dca7a6a.js";import{c as P,g}from"./api-2fe5baa7.js";const R={class:"page-wrapper",id:"app","data-layout":"horizontal","data-navbarbg":"skin6","data-sidebartype":"full","data-sidebar-position":"fixed","data-header-position":"fixed"},V=B('<header class="app-header"><nav class="navbar navbar-expand-lg navbar-light container-fluid px-0"><ul class="navbar-nav"><li class="nav-item d-block d-lg-none"><a class="nav-link sidebartoggler ms-n3" id="sidebarCollapse" href="javascript:void(0)"><i class="ti ti-menu-2"></i></a></li><li class="nav-item d-none d-lg-block"><a href="index.html" class="text-nowrap nav-link"><img src="'+N+'" class="light-logo" width="180" alt=""></a></li></ul></nav></header>',1),$={class:"body-wrapper overflow-hidden"},D={class:"position-relative overflow-hidden min-vh-100 d-flex align-items-center justify-content-center drawise-auth-bg"},z={class:"d-flex align-items-center justify-content-center w-100"},E={key:0,class:"row justify-content-center w-100"},F={class:"col-md-8 col-lg-8 col-xxl-8"},S=t("h1",{class:"display-6 fs-7 mb-4 text-center"}," Dashboard, let's Build it ",-1),T={class:"containermt-4"},I={class:"row"},K={class:"card"},M={class:"card-body"},U={class:"container"},q={class:"row"},A={class:"col-12 col-md-6 col-lg-3 d-flex align-items-center justify-content-center"},G=["src"],H={class:"col-12 col-md-6 col-lg-9 mt-4"},J={class:"d-flex align-items-center justify-content-between w-100 prof-flex"},O={class:"fs-5 d-none-prof-500"},Q=t("i",{class:"ti ti-cloud-download fs-4 me-2"},null,-1),W=t("hr",null,null,-1),X={class:"d-flex align-items-center justify-content-between w-100 prof-flex"},Y=["onClick"],Z=t("i",{class:"ti ti-external-link fs-4 me-2"},null,-1),tt=t("i",{class:"ti ti-edit fs-4 me-2"},null,-1),et=t("button",{class:"btn mb-3 d-block w-100 btn-outline-primary waves-effect waves-light",type:"button"}," Create new site ",-1),st={key:1,class:"progress-container"},nt=t("div",{class:"track"},[t("div",{class:"bar"})],-1),ot=t("div",null,"Loading ...",-1),at=[nt,ot],dt=k({__name:"dashboard",setup(it){const _=h([]),m=h([]),p=h(!0);j(()=>{P(),w()});async function w(){try{const n=(await g("/create_site/sites/")).data;console.log(n);const e=n.map(f=>y(f.company)),u=await Promise.all(e);_.value=n,m.value=u,p.value=!1}catch(s){console.error(s)}}async function y(s){try{const e="https://api.drawise.net"+(await g(`/create_site/company/${s}`)).data.logo_path;return console.log(e),e}catch(n){return console.error(n),"null"}}const x=s=>{window.open("https://drawise.net/web/"+s,"_blank")};return(s,n)=>(a(),o("div",R,[V,t("div",$,[t("div",D,[t("div",z,[p.value?(a(),o("div",st,at)):(a(),o("div",E,[t("div",F,[S,t("div",T,[t("div",I,[_.value?(a(),o(b,{key:0},[(a(!0),o(b,null,C(_.value,(e,u)=>(a(),o("div",{key:e.id,class:"col-sm-12 col-lg-12"},[t("div",K,[t("div",M,[t("div",U,[t("div",q,[t("div",A,[t("img",{src:m.value[u],alt:"",width:"100"},null,8,G)]),t("div",H,[t("div",J,[t("h1",O,v(e.site_name),1),i(l(r),{to:`dash/${e.id}/branding`,type:"button",class:"justify-content-center btn mb-1 btn-rounded btn-success d-flex align-items-center"},{default:c(()=>[Q,d(" Branding Kit ")]),_:2},1032,["to"])]),W,t("div",X,[t("button",{onClick:f=>x(e.domain_name),type:"button",class:"justify-content-center btn mb-1 btn-rounded btn-outline-success d-flex align-items-center najafi-btn"},[Z,d(" drawise.net/web/"+v(e.domain_name),1)],8,Y),i(l(r),{to:`dash/${e.id}/pages`,type:"button",class:"justify-content-center btn mb-1 btn-rounded btn-outline-success d-flex align-items-center najafi-btn"},{default:c(()=>[tt,d(" Edit ")]),_:2},1032,["to"])])])])])])])]))),128)),i(l(r),{to:"company"},{default:c(()=>[et]),_:1}),i(l(r),{to:"/terms",type:"button",class:"text-center d-block w-100 waves-effect"},{default:c(()=>[d(" Terms & privacy ")]),_:1})],64)):L("",!0)])])])]))])])])]))}});export{dt as default};