<template>
  <div class="app-container">
    <!-- <el-descriptions title="编辑主路径" /> -->
    <div class="title">
      <el-tag>主路径</el-tag>
      <div>
        {{ updata.routeName }}
      </div>
      <div class="select">
        <span> 适用范围 </span>
        <el-select v-model="updata.suitRange" placeholder="请选择" @change="changeoptions">
          <el-option v-for="item in options" :key="item.dictValue" :label="item.dictLabel" :value="item.dictValue">
          </el-option>
        </el-select>
      </div>
    </div>
    <div class="list">
      <div class="timelist">
        <div class="timetitle">
          管理路径节点({{ lists.length }})
          <i class="el-icon-circle-plus-outline" @click="addlist"></i>
        </div>
        <el-timeline>
          <el-timeline-item v-for="(item, index) in lists" :key="index" :color="listindex == index ? '#409EFF' : ''">
            <div class="top">
              <div class="toptop">
                <el-select v-model="item.routeNodeName" style="width: 100px">
                  <el-option v-for="item in parentDictCodelist" :key="item.dictValue" :label="item.dictLabel"
                    :value="item.dictValue">
                  </el-option>
                  <!-- <el-option label="出院后" value="AFTER_DISCHARGE" />
                  <el-option label="入院后" value="AFTER_ADMISSION" />
                  <el-option label="就诊后" value="AFTER_CONSULTATION" />
                  <el-option
                    label="就诊/出院后"
                    value="AFTER_VISIT_DISCHARGE"
                  />
                  <el-option label="术前" value="PREOPERATIVE" />
                  <el-option label="术后" value="POSTOPERATIVE" /> -->
                </el-select>
                <el-input v-model="item.routeNodeDay" style="width: 70px" type="number" :min="0"></el-input>
                <span>天</span>
              </div>
              <div>
                <i class="el-icon-delete" @click="delitem(item, index)"></i>
                <i class="el-icon-circle-plus-outline" @click="additem(item)"></i>
              </div>
            </div>
            <el-card v-for="(uitem, uindex) in item.list" :key="uitem.id"
              @click.native="bottomclickevent(uitem, index, uindex)"
              :class="listindex == index && itemindex == uindex ? 'cards' : ''">
              <h3 style="height: 20px">{{ uitem.taskTypeName }}</h3>
              <el-tag v-if="uitem.routeCheckStatus == 'AGREE'" class="routeCheckStatus">已审核</el-tag>
              <el-tag v-else-if="uitem.routeCheckStatus == 'DISAGREE'" type="danger"
                class="routeCheckStatus">不同意</el-tag>
              <el-tag v-else type="warning" class="routeCheckStatus">未审核</el-tag>
              <p style="height: 16px">{{ uitem.taskSubdivisionName }}</p>
            </el-card>
          </el-timeline-item>
        </el-timeline>
      </div>
      <div class="texts">
        <div class="topform">
          <el-form ref="form" :inline="true" :model="form" class="form">
            <el-form-item label="任务类型" prop="">
              <el-select v-model="form.taskType" style="width: 110px" @change="changeTaskType">
                <el-option v-for="item in selectTaskTypeList" :key="item.taskTypeCode" :label="item.taskTypeName"
                  :value="item.taskTypeCode">
                </el-option>
              </el-select>
            </el-form-item>
            <el-form-item label="任务细分" prop="">
              <el-select v-model="form.taskSubdivision" style="width: 110px" @change="changetaskSubdivision">
                <el-option v-for="item in taskPartitionList" :key="item.taskPartitionCode"
                  :label="item.taskPartitionName" :value="item.taskPartitionCode">
                </el-option>
              </el-select>
            </el-form-item>
            <el-form-item label="任务节点类型" prop="">
              <el-select v-model="form.taskNodeType" style="width: 150px">
                <el-option v-for="item in taskNodeTypeList" :key="item.id" :label="item.name" :value="item.code">
                </el-option>
              </el-select>
            </el-form-item>
            <!-- <el-form-item label="任务状态" prop="">
              <el-select v-model="form.taskStatus" style="width: 110px">
                <el-option v-for="item in taskStatusDictList" :key="item.id" :label="item.taskStatusName"
                  :value="item.taskStatusCode">
                </el-option>
              </el-select>
            </el-form-item> -->
            <el-form-item label="二级分类描述" prop="">
              <el-input v-model="form.secondClassifyDescribe" style="width: 110px" disabled></el-input>
            </el-form-item>
            <el-form-item label="执行时间" prop="">
              <el-time-select v-model="form.executionTime" style="width: 120px" placeholder="选择时间" disabled>
              </el-time-select>
            </el-form-item>
            <el-form-item label="问卷库模板选择" prop="" v-if="form.taskNodeType == 'QUESTIONNAIRE_SCALE'">
              <question @on-template="questionontemplate" :templateId="form.templateId"
                :templateName="form.templateName"></question>
            </el-form-item>
            <el-form-item label="宣教库模板选择" prop="" v-if="form.taskNodeType == 'PROPAGANDA_ARTICLE'">
              <propaganda @on-template="propagandaontemplate" :templateId="form.templateId"
                :templateName="form.templateName"></propaganda>
            </el-form-item>
          </el-form>
        </div>
        <div class="bottomform">
          <wangeditor style="width: 100%;background-color: red;" :nodeContent="form.nodeContent"
            @on-nodeContent="onNodeContent" v-show="form.taskNodeType != 'QUESTIONNAIRE_SCALE' &&
          form.taskNodeType != 'PROPAGANDA_ARTICLE' &&
          form.taskNodeType != 'PHONE_OUTBOUND'
          " ref="wangeditor" />
          <div class="card" v-show="form.taskNodeType != 'PHONE_OUTBOUND'">
            <div class="flex">
              <div class="pushMethod">
                推送方式：
                <span> 短信 </span>
              </div>
              <div class="pushMethod">
                模板：
                <message @on-template="messageontemplate" :templateId="form.messageTemplateId"
                  :templateName="form.messageTemplateName"></message>
              </div>
              <div class="pushMethod">
                <el-switch v-model="form.messagePushSign" active-color="#13ce66" active-value="1" inactive-value="0">
                </el-switch>
              </div>
            </div>
            <!-- <div class="flextwo">
              <div class="text">短信预览：</div>
              <el-input class="textarea" v-model="form.messagePreview" disabled></el-input>
            </div> -->
          </div>
          <div class="card" v-show="form.taskNodeType != 'PHONE_OUTBOUND'">
            <div class="flex">
              <div class="pushMethod">
                推送方式：
                <span> 公众号 </span>
              </div>
              <div class="pushMethod">
                模板：
                <span>
                  <officialAccount @on-template="officialAccountontemplate" :templateId="form.officialTemplateId"
                    :templateName="form.officialTemplateName">
                  </officialAccount>
                </span>
              </div>
              <div class="pushMethod">
                <el-switch v-model="form.officialPushSign" active-color="#13ce66" active-value="1" inactive-value="0">
                </el-switch>
              </div>
            </div>
            <!-- <div class="flextwo">
              <div class="text">提醒内容：</div>
              <el-input v-model="form.officialRemindContent" class="textarea" disabled></el-input>
            </div> -->
          </div>
          <div class="card" v-show="form.taskNodeType != 'PHONE_OUTBOUND'">
            <div class="flex">
              <div class="pushMethod">
                推送方式：
                <span> 小程序 </span>
              </div>
              <div class="pushMethod">
                模板：
                <span>
                  <miniProgram @on-template="miniProgramtemplate" :templateId="form.appletTemplateId"
                    :templateName="form.appletTemplateName">
                  </miniProgram>
                </span>
              </div>
              <div class="pushMethod">
                <el-switch v-model="form.appletPushSign" active-color="#13ce66" active-value="1" inactive-value="0">
                </el-switch>
              </div>
            </div>
            <!-- <div class="flextwo">
              <div class="text">提醒内容：</div>
              <el-input v-model="form.appletRemindContent" class="textarea" disabled></el-input>
            </div>
            <div class="flextwo">
              <div class="text">提示说明：</div>
              <el-input v-model="form.appletPromptDescription" class="textarea" disabled></el-input>
            </div> -->
          </div>
          <div class="card" style="height: 250px" v-show="form.taskNodeType == 'PHONE_OUTBOUND'">
            <div class="flex">
              <div class="pushMethod">
                推送方式：
                <span> 人工电话 </span>
              </div>
              <div class="pushMethod">
                模板：
                <scripts @on-template="messageontemplateword" :templateId="form.phoneTemplateId"
                  :templateName="form.phoneTemplateName"></scripts>
              </div>
              <div class="pushMethod">
                <el-switch v-model="form.phonePushSign" active-color="#13ce66" active-value="1" inactive-value="0">
                </el-switch>
              </div>
            </div>
            <div class="flex">
              <div class="pushMethod">
                重播次数：
                <span>
                  <el-select v-model="form.phoneRedialTimes" style="width: 100px">
                    <el-option v-for="item in optionslistS" :key="item.dictValue" :label="item.dictLabel"
                      :value="item.dictValue">
                    </el-option>
                  </el-select>
                </span>
              </div>
              <div class="pushMethod">
                时间间隔:
                <span>
                  <el-input v-model.number="form.phoneTimeInterval" oninput="value=value.replace(/[^\d]/g,'')"
                    style="width: 100px">
                    <!-- <el-option
                      v-for="item in optionslistS"
                      :key="item.dictValue"
                      :label="item.dictLabel"
                      :value="item.dictValue"
                    >
                    </el-option> -->
                  </el-input>
                </span>
              </div>
              <div class="pushMethod">
                短信提醒：
                <el-select v-model="form.phoneMessageRemind" style="width: 150px">
                  <el-option v-for="item in optionslist" :key="item.dictValue" :label="item.dictLabel"
                    :value="item.dictValue">
                  </el-option>
                </el-select>
              </div>
              <div class="pushMethod">
                短信模板：
                <span :class="form.phoneMessageRemind == 'NOT_SEND_MESSAGE' ? 'spanname' : ''">
                  <message style="width: 200px" @on-template="messageontemplateMESSAGE"
                    :templateId="form.phoneMessageTemplateId" :templateName="form.phoneMessageTemplateName"></message>
                </span>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import wangeditor from './wangEditor.vue'
