Commit cd466856 by wangzhihui

```

feat(recruitment): 增加门店新增功能和表单验证优化

- 添加门店新增功能,支持创建新门店信息
- 增加门店地址省市区选择组件
- 添加主营品牌多选功能
- 增加近一月新车销量输入验证
- 完善表单验证规则,包括动态验证逻辑
- 优化新增招聘页面布局和样式
- 在api文件中添加文件头注释
- 修复基础信息组件的属性绑定问题
```
1 parent 86b520c3
/*
* @Author: 'wangzhihui' '1733904062@qq.com'
* @Date: 2026-03-30 17:36:59
* @LastEditors: 'wangzhihui' '1733904062@qq.com'
* @LastEditTime: 2026-03-31 14:27:00
* @FilePath: \dj-car-life-system\src\api\recruitment.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
// 招聘管理 // 招聘管理
import request from "./request"; import request from "./request";
......
...@@ -8,25 +8,32 @@ ...@@ -8,25 +8,32 @@
--> -->
<template> <template>
<div class="baseInfo"> <div class="baseInfo">
<detailComp :configData="configData" :detailInfo="detailInfo"></detailComp> <DetailComp :config-data="configData" :detail-info="detailInfo"></DetailComp>
</div> </div>
</template> </template>
<script> <script>
import detailComp from "./detailComp.vue" import detailComp from "./detailComp.vue";
export default { export default {
components: { components: {
detailComp DetailComp: detailComp,
},
props: {
detailInfo: {
type: Object,
default: () => { },
},
}, },
data() { data() {
const contentStyle = { const contentStyle = {
width: "100%", "width": "100%",
display: 'inline-block', "display": "inline-block",
overflow: 'hidden', "overflow": "hidden",
'text-overflow': 'ellipsis', "text-overflow": "ellipsis",
'white-space': 'nowrap' "white-space": "nowrap",
} };
return { return {
configData: [ configData: [
{ {
...@@ -34,72 +41,67 @@ export default { ...@@ -34,72 +41,67 @@ export default {
infoData: [ infoData: [
{ {
title: "门店名称", title: "门店名称",
key: "merchantName" key: "merchantName",
}, },
{ {
title: "近一月新车销售", title: "近一月新车销售",
key: "salesVolume" key: "salesVolume",
}, },
{ {
title: "主营品牌", title: "主营品牌",
key: "brand", key: "brand",
style: contentStyle, style: contentStyle,
hasTooltip: true hasTooltip: true,
}, },
{ {
title: "门店地址", title: "门店地址",
key: "merchantAddress", key: "merchantAddress",
style: contentStyle, style: contentStyle,
hasTooltip: true hasTooltip: true,
}, },
{ {
title: "业务类型", title: "业务类型",
key: "businessTypeName" key: "businessTypeName",
}, },
{ {
title: "招聘类型", title: "招聘类型",
key: "recruitmentTypeName" key: "recruitmentTypeName",
}, },
{ {
title: "招聘数量", title: "招聘数量",
key: "recruitmentQuantity" key: "recruitmentQuantity",
}, },
{ {
title: "区域运营", title: "区域运营",
key: "regionOperationName" key: "regionOperationName",
}, },
{ {
title: "创建人", title: "创建人",
key: "createdBy" key: "createdBy",
}, },
{ {
title: "申请时间", title: "申请时间",
key: "createdDate" key: "createdDate",
}, },
{ {
title: "需求描述", title: "需求描述",
key: "requirementDescription", key: "requirementDescription",
col: 24 col: 24,
} },
] ],
} },
] ],
} };
}, },
methods: { methods: {
getStatusItem(baseData, optKey, row, rowKey) { getStatusItem(baseData, optKey, row, rowKey) {
if (!baseData || !baseData[optKey] || !row) return null if (!baseData || !baseData[optKey] || !row)
return null;
return baseData[optKey].find( return baseData[optKey].find(
(item) => item.confId == row[rowKey] // 使用严格相等 item => item.confId == row[rowKey], // 使用严格相等
) );
}
}, },
props: { },
detailInfo: { };
type: Object,
default: () => { }
}
}
}
</script> </script>
...@@ -83,7 +83,8 @@ ...@@ -83,7 +83,8 @@
:show-btn-ids="['9122306', '9122307']" /> :show-btn-ids="['9122306', '9122307']" />
</span> </span>
<!-- 关联 --> <!-- 关联 -->
<span v-if="scope.scope.relateStatus == 0" style="margin-right: 10px"> <!-- v-if="scope.scope.relateStatus == 0" -->
<span style="margin-right: 10px">
<auth-button :data="scope.scope" <auth-button :data="scope.scope"
:show-btn-ids="['9122309']" /> :show-btn-ids="['9122309']" />
</span> </span>
...@@ -130,25 +131,9 @@ ...@@ -130,25 +131,9 @@
:form-rules="isRelateRules" :form-rules="isRelateRules"
label-width="150px" label-width="150px"
:select-visible="isRelateVisible" :select-visible="isRelateVisible"
:slot-arr="['relateMerchantId']" :slot-arr="[]"
@handleClose="handleRelateClose" @handleClose="handleRelateClose"
@handleConfirm="handleRelateConfirm"> @handleConfirm="handleRelateConfirm">
<template #relateMerchantId="scope">
<el-select v-model="isRelateForm[scope.scope.name]"
v-el-select-loadmore="relateMerchantLoadmore"
filterable
:placeholder="scope.scope.placeholder || '请选择关联门店'"
remote
:remote-method="relateMerchantRemoteMethod"
reserve-keyword
style="width: 256px">
<el-option v-for="subItem in baseData.relateMerchantOpt"
:key="subItem.merchantId"
:label="subItem.merchantName"
:value="subItem.merchantId">
</el-option>
</el-select>
</template>
</glsk-form-dialog> </glsk-form-dialog>
</d2-container> </d2-container>
</template> </template>
...@@ -235,7 +220,11 @@ export default { ...@@ -235,7 +220,11 @@ export default {
{ {
label: "关联门店", label: "关联门店",
name: "relateMerchantId", name: "relateMerchantId",
placeholder: "请选择关联门店", type: "select",
optionList: [],
optionId: "confId",
optionLabel: "confValue",
optionsName: "relateMerchantOpt",
}, },
], ],
isRelateRules: { isRelateRules: {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!