zhangdaren
zhangdaren
  • 发布:2019-06-20 15:23
  • 更新:2024-03-29 21:03
  • 阅读:73570

miniprogram-to-uniapp使用指南(各种小程序项目转换为uni-app项目)

分类:uni-app

工具现在支持npm全局库、HBuilderX插件两种方式使用,任君选择,HBuilderX插件地址:https://ext.dcloud.net.cn/plugin?id=2656

一、它是谁?

【miniprogram-to-uniapp】转换微信小程序”项目为uni-app项目(新版本工具已经支持各种小程序转换)。

二、它的原理是什么?

最初是学了半节课堆和栈,觉得词法分析挺有意思的,再加上转换小程序插件时,发现这些繁琐的操作完全可以使用程序来完成。
核心是使用Babel获取AST(词法分析),然后或使用Babel自带函数增删,或正则分析替换等等操作。
可能有的朋友觉得,这种为啥不是纯正则分析? 纯正则可以解决一部分问题,对于标签与标签内容,其实正则是很难进行区分的哈。

三、它能做哪些事情?

  • 支持微信、QQ、头条/抖音、支付宝/钉钉和百度等小程序转换到 uni-app 项目
  • 支持有/无云开发的小程序项目转换为 uni-app 项目(cloudfunctions 目录将被忽略,uni-app 结合小程序云开发见:使用 uni-app 进行微信小程序云开发经验分享)
  • 支持解析 TypeScript 小程序项目
  • 支持解析使用 npm 模块的小程序项目
  • 支持解析 include 标签
  • 支持解析 template 标签
  • 支持解析 Behavior 文件为 mixins 文件
  • 支持.js', .wxml 和*.wxss 文件进行相应转换,并做了大量的优化
  • 支持识别 App、Page、Component、VantComponent、Behavior 和纯 Javascript 文件的转换
  • 修复变量名与函数重名的情况
  • 合并使用 require 导入的 wxs 文件
  • setData() polyfill
  • 搜索未在 data 声明,而直接在 setData()里使用的变量,并修复
  • 使用jyf-parser替换 wxParse(感谢网友 “爱瑞巴勒康忙北鼻” 的建议)
  • 因 uni-app 会将所有非 static 目录的资源文件删除,因此将所有资源文件移入 static 目录,并修复所有能修复到的路径(目前 uni 编译时会将非 static 目录的文件复制一份到 static 目录,但并不完全,因此本功能仍保留)

四、它还有哪些不支持转换?

  • 不支持转换反编译后的小程序项目
  • 不支持转换使用 uni-app 编译的小程序项目
  • 不支持转换使用 redux 开发的小程序(代表为:网易云信小程序 DEMO)
  • 不支持转换使用 wxpage 开发的小程序(https://github.com/tvfe/wxpage)
  • 不支持转换使用腾讯 omi 开发的小程序(https://github.com/Tencent/omi)
  • 不支持转换小程序抽象节点 componentGenerics
  • 不支持 component 里的 pageLifetimes 生命周期,请手动绕过
  • 不支持使用 js 系统关键字作为函数或变量名(如 default、import、return、switch 等)
  • 不支持以\$开头的变量名称,如 Page({data:{$data:{name:"hello"}}}) ,刚好\$data 是 vue 内置变量,so 不支持,需手动修复
  • 不支持以动态绑定的函数<input @input="test{{index+1}}">,需手动修复
  • 更多,请参照miniprogram to uniapp 工具答疑

五、怎么使用?

第一步

在命令行里,运行【 npm install miniprogram-to-uniapp -g 】进行安装,因为这个包是工具,要求全局都能使用,所以需要-g进行全局安装。
如果运行npm报错,请先安装Node.js,下载地址:https://nodejs.org/zh-cn/

第二步

继续在命令行里,运行【 wtu -V 】,执行结果如下:

显示版本号,说明已经安装成功了。(wtu -> 取自wx to uni之意,后面都用这个全局命令)

第三步

在命令行里,输入【wtu -i "你的小程序项目路径"】
注意 -i 前面和后面都有空格!!!
注意 -i 前面和后面都有空格!!!
注意 -i 前面和后面都有空格!!!
如:【wtu -i "E:\zpWork\Project_self\miniprogram-to-uniapp\test\test-wx-to-uni"】 ,回车后即可以在源项目同及目录得到一个后缀为_uni的目录,即转换成功。

转换前:

转换后:

转换后的项目文件对比(左边是小程序项目,右边是Uni-app项目目录):

第四步

将转换后的xxx_uni项目导入到hbuilder X,
点击菜单 运行--> 运行到小程序模拟器-->微信开发者工具!(如果是使用了vant的项目,请运行到H5,vant项目转换后仅支持H5和app)
点击菜单 运行--> 运行到小程序模拟器-->微信开发者工具!(如果是使用了vant的项目,请运行到H5,vant项目转换后仅支持H5和app)
点击菜单 运行--> 运行到小程序模拟器-->微信开发者工具!(如果是使用了vant的项目,请运行到H5,vant项目转换后仅支持H5和app)
重要的话说三遍!
然后查看转换后的项目运行到小程序,是否可以正常运行无报错!
(因为这种转换非100%,所以至少需要保证 小程序-->uniapp-->小程序仍然能正常运行,再考虑运行到其他小程序或app),
如有报错,请根据miniprogram to uniapp 工具答疑 进行修改,保证无报错,然后再运行到其他平台。

工具升级

因为工具更新比较频繁,安装后,可以使用如下命令进行升级:
npm update miniprogram-to-uniapp -g

注意:

  1. 遇到问题请参考文档:miniprogram to uniapp 工具答疑
  2. github上面的只是源代码。 日常使用,"仅"需要运行【 npm install miniprogram-to-uniapp -g 】进行安装才行,无需下载工具源码。
  3. 每次转换时都会将输出目录清空,请注意代码保存。
  4. 后续会有版本更新,请及时关注并更新~~,可以关注QQ群:780359397 获取最新信息

对于使用有疑问或建议,可以加入QQ群:780359397 进行讨论。

<a target="_blank" href="http://shang.qq.com/wpa/qunwpa?idkey=6cccd111e447ed70ee0c17672a452bf71e7e62cfa6b427bbd746df2d32297b64"><img border="0" src="http://pub.idqqimg.com/wpa/images/group.png" alt="小程序转uni-app讨论群" title="小程序转uni-app讨论群"></a>

因为有朋友使用本工具导致自己文件被删,在此表示抱歉!

this.setData()代码出处:https://ask.dcloud.net.cn/article/35020,在些表示感谢~

转换工具源码:https://github.com/zhangdaren/miniprogram-to-uniapp ,欢迎star和建议~

如有遇到bug或问题,欢迎评论、给出改进建议,感谢~~

21 关注 分享
z***@qq.com m***@gmail.com 7***@qq.com orageBeardApe 邓琪昌 bzliukai 我要 撇横横 8***@qq.com g***@126.com DigitalYu jinjidecj ai666 9***@qq.com heck b***@126.com 2***@qq.com Dlog_帅 灯下等雪 aliang888 876

要回复文章请先登录注册

1***@qq.com

1***@qq.com

作者很厉害,感谢,为什么css样式不直接放在vue.style中,要单独放一个文件引入
2020-03-11 11:57
9***@qq.com

9***@qq.com

牛逼
2020-03-08 20:25
zhangdaren

zhangdaren (作者)

回复 H***@163.com :
老铁,这么多,目前该工具只支持原生小程序项目哇,不支持wepy的,wepy的可以使用我的另一个工具https://github.com/zhangdaren/wepy-to-uniapp,不过改起来可能会有想重新做一次的想法。 也可以加我qq375890534,看看有没有办法吧。
2020-02-20 22:55
zhangdaren

zhangdaren (作者)

回复 1***@163.com :
但其实这个不用改呀,uni做了兼容的哇,,下个版本我研究一下吧(看看支持情况),最近有点小忙,预计下周能完成更新。
2020-02-20 22:52
H***@163.com

H***@163.com

感谢大佬出的工具,但是在 wepy小程序项目转换有问题,我是先把wepy 项目 run build 生成的dist文件夹进行转换替换,替换成功以后运行报了一大堆错误 好像是 v-bind的问题,大佬能指点下有没有好点的解决办法吗?不胜感激!
报错如下
~~~
Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:32.201 (Emitted value instead of an instance of Error)
15:34:32.215 Errors compiling template:
15:34:32.215 class="{{coverDisplay ? 'cover-show' : 'cover-hide'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:32.235 11 | </view>
15:34:32.235 12 | <video style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;" class="home-video" src="https://www.cosstores.cn/img/dm/pageup/190917/COS_TMALL_ESCAPE_WECHAT_VIDEO.mp4" autoplay show-play-btn="false" controls="{{false}}" loop="true" object-fit="fill" muted="true" enable-progress-gesture="false" bindplay="removeCover()">
15:34:32.254 13 | <view id="video-cover" style='height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;' class="{{coverDisplay ? 'cover-show' : 'cover-hide'}}"></view>
15:34:32.255 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:32.271 14 | </video>
15:34:32.272 15 | <!--<image src="https://www.cosstores.cn/img/dm/pageup/191010/Essential_banner.gif" style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;"></image>-->
15:34:32.308 style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div style="{{ val }}">, use <div :style="val">.
15:34:32.309 11 | </view>
15:34:32.325 12 | <video style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;" class="home-video" src="https://www.cosstores.cn/img/dm/pageup/190917/COS_TMALL_ESCAPE_WECHAT_VIDEO.mp4" autoplay show-play-btn="false" controls="{{false}}" loop="true" object-fit="fill" muted="true" enable-progress-gesture="false" bindplay="removeCover()">
15:34:32.344 13 | <view id="video-cover" style='height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;' class="{{coverDisplay ? 'cover-show' : 'cover-hide'}}"></view>
15:34:32.345 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:32.365 14 | </video>
15:34:32.365 15 | <!--<image src="https://www.cosstores.cn/img/dm/pageup/191010/Essential_banner.gif" style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;"></image>-->
15:34:32.386 style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div style="{{ val }}">, use <div :style="val">.
15:34:32.387 10 | <view class="startBtn">开启选购</view>
15:34:32.410 11 | </view>
15:34:32.414 12 | <video style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;" class="home-video" src="https://www.cosstores.cn/img/dm/pageup/190917/COS_TMALL_ESCAPE_WECHAT_VIDEO.mp4" autoplay show-play-btn="false" controls="{{false}}" loop="true" object-fit="fill" muted="true" enable-progress-gesture="false" bindplay="removeCover()">
15:34:32.434 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:32.453 13 | <view id="video-cover" style='height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;' class="{{coverDisplay ? 'cover-show' : 'cover-hide'}}"></view>
15:34:32.453 14 | </video>
15:34:32.471 controls="{{false}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:32.471 10 | <view class="startBtn">开启选购</view>
15:34:32.490 11 | </view>
15:34:32.490 12 | <video style="height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;" class="home-video" src="https://www.cosstores.cn/img/dm/pageup/190917/COS_TMALL_ESCAPE_WECHAT_VIDEO.mp4" autoplay show-play-btn="false" controls="{{false}}" loop="true" object-fit="fill" muted="true" enable-progress-gesture="false" bindplay="removeCover()">
15:34:32.510 | ^^^^^^^^^^^^^^^^^^^^
15:34:32.529 13 | <view id="video-cover" style='height:{{windowHeight}}px; width:{{windowHeight/1920*1080}}px;' class="{{coverDisplay ? 'cover-show' : 'cover-hide'}}"></view>
15:34:32.547 14 | </video>
15:34:32.566 wx:if="{{isShow}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:32.567 1 |
15:34:32.585 2 | <view>
15:34:32.585 3 | <view wx:if="{{isShow}}" class="videoBox" bindtap="enterPage" style="cursor:pointer;position: relative">
15:34:32.602 | ^^^^^^^^^^^^^^^^^^
15:34:32.602 4 | <view class="logo">
15:34:32.620 5 | <image src="https://www.cosstores.cn/img/dm/pageup/191010/logo_img.png"></image>
15:34:32.636 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/homeVideo/homeVideo.vue:0
15:34:32.637 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:32.654 (Emitted value instead of an instance of Error)
15:34:32.654 Errors compiling template:
15:34:32.670 class="{{currentPage===0?'':'hidden'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:32.686 1 |
15:34:32.702 2 | <view>
15:34:32.703 3 | <view class="{{currentPage===0?'':'hidden'}}">
15:34:32.719 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:32.720 4 | <addressList
15:34:32.737 5 | :list.sync="addressList"
15:34:32.737 class="{{currentPage===1?'':'hidden'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:32.753 8 | </addressList>
15:34:32.756 9 | </view>
15:34:32.771 10 | <view class="{{currentPage===1?'':'hidden'}}">
15:34:32.787 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:32.788 11 | <addressAdd
15:34:32.807 12 | @currentPage.user="getCurrentPage"
15:34:32.807 class="{{currentPage===2?'':'hidden'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:32.830 14 | </addressAdd>
15:34:32.856 15 | </view>
15:34:32.876 16 | <view class="{{currentPage===2?'':'hidden'}}">
15:34:32.876 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:32.899 17 | <addressEdit
15:34:32.899 18 | @currentPage.user="getCurrentPage"
15:34:32.922 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/address/address.vue:0
15:34:32.922 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:32.939 (Emitted value instead of an instance of Error)
15:34:32.940 Errors compiling template:
15:34:32.957 controls="{{false}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:32.957 8 | </view>
15:34:32.973 9 | <view class="videoBox">
15:34:32.973 10 | <video style="width:686rpx;height:390rpx" class="home-video" src="https://www.cosstores.cn/img/dm/pageup/191010/COS_Film1_16x9_Grade_FINAL.mp4" show-play-btn="false" controls="{{false}}" loop="true" object-fit="fill" muted="true" enable-progress-gesture="false" bindplay="removeCover()">
15:34:32.990 | ^^^^^^^^^^^^^^^^^^^^
15:34:33.007 11 | </video>
15:34:33.008 12 | </view>
15:34:33.024 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/ServiceCenter/brandstory.vue:0
15:34:33.024 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:33.041 (Emitted value instead of an instance of Error)
15:34:33.041 Errors compiling template:
15:34:33.057 style="height:{{winHeight-150}}px": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div style="{{ val }}">, use <div :style="val">.
15:34:33.057 13 | <scroll-view
15:34:33.073 14 | scroll-y="true"
15:34:33.089 15 | class="swiper-item-box"
15:34:33.090 |
15:34:33.105 16 | style="height:{{winHeight-150}}px"
15:34:33.125 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.151 17 | bindscrolltolower="onReachBottom"
15:34:33.152 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/order/order.vue:0
15:34:33.174 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:33.175 (Emitted value instead of an instance of Error)
15:34:33.194 Errors compiling template:
15:34:33.195 style="height:{{windowHeight-70}}px": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div style="{{ val }}">, use <div :style="val">.
15:34:33.212 1 |
15:34:33.212 2 | <view class="jumpPage" style="height:{{windowHeight}}px">
15:34:33.229 3 | <view class="jump" style="height:{{windowHeight-70}}px">
15:34:33.229 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.246 4 | <text class="skip">跳转中...</text>
15:34:33.262 5 | </view>
15:34:33.262 style="height:{{windowHeight}}px": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div style="{{ val }}">, use <div :style="val">.
15:34:33.278 1 |
15:34:33.279 2 | <view class="jumpPage" style="height:{{windowHeight}}px">
15:34:33.294 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.295 3 | <view class="jump" style="height:{{windowHeight-70}}px">
15:34:33.340 4 | <text class="skip">跳转中...</text>
15:34:33.340 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/item/redirect.vue:0
15:34:33.358 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:33.381 (Emitted value instead of an instance of Error)
15:34:33.395 Errors compiling template:
15:34:33.395 value="{{expressIdx}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:33.411 6 | <view class="listMob">
15:34:33.411 7 | <label>快递公司</label>
15:34:33.429 8 | <picker
15:34:33.446 |
15:34:33.447 9 | value="{{expressIdx}}"
15:34:33.462 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.463 10 | range-key="{{'expressName'}}"
15:34:33.480 range-key="{{'expressName'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:33.480 7 | <label>快递公司</label>
15:34:33.497 8 | <picker
15:34:33.498 9 | value="{{expressIdx}}"
15:34:33.514 |
15:34:33.515 10 | range-key="{{'expressName'}}"
15:34:33.531 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.532 11 | range="{{expressList}}"
15:34:33.550 range="{{expressList}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:33.551 8 | <picker
15:34:33.567 9 | value="{{expressIdx}}"
15:34:33.568 10 | range-key="{{'expressName'}}"
15:34:33.584 |
15:34:33.584 11 | range="{{expressList}}"
15:34:33.600 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.617 12 | bindchange="bindPickerChange"
15:34:33.617 class="a-button is-primary {{expressName&&expressNumber ?'':'btn_invalid'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:33.636 40 | </view>
15:34:33.658 41 | <view class="bottom-section text-center rmaRet">
15:34:33.658 42 | <button class="a-button is-primary {{expressName&&expressNumber ?'':'btn_invalid'}}" @tap="toRmaReturn">提交</button>
15:34:33.682 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.682 43 | </view>
15:34:33.702 44 | </view>
15:34:33.702 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/relogistics/relogistics.vue:0
15:34:33.720 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:33.722 (Emitted value instead of an instance of Error)
15:34:33.739 Errors compiling template:
15:34:33.739 value="{{phone}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:33.755 14 | name="phone"
15:34:33.756 15 | type="number"
15:34:33.772 16 | bindinput="phoneInput"
15:34:33.772 |
15:34:33.788 17 | value="{{phone}}"
15:34:33.788 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.804 18 | placeholder="请输入手机号码"
15:34:33.804 wx:if="{{sendMsgDisabled}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:33.822 27 | <view class="section_input">
15:34:33.823 28 | <view class="btn send_code">
15:34:33.839 29 | <text wx:if="{{sendMsgDisabled}}">{{time+'秒后获取'}}</text>
15:34:33.855 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.856 30 | <text @tap="sendCode" wx:else="{{sendMsgDisabled}}">发送验证码</text>
15:34:33.889 31 | </view>
15:34:33.889 wx:else="{{sendMsgDisabled}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:33.903 28 | <view class="btn send_code">
15:34:33.919 29 | <text wx:if="{{sendMsgDisabled}}">{{time+'秒后获取'}}</text>
15:34:33.936 30 | <text @tap="sendCode" wx:else="{{sendMsgDisabled}}">发送验证码</text>
15:34:33.937 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:33.953 31 | </view>
15:34:33.953 32 | <input class="code"
15:34:33.969 class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:33.986 23 | </view>
15:34:34.002 24 | <view class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}">
15:34:34.003 25 | <view class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}">
15:34:34.020 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.020 26 | <view class="section_title">验证码</view>
15:34:34.036 27 | <view class="section_input">
15:34:34.053 class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:34.069 22 | </view>
15:34:34.086 23 | </view>
15:34:34.102 24 | <view class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}">
15:34:34.103 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.119 25 | <view class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}">
15:34:34.135 26 | <view class="section_title">验证码</view>
15:34:34.154 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/register/register.vue:0
15:34:34.155 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:34.172 (Emitted value instead of an instance of Error)
15:34:34.173 Errors compiling template:
15:34:34.190 wx:if="{{!is_exit_address}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.207 2 | <view class="comfire_order">
15:34:34.224 3 | <view class="address" @tap="setAddress">
15:34:34.224 4 | <view class="empty_address" wx:if="{{!is_exit_address}}">
15:34:34.241 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.258 5 | <view class="title">设置收货地址</view>
15:34:34.275 6 | <view class="iconfont icon-jiantouxiangyou"></view>
15:34:34.276 wx:if="{{address.isDefault===1}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.293 13 | </view>
15:34:34.309 14 | <view class="active_address">
15:34:34.325 15 | <text class="defult" wx:if="{{address.isDefault===1}}"> [默认]</text>
15:34:34.326 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.343 16 | {{address.receiverState}} {{address.receiverCity}} {{address.receiverDistrict}} {{address.receiverAddress}}
15:34:34.360 17 | </view>
15:34:34.376 wx:if="{{orderDetail.discountFee !== '0.00'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.391 26 | <view class="left tongji">订单金额</view>
15:34:34.392 27 | <view class="o-order-summary">
15:34:34.408 28 | <view wx:if="{{orderDetail.discountFee !== '0.00'}}" class="discount-section">
15:34:34.409 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.425 29 | <view class="saleText_2">
15:34:34.440 30 | <span class="discount-label">已优惠</span>
15:34:34.441 wx:if="{{orderDetail.postFee / 1 == 0}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.457 34 | <view class="shipping-section freight">
15:34:34.474 35 | <span class="shipping-label">运费</span>
15:34:34.490 36 | <span class="shipping" wx:if="{{orderDetail.postFee / 1 == 0}}">{{orderDetail.postFee / 1 ? "¥ " + orderDetail.postFee / 1 : "¥ " + 0}}</span>
15:34:34.491 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.507 37 | <span class="shipping" wx:else> {{orderDetail.postFee / 1 ? "¥ " + orderDetail.postFee / 1 : ''}} </span>
15:34:34.507 38 | </view>
15:34:34.523 class="{{!couponShow?'iconfont icon-jiantou32':'iconfont icon-jiantou31'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:34.540 40 | <view wx:if="{{!orderDetail.couponCode}}" class="shipping-label">
15:34:34.557 41 | <view style="margin-left:-2rpx" @tap="couponOpenshow">
15:34:34.557 42 | 优惠券<span class="{{!couponShow?'iconfont icon-jiantou32':'iconfont icon-jiantou31'}}"></span><!-- 箭头朝上类:icon-expand_less -->
15:34:34.575 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.575 43 | </view>
15:34:34.591 44 | <view class="right input_box" hidden="{{!couponShow}}">
15:34:34.608 wx:if="{{ usableCoupon != '' }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.608 47 | <view class="btnStyle" @tap="useCoupon">提交</view>
15:34:34.625 48 | </view>
15:34:34.626 49 | <view wx:if="{{ usableCoupon != '' }}" @tap="couponOpen" style="padding:20rpx 0;text-decoration: underline;">查看可用优惠券</view>
15:34:34.644 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.644 50 | </view>
15:34:34.662 51 | </view>
15:34:34.663 hidden="{{!couponShow}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.680 42 | 优惠券<span class="{{!couponShow?'iconfont icon-jiantou32':'iconfont icon-jiantou31'}}"></span><!-- 箭头朝上类:icon-expand_less -->
15:34:34.681 43 | </view>
15:34:34.700 44 | <view class="right input_box" hidden="{{!couponShow}}">
15:34:34.717 | ^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.737 45 | <view class="coupon_box">
15:34:34.737 46 | <input bindinput="bindKeyInput" placeholder="请输入优惠券" />
15:34:34.756 wx:if="{{!orderDetail.couponCode}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.756 38 | </view>
15:34:34.774 39 | <view class="shipping-section" style="padding:10rpx 0">
15:34:34.774 40 | <view wx:if="{{!orderDetail.couponCode}}" class="shipping-label">
15:34:34.792 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.792 41 | <view style="margin-left:-2rpx" @tap="couponOpenshow">
15:34:34.809 42 | 优惠券<span class="{{!couponShow?'iconfont icon-jiantou32':'iconfont icon-jiantou31'}}"></span><!-- 箭头朝上类:icon-expand_less -->
15:34:34.826 wx:if="{{orderDetail.couponFee !== '0.00'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.826 57 | <view><text style="color: #FF571A;">{{couponMessage}}</text></view>
15:34:34.843 58 | </div>
15:34:34.861 59 | <div wx:if="{{orderDetail.couponFee !== '0.00'}}" class="discount-section">
15:34:34.877 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.892 60 | <span class="discount-label">券减:</span>
15:34:34.892 61 | <span class="discount">{{orderDetail.couponFee / 1 ? "- ¥ " + orderDetail.couponFee : '' }}</span>
15:34:34.909 class="a-radio-button {{ item ? 'is-checked':'' }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:34.909 73 | <radio-group bindchange="radioChange">
15:34:34.926 74 | <view class="m-radio-button u-clearfix u-float-left" wx:for="{{payTypeArr}}" wx:key="*this">
15:34:34.926 75 | <radio class="a-radio-button {{ item ? 'is-checked':'' }}" id="deliveryMode-1" value="{{item}}" />
15:34:34.943 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:34.943 76 | <label class="a-label js-a-label u-no-select custom-radio" for="deliveryMode-1"></label>
15:34:34.960 77 | <label class="a-label js-a-label label-text {{ item == 'Shouqianba'? 'sqb' : ''}}" for="deliveryMode-1">
15:34:34.960 value="{{item}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:34.978 73 | <radio-group bindchange="radioChange">
15:34:34.994 74 | <view class="m-radio-button u-clearfix u-float-left" wx:for="{{payTypeArr}}" wx:key="*this">
15:34:34.995 75 | <radio class="a-radio-button {{ item ? 'is-checked':'' }}" id="deliveryMode-1" value="{{item}}" />
15:34:35.012 | ^^^^^^^^^^^^^^^^
15:34:35.013 76 | <label class="a-label js-a-label u-no-select custom-radio" for="deliveryMode-1"></label>
15:34:35.031 77 | <label class="a-label js-a-label label-text {{ item == 'Shouqianba'? 'sqb' : ''}}" for="deliveryMode-1">
15:34:35.048 wx:if="{{item == 'Wechat'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.049 76 | <label class="a-label js-a-label u-no-select custom-radio" for="deliveryMode-1"></label>
15:34:35.068 77 | <label class="a-label js-a-label label-text {{ item == 'Shouqianba'? 'sqb' : ''}}" for="deliveryMode-1">
15:34:35.085 78 | <p class="a-paragraph option ng-binding icoBg i_weixin" wx:if="{{item == 'Wechat'}}">微信</p>
15:34:35.085 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.103 79 | <p class="a-paragraph option ng-binding icoBg i_weixin" wx:if="{{item == 'Shouqianba'}}">微信</p>
15:34:35.104 80 | </label>
15:34:35.121 wx:if="{{item == 'Shouqianba'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.138 77 | <label class="a-label js-a-label label-text {{ item == 'Shouqianba'? 'sqb' : ''}}" for="deliveryMode-1">
15:34:35.155 78 | <p class="a-paragraph option ng-binding icoBg i_weixin" wx:if="{{item == 'Wechat'}}">微信</p>
15:34:35.156 79 | <p class="a-paragraph option ng-binding icoBg i_weixin" wx:if="{{item == 'Shouqianba'}}">微信</p>
15:34:35.173 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.191 80 | </label>
15:34:35.208 81 | </view>
15:34:35.208 class="a-label js-a-label label-text {{ item == 'Shouqianba'? 'sqb' : ''}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:35.227 75 | <radio class="a-radio-button {{ item ? 'is-checked':'' }}" id="deliveryMode-1" value="{{item}}" />
15:34:35.244 76 | <label class="a-label js-a-label u-no-select custom-radio" for="deliveryMode-1"></label>
15:34:35.244 77 | <label class="a-label js-a-label label-text {{ item == 'Shouqianba'? 'sqb' : ''}}" for="deliveryMode-1">
15:34:35.262 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.281 78 | <p class="a-paragraph option ng-binding icoBg i_weixin" wx:if="{{item == 'Wechat'}}">微信</p>
15:34:35.299 79 | <p class="a-paragraph option ng-binding icoBg i_weixin" wx:if="{{item == 'Shouqianba'}}">微信</p>
15:34:35.300 wx:for="{{payTypeArr}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.318 72 | <view class="title">支付方式</view>
15:34:35.335 73 | <radio-group bindchange="radioChange">
15:34:35.353 74 | <view class="m-radio-button u-clearfix u-float-left" wx:for="{{payTypeArr}}" wx:key="*this">
15:34:35.354 | ^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.385 75 | <radio class="a-radio-button {{ item ? 'is-checked':'' }}" id="deliveryMode-1" value="{{item}}" />
15:34:35.386 76 | <label class="a-label js-a-label u-no-select custom-radio" for="deliveryMode-1"></label>
15:34:35.401 src="{{item.skuImageUrl}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.419 97 | <navigator url="/pages/goods_detail?id={{item.itemId}}&valueId={{item.skuProperties[0].valueId}}&valueName={{item.skuProperties[0].valueName}}" hover-class="none">
15:34:35.437 98 | <view class="img-box">
15:34:35.437 99 | <image src="{{item.skuImageUrl}}" class="img" />
15:34:35.454 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.454 100| </view>
15:34:35.471 101| </navigator>
15:34:35.472 url="/pages/goods_detail?id={{item.itemId}}&valueId={{item.skuProperties[0].valueId}}&valueName={{item.skuProperties[0].valueName}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.489 95 | <view class="list_box">
15:34:35.505 96 | <view class="goods-info">
15:34:35.506 97 | <navigator url="/pages/goods_detail?id={{item.itemId}}&valueId={{item.skuProperties[0].valueId}}&valueName={{item.skuProperties[0].valueName}}" hover-class="none">
15:34:35.522 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.522 98 | <view class="img-box">
15:34:35.539 99 | <image src="{{item.skuImageUrl}}" class="img" />
15:34:35.556 wx:for="{{item.discounts}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.574 104| <view wx:if="{{item.discounts != null && item.discounts.length > 0}}">
15:34:35.574 105| <view class="saleTab">
15:34:35.592 106| <block wx:for="{{item.discounts}}" wx:key="index" wx:for-item="discounts">
15:34:35.592 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.611 107| <span>{{discounts.discountName + " "}}</span>
15:34:35.611 108| </block>
15:34:35.628 wx:if="{{item.discounts != null && item.discounts.length > 0}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.646 102| <view class="text-box">
15:34:35.663 103| <!-- 促销 -->
15:34:35.664 104| <view wx:if="{{item.discounts != null && item.discounts.length > 0}}">
15:34:35.680 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.697 105| <view class="saleTab">
15:34:35.715 106| <block wx:for="{{item.discounts}}" wx:key="index" wx:for-item="discounts">
15:34:35.715 url="/pages/goods_detail?id={{item.itemId}}&valueId={{item.skuProperties[0].valueId}}&valueName={{item.skuProperties[0].valueName}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.735 109| </view>
15:34:35.752 110| </view>
15:34:35.753 111| <navigator url="/pages/goods_detail?id={{item.itemId}}&valueId={{item.skuProperties[0].valueId}}&valueName={{item.skuProperties[0].valueName}}" hover-class="none">
15:34:35.771 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.788 112| <view class="goods-title">{{item.itemName}}</view>
15:34:35.804 113| </navigator>
15:34:35.805 for="{{list}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.822 92 | <view class="goodsList">
15:34:35.822 93 | <view class="left tongji">订单商品</view>
15:34:35.839 94 | <repeat for="{{list}}" key="index" index="index" item="item">
15:34:35.855 | ^^^^^^^^^^^^^^
15:34:35.856 95 | <view class="list_box">
15:34:35.887 96 | <view class="goods-info">
15:34:35.888 wx:if="{{isShowNotice}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.902 129|
15:34:35.918 130| <!-- 弹窗 -->
15:34:35.935 131| <errorTip wx:if="{{isShowNotice}}" v-on:clickTap="isShow" :itemName.sync="itemName"></errorTip>
15:34:35.935 | ^^^^^^^^^^^^^^^^^^^^^^^^
15:34:35.951 132| <loading :showLoaded.sync="showLoaded"></loading>
15:34:35.952 133|
15:34:35.967 data-couponCode="{{item.couponCode}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:35.967 139| </view>
15:34:35.984 140| <view class="coucontent" wx:for="{{usableCoupon}}" wx:key='index'>
15:34:36.000 141| <view class="cousubstance" data-couponCode="{{item.couponCode}}" data-ruleName="{{item['couponRule'].ruleName}}" @tap="useCoupon">
15:34:36.000 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.017 142| <h4>{{item['couponRule'].ruleName}}</h4>
15:34:36.018 143| <view class="description" >{{item['couponRule'].description}}</view>
15:34:36.033 data-ruleName="{{item['couponRule'].ruleName}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.050 139| </view>
15:34:36.067 140| <view class="coucontent" wx:for="{{usableCoupon}}" wx:key='index'>
15:34:36.067 141| <view class="cousubstance" data-couponCode="{{item.couponCode}}" data-ruleName="{{item['couponRule'].ruleName}}" @tap="useCoupon">
15:34:36.083 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.101 142| <h4>{{item['couponRule'].ruleName}}</h4>
15:34:36.116 143| <view class="description" >{{item['couponRule'].description}}</view>
15:34:36.117 wx:for="{{usableCoupon}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.150 138| <view class="iconfont icon-cuowu1" bindtap="closeCoupon"></view>
15:34:36.150 139| </view>
15:34:36.167 140| <view class="coucontent" wx:for="{{usableCoupon}}" wx:key='index'>
15:34:36.167 | ^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.184 141| <view class="cousubstance" data-couponCode="{{item.couponCode}}" data-ruleName="{{item['couponRule'].ruleName}}" @tap="useCoupon">
15:34:36.185 142| <h4>{{item['couponRule'].ruleName}}</h4>
15:34:36.201 wx:if="{{getCoupon == 1 && usableCoupon.length > 0 }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.201 133|
15:34:36.218 134| <!-- 优惠券弹窗 -->
15:34:36.236 135| <view wx:if="{{getCoupon == 1 && usableCoupon.length > 0 }}">
15:34:36.237 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.254 136| <view class="couponItem" >
15:34:36.255 137| <view style="height:25px;">
15:34:36.272 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/confirmOrder/confirmOrder.vue:0
15:34:36.272 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:36.289 (Emitted value instead of an instance of Error)
15:34:36.289 Errors compiling template:
15:34:36.306 wx:if="{{comeRoute =='pages/relogistics'}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.306 1 |
15:34:36.323 2 | <view class="rma-success">
15:34:36.323 3 | <h4 wx:if="{{comeRoute =='pages/relogistics'}}">提交成功 等待退款</h4>
15:34:36.340 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.340 4 | <view wx:else>
15:34:36.357 5 | <h4><i class="iconfont icon-ok"></i>申请成功 请等待审核</h4>
15:34:36.372 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/applySuccess/applySuccess.vue:0
15:34:36.387 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:36.388 (Emitted value instead of an instance of Error)
15:34:36.403 Errors compiling template:
15:34:36.419 wx:if="{{customerInfo.mobile}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.435 4 | <view class="section" >
15:34:36.436 5 | <view class="section_title">手机号
15:34:36.452 6 | <text style="margin-left: 400rpx" wx:if="{{customerInfo.mobile}}">{{customerInfo.mobile}}</text>
15:34:36.452 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.468 7 | </view>
15:34:36.468 8 | <view class="section_input" wx:if="{{!customerInfo.mobile}}">
15:34:36.485 value="{{phone}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.501 16 | name="phone"
15:34:36.502 17 | type="number"
15:34:36.518 18 | bindinput="phoneInput"
15:34:36.535 |
15:34:36.551 19 | value="{{phone}}"
15:34:36.552 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.568 20 | placeholder="请输入手机号码"
15:34:36.585 wx:if="{{!customerInfo.mobile}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.602 6 | <text style="margin-left: 400rpx" wx:if="{{customerInfo.mobile}}">{{customerInfo.mobile}}</text>
15:34:36.602 7 | </view>
15:34:36.618 8 | <view class="section_input" wx:if="{{!customerInfo.mobile}}">
15:34:36.619 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.637 9 | <button
15:34:36.637 10 | open-type="getPhoneNumber"
15:34:36.653 wx:if="{{sendMsgDisabled}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.653 29 | <view class="section_input">
15:34:36.670 30 | <view class="btn send_code">
15:34:36.685 31 | <text wx:if="{{sendMsgDisabled}}">{{time+'秒后获取'}}</text>
15:34:36.686 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.703 32 | <text @tap="sendCode" wx:else="{{sendMsgDisabled}}">发送验证码</text>
15:34:36.704 33 | </view>
15:34:36.720 wx:else="{{sendMsgDisabled}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.720 30 | <view class="btn send_code">
15:34:36.736 31 | <text wx:if="{{sendMsgDisabled}}">{{time+'秒后获取'}}</text>
15:34:36.752 32 | <text @tap="sendCode" wx:else="{{sendMsgDisabled}}">发送验证码</text>
15:34:36.752 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.769 33 | </view>
15:34:36.769 34 | <input class="code"
15:34:36.785 class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:36.802 25 | </view>
15:34:36.819 26 | <view class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}">
15:34:36.820 27 | <view wx:if="{{!customerInfo.mobile}}" class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}">
15:34:36.837 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.837 28 | <view class="section_title">验证码</view>
15:34:36.854 29 | <view class="section_input">
15:34:36.855 wx:if="{{!customerInfo.mobile}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.888 25 | </view>
15:34:36.888 26 | <view class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}">
15:34:36.904 27 | <view wx:if="{{!customerInfo.mobile}}" class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}">
15:34:36.904 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.922 28 | <view class="section_title">验证码</view>
15:34:36.922 29 | <view class="section_input">
15:34:36.940 wx:if="{{!customerInfo.mobile}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:36.940 41 | </view>
15:34:36.957 42 |
15:34:36.957 43 | <view class="section" wx:if="{{!customerInfo.mobile}}">
15:34:36.974 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:36.975 44 | <view class="options_item">
15:34:36.991 45 | <checkbox-group bindchange="checkboxChange">
15:34:36.991 class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:37.009 24 | </view>
15:34:37.026 25 | </view>
15:34:37.026 26 | <view class="{{(authorized && getPhone !== 0) ? 'fade_in':'' }} {{(authorized === false && getPhone !== 0) ? 'fade_out':'' }}">
15:34:37.042 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.060 27 | <view wx:if="{{!customerInfo.mobile}}" class="section {{(authorized && getPhone !== 0) ? 'zIndexDown':'' }} {{(authorized === false && getPhone !== 0) ? 'zIndexUp':'' }}">
15:34:37.078 28 | <view class="section_title">验证码</view>
15:34:37.078 wx:if="{{showJoin == 1}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.096 1 |
15:34:37.096 2 | <view>
15:34:37.112 3 | <form bindsubmit="formSubmit" wx:if="{{showJoin == 1}}">
15:34:37.129 | ^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.147 4 | <view class="section" >
15:34:37.147 5 | <view class="section_title">手机号
15:34:37.164 class="swiper-tab-list {{currentTab==index ? 'active' : ''}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:37.181 106| <view class="list_block" wx:if="{{showJoin == 0}}">
15:34:37.198 107| <view class="swiper-tab">
15:34:37.199 108| <view wx:for="{{tabList}}" wx:key="index" class="swiper-tab-list {{currentTab==index ? 'active' : ''}}" data-current="{{index}}" bindtap="getCurrentTab">
15:34:37.217 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.217 109| {{item.name ? item.name: item }}
15:34:37.234 110| </view>
15:34:37.250 wx:for="{{tabList}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.267 106| <view class="list_block" wx:if="{{showJoin == 0}}">
15:34:37.267 107| <view class="swiper-tab">
15:34:37.283 108| <view wx:for="{{tabList}}" wx:key="index" class="swiper-tab-list {{currentTab==index ? 'active' : ''}}" data-current="{{index}}" bindtap="getCurrentTab">
15:34:37.300 | ^^^^^^^^^^^^^^^^^^^^
15:34:37.317 109| {{item.name ? item.name: item }}
15:34:37.317 110| </view>
15:34:37.333 data-current="{{index}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.351 106| <view class="list_block" wx:if="{{showJoin == 0}}">
15:34:37.366 107| <view class="swiper-tab">
15:34:37.381 108| <view wx:for="{{tabList}}" wx:key="index" class="swiper-tab-list {{currentTab==index ? 'active' : ''}}" data-current="{{index}}" bindtap="getCurrentTab">
15:34:37.381 | ^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.398 109| {{item.name ? item.name: item }}
15:34:37.415 110| </view>
15:34:37.434 wx:if="{{showInfo}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.434 110| </view>
15:34:37.450 111| </view>
15:34:37.467 112| <view wx:if='{{showInfo}}'>
15:34:37.484 | ^^^^^^^^^^^^^^^^^^^^
15:34:37.484 113| <view class="item_bock">
15:34:37.500 114| <view class="title">昵称:</view>
15:34:37.517 wx:if="{{showGrowth}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.533 128| </view>
15:34:37.534 129| </view>
15:34:37.550 130| <view wx:if='{{showGrowth}}'>
15:34:37.550 | ^^^^^^^^^^^^^^^^^^^^^^
15:34:37.567 131| <view class="image">
15:34:37.583 132| <view class="xiala">
15:34:37.600 wx:if="{{showJoin == 0}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.601 104| </form>
15:34:37.617 105|
15:34:37.634 106| <view class="list_block" wx:if="{{showJoin == 0}}">
15:34:37.651 | ^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.651 107| <view class="swiper-tab">
15:34:37.667 108| <view wx:for="{{tabList}}" wx:key="index" class="swiper-tab-list {{currentTab==index ? 'active' : ''}}" data-current="{{index}}" bindtap="getCurrentTab">
15:34:37.667 at /Users/tiamo/work/uniapp/stroies-miniprogram-store/pages/setting/setting.vue:0
15:34:37.684 Module Error (from ./node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js):
15:34:37.700 (Emitted value instead of an instance of Error)
15:34:37.717 Errors compiling template:
15:34:37.717 wx:if="{{isShowCustomNavBar}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.734 1 |
15:34:37.734 2 | <view>
15:34:37.750 3 | <navBar
15:34:37.767 |
15:34:37.767 4 | wx:if="{{isShowCustomNavBar}}"
15:34:37.783 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.784 5 | :navbarData.sync="navbarData"
15:34:37.800 value="{{keyword}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:37.817 20 | class="search_input"
15:34:37.833 21 | placeholder-class="phcolor"
15:34:37.834 22 | placeholder="搜索商品"
15:34:37.851 |
15:34:37.851 23 | value="{{keyword}}"
15:34:37.885 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.885 24 | confirm-type="search"
15:34:37.900 duplicate attribute: animation
15:34:37.900 37 | friction="10"
15:34:37.917 38 | inertia="true"
15:34:37.934 39 | direction="all"
15:34:37.934 |
15:34:37.950 40 | animation="{{moveAnimation}}"
15:34:37.967 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:37.983 41 | >
15:34:37.984 x="{{x}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:38.000 31 | <movable-area style="width:100vw;height:{{whMovablearea}}">
15:34:38.001 32 | <movable-view
15:34:38.017 33 | style="z-index:1000;"
15:34:38.033 |
15:34:38.034 34 | x="{{x}}"
15:34:38.050 | ^^^^^^^^^^^^^^^
15:34:38.051 35 | y="{{y}}"
15:34:38.067 y="{{y}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:38.067 32 | <movable-view
15:34:38.084 33 | style="z-index:1000;"
15:34:38.084 34 | x="{{x}}"
15:34:38.100 |
15:34:38.117 35 | y="{{y}}"
15:34:38.117 | ^^^^^^^^^^^^^^^
15:34:38.133 36 | animation="false"
15:34:38.134 animation="{{moveAnimation}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:38.150 37 | friction="10"
15:34:38.151 38 | inertia="true"
15:34:38.167 39 | direction="all"
15:34:38.167 |
15:34:38.184 40 | animation="{{moveAnimation}}"
15:34:38.184 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:38.200 41 | >
15:34:38.217 class="nav_item {{index === currentIndexNav? 'active' : ''}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div class="{{ val }}">, use <div :class="val">.
15:34:38.234 58 | data-isSort="{{item.parameters.hideSort}}"
15:34:38.251 59 | data-isFilter="{{item.parameters.showFilter}}"
15:34:38.267 60 | data-isSpecial="{{item.parameters.isSpecial}}"
15:34:38.267 |
15:34:38.284 61 | class="nav_item {{index === currentIndexNav? 'active' : ''}}"
15:34:38.284 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:38.300 62 | >
15:34:38.301 wx:if="{{item.visible}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:38.317 50 | <scroll-view scroll-x>
15:34:38.318 51 | <block wx:for="{{threeChildcateList}}" wx:key="index">
15:34:38.334 52 | <view
15:34:38.334 |
15:34:38.351 53 | wx:if="{{item.visible}}"
15:34:38.351 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:38.367 54 | @tap="activeNav"
15:34:38.382 data-index="{{index}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:38.395 52 | <view
15:34:38.396 53 | wx:if="{{item.visible}}"
15:34:38.411 54 | @tap="activeNav"
15:34:38.411 |
15:34:38.425 55 | data-index="{{index}}"
15:34:38.426 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15:34:38.440 56 | data-classId="{{item.foreignId}}"
15:34:38.441 data-classId="{{item.foreignId}}": Interpolation inside attributes has been removed. Use v-bind or the colon shorthand instead. For example, instead of <div id="{{ val }}">, use <div :id="val">.
15:34:38.455 53 | wx:if="{{item.visible}}"
15:34:38.470 54 | @tap="activeNav"
15:34:38.485 55 | data-index="{{index}}"
15:34:38.485 |
2020-02-20 16:05
1***@163.com

