Przeglądaj źródła

更新工作人员端数据管理

libushang 7 miesięcy temu
rodzic
commit
19228a0eb6

+ 33 - 0
src/api/rescueManagement/index.ts

@@ -0,0 +1,33 @@
+import request from "@/utils/request";
+
+export function getTaskList(params) {
+  return request({
+    url: "/api/riskManagement/rescue/resources/children/task/list",
+    method: "get",
+    params: params
+  });
+}
+
+export function queryMyTaskRecord(params) {
+  return request({
+    url: '/api/riskManagement/rescue/resources/children/task/records',
+    method: 'get',
+    params: params
+  });
+}
+
+export function addTaskResult(data) {
+  return request({
+      url: '/api/riskManagement/rescue/resources/children/task/result/create',
+      method: 'post',
+      data: data
+    });
+}
+
+export function listTaskResult(children_task_id, params) {
+  return request({
+      url: '/api/riskManagement/rescue/resources/children/task/result/'+children_task_id+"/list",
+      method: 'get',
+      params: params
+    });
+}

+ 26 - 0
src/router/routes.ts

@@ -260,6 +260,24 @@ export const constantRoutes: Array<RouteRecordRaw> = [
     meta: {
       title: "排查结果"
     }
+  },
+  {
+    path: "/rescueGatherResultAdd",
+    name: "rescueGatherResultAdd",
+    component: () =>
+      import("@/views/worker/rescueManagement/rescueGatherResultAdd.vue"),
+    meta: {
+      title: "上报"
+    }
+  },
+  {
+    path: "/rescueGatherResultList",
+    name: "rescueGatherResultList",
+    component: () =>
+      import("@/views/worker/rescueManagement/rescueGatherResultList.vue"),
+    meta: {
+      title: "采集结果"
+    }
   }
 ];
 
@@ -379,6 +397,14 @@ export const workerRoute = [
           title: "风险防控"
         }
       },
