Commit 0b3e418d authored by “yiyousong”'s avatar “yiyousong”

feat:站点添加在线取号、微预约、政务地图控制

parent 3fe0cdd8
......@@ -14,13 +14,10 @@
>
</div>
<div class="content">
<a-form-model
ref="ruleForm"
:model="formInfo"
:rules="formRules"
layout="inline"
>
<a-form-model ref="ruleForm" :model="formInfo" :rules="formRules">
<div class="color_title">基本信息</div>
<a-row>
<a-col :span="8">
<a-form-model-item label="中心名称" prop="siteName">
<a-input
v-model="formInfo.siteName"
......@@ -28,6 +25,8 @@
placeholder="请输入中心名称"
/>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="英文名称" prop="englishName">
<a-input
v-model="formInfo.englishName"
......@@ -35,22 +34,17 @@
placeholder="请输入中心名称"
/>
</a-form-model-item>
<!-- <a-form-model-item label="中心编号" prop="siteCode">
<a-input
v-model="formInfo.siteCode"
type="text"
placeholder="请输入中心编号"
/>
</a-form-model-item> -->
</a-col>
<a-col :span="8">
<a-form-model-item label="区域编号" prop="areaCode">
<a-input
v-model="areaInfo.areaCode"
readOnly
type="text"
placeholder="请输入区域编号"
/>
</a-form-model-item>
/> </a-form-model-item
></a-col>
<a-col :span="8">
<a-form-model-item label="IP" prop="siteIp">
<a-input
v-model="formInfo.siteIp"
......@@ -58,6 +52,8 @@
placeholder="请输入IP地址"
/>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="中心端口" prop="sitePort">
<a-input
v-model="formInfo.sitePort"
......@@ -65,13 +61,17 @@
placeholder="请输入中心端口"
/>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="中心电话" prop="siteTel">
<a-input
v-model="formInfo.siteTel"
type="text"
placeholder="请输入座机号码:区号-号码"
placeholder="请输入中心电话"
/>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="站点负责人" prop="leadingOfficial">
<a-input
v-model="formInfo.leadingOfficial"
......@@ -79,15 +79,25 @@
placeholder="请输入站点负责人"
/>
</a-form-model-item>
<a-form-model-item label="负责人电话" prop="leadingOfficialTelephone">
</a-col>
<a-col :span="8">
<a-form-model-item
label="负责人电话"
prop="leadingOfficialTelephone"
>
<a-input
v-model="formInfo.leadingOfficialTelephone"
type="text"
placeholder="请输入负责人电话电话"
/>
</a-form-model-item>
<a-form-model-item label="总栋数" prop="building" class="building">
</a-col>
<a-col :span="8">
<a-form-model-item
label="总栋数"
prop="building"
class="building"
>
<a-input
style="padding-right: 40px"
v-model.number="formInfo.building"
......@@ -96,6 +106,8 @@
/>
<span class="tips"></span>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="总楼层" prop="level" class="level">
<a-input
style="padding-right: 40px"
......@@ -105,6 +117,8 @@
/>
<span class="tips"></span>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="中心位置" prop="proCode">
<a-cascader
v-model="cityData"
......@@ -119,6 +133,8 @@
@change="oncityChange"
/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="详细地址" prop="detailAddress">
<a-input
v-model="formInfo.detailAddress"
......@@ -134,6 +150,8 @@
>获取经纬度</a-button
>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="经度" prop="longitude">
<a-input
v-model="formInfo.longitude"
......@@ -141,6 +159,8 @@
placeholder="请输入经度"
/>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item label="纬度" prop="latitude">
<a-input
v-model="formInfo.latitude"
......@@ -148,6 +168,8 @@
placeholder="请输入纬度"
/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="中心简介" prop="siteRemark">
<a-textarea
v-model="formInfo.siteRemark"
......@@ -156,6 +178,8 @@
allow-clear
/>
</a-form-model-item>
</a-col>
<a-col :span="24">
<a-form-model-item label="中心Logo" prop="logoPath">
<a-upload
:action="api + 'base/file/commonupload'"
......@@ -170,30 +194,13 @@
<div class="ant-upload-text">上传图片</div>
</div>
</a-upload>
<!-- <a-upload
name="file"
list-type="picture-card"
class="avatar-uploader"
:show-upload-list="false"
:action="api + 'base/file/commonupload'"
:before-upload="beforeUpload"
@change="handleChange"
:accept="accept"
>
<img
class="logo"
v-if="formInfo.logoPath"
:src="api + formInfo.logoPath"
/>
<div v-else>
<a-icon :type="loading ? 'loading' : 'plus'" />
<div class="ant-upload-text">上传图片</div>
</div>
</a-upload> -->
</a-form-model-item>
<div class="color_title">办公信息</div>
</a-col>
</a-row>
<div class="color_title">办公信息</div>
<a-row>
<a-col :span="8">
<a-form-model-item class="amWork-time" prop="amWorkEndTime">
<a-form-model-item label="上午上班" prop="amWorkStartTime">
<a-time-picker
......@@ -209,6 +216,8 @@
/>
</a-form-model-item>
</a-form-model-item>
</a-col>
<a-col :span="8">
<a-form-model-item class="pmWork-time" prop="pmWorkEndTime">
<a-form-model-item label="下午上班" prop="pmWorkStartTime">
<a-time-picker
......@@ -224,6 +233,8 @@
/>
</a-form-model-item>
</a-form-model-item>
</a-col>
</a-row>
<a-form-model-item label="工作日">
<y-checkbox
v-model="formInfo.workday1"
......@@ -254,6 +265,23 @@
checkText="星期天"
></y-checkbox>
</a-form-model-item>
<a-row>
<a-col :span="4">
<a-form-model-item label="在线取号" prop="onlineTake">
<YSwitch v-model="formInfo.onlineTake"></YSwitch>
</a-form-model-item>
</a-col>
<a-col :span="4">
<a-form-model-item label="微预约" prop="appointment">
<YSwitch v-model="formInfo.appointment"></YSwitch>
</a-form-model-item>
</a-col>
<a-col :span="4">
<a-form-model-item label="政务地图" prop="gowMap">
<YSwitch v-model="formInfo.gowMap"></YSwitch>
</a-form-model-item>
</a-col>
</a-row>
<div class="color_title">部署板块</div>
<a-form-model-item
:label-col="{ span: 2 }"
......@@ -281,6 +309,7 @@
<script>
import { modelList, siteSave } from "@/services/basicsetFun";
import YCheckbox from "@/components/ycheckbox/YCheckbox.vue";
import YSwitch from "@/components/yswitch/YSwitch.vue";
// import options from "@/utils/city";
import { regionData } from "element-china-area-data";
import PrevieModal from "@/components/PrevieModal.vue";
......@@ -294,18 +323,11 @@ export default {
type: String,
required: true,
},
// labelCol: {
// type: Number,
// default: 5,
// },
// wrapperCol: {
// type: Number,
// default: 16,
// },
},
components: {
YCheckbox,
PrevieModal,
YSwitch,
},
data() {
// 验证手机号码
......@@ -319,16 +341,16 @@ export default {
callback();
}
};
const changeLandline = (rule, value, callback) => {
if (!value) {
callback(new Error("请输入中心座机号"));
callback();
} else if (!/^[0][1-9]{2,3}-[0-9]{5,10}$/.test(value)) {
callback(new Error("格式:区号-电话号码"));
} else {
callback();
}
};
// const changeLandline = (rule, value, callback) => {
// if (!value) {
// callback(new Error("请输入中心座机号"));
// callback();
// } else if (!/^[0][1-9]{2,3}-[0-9]{5,10}$/.test(value)) {
// callback(new Error("格式:区号-电话号码"));
// } else {
// callback();
// }
// };
return {
api: process.env.VUE_APP_API_BASE_URL + "/",
api2: process.env.VUE_APP_API_IMG_URL,
......@@ -379,6 +401,9 @@ export default {
workday6: "", // 周六
workday7: "", // 周日
modelIds: [], // 部署模块
onlineTake: 0, // 在线取号
appointment: 0, // 微预约
gowMap: 0, // 政务地图
}, //表单提交数据
indeterminate: true,
checkAll: false,
......@@ -471,7 +496,7 @@ export default {
siteTel: [
{
required: true,
validator: changeLandline,
message: "中心电话不能为空",
trigger: "blur",
},
],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment