Hwt 3 роки тому
батько
коміт
c457bdbf11

BIN
smart/src/assets/img/btn_peizhi.png


+ 1 - 1
smart/src/views/accessRecord/index.vue

@@ -40,7 +40,7 @@
     </div>
     <zz-table
       :cols="cols"
-      :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+      :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
       :data="mixins_list"
       :pageset="mixins_pageset"
       @page-change="pageChange"

+ 1 - 1
smart/src/views/channelManagement/index.vue

@@ -33,7 +33,7 @@
     </div>
     <zz-table
       :cols="cols"
-      :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+      :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
       :data="mixins_list"
       :pageset="mixins_pageset"
       @page-change="pageChange"

+ 1 - 1
smart/src/views/onSiteVehicles/index.vue

@@ -41,7 +41,7 @@
     </div>
     <zz-table
       :cols="cols"
-      :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+      :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
       :data="mixins_list"
       :pageset="mixins_pageset"
       @page-change="pageChange"

+ 1 - 1
smart/src/views/parkingManagement/index.vue

@@ -30,7 +30,7 @@
     </div>
     <zz-table
       :cols="cols"
-      :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+      :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
       :data="mixins_list"
       :pageset="mixins_pageset"
       @page-change="pageChange"

+ 1 - 1
smart/src/views/parkingSpaceManagement/parkingSpaceList.vue

@@ -66,7 +66,7 @@
     <div>
       <zz-table
         :cols="cols"
-        :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+        :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
         :data="mixins_list"
         :loading="mixins_onQuery"
         :pageset="mixins_pageset"

+ 8 - 8
smart/src/views/rechargeRecord/index.js

