PageSourceSearch

https://www.filmpro.ru/_nuxt/B8pA72Qz.js

js filmpro.ru collected 2026-10-02 03:54:21 UTC 2,627 bytes, 1 lines download raw bytes

1import{g as M,o as N,a as P,_ as A}from"./BwiywTlr.js";import{_ as B}from"./B7rgdppr.js";import{_ as D,a as E}from"./CNNlfnmq.js";import{_ as j}from"./Dqq5sVkF.js";import{_ as w}from"./CU-aVGdC.js";import{_ as I}from"./fPhffBcC.js";import{u as L}from"./9XmEXdK0.js";import{u as q}from"./C5P-lpf1.js";import{z as F,a2 as G,G as H,a7 as e,V as a,y as l,Y as u,c as O,b as R,k as Y,P as J,a4 as d,a1 as f}from"./pEjZETfw.js";import"./Cbp2waRB.js";import"./B4U-JsHY.js";import"./9EOMS3tm.js";import"./NWEso5Ur.js";import"./gfLliCm3.js";import"./CkM_fYjw.js";import"./Y3YGt8om.js";import"./ByBMDjtQ.js";import"./CMPjFafy.js";import"./DvJakqkG.js";const K={type:"button"},Q={class:"flex w-full justify-end p-4"},i=10,bt=F({__name:"materials",async setup(W){let s,c;const{unblockUser:h,blockUser:b}=L(),k=M(),m=N(),n=R(1),{data:x,refresh:r}=([s,c]=G(()=>q("/api/materials/reports",{method:"POST",query:{page:n,pageSize:i}},"$H0AesfkjzE")),s=await s,c(),s),y=[{key:"title",label:"Заголовок"},{key:"author",label:"Автор"},{key:"complainsCnt",label:"Жалобы",sortable:!0},{key:"actions",label:"Действия"}],g=Y(()=>x.value?.map(t=>t)||[]),U=t=>[[{label:t.author?.blocked?"Разблокировать пользователя":"Заблокировать пользователя",icon:t.author?.blocked?"i-ci-user-add":"i-ci-user-close",click:()=>{t.author?.blocked?h(t.author?.id||-1,r):b(t.author?.id||-1,r)}}],[{label:"Удалить материал",icon:"i-ci-trash-full",click:()=>T(t.id)}]];function T(t){k.open(I,{onAccept:()=>{$fetch(`/api/materials/${t}`,{method:"PUT",body:{statusId:4}}).then(async()=>{await r(),m.add({title:"Материал удален"})}).catch(()=>{m.add({title:"Не удалось удалить материал",color:"red",icon:"i-ci-error-outline"})})}})}return(t,_)=>{const p=A,V=P,z=B,S=E,$=D,v=j,C=w;return J(),H("div",null,[e(v,{columns:y,rows:l(g)},{"title-data":a(({row:o})=>[e(p,{external:"",to:{name:"materials-id",params:{id:o.id}}},{default:a(()=>[d(f(o.title),1)]),_:2},1032,["to"])]),"author-data":a(({row:o})=>[e(p,{external:"",to:{name:"users-id",params:{id:o.author.id}}},{default:a(()=>[d(f(o.author.fullname),1)]),_:2},1032,["to"])]),"actions-data":a(({row:o})=>[e(z,{items:U(o)},{default:a(()=>[u("button",K,[e(V,{size:"1.5rem",name:"i-ci-more-horizontal"})])]),_:1},8,["items"])]),"empty-state":a(()=>[e(S)]),"loading-state":a(()=>[e($)]),_:1},8,["rows"]),u("div",Q,[e(C,{modelValue:l(n),"onUpdate:modelValue":_[0]||(_[0]=o=>O(n)?n.value=o:null),size:"md","page-count":i,total:i*l(n)+i},null,8,["modelValue","total"])])])}}});export{bt as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.