From f0cad0c5ea4778036452217b4704c6875dc246e3 Mon Sep 17 00:00:00 2001
From: kongdeqiang <123456>
Date: 星期一, 18 十一月 2024 14:50:47 +0800
Subject: [PATCH] feat: 缴费记录
---
src/components/page/user/index.vue | 43 +++++++++++++++++++++++++++----------------
1 files changed, 27 insertions(+), 16 deletions(-)
diff --git a/src/components/page/user/index.vue b/src/components/page/user/index.vue
index ad5645d..459ee48 100644
--- a/src/components/page/user/index.vue
+++ b/src/components/page/user/index.vue
@@ -3,7 +3,7 @@
<div style="padding: 10px 10px 0px 10px;">
<el-form :inline="true" :model="searchForm">
<el-form-item label="鍚嶇О">
- <el-input v-model="searchForm.name"></el-input>
+ <el-input v-model="searchForm.name" clearable></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" size="small" @click="onSearch" icon="el-icon-search">鏌ヨ</el-button>
@@ -21,6 +21,8 @@
<template slot-scope="scope">
<p v-if="scope.row.type==0">鍋滆溅鍦虹鐞嗗憳</p>
<p v-if="scope.row.type==1">鎵ф硶浜哄憳</p>
+ <p v-if="scope.row.type==2">绯荤粺绠$悊鍛�</p>
+ <p v-if="scope.row.type==3">鎵嬫寔缁堢绠$悊鍛�</p>
</template>
</el-table-column>
<el-table-column label="鎿嶄綔" fixed="right" width="150" align="center">
@@ -38,6 +40,9 @@
<el-form-item label="鐧诲綍鍚�" prop="loginName" :rules="[{required: true, message: '璇疯緭鍏ョ櫥褰曞悕', trigger: 'blur'}]">
<el-input v-model="formData.loginName" auto-complete="off"></el-input>
</el-form-item>
+ <el-form-item label="瀵嗙爜" prop="password" :rules="[{required: true, message: '璇疯緭鍏ュ瘑鐮�', trigger: 'blur'}]">
+ <el-input v-model="formData.password" auto-complete="off"></el-input>
+ </el-form-item>
<el-form-item label="濮撳悕" prop="name" :rules="[{required: true, message: '璇疯緭鍏ュ鍚�', trigger: 'blur'}]">
<el-input v-model="formData.name" auto-complete="off"></el-input>
</el-form-item>
@@ -46,8 +51,10 @@
</el-form-item>
<el-form-item label="浜哄憳绫诲瀷" prop="type" :rules="[{required: true, message: '璇烽�夋嫨浜哄憳绫诲瀷', trigger: 'change'}]">
<el-select v-model="formData.type">
- <el-option label="鍋滆溅鍦虹鐞嗗憳" :value=0></el-option>
+ <el-option label="鍋滆溅鍦哄悗鍙扮鐞嗗憳" :value=0></el-option>
<el-option label="鎵ф硶浜哄憳" :value=1></el-option>
+ <el-option label="绯荤粺绠$悊鍛�" :value=2></el-option>
+ <el-option label="鎵嬫寔缁堢绠$悊鍛�" :value=3></el-option>
</el-select>
</el-form-item>
<el-form-item label="绠$悊鍋滆溅鍦�" prop="parkIds">
@@ -99,10 +106,10 @@
this.formData.parkIds = this.parkIds.toString()
this.$refs['formData'].validate((valid) => {
if (valid) {
- this.$byutil.postData(this, this.$systemconfig.basePath + '/user/save', this.formData, res => {
+ this.$byutil.postData(this, this.$systemconfig.basePath + '/ffzf/user/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 {
@@ -111,11 +118,11 @@
});
},
loadData() {
- this.$byutil.loadPageData(this, this.$systemconfig.basePath + '/user/findPage', this.searchForm);
+ this.$byutil.loadPageData(this, this.$systemconfig.basePath + '/ffzf/user/findPage', this.searchForm);
},
getParkList(){
- this.$byutil.postData(this, this.$systemconfig.basePath + '/park/findAll',null,res => {
- this.parkList = res.obj
+ this.$byutil.postData(this, this.$systemconfig.basePath + '/ffzf/park/findAll',null,res => {
+ this.parkList = res.data
});
},
onSearch() {
@@ -135,20 +142,24 @@
}
},
onEdit(index, row) {
+ this.parkIds = []
this.getParkList()
this.flag=true;
this.formData = row;
- let ids = this.formData.parkIds.split(",")
- let resList = [];
- ids.forEach(item => {
- resList.push(Number(item))
- })
- this.parkIds = resList;
+ let ids = null
+ if(this.formData.parkIds){
+ ids=this.formData.parkIds.split(",")
+ let resList = [];
+ ids.forEach(item => {
+ resList.push(Number(item))
+ })
+ this.parkIds = resList;
+ }
console.log(this.parkIds)
},
onDelete(index, row) {
- this.$byutil.deleteData(this,this.$systemconfig.basePath+"/user/delete",{id:row.id}, res => {
- this.$message({message: res.message, type: 'success'});
+ this.$byutil.deleteData(this,this.$systemconfig.basePath+"/ffzf/user/delete",{id:row.id}, res => {
+ this.$message({message: '鍒犻櫎鎴愬姛', type: 'success'});
this.loadData();
})
},
@@ -166,4 +177,4 @@
<style scoped>
-</style>
\ No newline at end of file
+</style>
--
Gitblit v1.9.1