1 |
- import{d as M,r as _,aU as R,e as $,P as j,o as N,c as A,f as r,w as e,a,v as U,q as G,m as v,N as b,F as K,z as L,_ as Q,B as T,C as W,a$ as X,H as Y,__tla as Z}from"./index-2eab2d23.js";import{_ as aa,__tla as ta}from"./index.vue_vue_type_script_setup_true_lang-5730b053.js";import{_ as la,__tla as ra}from"./ContentWrap.vue_vue_type_script_setup_true_lang-5a63038a.js";import{_ as ea,__tla as _a}from"./main.vue_vue_type_script_setup_true_lang-9ca53d42.js";import{g as oa,c as sa,u as ca,d as na,__tla as ia}from"./main-16c68401.js";import{s as ua,__tla as ma}from"./index-5f871167.js";import{N as pa,c as fa,__tla as da}from"./NewsForm-bad22168.js";import ya,{__tla as ha}from"./DraftTable-19d95dae.js";import{u as va,__tla as ga}from"./useMessage-171aa63e.js";import{_ as wa}from"./_plugin-vue_export-helper-1b428a4d.js";import{__tla as Ia}from"./index-cc63c3c4.js";import{__tla as Sa}from"./el-card-c558f0ec.js";import{__tla as Na}from"./index-a72a8920.js";import{__tla as Ua}from"./main-74cfbf31.js";import{__tla as ba}from"./el-image-2171f3ff.js";import{__tla as Ca}from"./el-image-viewer-5d14bc77.js";import{__tla as Pa}from"./main-ec2be832.js";import{__tla as Va}from"./main.vue_vue_type_script_setup_true_lang-0610a4e1.js";import{__tla as ka}from"./index-4663832c.js";import{__tla as xa}from"./formatTime-41155543.js";import{__tla as za}from"./style.css_vue_type_style_index_0_src_true_lang-2706eaa9.js";import{__tla as qa}from"./CoverSelect-4a522a9e.js";import{__tla as Da}from"./useUpload-1c63b1eb.js";let C,Ea=Promise.all([(()=>{try{return Z}catch{}})(),(()=>{try{return ta}catch{}})(),(()=>{try{return ra}catch{}})(),(()=>{try{return _a}catch{}})(),(()=>{try{return ia}catch{}})(),(()=>{try{return ma}catch{}})(),(()=>{try{return da}catch{}})(),(()=>{try{return ha}catch{}})(),(()=>{try{return ga}catch{}})(),(()=>{try{return Ia}catch{}})(),(()=>{try{return Sa}catch{}})(),(()=>{try{return Na}catch{}})(),(()=>{try{return Ua}catch{}})(),(()=>{try{return ba}catch{}})(),(()=>{try{return Ca}catch{}})(),(()=>{try{return Pa}catch{}})(),(()=>{try{return Va}catch{}})(),(()=>{try{return ka}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return za}catch{}})(),(()=>{try{return qa}catch{}})(),(()=>{try{return Da}catch{}})()]).then(async()=>{C=wa(M({name:"MpDraft",__name:"index",setup(Fa){const c=va(),o=_(-1);R("accountId",o);const d=_(!0),g=_([]),w=_(0),n=$({pageNo:1,pageSize:10,accountId:o}),i=_(!1),u=_([]),I=_(""),m=_(!0),y=_(!1),P=l=>{o.value=l,n.pageNo=1,p()},V=async l=>{try{await c.confirm("\u4FEE\u6539\u5185\u5BB9\u53EF\u80FD\u8FD8\u672A\u4FDD\u5B58\uFF0C\u786E\u5B9A\u5173\u95ED\u5417?"),l()}catch{}},p=async()=>{d.value=!0;try{const l=await oa(n);l.list.forEach(t=>{t.content.newsItem.forEach(f=>{f.picUrl=f.thumbUrl})}),g.value=l.list,w.value=l.total}finally{d.value=!1}},k=()=>{m.value=!0,u.value=[fa()],i.value=!0},x=l=>{I.value=l.mediaId,u.value=JSON.parse(JSON.stringify(l.content.newsItem)),m.value=!1,i.value=!0},z=async()=>{y.value=!0;try{m.value?(await sa(o.value,u.value),c.notifySuccess("\u65B0\u589E\u6210\u529F")):(await ca(o.value,I.value,u.value),c.notifySuccess("\u66F4\u65B0\u6210\u529F"))}finally{i.value=!1,y.value=!1,await p()}},q=async l=>{const t=l.mediaId;try{await c.confirm("\u4F60\u6B63\u5728\u901A\u8FC7\u53D1\u5E03\u7684\u65B9\u5F0F\u53D1\u8868\u5185\u5BB9\u3002 \u53D1\u5E03\u4E0D\u5360\u7528\u7FA4\u53D1\u6B21\u6570\uFF0C\u4E00\u5929\u53EF\u591A\u6B21\u53D1\u5E03\u3002\u5DF2\u53D1\u5E03\u5185\u5BB9\u4E0D\u4F1A\u63A8\u9001\u7ED9\u7528\u6237\uFF0C\u4E5F\u4E0D\u4F1A\u5C55\u793A\u5728\u516C\u4F17\u53F7\u4E3B\u9875\u4E2D\u3002 \u53D1\u5E03\u540E\uFF0C\u4F60\u53EF\u4EE5\u524D\u5F80\u53D1\u8868\u8BB0\u5F55\u83B7\u53D6\u94FE\u63A5\uFF0C\u4E5F\u53EF\u4EE5\u5C06\u53D1\u5E03\u5185\u5BB9\u6DFB\u52A0\u5230\u81EA\u5B9A\u4E49\u83DC\u5355\u3001\u81EA\u52A8\u56DE\u590D\u3001\u8BDD\u9898\u548C\u9875\u9762\u6A21\u677F\u4E2D\u3002"),await ua(o.value,t),c.notifySuccess("\u53D1\u5E03\u6210\u529F"),await p()}catch{}},D=async l=>{const t=l.mediaId;try{await c.confirm("\u6B64\u64CD\u4F5C\u5C06\u6C38\u4E45\u5220\u9664\u8BE5\u8349\u7A3F, \u662F\u5426\u7EE7\u7EED?"),await na(o.value,t),c.notifySuccess("\u5220\u9664\u6210\u529F"),await p()}catch{}};return(l,t)=>{const f=L,E=Q,h=T,F=W,S=la,J=aa,O=X,B=j("hasPermi"),H=Y;return N(),A(K,null,[r(S,null,{default:e(()=>[r(F,{class:"-mb-15px",model:a(n),ref:"queryFormRef",inline:!0,"label-width":"68px"},{default:e(()=>[r(f,{label:"\u516C\u4F17\u53F7",prop:"accountId"},{default:e(()=>[r(a(ea),{onChange:P})]),_:1}),r(f,null,{default:e(()=>[U((N(),G(h,{type:"primary",plain:"",onClick:k,disabled:a(o)===0},{default:e(()=>[r(E,{icon:"ep:plus"}),v("\u65B0\u589E ")]),_:1},8,["disabled"])),[[B,["mp:draft:create"]]])]),_:1})]),_:1},8,["model"])]),_:1}),r(S,null,{default:e(()=>[r(a(ya),{loading:a(d),list:a(g),onUpdate:x,onDelete:D,onPublish:q},null,8,["loading","list"]),r(J,{total:a(w),page:a(n).pageNo,"onUpdate:page":t[0]||(t[0]=s=>a(n).pageNo=s),limit:a(n).pageSize,"onUpdate:limit":t[1]||(t[1]=s=>a(n).pageSize=s),onPagination:p},null,8,["total","page","limit"])]),_:1}),r(O,{title:a(m)?"\u65B0\u5EFA\u56FE\u6587":"\u4FEE\u6539\u56FE\u6587",width:"80%",modelValue:a(i),"onUpdate:modelValue":t[4]||(t[4]=s=>b(i)?i.value=s:null),"before-close":V,"destroy-on-close":""},{footer:e(()=>[r(h,{onClick:t[3]||(t[3]=s=>i.value=!1)},{default:e(()=>[v("\u53D6 \u6D88")]),_:1}),r(h,{type:"primary",onClick:z},{default:e(()=>[v("\u63D0 \u4EA4")]),_:1})]),default:e(()=>[U(r(a(pa),{modelValue:a(u),"onUpdate:modelValue":t[2]||(t[2]=s=>b(u)?u.value=s:null),"is-creating":a(m)},null,8,["modelValue","is-creating"]),[[H,a(y)]])]),_:1},8,["title","modelValue"])],64)}}}),[["__scopeId","data-v-c1e8287e"]])});export{Ea as __tla,C as default};
|