소스 검색

8.2 16:00

Tartarus 2 년 전
부모
커밋
b6de494e82
2개의 변경된 파일60개의 추가작업 그리고 27개의 파일을 삭제
  1. 50 25
      src/views/mine/index.vue
  2. 10 2
      src/views/table/index.vue

+ 50 - 25
src/views/mine/index.vue

xqd xqd xqd xqd xqd xqd xqd xqd
@@ -13,15 +13,21 @@
 						<el-form-item label="供应商名称" :rules="[{  message: '姓名不能为空不能为空'}]">
 							<el-input v-model="form.name" class="ipwidth"  />
 						</el-form-item>
-						<el-form-item label="社会信用代码" :rules="[{ message: '电话号码不能为空'}]">
-							<el-input v-model="form.socialCode" class="ipwidth" disabled/>
+						<el-form-item label="供应商账号">
+							<el-input v-model="form.account" class="ipwidth" />
 						</el-form-item>
-						<el-form-item label="法人姓名" :rules="[{  message: '身份证不能为空'}]">
-							<el-input v-model="form.legalPerson" class="ipwidth" />
+						<el-form-item label="供应商密码">
+							<el-input v-model="form.password" class="ipwidth" type="password" show-password/>
 						</el-form-item>
 						<el-form-item label="供应商联系人" :rules="[{  message: '身份证不能为空'}]">
 							<el-input v-model="form.contacts" class="ipwidth" />
 						</el-form-item>
+						<el-form-item label="供应商联系电话">
+							<el-input v-model="form.contactsMobile" class="ipwidth" />
+						</el-form-item>
+						
+						<el-form-item >
+							<el-button type="primary" @click="update">保存修改</el-button>
 						</el-form-item>
 					</el-form>
 				</el-col>
@@ -32,15 +38,12 @@
 								<span style="color:#262626;">其他信息</span>
 							</span>
 						</el-form-item>
-						<el-form-item label="供应商联系电话">
-							<el-input v-model="form.contactsMobile" class="ipwidth" />
+						<el-form-item label="法人姓名" :rules="[{  message: '身份证不能为空'}]">
+							<el-input v-model="form.legalPerson" class="ipwidth" />
 						</el-form-item>
-						<el-form-item label="供应商账号">
-							<el-input v-model="form.account" class="ipwidth" />
+						<el-form-item label="社会信用代码" :rules="[{ message: '电话号码不能为空'}]">
+							<el-input v-model="form.socialCode" class="ipwidth" disabled/>
 						</el-form-item>
-						<!-- <el-form-item label="供应商密码">
-							<el-input v-model="form.password" class="ipwidth" type="password" show-password/>
-						</el-form-item> -->
 						<el-collapse v-model="activeNames"  style="width: 80%;float: right;">
 							<el-collapse-item title="供应商认证照片" name="3">
 								<div class="boximg">
@@ -49,12 +52,12 @@
 										<i class="el-icon-plus" />
 									</el-upload>
 									<el-dialog :visible.sync="dialogVisibleimg">
-										<img width="100%" :src="form.identifyPicList" alt="" />
+										<img width="100%" :src="form.identifyPics" alt="" />
 									</el-dialog>
 								</div>
 								<div>
-									<el-image style="width: 100px; height: 100px" v-for="(item,index) in form.identifyPicList" :key="index" :src="item"
-									:preview-src-list="form.identifyPicList"	>
+									<el-image style="width: 100px; height: 100px" v-for="(item,index) in form.identifyPics" :key="index" :src="item"
+									:preview-src-list="form.identifyPics">
 									</el-image>
 								</div>
 							</el-collapse-item>
@@ -65,21 +68,21 @@
 										<i class="el-icon-plus" />
 									</el-upload>
 									<el-dialog :visible.sync="dialogVisibleimg">
-										<img width="100%" :src="form.proxyFileList" alt="" />
+										<img width="100%" :src="form.proxyFile" alt="" />
 									</el-dialog>
 								</div>
 								<div>
-									<el-image style="width: 100px; height: 100px" v-for="(item,index) in form.proxyFileList" :key="index" :src="item"
-									:preview-src-list="form.proxyFileList"	>
+									<el-image style="width: 100px; height: 100px" v-for="(item,index) in form.proxyFile" :key="index" :src="item"
+									:preview-src-list="form.proxyFile"	>
 									</el-image>
 								</div>
 							</el-collapse-item>
