Browse Source

联调

V1.0
mk 2 years ago
parent
commit
ed70fc853a
  1. 77
      src/views/modules/satisfaction/communitySelfInsp/followUpDetail.vue
  2. 116
      src/views/modules/satisfaction/communitySelfInsp/formList.vue
  3. 21
      src/views/modules/satisfaction/communitySelfInsp/index.vue

77
src/views/modules/satisfaction/communitySelfInsp/followUpDetail.vue

@ -1,28 +1,51 @@
<template> <template>
<div class='g-main dialog-h-content'> <div class='g-main dialog-h-content'>
<h3>海伦路路社区8月份满意度调查</h3> <h3>{{agencyName}}{{period.substr(5,2)}}月份满意度调查</h3>
<p>尊敬的居民朋友</p> <p>尊敬的居民朋友</p>
<p style="text-indent: 2em; ">为了更好地推进社区工作为您提供更全面优质的服务请您根据真实情况填写此表我们将认真对待您提出的问题并承诺对您提供的信息保密感谢您的配合</p> <p style="text-indent: 2em; ">为了更好地推进社区工作为您提供更全面优质的服务请您根据真实情况填写此表我们将认真对待您提出的问题并承诺对您提供的信息保密感谢您的配合</p>
<div class="card" v-for="(item, index) in formList" :key="index"> <div class="card" v-for="(item, index) in formList" :key="index">
<p>{{ index + 1 }}您对本社区的{{ item.label }}是否满意</p> <p>{{ index + 1 }}您对本社区的{{ item.label }}是否满意</p>
<section class="f-hflex"> <section class="f-hflex">
<el-radio class="f-bot16" v-model.trim="form[item.pkey]" label="veryGood">满意</el-radio> <el-radio class="f-bot16" v-model.trim="form[item.pkey]" disabled label="veryGood">满意</el-radio>
<el-radio class="f-bot16" v-model.trim="form[item.pkey]" label="good">基本满意</el-radio> <el-radio class="f-bot16" v-model.trim="form[item.pkey]" disabled label="good">基本满意</el-radio>
<el-radio class="f-bot16" v-model.trim="form[item.pkey]" label="bad">不满意</el-radio> <el-radio class="f-bot16" v-model.trim="form[item.pkey]" disabled label="bad">不满意</el-radio>
</section> </section>
<p>{{ index + 1 }}.1您具体对那些方面不满意</p> <p>{{ index + 1 }}.1您具体对那些方面不满意</p>
<section class="f-hflex" v-for="(itemK, indexK) in item.children"> <section class="f-hflex" v-for="(itemK, indexK) in item.children">
<el-radio class="f-bot16" v-model.trim="form[item.value]" :label="itemK.value" <el-radio class="f-bot16" v-model.trim="form[item.value]" :label="itemK.value" disabled
@change="caca">{{ itemK.label }}</el-radio> >{{ itemK.label }}</el-radio>
<el-input v-if="indexK == item.children.length -1 && form[item.pkey] == 'bad'" placeholder="请填写不满意原因" v-model.trim="form[item.reason]"></el-input> <el-input v-if="indexK == item.children.length -1 && form[item.pkey] == 'bad'" disabled placeholder="请填写不满意原因" v-model.trim="form[item.reason]"></el-input>
</section> </section>
</div> </div>
<p>8姓名{{form.reporterName}}</p>
<p>9电话{{form.reporterMobile}}</p>
<p>10姓名{{form.reporterName}}</p>
<p>11您是否接受回访</p>
<section class="f-hflex">
<el-radio class="f-bot16" v-model="form.followUpStatus" disabled :label="-2">未知</el-radio>
<el-radio class="f-bot16" v-model="form.followUpStatus" disabled :label="-1">不接受回访</el-radio>
<el-radio class="f-bot16" v-model="form.followUpStatus" disabled :label="0">接受回访/待回访</el-radio>
<el-radio class="f-bot16" v-model="form.followUpStatus" disabled :label="1">已回访</el-radio>
</section>
<p v-if="form.followUpStatus === 0">12请选择合适您的回访方式</p>
<section class="f-hflex" v-if="form.followUpStatus === 0">
<el-radio class="f-bot16" v-model="form.expectFollowUpWay" disabled label="0">未知</el-radio>
<el-radio class="f-bot16" v-model="form.expectFollowUpWay" disabled label="1">电话回访</el-radio>
<el-radio class="f-bot16" v-model="form.expectFollowUpWay" disabled label="2">上门回访</el-radio>
</section>
<p >请填写您的家庭住址</p>
<el-input v-model="form.resideAddress" disabled></el-input>
<el-row type="flex" justify="end" class="f-top12">
<el-col :span="2">
<el-button @click="handleClose"> 取消</el-button>
</el-col>
</el-row>
</div> </div>
</template> </template>
<script> <script>
import { requestGet } from "@/js/dai/request";
export default { export default {
// //
data() { data() {
@ -64,13 +87,23 @@ export default {
socialAssistanceReason: '', socialAssistanceReason: '',
oldPeopleProvideReason: '', oldPeopleProvideReason: '',
medicalReason: '', medicalReason: '',
}
//
reporterName:'',
reporterMobile:'',
followUpStatus: null,
expectFollowUpWay:'',
resideAddress:'',
},
agencyName:this.$store.state.user.agencyName,
}; };
}, },
// //
async created() { async created() {
console.log(this.period);
await this.getDicts() await this.getDicts()
await this.handleArr() await this.handleArr()
await this.getInspResult()
}, },
// //
methods: { methods: {
@ -96,9 +129,6 @@ export default {
this.formList = transformArray(this.dicts.satisfaction_ns_aspect); this.formList = transformArray(this.dicts.satisfaction_ns_aspect);
console.log(this.formList); console.log(this.formList);
}, },
caca(val){
console.log(val);
},
async getDicts() { async getDicts() {
try { try {
@ -121,6 +151,19 @@ export default {
console.log("获取字典失败: ", error); console.log("获取字典失败: ", error);
} }
}, },
async getInspResult(){
const url = `/governance/satisfaction/communitySelfInsp/inspResult/detail/${this.inspResultId}`
const {data,code,msg} = await requestGet(url)
if(code == 0){
this.form = {...data.reporter,...data.satisfaction}
console.log(this.form);
}else{
this.$message.error(msg)
}
},
handleClose(){
this.$emit('handleClose')
}
}, },
// //
components: {}, components: {},
@ -128,6 +171,16 @@ export default {
computed: {}, computed: {},
// //
watch: {}, watch: {},
props:{
inspResultId:{
type:String,
default:''
},
period:{
type:String,
default:''
}
}
} }
</script> </script>

