scorpio 2 years ago
parent
commit
bef052d06b
2 changed files with 49 additions and 3 deletions
  1. 44 0
      src/components/area-picker/index.vue
  2. 5 3
      src/views/project/componens/info1.vue

+ 44 - 0
src/components/area-picker/index.vue

@@ -0,0 +1,44 @@
+<template>
+  <div class="full-width">
+    <avue-input-tree
+      v-model="form"
+      placeholder="请选择内容"
+      :dic="dic"
+    ></avue-input-tree>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      form: {},
+      dic: [
+        {
+          label: '选项1',
+          value: 0,
+          children: [
+            {
+              label: '选项3',
+              value: 2
+            },
+            {
+              label: '选项4',
+              value: 3
+            }
+          ]
+        },
+        {
+          label: '选项2',
+          value: 1
+        }
+      ]
+    }
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+:deep(.el-input) {
+}
+</style>

+ 5 - 3
src/views/project/componens/info1.vue

@@ -24,8 +24,8 @@
         </el-form-item>
         <el-form-item class="full-width flex-child-average">
           <div class="flex flex-center full-width item">
-            <span class="title">区:</span>
-            <el-input placeholder="请选择区县"></el-input>
+            <span class="title">区:</span>
+            <area-picker class="light-green-bg" />
           </div>
         </el-form-item>
       </div>
@@ -120,10 +120,12 @@
 
 <script>
 import wtCard from '@/components/wt-card/index.vue'
+import areaPicker from '@/components/area-picker/index.vue'
 
 export default {
   components: {
-    wtCard
+    wtCard,
+    areaPicker
   },
   props: {
     info: {