import{A as x,B as N,C as D}from"./elementPlus.CXoFsoPv.js";import{_ as u}from"./index.vue_vue_type_script_setup_true_lang.DKtMKa0b.js";import{h as s}from"./hasPermission.Dyr7g3RK.js";import{d as V,ai as l,o as i,c as a,u as e,a as b,U as t,O as o,R as r,T as E,S as c}from"./vue.1RczIYhx.js";const T={class:"font-medium"},U={key:0},z={class:"flex justify-center gap-2"},A={key:0},j={key:1},F={key:2,class:"italic"},O={key:1},G=V({__name:"DataTableSlot",props:{row:{},field:{}},emits:["edit-row","handle-delete"],setup(k,{emit:y}){const C=k,{row:d,field:_}=C,p=y;function h(){p("edit-row",d)}function g(){p("handle-delete",d)}return(P,n)=>{const f=l("el-icon"),m=l("el-button"),v=l("el-popconfirm"),w=l("el-tag");return i(),a("div",T,[e(_)==="operate"?(i(),a("div",U,[b("div",z,[e(s)("SkuBrandUpdate")?(i(),a("div",A,[t(u,{circle:"",plain:"",type:"warning",onClick:h},{default:o(()=>[t(f,null,{default:o(()=>[t(e(N))]),_:1})]),_:1})])):r("",!0),e(s)("SkuBrandDelete")?(i(),a("div",j,[t(v,{icon:e(x),"icon-color":"#626AEF",title:"你确定要删除此项吗?",width:"220",onConfirm:g},{reference:o(()=>[t(u,{circle:"",plain:"",type:"danger"},{default:o(()=>[t(f,null,{default:o(()=>[t(e(D))]),_:1})]),_:1})]),actions:o(({confirm:B,cancel:S})=>[t(m,{size:"small",onClick:S},{default:o(()=>n[0]||(n[0]=[c("No!")])),_:2},1032,["onClick"]),t(m,{size:"small",type:"danger",onClick:B},{default:o(()=>n[1]||(n[1]=[c(" Yes? ")])),_:2},1032,["onClick"])]),_:1},8,["icon"])])):r("",!0),!e(s)("SkuBrandUpdate")&&!e(s)("SkuBrandDelete")?(i(),a("div",F,[t(w,{type:"warning"},{default:o(()=>n[2]||(n[2]=[c(" 暂无权限 ")])),_:1})])):r("",!0)])])):(i(),a("div",O,E(e(d)[e(_)]||"-"),1))])}}});export{G as _};
