12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364 |
- <template>
- <view class="content">
- <view class="top"></view>
- <view class="te"></view>
- <image @click="previewImage" src="http://dmsimg.66km.com/thFiles/7C057545-E11E-40F5-AD3C-637EF653B417.jpg" mode=""></image>
-
- </view>
- </template>
- <script>
-
- export default {
- data() {
- return {
- ImageList: [
- {
- imgUrl:"http://dmsimg.66km.com/thFiles/7C057545-E11E-40F5-AD3C-637EF653B417.jpg",
- acronymUrl:"http://dmsimg.66km.com/thFiles/7C057545-E11E-40F5-AD3C-637EF653B417.jpg",
- picture:false,
- }
- ]
- }
- },
- onLoad() {
-
- },
- methods: {
- previewImage(){
- var arr = [];
- var img='http://dmsimg.66km.com/thFiles/7C057545-E11E-40F5-AD3C-637EF653B417.jpg'
- arr.push(img)
-
- // 预览图片
- uni.previewImage({
- urls: arr,
- current: img,
- longPressActions: {
- itemList: ['发送给朋友', '保存图片', '收藏'],
- success: function(data) {
- console.log('选中了第' + (data.tapIndex + 1) + '个按钮,第' + (data.index + 1) + '张图片');
- },
- fail: function(err) {
- console.log(err.errMsg);
- }
- }
- });
- }
- }
- }
- </script>
- <style scoped>
- .top{
- width: 100vw;
- height: 20px;
- background: red;
- }
- .te{
- width: 960px;
- height: 20px;
- background: yellow;
- }
- </style>
|