import question from '@/views/system/components/question.vue'
import message from '@/views/system/components/message.vue'
import propaganda from '@/views/system/components/propaganda.vue'
import officialAccount from '@/views/system/components/officialAccount.vue'
import miniProgram from '@/views/system/components/miniProgram.vue'
import scripts from '@/views/system/components/script.vue'

import {
  selectTaskTypeList, taskPartitionList, taskStatusDictList, specialDiseaseNode, selectSpecialDiseasenew, updateRouteCheckStatus, getById, selectSpecialDisease,
} from '@/api/system/specialDiseaseNode'
import questionopennew from '../components/questionopennew.vue';
import Editorxj from "../../system/Editorxj/index.vue";
import { getAgencytype } from "@/api/system/agency";

export default {
  components: { wangeditor, question, propaganda, message, officialAccount, miniProgram, questionopennew, Editorxj, scripts, },
  props: ['lookitem'],
  name: "specialDiseaseNodeopen",
  data() {
    return {
      options: [],
      optionslist: [],
      optionslistS: [],
      show: false,
      baseUrl: process.env.VUE_APP_BASE_API,
      dialogVisible: false,
      routeform: {
        routeCheckStatus: null,
        routeCheckRemark: "",
      },
      rules: {
        routeCheckStatus: [
          { required: true, message: '请选择节点审核状态', trigger: 'change' }
        ],
      },
      totalNumber: 0,
      agreeNumber: 0,
      updata: {
        specialDiseaseRouteId: "",
        manageRouteId: '',
        suitRange: '',
        routeName: '',
        specialDiseaseNodeList: [],
      },
      form: {
        nodeContent: '<p></p>',
        templateId: '',
        templateName: '',
        taskType: '',
        taskSubdivision: '',
        taskSubdivisionName: '',
        taskStatus: '',
        secondClassifyDescribe: '',
        executionTime: '',
        appletPushSign: '0',
        officialPushSign: '0',
        messagePushSign: 0,
        taskNodeType: '',
        officialRemindContent: '',
        messagePreview: '',
        appletRemindContent: '',
        appletPromptDescription: '',
      },
      itemindex: 0,
      listindex: 0,
      lists: [],
      lookitemnew: {},
      value: '',
      input: '',
      parentDictCode: "",
      //任务类型
      selectTaskTypeList: [],
      //任务状态
      taskStatusDictList: [],
      //任务细分
      taskPartitionList: [],
      parentDictCodelist: [],
      taskNodeTypeList: [
        {
          name: '电话外呼',
          code: 'PHONE_OUTBOUND',
        },
        {
          name: '问卷量表',
          code: 'QUESTIONNAIRE_SCALE',
        },
        {
          name: '宣教文案',
          code: 'PROPAGANDA_ARTICLE',
        },
        {
          name: '文字提醒',
          code: 'TEXT_REMIND',
        }
      ],
    };
  },
  created() {
    this.updata = this.lookitem
    console.log(this.updata)
    this.updata.manageRouteId = this.lookitem.manageRouteId
    this.updata.specialDiseaseRouteId = this.updata.id
    this.taskinfo();
    this.infolistword();
    this.infolistMESSAGE();
    this.infolist();
  },
  beforeDestroy() { },
  watch: {
    lookitem(newValue, oldValue) {
      this.updata = newValue;
      this.updata.manageRouteId = newValue.manageRouteId
      this.taskinfo();
    }
  },
  mounted() {
  },
  methods: {
    infolistword() {
      var dictType = "text_message_remind";
      getAgencytype(dictType).then((res) => {
        this.optionslist = res.data;
        // this.taskinfo();
      });
    },
    infolistMESSAGE() {
      var dictType = "redial_times";
      getAgencytype(dictType).then((res) => {
        this.optionslistS = res.data;
        // this.taskinfo();
      });
    },
    infolist() {
      var dictType = "suit_range";
      getAgencytype(dictType).then((res) => {
        this.options = res.data;
        this.taskinfo();
      });
    },
    changeoptions(e) {
      this.parentDictCode = this.options.find(
        (el) => el.dictValue == e
      )?.dictCode;
      this.changelisy();
    },
    changelisy() {
      list(this.parentDictCode).then((res) => {
        this.parentDictCodelist = res.rows;
      });
    },
    info() {
      const loading = this.$loading({
        lock: true,
        text: "数据加载中",
        spinner: "el-icon-loading",
        background: "rgba(0, 0, 0, 0.7)",
      });
      this.lists = [];
      if (this.$route.query) {
        this.parentDictCode = this.options.find(
          (el) => el.dictValue == this.updata.suitRange
        )?.dictCode;
        // this.changelisy();
        this.updata.routeName = this.$route.query.routeName;
        // this.updata.specialDiseaseRouteId = this.$route.query.id;
        selectSpecialDisease(this.updata.id).then((res) => {
          this.agreeNumber = res.data.agreeNumber;
          this.totalNumber = res.data.totalNumber;
          res.data.specialDiseaseNodeList.forEach((e) => {
            // if (e.taskNodeType == 'PHONE_OUTBOUND') {
            //   e.taskSubdivisionName = e.taskSubdivisionName + '(电话外呼)'
            // } else if (e.taskNodeType == 'QUESTIONNAIRE_SCALE') {
            //   e.taskSubdivisionName = e.taskSubdivisionName + '(问卷量表)'
            // } else if (e.taskNodeType == 'PROPAGANDA_ARTICLE') {
            //   e.taskSubdivisionName = e.taskSubdivisionName + '(宣教文案)'
            // } else if (e.taskNodeType == 'TEXT_REMIND') {
            //   e.taskSubdivisionName = e.taskSubdivisionName + '(文字提醒)'
            // }
            if (e.messagePushSign) {
              e.messagePushSign = "" + e.messagePushSign;
            } if (e.officialPushSign) {
              e.officialPushSign = "" + e.officialPushSign;
            }
            if (e.appletPushSign) {
              e.appletPushSign = "" + e.appletPushSign;
            }
            if (e.phonePushSign) {
              e.phonePushSign = "" + e.phonePushSign
            }
          });
          this.lists = this.handleData(
            res.data.specialDiseaseNodeList,
            "routeNodeDay",
            "routeNodeName"
          );
          this.form = this.lists[0].list[0];
          if (this.form.taskType) {
            this.changeTaskType(this.form.taskType, this.form.taskSubdivision);
          }
          loading.close();
        });
      } else {
        this.lists.push({
          routeNodeName: "",
          routeNodeDay: "",
          list: [
            {
              nodeContent: "<p></p>",
              templateId: "",
              templateName: "",
              taskType: "",
              taskSubdivision: "",
              taskSubdivisionName: "",
              taskStatus: "",
              secondClassifyDescribe: "",
              executionTime: "",
              appletPushSign: "0",
              officialPushSign: "0",
              messagePushSign: "0",
              messagePreview: "",
              officialRemindContent: "",
              taskNodeType: "",
              appletRemindContent: "",
              appletPromptDescription: "",
            },
          ],
        });
        this.form = this.lists[0].list[0];
        loading.close();
      }
    },
    handleData(list, key, keytwo) {
      //得到数据的主键列表
      let keysArr = list.map((item) => {
        return {
          routeNodeDay: item[key],
          routeNodeName: item[keytwo],
        };
      });
      let array = keysArr.filter(
        (item, index, arr) =>
          index ===
          arr.findIndex(
            (ite) =>
              ite.routeNodeDay == item.routeNodeDay &&
              ite.routeNodeName == item.routeNodeName
          )
      );
      // for (var i = 0; i < keysArr.length; i++) {
      //     for (var j = i + 1; j < keysArr.length; j++) {
      //         if (keysArr[i].routeNodeDay == keysArr[j].routeNodeDay && keysArr[i].routeNodeName == keysArr[j].routeNodeName) {
      //             keysArr.splice(j, 1);
      //             j--;
      //         }
      //     }
      // }
      let keys = [...new Set(array)];
      let newList = keys.map((item) => {
        return {
          //这里写新的 数据结构 如下是整体复制
          routeNodeDay: item[key],
          routeNodeName: item[keytwo],
          list: list.filter(
            (i) => i[key] == item[key] && i[keytwo] == item[keytwo]
          ),
        };
      });
      return newList;
    },
    //wangeditor传值
    onNodeContent(item) {
      this.form.nodeContent = item.nodeContent
    },
    //小程序传值
    miniProgramtemplate(item) {
      this.form.appletTemplateId = item.templateId
      this.form.appletTemplateName = item.templateName
      this.form.appletRemindContent = item.templateContent
    },
    //短信传值
    messageontemplate(item) {
      this.form.messageTemplateId = item.templateId
      this.form.messageTemplateName = item.templateName
      this.form.messagePreview = item.templateContent
    },
    //公众号传值
    officialAccountontemplate(item) {
      this.form.officialTemplateId = item.templateId
      this.form.officialTemplateName = item.templateName
      this.form.officialRemindContent = item.templateContent
    },
    //问卷传值
    questionontemplate(item) {
      this.form.templateId = item.templateId
      this.form.templateName = item.templateName
    },
    // 短信
    messageontemplateMESSAGE(item) {
      this.form.phoneMessageTemplateId = item.templateId;
      this.form.phoneMessageTemplateName = item.templateName;
      this.form.messagePreview = item.templateContent;
    },
    // 话术
    messageontemplateword(item) {
      this.form.phoneTemplateId = item.templateId;
      this.form.phoneTemplateName = item.templateName;
      // this.form.messagePreview = item.templateContent;
    },
    //宣教传值
    propagandaontemplate(item) {
      this.form.templateId = item.templateId
      this.form.templateName = item.templateName
    },
    bottomclickevent(uitem, index, uindex) {
      if (
        this.form.taskNodeType != "QUESTIONNAIRE_SCALE" &&
        this.form.taskNodeType != "PROPAGANDA_ARTICLE"
      ) {
        this.$refs.wangeditor.emit();
      }
      setTimeout(() => {
        this.form = uitem;
        this.taskPartitionList = [];
        if (this.form.taskType) {
          this.changeTaskType(this.form.taskType, this.form.taskSubdivision);
        }
        this.listindex = index;
        this.itemindex = uindex;
      }, 150);
    },
    handleStep() {
      this.active = 2
    },
    //任务类型 任务状态
    taskinfo() {
      selectTaskTypeList().then(res => {
        this.selectTaskTypeList = res.data
        this.info();
      })
    },
    //任务细分
    changeTaskType(code, taskSubdivision) {
      let id = this.selectTaskTypeList?.find(e => e.taskTypeCode == code)?.id
      this.form.taskTypeName = this.selectTaskTypeList?.find(e => e.taskTypeCode == code)?.taskTypeName
      taskPartitionList(id).then(res => {
        this.taskPartitionList = res.data
        this.form.taskSubdivision = ''
        this.form.taskSubdivisionName = ''
        this.form.taskNodeType = ''
        if (taskSubdivision) {
          this.form.taskSubdivision = taskSubdivision
          this.changetaskSubdivision(taskSubdivision, 1)
        }
      })
    },
    //点击任务细分
    changetaskSubdivision(code, type) {
      this.form.taskSubdivisionName = this.taskPartitionList?.find(e => e.taskPartitionCode == code)?.taskPartitionName
      let id = this.taskPartitionList?.find(e => e.taskPartitionCode == code)?.id
      taskStatusDictList(id).then(res => {
        this.taskStatusDictList = res.data
      })
      this.taskPartitionList.forEach(el => {
        if (code == el.taskPartitionCode) {
          this.form.executionTime = el.executionTime
          this.form.taskNodeType = el.taskNodeType
          if (!type) {
            this.form.templateId = ''
            this.form.templateName = ''
          }
        }
      })
    },
    addlist() {
      list(this.parentDictCode).then((res) => {
        // this.parentDictCodelist = res.rows;
        res.rows.forEach((e) => {
          this.lists.forEach((el) => {
            el.routeNodeName = e.dictLabel;
          });
        });
      });
      this.lists.push({
        routeNodeName: "",
        routeNodeDay: "",
        list: [
          {
            nodeContent: "<p></p>",
            templateId: "",
            templateName: "",
            taskType: "",
            officialRemindContent: "",
            taskSubdivision: "",
            taskSubdivisionName: "",
            appletRemindContent: "",
            appletPromptDescription: "",
            taskStatus: "",
            secondClassifyDescribe: "",
            executionTime: "",
            appletPushSign: "0",
            officialPushSign: "0",
            messagePushSign: "0",
            messagePreview: "",
            taskNodeType: "",
          },
        ],
      });
    },
    additem(item) {
      item.list.push({
        nodeContent: '<p></p>',
        templateId: '',
        templateName: '',
        taskType: '',
        officialRemindContent: '',
        taskSubdivision: '',
        taskSubdivisionName: '',
        taskStatus: '',
        secondClassifyDescribe: '',
        executionTime: '',
        appletPushSign: '0',
        officialPushSign: '0',
        messagePushSign: '0',
        appletRemindContent: '',
        appletPromptDescription: '',
        messagePreview: '',
        taskNodeType: '',
      })
    },
    delitem(item, index) {
      item.list.splice(this.itemindex, 1)
      if (item.list.length == 0) {
        this.lists.splice(index, 1)
      }
    },
    //取消
    handleClose() {
      this.dialogVisible = false
      this.routeform = {
        routeCheckStatus: '',
        routeCheckRemark: "",
      }
      this.resetForm("routeform");
    },
    //审核
    auditing() {
      this.$refs["routeform"].validate(valid => {
        if (valid) {
          const loading = this.$loading({
            lock: true,
            text: '审核中',
            spinner: 'el-icon-loading',
            background: 'rgba(0, 0, 0, 0.7)'
          });
          updateRouteCheckStatus({
            routeCheckStatus: this.routeform.routeCheckStatus,
            id: this.form.specialDiseaseNodeId,
            routeCheckRemark: this.routeform.routeCheckRemark,
            routeCheckPerson: JSON.parse(localStorage.getItem('user')).nickName
          }).then(res => {
            if (res.data == 1) {
              this.info();
              this.handleClose()
              this.$modal.msgSuccess("审核成功!");
              loading.close();
            }
          })
        }
      })
    },
  }
};
</script>
<style scoped lang="scss">
::v-deep iframe {
  width: 100%;
  height: 500px;
}

