|
@@ -3,7 +3,7 @@
|
|
|
<div class="addWagonLoad">
|
|
|
<PageTitle>返回</PageTitle>
|
|
|
<el-divider content-position="left">司机信息</el-divider>
|
|
|
- <div class="form-box" style="margin-right: 10rem">
|
|
|
+ <div class="form_box" style="margin-right: 10rem">
|
|
|
<dil-form :formId="311" v-model="form1" ref="from1"></dil-form>
|
|
|
</div>
|
|
|
<div class="inputBox">
|
|
@@ -12,7 +12,7 @@
|
|
|
v-model="state"
|
|
|
@input="onInput"
|
|
|
:fetch-suggestions="querySearch"
|
|
|
- placeholder="请输入内容"
|
|
|
+ placeholder="边输入边查询"
|
|
|
:trigger-on-focus="false"
|
|
|
@select="handleSelect"
|
|
|
></el-autocomplete>
|
|
@@ -23,7 +23,7 @@
|
|
|
action="http://localhost:8080/api/v1/rms/upload"
|
|
|
:on-preview="handlePreview"
|
|
|
:on-remove="handleRemove"
|
|
|
- :on-success="handleAvatarSuccess"
|
|
|
+ :on-success="handleAvatarSuccess1"
|
|
|
:file-list="fileList"
|
|
|
list-type="picture">
|
|
|
<div>行驶证照片
|
|
@@ -38,7 +38,7 @@
|
|
|
action="http://localhost:8080/api/v1/rms/upload"
|
|
|
:on-preview="handlePreview"
|
|
|
:on-remove="handleRemove"
|
|
|
- :on-success="handleAvatarSuccess"
|
|
|
+ :on-success="handleAvatarSuccess2"
|
|
|
:file-list="fileList"
|
|
|
list-type="picture">
|
|
|
<div>驾驶证照片
|
|
@@ -53,7 +53,7 @@
|
|
|
action="http://localhost:8080/api/v1/rms/upload"
|
|
|
:on-preview="handlePreview"
|
|
|
:on-remove="handleRemove"
|
|
|
- :on-success="handleAvatarSuccess"
|
|
|
+ :on-success="handleAvatarSuccess3"
|
|
|
:file-list="fileList"
|
|
|
list-type="picture">
|
|
|
<div>运输证照片
|
|
@@ -69,7 +69,7 @@
|
|
|
action="http://localhost:8080/api/v1/rms/upload"
|
|
|
:on-preview="handlePreview"
|
|
|
:on-remove="handleRemove"
|
|
|
- :on-success="handleAvatarSuccess"
|
|
|
+ :on-success="handleAvatarSuccess4"
|
|
|
:file-list="fileList"
|
|
|
list-type="picture">
|
|
|
<div>从业资格证照片
|
|
@@ -78,7 +78,7 @@
|
|
|
</el-upload>
|
|
|
</div>
|
|
|
|
|
|
- <div class="button-box">
|
|
|
+ <div class="button_box">
|
|
|
<el-button @click="cancel">取消</el-button>
|
|
|
<el-button type="primary" @click="makeSure">确定</el-button>
|
|
|
</div>
|
|
@@ -100,7 +100,11 @@ export default {
|
|
|
fileList: [],
|
|
|
carrierIds:"",
|
|
|
state: "",
|
|
|
- imageUrl:"",
|
|
|
+ imageUrl1:"",
|
|
|
+ imageUrl2:"",
|
|
|
+ imageUrl3:"",
|
|
|
+ imageUrl4:"",
|
|
|
+ imageUrls:[],
|
|
|
};
|
|
|
},
|
|
|
mounted() {},
|
|
@@ -136,8 +140,36 @@ export default {
|
|
|
this.carrierIds=item.carrierIds;
|
|
|
console.log(item)
|
|
|
},
|
|
|
- handleAvatarSuccess(res,file){
|
|
|
- this.imageUrl=URL.createObjectURL(file.raw);
|
|
|
+ beforeUpload2 (file) {
|
|
|
+ const isLt2M = file.size < 1024 * 1024 * 0.5
|
|
|
+ console.log('大小' + isLt2M)
|
|
|
+ if (!isLt2M) {
|
|
|
+ this.$message.error('上传文件大小不能超过500kb!')
|
|
|
+ }
|
|
|
+ let size = file.size / 1024
|
|
|
+ console.log('大小' + size)
|
|
|
+ let _URL = window.URL || window.webkitURL
|
|
|
+ let img = new Image()
|
|
|
+ img.onload = function () {
|
|
|
+ let width = img.width
|
|
|
+ let height = img.height
|
|
|
+ console.log('width--->' + width)
|
|
|
+ console.log('height--->' + height)
|
|
|
+ }
|
|
|
+ img.src = _URL.createObjectURL(file)
|
|
|
+ return isLt2M
|
|
|
+ },
|
|
|
+ handleAvatarSuccess1(res,file){
|
|
|
+ this.imageUrl1=URL.createObjectURL(file.raw);
|
|
|
+ },
|
|
|
+ handleAvatarSuccess2(res,file){
|
|
|
+ this.imageUrl2=URL.createObjectURL(file.raw);
|
|
|
+ },
|
|
|
+ handleAvatarSuccess3(res,file){
|
|
|
+ this.imageUrl3=URL.createObjectURL(file.raw);
|
|
|
+ },
|
|
|
+ handleAvatarSuccess4(res,file){
|
|
|
+ this.imageUrl4=URL.createObjectURL(file.raw);
|
|
|
},
|
|
|
handleRemove(file, fileList) {
|
|
|
console.log(file, fileList);
|
|
@@ -202,50 +234,59 @@ export default {
|
|
|
};
|
|
|
</script>
|
|
|
<style lang='scss'>
|
|
|
-.button-box{
|
|
|
- display: flex;
|
|
|
- text-align: center;
|
|
|
- align-items: center;
|
|
|
- justify-content: center;
|
|
|
- margin-top: 0.3125rem;
|
|
|
- margin-bottom: 1.25rem;
|
|
|
-}
|
|
|
-.inputBox{
|
|
|
- display: flex;
|
|
|
- text-align: center;
|
|
|
- align-items: center;
|
|
|
- justify-content: center;
|
|
|
- margin-top: 0.1000rem;
|
|
|
- margin-bottom: 0.25rem;
|
|
|
- margin-left: -12.5rem;
|
|
|
-}
|
|
|
-.photoBox{
|
|
|
+.addWagonLoad {
|
|
|
+ .form_box {
|
|
|
+ width: 100%;
|
|
|
+ margin-top: 30px;
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ .el-form-item{
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ .el-form-item__label{
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ }
|
|
|
+ .el-form-item__content{
|
|
|
+ .el-select{
|
|
|
+ width: 250px;
|
|
|
+ }
|
|
|
+ .el-input{
|
|
|
+ width: 250px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .photoBox{
|
|
|
display: flex;
|
|
|
text-align: center;
|
|
|
align-items: center;
|
|
|
justify-content: center;
|
|
|
margin-top: 1rem;
|
|
|
margin-bottom: 0.25rem;
|
|
|
- margin-left: -18rem;
|
|
|
+ // margin-left: -18rem;
|
|
|
}
|
|
|
-.form-box{
|
|
|
- display:flex;
|
|
|
- justify-content: center;
|
|
|
- .el-form-item{
|
|
|
- display:flex;
|
|
|
+ .inputBox{
|
|
|
+ display: flex;
|
|
|
justify-content: center;
|
|
|
- .el-form-item__label{
|
|
|
- display:flex;
|
|
|
+ margin-bottom: 30px;
|
|
|
+ .text{
|
|
|
+ text-align: right;
|
|
|
+ display: flex;
|
|
|
align-items: center;
|
|
|
+ margin-right: 5px;
|
|
|
}
|
|
|
- .el-form-item__content{
|
|
|
- .el-input{
|
|
|
- .el-input__inner{
|
|
|
- width:250px;
|
|
|
- }
|
|
|
- }
|
|
|
+ .input{
|
|
|
+ width: 250px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .button_box{
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ .el-button{
|
|
|
+ width: 80px;
|
|
|
+ margin-right: 10px;
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
</style>
|