|
- // 打开相册
- function openImg() {
- api.getPicture({
- sourceType: 'album',
- encodingType: 'png',
- mediaValue: 'pic',
- destinationType: 'url',
- allowEdit: false,
- quality: 70,
- // targetWidth: 100,
- // targetHeight: 100,
- saveToPhotoAlbum: false
- }, function(ret, err) {
- if (ret) {
- console.log(JSON.stringify(ret))
- } else {
- alert(JSON.stringify(err.msg));
- }
- });
- }
复制代码 |
|