效果# # #
“编辑和共享”页包括:

# ### 3。` share & amp# 039;页面
Share页面是多行输入框& amp# 039;textarea & amp# 039;图片选择按钮& amp# 039;button & amp# 039;共享按钮& amp# 039;button & amp# 039;是。
下面是“` `”。
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
Textarea placeholder=& amp# 039;文案输入& amp# 039;bindblur=& amp# 039;bindTextAreaBlur & amp# 039;
Value=& amp# 039;{ { details } } & amp# 039;class=& amp# 039;text & amp# 039;/textarea
Input\n\n/input
Button bind tap=& amp# 039;seleteanduploadpicture & amp# 039;
Image src=& amp# 039;Fm=26gp=0.jpg & amp# 039;/图像
/button
Input\n\n/input
Button bindtap=& amp# 039;共享和amp# 039;共享/button
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
下面是“` `”。
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
Constdb=wx.cloud.database()。集合(& amp# 039;pyq & amp# 039;)
页面({
Data: {
详细资料: & amp# 039;& amp# 039;
ImgURL: & amp# 039;& amp# 039;是
},
bindtextareablur 3360 function(e){
con);
Var that=this
({
Details: e.de
});
},
SeleteAndUploadPicture() {
Let that=this
Wx.chooseImage({
Count: 1、
size type :[& amp;# 039;original & amp# 039;& amp# 039;compressed & amp# 039;],
source type :[& amp;# 039;album & amp# 039;& amp# 039;camera & amp# 039;],
Success: RES={
con(& amp;# 039;choose successfully & amp# 039;RES)
({
imgurl : RES . tempfile paths[0]
})
},
Fail(res) {
con(& amp;# 039;choose failed & amp# 039;RES)
}
})
},
Share() {
con(& amp;# 039;调用share的方法& amp# 039;)
Let that=this
Wx.cloud.uploadFile({
Cloudpath : new date()。get time()& amp;# 039;png & amp# 039;
文件路径://文件路径
Success: function (res) {
con(& amp;# 039;upload successfully & amp# 039;RES)
({
ImgURL: res.fileID
})
},
Fail(res) {
con(& amp;# 039;upload failed & amp# 039;RES)
}
})
DB.add({
Data: {
Descption:
ImgURL:
},
Success(res) {
con(& amp;# 039;share成功& amp# 039;RES)
Wx.navigateTo(
Url: & amp# 039;/./pages/pyq/pyq & amp;# 039;
})
Wx.showToast({
标题: & amp# 039;成功& amp# 039;
Icon: & amp# 039;success & amp# 039;
Duration: 2000
})
},
Fail(res) {
con(& amp;# 039;share失败& amp# 039;RES)
}
})
}
})
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
下面是“` `”。
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
.text{
/* height 3360 100 rpx;
line-height : 100 rpx;*/
width : 100%;
Font-size: 60rpx:
background-color : # BFA;
}
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
# ### 4。` pyq & amp# 039;页面
下面是“` `”。
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
View{{index}} : {{i}}/view
Image src=& amp# 039;{ { I } & amp;# 039;/image
View\n/view
/view
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
下面是“` `”。
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
Constdb=wx.cloud.database()。集合(& amp# 039;pyq & amp# 039;)
页面({
Data: {
Array: []
},
OnLoad() {
Let that=this
DB.get({
Success(res) {
({
Array3360res.data
})
for(let I=0;I RES . da;I) {
Con[i]。descption)
Con[i]。imgURL)
}
}
})
}
})
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。
` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` ` `。