Browse Source

详情修改

shibei_master
jiangyy 4 years ago
parent
commit
9b4e63a658
  1. 35
      src/views/modules/communityParty/regionalParty/activitys.vue
  2. 302
      src/views/modules/communityParty/regionalParty/activitysDetail.vue
  3. 64
      src/views/modules/communityParty/regionalParty/units.vue
  4. 271
      src/views/modules/communityParty/regionalParty/unitsDetail.vue
  5. 12
      src/views/modules/communityService/ninePlaces/inspect/inspect.vue
  6. 13
      src/views/modules/communityService/ninePlaces/places/places.vue
  7. 12
      src/views/modules/communityService/ninePlaces/team/team.vue

35
src/views/modules/communityParty/regionalParty/activitys.vue

@ -11,6 +11,7 @@
prop="unitId">
<el-select class="item_width_1"
v-model="formData.unitId"
size="small"
placeholder="全部"
clearable>
<el-option v-for="item in unitList"
@ -26,6 +27,7 @@
prop="serviceMatter">
<el-select class="item_width_2"
v-model="formData.serviceMatter"
size="small"
placeholder="请选择"
clearable>
<el-option v-for="item in serviceList"
@ -42,6 +44,7 @@
<el-form-item label="活动标题"
prop="title">
<el-input v-model="formData.title"
size="small"
class="item_width_1"
clearable
placeholder="请输入内容">
@ -52,6 +55,7 @@
<el-form-item label="活动时间"
prop="startTime">
<el-date-picker v-model="timeRange"
size="small"
type="daterange"
value-format="yyyy-MM-dd HH:mm:ss"
@change="handleTimeChange"
@ -63,9 +67,11 @@
</el-form-item>
<el-button style="margin-left:10px"
type="primary"
size="small"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:10px"
type="yellow"
size="small"
@click="resetSearch">重置</el-button>
</div>
</el-form>
@ -193,6 +199,16 @@
@dialogCancle="addFormCancle"
@dialogOk="addFormOk"></activitys-form>
</el-dialog>
<el-dialog :visible.sync="detailShow"
:close-on-click-modal="false"
:close-on-press-escape="false"
:title="'活动详情'"
width="950px"
top="5vh"
@closed="detailClosed">
<activitys-detail ref="ref_detail"
:serviceList="serviceList"></activitys-detail>
</el-dialog>
</div>
</template>
@ -200,6 +216,7 @@
<script>
import activitysForm from './activitysForm'
import activitysDetail from './activitysDetail'
import util from '@js/util.js';
import { requestPost } from "@/js/dai/request";
import { mapGetters } from 'vuex'
@ -255,6 +272,7 @@ export default {
//form
formShow: false,
formTitle: '新增单位',
detailShow: false,
files: "",
fileName: "",
@ -263,7 +281,7 @@ export default {
}
},
components: {
activitysForm
activitysForm, activitysDetail
},
async created () {
@ -355,11 +373,14 @@ export default {
this.formShow = false
},
detailClosed () {
this.detailShow = false
},
handleDetail (row) {
this.formTitle = '详情'
this.formShow = true
this.detailShow = true
this.$nextTick(() => {
this.$refs.ref_form.initForm('detail', row.id)
this.$refs.ref_detail.initForm(row)
})
},
@ -618,7 +639,7 @@ export default {
.div_search {
background: #ffffff;
border-radius: 4px;
padding: 35px 20px;
padding: 30px 20px 5px;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
}
@ -626,14 +647,14 @@ export default {
width: 260px;
}
.item_width_2 {
width: 520px;
width: 495px;
}
.div_table {
background: #ffffff;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
border-radius: 4px;
margin-top: 20px;
margin-top: 15px;
padding: 23px 30px 10px;
.table {

302
src/views/modules/communityParty/regionalParty/activitysDetail.vue

@ -0,0 +1,302 @@
<template>
<div>
<div>
<div>
<el-form ref="ref_form"
:inline="true"
:model="formData"
class="form">
<el-form-item label="服务事项"
label-width="150px"
prop="serviceMatterShow">
<span class="detail_span">{{formData.serviceMatterShow}}</span>
</el-form-item>
<el-form-item label="单位名称"
prop="unitId"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.unitName}}</span>
</el-form-item>
<el-form-item label="活动标题"
prop="title"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.title}}</span>
</el-form-item>
<el-form-item label="活动目标"
prop="target"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.target}}</span>
</el-form-item>
<el-form-item label="活动内容"
prop="target"
label-width="150px"
style="display: block">
<p class="text_p"
v-html="formData.content"></p>
</el-form-item>
<el-form-item label="服务人数"
style="display: block"
prop="peopleCount"
label-width="150px">
<span class="detail_span">{{formData.peopleCount}}</span>
</el-form-item>
<el-form-item label="活动时间"
style="display: block"
prop="activityTime"
label-width="150px">
<span class="detail_span">{{formData.activityTime}}</span>
</el-form-item>
<el-form-item label="活动地址"
prop="address"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.address}}</span>
</el-form-item>
<el-form-item label="活动坐标"
prop="longitude"
label-width="150px"
style="display: block">
<div style="width:500px">
<div id="app">
</div>
</div>
</el-form-item>
<el-form-item label="活动结果"
prop="result"
label-width="150px"
style="display: block">
<p class="text_p"
v-html="formData.result"></p>
</el-form-item>
</el-form>
</div>
</div>
</div>
</template>
<script>
import { Loading } from 'element-ui' // Loading
var map
var search
var markers
var infoWindowList
var geocoder //
let loading //
export default {
data () {
return {
formData: {},
}
},
components: {},
mounted () {
this.initMap()
},
methods: {
async initForm (row) {
this.startLoading()
for (let item of this.serviceList) {
if (row.serviceMatter === item.value) {
row.serviceMatterShow = item.label
}
}
this.formData = { ...row }
map.setCenter(new TMap.LatLng(this.formData.latitude, this.formData.longitude))
this.setMarker(this.formData.latitude, this.formData.longitude)
this.endLoading()
},
// init
initMap () {
//
var center = new window.TMap.LatLng(36.0722275, 120.38945519)
// map TMap.Map()
map = new window.TMap.Map(document.getElementById('app'), {
center: center, //
zoom: 17.2, //
pitch: 43.5, //
rotation: 45 //
})
search = new window.TMap.service.Search({ pageSize: 10 })
//
markers = new TMap.MultiMarker({
map: map,
geometries: []
})
infoWindowList = Array(10)
geocoder = new TMap.service.Geocoder(); //
//
map.on('panend', () => {
this.handleMoveCenter()
})
this.handleMoveCenter()
this.convert()
},
setMarker (lat, lng) {
markers.setGeometries([])
markers.add([
{
id: '4',
styleId: 'marker',
position: new TMap.LatLng(lat, lng),
properties: {
title: 'marker4'
}
}
])
},
handleSearchMap () {
infoWindowList.forEach((infoWindow) => {
infoWindow.close()
})
infoWindowList.length = 0
markers.setGeometries([])
//
search
.searchRectangle({
keyword: this.keyWords,
bounds: map.getBounds()
})
.then((result) => {
let { data } = result
if (Array.isArray(data) && data.length > 0) {
const {
location: { lat, lng }
} = data[0]
map.setCenter(new TMap.LatLng(lat, lng))
this.setMarker(lat, lng)
this.formData.latitude = lat
this.formData.longitude = lng
this.convert()
} else {
this.$message.error('未检索到相关位置坐标')
}
})
},
handleMoveCenter () {
//
const center = map.getCenter()
const lat = center.getLat()
const lng = center.getLng()
this.formData.latitude = lat
this.formData.longitude = lng
this.setMarker(lat, lng)
this.convert(lat, lng)
},
convert (lat, lng) {
markers.setGeometries([]);
// var input = document.getElementById('location').value.split(',');
let location
if (lat && lng) {
location = new TMap.LatLng(lat, lng);
} else {
location = new TMap.LatLng(this.formData.latitude, this.formData.longitude);
}
// map.setCenter(location);
markers.updateGeometries([
{
id: 'main', //
position: location,
},
]);
geocoder
.getAddress({ location: location }) //
.then((result) => {
// this.formData.address = result.result.address
//
});
},
//
startLoading () {
loading = Loading.service({
lock: true, //
text: '正在加载……', //
background: 'rgba(0,0,0,.7)' //
})
},
//
endLoading () {
// clearTimeout(timer);
if (loading) {
loading.close()
}
}
},
computed: {},
props: {
serviceList: {
type: Array,
default: []
},
}
}
</script>
<style lang="scss" scoped>
.detail_span {
width: 500px;
font-weight: bold;
text-align: left;
margin: 0 0;
font-size: 16px;
}
.text_p {
margin: 0 0;
border: 3px;
> p {
margin: 0 0;
}
}
.div_map {
position: relative;
}
</style>

