Commit 75dfde4d by 冷斌

Merge remote-tracking branch 'origin/master'

parents 680f86a5 79335792
...@@ -107,13 +107,15 @@ ...@@ -107,13 +107,15 @@
.smrz .list_hd { font-size: .7rem; color: #333; } .smrz .list_hd { font-size: .7rem; color: #333; }
.smrz .list_bd { width: 70%; text-align: right; font-size: .7rem; color: #999; } .smrz .list_bd { width: 70%; text-align: right; font-size: .7rem; color: #999; }
.smrz .list_bd::-webkit-input-placeholder { color: #999; } .smrz .list_bd::-webkit-input-placeholder { color: #999; }
.smrz .scimgBox { width: 100%; margin-top: .5rem; padding: 0 .7rem; position: relative; height: 5.4rem; } .smrz .scimgBox { width: 100%; margin-top: .5rem; padding: 0 .7rem; display: flex; align-items: center; }
.smrz .imgItem-L { width: 5.4rem; height: 5.4rem; border-radius: .4rem; position: absolute;left: 0; top: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; } /* .smrz .imgItem-L { width: 5.4rem; height: 5.4rem; border-radius: .4rem; position: absolute;left: 0; top: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; }
.smrz .imgItem-R { width: 5.4rem; height: 5.4rem; border-radius: .4rem; position: absolute;right: 0; top: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; } .smrz .imgItem-R { width: 5.4rem; height: 5.4rem; border-radius: .4rem; position: absolute;right: 0; top: 0; display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; }
.smrz .imgItem-M { width: 5.4rem; height: 5.4rem; border-radius: .4rem; position: absolute;left: 50%; top: 0; transform: translate(-50%,0); display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; } .smrz .imgItem-M { width: 5.4rem; height: 5.4rem; border-radius: .4rem; position: absolute;left: 50%; top: 0; transform: translate(-50%,0); display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; } */
.smrz .imgItemL img { width: 100%; height: 100%; } /* .smrz .imgItemL img { width: 100%; height: 100%; }
.smrz .imgItemR img { width: 100%; height: 100%; } .smrz .imgItemR img { width: 100%; height: 100%; }
.smrz .imgItemM img { width: 100%; height: 100%; } .smrz .imgItemM img { width: 100%; height: 100%; } */
.smrz .imgItem { width: 5.4rem; height: 5.4rem; border-radius: .4rem; display: flex; align-items: center; justify-content: center; flex-direction: column; overflow: hidden; margin-right: .5rem; }
.smrz .imgItem img { width: 100%; height: 100%; }
.smrz .addTipsimg { width: 1.05rem; height: 1.05rem; } .smrz .addTipsimg { width: 1.05rem; height: 1.05rem; }
.smrz .addTips_wz { font-size: .5rem; color: #C45EFF; margin-top: .35rem; } .smrz .addTips_wz { font-size: .5rem; color: #C45EFF; margin-top: .35rem; }
.smrz .zhengjz { width: 100%; height: 100%; } .smrz .zhengjz { width: 100%; height: 100%; }
......
...@@ -56,21 +56,21 @@ ...@@ -56,21 +56,21 @@
</div> </div>
<div class="scimgBox"> <div class="scimgBox">
<div v-if="isFile" class="imgItemL" @click="addImg('front_view')"> <div v-if="isFile" class="imgItem" @click="addImg('front_view')">
<img :src="form.front_view ? form.front_view : upload_image"> <img :src="form.front_view ? form.front_view : upload_image">
</div> </div>
<div class="imgItemM" @click="addImg('back_view')"> <div v-if="isFile2" class="imgItem" @click="addImg('back_view')">
<img :src="form.back_view ? form.back_view : upload_image2"> <img :src="form.back_view ? form.back_view : upload_image2">
</div> </div>
<div class="imgItemR" @click="addImg('handset_view')"> <div v-if="isFile3" class="imgItem" @click="addImg('handset_view')">
<img :src="form.handset_view ? form.handset_view : upload_image3"> <img :src="form.handset_view ? form.handset_view : upload_image3">
</div> </div>
<!-- <input id="file" name="image" type="file" v-show="false" class="upload" accept="image/*" @change="upload"/> <!-- <input id="file" name="image" type="file" v-show="false" class="upload" accept="image/*" @change="upload"/>
<input id="file2" name="image" type="file" v-show="false" class="upload" accept="image/*" @change="upload"/> <input id="file2" name="image" type="file" v-show="false" class="upload" accept="image/*" @change="upload"/>
<input id="file3" name="image" type="file" v-show="false" class="upload" accept="image/*" @change="upload"/> --> <input id="file3" name="image" type="file" v-show="false" class="upload" accept="image/*" @change="upload"/> -->
<input id="file" name="image" type="file" v-if="isFile" style="display: none;" accept="image/*" @change="upload"/> <input id="file" name="image" type="file" v-if="isFile" style="display: none;" accept="image/*" @change="upload"/>
<input id="file2" name="image" type="file" style="display: none;" accept="image/*" @change="upload"/> <input id="file2" name="image" type="file" v-if="isFile2" style="display: none;" accept="image/*" @change="upload"/>
<input id="file3" name="image" type="file" style="display: none;" accept="image/*" @change="upload"/> <input id="file3" name="image" type="file" v-if="isFile3" style="display: none;" accept="image/*" @change="upload"/>
</div> </div>
<!-- 按钮 --> <!-- 按钮 -->
...@@ -201,7 +201,7 @@ ...@@ -201,7 +201,7 @@
}) })
}, },
addImg: function (name) { addImg: function (name) {
layer.msg("修改已图片方法调用了"); // layer.msg("修改已图片方法调用了");
this.uploadName = name; this.uploadName = name;
if (this.uploadName === 'front_view') { if (this.uploadName === 'front_view') {
$("#file").click(); $("#file").click();
...@@ -217,24 +217,26 @@ ...@@ -217,24 +217,26 @@
} }
}, },
upload: function () { upload: function () {
layer.msg("上传图片方法调用了"); // layer.msg("上传图片方法调用了");
let _this = this; let _this = this;
let saveName, id = ''; let saveName, id = '';
if (_this.uploadName === 'front_view') { if (_this.uploadName === 'front_view') {
id = 'file'; id = 'file';
saveName = 'auth_' + uid + '_1'; saveName = 'auth_' + uid + '_1';
console.log(1111) _this.isFile = false
} }
if (_this.uploadName === 'back_view') { if (_this.uploadName === 'back_view') {
id = 'file2'; id = 'file2';
saveName = 'auth_' + uid + '_2'; saveName = 'auth_' + uid + '_2';
_this.isFile2 = false
} }
if (_this.uploadName === 'handset_view') { if (_this.uploadName === 'handset_view') {
id = 'file3'; id = 'file3';
saveName = 'auth_' + uid + '_3'; saveName = 'auth_' + uid + '_3';
_this.isFile3 = false
} }
var loadingIndex = layer.load(2); var loadingIndex = layer.load(2);
_this.isFile = false
$.ajaxFileUpload({ $.ajaxFileUpload({
url: './index.php?g=Appapi&m=Auth&a=upload', url: './index.php?g=Appapi&m=Auth&a=upload',
secureuri: false, secureuri: false,
...@@ -252,16 +254,15 @@ ...@@ -252,16 +254,15 @@
layer.msg(msg); layer.msg(msg);
} else { } else {
if (_this.uploadName === 'front_view') { if (_this.uploadName === 'front_view') {
console.log(1111)
_this.form.front_view = str.data.url; _this.form.front_view = str.data.url;
_this.isFile = true _this.isFile = true
} }
if (_this.uploadName === 'back_view') { if (_this.uploadName === 'back_view') {
console.log(22222) _this.isFile2 = true
_this.form.back_view = str.data.url; _this.form.back_view = str.data.url;
} }
if (_this.uploadName === 'handset_view') { if (_this.uploadName === 'handset_view') {
console.log(3333) _this.isFile3 = true
_this.form.handset_view = str.data.url; _this.form.handset_view = str.data.url;
} }
_this.checkSubmit(); _this.checkSubmit();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment