 <template>
  <div
    class="main"
    v-loading="loading"
    element-loading-text="拼命加载中"
    element-loading-spinner="el-icon-loading"
    element-loading-background="rgba(0, 0, 0, 0.8)"
  >
     <iframe :src="pdfUrl" frameborder="0" height="100%" width="100%"></iframe>
  </div>
</template>

<script>
import { getReportUrl } from "@/request/timeline.js";

export default {
  props: ["operationId", "id"],
  data() {
    return {
      pdfUrl: "",
      anesthesiaFlagFrom: {},
      loading: true,
    };
  },
  async created() {
    let res = await getReportUrl(this.id, this.operationId);
    this.pdfUrl = res.data;
    this.loading = false;
  },
};
</script>

<style lang="less" scoped>
.main {
  background: #e6e7ec;
  height: 100%;
  position: relative;
  display: flex;
  justify-content: space-between;
}
</style>