Browse Source

Merge branch 'feature/dev_point_manage' into dev

test
wanggongfeng 3 years ago
parent
commit
bed0b382f8
  1. 6
      src/views/modules/plugins/point/icpointnucleicmonitoring-add-or-update.vue
  2. 63
      src/views/modules/plugins/point/icpointnucleicmonitoring.vue
  3. 27
      src/views/modules/plugins/point/icpointvaccinesinoculation-add-or-update.vue
  4. 80
      src/views/modules/plugins/point/icpointvaccinesinoculation.vue

6
src/views/modules/plugins/point/icpointnucleicmonitoring-add-or-update.vue

@ -224,7 +224,7 @@ export default {
};
},
},
mounted() {
created() {
this.getFormInfo();
},
props: {
@ -247,7 +247,7 @@ export default {
},
// init
initMap() {
let { latitude, longitude } = this.dataForm;
let { latitude, longitude } = this.$store.state.user;
//
if (!latitude || latitude == "" || latitude == "0") {
latitude = 39.9088810666821;
@ -371,7 +371,7 @@ export default {
this.$http
.post(`/gov/org/agency/communityListByCustomerId`)
.then(({ data: res }) => {
if (tMapres.code !== 0) {
if (res.code !== 0) {
return this.$message.error(res.msg);
}
this.organizationList = res.data;

63
src/views/modules/plugins/point/icpointnucleicmonitoring.vue

@ -112,6 +112,8 @@
v-loading="dataListLoading"
:data="dataList"
border
:row-key="row => { return row.id.toString() }"
:header-cell-style="{ background: '#2195FE', color: '#FFFFFF' }"
style="width: 100%; height: 564px"
><el-table-column
label="序号"
@ -152,8 +154,7 @@
show-overflow-tooltip
></el-table-column>
<el-table-column
:label="$t('handle')"
fixed="right"
label="操作"
header-align="center"
align="center"
width="150"
@ -162,31 +163,37 @@
<el-button
type="text"
size="small"
class="div-table-button--detail"
@click="addOrUpdateHandle(scope.row.id, '查看')"
>{{ "查看" }}</el-button
>
<el-button
type="text"
size="small"
class="div-table-button--edit"
@click="addOrUpdateHandle(scope.row.id, '修改')"
>{{ scope.row.longitude === null ? "待完善" : "修改" }}</el-button
>
<el-button
type="text"
size="small"
class="div-table-button--delete--noline"
@click="handleDelete(scope.row.id)"
>{{ $t("delete") }}</el-button
>
</template>
</el-table-column>
</el-table>
<el-pagination @size-change="pageSizeChangeHandle"
@current-change="pageCurrentChangeHandle"
:page-sizes="[20, 50, 100, 200]"
:page-size="limit"
layout="sizes, prev, pager, next, total"
:total="total">
</el-pagination>
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page.sync="pageNo"
:page-sizes="[20, 50, 100, 200]"
:page-size="pageSize"
layout="sizes, prev, pager, next, total"
:total="total"
>
</el-pagination>
</div>
<!-- 弹窗, 新增 / 修改 -->
<el-dialog
@ -236,13 +243,6 @@ export default {
mixins: [mixinViewModule],
data() {
return {
mixinViewModuleOptions: {
getDataListURL: "/epmetuser/icPointNucleicMonitoring/page",
getDataListIsPage: true,
deleteURL: "/epmetuser/icPointNucleicMonitoring",
deleteIsBatch: true,
// exportURL: '/epmetuser/icPointNucleicMonitoring/export'
},
dataForm: {
name: "",
mobile: "",
@ -254,6 +254,10 @@ export default {
sendNoticeFormShow: false,
noticeVisible: false,
noticeOrigin: "3",
pageSize: 20,
pageNo: 0,
total: 0,
dataListLoading:false
};
},
components: {
@ -265,6 +269,33 @@ export default {
this.getFormInfo();
},
methods: {
async loadTable() {
this.dataListLoading = true;
const url = "/epmetuser/icPointNucleicMonitoring/page";
let params = {
limit: this.pageSize,
page: this.pageNo,
};
const { data, code, msg } = await requestGet(url, params);
if (code === 0) {
console.log(data.list);
this.dataList = data.list;
this.total = data.total;
} else {
this.$message.error(msg);
}
this.dataListLoading = false;
},
handleSizeChange(val) {
this.pageSize = val;
this.pageNo = 1;
this.loadTable();
},
handleCurrentChange(val) {
this.pageNo = val;
this.loadTable();
},
async handleDelete(id) {
this.$confirm("确认删除?", "提示", {
confirmButtonText: "确定",

27
src/views/modules/plugins/point/icpointvaccinesinoculation-add-or-update.vue

@ -25,7 +25,10 @@
:disabled="dialogTitle == '查看'"
></el-input>
</el-form-item>
<el-form-item label="接种时间" :class="dataForm.noAvailableVaccines != '2'?'':'time-class'">
<el-form-item
label="接种时间"
:class="dataForm.noAvailableVaccines != '2' ? '' : 'time-class'"
>
<div class="data-block">
<div style="width: 30%">
<el-date-picker
@ -340,7 +343,7 @@ export default {
},
// init
initMap() {
let { latitude, longitude } = this.dataForm;
let { latitude, longitude } = this.$store.state.user;
//
if (!latitude || latitude == "" || latitude == "0") {
latitude = 39.9088810666821;
@ -494,13 +497,11 @@ export default {
...this.dataForm,
...res.data,
};
if (res.data.moStartTime !== "" && res.data.afStartTime !== "") {
if (res.data.moStartTime !== "") {
this.morningTime = [res.data.moStartTime, res.data.moEndTime];
this.afterTime = [res.data.afStartTime, res.data.afEndTime];
}
if (!this.dataForm.longitude && !this.dataForm.latitude) {
this.dataForm.longitude = "120.38945519";
this.dataForm.latitude = "36.0722275";
if (res.data.afStartTime !== "") {
this.afterTime = [res.data.afStartTime, res.data.afEndTime];
}
this.initMap();
})
@ -513,10 +514,12 @@ export default {
if (!valid) {
return false;
}
if(!this.dataForm.inoculationDate &&
this.dataForm.noAvailableVaccines === "2"){
this.$message.error("请选择接种日期");
return false;
if (
!this.dataForm.inoculationDate &&
this.dataForm.noAvailableVaccines === "2"
) {
this.$message.error("请选择接种日期");
return false;
}
if (
this.morningTime === null &&
@ -566,7 +569,7 @@ export default {
.data-block {
display: flex;
}
.time-block>div{
.time-block > div {
margin-bottom: 10px;
}
.time-block span {

80
src/views/modules/plugins/point/icpointvaccinesinoculation.vue

@ -102,7 +102,9 @@
v-loading="dataListLoading"
:data="dataList"
border
style="width: 100%; height: 564px"
:row-key="row => { return row.id.toString() }"
:header-cell-style="{ background: '#2195FE', color: '#FFFFFF' }"
style="width: 100%; height: 564px;overflow: auto;"
>
<el-table-column
label="序号"
@ -111,12 +113,6 @@
type="index"
width="50"
></el-table-column>
<!--<el-table-column-->
<!--prop="orgName"-->
<!--label="所属组织名称"-->
<!--header-align="center"-->
<!--align="center"-->
<!--&gt;</el-table-column>-->
<el-table-column
prop="name"
label="疫苗接种点名称"
@ -130,7 +126,7 @@
align="center"
></el-table-column>
<el-table-column
label="接种上午时间"
label="上午接种时间"
header-align="center"
align="center"
>
@ -139,7 +135,7 @@
</template>
</el-table-column>
<el-table-column
label="接种下午开始时间"
label="下午接种时间"
header-align="center"
align="center"
>
@ -151,12 +147,14 @@
prop="noAvailableVaccines"
label="暂无疫苗"
header-align="center"
width="100"
align="center"
></el-table-column>
<el-table-column
prop="mobile"
label="咨询电话"
header-align="center"
width="150"
align="center"
></el-table-column>
<el-table-column
@ -164,11 +162,11 @@
label="接种点地址"
header-align="center"
align="center"
width="230"
show-overflow-tooltip
></el-table-column>
<el-table-column
:label="$t('handle')"
fixed="right"
label="操作"
header-align="center"
align="center"
width="150"
@ -177,31 +175,37 @@
<el-button
type="text"
size="small"
class="div-table-button--detail"
@click="addOrUpdateHandle(scope.row.id, '查看')"
>{{ "查看" }}</el-button
>
<el-button
type="text"
size="small"
class="div-table-button--edit"
@click="addOrUpdateHandle(scope.row.id, '修改')"
>{{ scope.row.longitude === null ? "待完善" : "修改" }}</el-button
>
<el-button
type="text"
size="small"
class="div-table-button--delete--noline"
@click="handleDelete(scope.row.id)"
>{{ $t("delete") }}</el-button
>
</template>
</el-table-column>
</el-table>
<el-pagination @size-change="pageSizeChangeHandle"
@current-change="pageCurrentChangeHandle"
:page-sizes="[20, 50, 100, 200]"
:page-size="limit"
layout="sizes, prev, pager, next, total"
:total="total">
</el-pagination>
<el-pagination
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
:current-page.sync="pageNo"
:page-sizes="[20, 50, 100, 200]"
:page-size="pageSize"
layout="sizes, prev, pager, next, total"
:total="total"
>
</el-pagination>
</div>
<!-- 弹窗, 新增 / 修改 -->
<el-dialog
@ -246,17 +250,11 @@
import mixinViewModule from "@/mixins/view-module";
import AddOrUpdate from "./icpointvaccinesinoculation-add-or-update";
import icpointNoice from "./icpointNoice";
import { requestPost } from "@/js/dai/request";
import { requestPost , requestGet} from "@/js/dai/request";
export default {
mixins: [mixinViewModule],
data() {
return {
mixinViewModuleOptions: {
getDataListURL: "/epmetuser/icPointVaccinesInoculation/page",
getDataListIsPage: true,
deleteURL: "/epmetuser/icPointVaccinesInoculation",
deleteIsBatch: true,
},
dataForm: {
name: "",
mobile: "",
@ -266,6 +264,10 @@ export default {
noticeVisible: false,
noticeOrigin: "4",
dialogTitle: "",
pageSize: 20,
pageNo: 0,
total: 0,
dataListLoading:false,
};
},
components: {
@ -273,9 +275,37 @@ export default {
icpointNoice,
},
mounted() {
this.loadTable();
this.noticeFun();
},
methods: {
async loadTable() {
this.dataListLoading = true;
const url = "/epmetuser/icPointVaccinesInoculation/page";
let params = {
limit: this.pageSize,
page: this.pageNo,
};
const { data, code, msg } = await requestGet(url, params);
if (code === 0) {
console.log(data.list);
this.dataList = data.list;
this.total = data.total;
} else {
this.$message.error(msg);
}
this.dataListLoading = false;
},
handleSizeChange(val) {
this.pageSize = val;
this.pageNo = 1;
this.loadTable();
},
handleCurrentChange(val) {
this.pageNo = val;
this.loadTable();
},
async handleDelete(id) {
this.$confirm("确认删除?", "提示", {
confirmButtonText: "确定",

Loading…
Cancel
Save