flybl
flybl
  • 发布:2024-10-06 18:52
  • 更新:2024-10-06 21:48
  • 阅读:476

打包基座就失败了! #插件讨论# 【 andriod扫码原生插件UTS版本(毫秒级扫码,支持多种类型码,支持扫多个码) - android支持 】

分类:uni-app

打包基座就失败了!

Appid: UNI72DE239

错误解决方案

错误描述: uts插件编译失败
解决方案: 请根据编译错误修改插件相关代码后重新提交打包。或联系插件作者解决。
######################

e: file://[PackagePath]/wgtRoot/UNI72DE239/uni_modules/xt-barcode-scan/utssdk/app-android/src/index.kt:122:33 Type mismatch: inferred type is String? but Any was expected
e: file://[PackagePath]/wgtRoot/UNI72DE239/uni_modules/xt-barcode-scan/utssdk/app-android/src/index.kt:125:30 Type mismatch: inferred type is String? but Any was expected
e: file://[PackagePath]/wgtRoot/UNI72DE239/uni_modules/xt-barcode-scan/utssdk/app-android/src/index.kt:128:34 Type mismatch: inferred type is String? but Any was expected

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':uni_modules:xt-barcode-scan:compileReleaseKotlin'.

    A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
    Compilation error. See log for more details

  • Try:

    Run with --stacktrace option to get the stack trace.
    Run with --info or --debug option to get more log output.
    Run with --scan to get full insights.
    Get more help at https://help.gradle.org.

BUILD FAILED in 40s
Error code = -5000
Error message:
UTS plugin @ utssdk xt-barcode-scan compile error!

2024-10-06 18:52 负责人:无 分享
已邀请:
android支持

android支持 - 需要深度合作,可以先群里或者请联系qq:243448165

回调参数与代码中不一致问题。需要修改app代码处回调参数类型。
请使用demo:https://docs.qq.com/pdf/DYlR2UGpQb0J2d1Jj 
运行成功后将demo的代码复制到项目,demo可以打包基座成功并运行成功。

flybl

flybl (作者)

仅仅是打包基座,只一句import {ScanOptions,scanBarCode } from "@/uni_modules/xt-barcode-scan" 代码,还没有调用!

android支持

android支持 - 需要深度合作,可以先群里或者请联系qq:243448165

目前只适配了VUE3, VUE2待适配中

android支持

android支持 - 需要深度合作,可以先群里或者请联系qq:243448165

已兼容VUE2 使用1.0.2版本

import {ScanOptions,scanBarCode } from "@/uni_modules/xt-barcode-scan"  

scanBarCode({  
    params: '{"showVibrate": true,"showBeep": true,"showPhotoAlbum": true,"showLightController": true,"supportZoom": true,"scanColor": "#ff0000","fullScreenScan":true}',  
    complete: (res) => {  
        console.log(res);  
    }  
});

要回复问题请先登录注册