index-DyJKl7vP.js 3.1 KB

1
  1. import{_ as f}from"./BasicTable.vue_vue_type_script_setup_true_lang-LfIfgHfU.js";import"./TableImg.vue_vue_type_style_index_0_lang-Bw1yjZfI.js";import{_}from"./index-COaHNk09.js";import{u as b}from"./useTable-Ckkpwxcg.js";import{j as g}from"./index-BXL90VpN.js";import{u as h}from"./index-CFdteMiu.js";import{_ as C}from"./WebsiteDrawer.vue_vue_type_script_setup_true_lang-9R2OTrgw.js";import{M as T,U as k}from"./antd-FjOLgRLC.js";import{d as w,f as D,k as t,a9 as r,Z as B,_ as S,a8 as s,G as $}from"./vue-ByATgq5d.js";import{_ as y}from"./entry/index-C7JiT1GB.js";import"./BasicForm.vue_vue_type_script_setup_true_lang-CNQgK2hZ.js";import"./FormItem.vue_vue_type_script_lang-DShPDeWl.js";import"./componentMap-Bl3zv6Ms.js";import"./useFormItem-DmfL7Ss_.js";import"./RadioButtonGroup.vue_vue_type_script_setup_true_lang-DXgKlWOB.js";import"./index-DdNcNAMt.js";import"./IconPicker.vue_vue_type_script_setup_true_lang-DORWVBs9.js";import"./copyTextToClipboard-D9zCzvi-.js";import"./index-3Ue_ZFSu.js";import"./index-DU88M1nq.js";import"./index-Cj7S-5xp.js";import"./useWindowSizeFn-JqODWlR_.js";import"./base64Conver-bBv-IO2K.js";import"./helper-Ba5FUquL.js";import"./BasicForm.vue_vue_type_style_index_0_lang-9WP9An_0.js";import"./useForm-BijxHkUB.js";import"./uuid-D0SLUWHI.js";import"./sortable.esm-CoO8jRpa.js";import"./onMountedOrActivated-BDlj7Upy.js";import"./useSortable-y7X8pv8d.js";import"./download-DGeKzh-1.js";const E=[{title:"分类名称",dataIndex:"name",width:150},{title:"备注",dataIndex:"remark"}],x={title:"产品分类列表",titleHelpMessage:"比如:后台管理模块,前台管理模块,命名空间必须与代码模块保持一致!",api:()=>g("product_category",{}),columns:E,bordered:!0,showTableSetting:!0,loading:!0,pagination:{defaultPageSize:20,pageSize:1e3},actionColumn:{width:160,title:"操作",dataIndex:"action",slots:{customRender:"action"}}},R=w({components:{BasicTable:f,TableAction:_,WebsiteDrawer:C},setup(){const[e,{openDrawer:n}]=h(),l=D(!1),[c,{reload:m}]=b(x);function p(o){n(!0,{record:o,isUpdate:!0})}function i(){m()}function a(){n(!0,{isUpdate:!1})}return{loading:l,registerTable:c,registerDrawer:e,handleCreate:a,handleEdit:p,handleSuccess:i,handleDelete:o=>{T.confirm({title:"你确定要删除该站点吗?",icon:t(k),content:t("div",{style:"color:red;"},"注:该站点关联数据将无法恢复!"),okText:"删除",okType:"danger",onOk(){}})}}}}),A={class:"p-4"};function v(e,n,l,c,m,p){const i=r("a-button"),a=r("TableAction"),u=r("BasicTable"),o=r("WebsiteDrawer");return B(),S("div",A,[t(u,{onRegister:e.registerTable},{toolbar:s(()=>[t(i,{type:"primary",onClick:e.handleCreate},{default:s(()=>[$(" 新增产品分类 ")]),_:1},8,["onClick"])]),action:s(({record:d})=>[t(a,{actions:[{label:"编辑",icon:"clarity:note-edit-line",color:"success",onClick:e.handleEdit.bind(null,d)},{label:"删除",icon:"ic:outline-delete-outline",color:"error",onClick:e.handleDelete.bind(null,d)}]},null,8,["actions"])]),_:1},8,["onRegister"]),t(o,{onRegister:e.registerDrawer,onSuccess:e.handleSuccess},null,8,["onRegister","onSuccess"])])}const me=y(R,[["render",v]]);export{me as default};