WXL (wul)
6 天以前 fb34ba28cb908bd328cf6690ab0b19a56428f4e2
src/main.js
@@ -51,6 +51,7 @@
import {
  parseTime,
  formatTime,
  followupAuthority,
  resetForm,
  addDateRange,
  selectDictLabel,
@@ -111,6 +112,7 @@
Vue.prototype.formatTime = formatTime;
Vue.prototype.daysBetween = daysBetween;
Vue.prototype.resetForm = resetForm;
Vue.prototype.followupAuthority = followupAuthority;
Vue.prototype.addDateRange = addDateRange;
Vue.prototype.selectDictLabel = selectDictLabel;
Vue.prototype.selectDictLabels = selectDictLabels;
@@ -150,6 +152,19 @@
Vue.config.productionTip = false;
// 全局注入机构判断(省立同德系列 / 纯省立同德院区)。
// 所有组件无需单独注册 computed,模板与 this 中可直接使用 isTongdeOrg / isTongdeCampus
Vue.mixin({
  computed: {
    isTongdeOrg() {
      return this.$store.getters.isTongdeOrg; // 是否省立同德系列院区(含南华大学附属第一医院)
    },
    isTongdeCampus() {
      return this.$store.getters.isTongdeCampus;// 是否纯省立同德院区(不含南华大学附属第一医院)
    },
  },
});
new Vue({
  el: "#app",
  router,