k***@sina.com
k***@sina.com
  • 发布:2021-01-14 13:10
  • 更新:2021-01-21 18:08
  • 阅读:1060

【报Bug】uniCloud Admin菜单显示错误

分类:uni-app

产品分类: uniapp/App

PC开发环境操作系统: Windows

PC开发环境操作系统版本号: window 10

HBuilderX类型: 正式

HBuilderX版本号: 3.0.5

手机系统: iOS

手机系统版本号: iOS 13.2

手机厂商: 苹果

手机机型: ipad air 3

页面类型: vue

打包方式: 云端

项目创建方式: HBuilderX

操作步骤:

启动uniCloud Admin,插入自定义菜单

预期结果:

正确显示自定义菜单和原有系统管理菜单

实际结果:

显示
《自定义菜单》
undefined
undefined

bug描述:

此错误在ipad和android pad上都出现

uniCloud Admin 中的添加了自定义菜单后,自定义菜单可以显示,原有的系统设置菜单无法显示,uni-menu-sidebar.vue 报错如下:

12:56:39.222 uniCloud admin 当前版本号:, 1.2.9 at App.vue:26
12:56:39.242 App Show at App.vue:36
12:56:40.246 [Object] {"userInfo":{"_id":"5ffe9755bbbf9b0001501055","username":"QWERTY","role":["admin"],"register_date":1610520...} at store/modules/app.js:36
12:58:31.624 App Hide at App.vue:39
13:00:41.057 App Show at App.vue:36
13:00:42.076 [Vue warn]: Error in render: "TypeError: Attempted to assign to readonly property."
13:00:42.097 found in
13:00:42.118 ---> <UniMenuSidebar> at components/uni-menu-sidebar/uni-menu-sidebar.vue:1
13:00:42.139     <UniNavMenu> at components/uni-nav-menu/uni-nav-menu.vue:1
13:00:42.160      <LeftWindow> at windows/leftWindow.vue:1
13:00:42.181       <FixWindow> at components/fix-window/fix-window.vue:1
13:00:42.201        at pages/system/menu/list.vue:1 ERROR
13:00:42.221 TypeError: Attempted to assign to readonly property.
ERROR
13:00:42.242 cid unmatched [object Object]
13:00:42.262 TypeError: Invalid attempt to destructure non-iterable instance.
13:00:42.283 In order to be iterable, non-array objects must have a [Symbol.iterator]() method.
13:00:42.303 cid unmatched [object Object]
13:00:42.324 TypeError: Invalid attempt to destructure non-iterable instance.
13:00:42.344 In order to be iterable, non-array objects must have a [Symbol.iterator]() method.
13:00:42.364 cid unmatched [object Object]
13:00:42.384 TypeError: Invalid attempt to destructure non-iterable instance.
13:00:42.405 In order to be iterable, non-array objects must have a [Symbol.iterator]() method.
13:00:42.426 cid unmatched [object Object]
13:00:42.446 TypeError: Invalid attempt to destructure non-iterable instance.
13:00:42.466 In order to be iterable, non-array objects must have a [Symbol.iterator]() method.

发现uni-menu-sidebar.vue line:5 <template v-if="!item.children || !item.children.length">
对item.children的访问出错,怀疑是包装过程中出现错误。

在其上一行插入代码 <view style="display: none;">{{item.children}}</view>
可以暂时消除错误。

望详查。

2021-01-14 13:10 负责人:无 分享
已邀请:
7***@qq.com

7***@qq.com

确实会出现这问题,我打包成安卓的动态菜单全是undefined。用你的方式解决了。

jxtian

jxtian

下一版 HBuilderX alpha 3.0.8 已修复,即将发布

该问题目前已经被锁定, 无法添加新回复