Mr.Zhang
2023-08-22 e37485d41550b3e7e22423875d31401a8470e0b7
screen_standard/src/components/AppLayout.vue
@@ -55,8 +55,9 @@
import { getAssets } from '@/utils'
import { getDepartmentList } from '@/utils/apis.js'
import { reactive, toRefs, ref, onMounted } from 'vue';
import { useCounterStore } from '@/stores/counter.js'
import { RouterView } from 'vue-router'
const enterprise = useCounterStore()
const layoutList = [
  { bgImg: 'bg_zhixingzhong@2x.png', name: '执行中计划数(个)', logo: 'ic_zhixingzhong@2x.png' },
  { bgImg: 'bg_yanqijihua@2x.png', name: '延期计划数(个)', logo: 'ic_yanqijihua@2x.png' },
@@ -64,6 +65,7 @@
  { bgImg: 'bg_jinrishebei@2x.png', name: '今日生产设备(台)', logo: 'ic_jinrishebei@2x.png' },
  { bgImg: 'bg_jinribuliang@2x.png', name: '今日不良品率(%)', logo: 'ic_jinribuliang@2x.png' },
]
const data = reactive({
  tempCom: { name: '豆米科技' },
  isFull: false,
@@ -78,7 +80,9 @@
let { tempCom, isFull, tempDate, comList } = toRefs(data)
const selectCom = (item, index) => {
  console.log(item);
  data.tempCom = item
  enterprise.setDepartId(data.tempCom.id)
}
const fullChange = () => {
@@ -110,10 +114,11 @@
}
onMounted(() => {
  getDepartmentList(8)
  getDepartmentList(enterprise.companyId)
    .then(res => {
      data.comList = res
      data.tempCom = res[0]
      enterprise.setDepartId(data.tempCom.id)
    })
    .catch(err => {})
  const week = ['星期一', '星期二', '星期三', '星期四', '星期五', '星期六', '星期日',]