+      {
+        path: "rescueManagement",
+        name: "rescueManagement",
+        component: () => import("@/views/worker/rescueManagement/index.vue"),
+        meta: {
+          title: "数据管理"
+        }
+      },
       {
         path: "duty",
         name: "Duty",

+ 1 - 1
src/views/worker/index.vue

@@ -111,7 +111,7 @@ const goToInformationReception = () => {
 const menu = ref([
   { name: "巡查工作", icon: "icon1", num: 0, url: "inspectionWork" },
   { name: "风险防控", icon: "icon2", num: 0, url: "riskManagement" },
-  { name: "数据管理", icon: "icon3", num: 0, url: "" },
+  { name: "数据管理", icon: "icon3", num: 0, url: "rescueManagement" },
   { name: "在线点名", icon: "icon4", num: 0, url: "rollCallRecord2" }
 ]);
 

+ 206 - 0
src/views/worker/rescueManagement/deviceSource.vue

@@ -0,0 +1,206 @@
+<!--救援设备-->
+<template>
+    <van-list
+      v-model:loading="loading"
+      v-model:error="error"
+      error-text="请求失败,点击重新加载"
+      :finished="finished"
+      finished-text="没有更多任务了"
+      class="list"
+      @load="getList"
+    >
+      <div
+        v-for="(item, index) in taskData"
+        :key="item.id"
+        class="event-list-item"
+      >
+        <div class="item-title">
+          <div class="item-title-text">救援设备采集任务</div>
+          <div class="item-title-control">
+            <van-button type="primary" @click="handleView(item)">
+              上报
+            </van-button>
+          </div>
+        </div>
+        <div class="item-content">
+          <div class="item-data">
+            <div class="item-left">
+              <i class="icon4" />
+              <div class="item-data-label">采集周期:</div>
+            </div>
+            <div class="item-data-value">{{ get_task_cycle(item.cycle) }}</div>
+          </div>
+          <div class="item-data">
+            <div class="item-left">
+              <i class="icon4" />
+              <div class="item-data-label">采集范围:</div>
+            </div>
+            <div class="item-data-value">{{ get_task_range(item.task_range) }}</div>
+          </div>
+          <div class="item-data">
+            <div class="item-left">
+              <i class="icon4" />
+              <div class="item-data-label">要求采集时间:</div>
+            </div>
+            <div class="item-data-value">{{ item.task_time }}</div>
+          </div>
+        </div>
+      </div>
+    </van-list>
+  </template>
+  <script setup lang="ts">
+  import { ref, reactive, toRefs } from "vue";
+  import { useRouter } from "vue-router";
+  import { getTaskList } from "@/api/rescueManagement";
+  const router = useRouter();
+  const total = ref(0);
+  const loading = ref(false);
+  const error = ref(false);
+  const finished = ref(false);
+  const data = reactive({
+    queryParams: {
+      type: '2', // 救援设备采集任务
+      page: 0,
+      pageSize: 10
+    }
+  });
+  
+  // 巡查周期选项
+  const cycleOptions = [
+    { value: '', label: '全部' },
+    { value: '0', label: '每年' },
+    { value: '1', label: '每月' },
+    { value: '2', label: '每周' },
+    { value: '3', label: '每日' },
+    { value: '4', label: '一次' }
+  ];
+  const rangeOptions = {
+        '0': '市级',
+        '1': '区县级',
+        '2': '镇街级',
+        '3': '村居级'
+  };
+  
+  const get_task_cycle = (cycle: String) => {
+    return cycleOptions.find(item => item.value == cycle).label
+  }
+  const get_task_range = (range) => {
+    return rangeOptions[range]
+  }
+  
+  const { queryParams } = toRefs(data);
+  const taskData = ref([]);
+  
+  async function getList() {
+    loading.value = true;
+    queryParams.value.page++;
+    getTaskList(queryParams.value)
+      .then(res => {
+        var items = res.data || [];
+        total.value = res.total;
+        if (queryParams.value.page == 1) {
+          taskData.value = [];
+        }
+        items.forEach(val => {
+          taskData.value.push(val);
+        });
+        if (queryParams.value.pageSize * queryParams.value.page >= total.value) {
+          finished.value = true;
+        } else {
+          finished.value = false;
+        }
+      })
+      .catch(() => {
+        error.value = true;
+        finished.value = false;
+      })
+      .finally(() => {
+        loading.value = false;
+      });
+  }
+  const handleView = (item) => {
+    router.push("/rescueGatherResultAdd?id="+item.id+"&type="+item.type+"&area_code="+item.area_code);
+  }
+  </script>
+  
+  <style lang="scss" scoped>
+  .list {
+    height: calc(100vh - 102px);
+    overflow-y: auto;
+  }
+  .van-doc-block__title {
+    color: var(--van-doc-text-color-4);
+    margin: 0;
+    padding: 32px 16px 16px;
+    font-size: 14px;
+    font-weight: 400;
+    line-height: 16px;
+  }
+  
+  .event-list-item {
+    position: relative;
+    margin: 16px 16px 0;
+    background: #ffffff;
+    border-radius: 4px;
+    border: 0.5px solid #eaedf7;
+    box-shadow: 0 0 4px 0 #4554661a;
+    &:first-child {
+      margin-top: 0;
+    }
+    .item-title {
+      display: flex;
+      align-items: center;
+      justify-content: space-between;
+      min-height: 46px;
+      background-image: linear-gradient(180deg, #f3f7fd 0%, #ffffff 100%);
+      padding: 0 12px;
+      .item-title-text {
+        font-size: 16px;
+        color: #414f64;
+        font-weight: 600;
+      }
+  
+      .item-title-control {
+        display: inline-flex;
+        justify-content: center;
+        align-items: center;
+      }
+      .van-button {
+        width: 73px;
+        height: 24px;
+        padding: 0;
+      }
+    }
+    .item-content {
+      padding: 0 12px 12px;
+    }
+    .item-data {
+      font-size: 14px;
+      display: flex;
+      flex-direction: row;
+      align-items: flex-start;
+      justify-content: start;
+      line-height: 26px;
+      .item-left {
+        display: flex;
+        align-items: center;
+        flex-shrink: 0;
+      }
+      .item-data-label {
+        flex-shrink: 0;
+        color: #414f64;
+      }
+  
+      .item-data-value {
+        color: #414f64;
+      }
+    }
+  }
+  .van-dropdown-menu {
+    :deep(.van-dropdown-menu__bar) {
+      background: transparent;
+      box-shadow: none;
+    }
+  }
+  </style>
+  

+ 264 - 0
src/views/worker/rescueManagement/gatherRecords.vue

@@ -0,0 +1,264 @@
+<!--采集记录-->
+<template>
+    <div class="container">
+      <van-search
+        placeholder="请输入任务名称"
+        v-model="queryParams.search_keyword"
+        class="common-search"
+        :left-icon="searchImg"
+        :right-icon="closeImg"
+        @search="on_search_keyword"
+        @click-right-icon.stop="on_search_cancel"
+      />
+      <van-dropdown-menu>
+        <van-dropdown-item
+          v-model="queryParams.type"
+          :title="!!queryParams.type ? '' : '类型'"
+          :options="businessOptions"
+          @change="change_busi_type"
+        />
+      </van-dropdown-menu>
+      <van-list
+        v-model:loading="loading"
+        v-model:error="error"
+        error-text="请求失败,点击重新加载"
+        :finished="finished"
+        finished-text="没有更多任务了"
+        @load="getList"
+      >
+        <div
+          v-for="(item, index) in taskData"
+          :key="item.id"
+          class="event-list-item"
+        >
+          <div class="item-title">
+            <div class="item-title-text">
+              {{ get_task_title(item.type) }}
+            </div>
+            <div class="item-title-control">
+              <van-button type="primary" @click="handleView(item)">
+                采集结果
+              </van-button>
+            </div>
+          </div>
+          <div class="item-content">
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">采集周期:</div>
+              </div>
+              <div class="item-data-value">{{ get_task_cycle(item.cycle) }}</div>
+            </div>
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">采集范围:</div>
+              </div>
+              <div class="item-data-value">{{ get_task_range(item.task_range) }}</div>
+            </div>
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">要求巡检时间:</div>
+              </div>
+              <div class="item-data-value">{{ item.task_time }}</div>
+            </div>
+          </div>
+        </div>
+      </van-list>
+    </div>
+  </template>
+  
+  <script lang="ts" setup>
+  import { getCurrentInstance, reactive, ref, toRefs, onMounted } from "vue";
+  import { useRouter } from "vue-router";
+  import searchImg from "@/assets/images/search.png";
+  import closeImg from "@/assets/images/close.png";
+  import { queryMyTaskRecord } from "@/api/rescueManagement";
+
+  const router = useRouter();
+  const taskData = ref([]);
+  const total = ref(0);
+  const loading = ref(false);
+  const error = ref(false);
+  const finished = ref(false);
+  const initFormData = reactive({
+    range: "",
+    cycle: "",
+    time: "",
+    title: "",
+    create_time: "",
+    id: 0
+  });
+  // 采集业务选项
+  const businessOptions = [
+    { text: "全部", value: "" },
+    { text: "庇护场所采集任务", value: "0" },
+    { text: "救援队伍采集任务", value: "1" },
+    { text: "救援设备采集任务", value: "2" }
+  ];
+  // 采集周期选项
+  const cycleOptions = [
+    { value: '', label: '全部' },
+    { value: '0', label: '每年' },
+    { value: '1', label: '每月' },
+    { value: '2', label: '每周' },
+    { value: '3', label: '每日' },
+    { value: '4', label: '一次' }
+  ];
+  const rangeOptions = {
+        '0': '市级',
+        '1': '区县级',
+        '2': '镇街级',
+        '3': '村居级'
+  };
+  const get_task_title = (business: String) => {
+    return businessOptions.find(item => item.value == business).text
+  }
+  const get_task_cycle = (cycle: String) => {
+    return cycleOptions.find(item => item.value == cycle).label
+  }
+  const get_task_range = (range) => {
+    return rangeOptions[range]
+  }
+  const data = reactive({
+    form: { ...initFormData },
+    queryParams: {
+      search_keyword: '',
+      type: '',
+      page: 0,
+      pageSize: 10
+    }
+  });
+  const { queryParams, form } = toRefs(data);
+  // 获取列表数据的方法
+  async function getList() {
+    loading.value = true;
+    queryParams.value.page++;
+    queryMyTaskRecord(queryParams.value)
+      .then(res => {
+        var items = res.data || [];
+        total.value = res.total;
+        if (queryParams.value.page == 1) {
+          taskData.value = [];
+        }
+        items.forEach(val => {
+          taskData.value.push(val);
+        });
+        if (queryParams.value.pageSize * queryParams.value.page >= total.value) {
+          finished.value = true;
+        } else {
+          finished.value = false;
+        }
+      })
+      .catch(() => {
+        error.value = true;
+        finished.value = false;
+      })
+      .finally(() => {
+        loading.value = false;
+      });
+  }
+  // 搜索关键字变化时触发的方法
+  function on_search_keyword(keyword) {
+    // 根据搜索关键字更新查询参数
+    queryParams.value.search_keyword = keyword;
+    queryParams.value.page = 0;
+    // 刷新列表数据
+    getList();
+  }
+  
+  // 右侧关闭按钮点击时触发的方法
+  const on_search_cancel = () => {
+    // 清空搜索关键字
+    queryParams.value.search_keyword = "";
+    queryParams.value.page = 0;
+    // 刷新列表数据
+    getList();
+  }
+  
+  const change_busi_type = () => {
+    queryParams.value.page = 0;
+    getList();
+  }
+  const handleView = (item) => {
+    router.push("/rescueGatherResultList?id="+item.id+"&type="+item.type+"&area_code="+item.area_code);
+  }
+
+  onMounted(()=>{
+    console.log("onMounted");
+  })
+  </script>
+  
+  <style lang="scss" scoped>
+  .event-list-item {
+    position: relative;
+    margin: 16px 16px 0;
+    background: #ffffff;
+    border-radius: 4px;
+    border: 0.5px solid #eaedf7;
+    box-shadow: 0 0 4px 0 #4554661a;
+    &:first-child {
+      margin-top: 0px;
+    }
+    .item-title {
+      display: flex;
+      align-items: center;
+      justify-content: space-between;
+      min-height: 46px;
+      background-image: linear-gradient(180deg, #f3f7fd 0%, #ffffff 100%);
+      padding: 0 12px;
+      .item-title-text {
+        font-size: 16px;
+        color: #414f64;
+        font-weight: 600;
+      }
+  
+      .item-title-control {
+        display: inline-flex;
+        justify-content: center;
+        align-items: center;
+      }
+      .van-button {
+        width: 73px;
+        height: 24px;
+        padding: 0;
+      }
+    }
+    .item-content {
+      padding: 0 12px 12px;
+    }
+    .item-data {
+      font-size: 14px;
+      display: flex;
+      flex-direction: row;
+      align-items: flex-start;
+      justify-content: start;
+      line-height: 26px;
+      .item-left {
+        display: flex;
+        align-items: center;
+        flex-shrink: 0;
+      }
+      .item-data-label {
+        flex-shrink: 0;
+        color: #414f64;
+      }
+  
+      .item-data-value {
+        color: #414f64;
+      }
+    }
+  }
+  .van-dropdown-menu {
+    :deep(.van-dropdown-menu__bar) {
+      background: transparent;
+      box-shadow: none;
+    }
+    :deep(.van-dropdown-menu__item) {
+      justify-content: right;
+      margin-right: 20px;
+    }
+  }
+  </style>
+  

+ 110 - 0
src/views/worker/rescueManagement/index.vue

@@ -0,0 +1,110 @@
+<template>
+  <div class="container">
+    <div class="tabs">
+      <div v-for="item in tabs" :key="item.id" class="tab" @click="handleClickTab(item.id)">
+        <i :class="activeIndex === item.id ? item.icon + '_checked' : item.icon" />
+        <div :class="activeIndex === item.id ? 'tab-text text-active' : 'tab-text'">{{ item.name }}</div>
+      </div>
+    </div>
+    <div class="content">
+      <shelterSource v-if="activeIndex === 'shelterSource'" @changIndex="handleClickTab" />
+      <rescueSource v-else-if="activeIndex === 'rescueSource'" />
+      <deviceSource v-else-if="activeIndex === 'deviceSource'" />
+      <gatherRecords v-else-if="activeIndex === 'gatherRecords'" />
+    </div>
+  </div>
+</template>
+<script setup lang="ts">
+import { ref } from "vue";
+import shelterSource from "./shelterSource.vue";
+import rescueSource from "./rescueSource.vue";
+import deviceSource from "./deviceSource.vue";
+import gatherRecords from "./gatherRecords.vue";
+
+let activeIndex = ref('shelterSource');
+let tabs = ref([
+  { id: 'shelterSource', name: '庇护场所', icon: 'tab1' },
+  { id: 'rescueSource', name: '救援队伍', icon: 'tab2' },
+  { id: 'deviceSource', name: '救援设备', icon: 'tab3' },
+  { id: 'gatherRecords', name: '采集记录', icon: 'tab4' },
+]);
+
+// 点击tab
+const handleClickTab = (id) => {
+  activeIndex.value = id;
+};
+
+</script>
+
+
+<style lang="scss" scoped>
+.container {
+  height: calc(100vh - 55px);
+  padding-top: 12px;
+  position: relative;
+  display: flex;
+  flex-direction: column;
+  .tabs {
+    height: 90px;
+    flex-shrink: 0;
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+    padding: 0 16px;
+    .tab {
+      display: flex;
+      flex-direction: column;
+      justify-content: center;
+      align-items: center;
+      .icon1, .icon2, .icon3, .icon4 {
+        display: inline-block;
+        width: 48px;
+        height: 48px;
+        background-color: #9d9d9d;
+      }
+      .tab-text {
+        color: #414F64;
+        font-size: 14px;
+        margin-top: 8px;
+      }
+      .text-active {
+        color: #2C81FF;
+      }
+    }
+  }
+  .content {
+    margin-top: 10px;
+    height: calc(100vh - 180px);
+    overflow-y: auto;
+  }
+  .tab1 {
+    background: url("@/assets/images/tab4.png") no-repeat;
+  }
+  .tab1_checked {
+    background: url("@/assets/images/tab4_checked.png") no-repeat;
+  }
+  .tab2 {
+    background: url("@/assets/images/tab5.png") no-repeat;
+  }
+  .tab2_checked {
+    background: url("@/assets/images/tab5_checked.png") no-repeat;
+  }
+  .tab3 {
+    background: url("@/assets/images/tab6.png") no-repeat;
+  }
+  .tab3_checked {
+    background: url("@/assets/images/tab6_checked.png") no-repeat;
+  }
+  .tab4 {
+    background: url("@/assets/images/tab7.png") no-repeat;
+  }
+  .tab4_checked {
+    background: url("@/assets/images/tab7_checked.png") no-repeat;
+  }
+  .tab1, .tab1_checked, .tab2, .tab2_checked, .tab3, .tab3_checked, .tab4, .tab4_checked {
+    width: 48px;
+    height: 48px;
+    background-size: 100% 100%;
+  }
+}
+</style>

+ 154 - 0
src/views/worker/rescueManagement/rescueGatherResultAdd.vue

@@ -0,0 +1,154 @@
+<template>
+    <van-form @submit="on_submit">
+        
+        <div style="padding: 16px 0 ;display:flex;flex-direction: row;justify-content: space-between;">
+            <div class="van-doc-block__title">{{get_task_title(type)}}</div>
+            <div class="van-doc-block__sub_title" @click="add" v-if="points.length < 3">新增采集点</div>
+        </div>
+
+        <div style="padding: 8px 8px 0 8px;background: #fff" v-for="(point, index) in points" :key="index">
+            <van-field
+            v-model="point.point_name"
+                :label="get_point_label(index)"
+                placeholder="填写采集点"
+                :rules="[{ required: true, message: '请填写采集点'  }]"
+            />
+
+            <van-field
+                v-model="point.task_result"
+                label="采集结果"
+                placeholder="选择采集结果"
+                :rules="[{ required: true, message: '请选择采集结果'  }]"
+                readonly
+                @click="openPicker(point)"
+            />
+
+            <van-field
+            v-model="point.remark"
+                label="备注信息"
+                placeholder="填写备注信息"
+                :rules="[{ required: false, message: '请填写备注信息'  }]"
+            />
+
+            <van-field name="fileList" label="现场照片" label-align="top">
+                <template #input>
+                    <ImageUpload v-model="point.fileList" :fileType="['png', 'jpeg', 'jpg']"/>
+                </template>
+            </van-field>
+        </div>
+
+        <div class="popup-footer" style="padding-bottom:16px;">
+            <van-button @click="handleCancel()" class="cancel-btn">取 消</van-button>
+            <van-button type="primary" native-type="submit" class="confirm-btn">提 交</van-button>
+        </div>
+    </van-form>
+    <van-popup v-model:show="showPicker" round position="bottom">
+        <van-picker
+            :columns="resultOptions"
+            @cancel="showPicker = false"
+            @confirm="onConfirm"
+        />
+    </van-popup>
+</template>
+<script lang="ts" setup>
+import {reactive, ref, toRefs, onMounted} from 'vue';
+import {useRoute, useRouter} from "vue-router";
+import { addTaskResult } from "@/api/rescueManagement";
+import { showToast } from 'vant';
+
+const route = useRoute();
+const router = useRouter();
+const id = ref('');
+const type = ref('');
+const area_code = ref('');
+const showPicker = ref(false);
+
+// 采集业务选项
+const businessOptions = [
+  { text: "全部", value: "" },
+  { text: "庇护场所采集任务", value: "0" },
+  { text: "救援队伍采集任务", value: "1" },
+  { text: "救援设备采集任务", value: "2" }
+];
+
+const resultOptions = [
+    { value: '0', text: '正常' },
+    { value: '1', text: '异常' }
+];
+
+const onConfirm = ({selectedOptions}) => {
+  showPicker.value = false;
+  point.value.task_result = selectedOptions[0].text;
+}
+
+const get_point_label = (index) => {
+  return "采集点" + (index+1);
+}
+
+const get_task_title = (business: String) => {
+  return businessOptions.find(item => item.value == business).text
+}
+const point = ref();
+const points = ref([{
+    point_name: '',
+    task_result: '',
+    remark: '',
+    fileList: []
+}]);
+
+const on_submit = () => {
+    console.log('on_submit', points.value);
+    addTaskResult({
+        children_task_id: id.value,
+        result: points.value,
+        area_code: area_code.value
+    }).then((res)=>{
+        router.replace("/rescueGatherResultList?id="+id.value+"&type="+type.value+"&area_code="+area_code.value);
+    });
+};
+
+const openPicker = (p) => {
+    point.value = p;
+    showPicker.value = true;
+};
+
+const add = () => {
+    points.value.push({
+        point_name: '',
+        task_result: '',
+        remark: '',
+        fileList: []
+    })
+};
+
+const handleCancel = () => {
+    router.back();
+}
+
+onMounted(() => {
+  id.value = route.query.id as string;
+  type.value = route.query.type as string;
+  area_code.value = route.query.area_code as string;
+})
+
+</script>
+
+<style lang="scss" scoped>
+.van-doc-block__title {
+  color: var(--van-doc-text-color-4);
+  margin: 0px;
+  padding: 0 6vmin;
+  font-size: 4.6vmin;
+  font-weight: 600;
+  line-height: 6.0vmin;
+}
+
+.van-doc-block__sub_title {
+    margin: 0px;
+    padding: 0 6vmin;
+    font-size: 3.6vmin;
+    font-weight: 400;
+    line-height: 6.0vmin;
+    color: #1989fa;
+}
+</style>

+ 219 - 0
src/views/worker/rescueManagement/rescueGatherResultList.vue

@@ -0,0 +1,219 @@
+<template>
+    <div class="container">
+        <div style="padding-top: 16px;display:flex;flex-direction: row;justify-content: space-between;">
+            <div class="van-doc-block__title">{{get_task_title(type)}}</div>
+        </div>
+
+        <div
+          v-for="(item, index) in resultData"
+          :key="item.id"
+          class="event-list-item"
+        >
+          <div class="item-content">
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">{{ get_point_label(index)}}:</div>
+              </div>
+              <div class="item-data-value">{{ item.point_name }}</div>
+            </div>
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">采集结果:</div>
+              </div>
+              <div class="item-data-value">{{ item.result }}</div>
+            </div>
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">备注信息:</div>
+              </div>
+              <div class="item-data-value">{{ item.remark }}</div>
+            </div>
+            <div class="item-data">
+              <div class="item-left">
+                <i class="icon4" />
+                <div class="item-data-label">现场照片:</div>
+              </div>
+              <div class="item-data-image">
+                <img
+                    v-for="(file, index2) in item.fileList"
+                    :key="file.id"
+                    class="image"
+                    :src="get_img_url(file.url)"
+                  ></img>
+              </div>
+            </div>
+          </div>
+        </div>
+    </div>
+</template>
+
+
+<script lang="ts" setup>
+import {reactive, ref, toRefs, onMounted} from 'vue';
+import {useRoute, useRouter} from "vue-router";
+import {listTaskResult } from "@/api/rescueManagement";
+import { showToast } from 'vant';
+
+const route = useRoute();
+const router = useRouter();
+const id = ref('');
+const type = ref('');
+const resultData = ref([]);
+
+// 采集业务选项
+const businessOptions = [
+  { text: "全部", value: "" },
+  { text: "庇护场所采集任务", value: "0" },
+  { text: "救援队伍采集任务", value: "1" },
+  { text: "救援设备采集任务", value: "2" }
+];
+
+const data = reactive({
+    queryParams: {
+      page: 1,
+      pageSize: 100
+    }
+});
+const { queryParams } = toRefs(data);
+
+const get_point_label = (index) => {
+  return "采集点" + (index+1);
+}
+
+const get_task_title = (business: String) => {
+    return businessOptions.find(item => item.value == business).text
+}
+
+const getList = () => {
+    listTaskResult(id.value, queryParams.value)
+      .then(res => {
+        resultData.value = res.data || [];
+    });
+};
+
+const baseUrl = import.meta.env.VITE_BASE_API;
+const downLoadApi = import.meta.env.VITE_BASE_DOWNLOAD_API;
+
+const get_img_url = (url) => {
+  return baseUrl + downLoadApi + url;
+}
+
+onMounted(() => {
+  id.value = route.query.id as string;
+  type.value = route.query.type as string;
+  getList();
+})
+</script>
+
+
+<style lang="scss" scoped>
+.van-doc-block__title {
+  color: var(--van-doc-text-color-4);
+  margin: 0px;
+  padding: 0 6vmin;
+  font-size: 4.6vmin;
+  font-weight: 600;
+  line-height: 6.0vmin;
+}
+
+.event-list-item {
+    position: relative;
+    margin: 16px 16px 0;
+    background: #ffffff;
+    border-radius: 4px;
+    border: 0.5px solid #eaedf7;
+    box-shadow: 0 0 4px 0 #4554661a;
+    &:first-child {
+      margin-top: 0px;
+    }
+    .item-title {
+      display: flex;
+      align-items: center;
+      justify-content: space-between;
+      min-height: 46px;
+      background-image: linear-gradient(180deg, #f3f7fd 0%, #ffffff 100%);
+      padding: 0 12px;
+      .item-title-text {
+        font-size: 16px;
+        color: #414f64;
+        font-weight: 600;
+      }
+  
+      .item-title-control {
+        display: inline-flex;
+        justify-content: center;
+        align-items: center;
+      }
+      .van-button {
+        width: 73px;
+        height: 24px;
+        padding: 0;
+      }
+    }
+    .item-content {
+      padding: 0 12px 12px;
+    }
+    .item-data {
+      font-size: 14px;
+      display: flex;
+      flex-direction: row;
+      align-items: flex-start;
+      justify-content: start;
+      line-height: 26px;
+      .item-left {
+        display: flex;
+        align-items: center;
+        flex-shrink: 0;
+      }
+      .item-data-label {
+        flex-shrink: 0;
+        color: #414f64;
+      }
+  
+      .item-data-value {
+        color: #414f64;
+      }
+
+      .item-data-image {
+        display:flex;
+        flex-direction: row; 
+
+        .image {
+          height:var(--van-uploader-size);;
+          width:var(--van-uploader-size);;
+        }
+      }
+    }
+  }
+  .icon1 {
+    width: 17px;
+    height: 16px;
+    background: url("@/assets/images/event/icon1.png") no-repeat;
+    background-size: 100% 100%;
+    margin-right: 7px;
+  }
+  .icon2 {
+    width: 17px;
+    height: 16px;
+    background: url("@/assets/images/event/icon2.png") no-repeat;
+    background-size: 100% 100%;
+    margin-right: 7px;
+  }
+  .icon3 {
+    width: 17px;
+    height: 16px;
+    background: url("@/assets/images/event/icon3.png") no-repeat;
+    background-size: 100% 100%;
+    margin-right: 7px;
+  }
+  .icon4 {
+    width: 17px;
+    height: 16px;
+    background: url("@/assets/images/event/icon4.png") no-repeat;
+    background-size: 100% 100%;
+    margin-right: 7px;
+  }
+</style>

+ 205 - 0
src/views/worker/rescueManagement/rescueSource.vue

@@ -0,0 +1,205 @@
+<!--救援队伍-->
+<template>
+  <van-list
+    v-model:loading="loading"
+    v-model:error="error"
+    error-text="请求失败,点击重新加载"
+    :finished="finished"
+    finished-text="没有更多任务了"
+    class="list"
+    @load="getList"
+  >
+    <div
+      v-for="(item, index) in taskData"
+      :key="item.id"
+      class="event-list-item"
+    >
+      <div class="item-title">
+        <div class="item-title-text">救援队伍采集任务</div>
+        <div class="item-title-control">
+          <van-button type="primary" @click="handleView(item)">
+            上报
+          </van-button>
+        </div>
+      </div>
+      <div class="item-content">
+        <div class="item-data">
+          <div class="item-left">
+            <i class="icon4" />
+            <div class="item-data-label">采集周期:</div>
+          </div>
+          <div class="item-data-value">{{ get_task_cycle(item.cycle) }}</div>
+        </div>
+        <div class="item-data">
+          <div class="item-left">
+            <i class="icon4" />
+            <div class="item-data-label">采集范围:</div>
+          </div>
+          <div class="item-data-value">{{ get_task_range(item.task_range) }}</div>
+        </div>
+        <div class="item-data">
+          <div class="item-left">
+            <i class="icon4" />
+            <div class="item-data-label">要求采集时间:</div>
+          </div>
+          <div class="item-data-value">{{ item.task_time }}</div>
+        </div>
+      </div>
+    </div>
+  </van-list>
+</template>
+<script setup lang="ts">
+import { ref, reactive, toRefs } from "vue";
+import { useRouter } from "vue-router";
+import { getTaskList } from "@/api/rescueManagement";
+const router = useRouter();
+const total = ref(0);
+const loading = ref(false);
+const error = ref(false);
+const finished = ref(false);
+const data = reactive({
+  queryParams: {
+    type: '1', // 救援队伍采集任务
+    page: 0,
+    pageSize: 10
+  }
+});
+
+// 巡查周期选项
+const cycleOptions = [
+  { value: '', label: '全部' },
+  { value: '0', label: '每年' },
+  { value: '1', label: '每月' },
+  { value: '2', label: '每周' },
+  { value: '3', label: '每日' },
+  { value: '4', label: '一次' }
+];
+const rangeOptions = {
+      '0': '市级',
+      '1': '区县级',
+      '2': '镇街级',
+      '3': '村居级'
+};
+
+const get_task_cycle = (cycle: String) => {
+  return cycleOptions.find(item => item.value == cycle).label
+}
+const get_task_range = (range) => {
+  return rangeOptions[range]
+}
+
+const { queryParams } = toRefs(data);
+const taskData = ref([]);
+
+async function getList() {
+  loading.value = true;
+  queryParams.value.page++;
+  getTaskList(queryParams.value)
+    .then(res => {
+      var items = res.data || [];
+      total.value = res.total;
+      if (queryParams.value.page == 1) {
+        taskData.value = [];
+      }
+      items.forEach(val => {
+        taskData.value.push(val);
+      });
+      if (queryParams.value.pageSize * queryParams.value.page >= total.value) {
+        finished.value = true;
+      } else {
+        finished.value = false;
+      }
+    })
+    .catch(() => {
+      error.value = true;
+      finished.value = false;
+    })
+    .finally(() => {
+      loading.value = false;
+    });
+}
+const handleView = (item) => {
+  router.push("/rescueGatherResultAdd?id="+item.id+"&type="+item.type+"&area_code="+item.area_code);
+}
+</script>
+
+<style lang="scss" scoped>
+.list {
+  height: calc(100vh - 102px);
+  overflow-y: auto;
+}
+.van-doc-block__title {
+  color: var(--van-doc-text-color-4);
+  margin: 0;
+  padding: 32px 16px 16px;
+  font-size: 14px;
+  font-weight: 400;
+  line-height: 16px;
+}
+
+.event-list-item {
+  position: relative;
+  margin: 16px 16px 0;
+  background: #ffffff;
+  border-radius: 4px;
+  border: 0.5px solid #eaedf7;
+  box-shadow: 0 0 4px 0 #4554661a;
+  &:first-child {
+    margin-top: 0;
+  }
+  .item-title {
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
+    min-height: 46px;
+    background-image: linear-gradient(180deg, #f3f7fd 0%, #ffffff 100%);
+    padding: 0 12px;
+    .item-title-text {
+      font-size: 16px;
+      color: #414f64;
+      font-weight: 600;
+    }
+
+    .item-title-control {
+      display: inline-flex;
+      justify-content: center;
+      align-items: center;
+    }
+    .van-button {
+      width: 73px;
+      height: 24px;
+      padding: 0;
+    }
+  }
+  .item-content {
+    padding: 0 12px 12px;
+  }
+  .item-data {
+    font-size: 14px;
+    display: flex;
+    flex-direction: row;
+    align-items: flex-start;
+    justify-content: start;
+    line-height: 26px;
+    .item-left {
+      display: flex;
+      align-items: center;
+      flex-shrink: 0;
+    }
+    .item-data-label {
+      flex-shrink: 0;
+      color: #414f64;
+    }
+
+    .item-data-value {
+      color: #414f64;
+    }
+  }
+}
+.van-dropdown-menu {
+  :deep(.van-dropdown-menu__bar) {
+    background: transparent;
+    box-shadow: none;
+  }
+}
+</style>

+ 205 - 0
src/views/worker/rescueManagement/shelterSource.vue

@@ -0,0 +1,205 @@
+<!--庇护场所-->
+<template>
+  <van-list
+    v-model:loading="loading"
+    v-model:error="error"
+    error-text="请求失败,点击重新加载"
+    :finished="finished"
+    finished-text="没有更多任务了"
+    class="list"
+    @load="getList"
+  >
+    <div
+      v-for="(item, index) in taskData"
+      :key="item.id"
+      class="event-list-item"
+    >
+      <div class="item-title">
+        <div class="item-title-text">庇护场所采集任务</div>
+        <div class="item-title-control">
+          <van-button type="primary" @click="handleView(item)">
+            上报
+          </van-button>
+        </div>
+      </div>
+      <div class="item-content">
+        <div class="item-data">
+          <div class="item-left">
+            <i class="icon4" />
+            <div class="item-data-label">采集周期:</div>
+          </div>
+          <div class="item-data-value">{{ get_task_cycle(item.cycle) }}</div>
+        </div>
+        <div class="item-data">
+          <div class="item-left">
+            <i class="icon4" />
+            <div class="item-data-label">采集范围:</div>
+          </div>
+          <div class="item-data-value">{{ get_task_range(item.task_range) }}</div>
+        </div>
+        <div class="item-data">
+          <div class="item-left">
+            <i class="icon4" />
+            <div class="item-data-label">要求采集时间:</div>
+          </div>
+          <div class="item-data-value">{{ item.task_time }}</div>
+        </div>
+      </div>
+    </div>
+  </van-list>
+</template>
+<script setup lang="ts">
+import { ref, reactive, toRefs } from "vue";
+import { useRouter } from "vue-router";
+import { getTaskList } from "@/api/rescueManagement";
+const router = useRouter();
+const total = ref(0);
+const loading = ref(false);
+const error = ref(false);
+const finished = ref(false);
+const data = reactive({
+  queryParams: {
+    type: '0', // 庇护场所采集任务
+    page: 0,
+    pageSize: 10
+  }
+});
+
+// 巡查周期选项
+const cycleOptions = [
+  { value: '', label: '全部' },
+  { value: '0', label: '每年' },
+  { value: '1', label: '每月' },
+  { value: '2', label: '每周' },
+  { value: '3', label: '每日' },
+  { value: '4', label: '一次' }
+];
+const rangeOptions = {
+      '0': '市级',
+      '1': '区县级',
+      '2': '镇街级',
+      '3': '村居级'
+};
+
+const get_task_cycle = (cycle: String) => {
+  return cycleOptions.find(item => item.value == cycle).label
+}
+const get_task_range = (range) => {
+  return rangeOptions[range]
+}
+
+const { queryParams } = toRefs(data);
+const taskData = ref([]);
+
+async function getList() {
+  loading.value = true;
+  queryParams.value.page++;
+  getTaskList(queryParams.value)
+    .then(res => {
+      var items = res.data || [];
+      total.value = res.total;
+      if (queryParams.value.page == 1) {
+        taskData.value = [];
+      }
+      items.forEach(val => {
+        taskData.value.push(val);
+      });
+      if (queryParams.value.pageSize * queryParams.value.page >= total.value) {
+        finished.value = true;
+      } else {
+        finished.value = false;
+      }
+    })
+    .catch(() => {
+      error.value = true;
+      finished.value = false;
+    })
+    .finally(() => {
+      loading.value = false;
+    });
+}
+const handleView = (item) => {
+  router.push("/rescueGatherResultAdd?id="+item.id+"&type="+item.type+"&area_code="+item.area_code);
+}
+</script>
+
+<style lang="scss" scoped>
+.list {
+  height: calc(100vh - 102px);
+  overflow-y: auto;
+}
+.van-doc-block__title {
+  color: var(--van-doc-text-color-4);
+  margin: 0;
+  padding: 32px 16px 16px;
+  font-size: 14px;
+  font-weight: 400;
+  line-height: 16px;
+}
+
+.event-list-item {
+  position: relative;
+  margin: 16px 16px 0;
+  background: #ffffff;
+  border-radius: 4px;
+  border: 0.5px solid #eaedf7;
+  box-shadow: 0 0 4px 0 #4554661a;
+  &:first-child {
+    margin-top: 0;
+  }
+  .item-title {
+    display: flex;
+    align-items: center;
+    justify-content: space-between;
+    min-height: 46px;
+    background-image: linear-gradient(180deg, #f3f7fd 0%, #ffffff 100%);
+    padding: 0 12px;
+    .item-title-text {
+      font-size: 16px;
+      color: #414f64;
+      font-weight: 600;
+    }
+
+    .item-title-control {
+      display: inline-flex;
+      justify-content: center;
+      align-items: center;
+    }
+    .van-button {
+      width: 73px;
+      height: 24px;
+      padding: 0;
+    }
+  }
+  .item-content {
+    padding: 0 12px 12px;
+  }
+  .item-data {
+    font-size: 14px;
+    display: flex;
+    flex-direction: row;
+    align-items: flex-start;
+    justify-content: start;
+    line-height: 26px;
+    .item-left {
+      display: flex;
+      align-items: center;
+      flex-shrink: 0;
+    }
+    .item-data-label {
+      flex-shrink: 0;
+      color: #414f64;
+    }
+
+    .item-data-value {
+      color: #414f64;
+    }
+  }
+}
+.van-dropdown-menu {
+  :deep(.van-dropdown-menu__bar) {
+    background: transparent;
+    box-shadow: none;
+  }
+}
+</style>