From 92146b2ca987538074c380f07f567ca85347dd13 Mon Sep 17 00:00:00 2001
From: kongdeqiang <123456>
Date: 星期一, 06 一月 2025 14:17:39 +0800
Subject: [PATCH] feat: 新增月租车页面

---
 src/components/page/park/index.vue |   32 +++++++++++++++++++++++---------
 1 files changed, 23 insertions(+), 9 deletions(-)

diff --git a/src/components/page/park/index.vue b/src/components/page/park/index.vue
index e78239a..769c778 100644
--- a/src/components/page/park/index.vue
+++ b/src/components/page/park/index.vue
@@ -5,18 +5,24 @@
                 <!--<el-form-item label="鍚嶇О">-->
                     <!--<el-input v-model="searchForm.name"></el-input>-->
                 <!--</el-form-item>-->
+              <el-form-item label="鍋滆溅鍦�">
+                <el-select v-model="searchForm.id" clearable>
+                  <el-option v-for="item in table1" :key="item.id" :label="item.name" :value="item.id" ></el-option>
+                </el-select>
+              </el-form-item>
                 <el-form-item>
-                    <!--<el-button type="primary" size="small" @click="onSearch" icon="el-icon-search">鏌ヨ</el-button>-->
-                    <el-button type="primary" size="small" @click="onAdd" icon="el-icon-plus">澧炲姞</el-button>
+                   <el-button type="primary" size="small" @click="onSearch" icon="el-icon-search">鏌ヨ</el-button>
+                    <el-button type="primary" size="small" @click="onAdd" icon="el-icon-plus">鏂板</el-button>
                 </el-form-item>
             </el-form>
         </div>
 
         <el-table :data="pageData.rows" v-loading="pageData.isLoading" border style="width:100%;border:1px solid #bcbec2;">
             <el-table-column type="index" width="50" label="搴忓彿" align="center"> </el-table-column>
-            <el-table-column prop="name" label="鍋滆溅鍦哄悕绉�" align="center"></el-table-column>
+            <el-table-column prop="name" label="鍋滆溅鍦哄悕绉�" align="center" width="350"></el-table-column>
             <el-table-column prop="code" label="缂栧彿" align="center" width="80"></el-table-column>
-            <el-table-column prop="num" label="杞︿綅鏁伴噺" align="center" width="80"></el-table-column>
+            <el-table-column prop="num" label="璁″垝杞︿綅鏁伴噺" align="center" width="120"></el-table-column>
+            <el-table-column prop="carNum" label="鍦哄唴娉婅溅鏁伴噺" align="center" width="120"></el-table-column>
             <el-table-column prop="content" label="鎻忚堪" align="center"></el-table-column>
             <el-table-column label="鎿嶄綔" fixed="right" width="250" align="center">
                 <template slot-scope="scope">
@@ -72,8 +78,10 @@
             return {
                 flag:false,
                 flag2:false,
+                table1:[],
                 searchForm: {
-                    name: ''
+                    name: '',
+                    id:'',
                 },
                 pageData: this.$byutil.defaultPageData(),
                 formData: {
@@ -82,12 +90,13 @@
                     phone: '',
                     type: '',
                 },
-                urlPath:this.$systemconfig.basePath + '/park/',
+                urlPath:this.$systemconfig.basePath + '/ffzf/park/',
                 id:null,
             }
         },
         mounted() {
             this.loadData();
+            this.getAllPark();
         },
         methods: {
             onSave(){
@@ -96,7 +105,7 @@
                         this.$byutil.postData(this, this.urlPath+'save', this.formData, res => {
                             this.$refs['formData'].resetFields();
                             this.flag=false;
-                            this.$message({message: res.message, type: 'success'});
+                            this.$message({message: '淇濆瓨鎴愬姛', type: 'success'});
                             this.loadData();
                         })
                     } else {
@@ -110,6 +119,11 @@
             onSearch() {
                 this.pageData = this.$byutil.defaultPageData();
                 this.loadData();
+            },
+            getAllPark(){
+              this.$byutil.postData(this, this.$systemconfig.basePath+'/ffzf/park/findAll', {}, res => {
+                this.table1 = res.data;
+              })
             },
             onAdd() {
                 this.flag=true;
@@ -127,7 +141,7 @@
             },
             onDelete(index, row) {
                 this.$byutil.deleteData(this,this.urlPath+"delete",{id:row.id}, res => {
-                    this.$message({message: res.message, type: 'success'});
+                    this.$message({message: '鍒犻櫎鎴愬姛', type: 'success'});
                     this.loadData();
                 })
             },
@@ -150,4 +164,4 @@
 
 <style scoped>
 
-</style>
\ No newline at end of file
+</style>

--
Gitblit v1.9.1