From 74e563da7fa6886449fd2be5933e2d4ca5c85f48 Mon Sep 17 00:00:00 2001
From: jack <jack.su@pollex.com.tw>
Date: 星期二, 12 九月 2023 11:25:52 +0800
Subject: [PATCH] [UPDATE] 解決弱點Se: Incorrect definition of Serializable class [UPDATE] 解決弱點Information exposure to log file [UPDATE] 解決弱點Use of hard-coded password

---
 PAMapp/components/AddressPicker.vue |   59 +++++++++++++++++++++++++++++++++++------------------------
 1 files changed, 35 insertions(+), 24 deletions(-)

diff --git a/PAMapp/components/AddressPicker.vue b/PAMapp/components/AddressPicker.vue
index ecf7975..95314fa 100644
--- a/PAMapp/components/AddressPicker.vue
+++ b/PAMapp/components/AddressPicker.vue
@@ -1,38 +1,52 @@
 <template>
     <div class="text--center">
-        <div class="subTitle mb-10">������</div>
-        <el-input
-            type="text"
-            class="p mt-10"
-            v-model="keyWord"
-            @change="searchDistrict"
-            placeholder="隢撓���摮�"
-        ></el-input>
-        <Ui-ScrollPicker
-            :options="filterOptions"
-            :initValue="district"
-            @change="selectDistrict"
-        ></Ui-ScrollPicker>
-        <div class="text--center mt-10">
-            <el-button type="primary" @click="confirm">蝣箄��</el-button>
-        </div>
+      <div class="subTitle mb-10">�����</div>
+      <el-input
+          type="text"
+          class="p mt-10 cursor--pointer input-radius"
+          tabindex="-1"
+          v-model="keyWord"
+          @input="searchDistrict"
+          placeholder="隢撓���摮�"
+      ></el-input>
+      <Ui-ScrollPicker
+          :options="filterOptions"
+          :initValue="district"
+          @change="selectDistrict"
+      ></Ui-ScrollPicker>
+      <div class="text--center mt-10">
+          <el-button type="primary" @click="confirm">蝣箄��</el-button>
+      </div>
     </div>
 </template>
 
 <script lang="ts">
 import { Vue, Component, Emit } from 'nuxt-property-decorator';
 
+import { taiwanCities } from '~/shared/const/taiwan-cities';
+
 @Component
 export default class AddressPicker extends Vue {
 
-    options = ['�����', '�����', '�����', '獢�腦', '�蝡孵��', '�蝡寧腦', '���腦', '�銝剖��', '敶啣�腦', '���腦', '���腦', '��儔撣�', '��儔蝮�', '�����', '擃���', '撅蝮�', '��蝮�', '��蝮�', '摰蝮�', '瞉�腦', '���蝮�', '��瘙腦'];
-    keyWord = '';
+    options      : string[] = taiwanCities;
+    keyWord      : string   = '';
     filterOptions: string[] = [];
-    district = '�����';
+    district     : string   = '�����';
+
+    //////////////////////////////////////////////////////////////////////
 
     mounted() {
         this.filterOptions = JSON.parse(JSON.stringify(this.options));
     }
+
+    //////////////////////////////////////////////////////////////////////
+
+    @Emit('confirm')
+    confirm(): string {
+        return this.district;
+    }
+
+    //////////////////////////////////////////////////////////////////////
 
     searchDistrict() {
         this.filterOptions = this.options.filter(e => e.match(this.keyWord));
@@ -42,10 +56,7 @@
         this.district = value;
     }
 
-    @Emit('confirm')
-    confirm() {
-        return this.district;
-    }
+
 
 }
 </script>
@@ -54,4 +65,4 @@
     .cus-input {
         font-size: 20px;
     }
-</style>
\ No newline at end of file
+</style>

--
Gitblit v1.8.0