1***@163.com

回复 zhangdaren :
页面上的图片路径 不会调整过来,希望大佬下个版本可以把小程序的API方法转成uni方法这个应该不难吧,你要是转了 我们就不用一个个去找着把wx改成uni了
2020-02-19 17:58
zhangdaren

zhangdaren (作者)

回复 1***@163.com :
最近发现 可以使用/来表示根路径了,下版转换后的路径会更精简,没那么长了。
你说的如果是static同级image路径应该不用?这个我再测试一下,现在所知道的是uni-app在编译时,会将非static目录的文件,复制一份并重名后放在static里,但似乎对于tabbar的icon没有调整(不知道新版调整没),,而对于src="'img/' + url" 这种也是没有办法,下版本更新前,会再次审视这种路径优化哈。
2020-02-19 17:42
1***@163.com

1***@163.com

回复 1***@163.com :
大神你可设置 如果小程序image是在外面的 就不要放到static里面去 还是放在外面 那样就不用手动调路径了,哈哈哈,不过你这个程序总体来说还是非常节省时间的,感谢大佬!
2020-02-19 10:30
1***@163.com

1***@163.com

有图片的image文件夹在static里面 外面的image文件夹里面是空的
2020-02-19 10:24
jinjidecj

jinjidecj

大神!支持!
2020-02-16 20:13