toChatPage method
dynamic
toChatPage(
- String jid
)
Implementation
toChatPage(String jid) {
if (jid.isNotEmpty) {
///Future delayed is added here, as the chat page is opened and closed by QA team rapidly and repeatedly.
///So to avoid the controller delete after new controller created with same jid, added this delay.
Future.delayed(
const Duration(milliseconds: 200),
() => NavUtils.toNamed(Routes.chat,
arguments:
ChatViewArguments(chatJid: jid, topicId: topicId.value)));
// NavUtils.toNamed(Routes.chat, arguments: ChatViewArguments(chatJid: jid,topicId: topicId.value));
// DialogUtils.progressLoading();
/*getProfileDetails(jid).then((value) {
if (value.jid != null) {
DialogUtils.hideLoading();
// recentChats.firstWhere((element) => element.jid==jid).isConversationUnRead=false;
// debugPrint("Dashboard Profile===>$value");
var profile = value;//profiledata(value.toString());
NavUtils.toNamed(Routes.chat, arguments: profile);
}
});*/
// SessionManagement.setChatJid(jid);
// NavUtils.toNamed(Routes.chat);
}
}