作者 lihongjuan

4352345

... ... @@ -85,7 +85,7 @@
},
globalData: {
userInfo: null,
//baseUrl: 'http://icrgangjuren.w.brotop.cn/'
// baseUrl: 'http://icrgangjuren.w.brotop.cn/'
baseUrl:'https://icr.gangjuren.com/'
}
}
... ...
... ... @@ -134,7 +134,7 @@
<view class="subshuju" @click="edifenxiangor?set_number:''" v-if="edifenxiangor">提交数据</view>
<!-- <view class="subshuju" v-else>提交数据</view> -->
<view class="tupianshangchuan" v-if="picshangchuan">图片上传中</view>
... ... @@ -163,7 +163,8 @@
id:'',
is_share:0,
fenxiangor:true,
edifenxiangor:true
edifenxiangor:true,
picshangchuan:false
}
},
methods: {
... ... @@ -178,7 +179,7 @@
// sourceType: ['camera'],//拍摄照片
// sourceType: '',
success: (chooseImageRes) => {
console.log(909090808080)
this.picshangchuan=true
const tempFilePaths = chooseImageRes.tempFilePaths;
let images = tempFilePaths[0]
... ... @@ -197,11 +198,9 @@
header: head,
// images:images
success: (uploadFileRes) => {
console.log(uploadFileRes);
let data = JSON.parse(uploadFileRes.data)
console.log(data)
this.picshangchuan=false
console.log('000999888',this.imglist)
let data = JSON.parse(uploadFileRes.data)
this.imglist.push(data.data.src)
}
});
... ... @@ -226,11 +225,11 @@
sourceType: ['camera'],//拍摄照片
// sourceType: '',
success: (chooseImageRes) => {
console.log(909090808080)
this.picshangchuan=true
const tempFilePaths = chooseImageRes.tempFilePaths;
let images = tempFilePaths[0]
console.log(images)
let head = {
'token': uni.getStorageSync('token'),
... ... @@ -245,9 +244,9 @@
header: head,
// images:images
success: (uploadFileRes) => {
console.log(uploadFileRes);
this.picshangchuan=false
let data = JSON.parse(uploadFileRes.data)
console.log(data)
this.imglist.push(data.data.src)
}
});
... ... @@ -568,4 +567,19 @@
line-height: 100rpx;
margin: 42rpx auto;
}
.tupianshangchuan{
width:200rpx;
height:50rpx;
background: #3E3A39;
color:#fff;
font-size: 24rpx;
text-align: center;
line-height: 50rpx;
opacity: 0.5;
position: absolute;
border-radius: 20rpx;
top:45%;
left:50%;
transform: translate(-50%,-50%)
}
</style>
... ...
... ... @@ -53,12 +53,12 @@
<view class="yangli">
<view class="yangliword">样例展示</view>
<view class='yangliimg'>
<view class='yitemimg'>
<image src="/static/img/yangli.png"></image>
<view class='yitemimg' v-for="(item,index) in examplearr" :key="index" @click="viewimg(index)">
<image :src="item"></image>
</view>
<view class='yitemimg'>
<!-- <view class='yitemimg'>
<image src="/static/img/yangli1.png"></image>
</view>
</view> -->
</view>
</view>
... ... @@ -108,7 +108,8 @@
upload_word: '上传图片',
upimg: '',
qudingshow: true,
picshangchuan:false
picshangchuan:false,
examplearr:['https://icr.gangjuren.com/assets/img/shili1.png','https://icr.gangjuren.com/assets/img/shili2.png']
}
},
methods: {
... ... @@ -128,7 +129,9 @@
success: (chooseImageRes) => {
this.picshangchuan=true
this.picshangchuan=true;
this.qudingshow = false;
console.log('888777666555',this.qudingshow)
// uni.showToast({
... ... @@ -154,7 +157,9 @@
header: head,
// images:images
success: (uploadFileRes) => {
this.picshangchuan=false
this.picshangchuan=false;
this.qudingshow = true;
console.log('888777666555',this.qudingshow)
// uni.hideLoading();
... ... @@ -215,7 +220,8 @@
sourceType: ['camera'], //拍摄照片
// sourceType: '',
success: (chooseImageRes) => {
this.picshangchuan=true
this.picshangchuan=true;
this.qudingshow = false
const tempFilePaths = chooseImageRes.tempFilePaths;
let images = tempFilePaths[0];
... ... @@ -234,7 +240,8 @@
header: head,
// images:images
success: (uploadFileRes) => {
this.picshangchuan=false
this.picshangchuan=false;
this.qudingshow = true
let data = JSON.parse(uploadFileRes.data)
console.log(data)
this.upimg = data.data.src
... ... @@ -242,8 +249,7 @@
});
},
fail: function(err) {
console.log('76543221')
console.log(err, "失败的回调")
}
});
... ... @@ -251,6 +257,18 @@
},
//图片预览
viewimg(index) {
uni.previewImage({
current: this.examplearr[index],
urls: this.examplearr,
success: function(res) {},
fail: function(res) {},
complete: function(res) {},
})
},
// 获取数管剩余时间次数
get_surplus() {
let t = this;
... ...
... ... @@ -59,7 +59,7 @@
<view class="shugaunimg">
<image src="/static/img/suo.png"></image>
<view class="keshijian">剩余可用时间:{{guanshowshengyuqixian}}</view>
<view class="remaincishu">剩余使用次数:{{shenyu.times}}</view>
<view class="remaincishu">剩余使用次数:{{shenyu.times}}</view>
</view>
<view class="shubanlist">
... ...