作者 李洪娟

合并分支 'lhj' 到 'master'

123



查看合并请求 !7
... ... @@ -459,8 +459,9 @@
}
.dibu {
position: absolute;
bottom: 45rpx;
/* position: absolute;
bottom: 45rpx; */
margin-top:40rpx;
width: 750rpx;
display: flex;
flex-direction: column;
... ...
... ... @@ -43,7 +43,10 @@
</view>
<view class="yiqihead">
<view class="yiqiheadleft">复核数量</view>
<view class="yiqiheadright">{{equipment_log.fuhe}}</view>
<view class="yiqiheadright">
<input type="number" placeplaceholder="请输入复核数量" v-model="fuhe" placeholder-class="fuheshuliangname" />
<!-- {{}} -->
</view>
</view>
</view>
<view class="yewu">
... ... @@ -98,7 +101,7 @@
<view class="imgbox">
<view v-for="(item,index) in imglist" :key="index" class="imgshang">
<view class="upload" >
<view class="upload">
<image :src="item" @click="viewimgtu(index)"></image>
<view class="chahao" @click="del(index)">
<image src="../../static/img/chahao3.png"></image>
... ... @@ -122,7 +125,7 @@
<view class="imgbox">
<view v-for="(item,index) in imglist" :key="index" class="imgshang">
<view class="upload" >
<view class="upload">
<image :src="item" @click="viewimgtu(index)"></image>
</view>
... ... @@ -132,7 +135,12 @@
</view>
</view>
<view class="subshuju" @click="edifenxiangor?set_number:''" v-if="edifenxiangor">提交数据</view>
<!-- <view class="subshuju" >提交数据</view> -->
<!-- <view @click="tijiao">提交数据</view> -->
<!-- <view class="subshuju" @click="edifenxiangor?tijiao:''" v-if="edifenxiangor">提交数据{{edifenxiangor}}</view> -->
<view class="subshuju" @click="tijiao" v-if="edifenxiangor">提交数据</view>
<view class="subshuju" v-else>提交数据</view>
<!-- <view class="subshuju" v-else>提交数据</view> -->
<view class="tupianshangchuan" v-if="picshangchuan">图片上传中</view>
... ... @@ -158,19 +166,20 @@
ziduan5: "",
image: [],
chuanimg: '/static/img/upload.png',
imglist:[],
number:'',
id:'',
is_share:0,
fenxiangor:true,
edifenxiangor:true,
picshangchuan:false
imglist: [],
number: '',
id: '',
is_share: 0,
fenxiangor: true,
edifenxiangor: true,
picshangchuan: false,
fuhe:''
}
},
methods: {
//选择照片
shoseimg() {
let baseurl=uni.getStorageSync("baseurl")
let baseurl = uni.getStorageSync("baseurl")
uni.chooseImage({
count: 1,
... ... @@ -179,7 +188,7 @@
// sourceType: ['camera'],//拍摄照片
// sourceType: '',
success: (chooseImageRes) => {
this.picshangchuan=true
this.picshangchuan = true
const tempFilePaths = chooseImageRes.tempFilePaths;
let images = tempFilePaths[0]
... ... @@ -190,7 +199,7 @@
}
uni.uploadFile({
url: baseurl+'/api/person/upload',
url: baseurl + '/api/person/upload',
filePath: tempFilePaths[0],
name: 'images',
token: uni.getStorageSync('token'),
... ... @@ -198,7 +207,7 @@
header: head,
// images:images
success: (uploadFileRes) => {
this.picshangchuan=false
this.picshangchuan = false
let data = JSON.parse(uploadFileRes.data)
this.imglist.push(data.data.src)
... ... @@ -217,15 +226,15 @@
//拍摄照片上传
camera() {
let baseurl=uni.getStorageSync("baseurl")
let baseurl = uni.getStorageSync("baseurl")
uni.chooseImage({
count:1,
count: 1,
sizeType: ['original', 'compressed'],
//sourceType: ['album'], //从相册选择
sourceType: ['camera'],//拍摄照片
sourceType: ['camera'], //拍摄照片
// sourceType: '',
success: (chooseImageRes) => {
this.picshangchuan=true
this.picshangchuan = true
const tempFilePaths = chooseImageRes.tempFilePaths;
let images = tempFilePaths[0]
... ... @@ -236,7 +245,7 @@
}
uni.uploadFile({
url: baseurl+'/api/person/upload',
url: baseurl + '/api/person/upload',
filePath: tempFilePaths[0],
name: 'images',
token: uni.getStorageSync('token'),
... ... @@ -244,7 +253,7 @@
header: head,
// images:images
success: (uploadFileRes) => {
this.picshangchuan=false
this.picshangchuan = false
let data = JSON.parse(uploadFileRes.data)
this.imglist.push(data.data.src)
... ... @@ -261,43 +270,46 @@
},
//删除图片
del(index){
let newimglist=this.imglist;
for(var i=0;i<newimglist.length;i++){
if(i==index){
newimglist.splice(i,1)
del(index) {
let newimglist = this.imglist;
for (var i = 0; i < newimglist.length; i++) {
if (i == index) {
newimglist.splice(i, 1)
}
}
this.imglist=newimglist;
console.log('9999888',this.imglist)
this.imglist = newimglist;
console.log('9999888', this.imglist)
},
// 获取数管剩余时间次数
// 获取数板信息详情
get_shubandetail() {
console.log('666666',this.number)
console.log('666666', this.number)
let t = this;
let url = "api/equipment/getEquipmentDetail";
let param = {
number: this.number,
equipment_log_id: t.id,
is_share:t.is_share
is_share: t.is_share
};
app.post(url, param, 'post').then(r => {
t.equipment_log = r.equipment_log;
t.biaoshi=r.equipment_log.biaoshi;
t.description=r.equipment_log.description;
t.ziduan1=r.equipment_log.ziduan1;
t.ziduan2=r.equipment_log.ziduan2;
t.ziduan3=r.equipment_log.ziduan3;
t.ziduan4=r.equipment_log.ziduan4;
t.ziduan5=r.equipment_log.ziduan5;
t.imglist=r.equipment_log.images
t.fuhe=r.equipment_log.fuhe
t.biaoshi = r.equipment_log.biaoshi;
t.description = r.equipment_log.description;
t.ziduan1 = r.equipment_log.ziduan1;
t.ziduan2 = r.equipment_log.ziduan2;
t.ziduan3 = r.equipment_log.ziduan3;
t.ziduan4 = r.equipment_log.ziduan4;
t.ziduan5 = r.equipment_log.ziduan5;
t.imglist = r.equipment_log.images
}).catch(err => {
... ... @@ -305,22 +317,22 @@
})
},
// 提交数据
set_number() {
tijiao() {
console.log(123)
let t = this;
if (this.imglist.length == 0) {
uni.showToast({
title: '请上传相关图片',
icon: 'none'
})
return false
}
// if (this.imglist.length == 0) {
// uni.showToast({
// title: '请上传相关图片',
// icon: 'none'
// })
// return false
// }
let url = "api/equipment/setEquipmentLog";
let param = {
number: t.equipment_log.number,
equipment_log_id: t.equipment_log.id,
fuhe: t.equipment_log.fuhe,
fuhe: t.fuhe,
biaoshi: t.biaoshi,
description: t.description,
ziduan1: t.ziduan1,
... ... @@ -333,17 +345,21 @@
app.post(url, param, 'post').then(r => {
console.log(r)
uni.showToast({
title:'编辑成功',
icon:'none'
title: '编辑成功',
icon: 'none'
})
t.edifenxiangor=false
t.edifenxiangor = false
}).catch(err => {
console.log(err)
uni.showToast({
title: err.msg,
icon: 'none'
});
})
},
//图片预览
viewimgtu(index) {
console.log('999000',index)
console.log('999000', index)
uni.previewImage({
current: this.imglist[index],
... ... @@ -358,17 +374,17 @@
onLoad(options) {
console.log('777777',options)
this.number=options.number;
this.id=options.id;
if(options.type==1){
this.is_share=1;
this.fenxiangor=false;
this.edifenxiangor=false
}else{
this.is_share=0;
this.fenxiangor=true;
this.edifenxiangor=true
console.log('777777', options)
this.number = options.number;
this.id = options.id;
if (options.type == 1) {
this.is_share = 1;
this.fenxiangor = false;
this.edifenxiangor = false
} else {
this.is_share = 0;
this.fenxiangor = true;
this.edifenxiangor = true
}
this.get_shubandetail()
... ... @@ -385,22 +401,24 @@
}
return {
title: "智能点数小程序",
path: 'pages/shubandetail/shubandetail?share=' + 'true'+'&type='+1+'&number='+this.number+'&id='+this.id
path: 'pages/shubandetail/shubandetail?share=' + 'true' + '&type=' + 1 + '&number=' + this.number + '&id=' + this.id
}
},
}
</script>
<style>
.imgbox{
display:flex;
.imgbox {
display: flex;
align-items: center;
flex-wrap: wrap;
}
.imgshang{
display:flex;
.imgshang {
display: flex;
align-items: center;
}
.infotou {
background: #fff;
padding: 34rpx 32rpx;
... ... @@ -500,6 +518,15 @@
color: #7F8389;
font-size: 28rpx;
}
.yiqiheadright input{
text-align: right;
}
.fuheshuliangname {
color: #7F8389;
font-size: 28rpx;
}
.yewu {
background: #FFFFFF;
... ... @@ -543,15 +570,16 @@
height: 160rpx;
font-size: 0;
margin-top: 30rpx;
margin-left:14rpx;
margin-left: 14rpx;
position: relative;
}
.chahao{
width:40rpx;
height:40rpx;
position:absolute;
top:-10rpx;
right:-10rpx;
.chahao {
width: 40rpx;
height: 40rpx;
position: absolute;
top: -10rpx;
right: -10rpx;
}
.subshuju {
... ... @@ -567,19 +595,20 @@
line-height: 100rpx;
margin: 42rpx auto;
}
.tupianshangchuan{
width:200rpx;
height:50rpx;
.tupianshangchuan {
width: 200rpx;
height: 50rpx;
background: #3E3A39;
color:#fff;
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%)
top: 45%;
left: 50%;
transform: translate(-50%, -50%)
}
</style>
... ...
... ... @@ -36,9 +36,9 @@
</view>
<view class="remaintime">
<view class="remainleft">剩余可用时间:{{shengyu_time}}</view>
<view class="remainright">
<!-- <view class="remainright">
<image src="/static/img/row.png"></image>
</view>
</view> -->
</view>
<view class="shubanbox">
<view class="shubanhead">
... ...
... ... @@ -131,7 +131,7 @@
this.picshangchuan=true;
this.qudingshow = false;
console.log('888777666555',this.qudingshow)
// uni.showToast({
... ... @@ -159,7 +159,7 @@
success: (uploadFileRes) => {
this.picshangchuan=false;
this.qudingshow = true;
console.log('888777666555',this.qudingshow)
// uni.hideLoading();
... ... @@ -323,7 +323,7 @@
this.hours = hrStr;
this.minutes = minStr;
this.seconds = secStr;
console.log(this.days)
totalSecond--;
... ... @@ -395,7 +395,8 @@
},
onShow() {
console.log(777)
this.qudingshow = true
this.qudingshow = true;
},
mounted() {
console.log(77766555)
... ...
... ... @@ -319,9 +319,9 @@
</view>
</view>
<view class="yewuxinxiitem">
<view class="yewuxinleft">钥</view>
<view class="yewuxinleft">钥</view>
<view class="yewuinput">
<input type="text" placeholder="请输入钥" placeholder-class="enteryewu" v-model="mSign" />
<input type="text" placeholder="请输入钥" placeholder-class="enteryewu" v-model="mSign" />
</view>
</view>
<view class="yewubottom">
... ... @@ -381,7 +381,8 @@
fengxiangshare: true,
is_share: 0,
fileimg: [],
quedingmi:true
quedingmi:true,
}
},
methods: {
... ... @@ -450,6 +451,19 @@
t.ziduan5=r.info.ziduan5
t.fileimg[0] = r.info.files
t.images = r.images;
console.log('999999',r.printer.machine_code)
if(r.printer.machine_code!=null){
t.machineCode=r.printer.machine_code
}
console.log('909086',t.machineCode)
if(r.printer.m_sign!=null){
t.mSign=r.printer.m_sign
}
console.log('808096',t.mSign)
// 管径列表
t.log_list = r.log_list;
t.count = r.count
... ... @@ -480,7 +494,10 @@
var sec = second - day * 3600 * 24 - hr * 3600 - min * 60;
var secStr = sec.toString();
if (secStr.length == 1) secStr = secStr;
this.shengyu_time = dayStr + '天' + hrStr + '小时' + minStr + "分钟"
this.shengyu_time = dayStr + '天' + hrStr + '小时' + minStr + "分钟";
},
// 更新数管数据
get_update() {
... ... @@ -698,8 +715,6 @@
display: flex;
align-items: center;
justify-content: space-between;
}
image {
... ...
... ... @@ -60,6 +60,7 @@
<image src="/static/img/suo.png"></image>
<view class="keshijian">剩余可用时间:{{guanshowshengyuqixian}}</view>
<view class="remaincishu">剩余使用次数:{{shenyu.times}}</view>
<view class='newuser'>新用户赠送100次</view>
</view>
<view class="shubanlist">
... ... @@ -111,7 +112,9 @@
guanshowshengyuqixian:0,
numbername:'',
saoshuban_number:'扫码获取',
entershuban_number:''
entershuban_number:'',
clcikcshuban:'',
clickshuguan:''
}
},
methods: {
... ... @@ -121,11 +124,14 @@
this.currentTab = id;
if (id == 1) {
this.banpage = 1;
this.shubanlist = []
this.shubanlist = [];
this.clcikcshuban=1
this.shubantaocanlist();
this.get_bianhao();
} else {
this.guanpage = 1;
this.clickshuguan=1;
this.shuguanlist = [];
this.getshuguanlist();
this.get_shenyu()
... ... @@ -309,16 +315,24 @@
},
//数板套餐列表
shubantaocanlist() {
console.log('111000999')
console.log('88888',this.clcikcshuban)
let param = {
page: this.banpage
}
app.post("api/wxpay/getPlateMealList", param, 'get')
.then(res => {
console.log('999000999')
console.log(res);
if(this.clcikcshuban==1){
// console.log('这是数板数据')
this.shubanlist=res
}else{
// console.log('这是拼接数板数据')
this.shubanlist = this.shubanlist.concat(res)
}
})
.catch(err => {
console.log(err)
... ... @@ -326,19 +340,45 @@
},
//数管套餐购买列表
getshuguanlist() {
console.log('99999',this.clickshuguan)
// uni.showLoading({
// title:'数据加载中',
// mask:true
//
// })
let param = {
page: this.guanpage
}
app.post("api/wxpay/getTubeMealList", param, 'get')
.then(res => {
console.log(res);
if(this.clickshuguan==1){
// console.log('这是数管数据')
this.shuguanlist=res
}else{
// console.log('这是拼接数管数据',this.clickshuguan)
this.shuguanlist = this.shuguanlist.concat(res);
console.log('898989',this.shuguanlist)
}
// uni.hideLoading()
// console.log('898989',this.shuguanlist)
})
.catch(err => {});
.catch(err => {
// uni.hideLoading()
});
},
// 判断数板仪编号是否有效
//数板订单
ordershuban(e) {
... ... @@ -649,6 +689,9 @@
},
// 触底事件
onReachBottom() {
this.clcikcshuban='';
this.clickshuguan=''
let nebanpage = this.banpage;
nebanpage++;
this.banpage = nebanpage
... ... @@ -882,7 +925,7 @@
.keshijian {
position: absolute;
top: 44rpx;
top: 20rpx;
left: 34rpx;
color: #FFFFFF;
font-size: 28rpx;
... ... @@ -891,7 +934,15 @@
.remaincishu {
position: absolute;
top: 120rpx;
top: 77rpx;
left: 34rpx;
color: #FFFFFF;
font-size: 28rpx;
}
.newuser{
position: absolute;
bottom:20rpx;
left: 34rpx;
color: #FFFFFF;
font-size: 28rpx;
... ...