|
@@ -64,6 +64,19 @@
|
|
},
|
|
},
|
|
computed: mapState(['sysinfo', 'Bluetooth']),
|
|
computed: mapState(['sysinfo', 'Bluetooth']),
|
|
onLoad() {
|
|
onLoad() {
|
|
|
|
+ uni.showLoading({
|
|
|
|
+ title: '加载中',
|
|
|
|
+ mask:true
|
|
|
|
+ })
|
|
|
|
+ this.$api.doRequest('get', '/qualityInspectionManagement/api/getQualityInspection', {
|
|
|
|
+ id: uni.getStorageSync('quality_print_id')
|
|
|
|
+ }).then(res => {
|
|
|
|
+ uni.hideLoading()
|
|
|
|
+ if (res.data.data) {
|
|
|
|
+ let data = res.data.data
|
|
|
|
+ this.gridList.qualityNo = data.qualityNo
|
|
|
|
+ }
|
|
|
|
+ })
|
|
let that = this;
|
|
let that = this;
|
|
let {
|
|
let {
|
|
BLEInformation
|
|
BLEInformation
|
|
@@ -105,7 +118,7 @@
|
|
onShow() {
|
|
onShow() {
|
|
this.gridList = uni.getStorageSync("quality_print")
|
|
this.gridList = uni.getStorageSync("quality_print")
|
|
this.utils.nullToString(this.gridList)
|
|
this.utils.nullToString(this.gridList)
|
|
- if(!this.gridList.compId){
|
|
|
|
|
|
+ if (!this.gridList.compId) {
|
|
this.gridList.compId = uni.getStorageSync('pcUserInfo').compId
|
|
this.gridList.compId = uni.getStorageSync('pcUserInfo').compId
|
|
}
|
|
}
|
|
console.log(this.gridList)
|
|
console.log(this.gridList)
|
|
@@ -144,7 +157,7 @@
|
|
// })
|
|
// })
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- goToList(){
|
|
|
|
|
|
+ goToList() {
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
url: '/pages/erpbusiness/quality_testing?managementType=1'
|
|
url: '/pages/erpbusiness/quality_testing?managementType=1'
|
|
})
|
|
})
|
|
@@ -166,6 +179,7 @@
|
|
},
|
|
},
|
|
//打印票据数据
|
|
//打印票据数据
|
|
receiptTest() {
|
|
receiptTest() {
|
|
|
|
+ console.log(this.gridList)
|
|
var that = this;
|
|
var that = this;
|
|
var canvasWidth = that.canvasWidth
|
|
var canvasWidth = that.canvasWidth
|
|
var canvasHeight = that.canvasHeight
|
|
var canvasHeight = that.canvasHeight
|
|
@@ -177,11 +191,13 @@
|
|
command.setSelectJustification(1) //居中
|
|
command.setSelectJustification(1) //居中
|
|
command.rowSpace(200);
|
|
command.rowSpace(200);
|
|
// command.rowSpace(10);
|
|
// command.rowSpace(10);
|
|
|
|
+
|
|
command.setText(that.gridList.qualityNo.substring(that.gridList.qualityNo.length - 3));
|
|
command.setText(that.gridList.qualityNo.substring(that.gridList.qualityNo.length - 3));
|
|
command.setPrint();
|
|
command.setPrint();
|
|
command.rowSpace(60);
|
|
command.rowSpace(60);
|
|
command.bold(0); //取消加粗
|
|
command.bold(0); //取消加粗
|
|
command.setFontSize(0); //正常字体
|
|
command.setFontSize(0); //正常字体
|
|
|
|
+
|
|
// 标题
|
|
// 标题
|
|
command.bold(1); //加粗
|
|
command.bold(1); //加粗
|
|
command.setFontSize(16); //字体大小
|
|
command.setFontSize(16); //字体大小
|
|
@@ -196,7 +212,8 @@
|
|
command.rowSpace(60);
|
|
command.rowSpace(60);
|
|
command.setSelectSizeOfModuleForQRCode(5);
|
|
command.setSelectSizeOfModuleForQRCode(5);
|
|
command.setSelectErrorCorrectionLevelForQRCode(7)
|
|
command.setSelectErrorCorrectionLevelForQRCode(7)
|
|
- command.setStoreQRCodeData(that.gridList.compId + '&' + that.gridList.qualityNo + '&' + that.gridList.warehouseId);
|
|
|
|
|
|
+ command.setStoreQRCodeData(that.gridList.compId + '&' + that.gridList.qualityNo + '&' + that.gridList
|
|
|
|
+ .warehouseId);
|
|
command.setPrintQRCode();
|
|
command.setPrintQRCode();
|
|
//客户姓名
|
|
//客户姓名
|
|
command.setSelectJustification(0); //居左
|
|
command.setSelectJustification(0); //居左
|