“yueshang” 1 yıl önce
ebeveyn
işleme
a1f0dd00a7

+ 5 - 2
src/api/backend/remindBroad.js

@@ -63,10 +63,13 @@ export function getDepts(data) {
 }
 
 // 重要提醒获取当前用户管理的大队信息
-export function getFireTeams(data){
+export function getFireTeams(query){
   return request({
     url: '/backend/remind-broad/getfireteams',
+    header: {
+      'content-type': 'application/x-www-form-urlencoded'
+    },
     method: 'post',
-    data: data
+    params: query
   })
 }

+ 17 - 21
src/components/choiceOrange/index.vue

@@ -126,7 +126,7 @@ export default {
       // 总条数
       orgtotal: 0,
       // 遮罩层
-      orgloading: true,
+      orgloading: false,
       Righloading: false,
       // 左侧查询参数
       orgqueryParams: {
@@ -160,6 +160,7 @@ export default {
         pageSize: 10,
         userId: null,
         sjxfjg: null,
+        qumc:null
       },
     };
   },
@@ -168,7 +169,7 @@ export default {
     // this.getTreeselect();
     this.Orgreset();
     this.getOrgList();
-    this.getDeptData(); //获取街道和大队的数据
+    this.getDeptData(1); //获取街道和大队的数据
   },
   props: {
     userId: {
@@ -204,7 +205,7 @@ export default {
     clickType: {
       //深度监听
       handler(newV, oldV) {
-        this.getDeptData();
+        this.getDeptData(1);
       },
       deep: true,
       immediate: true,
@@ -212,10 +213,10 @@ export default {
     open: {
       //深度监听
       handler(newV, oldV) {
-        if (!newV) {
+        this.queryParamsStreet.qumc = null
           this.alreadySelectedOrgList = [];
           this.leftSelectedOrgList = [];
-        }
+          this.getDeptData(1)  
       },
       deep: true,
       immediate: true,
@@ -223,19 +224,19 @@ export default {
   },
   methods: {
     /** 获取消防大队和街道的数据 */
-    getDeptData() {
+    getDeptData(val) {
       // 获取大队数据
+      this.orgloading = true;
       this.leftDataList = null;
       if (this.clickType == 2) {
-        getFireTeams(this.userId).then((res) => {
+        getFireTeams({pageNo:1,pageSize:100}).then((res) => {
           this.orgloading = false;
           this.leftDataList = res.data.records;
         });
       } else if (this.clickType == 3) {
-        console.log("this.clickType", this.clickType);
+        this.queryParamsStreet.pageNo = val
         this.queryParamsStreet.userId = this.$store.state.user.id;
         this.queryParamsStreet.sjxfjg = this.userType;
-        console.log("-------------", this.queryParamsStreet.sjxfjg);
         // this.form.deptId
         getStreetPage(this.queryParamsStreet).then((response) => {
           this.orgloading = false;
@@ -249,19 +250,19 @@ export default {
     },
     /** 搜索按钮操作 */
     handleQuery() {
-      console.log(this.orgqueryParams, " this.orgqueryParams");
       this.queryParamsStreet.pageNo = 1;
-      this.getDeptData();
+      this.getDeptData(1);
     },
     /** 重置按钮操作 */
     resetQuery() {
       this.resetForm("queryForm");
+      this.queryParamsStreet.qumc = null
       this.handleQuery();
     },
     // ========单位信息==============================================================
     // 单位信息表单重置
     Orgreset() {
-      //   this.alreadySelectedOrgList = [];
+        // this.alreadySelectedOrgList = [];
       this.alreadySelectedOrgqueryParams = {
         pageNo: 1,
         pageSize: 10,
@@ -287,18 +288,13 @@ export default {
     //   });
     // },
     /** 查询单位信息列表 */
-    getOrgList() {
-      // 执行查询
-      //   this.orgloading = true;
-      //   getOrgPage(this.orgqueryParams).then((response) => {
-      //     this.list = response.data.list;
-      //     this.orgtotal = response.data.total;
-      //     this.orgloading = false;
-      //   });
+    getOrgList(val) {
+     if(val){
+      this.getDeptData(val.page)
+     }
     },
     // 分配分管单位table点击
     tableRowClick(row) {
-      console.log("row, column, event :>> ", row);
     },
     // 分配分管单位左侧多选框发送改变时
     handleSelectionChange(val) {

+ 5 - 21
src/views/backend/remindInfo/index.vue

@@ -584,17 +584,13 @@ export default {
       getUserProfile().then((response) => {
         this.form.deptId = response.data ? response.data.dept.id : "";
         this.userType = this.form.deptId;
-        console.log("this.userType", this.userType);
         getuserinfo(response.data.id)
           .then((res) => {
             this.streetId = res.data.streetInfo.id;
             // this.streetId = res.data.street
-            console.log("res=====", res);
           })
           .catch((err) => {
-            console.log("err", err);
           });
-        console.log("this.form.response", response);
       });
     },
     //获取所有的部门
@@ -602,13 +598,11 @@ export default {
       getDepts().then((response) => {
         this.listDeptData = response.data;
         this.getList();
-        console.log("response===", response);
       });
     },
     /** 查询列表 */
     getList(seeId) {
       this.list = []
-      console.log('seeId=====', seeId)
       this.loading = true;
       this.queryParams.userId = this.$store.state.user.id;
       // 执行查询
@@ -642,7 +636,6 @@ export default {
         }
         getRemindBroadPage(this.queryParams).then((response) => {
           this.loading = false;
-          console.log("this.listDeptData", this.listDeptData);
           response.data.records.forEach((key) => {
             this.listDeptData.forEach((item) => {
               if (item.id == key.sender) {
@@ -658,7 +651,6 @@ export default {
             });
           });
           this.list = response.data.records;
-          console.log("response.data.records", response.data.records);
           this.total = response.data.total;
         });
       }
@@ -679,7 +671,8 @@ export default {
         deptId: undefined,
         pubDate: undefined,
         remindZzList: [],
-        doneDate:undefined
+        doneDate:undefined,
+        fileUrls:[]
       };
       this.resetForm("form");
     },
@@ -694,11 +687,6 @@ export default {
         this.queryParams.doneDateStart = this.queryParams.doneDate[0];
         this.queryParams.doneDateEnd = this.queryParams.doneDate[1];
       }
-      console.log(
-        "ssssssss",
-        this.queryParams.pubDate,
-        this.queryParams.doneDate
-      );
       this.getList();
     },
     /** 重置按钮操作 */
@@ -725,7 +713,6 @@ export default {
     },
     // 已接受和信息反馈查看按钮
     handleSee2(row) {
-      console.log("row", row);
       const id = row.broad_id;
 
       getRemindBroad(id).then((response) => {
@@ -744,13 +731,11 @@ export default {
       this.form.broadType = row.broad_type;
     },
     submitFormComplete() {
-      console.log("this.form222222", this.form);
       this.form.fileUrls =
         this.form.fileUrls && this.form.fileUrls.length > 0
           ? this.form.fileUrls.split(",")
           : [];
       this.form.doneDate = parseTime(new Date(), "{y}-{m}-{d}");
-      console.log('this.form', this.form)
       this.$refs["form"].validate((valid) => {
         if (!valid) {
           return;
@@ -777,7 +762,8 @@ export default {
     submitForm() {
       // this.alreadySelectedOrgList = this.$refs["choiceSelect"].confirmMSg()
       // this.orgType = this.$refs["choiceSelect"].confirmoOrgTypeMSg()
-      const alreadyChooseOrg = this.$refs["choiceSelect"].confirmMSg();
+      let alreadyChooseOrg = [];
+      alreadyChooseOrg = this.$refs["choiceSelect"].confirmMSg();
       alreadyChooseOrg.forEach((item) => {
         if (item.deptName) {
           this.form.remindZzList.push({
@@ -808,10 +794,9 @@ export default {
         //   return;
         // }
         // 添加的提交
-        this.form.fileUrls = this.form.fileUrls
+        this.form.fileUrls = this.form.fileUrls.length>0
           ? this.form.fileUrls.split(",")
           : [];
-        console.log("this.form", this.form);
         createRemindInfo(this.form).then((response) => {
           this.$modal.msgSuccess("新增成功");
           this.open = false;
@@ -852,7 +837,6 @@ export default {
         .catch(() => {});
     },
     clickTab(e) {
-      console.log(e._props.name, "e._props.name;e._props.name;");
       const name = e._props.name;
       this.queryParams.pageNo = 1;
       this.list = [];