{
+ console.log("res----dddd", res);
+ // this.download(res.data, title + '.xls')
+ if (res.headers["content-disposition"]) {
+ let fileName = window.decodeURI(
+ res.headers["content-disposition"].split(";")[1].split("=")[1]
+ );
+ console.log("filename", fileName);
+ let blob = new Blob([res.data], {
+ type: "application/vnd.ms-excel",
+ });
+ var url = window.URL.createObjectURL(blob);
+ var aLink = document.createElement("a");
+ aLink.style.display = "none";
+ aLink.href = url;
+ aLink.setAttribute("download", fileName);
+ document.body.appendChild(aLink);
+ aLink.click();
+ document.body.removeChild(aLink); //下载完成移除元素
+ window.URL.revokeObjectURL(url); //释放掉blob对象
+ } else this.$message.error("下载失败");
+ })
+ .catch((err) => {
+ console.log("err", err);
+ return this.$message.error("网络错误");
+ });
+ },
+ // 下载文件
+ download (data, fileName) {
+ if (!data) {
+ return;
+ }
+
+ var csvData = new Blob([data]);
+
+ if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+ window.navigator.msSaveOrOpenBlob(csvData, fileName);
+ }
+ // for Non-IE (chrome, firefox etc.)
+ else {
+ var a = document.createElement("a");
+ document.body.appendChild(a);
+ a.style = "display: none";
+ var url = window.URL.createObjectURL(csvData);
+ a.href = url;
+ a.download = fileName;
+ a.click();
+ a.remove();
+ window.URL.revokeObjectURL(url);
+ }
+ },
diaClose () {
@@ -456,16 +569,18 @@ export default {
//重置搜索条件
resetSearch () {
this.formData = {
+ placeCategory: '',//0九小场所、1企事业单位
placeOrgName: '',//场所名称
mobile: '',//联系电话
- scale: '',//场所规模【 0:10人以下 1:10-20人 2:21-40人 3:41-100人 4:100人以上】
+ // scale: '',//场所规模【 0:10人以下 1:10-20人 2:21-40人 3:41-100人 4:100人以上】
+ scaleTotal: '',
gridId: '',//场所区域【网格Id】
ninePlaceVal: '',//场所类型【九小场所Value值】
isPage: true,//是否分页(是:true 否:false) 有这个参数是给新增巡查记录时用的,默认是
}
this.pageSize = 10
this.pageNo = 0
- this.loadTable()
+ // this.loadTable()
},
diff --git a/src/views/modules/communityService/ninePlaces/places/placesDetail.vue b/src/views/modules/communityService/ninePlaces/places/placesDetail.vue
index 7aab0f801..2a828d80e 100644
--- a/src/views/modules/communityService/ninePlaces/places/placesDetail.vue
+++ b/src/views/modules/communityService/ninePlaces/places/placesDetail.vue
@@ -8,6 +8,10 @@
场所类型:
{{ formData.ninePlaceName||'--' }}
+
+ 场所类别:
+ {{ formData.placeCategory ||'--' }}
+
场所区域:
@@ -25,7 +29,7 @@
规模:
- {{ formData.scaleName||'--' }}
+ {{ formData.scaleTotal||'--' }}
负责人:
diff --git a/src/views/modules/communityService/ninePlaces/places/placesForm.vue b/src/views/modules/communityService/ninePlaces/places/placesForm.vue
index ae7bb8e0c..e5d816dde 100644
--- a/src/views/modules/communityService/ninePlaces/places/placesForm.vue
+++ b/src/views/modules/communityService/ninePlaces/places/placesForm.vue
@@ -6,11 +6,25 @@
:inline="true"
:model="formData"
:rules="dataRule"
+ label-width="150px"
:disabled="formType === 'detail'"
class="form">
+
+
+
+
+
+
-
+ -->
+
+
+
+