::v-deep .el-card__body {
  position: relative;
}

::v-deep .el-input__inner {
  color: black !important;
  background-color: #fff !important;
  cursor: default !important;
}

.propaganda {
  background: #fff;

  .titletop {
    font-size: 16px;
    font-weight: 700;
    margin-left: 30px;
  }

  .bodytop {
    position: relative;
    top: 20px;
    // height: 500px;
    // overflow: auto;
    // border: 1px solid #e2e2e2;

    .titledata {
      margin: 30px 0px 15px 30px;
      top: 14px;
      font-size: 20px;
    }

    .audiotop {
      margin: 10px 0px 10px 30px;
    }

    img {
      // width: 100%;
      // width: 362px;
      // height: 127px;
      margin: 0px 0px 0px 30px;
    }

    .know {
      margin: 11px 0px 10px 30px;
      font-size: 16px;
    }

    .knowlist {
      margin: 10px 0px 10px 30px;
      font-size: 16px;
    }
  }
}

.routeCheckStatus {
  position: absolute;
  right: 10px;
  top: 30px;
}

.dialog-footer {
  padding: 0 20px 0;
  text-align: right;
}

.bottomform {
  background-color: #f2f4f5;
  margin-top: 10px;

  .card {
    pointer-events: none;
    background-color: #fff;
    width: 100%;
    height: 200px;
    margin: 20px 0 0;
    padding: 20px 50px 0px 20px;

    .flextwo {
      margin-top: 20px;

      .text {
        font-size: 13px;
        color: #64666a;
      }

      ::v-deep .el-input__inner {
        color: black !important;
        background-color: #fff !important;
        cursor: default !important;
      }

      .textarea {
        width: 90%;
        padding: 0 10px;
        height: 50px;
        line-height: 50px;
        // border: 1px solid #DCDFE6;
        border-radius: 5px;
        display: flex;
        align-items: center;

        ::v-deep .el-input {
          padding: 0 10px;
          width: 50%;
          color: black;
          font-size: 13px;
          height: 40px;
          line-height: 40px;
        }

        ::v-deep .el-input__inner {
          color: black;
          font-size: 13px;
        }
      }
    }

    .flex {
      display: flex;
      width: 100%;
      align-items: center;
      // background: red;
      justify-content: space-between;

      .pushMethod {
        height: 30px;
        margin-top: 30px;
        line-height: 30px;
        font-size: 13px;
        color: #64666a;

        .spanname {
          pointer-events: none;
        }

        ::v-deep .el-input__inner {
          color: black;
          font-size: 13px;
        }

        span {
          color: black;
          font-size: 13px;
        }
      }
    }
  }
}