64
src/views/modules/communityParty/regionalParty/units.vue

@ -12,6 +12,7 @@
<el-input v-model="formData.unitName"
class="item_width_1"
clearable
size="small"
placeholder="请输入内容">
</el-input>
@ -21,6 +22,7 @@
<el-select class="item_width_2"
v-model="formData.serviceMatter"
placeholder="请选择"
size="small"
clearable>
<el-option v-for="item in serviceList"
:key="item.value"
@ -37,6 +39,7 @@
<el-select class="item_width_1"
v-model="formData.type"
placeholder="请选择"
size="small"
clearable>
<el-option v-for="item in typeList"
:key="item.value"
@ -50,6 +53,7 @@
prop="contact">
<el-input v-model="formData.contact"
class="item_width_1"
size="small"
clearable
placeholder="请输入内容">
</el-input>
@ -60,6 +64,7 @@
prop="contactMobile">
<el-input v-model="formData.contactMobile"
class="item_width_1"
size="small"
clearable
placeholder="请输入内容">
</el-input>
@ -68,9 +73,11 @@
<el-button style="margin-left:10px"
type="primary"
size="small"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:10px"
type="yellow"
size="small"
@click="resetSearch">重置</el-button>
</div>
</el-form>
@ -81,6 +88,10 @@
type="green"
size="small"
@click="handleAdd">新增</el-button>
<el-button style="float:left"
type="yellow"
size="small"
@click="handleExport">导出</el-button>
<el-upload ref="upload"
:multiple='false'
:show-file-list='false'
@ -94,11 +105,6 @@
size="small"
type="red">导入</el-button>
<el-button style="float:left"
type="yellow"
size="small"
@click="handleExport">导出</el-button>
</el-upload>
</div>
@ -145,7 +151,7 @@
header-align="center"
align="center"
label="联系人"
width="100">
width="80">
</el-table-column>
<el-table-column prop="contactMobile"
header-align="center"
@ -222,6 +228,15 @@
@dialogCancle="addFormCancle"
@dialogOk="addFormOk"></units-form>
</el-dialog>
<el-dialog :visible.sync="detailShow"
:close-on-click-modal="false"
:close-on-press-escape="false"
:title="'单位详情'"
width="950px"
top="5vh"
@closed="detailClosed">
<units-detail ref="ref_detail"></units-detail>
</el-dialog>
</div>
</template>
@ -229,6 +244,7 @@
<script>
import unitsForm from './unitsForm'
import unitsDetail from './unitsDetail'
import { requestPost } from "@/js/dai/request";
import { mapGetters } from 'vuex'
@ -268,7 +284,6 @@ export default {
unitId: '',
formData: {
unitName: '',
serviceMatter: '',
type: '',
@ -281,6 +296,7 @@ export default {
//form
formShow: false,
formTitle: '新增单位',
detailShow: false,
files: "",
fileName: "",
@ -289,7 +305,7 @@ export default {
}
},
components: {
unitsForm
unitsForm, unitsDetail
},
async created () {
@ -367,14 +383,7 @@ export default {
if (code === 0) {
this.total = data.total
this.tableData = data.list
// this.tableData.forEach(item => {
// item.serviceMatterShow = ''
// if (item.serviceMatterList.length > 0) {
// item.serviceMatterShow = item.serviceMatterList.join('')
// }
// });
} else {
this.$message.error(msg)
}
@ -387,18 +396,20 @@ export default {
this.$refs.ref_form.resetData()
this.formShow = false
},
detailClosed () {
this.detailShow = false
},
handleDetail (row) {
this.formTitle = '详情'
this.formShow = true
this.detailShow = true
this.$nextTick(() => {
this.$refs.ref_form.initForm('detail', row.id)
this.$refs.ref_detail.initForm(row)
})
},
handleAdd () {
this.formTitle = '新增'
this.formShow = true
this.formShow = 'edit'
this.$nextTick(() => {
this.$refs.ref_form.initForm('add', null)
})
@ -476,13 +487,10 @@ export default {
async handleExport () {
let title = '联建单位列表'
const url = "/partyunit/export"
const url = "/heart/icpartyunit/export"
let params = {
ownerName: this.ownerName,
ownerPhone: this.ownerPhone,
level: this.agencyObj.level,
id: this.agencyObj.id
agencyId: this.agencyId,
...this.formData
}
app.ajax.exportFilePost(
@ -557,7 +565,7 @@ export default {
//
this.$refs['upload'].clearFiles()
var url = '/partyunit/import'
var url = '/heart/icpartyunit/import'
let fileFormData = new FormData();
fileFormData.append('file', this.files);//filenamefiletest.zip
@ -631,7 +639,7 @@ export default {
.div_search {
background: #ffffff;
border-radius: 4px;
padding: 35px 20px;
padding: 30px 20px 5px;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
}
@ -646,7 +654,7 @@ export default {
background: #ffffff;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
border-radius: 4px;
margin-top: 20px;
margin-top: 15px;
padding: 23px 30px 10px;
.table {

271
src/views/modules/communityParty/regionalParty/unitsDetail.vue

@ -0,0 +1,271 @@
<template>
<div>
<el-form ref="ref_form"
:inline="true"
:model="formData"
class="form">
<el-form-item label="单位名称:"
prop="unitName"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.unitName}}</span>
</el-form-item>
<el-form-item label="分类:"
prop="type"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.type}}</span>
</el-form-item>
<el-form-item label="服务事项:"
prop="serviceMatterList"
label-width="150px"
style="display: block">
<p class="detail_span"
v-for="(item,index) in formData.serviceMatterList"
:key="index">{{item}}</p>
</el-form-item>
<el-form-item label="联系人:"
prop="contact"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.contact}}</span>
</el-form-item>
<el-form-item label="联系电话:"
prop="contactMobile"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.contactMobile}}</span>
</el-form-item>
<el-form-item label="在职党员:"
style="display: block"
prop="memberCount"
label-width="150px">
<span class="detail_span">{{formData.memberCount}}</span>
</el-form-item>
<el-form-item label="备注:"
prop="remark"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.remark?formData.remark:'无'}}</span>
</el-form-item>
<el-form-item label="地理位置:"
prop="address"
label-width="150px"
style="display: block">
<span class="detail_span">{{formData.address}}</span>
</el-form-item>
<el-form-item label="位置坐标:"
prop="longitude"
label-width="150px"
style="display: block">
<div style="width:500px">
<div id="app">
</div>
</div>
</el-form-item>
</el-form>
</div>
</template>
<script>
import { Loading } from 'element-ui' // Loading
var map
var search
var markers
var infoWindowList
var geocoder //
let loading //
export default {
data () {
return {
formData: {},
}
},
components: {},
mounted () {
this.initMap()
},
methods: {
async initForm (row) {
this.startLoading()
this.formData = { ...row }
map.setCenter(new TMap.LatLng(this.formData.latitude, this.formData.longitude))
this.setMarker(this.formData.latitude, this.formData.longitude)
this.endLoading()
},
// init
initMap () {
//
var center = new window.TMap.LatLng(36.0722275, 120.38945519)
// map TMap.Map()
map = new window.TMap.Map(document.getElementById('app'), {
center: center, //
zoom: 17.2, //
pitch: 43.5, //
rotation: 45 //
})
search = new window.TMap.service.Search({ pageSize: 10 })
//
markers = new TMap.MultiMarker({
map: map,
geometries: []
})
infoWindowList = Array(10)
geocoder = new TMap.service.Geocoder(); //
//
map.on('panend', () => {
this.handleMoveCenter()
})
this.handleMoveCenter()
this.convert()
},
setMarker (lat, lng) {
markers.setGeometries([])
markers.add([
{
id: '4',
styleId: 'marker',
position: new TMap.LatLng(lat, lng),
properties: {
title: 'marker4'
}
}
])
},
handleSearchMap () {
infoWindowList.forEach((infoWindow) => {
infoWindow.close()
})
infoWindowList.length = 0
markers.setGeometries([])
//
search
.searchRectangle({
keyword: this.keyWords,
bounds: map.getBounds()
})
.then((result) => {
let { data } = result
if (Array.isArray(data) && data.length > 0) {
const {
location: { lat, lng }
} = data[0]
map.setCenter(new TMap.LatLng(lat, lng))
this.setMarker(lat, lng)
this.formData.latitude = lat
this.formData.longitude = lng
this.convert()
} else {
this.$message.error('未检索到相关位置坐标')
}
})
},
handleMoveCenter () {
//
const center = map.getCenter()
const lat = center.getLat()
const lng = center.getLng()
this.formData.latitude = lat
this.formData.longitude = lng
this.setMarker(lat, lng)
this.convert(lat, lng)
},
convert (lat, lng) {
markers.setGeometries([]);
// var input = document.getElementById('location').value.split(',');
let location
if (lat && lng) {
location = new TMap.LatLng(lat, lng);
} else {
location = new TMap.LatLng(this.formData.latitude, this.formData.longitude);
}
// map.setCenter(location);
markers.updateGeometries([
{
id: 'main', //
position: location,
},
]);
geocoder
.getAddress({ location: location }) //
.then((result) => {
// this.formData.address = result.result.address
//
});
},
//
startLoading () {
loading = Loading.service({
lock: true, //
text: '正在加载……', //
background: 'rgba(0,0,0,.7)' //
})
},
//
endLoading () {
// clearTimeout(timer);
if (loading) {
loading.close()
}
}
},
computed: {
},
props: {
}
}
</script>
<style scoped>
.detail_span {
width: 500px;
font-weight: bold;
text-align: left;
margin: 0 0;
font-size: 16px;
}
.div_map {
position: relative;
}
.form {
margin-top: 30px;
}
</style>

12
src/views/modules/communityService/ninePlaces/inspect/inspect.vue

@ -10,6 +10,7 @@
<el-form-item label="场所名称"
prop="placeOrgName">
<el-input v-model="formData.placeOrgName"
size="small"
class="item_width_1"
clearable
placeholder="请输入九小场所名称">
@ -21,6 +22,7 @@
prop="firstResult">
<el-select class="item_width_1"
v-model="formData.firstResult"
size="small"
placeholder="请选择"
clearable>
<el-option v-for="item in resultList"
@ -53,6 +55,7 @@
prop="ninePlaceVal">
<el-select class="item_width_1"
v-model="formData.ninePlaceVal"
size="small"
placeholder="请选择"
clearable>
<el-option v-for="item in placeTypeList"
@ -68,6 +71,7 @@
prop="finalResult">
<el-select class="item_width_1"
v-model="formData.finalResult"
size="small"
placeholder="请选择"
clearable>
<el-option v-for="item in resultList"
@ -78,10 +82,12 @@
</el-select>
</el-form-item>
<el-button style="margin-left:10px"
<el-button style="margin-left:30px"
size="small"
type="primary"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:10px"
size="small"
type="yellow"
@click="resetSearch">重置</el-button>
</div>
@ -544,7 +550,7 @@ export default {
.div_search {
background: #ffffff;
border-radius: 4px;
padding: 35px 20px;
padding: 30px 20px 5px;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
}
@ -556,7 +562,7 @@ export default {
background: #ffffff;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
border-radius: 4px;
margin-top: 20px;
margin-top: 15px;
padding: 23px 30px 10px;
.table {

13
src/views/modules/communityService/ninePlaces/places/places.vue

@ -10,6 +10,7 @@
<el-form-item label="场所名称"
prop="placeOrgName">
<el-input v-model="formData.placeOrgName"
size="small"
class="item_width_1"
clearable
placeholder="请输入九小场所名称">
@ -20,6 +21,7 @@
<el-form-item label="联系电话"
prop="mobile">
<el-input v-model="formData.mobile"
size="small"
class="item_width_1"
clearable
placeholder="请输入电话">
@ -31,6 +33,7 @@
prop="gridId">
<el-select class="item_width_1"
v-model="formData.gridId"
size="small"
placeholder="全部"
clearable>
<el-option v-for="item in gridList"
@ -47,6 +50,7 @@
<el-form-item label="规模"
prop="scale">
<el-select class="item_width_1"
size="small"
v-model="formData.scale"
placeholder="请选择"
clearable>
@ -61,6 +65,7 @@
<el-form-item label="场所类型"
prop="ninePlaceVal">
<el-select class="item_width_1"
size="small"
v-model="formData.ninePlaceVal"
placeholder="请选择"
clearable>
@ -73,10 +78,12 @@
</el-form-item>
<el-button style="margin-left:10px"
<el-button style="margin-left:30px"
size="small"
type="primary"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:10px"
size="small"
type="yellow"
@click="resetSearch">重置</el-button>
</div>
@ -479,7 +486,7 @@ export default {
.div_search {
background: #ffffff;
border-radius: 4px;
padding: 35px 20px;
padding: 30px 20px 5px;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
}
@ -491,7 +498,7 @@ export default {
background: #ffffff;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
border-radius: 4px;
margin-top: 20px;
margin-top: 15px;
padding: 23px 30px 10px;
.table {

12
src/views/modules/communityService/ninePlaces/team/team.vue

@ -10,6 +10,7 @@
<el-form-item label="负责人"
prop="personInCharge">
<el-input v-model="formData.personInCharge"
size="small"
class="item_width_1"
clearable
placeholder="请输入负责人姓名">
@ -20,6 +21,7 @@
<el-form-item label="联系电话"
prop="mobile">
<el-input v-model="formData.mobile"
size="small"
class="item_width_1"
clearable
placeholder="请输入电话">
@ -32,6 +34,7 @@
prop="gridId">
<el-select class="item_width_1"
v-model="formData.gridId"
size="small"
placeholder="全部"
clearable>
<el-option v-for="item in gridList"
@ -46,6 +49,7 @@
<el-form-item label="场所类型"
prop="ninePlaceVal">
<el-select class="item_width_1"
size="small"
v-model="formData.ninePlaceVal"
placeholder="请选择"
clearable>
@ -58,10 +62,12 @@
</el-form-item>
<el-button style="margin-left:10px"
<el-button style="margin-left:30px"
size="small"
type="primary"
@click="handleSearch">查询</el-button>
<el-button style="margin-left:10px"
size="small"
type="yellow"
@click="resetSearch">重置</el-button>
</div>
@ -454,7 +460,7 @@ export default {
.div_search {
background: #ffffff;
border-radius: 4px;
padding: 35px 20px;
padding: 30px 20px 5px;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
}
@ -466,7 +472,7 @@ export default {
background: #ffffff;
box-shadow: 0px 2px 12px 0px rgba(0, 0, 0, 0.1);
border-radius: 4px;
margin-top: 20px;
margin-top: 15px;
padding: 23px 30px 10px;
.table {

Loading…
Cancel
Save