2***@qq.com
2***@qq.com
  • 发布:2020-09-23 18:48
  • 更新:2022-03-24 21:07
  • 阅读:711

关于相册国际化失效问题

分类:uni-app

按照官网的建议配置了一下, 发现应用名称是随着系统改变了, 但是相册内的国际化并没有随之改变, 不知道是哪里写错了, 还是bug(每次修改都重新打包过自定义基座, 也尝试过正式发布, 但同样不好使)

manifest.json文档说明
应用云端打包国际化处理

manifest.json代码如下:

"app-plus" : {  
        "locales" : {  
            "zh" : {  
                //中文(简体)  
                "name" : "应用名称",  
                "android" : {  
                    "strings" : {  
                        //Android平台自定义字符串    
                        "dcloud_gallery_library_name" : "Media Selector",  
                        "dcloud_gallery_all_dir_name" : "All Photo&Video",  
                        "dcloud_gallery_all_video" : "All Video",  
                        "dcloud_gallery_all_image" : "All Photo",  
                        "dcloud_gallery_select_title" : "Choose Photo&Video",  
                        "dcloud_gallery_select_video_title" : "Choose Video",  
                        "dcloud_gallery_select_image_title" : "Choose Photo",  
                        "dcloud_gallery_video_dir_name" : "All Video",  
                        "dcloud_gallery_msg_amount_limit" : "已达到选择数量上限222",  
                        "dcloud_gallery_msg_size_limit" : "请压缩和剪切后上传,文件最大只支持222",  
                        "dcloud_gallery_select_null" : "Choose File",  
                        "dcloud_gallery_done" : "Done",  
                        "dcloud_gallery_count_string" : "",  
                        "dcloud_gallery_preview" : "Preview",  
                        "dcloud_gallery_select" : "Select",  
                        "dcloud_gallery_video" : "Video",  
                        "dcloud_gallery_cant_play_video" : "没有可以播放的程序222",  
                        "dcloud_gallery_read_external_storage" : "需要打开读取存储权限222"  
                    }  
                },  
                "ios" : {  
                    "infoPlist" : {  
                        //iOS平台自定义InfoPlist.strings    
                        "dcloud_gallery_library_name" : "Media Selector",  
                        "dcloud_gallery_all_dir_name" : "All Photo&Video",  
                        "dcloud_gallery_all_video" : "All Video",  
                        "dcloud_gallery_all_image" : "All Photo",  
                        "dcloud_gallery_select_title" : "Choose Photo&Video",  
                        "dcloud_gallery_select_video_title" : "Choose Video",  
                        "dcloud_gallery_select_image_title" : "Choose Photo",  
                        "dcloud_gallery_video_dir_name" : "All Video",  
                        "dcloud_gallery_msg_amount_limit" : "已达到选择数量上限222",  
                        "dcloud_gallery_msg_size_limit" : "请压缩和剪切后上传,文件最大只支持222",  
                        "dcloud_gallery_select_null" : "Choose File",  
                        "dcloud_gallery_done" : "Done",  
                        "dcloud_gallery_count_string" : "",  
                        "dcloud_gallery_preview" : "Preview",  
                        "dcloud_gallery_select" : "Select",  
                        "dcloud_gallery_video" : "Video",  
                        "dcloud_gallery_cant_play_video" : "没有可以播放的程序222",  
                        "dcloud_gallery_read_external_storage" : "需要打开读取存储权限222"  
                    }  
                }  
            },  
            "en" : {  
                //日文  
                "name" : "program",  
                "android" : {  
                    "strings" : {  
                        //Android平台自定义字符串    
                        "dcloud_gallery_library_name" : "Media Selector",  
                        "dcloud_gallery_all_dir_name" : "All Photo&Video",  
                        "dcloud_gallery_all_video" : "All Video",  
                        "dcloud_gallery_all_image" : "All Photo",  
                        "dcloud_gallery_select_title" : "Choose Photo&Video",  
                        "dcloud_gallery_select_video_title" : "Choose Video",  
                        "dcloud_gallery_select_image_title" : "Choose Photo",  
                        "dcloud_gallery_video_dir_name" : "All Video",  
                        "dcloud_gallery_msg_amount_limit" : "已达到选择数量上限222",  
                        "dcloud_gallery_msg_size_limit" : "请压缩和剪切后上传,文件最大只支持222",  
                        "dcloud_gallery_select_null" : "Choose File",  
                        "dcloud_gallery_done" : "Done",  
                        "dcloud_gallery_count_string" : "",  
                        "dcloud_gallery_preview" : "Preview",  
                        "dcloud_gallery_select" : "Select",  
                        "dcloud_gallery_video" : "Video",  
                        "dcloud_gallery_cant_play_video" : "没有可以播放的程序222",  
                        "dcloud_gallery_read_external_storage" : "需要打开读取存储权限222"  
                    }  
                },  
                "ios" : {  
                    "infoPlist" : {  
                        //iOS平台自定义InfoPlist.strings    
                        "dcloud_gallery_library_name" : "Media Selector",  
                        "dcloud_gallery_all_dir_name" : "All Photo&Video",  
                        "dcloud_gallery_all_video" : "All Video",  
                        "dcloud_gallery_all_image" : "All Photo",  
                        "dcloud_gallery_select_title" : "Choose Photo&Video",  
                        "dcloud_gallery_select_video_title" : "Choose Video",  
                        "dcloud_gallery_select_image_title" : "Choose Photo",  
                        "dcloud_gallery_video_dir_name" : "All Video",  
                        "dcloud_gallery_msg_amount_limit" : "已达到选择数量上限222",  
                        "dcloud_gallery_msg_size_limit" : "请压缩和剪切后上传,文件最大只支持222",  
                        "dcloud_gallery_select_null" : "Choose File",  
                        "dcloud_gallery_done" : "Done",  
                        "dcloud_gallery_count_string" : "",  
                        "dcloud_gallery_preview" : "Preview",  
                        "dcloud_gallery_select" : "Select",  
                        "dcloud_gallery_video" : "Video",  
                        "dcloud_gallery_cant_play_video" : "没有可以播放的程序222",  
                        "dcloud_gallery_read_external_storage" : "需要打开读取存储权限222"  
                    }  
                }  
            }  
        }  
}

这边是页面代码:

plus.gallery.pick(async (res)=>{  

    this.imageList=[];  
    console.log(res)  
    this.imageList.push(res);  

},(err)=>{  
console.log(err)  
},{  
    maximum: 1,  
    multiple: false,  
    filter:"image"  
});
2020-09-23 18:48 负责人:无 分享
已邀请:
8***@qq.com

8***@qq.com

插个眼

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