|
@@ -1,12 +1,22 @@
|
|
|
<template>
|
|
|
<div class="card-edit">
|
|
|
<a-form :model="dataModel" autocomplete="off" @finish="onFinish">
|
|
|
- <a-divider orientation="left">企业信息管理</a-divider>
|
|
|
+ <a-divider orientation="left">基础信息</a-divider>
|
|
|
<a-row :gutter="24">
|
|
|
- <a-col :span="7">
|
|
|
+ <a-col :span="8">
|
|
|
+ <a-form-item
|
|
|
+ label="统一社会信用代码"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="companyCode"
|
|
|
+ :rules="[{ required: true, message: '请输入统一信用代码!' }]"
|
|
|
+ >
|
|
|
+ <a-input v-model:value="dataModel.companyCode" placeholder=""/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
label="企业名称"
|
|
|
- :label-col="{ span: 7 }"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
name="companyName"
|
|
|
:rules="[{ required: true, message: '请输入企业名称!' }]"
|
|
|
>
|
|
@@ -15,30 +25,45 @@
|
|
|
</a-col>
|
|
|
<a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="统一社会信用代码"
|
|
|
+ label="所属驿站"
|
|
|
:label-col="{ span: 8 }"
|
|
|
- name="companyCode"
|
|
|
- :rules="[{ required: true, message: '请输入统一信用代码!' }]"
|
|
|
+ name="siteID"
|
|
|
+ :rules="[{ required: true, message: '请选择所属驿站!' }]"
|
|
|
>
|
|
|
- <a-input v-model:value="dataModel.companyCode" placeholder=""/>
|
|
|
+ <a-select
|
|
|
+ ref="select"
|
|
|
+ v-model:value="dataModel.siteID"
|
|
|
+ v-on:change="siteChange"
|
|
|
+ :options="siteList"
|
|
|
+ :field-names="{ label: 'siteName', value: 'siteID' }"
|
|
|
+ >
|
|
|
+ </a-select>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
- <a-col :span="9">
|
|
|
+ </a-row>
|
|
|
+ <a-row :gutter="24">
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="法定代表人(负责人)"
|
|
|
- :label-col="{ span: 9 }"
|
|
|
- name="frName"
|
|
|
- :rules="[{ required: true, message: '请选择法定代表人!' }]"
|
|
|
+ label="企业办公地址"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="address"
|
|
|
+ :rules="[{ required: true, message: '请输入企业办公地址!' }]"
|
|
|
>
|
|
|
- <a-input v-model:value="dataModel.frName" placeholder=""/>
|
|
|
+ <a-textarea v-model:value="dataModel.address" placeholder="" :rows="4"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="7">
|
|
|
+ <a-col :span="8">
|
|
|
+ <a-form-item
|
|
|
+ label="企业联系人"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="userName"
|
|
|
+ :rules="[{ required: true, message: '请输入企业联系人!' }]"
|
|
|
+ >
|
|
|
+ <a-input v-model:value="dataModel.userName" placeholder=""/>
|
|
|
+ </a-form-item>
|
|
|
<a-form-item
|
|
|
label="企业状态"
|
|
|
- :label-col="{ span: 7 }"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
name="recordStatus"
|
|
|
:rules="[{ required: true, message: '请选择企业状态!' }]"
|
|
|
>
|
|
@@ -50,102 +75,102 @@
|
|
|
>
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
|
-
|
|
|
</a-col>
|
|
|
<a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="营业执照有效期"
|
|
|
+ label="企业联系电话"
|
|
|
:label-col="{ span: 8 }"
|
|
|
- name="validTime"
|
|
|
- :rules="[{ required: true, message: '请输入营业执照有效期!' }]"
|
|
|
+ name="userMobile"
|
|
|
+ :rules="[{ required: true, message: '请输入企业联系电话!' }]"
|
|
|
>
|
|
|
- <label v-if="!showPicker" style="float:left;line-height: 30px;height: 30px;font-size: 16px;">{{dataModel.validTime}}</label>
|
|
|
- <a-date-picker
|
|
|
- v-if="showPicker"
|
|
|
- v-model:value="dataModel.validTime"
|
|
|
- picker="date"
|
|
|
- value-format="YYYY-MM-DD"
|
|
|
- />
|
|
|
- <div v-if="!showPicker" style="margin-left:10px;color:blue;float:left;line-height: 30px;height: 30px;font-size: 16px;"
|
|
|
- v-on:click="showDataPicker">选择有效期</div>
|
|
|
+ <a-input v-model:value="dataModel.userMobile" placeholder=""/>
|
|
|
</a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="9">
|
|
|
<a-form-item
|
|
|
- label="企业分类"
|
|
|
- :label-col="{ span: 9 }"
|
|
|
- name="companyType"
|
|
|
- :rules="[{ required: false, message: '请选择企业分类!' }]"
|
|
|
+ label="是否缺工"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="recordStatus"
|
|
|
+ :rules="[{ required: true, message: '请选择是否缺工!' }]"
|
|
|
>
|
|
|
<a-select
|
|
|
ref="select"
|
|
|
- v-model:value="dataModel.companyType"
|
|
|
- :options="studentStatuslist"
|
|
|
+ v-model:value="dataModel.recordStatus"
|
|
|
+ :options="companyStatusList"
|
|
|
:field-names="{ label: 'name', value: 'value' }"
|
|
|
>
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="7">
|
|
|
+ <a-divider orientation="left">其他信息</a-divider>
|
|
|
+ <a-row>
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="联系人姓名"
|
|
|
- :label-col="{ span: 7 }"
|
|
|
- name="userName"
|
|
|
- :rules="[{ required: true, message: '请输入企业联系人!' }]"
|
|
|
+ label="法定代表人(负责人)"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="frName"
|
|
|
>
|
|
|
- <a-input v-model:value="dataModel.userName" placeholder=""/>
|
|
|
+ <a-input v-model:value="dataModel.frName" placeholder=""/>
|
|
|
</a-form-item>
|
|
|
-
|
|
|
</a-col>
|
|
|
<a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="联系电话"
|
|
|
+ label="营业执照有效期"
|
|
|
:label-col="{ span: 8 }"
|
|
|
- name="userMobile"
|
|
|
- :rules="[{ required: true, message: '请输入企业联系电话!' }]"
|
|
|
+ name="validTime"
|
|
|
>
|
|
|
- <a-input v-model:value="dataModel.userMobile" placeholder=""/>
|
|
|
- </a-form-item>
|
|
|
+ <a-radio-group v-model:value="showPicker" name="showPicker">
|
|
|
+ <a-radio value="1">至长期</a-radio>
|
|
|
+ <a-radio value="2">
|
|
|
+ <a-date-picker
|
|
|
+ v-model:value="showDateTime"
|
|
|
+ picker="date"
|
|
|
+ value-format="YYYY-MM-DD"
|
|
|
+ />
|
|
|
+ </a-radio>
|
|
|
+ </a-radio-group>
|
|
|
|
|
|
+ <!-- <label v-if="!showPicker"-->
|
|
|
+ <!-- style="float:left;line-height: 30px;height: 30px;font-size: 16px;">{{ dataModel.validTime }}</label>-->
|
|
|
+ <!-- -->
|
|
|
+ <!-- <div v-if="!showPicker"-->
|
|
|
+ <!-- style="margin-left:10px;color:blue;float:left;line-height: 30px;height: 30px;font-size: 16px;"-->
|
|
|
+ <!-- v-on:click="showDataPicker">选择有效期-->
|
|
|
+ <!-- </div>-->
|
|
|
+ </a-form-item>
|
|
|
</a-col>
|
|
|
- <a-col :span="9">
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="联系邮箱"
|
|
|
- :label-col="{ span: 9 }"
|
|
|
+ label="企业邮箱"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
name="companyEmail"
|
|
|
- :rules="[{ required: true, message: '请选择企业邮箱!' }]"
|
|
|
>
|
|
|
<a-input v-model:value="dataModel.companyEmail" placeholder=""/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="7">
|
|
|
+ <a-row>
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="所属驿站"
|
|
|
- :label-col="{ span: 7 }"
|
|
|
- name="siteID"
|
|
|
- :rules="[{ required: true, message: '请选择所属驿站!' }]"
|
|
|
+ label="企业分类"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="companyType"
|
|
|
+ :rules="[{ required: false, message: '请选择企业分类!' }]"
|
|
|
>
|
|
|
<a-select
|
|
|
ref="select"
|
|
|
- v-model:value="dataModel.siteID"
|
|
|
- v-on:change="siteChange"
|
|
|
- :options="siteList"
|
|
|
- :field-names="{ label: 'siteName', value: 'siteID' }"
|
|
|
+ v-model:value="dataModel.companyType"
|
|
|
+ :options="studentStatuslist"
|
|
|
+ :field-names="{ label: 'name', value: 'value' }"
|
|
|
>
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
|
-
|
|
|
</a-col>
|
|
|
<a-col :span="8">
|
|
|
<a-form-item
|
|
|
label="所属县区"
|
|
|
:label-col="{ span: 8 }"
|
|
|
name="regionCode"
|
|
|
- :rules="[{ required: true, message: '请选择所属县区!' }]"
|
|
|
+ :rules="[{ required: false, message: '请选择所属县区!' }]"
|
|
|
>
|
|
|
<a-select
|
|
|
ref="select"
|
|
@@ -156,14 +181,13 @@
|
|
|
>
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
|
-
|
|
|
</a-col>
|
|
|
- <a-col :span="9">
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
label="所属街道"
|
|
|
- :label-col="{ span: 9 }"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
name="streetCode"
|
|
|
- :rules="[{ required: true, message: '请选择所属街道!' }]"
|
|
|
+ :rules="[{ required: false, message: '请选择所属街道!' }]"
|
|
|
>
|
|
|
<a-select
|
|
|
ref="select"
|
|
@@ -173,20 +197,9 @@
|
|
|
>
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
|
-
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="7">
|
|
|
- <a-form-item
|
|
|
- label="企业办公地址"
|
|
|
- :label-col="{ span: 7 }"
|
|
|
- name="address"
|
|
|
- :rules="[{ required: true, message: '请输入企业办公地址!' }]"
|
|
|
- >
|
|
|
- <a-textarea v-model:value="dataModel.address" placeholder="" :rows="4"/>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
+ <a-row>
|
|
|
<a-col :span="8">
|
|
|
<a-form-item
|
|
|
label="企业规模"
|
|
@@ -202,37 +215,38 @@
|
|
|
>
|
|
|
</a-select>
|
|
|
</a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="参保人数(人)"
|
|
|
+ label="用工情况(人)"
|
|
|
:label-col="{ span: 8 }"
|
|
|
- name="insuredCount"
|
|
|
- :rules="[{ required: true, message: '请输入参保人数!' }]"
|
|
|
+ name="workSituation"
|
|
|
+ :rules="[{ required: false, message: '请输入用工人数!' }]"
|
|
|
>
|
|
|
- <a-input v-model:value="dataModel.insuredCount" type="number" min="1" placeholder=""/>
|
|
|
+ <a-input v-model:value="dataModel.workSituation" placeholder=""/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
- <a-col :span="9">
|
|
|
+ <a-col :span="8">
|
|
|
<a-form-item
|
|
|
- label="用工情况(人)"
|
|
|
- :label-col="{ span: 9 }"
|
|
|
- name="workSituation"
|
|
|
- :rules="[{ required: true, message: '请输入用工人数!' }]"
|
|
|
+ label="参保人数(人)"
|
|
|
+ :label-col="{ span: 8 }"
|
|
|
+ name="insuredCount"
|
|
|
+ :rules="[{ required: false, message: '请输入参保人数!' }]"
|
|
|
>
|
|
|
- <a-input v-model:value="dataModel.workSituation" placeholder=""/>
|
|
|
+ <a-input v-model:value="dataModel.insuredCount" placeholder=""/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
- <a-divider orientation="left">其他信息</a-divider>
|
|
|
<a-row>
|
|
|
- <a-col class="table-bottom-a1">
|
|
|
- <a-form-item :label-col="{span:8}" label="" name="businScope">
|
|
|
+ <a-col class="table-bottom-a1" span="24">
|
|
|
+ <a-form-item :label-col="{span:24}" name="businScope" label="经营范围">
|
|
|
<a-textarea v-model:value="dataModel.businScope" placeholder="经营范围" :rows="4"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
|
<a-row>
|
|
|
- <a-col class="table-bottom-a1">
|
|
|
- <a-form-item :label-col="{span:8}" label="" name="companyDesc">
|
|
|
+ <a-col class="table-bottom-a1" span="24">
|
|
|
+ <a-form-item :label-col="{span:24}" label="企业简介" name="companyDesc">
|
|
|
<a-textarea v-model:value="dataModel.companyDesc" placeholder="企业简介" :rows="4"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
@@ -269,15 +283,15 @@ export default defineComponent(
|
|
|
const router = useRouter();
|
|
|
const siteList = ref<SelectProps['options']>();
|
|
|
const tabsViewStore = useTabsViewStore();
|
|
|
- const showPicker = ref<boolean>(false);
|
|
|
- const showDataPicker = ()=>{
|
|
|
- let toDay = new Date();
|
|
|
- formState.dataModel.validTime = dayjs(toDay.toLocaleDateString().replaceAll("/","-")) ;
|
|
|
- showPicker.value = true;
|
|
|
- }
|
|
|
+ const showPicker = ref('1');
|
|
|
+ const showDateTime = ref<any>();
|
|
|
+ // const showDataPicker = () => {
|
|
|
+ // let toDay = new Date();
|
|
|
+ // showDateTime.value = dayjs(new Date().toLocaleDateString().replaceAll("/", "-"));
|
|
|
+ // }
|
|
|
const companyStatusList = ref<SelectProps['options']>([
|
|
|
{value: 1, name: '在营'},
|
|
|
- {value: 0, name: '关闭'},
|
|
|
+ {value: 0, name: '停业'},
|
|
|
]);
|
|
|
const regionList = ref<SelectProps['options']>();
|
|
|
const streetList = ref<SelectProps['options']>();
|
|
@@ -298,14 +312,14 @@ export default defineComponent(
|
|
|
siteList.value = data;
|
|
|
})
|
|
|
|
|
|
- const getCompanyModelList = async function(){
|
|
|
- const data :any = await getSysDictionaryList("CompanyModel");
|
|
|
+ const getCompanyModelList = async function () {
|
|
|
+ const data: any = await getSysDictionaryList("CompanyModel");
|
|
|
companyModelList.value = data;
|
|
|
- console.log("companyModelList",companyModelList.value );
|
|
|
+ console.log("companyModelList", companyModelList.value);
|
|
|
}
|
|
|
|
|
|
- const siteChange = async function(){
|
|
|
- const curSiteData :any = await getSiteByID(formState.dataModel.siteID);
|
|
|
+ const siteChange = async function () {
|
|
|
+ const curSiteData: any = await getSiteByID(formState.dataModel.siteID);
|
|
|
formState.dataModel.regionCode = curSiteData.regionCode;
|
|
|
get('system/area/getAreaList', {code: formState.dataModel.regionCode}).then(data => {
|
|
|
streetList.value = data;
|
|
@@ -316,18 +330,24 @@ export default defineComponent(
|
|
|
const changeCity = () => {
|
|
|
if (formState.dataModel.regionCode) {
|
|
|
get('system/area/getAreaList', {code: formState.dataModel.regionCode}).then(data => {
|
|
|
- console.log("streetList",data);
|
|
|
+ console.log("streetList", data);
|
|
|
streetList.value = data;
|
|
|
})
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- const regionChange =async function(){
|
|
|
+ const regionChange = async function () {
|
|
|
formState.dataModel.streetCode = null;
|
|
|
changeCity();
|
|
|
}
|
|
|
|
|
|
const onFinish = () => {
|
|
|
+ console.log(showPicker.value);
|
|
|
+ if (showPicker.value === '1') {
|
|
|
+ formState.dataModel.validTime = '长期';
|
|
|
+ } else {
|
|
|
+ formState.dataModel.validTime = showDateTime.value;
|
|
|
+ }
|
|
|
save(formState.dataModel).then(result => {
|
|
|
if (result) {
|
|
|
tabsViewStore.closeCurrentTab(fullPath);
|
|
@@ -340,7 +360,12 @@ export default defineComponent(
|
|
|
getCompanyModelList();
|
|
|
getCompanyById(id).then(result => {
|
|
|
formState.dataModel = result;
|
|
|
- showPicker.value = formState.dataModel.validTime !='长期';
|
|
|
+ showPicker.value = formState.dataModel.validTime == '长期' ? '1' : '2';
|
|
|
+ if (showPicker.value === '1')
|
|
|
+ showDateTime.value = dayjs(new Date().toLocaleDateString().replaceAll("/", "-"));
|
|
|
+ else
|
|
|
+ showDateTime.value = formState.dataModel.validTime;
|
|
|
+ console.log(showDateTime);
|
|
|
changeCity();
|
|
|
})
|
|
|
};
|
|
@@ -357,8 +382,8 @@ export default defineComponent(
|
|
|
streetList,
|
|
|
companyModelList,
|
|
|
companyStatusList,
|
|
|
- showDataPicker,
|
|
|
changeCity,
|
|
|
+ showDateTime,
|
|
|
regionChange,
|
|
|
}
|
|
|
},
|