-							<el-collapse-item title="修改密码" name="5">
+							<!-- <el-collapse-item title="修改密码" name="5">
 								<el-input v-model="password.oldPassword" placeholder="请输入旧密码" type="password" show-password></el-input>
 								<el-input v-model="password.newPassword" placeholder="请输入新密码" type="password" show-password></el-input>
 								<el-input v-model="password.ConfirmnewPassword" placeholder="确认新密码" type="password" show-password ></el-input>
 								<el-button type="primary" @click="onSubmit">确认修改</el-button>
-							</el-collapse-item>
+							</el-collapse-item> -->
 						</el-collapse>
 						</el-form-item>
 					</el-form>
@@ -166,8 +169,8 @@
 					password:'',
 					socialCode:'',
 					legalPerson:'',
-					identifyPicList:[],
-					proxyFileList:[],
+					identifyPics:[],
+					proxyFile:[],
 				},
 				password:{
 					oldPassword: '',
@@ -187,6 +190,9 @@
 					method: 'get'
 				}).then((res) => {
 					this.form=res.data
+					console.log(res)
+					this.form.identifyPics=res.data.identifyPicList
+					this.form.proxyFile=res.data.proxyFileList
 				})
 			} else if (this.role === 1) {
 				this.$request({
@@ -252,8 +258,7 @@
 			  //解构
 			  let { file } = res.data;
 			  this.identifyPicsArray.push(file);
-			  this.form.identifyPicList = this.identifyPicsArray;
-			  console.log(this.form,"form")
+			  this.form.identifyPics = this.identifyPicsArray;
 			},
 			/* 供应商上传委托书图片上传成功  */
 			handleSuccess(res) {
@@ -262,8 +267,28 @@
 					file
 				} = res.data;
 				this.proxyFileArray.push(file);
-				this.form.proxyFileList = this.proxyFileArray;
-				console.log(this.form,"form")
+				this.form.proxyFile = this.proxyFileArray;
+			},
+			update() {
+				console.log(this.form)
+				this.$request({
+					url:'/api/Supplier/update',
+					method:'post',
+					data:this.form
+				}).then((res)=>{
+					console.log(res)
+					if(res.code===200){
+						this.$message({
+							type:'success',
+							message:'修改成功!'
+						})
+					}else{
+						this.$message({
+							type:'error',
+							message:'修改失败!'
+						})
+					}
+				})
 			},
 		}
 	}

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

xqd xqd xqd xqd xqd xqd
@@ -34,7 +34,7 @@
 
 		<!-- 弹窗修改 -->
 		<el-dialog title="修改承兑人" :visible.sync="dialogVisible1" width="500px">
-			<el-form :model="tableData" label-width="80px">
+			<el-form :model="tableData" label-width="100px">
 				<el-form-item label="姓名" prop="tableData.name">
 					<el-input v-model="tableData.name" style="width: 100%;"></el-input>
 				</el-form-item>
@@ -45,6 +45,9 @@
 				<el-form-item label="银行名称" prop="tableData.bankName">
 					<el-input v-model="tableData.bankName" style="width: 100%;"></el-input>
 				</el-form-item>
+				<el-form-item label="开户行行号" prop="bankName">
+					<el-input v-model="tableData.bankNo" style="width: 100%;" placeholder="请输入开户行行号" ></el-input>
+				</el-form-item>
 				<el-form-item label="服务费率" prop="tableData.serviceRate">
 					<el-input v-model="tableData.serviceRate" style="width: 100%;" onkeyup="value=value.replace(/[^\d.]/g,'')">
 						<i slot="suffix" style="font-style:normal;margin-right: 10px;">%</i>
@@ -105,6 +108,8 @@
 			</el-table-column>
 			<el-table-column align="center" label="开户行名称" prop="bankName">
 			</el-table-column>
+			<el-table-column align="center" label="开户行行号" prop="bankNo">
+			</el-table-column>
 			<el-table-column align="center" label="服务费率">
 				<template slot-scope="scope"> {{ scope.row.serviceRate }}% </template>
 			</el-table-column>
@@ -189,6 +194,7 @@
 					name: '',
 					serviceRate: '',
 					interest: '',
+					bankNo:'',
 					bankAccount: '',
 					bankName: '',
 					id: ''
@@ -365,8 +371,9 @@
 					url: '/api/Acceptor/' + id,
 					method: 'get',
 				}).then((res) => {
+					console.log(res)
 					this.tableData = res.data
-					this.tableData.id = this.$route.query.id
+					this.tableData.id = id
 				})
 				this.dialogVisible1 = true
 			},
@@ -382,6 +389,7 @@
 							type: 'success',
 							message: '修改成功!'
 						})
+						this.getAllList();
 					} else {
 						this.$message({
 							type: 'danger',