Browse Source

上传导航卡片代码

newdev_shunjiawei
liwei1dao 2 years ago
parent
commit
ce1c89511d
  1. 2
      lib/modules/chat/views/chat_navigation_card.dart
  2. 4
      lib/modules/chat/views/chat_view.dart

2
lib/modules/chat/views/chat_navigation_card.dart

@ -41,7 +41,7 @@ class _ChatNavigationCardState extends State<ChatNavigationCard> {
}
void _getLocation() async {
List endPointList = widget.data?['navigationcard']['location'].split(',');
List endPointList = widget.data?['location'].split(',');
endPoint = LatLng(
double.parse(endPointList[0]),
double.parse(endPointList[1]),

4
lib/modules/chat/views/chat_view.dart

@ -362,8 +362,8 @@ class ChatView extends GetView<ChatController> {
if (message.data?['card_spotify'] != null) {
box = ChatMusicCard(message.data?['card_spotify'], isDarkMode);
}
if (message.data?['navigationcard'] != null) {
box = ChatNavigationCard(message.data, isDarkMode);
if (message.data?['card_navigation'] != null) {
box = ChatNavigationCard(message.data?['card_navigation'], isDarkMode);
}
}
return box;

Loading…
Cancel
Save