riku
5 天以前 f19e5267cc23b1c714dc746239864f33ed715dd9
src/views/fysp/task/components/CompSubTaskList.vue
@@ -1,6 +1,6 @@
<template>
  <el-row justify="space-between">
    <el-text>{{dateStr}}计划</el-text>
    <el-text>{{ dateStr }}计划</el-text>
    <div v-show="create && data && data.length > 0">
      <el-button
        icon="IconPrinter"
@@ -13,6 +13,9 @@
      <el-button type="success" size="small" @click="add" icon="Switch"
        >任务调整</el-button
      >
      <el-button type="primary" size="small" @click="openMap">
        进入地图<el-icon class="el-icon--right"><Right /></el-icon>
      </el-button>
    </div>
  </el-row>
  <el-divider />
@@ -27,7 +30,7 @@
      >
        <ItemSubTask v-for="s in data" :key="s.guid" :item="s">
          <template #default="{ item }">
            <el-space direction="vertical">
            <el-space direction="horizontal">
              <el-button
                :disabled="item.status != '未执行'"
                plain
@@ -35,16 +38,16 @@
                size="small"
                icon="EditPen"
                @click="edit(item)"
                >修改</el-button
              >
                title="修改"
              ></el-button>
              <el-button
                :disabled="item.status != '未执行'"
                type="danger"
                size="small"
                icon="Delete"
                @click="remove(item)"
                >移除</el-button
              >
                title="移除"
              ></el-button>
            </el-space>
          </template>
        </ItemSubTask>
@@ -111,9 +114,9 @@
const downloadDialog = ref(false);
const downloadSceneList = ref([]);
const emit = defineEmits(['submit', 'add', 'remove', 'update:modelValue']);
const emit = defineEmits(['submit', 'add', 'openMap', 'remove', 'update:modelValue']);
const dateStr = computed(()=> dayjs(props.date).format('MM月DD日'))
const dateStr = computed(() => dayjs(props.date).format('MM月DD日'));
function remove(item) {
  if (item.status == '未执行') {
@@ -156,6 +159,15 @@
  emit('add');
}
/**
 * 打开场景地图
 */
function openMap() {
  emit('openMap');
}
onUnmounted(() => {
  dialogVisible.value = false;
});