Bläddra i källkod

客运站g关联表修改

wsp 1 år sedan
förälder
incheckning
e5ac20cd2a

+ 4 - 0
components.d.ts

@@ -25,6 +25,7 @@ declare module 'vue' {
     ElFormItem: typeof import('element-plus/es')['ElFormItem']
     ElHeader: typeof import('element-plus/es')['ElHeader']
     ElIcon: typeof import('element-plus/es')['ElIcon']
+    ElImage: typeof import('element-plus/es')['ElImage']
     ElInput: typeof import('element-plus/es')['ElInput']
     ElMain: typeof import('element-plus/es')['ElMain']
     ElMenu: typeof import('element-plus/es')['ElMenu']
@@ -37,7 +38,10 @@ declare module 'vue' {
     ElSwitch: typeof import('element-plus/es')['ElSwitch']
     ElTable: typeof import('element-plus/es')['ElTable']
     ElTableColumn: typeof import('element-plus/es')['ElTableColumn']
+    ElTabPane: typeof import('element-plus/es')['ElTabPane']
+    ElTabs: typeof import('element-plus/es')['ElTabs']
     ElTimePicker: typeof import('element-plus/es')['ElTimePicker']
+    ElUpload: typeof import('element-plus/es')['ElUpload']
     HelloWorld: typeof import('./src/components/HelloWorld.vue')['default']
     IconCommunity: typeof import('./src/components/icons/IconCommunity.vue')['default']
     IconDocumentation: typeof import('./src/components/icons/IconDocumentation.vue')['default']

+ 1 - 1
index.html

@@ -4,7 +4,7 @@
     <meta charset="UTF-8">
     <link rel="icon" href="/favicon.ico">
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
-    <title>车辆调度管理系统</title>
+    <title>定制班车管理系统</title>
   </head>
   <body>
     <div id="app"></div>

+ 5 - 5
src/request/api.js

@@ -244,7 +244,7 @@ export const apisystemdzbcOrderUpdate = query => {
 
 
 
-//查询定制班车-客运列表https://khy.xiaole.vip/api/system/dzbcKyz/list
+//查询定制班车-客运公司列表https://khy.xiaole.vip/api/system/dzbcKyz/list
 
 export const  apisystemdzbcKyzlist = query => {
     return service({
@@ -254,7 +254,7 @@ export const  apisystemdzbcKyzlist = query => {
     });
 };
 
-//导出定制班车-客运列表https://khy.xiaole.vip/api/system/dzbcKyz/export
+//导出定制班车-客运公司列表https://khy.xiaole.vip/api/system/dzbcKyz/export
 export const  apisystemdzbcKyzexport = query => {
     return service({
         url: '/api/system/dzbcKyz/export',
@@ -264,7 +264,7 @@ export const  apisystemdzbcKyzexport = query => {
     });
 };
 
-//新增定制班车-客运https://khy.xiaole.vip/api/system/dzbcKyz
+//新增定制班车-客运公司https://khy.xiaole.vip/api/system/dzbcKyz
 export const  apisystemdzbcKyzAdd = query => {
     return service({
         url: `/api/system/dzbcKyz`,
@@ -273,7 +273,7 @@ export const  apisystemdzbcKyzAdd = query => {
     });
 };
 
-//删除定制班车-客运https://khy.xiaole.vip/api/system/dzbcKyz/{ids}
+//删除定制班车-客运公司https://khy.xiaole.vip/api/system/dzbcKyz/{ids}
 export const  apisystemdzbcKyzDel = query => {
     return service({
         url: `/api/system/dzbcKyz/${query.id}`,
@@ -281,7 +281,7 @@ export const  apisystemdzbcKyzDel = query => {
     });
 };
 
-//修改定制班车-客运https://khy.xiaole.vip/api/system/dzbcKyz
+//修改定制班车-客运公司https://khy.xiaole.vip/api/system/dzbcKyz
 export const apisystemdzbcKyzUpdate = query => {
     return service({
         url: `/api/system/dzbcKyz`,

+ 3 - 3
src/views/HomeView.vue

@@ -49,7 +49,7 @@ let filterName=computed(()=>{
       res='订单管理'
       break;
     case '/passengerstation':
-      res='客运管理'
+      res='客运公司管理'
       break;
     case '/roleman':
       res='角色管理'
@@ -106,7 +106,7 @@ watch(() => route, (newRoute, oldRoute) => {
           placeholder="搜索菜单..."
           :suffix-icon="Search"
         /> -->
-        车辆调度管理系统
+        定制班车管理系统
         </div>
         <el-menu
        
@@ -187,7 +187,7 @@ watch(() => route, (newRoute, oldRoute) => {
           <div class="ima-icon">
             <img style="width:12px;height:auto" src="../../public/imgs/orderman.png" alt="">
           </div>
-          <span style="flex:1">客运管理</span>
+          <span style="flex:1">客运公司管理</span>
           <div class="next-img">
             <el-icon><ArrowRightBold /></el-icon>
           </div>

+ 5 - 41
src/views/areaman/index.vue

@@ -147,21 +147,7 @@ const getTableData=()=>{
   }).then(res=>{
     if(res.code==200){
       total.value=res.total
-      tableData.value=res.rows.map(item=>{
-        let data=passengerstation.value.filter(kyz=>{
-          return item.kyzId==kyz.id
-          
-        })[0]
-
-       
-
-        if(data){
-          item.kyzName=data.name
-        }
-
-        return item
-        
-      })
+      tableData.value=res.rows
     }
     loading.value=false
     
@@ -184,13 +170,8 @@ const deleteItem=(id)=>{
 }
 let passengerstation=ref([])
 onMounted(()=>{
- 
-  apisystemdzbcKyzlist({}).then((res:any)=>{
-    passengerstation.value=res.rows
-    getTableData()
-  }).catch((err:any)=>{
-    console.log(err)
-  })
+  getTableData()
+  
 })
 
 
@@ -240,7 +221,7 @@ onMounted(()=>{
                         
                         </el-table-column>
                        
-                        <el-table-column prop="kyzName" label="所属客运站" />
+                        
                         <el-table-column prop="remark" label="备注" />
                         <el-table-column fixed="right" label="操作" min-width="120">
                           <template #default="scope">
@@ -305,24 +286,7 @@ onMounted(()=>{
             </el-col>
            
            
-            <el-col :span="12">
-              <el-form-item label="所属客运站">
-                <el-select
-                  v-model="ruleForm.kyzId"
-                  placeholder="所属客运站"
-                  
-                  style="width: 100%"
-                >
-                  <el-option
-                    v-for="item in passengerstation"
-                    :key="item.value"
-                    :label="item.name"
-                    :value="item.id"
-                  />
-                </el-select>
-               
-              </el-form-item>
-            </el-col>
+           
             <el-col :span="24">
               <el-form-item label="经纬度">
                 <el-input placeholder="经纬度" v-model="ruleForm.location" />

+ 42 - 3
src/views/carman/index.vue

@@ -1,5 +1,5 @@
 <script setup lang="ts">
-import { apisystemuserlist,apisystemdzbcCarlist,apisystemdzbcCarexport,apisystemdzbcCarDel,apisystemdzbcCarAdd,apisystemdzbcCarUpdate } from '../../request/api.js'
+import { apisystemdzbcKyzlist,apisystemuserlist,apisystemdzbcCarlist,apisystemdzbcCarexport,apisystemdzbcCarDel,apisystemdzbcCarAdd,apisystemdzbcCarUpdate } from '../../request/api.js'
 import type { ComponentSize, FormInstance, FormRules } from 'element-plus'
 import { ElMessage } from 'element-plus'
 interface RuleForm {
@@ -161,6 +161,21 @@ const getTableData=()=>{
           item.nickName=data.nickName
         }
 
+
+        let kyzdata=kyzList.value.filter(kyz=>{
+          return item.kyzId==kyz.id
+          
+        })[0]
+
+       
+
+        if(kyzdata){
+          item.kyzName=kyzdata.name
+        }
+
+
+
+
         return item
         
       })
@@ -185,6 +200,7 @@ const deleteItem=(id)=>{
   })
 }
 let sijiList=ref([])
+let kyzList=ref([])
 onMounted(()=>{
  
   apisystemuserlist({
@@ -194,6 +210,12 @@ onMounted(()=>{
     if(res.code==200){
       
       sijiList.value=res.rows
+      apisystemdzbcKyzlist({}).then((res:any)=>{
+        kyzList.value=res.rows
+        
+      }).catch((err:any)=>{
+        console.log(err)
+      })
       getTableData()
     }
    
@@ -247,7 +269,7 @@ onMounted(()=>{
                     <el-table element-loading-text='加载中' header-row-class-name="reset-gray-head" :data="tableData"  style="width: 100%" v-loading="loading">
                         <el-table-column prop="carNum" label="车牌号" />
                         <el-table-column prop="carZw" label="座位数" />
-                       
+                        <el-table-column prop="kyzName" label="所属客运公司" />
                         <el-table-column prop="driverId" label="司机">
                           <template #default="scope">
                           <div class="table-user-wrap">
@@ -336,7 +358,24 @@ onMounted(()=>{
               </el-form-item>
             </el-col>
 
-            
+             <el-col :span="12">
+              <el-form-item label="所属客运公司">
+                <el-select
+                  v-model="ruleForm.kyzId"
+                  placeholder="所属客运公司"
+                  
+                  style="width: 100%"
+                >
+                  <el-option
+                    v-for="item in kyzList"
+                    :key="item.value"
+                    :label="item.name"
+                    :value="item.id"
+                  />
+                </el-select>
+               
+              </el-form-item>
+            </el-col>
            
             <el-col :span="12">
               <el-form-item label="司机">

+ 1 - 1
src/views/home/index.vue

@@ -77,7 +77,7 @@ onMounted(()=>{
 <template>
     <div>
         <div class="title">
-            欢迎使用车辆调度管理系统
+            欢迎使用定制班车管理系统
         </div>
         <div class="sub-title">
             请从左侧菜单选择要管理的功能模块

+ 1 - 1
src/views/login/index.vue

@@ -101,7 +101,7 @@ onMounted(()=>{
     
         <div class="ms-login">
             <div class="right">
-                <div class="ms-title">车辆调度管理系统</div>
+                <div class="ms-title">定制班车管理系统</div>
                 <div style="padding-bottom:20px">
                     请登录以继续使用
                 </div>

+ 10 - 2
src/views/orderman/index.vue

@@ -299,10 +299,18 @@ onMounted(()=>{
                           </template>
                         </el-table-column>
                         <el-table-column prop="price" label="单价">
-                         
+                          <template #default="scope">
+                            <div>
+                              {{ scope.row.price/100 }}
+                            </div>
+                          </template>
                         </el-table-column>
                         <el-table-column prop="totalPrice" label="总价">
-                         
+                          <template #default="scope">
+                            <div>
+                              {{ scope.row.totalPrice/100 }}
+                            </div>
+                          </template>
                         </el-table-column>
                         
                     </el-table>

+ 7 - 7
src/views/passengerstation/index.vue

@@ -132,7 +132,7 @@ const downExcell=()=>{
     const link = document.createElement('a');
     link.href = url;
     // 把获得的blob的对象链接赋值给新创建的这个 a 链接
-    link.setAttribute('download', '客运列表.xls'); // 设置下载文件名
+    link.setAttribute('download', '客运公司列表.xls'); // 设置下载文件名
     document.body.appendChild(link);
     // 使用js点击这个链接
     link.click();
@@ -190,14 +190,14 @@ onMounted(()=>{
        <div class="common-top">
         <div class="left-part">
           <div class="title">
-            客运管理
+            客运公司管理
           </div>
           <div class="sub-title">
             
           </div>
         </div>
         <div class="right-part">
-          <el-button type="primary" :icon="Plus" @click="addItem({})">新增客运  </el-button>
+          <el-button type="primary" :icon="Plus" @click="addItem({})">新增客运公司  </el-button>
         </div>
        </div>
 
@@ -207,7 +207,7 @@ onMounted(()=>{
                         <el-input
                           v-model="name"
                          
-                          placeholder="搜索客运..."
+                          placeholder="搜索客运公司..."
                           style="width:260px"
                         >
                         
@@ -226,7 +226,7 @@ onMounted(()=>{
                       </div>
                     </div>
                     <el-table element-loading-text='加载中' header-row-class-name="reset-gray-head" :data="tableData"  style="width: 100%" v-loading="loading">
-                        <el-table-column prop="name" label="客运名称" />
+                        <el-table-column prop="name" label="客运公司名称" />
                         <el-table-column prop="addr" label="地址" />
                        
                         <el-table-column prop="contactName" label="联系人">
@@ -298,8 +298,8 @@ onMounted(()=>{
         >
           <el-row :gutter="20">
             <el-col :span="12">
-              <el-form-item label="客运名称" prop="name">
-                <el-input placeholder="客运名称" v-model="ruleForm.name" />
+              <el-form-item label="客运公司名称" prop="name">
+                <el-input placeholder="客运公司名称" v-model="ruleForm.name" />
               </el-form-item>
             </el-col>
             <el-col :span="12">