#
whycq
2023-05-08 3b9a0380f8dfb24964c0afbd635dc7d2f013d475
pages/print/printUNI.vue
@@ -46,6 +46,9 @@
            val: "",
            dateTimer: "",
            valArr: [],
            print_data: '',
            mat: '',
            time: '',
            // 巴枪参数
            // broadcase_actions: "com.android.receive_scan_action",
            // broadcast_flag: "data"
@@ -69,13 +72,25 @@
      onLoad(options) {
         _this = this;
          this.$init_bluetooth();
          let that = this
          const eventChannel = this.getOpenerEventChannel();
          eventChannel.on('data1', function(data1) {
             that.mat = data1.data
            that.time = data1.time
            console.log(data1);
          })
      },
      methods: {
         ...mapActions([SET_CONNECTBLEDATA]),
         senBleLabel() {
            // console.log(this.$Mock.order_data);
            if(!print) return;
            print.startPrint(this.$Mock.order_data);
            console.log(this.mat);
            this.print_data =  this.$Mock.order_data
            this.print_data.MATNR = this.mat.matnr
            this.print_data.MAKTX = this.mat.maktx
            this.print_data.MODI_TIME = this.time
            print.startPrint(this.print_data);
         },
         // 连接打印机
         confirm_bluetooth(item) {