浏览代码

公共方法、属性文件

DESKTOP-O04BTUJ\muzen 3 年之前
父节点
当前提交
41f8a80828
共有 1 个文件被更改,包括 25 次插入0 次删除
  1. 25 0
      src/mixin/index.js

+ 25 - 0
src/mixin/index.js

@@ -0,0 +1,25 @@
+import {
+  getClientTypeList
+} from '@/api/device/version'
+
+const devMixin = {
+  data() {
+    return {
+      devOptions: []
+    }
+  },
+  mounted() {
+    getClientTypeList().then(res => {
+      if (res.code === 0) {
+        res.data.map(i => {
+          this.devOptions.push({
+            value: i.clientTypeId,
+            label: i.name
+          })
+        })
+      }
+    })
+  },
+}
+
+export { devMixin }