Browse Source

代码规范修改

master
zhangyongzhangyong 6 years ago
parent
commit
10fda6c50c
  1. 352
      src/views/modules/heart/actinfo-add-or-update.vue
  2. 13
      src/views/modules/heart/actinfo-list.vue
  3. 430
      src/views/modules/heart/map-select.vue

352
src/views/modules/heart/actinfo-add-or-update.vue

@ -289,12 +289,12 @@ export default {
return {
visible: false,
dataForm: {
id:"",
id: '',
title: '',
headPic: '',
signupStartTime: '',
signupEndTime: '',
actQuotaCategory:'1',
actQuotaCategory: '1',
actStartTime: '',
actEndTime: '',
actAddress: '',
@ -317,88 +317,87 @@ export default {
deptId: '',
punishmentPoints: '',
reward: '',
isBanner:"1",
isBanner: '1',
actUserDefaultState: '1',
bannerUrl:""
bannerUrl: ''
},
isSignupEndTime: {
disabledDate(time) {
return time < Date.now() - 8.64e7;//8.64e7=1000*60*60*24
isSignupEndTime: {
disabledDate (time) {
return time < Date.now() - 8.64e7 // 8.64e7=1000*60*60*24
}
},
isImgRequired: true,
mapSelectVisible: false,
signInIsAble: true,
isAble: false,
loading: false,
//
quillEditor: null,
quillEditorToolbarOptions: [
['bold', 'italic', 'underline', 'strike'],
['blockquote', 'code-block', 'image'],
[{ 'header': 1 }, { 'header': 2 }],
[{ 'list': 'ordered' }, { 'list': 'bullet' }],
[{ 'script': 'sub' }, { 'script': 'super' }],
[{ 'indent': '-1' }, { 'indent': '+1' }],
[{ 'direction': 'rtl' }],
[{ 'size': ['small', false, 'large', 'huge'] }],
[{ 'header': [1, 2, 3, 4, 5, 6, false] }],
[{ 'color': [] }, { 'background': [] }],
[{ 'font': [] }],
[{ 'align': [] }],
['clean']
],
uploadUrl: '',
pickerBeginDateBefore: {
disabledDate: (time) => {
let beginDateVal = this.dataForm.actStartTime
if (beginDateVal) {
return time.getTime() > new Date(beginDateVal).getTime()
}
}
},
pickerBeginSignInDateAfter: {
disabledDate: (time) => {
let EndDateVal = this.dataForm.signinEndTime
if (EndDateVal) {
return time.getTime() < new Date(EndDateVal).getTime()
}
},
isImgRequired: true,
mapSelectVisible:false,
signInIsAble: true,
isAble: false,
loading: false,
//
quillEditor: null,
quillEditorToolbarOptions: [
['bold', 'italic', 'underline', 'strike'],
['blockquote', 'code-block', 'image'],
[{ 'header': 1 }, { 'header': 2 }],
[{ 'list': 'ordered' }, { 'list': 'bullet' }],
[{ 'script': 'sub' }, { 'script': 'super' }],
[{ 'indent': '-1' }, { 'indent': '+1' }],
[{ 'direction': 'rtl' }],
[{ 'size': ['small', false, 'large', 'huge'] }],
[{ 'header': [1, 2, 3, 4, 5, 6, false] }],
[{ 'color': [] }, { 'background': [] }],
[{ 'font': [] }],
[{ 'align': [] }],
['clean']
],
uploadUrl: '',
pickerBeginDateBefore: {
disabledDate: (time) => {
let beginDateVal = this.dataForm.actStartTime
if (beginDateVal) {
return time.getTime() > new Date(beginDateVal).getTime()
}
}
},
pickerBeginSignInDateAfter: {
disabledDate: (time) => {
let EndDateVal = this.dataForm.signinEndTime
if (EndDateVal) {
return time.getTime() < new Date(EndDateVal).getTime()
}
}
},
pickerBeginDateAfter: {
disabledDate: (time) => {
let EndDateVal = this.dataForm.actEndTime
if (EndDateVal) {
return time.getTime() < new Date(EndDateVal).getTime()
}
}
}
},
pickerBeginDateAfter: {
disabledDate: (time) => {
let EndDateVal = this.dataForm.actEndTime
if (EndDateVal) {
return time.getTime() < new Date(EndDateVal).getTime()
}
}
}
}
},
created () {
this.$http
.get(`/sys/user/deptOptions/getByLoginUser`)
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.options = res.data.options
})
.catch(() => {})
this.visible = true
this.$nextTick(() => {
//
this.hideUpload = false
this.uploadUrl = `${window.SITE_CONFIG['apiURL']}/oss/file/upload?token=${Cookies.get('token')}`
if (this.quillEditor) {
this.quillEditor.deleteText(0, this.quillEditor.getLength())
} else {
this.quillEditorHandle()
}
// end
})
},
created () {
this.$http
.get(`/sys/user/deptOptions/getByLoginUser`)
.then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.options = res.data.options
})
.catch(() => {})
this.visible = true
this.$nextTick(() => {
//
this.hideUpload = false
this.uploadUrl = `${window.SITE_CONFIG['apiURL']}/oss/file/upload?token=${Cookies.get('token')}`
if (this.quillEditor) {
this.quillEditor.deleteText(0, this.quillEditor.getLength())
} else {
this.quillEditorHandle()
}
// end
})
},
computed: {
dataRule () {
return {
@ -525,10 +524,9 @@ export default {
}
},
backToActList () {
this.$emit('refreshDataList')
this.$parent.selectComponent = 'ActInfoList'
this.$router.push({ path: '/heart-actinfo'})
this.$emit('refreshDataList')
this.$parent.selectComponent = 'ActInfoList'
this.$router.push({ path: '/heart-actinfo'})
},
init () {
this.visible = true
@ -539,60 +537,60 @@ export default {
}
})
},
position(position){
if(position.type == 1 ){
this.dataForm.actAddress = position.address;
this.dataForm.actLatitude = position.latitude;
this.dataForm.actLongitude = position.longitude;
this.dataForm.signinAddress = position.address;
this.dataForm.signinLatitude = position.latitude;
this.dataForm.signinLongitude = position.longitude;
} else {
this.dataForm.signinAddress = position.address;
this.dataForm.signinLatitude = position.latitude;
this.dataForm.signinLongitude = position.longitude;
position(position){
if(position.type == 1 ){
this.dataForm.actAddress = position.address
this.dataForm.actLatitude = position.latitude
this.dataForm.actLongitude = position.longitude
this.dataForm.signinAddress = position.address
this.dataForm.signinLatitude = position.latitude
this.dataForm.signinLongitude = position.longitude
} else {
this.dataForm.signinAddress = position.address
this.dataForm.signinLatitude = position.latitude
this.dataForm.signinLongitude = position.longitude
}
},
//
quillEditorHandle () {
this.quillEditor = new Quill('#J_quillEditor', {
modules: {
toolbar: this.quillEditorToolbarOptions
},
theme: 'snow'
})
this.quillEditor.container.style.height = `${300}px`
// // (使element upload)
this.quillEditor.getModule('toolbar').addHandler('image', () => {
this.$refs.uploadBtn.$el.click()
})
//
this.quillEditor.on('text-change', () => {
this.dataForm.actContent = this.quillEditor.root.innerHTML
if ((this.dataForm.actContent).length > 10000) {
return this.$message.error('您输入的的内容已超过字数')
}
},
//
quillEditorHandle () {
this.quillEditor = new Quill('#J_quillEditor', {
modules: {
toolbar: this.quillEditorToolbarOptions
},
theme: 'snow'
})
this.quillEditor.container.style.height = `${300}px`
// // (使element upload)
this.quillEditor.getModule('toolbar').addHandler('image', () => {
this.$refs.uploadBtn.$el.click()
})
//
this.quillEditor.on('text-change', () => {
this.dataForm.actContent = this.quillEditor.root.innerHTML
if ((this.dataForm.actContent).length > 10000) {
return this.$message.error('您输入的的内容已超过字数')
}
})
},
// ()
uploadBeforeUploadHandle (file) {
if (file.type !== 'image/jpg' && file.type !== 'image/jpeg' && file.type !== 'image/png' && file.type !== 'image/gif') {
this.$message.error(this.$t('upload.tip', { 'format': 'jpg、png、gif' }))
return false
}
},
// ()
uploadSuccessHandle (res, file, fileList) {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.quillEditor.insertEmbed(this.quillEditor.getSelection().index, 'image', res.data.url)
},
setRegistTime () {
this.dataForm.newsReleaseStartTime = this.time[0]
this.dataForm.newsReleaseEndTime = this.time[1]
},
// ends
})
},
// ()
uploadBeforeUploadHandle (file) {
if (file.type !== 'image/jpg' && file.type !== 'image/jpeg' && file.type !== 'image/png' && file.type !== 'image/gif') {
this.$message.error(this.$t('upload.tip', { 'format': 'jpg、png、gif' }))
return false
}
},
// ()
uploadSuccessHandle (res, file, fileList) {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.quillEditor.insertEmbed(this.quillEditor.getSelection().index, 'image', res.data.url)
},
setRegistTime () {
this.dataForm.newsReleaseStartTime = this.time[0]
this.dataForm.newsReleaseEndTime = this.time[1]
},
// ends
//
getInfo () {
this.$http.get(`/heart/actinfo/${this.dataForm.id}`).then(({ data: res }) => {
@ -607,30 +605,26 @@ export default {
},
//
dataFormSubmitHandle: debounce(function () {
if (this.dataForm.isActQuota == 0){
this.dataForm.actQuota = 0
}
if (this.dataForm.isActQuota == 0){
this.dataForm.actQuota = 0
}
this.$refs['dataForm'].validate((valid) => {
if (!valid) {
return false
}
var signUpEndTime = new Date(Date.parse(this.dataForm.signupEndTime));
var actStarTime = new Date(Date.parse(this.dataForm.actStartTime));
var actEndTime = new Date(Date.parse(this.dataForm.actEndTime));
var signinEndTime = new Date(Date.parse(this.dataForm.signinEndTime));
if (signUpEndTime > actStarTime) {
return this.$message.error('活动开始时间必须大于报名截止时间。');
}
if (actEndTime < actStarTime) {
return this.$message.error('活动结束时间必须大于活动开始时间。');
}
if (signinEndTime < actEndTime) {
return this.$message.error('签到结束时间必须大于活动结束时间。');
}
var signUpEndTime = new Date(Date.parse(this.dataForm.signupEndTime))
var actStarTime = new Date(Date.parse(this.dataForm.actStartTime))
var actEndTime = new Date(Date.parse(this.dataForm.actEndTime))
var signinEndTime = new Date(Date.parse(this.dataForm.signinEndTime))
if (signUpEndTime > actStarTime) {
return this.$message.error('活动开始时间必须大于报名截止时间.')
}
if (actEndTime < actStarTime) {
return this.$message.error('活动结束时间必须大于活动开始时间.')
}
if (signinEndTime < actEndTime) {
return this.$message.error('签到结束时间必须大于活动结束时间.')
}
this.isAble = true
this.$http[!this.dataForm.id ? 'post' : 'put']('/heart/actinfo/', this.dataForm).then(({ data: res }) => {
this.isAble = false
@ -647,34 +641,36 @@ export default {
}
})
this.$parent.selectComponent = 'ActInfoList'
this.$router.push({ path: '/heart-actinfo'})
this.$router.push({
path: '/heart-actinfo'
})
}).catch(() => {})
})
}, 1000, { 'leading': true, 'trailing': false }),
handleAvatarActSuccess (res, file) {
this.loading = false
this.dataForm.headPic = res.data.url
},
handleAvatarBannerSuccess (res, file) {
this.loading = false
this.dataForm.bannerUrl = res.data.url
},
beforeAvatarUpload (file) {
this.loading = true
},
handelError () {
this.loading = false
},
mapSelectHandle (type) {
this.mapSelectVisible = true
this.$nextTick(() => {
this.$refs.mapSelect.init(type,this.dataForm.clockRadius)
})
}
handleAvatarActSuccess (res, file) {
this.loading = false
this.dataForm.headPic = res.data.url
},
handleAvatarBannerSuccess (res, file) {
this.loading = false
this.dataForm.bannerUrl = res.data.url
},
beforeAvatarUpload (file) {
this.loading = true
},
handelError () {
this.loading = false
},
mapSelectHandle (type) {
this.mapSelectVisible = true
this.$nextTick(() => {
this.$refs.mapSelect.init(type, this.dataForm.clockRadius)
})
}
},
components: {
MapSelect
}
MapSelect
}
}
</script>
<style>

