pull/1/head
张萌 3 years ago
commit a223744ce3

@ -605,21 +605,26 @@ class _EventDetailPageState extends State<EventDetailPage> {
minWidth: 120.w, minWidth: 120.w,
height: 55.w, height: 55.w,
onPressed: () async { onPressed: () async {
var res = await NetUtil() if (_textEditingController.text.trim().isEmptyOrNull) {
.post(SAASAPI.community.commentInsert, params: params); BotToast.showText(text: '请填写内容');
if (res.success) { return;
_textEditingController.clear(); }else{
if (_rootId == 0) { var res = await NetUtil()
_refreshController.callRefresh(); .post(SAASAPI.community.commentInsert, params: params);
if (res.success) {
_textEditingController.clear();
if (_rootId == 0) {
_refreshController.callRefresh();
} else {
await updateComments();
_focusNode.unfocus();
}
setState(() {});
} else { } else {
await updateComments(); BotToast.showText(text: res.msg);
_focusNode.unfocus();
} }
setState(() {}); FocusScope.of(context).requestFocus(FocusNode());
} else {
BotToast.showText(text: res.msg);
} }
FocusScope.of(context).requestFocus(FocusNode());
}, },
child: Text( child: Text(
'发布', '发布',

@ -224,6 +224,7 @@ class MyCommunityViewState extends State<MyCommunityView>
), ),
50.wb, 50.wb,
Column( Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Container( Container(
width: 552.w, width: 552.w,

Loading…
Cancel
Save