"use strict";
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
const Vue = require("vue");
;/* empty css                */
const _pluginVue_exportHelper = require("../../../../../../_virtual/_plugin-vue_export-helper.js");
const _sfc_main = {
  __name: "AppDetail",
  props: {
    params: {
      type: Object,
      default: {}
    },
    baseInfoPageSource: {
      type: String,
      default: "dynamic"
    },
    baseInfoPageId: {
      type: String,
      default: ""
    },
    options: {
      type: Array,
      default: []
    },
    document: {
      type: Boolean,
      default: false
    },
    approvalHistory: {
      type: Boolean,
      default: false
    },
    actionBar: {
      type: Object
    },
    taskId: {
      type: String,
      default: ""
    },
    taskType: {
      type: String,
      default: ""
    }
  },
  setup(__props) {
    const props = __props;
    const currentInstance = Vue.getCurrentInstance();
    const ctx = currentInstance.proxy;
    ctx.route;
    const activeName = Vue.ref("tab_base_info");
    const baseInfoPageId = Vue.ref("");
    if (props.baseInfoPageSource == "dynamic") ;
    else {
      baseInfoPageId.value = props.baseInfoPageId;
    }
    const tabsOptions = Vue.computed(() => {
      const tabs = [
        {
          id: "tab_base_info",
          title: "基本信息",
          pageId: baseInfoPageId.value
        },
        ...props.options || []
      ];
      if (props.document) {
        tabs.push({ id: "tab_doc_info", title: "要件信息" });
      }
      if (props.approvalHistory) {
        tabs.push({ id: "tab_timeline_info", title: "审批历史" });
      }
      return tabs;
    });
    Vue.computed(() => {
      return tabsOptions.value.find((item) => item.id == activeName.value);
    });
    return (_ctx, _cache) => {
      const _component_FecMobileTabs = Vue.resolveComponent("FecMobileTabs");
      const _component_FecMobileApprovalBar = Vue.resolveComponent("FecMobileApprovalBar");
      return Vue.openBlock(), Vue.createElementBlock(Vue.Fragment, null, [
        Vue.createVNode(_component_FecMobileTabs, {
          modelValue: Vue.unref(activeName),
          "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => Vue.isRef(activeName) ? activeName.value = $event : null),
          options: Vue.unref(tabsOptions),
          params: __props.params
        }, null, 8, ["modelValue", "options", "params"]),
        __props.actionBar ? (Vue.openBlock(), Vue.createBlock(_component_FecMobileApprovalBar, Vue.normalizeProps(Vue.mergeProps({ key: 0 }, __props.actionBar)), null, 16)) : Vue.createCommentVNode("", true)
      ], 64);
    };
  }
};
const _AppDetail = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-ab2095bf"]]);
exports.default = _AppDetail;