@@ -2,14 +2,14 @@ export default {
     data() {
         return {
             cols: [
-                // {
-                //     label: '车主名称',
-                //     prop: '11'
-                // },
-                // {
-                //     label: '手机号',
-                //     prop: '11'
-                // },
+                {
+                    label: '车主名称',
+                    prop: 'userName'
+                },
+                {
+                    label: '手机号',
+                    prop: 'tel'
+                },
                 {
                     label: '车牌号',
                     prop: 'fullCarNoStr'

+ 5 - 3
smart/src/views/rechargeRecord/index.vue

@@ -6,7 +6,7 @@
         placeholder="输入车牌号"
         class="search-input"
         clearable
-        v-model="mixins_query.plateNo "
+        v-model="mixins_query.plateNo"
       ></el-input>
       <el-select
         placeholder="停车场名称"
@@ -53,7 +53,7 @@
     </div>
     <zz-table
       :cols="cols"
-      :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+      :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
       :data="mixins_list"
       :pageset="mixins_pageset"
       @page-change="pageChange"
@@ -112,8 +112,10 @@ export default {
       this.parkName = name;
     },
     lookDetails () {
+      console.log(this.mixins_query)
       this.mixins_dataUrl = '/sc-community-web/parkingCar/queryChargeRecord';
-      this.mixins_query = { parkId: this.mixins_query.parkId, parkName: this.parkName };
+      this.mixins_query = { parkId: this.mixins_query.parkId, parkName: this.parkName, plateNo: this.mixins_query.plateNo };
+      console.log(this.mixins_query)
       this.mixins_search();
     },
     // 获取停车场名称

+ 1 - 1
smart/src/views/temporaryStopCharge/index.vue

@@ -54,7 +54,7 @@
     </div>
     <zz-table
       :cols="cols"
-      :settings="{ showCheckbox: true, showIndex: true, stripe: true }"
+      :settings="{ showCheckbox: false, showIndex: true, stripe: true }"
       :data="mixins_list"
       :pageset="mixins_pageset"
       @page-change="pageChange"

+ 9 - 5
smart/src/views/vehicleInformation/index.vue

@@ -150,6 +150,7 @@ export default {
       mixins_post: 'post',
       nameParkingLot: [],
       parkName: '',
+      comm: ''
     }
   },
   methods: {
@@ -180,6 +181,8 @@ export default {
     },
     add (row) {
       console.log(row.cardId);
+      debugger
+      this.comm = 'add'
       this.details(row.cardId);
     },
     parkingLot (name) {
@@ -188,7 +191,9 @@ export default {
     addCommand (command) {
       if (command === 'add') {
         // this.addOrEdit('add');
+        this.comm = '';
         this.details();
+
       }
       if (command === 'template') {
         // this.__exportExcel('/sc-community/excel/download/template', { importType: 'FACILITY' });
@@ -208,12 +213,13 @@ export default {
           height: '861px',
           props: {
             cardId: row,
+            comm: this.comm,
             callback: resolve
           },
           // showConfirmButton: true,
           // showCancelButton: true,
           hideStar: true,
-          title: '新增内部车'
+          title: this.comm == 'add' ? '编辑内部车' : '新增内部车'
         });
       }).then(() => {
         this.mixins_search();
@@ -251,16 +257,14 @@ export default {
           width: '511px',
           height: '683px',
           props: {
-            // id: row.id,
-            // callback: resolve
             userName: row.userName,
             cardType: row.cardType,
             parkId: row.parkId,
             cardId: row.cardId,
+            fullCarNoStr: row.fullCarNoStr,
+            residentId: row.residentId,
             callback: resolve,
           },
-          // showConfirmButton: true,
-          // showCancelButton: true,
           hideStar: true,
           title: '充值操作'
         });

+ 5 - 4
smart/src/views/vehicleInformation/setpPage/configure.vue

@@ -121,14 +121,15 @@ export default {
     },
   },
   created () {
+    this.vehiColor();
+    this.vehiColors();
+
     this.form.vehicleType = this.params.form[this.params.id].vehicleType;
-    this.form.vehicleColor = this.params.form[this.params.id].vehicleColor;
-    this.form.vehicleColors = this.params.form[this.params.id].vehicleColors;
+    this.form.vehicleColor = Number(this.params.form[this.params.id].vehicleColor);
+    this.form.vehicleColors = Number(this.params.form[this.params.id].vehicleColors);
     this.form.vehicleBrand = this.params.form[this.params.id].vehicleBrand;
     this.form.id = this.params.id;
 
-    this.vehiColor();
-    this.vehiColors();
   }
 }
 </script>

+ 88 - 32
smart/src/views/vehicleInformation/setpPage/details.vue

@@ -91,7 +91,7 @@
         <el-col :span="9">
           <el-form-item
             label="车牌类型"
-            prop="license"
+            prop="carTypes"
           >
             <el-select
               placeholder="请选择车牌类型"
@@ -255,7 +255,7 @@
               <el-input
                 v-model="tableData[scope.$index].positionInformation"
                 @click.native="positionInformation(scope.$index)"
-                placeholder="请输入内容"
+                placeholder="请选择车位"
               ></el-input>
             </template>
 
@@ -263,6 +263,7 @@
           <el-table-column
             label="操作"
             align="center"
+            width="100"
           >
             <template slot-scope="scope">
               <el-tooltip
@@ -395,10 +396,15 @@
                 placement="bottom"
                 content="编辑"
               >
-                <i
-                  class="zoniot_font zoniot-icon-bianji"
-                  @click="addEdit(scope.$index)"
-                ></i>
+                <span>
+                  <img
+                    src="../../../assets/img/btn_peizhi.png"
+                    alt=""
+                    style="width: 15px; height: 13px; margin-left: 10px; cursor: pointer;"
+                    @click="addEdit(scope.$index)"
+                  >
+                </span>
+
               </el-tooltip>
             </template>
 
@@ -414,10 +420,12 @@
 <script>
 import { parse } from 'path';
 import native from './native.vue'
+import configure from './configure.vue';
 export default {
-  props: ['params'],
+  props: ['params', configure],
   data () {
     return {
+      url: '',
       areaNamed: [],
       formDate: {
         userName: '',
@@ -596,6 +604,15 @@ export default {
           { required: true, message: '请输入手机号', trigger: 'blur' },
           { pattern: /^(0|86|17951)?(13[0-9]|15[012356789]|17[678]|18[0-9]|14[57])[0-9]{8}$/, message: '请输入正确的电话' }
         ],
+        carTypes: [
+          { type: 'date', required: true, message: '请选择车牌类型', trigger: 'change' }
+        ],
+
+      },
+      rule: {
+        parkingArea: [
+          { type: 'date', required: true, message: '请选择车牌类型', trigger: 'change' }
+        ]
       },
 
       room: [],
@@ -623,8 +640,9 @@ export default {
 
 
 
+
+
     parked (item) {
-      debugger
       this.areaNamed.push(item.label);
       // this.tableData.areaName = item.label;
       this.formDate.sort = item.startDate;
@@ -635,7 +653,18 @@ export default {
       // /sc-community-web/parkingCar/queryRechargeRules
       this.recharge = []
       this.$http
-        .get('/sc-community-web/parkingCar/queryRechargeRules', { carType: this.formDate.carType, parkingId: this.formDate.parkId })
+        .get('/sc-community-web/parkingCar/queryRechargeRules', {
+          carType: this.formDate.carTypes == '临时车' ? '0' :
+            this.formDate.carTypes == 'VIP车' ? '1' :
+              this.formDate.carTypes == '月租车' ? '2' :
+                this.formDate.carTypes == '充时车' ? '3' :
+                  this.formDate.carTypes == '时租车' ? '4' :
+                    this.formDate.carTypes == '产全车' ? '5' :
+                      this.formDate.carTypes == '计次车' ? '6' :
+                        this.formDate.carTypes == '贵宾车' ? '7' :
+                          this.formDate.carTypes == '员工卡' ? '8' : this.formDate.carTypes
+          , parkingId: this.formDate.parkId
+        })
         .then(({ data, msg, status }) => {
           console.log('data', data);
 
@@ -669,7 +698,7 @@ export default {
         console.log(this.formDate.tel)
         this.room = [];
         this.$http
-          .get('/sc-community-web/parkingCar/getUserInfo', { phone: this.formDate.tel })
+          .get('/sc-community/parkingCar/getUserInfo', { phone: this.formDate.tel })
           .then(({ data, msg, status }) => {
             for (let i = 0; i < data.houseInfos.length; i++) {
               this.room.push({
@@ -678,6 +707,10 @@ export default {
                 residentId: data.houseInfos[i].residentId,
               })
             }
+
+            this.formDate.resDate = data.houseInfos[0].id;
+            this.formDate.id = data.houseInfos[0].residentId;
+
           })
           .catch(() => { });
       }
@@ -734,7 +767,6 @@ export default {
           title: '选择车位'
         });
       }).then((data) => {
-        debugger
         var id = data[0].id;
         this.tableData[id].positionInformation = data[0].positionInformation;
         this.tableData[id].parkingId = data[0].value;
@@ -800,7 +832,6 @@ export default {
       }
     },
     region () {
-      debugger
       this.$http.post('/sc-community-web/parkingCar/findAreaInfo', { parkId: this.formDate.parkId }).then(({ data, status, msg }) => {
         this.eloption = [];
         for (let i = 0; i < data.length; i++) {
@@ -819,22 +850,34 @@ export default {
     },
     submit () {
       debugger
+      if (this.params.comm == 'add') {
+        // this.url = '/sc-community-web/parkingCar/addVehicleInfor'
+        this.url = '/sc-community-web/parkingCar/updateVehicleInfor'
+        for (let i = 0; i < this.tableData.length; i++) {
+          this.tableData[i].areaName = (Array.from(new Set(this.areaNamed))).join(',');
+        }
+      } else {
+        // this.url = '/sc-community-web/parkingCar/updateVehicleInfor'
+        this.url = '/sc-community-web/parkingCar/addVehicleInfor'
+      }
       this.$refs.formDate.validate((valid) => {
         console.log('valid', valid);
         if (valid) {
           var table = [];
-          debugger
-          this.tableData.areaName = (Array.from(new Set(this.areaNamed))).join(',');
-          debugger
           for (let i = 0; i < this.tableData.length; i++) {
+            // this.tableData[i].areaName = (Array.from(new Set(this.areaNamed))).join(',');
+            this.tableData[i].areaName = (Array.from(new Set(this.areaNamed))).join(',');
+            console.log(this.tableData[i]);
+            debugger
             table.push({
               areaId: [this.tableData[i].parkingArea],
               areaName: this.tableData[i].areaName,
               lotCount: this.num,
               lotName: this.tableData[i].positionInformation,
+
               // ruleId: this.formDate.ruleId,//暂无
               parkingId: this.tableData[i].parkingId,
-              lotName: '',
+              // lotName: '',
               carType: '',
               ruleId: this.formDate.ruleId,
               sequence: this.formDate.sort,
@@ -842,6 +885,7 @@ export default {
 
 
             })
+
             this.formDate.areaName = this.tableData[i].areaName
           }
           var parkingSpace = [];
@@ -849,11 +893,11 @@ export default {
             parkingSpace.push({
               carNo: this.parkingSpaceSetting[k].licensePlate + this.parkingSpaceSetting[k].license,
               cardNo: this.parkingSpaceSetting[k].accessCredentials,
-              enable: this.parkingSpaceSetting[k].state,
+              enable: this.parkingSpaceSetting[k].state == '启用' ? '1' : this.parkingSpaceSetting[k].state == '禁用' ? '2' : this.parkingSpaceSetting[k].state,
               remark: this.parkingSpaceSetting[k].remarks,
 
 
-              carType: this.formDate.carType,
+              carType: this.form[k].vehicleType,
               carNoColor: this.form[k].vehicleColor,
               carColor: this.form[k].vehicleColors,
               carBrand: this.form[k].vehicleBrand,
@@ -863,21 +907,29 @@ export default {
             this.plateNoInfo.push((this.parkingSpaceSetting[k].licensePlate + this.parkingSpaceSetting[k].license));
 
             for (let j = 0; j < table.length; j++) {
-              table[j].lotName = this.parkingSpaceSetting[k].license;
               table[j].carType = this.formDate.carType;
 
             }
 
-
           }
-          this.$http.post('/sc-community-web/parkingCar/addVehicleInfor', {
+          debugger
+          this.$http.post(this.url, {
+            cardId: this.params.cardId != undefined ? this.params.cardId : '',
             cardName: this.formDate.userName,
             userName: this.formDate.userName,
             tel: this.formDate.tel,
             houseId: this.formDate.residentId,
             residentId: this.formDate.id,
             remark: this.formDate.remark,
-            cardType: this.formDate.carTypes,
+            cardType: this.formDate.carTypes == '临时车' ? '0' :
+              this.formDate.carTypes == 'VIP车' ? '1' :
+                this.formDate.carTypes == '月租车' ? '2' :
+                  this.formDate.carTypes == '充时车' ? '3' :
+                    this.formDate.carTypes == '时租车' ? '4' :
+                      this.formDate.carTypes == '产全车' ? '5' :
+                        this.formDate.carTypes == '计次车' ? '6' :
+                          this.formDate.carTypes == '贵宾车' ? '7' :
+                            this.formDate.carTypes == '员工卡' ? '8' : this.formDate.carTypes,
             beginTime: this.formDate.beginTime,
             parkId: this.formDate.parkId,
             areaName: this.formDate.areaName,
@@ -904,7 +956,6 @@ export default {
   },
   created () {
     this.nameParking();
-
     if (this.params.cardId != undefined) {
       this.params.cardId;
       this.$http.get('/sc-community-web/parkingCar/getVehicleInfor', { id: this.params.cardId }).then(({ data, msg, status }) => {
@@ -925,32 +976,31 @@ export default {
 
 
 
-
         this.nameParkingLotName = '1';//随便
 
         this.formDate.beginTime = data.beginTime
         this.formDate.parkId = data.parkId
         var carLotStr = JSON.parse(data.carLotStr)
         for (let i = 0; i < carLotStr.length; i++) {
-          debugger
           // this.tableData[i].parkingArea = carLotStr[i].areaId
           this.tableData[i].areaName = carLotStr[i].areaName
           this.tableData[i].carType = data.cardType
           this.tableData[i].lotCount = carLotStr[i].lotCount
           this.tableData[i].positionInformation = carLotStr[i].lotName
+          this.tableData[i].parkingId = carLotStr[i].parkingId
           // this.formDate.ruleId = carLotStr.ruleId
           this.formDate.sort = carLotStr.sequence
         }
         for (let k = 0; k < data.parkCarDetails.length; k++) {
           this.parkingSpaceSetting[k].licensePlate = (data.fullCarNoStr).substr(0, 1)
           this.parkingSpaceSetting[k].license = (data.fullCarNoStr).substr(1)
-          this.parkingSpaceSetting[k].state = data.parkCarDetails[k].enable == 0 ? '启用' : '禁用'
+          this.parkingSpaceSetting[k].state = data.parkCarDetails[k].enable == 1 ? '启用' : '禁用'
           this.parkingSpaceSetting[k].remarks = data.parkCarDetails[k].remark
 
-          this.formDate.carType = data.cardType
-          this.form[k].vehicleColor = data.parkCarDetails[k].carNoColor
-          this.form[k].vehicleColors = data.parkCarDetails[k].carColor
-          this.form[k].vehicleBrand = data.parkCarDetails[k].carBrand
+          // this.formDate.carType = data.cardType
+          // this.form[k].vehicleColor = data.parkCarDetails[k].carNoColor
+          // this.form[k].vehicleColors = data.parkCarDetails[k].carColor
+          // this.form[k].vehicleBrand = data.parkCarDetails[k].carBrand
         }
 
 
@@ -958,12 +1008,18 @@ export default {
         this.nameParking();
         this.region();
 
-
         for (let i = 0; i < carLotStr.length; i++) {
-          debugger
           this.tableData[i].parkingArea = Number(carLotStr[i].areaId)
           this.formDate.ruleId = carLotStr[i].ruleId
         }
+        debugger
+        for (let k = 0; k < data.parkCarDetails.length; k++) {
+          this.formDate.carType = data.cardType;
+          this.form[k].vehicleType = data.parkCarDetails[k].carType;
+          this.form[k].vehicleColor = data.parkCarDetails[k].carNoColor
+          this.form[k].vehicleColors = data.parkCarDetails[k].carColor
+          this.form[k].vehicleBrand = data.parkCarDetails[k].carBrand
+        }
 
       });
     }

+ 66 - 12
smart/src/views/vehicleInformation/setpPage/native.vue

@@ -4,7 +4,7 @@
           :props="defaultProps"
           show-checkbox
     -->
-    <el-tree
+    <!-- <el-tree
       class="filter-tree"
       :data="dataRes"
       @check="checkChange"
@@ -19,7 +19,28 @@
       :filter-node-method="filterNode"
       ref="tree"
     >
-    </el-tree>
+    </el-tree> -->
+
+    <el-scrollbar
+      class="el-scrollbar-byself"
+      style="width: 100%"
+    >
+      <el-tree
+        :data="tenantsTree"
+        show-checkbox
+        node-key="value"
+        :props="treedefaultProps"
+        :default-checked-keys="defaultcheckedkeys"
+        ref="tenantstree"
+        @check-change="checkChange"
+      >
+        <div
+          style="width: 100%"
+          slot-scope="{ node, data }"
+          @click="thisCheck($event, node, data)"
+        >{{ data.name }}</div>
+      </el-tree>
+    </el-scrollbar>
 
   </div>
 </template>
@@ -32,22 +53,36 @@ export default {
   props: ['params'],
   data () {
     return {
-      defaultProps: {
-        children: 'children',
-        label: 'name'
-      },//过滤使用字段
-      dataRes: [],
+      // defaultProps: {
+      //   children: 'children',
+      //   label: 'name'
+      // },//过滤使用字段
+      // dataRes: [],
       checkedData: {},//当前点击的数据
+
+
       Information: '',
+
+
       id: '',
       positionInformation: [],
-      value: ''
+      value: '',
+
+
+      tenantsTree: [],
+      treedefaultProps: {
+        children: 'children',
+        label: 'name'
+      },
+      defaultcheckedkeys: []
     }
   },
 
   methods: {
     /** 控制树形单选 */
     checkChange (data, checked) {
+      this.checkedData = {}
+      debugger
       if (checked) {
         if (!!data.children && data.children.length > 0) {
           console.log("有子节点不可选")
@@ -56,7 +91,7 @@ export default {
           // 注意!!!
           //1、下方的id和属性中 node-key="id"必须是同一个字段  
           //2、$refs.tree 也需要和上方的属性匹配 ref="tree"
-          this.$refs.tree.setCheckedKeys([data.value]);
+          this.$refs.tenantstree.setCheckedKeys([data.value]);
         }
       }
       this.value = this.checkedData.value;
@@ -70,10 +105,29 @@ export default {
       this.$emit('close');
     },
 
-
+    filterTreeData (trData) {
+      trData.map((item, index) => {
+        if (this.isNotEmpty(item.children)) {
+          item.disabled = true;
+          this.filterTreeData(item.children);
+        } else {
+          item.disabled = false;
+        }
+      });
+    },
+    isNotEmpty (arr) {
+      return arr && Array.isArray(arr) && arr.length > 0;
+    },
+    thisCheck (ev, node, data) {
+      if (!data.disabled) {
+        node.checked = !node.checked;
+      }
+    },
     garage () {
       this.$http.get('/sc-community-web/assets/tree/garage/find').then(({ data, status, msg }) => {
         this.dataRes = data;
+        this.filterTreeData(this.dataRes);
+        this.tenantsTree = this.dataRes;
       })
     }
   },
@@ -88,13 +142,13 @@ export default {
 
 
 <style scoped>
-/deep/ .el-tree > .el-tree-node > .el-tree-node__content .el-checkbox {
+/* /deep/ .el-tree > .el-tree-node > .el-tree-node__content .el-checkbox {
     display: none;
 }
 
 /deep/.el-tree > .el-tree-node > .el-tree-node__children > .el-tree-node > .el-tree-node__content .el-checkbox {
     display: none;
-}
+} */
 /* /deep/.el-tree
     > .el-tree-node
     > .el-tree-node__children

+ 8 - 3
smart/src/views/vehicleInformation/setpPage/recharge.vue

@@ -176,6 +176,8 @@ export default {
       timeValue1: '',
       timeValue2: '',
       rechargeDate: [],
+      fullCarNoStr: '',
+      residentId: ''
     }
   },
   methods: {
@@ -208,7 +210,6 @@ export default {
         chargeAmount: this.rechargeDate[item.nameId].basicMoney
       })
       debugger
-
     },
     datePicker () {
 
@@ -267,7 +268,7 @@ export default {
       this.valueselect = this.complimentaryDays[0].label;
       this.valueselectName = this.complimentaryDays[0].name;
       this.idType = this.complimentaryDays[0].idType;
-      this.chargeAmount = this.complimentaryDays[0].chargeAmount;
+      this.chargeAmount = this.complimentaryDays[0].chargeAmount / 100;
       this.chargeNumber = item.name;
     },
     submit () {
@@ -283,7 +284,9 @@ export default {
         payChannel: this.paymentMethod,
         remark: this.inputText,
         validFrom: this.timeValue1,
-        validTo: this.timeValue2
+        validTo: this.timeValue2,
+        platNo: this.fullCarNoStr,
+        userId: this.residentId,
       }).then(({ data, status, msg }) => {
       })
       this.$emit('close');
@@ -296,6 +299,8 @@ export default {
     this.cardType = this.params.cardType;
     this.parkId = this.params.parkId;
     this.cardId = this.params.cardId;
+    this.fullCarNoStr = fullCarNoStr;
+    this.residentId = residentId;
 
 
     this.rechargeRules();