import{r as s,W as o}from"./index.D93ign_E.js";import{aH as i}from"./vue.D1BjjNmv.js";const r="/api/system/job_applications/";function n(t){return s({url:"/api/system/question_tag/list",method:"get",params:{...t,tenant_id:1}})}function l(t){return s({url:"/api/system/question_tag/create",method:"post",data:{...t,tenant_id:1}})}function u(t){return s({url:"/api/system/question_tag/update",method:"post",data:{...t,tenant_id:1}})}function d(t){return s({url:"/api/system/question_tag/delete",method:"post",data:{...t,tenant_id:1}})}function _(){return s({url:r,method:"get"})}function c(t){return s({url:"/api/system/question_category/list",method:"get",params:{...t,tenant_id:1}})}const m=function({crudExpose:t}){return i(),{crudOptions:{toolbar:{buttons:{search:{show:!1},refresh:{show:!1},compact:{show:!1},export:{text:"导出",type:"primary",size:"small",icon:"upload",circle:!1,display:!0},columns:{show:!1}}},request:{pageRequest:async e=>await n(e),addRequest:async({form:e})=>await l(e),editRequest:async({form:e,row:a})=>(e.id=a.id,await u(e)),delRequest:async({row:e})=>await d({id:e.id})},actionbar:{buttons:{add:{show:!0}}},rowHandle:{fixed:"right",width:200,buttons:{view:{show:!1},edit:{iconRight:"Edit",type:"text",show:!0},remove:{iconRight:"Delete",type:"text",show:!0}}},pagination:{show:!0},table:{rowKey:"id"},search:{show:!0,buttons:{search:{size:"small"},reset:{size:"small"}}},columns:{id:{title:"ID",form:{show:!1},column:{show:!1}},name:{title:"标签名称",search:{show:!0,component:{placeholder:"请输入标签名称"},size:"small",col:{span:3}},type:"input",column:{minWidth:120},form:{rules:[{required:!0,message:"标签名称为必填项"}]}},category_id:{title:"分类",search:{show:!0,size:"small",col:{span:3}},type:"dict-select",column:{minWidth:120,show:!1},dict:o({getData:async()=>{const e=await c({page:1,limit:1e3,tenant_id:1});return console.log(e.data.items),e.data.items||[]},label:"name",value:"id"}),form:{rules:[{required:!0,message:"分类为必填项"}]}},category_name:{title:"分类名称",column:{minWidth:120},form:{show:!1}},sort:{title:"排序",type:"number",column:{minWidth:80},form:{value:1}},questions_count:{title:"问题数量",type:"number",column:{minWidth:100},form:{show:!1}},create_datetime:{title:"创建时间",type:"datetime",column:{minWidth:160},form:{show:!1}},update_datetime:{title:"更新时间",type:"datetime",column:{minWidth:160},form:{show:!1}},description:{title:"描述",search:{show:!1,component:{placeholder:"请输入描述"}},type:"textarea",column:{minWidth:150,showOverflowTooltip:!0},form:{component:{span:24,placeholder:"请输入标签描述"}}}}}}},q=Object.freeze(Object.defineProperty({__proto__:null,createCrudOptions:m},Symbol.toStringTag,{value:"Module"}));export{_ as G,q as a,m as c};