13
src/views/modules/heart/actinfo-list.vue

@ -101,7 +101,7 @@ export default {
dataForm: {
actStatus: '',
startTime: '',
endTime:''
endTime: ''
},
addOrUpdateVisible: false,
actInfoDetailVisible: false,
@ -134,7 +134,7 @@ export default {
ActUserClockLog
},
created: function () {
this.getDataList();
this.getDataList()
},
methods: {
detailAction (id) {
@ -143,7 +143,9 @@ export default {
},
addAction () {
this.$parent.selectComponent = 'ActInfoAdd'
this.$router.push({ path: '/heart-actinfo'})
this.$router.push(
{ path: '/heart-actinfo'}
)
},
joinManage (id) {
this.$parent.selectComponent = 'ActUserRelation'
@ -161,12 +163,11 @@ export default {
return '下架'
}
},
cancelHandle(row){
cancelHandle (row) {
let state = row.actStatus
if(state === '1'){
if (state === '1') {
this.actInfoCancelVisible = true
this.$nextTick(() => {
console.log(this.$refs.actinfoCancel.dataForm);
this.$refs.actinfoCancel.dataForm.id = row.id
this.$refs.actinfoCancel.init()
})

430
src/views/modules/heart/map-select.vue

@ -1,243 +1,249 @@
<template>
<el-dialog :visible.sync="visible" :close-on-click-modal="false" :close-on-press-escape="false">
<el-form :inline="true"
:model="dataForm"
:label-width="$i18n.locale === 'en-US' ? '120px' : '120px'">
<el-row>
<el-form-item label="活动地点:"
prop="address">
<el-input v-model="dataForm.address"
type="text"
clearable
style="width:400px">
</el-input>&emsp;
<el-button type="primary"
@click="searchKeyword()">搜索</el-button>
</el-form-item>
</el-row>
<el-row>
<el-form-item label=" "
prop="map">
<div>
<div id="container" style="width:500px;height:400px;"></div>
</div>
</el-form-item>
</el-row>
</el-form>
<address-check v-if="addressCheckVisible" ref="addressCheck" v-on:checkOk="checkOk"></address-check>
<el-dialog :visible.sync="visible" :close-on-click-modal="false" :close-on-press-escape="false">
<el-form
:inline="true"
:model="dataForm"
:label-width="$i18n.locale === 'en-US' ? '120px' : '120px'"
>
<el-row>
<el-form-item label="活动地点:" prop="address">
<el-input v-model="dataForm.address" type="text" clearable style="width:400px"></el-input>&emsp;
<el-button type="primary" @click="searchKeyword()">搜索</el-button>
</el-form-item>
</el-row>
<el-row>
<el-form-item label=" " prop="map">
<div>
<div id="container" style="width:500px;height:400px;"></div>
</div>
</el-form-item>
</el-row>
</el-form>
<address-check v-if="addressCheckVisible" ref="addressCheck" v-on:checkOk="checkOk"></address-check>
</el-dialog>
</template>
<script>
var searchService;
import jsonp from 'jsonp'
import AddressCheck from './address-check'
var searchService
export default {
name:'maps',
name: 'maps',
data () {
return {
dataForm: {
address: "",
longitude:0,//
latitude:0,//
city:'',
type: 1,
radius:200
},
visible: false,
addressCheckVisible:false
dataForm: {
address: '',
longitude: 0, //
latitude: 0, //
city: '',
type: 1,
radius: 200
},
visible: false,
addressCheckVisible: false
}
},
methods: {
init (type,radius) {
init (type, radius) {
this.visible = true
this.dataForm.address = ''
this.dataForm.type = type
this.dataForm.radius = radius
this.getMyLocation();
this.getMyLocation()
},
getAddress(lat,lng) {
this.dataForm.longitude = lng;
this.dataForm.latitude = lat;
var url3 = "https://apis.map.qq.com/ws/geocoder/v1/?location=" + lat + "," + lng + "&key=MQFBZ-LTWW6-R7XSK-MFXUQ-DVSIE-BGB4M&output=jsonp";
jsonp(url3, null, (err, data) => {
if (err) {
console.log(err)
}
console.log(data)
this.dataForm.address = data.result.address
})
getAddress (lat, lng) {
this.dataForm.longitude = lng
this.dataForm.latitude = lat
var url3 =
'https://apis.map.qq.com/ws/geocoder/v1/?location=' +
lat +
',' +
lng +
'&key=MQFBZ-LTWW6-R7XSK-MFXUQ-DVSIE-BGB4M&output=jsonp'
jsonp(url3, null, (err, data) => {
if (err) {
console.log(err)
}
console.log(data)
this.dataForm.address = data.result.address
})
},
getMyLocation() {
var geolocation = new qq.maps.Geolocation("MQFBZ-LTWW6-R7XSK-MFXUQ-DVSIE-BGB4M", "e家党群-管理端");
geolocation.getIpLocation(this.showPosition, this.showErr);
},
showPosition(position) {
console.log(position);
this.dataForm.latitude = position.lat;
this.dataForm.longitude = position.lng;
this.dataForm.city = position.city;
this.setMap();
},
showErr() {
console.log("定位失败");
this.getMyLocation();//使
},
setMap() {
const that = this
var markerList =[];
var radiusList =[];
//map qq.maps.Map()
//
var myLatlng = new qq.maps.LatLng(this.dataForm.latitude,this.dataForm.longitude);
//
var zoom = this.capacity();
var myOptions = {
zoom: zoom, //
center: myLatlng, //
mapTypeId: qq.maps.MapTypeId.ROADMAP //MapType
getMyLocation () {
var geolocation = new qq.maps.Geolocation(
'MQFBZ-LTWW6-R7XSK-MFXUQ-DVSIE-BGB4M',
'e家党群-管理端'
)
geolocation.getIpLocation(this.showPosition, this.showErr)
},
showPosition (position) {
console.log(position)
this.dataForm.latitude = position.lat
this.dataForm.longitude = position.lng
this.dataForm.city = position.city
this.setMap()
},
showErr () {
console.log('定位失败')
this.getMyLocation() // 使
},
setMap () {
const that = this
var markerList = []
var radiusList = []
// map qq.maps.Map()
//
var myLatlng = new qq.maps.LatLng(
this.dataForm.latitude,
this.dataForm.longitude
)
//
var zoom = this.capacity()
var myOptions = {
zoom: zoom, //
center: myLatlng, //
mapTypeId: qq.maps.MapTypeId.ROADMAP // MapType
}
// dom
var map = new qq.maps.Map(
document.getElementById('container'),
myOptions
)
//
var radius = new qq.maps.Circle({
center: new qq.maps.LatLng(
this.dataForm.latitude,
this.dataForm.longitude
),
radius: this.dataForm.radius,
map: map
})
radiusList.push(radius)
var marker = new qq.maps.Marker({
position: myLatlng,
map: map
})
markerList.push(marker)
//
qq.maps.event.addListener(map, 'click', function (event) {
that.cleanMarkRadius(markerList, radiusList)
that.getAddress(event.latLng.lat, event.latLng.lng)
var myLatlng = new qq.maps.LatLng(event.latLng.lat, event.latLng.lng)
map.setCenter(myLatlng)
var marker = new qq.maps.Marker({
position: event.latLng,
map: map
})
//
var radius = new qq.maps.Circle({
center: new qq.maps.LatLng(event.latLng.lat, event.latLng.lng),
radius: that.dataForm.radius,
map: map
})
radiusList.push(radius)
markerList.push(marker)
qq.maps.event.addListener(map, 'click', function (event) {
that.cleanMarkRadius(markerList, radiusList)
})
qq.maps.event.addListener(marker, 'click', function (event) {
that.addressCheckHandle()
})
})
//
searchService = new qq.maps.SearchService({
complete: function (result) {
var pois = result.detail.pois
if (pois == null || pois.length <= 0) {
alert('未找到地址!')
that.getAddress(that.dataForm.latitude, that.dataForm.longitude)
return
}
// //dom
var map = new qq.maps.Map(document.getElementById("container"), myOptions);
//
var radius = new qq.maps.Circle({
center:new qq.maps.LatLng(this.dataForm.latitude,this.dataForm.longitude),
radius: this.dataForm.radius,
map: map
});
radiusList.push(radius);
map.setCenter(pois[0].latLng)
that.getAddress(pois[0].latLng.lat, pois[0].latLng.lng)
var marker = new qq.maps.Marker({
position:myLatlng,
map:map
});
map: map,
position: pois[0].latLng
})
//
var radius = new qq.maps.Circle({
center: new qq.maps.LatLng(pois[0].latLng.lat, pois[0].latLng.lng),
radius: that.dataForm.radius,
map: map
})
radiusList.push(radius)
markerList.push(marker)
//
qq.maps.event.addListener(map, 'click', function(event) {
that.cleanMarkRadius(markerList,radiusList);
that.getAddress(event.latLng.lat,event.latLng.lng);
var myLatlng = new qq.maps.LatLng(event.latLng.lat,event.latLng.lng);
map.setCenter(myLatlng);
var marker = new qq.maps.Marker({
position:event.latLng,
map:map
});
//
var radius = new qq.maps.Circle({
center:new qq.maps.LatLng(event.latLng.lat,event.latLng.lng),
radius: that.dataForm.radius,
map: map
});
radiusList.push(radius);
markerList.push(marker)
qq.maps.event.addListener(map, 'click', function(event) {
that.cleanMarkRadius(markerList,radiusList);
});
qq.maps.event.addListener(marker, 'click', function(event) {
that.addressCheckHandle();
});
});
//
searchService = new qq.maps.SearchService({
complete : function(result){
var pois = result.detail.pois;
if(pois == null || pois.length <= 0){
alert("未找到地址!");
that.getAddress(that.dataForm.latitude,that.dataForm.longitude);
return
}
map.setCenter(pois[0].latLng);
that.getAddress(pois[0].latLng.lat,pois[0].latLng.lng);
var marker = new qq.maps.Marker({
map:map,
position: pois[0].latLng
});
//
var radius = new qq.maps.Circle({
center:new qq.maps.LatLng(pois[0].latLng.lat,pois[0].latLng.lng),
radius: that.dataForm.radius,
map: map
});
radiusList.push(radius);
markerList.push(marker);
that.cleanMarkRadius(markerList,radiusList);
qq.maps.event.addListener(marker, 'click', function(event) {
that.addressCheckHandle();
});
}
});
},
searchKeyword() {
searchService.setLocation(this.dataForm.city);
searchService.search(this.dataForm.address);
},
addressCheckHandle() {
if (this.dataForm.address =='' || !(this.dataForm.latitude > 0)){
alert("请选择地址!");
return
}
this.addressCheckVisible = true
this.$nextTick(() => {
this.$refs.addressCheck.init(this.dataForm)
that.cleanMarkRadius(markerList, radiusList)
qq.maps.event.addListener(marker, 'click', function (event) {
that.addressCheckHandle()
})
},
checkOk(checkOk){
if (checkOk){
this.$emit('position', this.dataForm)
this.visible = false
}
},
cleanMarkRadius(markerList,radiusList) {
if (markerList) {
if(markerList.length > 1){
for (var i = 0; i < markerList.length-1; i++) {
markerList[i].setMap(null);
}
} else {
for (var i = 0; i < markerList.length; i++) {
markerList[i].setMap(null);
}
}
})
},
searchKeyword () {
searchService.setLocation(this.dataForm.city)
searchService.search(this.dataForm.address)
},
addressCheckHandle () {
if (this.dataForm.address === '' || !(this.dataForm.latitude > 0)) {
alert('请选择地址!')
return
}
this.addressCheckVisible = true
this.$nextTick(() => {
this.$refs.addressCheck.init(this.dataForm)
})
},
checkOk (checkOk) {
if (checkOk) {
this.$emit('position', this.dataForm)
this.visible = false
}
},
cleanMarkRadius (markerList, radiusList) {
if (markerList) {
if (markerList.length > 1) {
for (var i4 = 0; i4 < markerList.length - 1; i4++) {
markerList[i4].setMap(null)
}
if (radiusList) {
if(radiusList.length > 1){
for (var i = 0; i < radiusList.length-1; i++) {
radiusList[i].setMap(null);
}
} else {
for (var i = 0; i < markerList.length; i++) {
radiusList[i].setMap(null);
}
}
} else {
for (var i3 = 0; i3 < markerList.length; i3++) {
markerList[i3].setMap(null)
}
},
capacity() {
if(0 < this.dataForm.radius && this.dataForm.radius <= 25){
return 18
} else if (25 < this.dataForm.radius && this.dataForm.radius <= 50){
return 17
} else if (50 < this.dataForm.radius && this.dataForm.radius <= 100){
return 16
} else if (100 < this.dataForm.radius && this.dataForm.radius <= 200){
return 15
} else if (200 < this.dataForm.radius && this.dataForm.radius <= 500){
return 14
} else if (500 < this.dataForm.radius && this.dataForm.radius <= 1000){
return 13
} else if (1000 < this.dataForm.radius && this.dataForm.radius <= 2000){
return 12
} else if (2000 < this.dataForm.radius && this.dataForm.radius <= 5000){
return 11
}
}
},
components: {
AddressCheck
if (radiusList) {
if (radiusList.length > 1) {
for (var i2 = 0; i2 < radiusList.length - 1; i2++) {
radiusList[i2].setMap(null)
}
} else {
for (var i1 = 0; i1 < markerList.length; i1++) {
radiusList[i1].setMap(null)
}
}
}
},
capacity () {
if (this.dataForm.radius > 0 && this.dataForm.radius <= 25) {
return 18
} else if (this.dataForm.radius > 25 && this.dataForm.radius <= 50) {
return 17
} else if (this.dataForm.radius > 50 && this.dataForm.radius <= 100) {
return 16
} else if (this.dataForm.radius > 100 && this.dataForm.radius <= 200) {
return 15
} else if (this.dataForm.radius > 200 && this.dataForm.radius <= 500) {
return 14
} else if (this.dataForm.radius > 500 && this.dataForm.radius <= 1000) {
return 13
} else if (this.dataForm.radius > 1000 && this.dataForm.radius <= 2000) {
return 12
} else if (this.dataForm.radius > 2000 && this.dataForm.radius <= 5000) {
return 11
}
}
},
components: {
AddressCheck
}
}
</script>

Loading…
Cancel
Save