116
src/views/modules/satisfaction/communitySelfInsp/formList.vue

@ -17,42 +17,67 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-button size="small" type="primary "
@click="handleSearch">查询</el-button>
</el-form> </el-form>
<el-button type="primary" @click="xinzneg" >查看</el-button> <!-- <el-button type="primary" @click="xinzneg" >查看</el-button>
<el-button type="primary" @click="bianji" >回访记录</el-button> <el-button type="primary" @click="bianji" >回访记录</el-button> -->
<el-table class="m-table-item" :data="tableData" style="width: 100%"> <el-table class="m-table-item" :data="tableData" style="width: 100%">
<el-table-column label="序号" header-align="center" align="center" type="index" width="50"></el-table-column> <el-table-column label="序号" header-align="center" align="center" type="index" width="50"></el-table-column>
<el-table-column label="填写时间" prop="createdTime" header-align="center" align="center" type="index" <el-table-column label="填写时间" prop="createdTime" header-align="center" align="center" type="index"
width="100"></el-table-column> width="100"></el-table-column>
<el-table-column label="姓名" prop="reporterName" header-align="center" align="center" type="index" <el-table-column label="姓名" prop="reporterName" header-align="center" align="center" width="80" show-overflow-tooltip>
width="50"></el-table-column> </el-table-column>
<el-table-column label="联系电话" prop="reporterMobile" header-align="center" align="center" type="index" <el-table-column label="联系电话" prop="reporterMobile" header-align="center" align="center"
width="80"></el-table-column> width="120"></el-table-column>
<el-table-column label="回访方式" prop="followUpWay" header-align="center" align="center" type="index" <el-table-column label="回访方式" prop="followUpWay" header-align="center" align="center"
width="100"></el-table-column> width="100">
<el-table-column label="文化设施" prop="evaCulturalFacility" header-align="center" align="center" type="index" <template slot-scope="scope">
width="80"></el-table-column> {{scope.row.followUpWay?scope.row.followUpWay =='1'?'电话回访':scope.row.followUpWay == '2'?'上门回访':'':''}}
<el-table-column label="体育设施" prop="evaSportsFacility" header-align="center" align="center" type="index" </template>
width="80"></el-table-column> </el-table-column>
<el-table-column label="生态环境" prop="evaEcologicalEnv" header-align="center" align="center" type="index" <el-table-column label="文化设施" prop="evaCulturalFacility" header-align="center" align="center" width="80">
width="80"></el-table-column> <template slot-scope="scope">
<el-table-column label="社会治安" prop="evaSocialSecurity" header-align="center" align="center" type="index" {{ satisfactionCategory(scope.row, 'evaCulturalFacility') }}
width="80"></el-table-column> </template>
<el-table-column label="社会救助" prop="evaSocialAssistance" header-align="center" align="center" type="index" </el-table-column>
width="80"></el-table-column> <el-table-column label="体育设施" prop="evaSportsFacility" header-align="center" align="center" width="80">
<el-table-column label="老有所养" prop="evaOldPeopleProvide" header-align="center" align="center" type="index" <template slot-scope="scope">
width="80"></el-table-column> {{ satisfactionCategory(scope.row, 'evaSportsFacility') }}
<el-table-column label="基础教育" prop="evaBasicEducation" header-align="center" align="center" type="index" </template></el-table-column>
width="80"></el-table-column> <el-table-column label="生态环境" prop="evaEcologicalEnv" header-align="center" align="center" width="80"> <template
<el-table-column label="病有所医" prop="evaMedical" header-align="center" align="center" type="index" slot-scope="scope">
width="80"></el-table-column> {{ satisfactionCategory(scope.row, 'evaEcologicalEnv') }}
<el-table-column label="回访状态" prop="followUpStatus" header-align="center" align="center" type="index" </template> </el-table-column>
width="80"></el-table-column> <el-table-column label="社会治安" prop="evaSocialSecurity" header-align="center" align="center" width="80">
<template slot-scope="scope">
{{ satisfactionCategory(scope.row, 'evaSocialSecurity') }}
</template> </el-table-column>
<el-table-column label="社会救助" prop="evaSocialAssistance" header-align="center" align="center" width="80">
<template slot-scope="scope">
{{ satisfactionCategory(scope.row, 'evaSocialAssistance') }}
</template> </el-table-column>
<el-table-column label="老有所养" prop="evaOldPeopleProvide" header-align="center" align="center" width="80">
<template slot-scope="scope">
{{ satisfactionCategory(scope.row, 'evaOldPeopleProvide') }}
</template> </el-table-column>
<el-table-column label="基础教育" prop="evaBasicEducation" header-align="center" align="center" width="80">
<template slot-scope="scope">
{{ satisfactionCategory(scope.row, 'evaBasicEducation') }}
</template> </el-table-column>
<el-table-column label="病有所医" prop="evaMedical" header-align="center" align="center" width="80"> <template
slot-scope="scope">
{{ satisfactionCategory(scope.row, 'evaMedical') }}
</template> </el-table-column>
<el-table-column label="回访状态" prop="followUpStatus" header-align="center" align="center" show-overflow-tooltip width="80"> <template
slot-scope="scope" >
{{ scope.row.followUpStatus!= null?scope.row.followUpStatus == -1 ?'不接受回访':scope.row.followUpStatus == 1 ?'已回访':'接受回访/未回访':'--' }}
</template> </el-table-column>
<el-table-column fixed="right" label="操作" align="center" width="220"> <el-table-column fixed="right" label="操作" align="center" width="220">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button @click="handleDetail(scope.row)" type="text" size="small">查看</el-button> <el-button @click="handleDetail(scope.row)" type="text" size="small">查看</el-button>
<el-button @click="handleEdit(scope.row)" type="text" size="small">回访记录</el-button> <el-button @click="handelFollowUpList(scope.row)" type="text" size="small">回访记录</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@ -88,22 +113,28 @@ export default {
// //
created() { }, created() { },
async mounted() { async mounted() {
await this.getDicts()
await this.getTableData()
if (this.satisfactionCategoryStr) { if (this.satisfactionCategoryStr) {
this.formData.satisfactionCategory = this.satisfactionCategoryStr this.formData.satisfactionCategory = this.satisfactionCategoryStr
this.formData.inspRecordId = this.inspRecordId this.formData.inspRecordId = this.inspRecordId
console.log(this.formData.satisfactionCategory); this.formData.satisfactionLevel = this.seriesName
} }
await this.getDicts()
await this.getTableData()
}, },
// //
methods: { methods: {
xinzneg(){ handleDetail(row) {
this.$emit('handelDetail',true) this.$emit('handelDetail', row.id)
}, },
bianji(){ handelFollowUpList() {
this.$emit('handelFollowUpList', true) this.$emit('handelFollowUpList', true)
}, },
satisfactionCategory(row, name) {
if (row[name]) {
let text = this.dicts.satisfaction_level.find(item => item.value === row[name]).label
return text
}
},
async getDicts() { async getDicts() {
try { try {
const requests = [ const requests = [
@ -138,21 +169,22 @@ export default {
this.pageNo = val; this.pageNo = val;
this.getTableData(); this.getTableData();
}, },
handleSearch(){
this.getTableData()
},
async getTableData() { async getTableData() {
console.log(this.formData); let params = {
var params = {
...this.formData, ...this.formData,
pageNo: this.pageNo, pageNo: this.pageNo,
pageSize: this.pageSize, pageSize: this.pageSize,
}; };
console.log(params);
let url = '/governance/satisfaction/communitySelfInsp/inspResult/list' let url = '/governance/satisfaction/communitySelfInsp/inspResult/list'
const { data, code, msg } = await requestGet(url, params) const { data, code, msg } = await requestGet(url, params)
if (code == 0) { if (code == 0) {
this.tableData = data.data; this.tableData = data.list;
this.total = data.total; this.total = data.total;
} else { } else {
console.log(err); this.$message.error(msg)
} }
}, },
}, },
@ -168,6 +200,14 @@ export default {
period: { period: {
type: String, type: String,
default: '' default: ''
},
inspRecordId: {
type: String,
default: ''
},
seriesName: {
type: String,
default: ''
} }
}, },
// //

21
src/views/modules/satisfaction/communitySelfInsp/index.vue

@ -57,10 +57,10 @@
:close-on-press-escape="false" title="社区自查" :modal-append-to-body="false" width="820px" top="5vh" :close-on-press-escape="false" title="社区自查" :modal-append-to-body="false" width="820px" top="5vh"
class="dialog-h" @closed="showFormList = false"> class="dialog-h" @closed="showFormList = false">
<form-list ref="ref_add_form" @handleClose="handleClose" :satisfactionCategoryStr="satisfactionCategoryStr" <form-list ref="ref_add_form" @handleClose="handleClose" :satisfactionCategoryStr="satisfactionCategoryStr"
@handelDetail="handelDetail" @handelFollowUpList="handelFollowUpList" :period="formData.period" :inspRecordId="formData.inspRecordId"></form-list> @handelDetail="handelDetail" @handelFollowUpList="handelFollowUpList" :period="formData.period" :seriesName="seriesName" :inspRecordId="formData.inspRecordId"></form-list>
<el-dialog width="920px" class="dialog-h" title="社区自查报告详情" :close-on-click-modal="false" <el-dialog width="920px" class="dialog-h" title="社区自查报告详情" :close-on-click-modal="false"
v-if="showFollowUpDetail" :visible.sync="showFollowUpDetail" append-to-body> v-if="showFollowUpDetail" :visible.sync="showFollowUpDetail" append-to-body>
<follow-Detail></follow-Detail> <follow-Detail :period="formData.period" :inspResultId="inspResultId" @handleClose="handleClose"></follow-Detail>
</el-dialog> </el-dialog>
<el-dialog width="820px" class="dialog-h" title="回访记录" :close-on-click-modal="false" v-if="showFollowUpList" <el-dialog width="820px" class="dialog-h" title="回访记录" :close-on-click-modal="false" v-if="showFollowUpList"
:visible.sync="showFollowUpList" append-to-body> :visible.sync="showFollowUpList" append-to-body>
@ -210,7 +210,9 @@ export default {
qrCodeImgUrl: '',// qrCodeImgUrl: '',//
questionnaireUrl: '', questionnaireUrl: '',
synthesisScore: '', synthesisScore: '',
personQty: '' personQty: '',
inspResultId:""
}; };
}, },
@ -263,8 +265,9 @@ export default {
} }
}, },
// ------------------------------------------------------------------------------ // ------------------------------------------------------------------------------
handelDetail() { handelDetail(id) {
this.showFollowUpDetail = true; this.showFollowUpDetail = true;
this.inspResultId = id
}, },
handelFollowUpList() { handelFollowUpList() {
this.showFollowUpList = true; this.showFollowUpList = true;
@ -287,10 +290,7 @@ export default {
this.myChart.setOption(this.option); this.myChart.setOption(this.option);
let than = this; let than = this;
this.myChart.on("click", function (params) { this.myChart.on("click", function (params) {
// console.log(params.name); // than.handelClickChart(params.name,params.seriesName);
// console.log(params.data); //
// console.log(params.seriesName); //
than.handelClickChart(params.name);
}); });
window.addEventListener("resize", this.handleWindowResize); window.addEventListener("resize", this.handleWindowResize);
}, },
@ -299,15 +299,16 @@ export default {
this.myChart.resize(); this.myChart.resize();
} }
}, },
handelClickChart(name) { handelClickChart(name,seriesName) {
this.showFormList = true; this.showFormList = true;
this.satisfactionCategoryStr = this.dicts.satisfaction_category.filter( this.satisfactionCategoryStr = this.dicts.satisfaction_category.filter(
(item) => item.label == name (item) => item.label == name
)[0].value; )[0].value;
console.log(this.satisfactionCategoryStr); this.seriesName = seriesName == '满意'?'veryGood':seriesName == '基本满意'?'good':'bad';
}, },
handleClose() { handleClose() {
this.showFormList = false; this.showFormList = false;
this.showFollowUpDetail = false
}, },
// //
handleSearch(val) { handleSearch(val) {

Loading…
Cancel
Save