.topform {
  pointer-events: none;

  padding: 15px 0 0 15px;

  .form {
    ::v-deep .el-input__inner {
      height: 30px !important;
      line-height: 30px !important;
    }

    ::v-deep .el-form-item__label {
      font-size: 12px !important;
    }
  }
}

.title {
  display: flex;
  align-items: center;

  div {
    display: flex;
    padding-left: 10px;
    font-weight: 600;
    align-items: center;
  }

  .select {
    font-weight: 550;
    margin-left: 20%;
    font-size: 12px;

    .el-input {
      width: 200px;
      height: 30px !important;
      line-height: 30px !important;
    }
  }
}

.list {
  margin: 20px auto;
  width: 100%;
  background-color: #f2f4f5;
  display: flex;
  padding-top: 15px;
  justify-content: space-evenly;

  .timelist {
    width: 22%;
    background-color: #fff;
    padding: 0 20px 20px;
    // height: 680px;
    height: calc(100vh - 294px);
    overflow: scroll;

    .timetitle {
      height: 60px;
      display: flex;
      align-items: center;
      justify-content: space-between;
    }

    ::v-deep .el-timeline {
      width: 100%;
      padding: 15px 0 0 !important;
    }
  }

  .texts {
    width: 75%;
    // height: 680px;
    height: calc(100vh - 294px);
    overflow: scroll;
    background-color: #fff;
  }
}

.cards {
  border: 1px solid #409eff;
  border-left: 5px solid #409eff;
}

.top {
  display: flex;
  justify-content: space-between;
  align-items: center;

  .toptop {
    display: flex;
    align-items: center;
  }

  span {
    padding: 0 4px;
  }

  i {
    font-size: 17px;
  }

  i:nth-child(2) {
    padding-left: 12px;
  }
}

::v-deep .el-timeline-item__timestamp {
  margin: 0 !important;
  padding: 0 !important;
}

::v-deep .el-timeline-item__wrapper {
  padding-left: 14px !important;
}

::v-deep .el-timeline-item__content {
  transform: translateY(-2%);
}

::v-deep .el-card {
  margin-top: 20px !important;
}
</style>
