newHost
张萌 2 years ago
commit 57d1686f4c

@ -188,4 +188,4 @@ SPEC CHECKSUMS:
PODFILE CHECKSUM: fe0e1ee7f3d1f7d00b11b474b62dd62134535aea PODFILE CHECKSUM: fe0e1ee7f3d1f7d00b11b474b62dd62134535aea
COCOAPODS: 1.11.3 COCOAPODS: 1.11.2

@ -9,14 +9,16 @@ class BlacklistModel extends Equatable {
final int id; final int id;
final List<ImgModel> imgList; final List<ImgModel> imgList;
final String? name; final String? name;
final String nickName;
factory BlacklistModel.fromJson(Map<String, dynamic> json) => factory BlacklistModel.fromJson(Map<String, dynamic> json) =>
_$BlacklistModelFromJson(json); _$BlacklistModelFromJson(json);
BlacklistModel({ const BlacklistModel({
required this.id, required this.id,
required this.imgList, required this.imgList,
required this.name, this.name,
required this.nickName,
}); });
@override @override
@ -24,5 +26,6 @@ class BlacklistModel extends Equatable {
id, id,
imgList, imgList,
name, name,
nickName,
]; ];
} }

@ -13,4 +13,5 @@ BlacklistModel _$BlacklistModelFromJson(Map<String, dynamic> json) =>
.map((e) => ImgModel.fromJson(e as Map<String, dynamic>)) .map((e) => ImgModel.fromJson(e as Map<String, dynamic>))
.toList(), .toList(),
name: json['name'] as String?, name: json['name'] as String?,
nickName: json['nickName'] as String,
); );

@ -102,6 +102,7 @@ class _blackListPageState extends State<blackListPage> {
TextStyle(fontSize: 24.sp, color: Color(0xA6000000))), TextStyle(fontSize: 24.sp, color: Color(0xA6000000))),
])), ])),
), ),
20.hb,
Expanded( Expanded(
child: child:
// ListView.builder( // ListView.builder(
@ -192,7 +193,7 @@ class _blackListPageState extends State<blackListPage> {
// ) // )
, ,
title: Text( title: Text(
model.name == null ? '' : _getText(model.name!), model.nickName ?? '',
style: TextStyle(fontSize: 28.sp, color: ktextSubColor), style: TextStyle(fontSize: 28.sp, color: ktextSubColor),
), ),
trailing: GestureDetector( trailing: GestureDetector(
@ -240,13 +241,13 @@ class _blackListPageState extends State<blackListPage> {
); );
} }
_getText(String name) { // _getText(String name) {
String name2 = name.substring(0, 1); // String name2 = name.substring(0, 1);
for (var i = 0; i < name.length - 1; i++) { // for (var i = 0; i < name.length - 1; i++) {
name2 += '*'; // name2 += '*';
} // }
return name2; // return name2;
} // }
// _blackList(BlacklistModel model) { // _blackList(BlacklistModel model) {
// return ListTile( // return ListTile(
// leading: Container( // leading: Container(

@ -272,11 +272,10 @@ class _ChatCardState extends State<ChatCard> {
.make(), .make(),
onPressed: () //=> Get.back(result: true), onPressed: () //=> Get.back(result: true),
async { async {
var isShielding = //var isShielding =
await BlackListFunc.Block(widget.model.id); await BlackListFunc.Block(
if (isShielding) { widget.model.createId);
Get.back(); Get.back();
}
}, },
), ),
], ],

@ -2,7 +2,7 @@ name: aku_new_community
description: A new Flutter project. description: A new Flutter project.
publish_to: "none" publish_to: "none"
version: 1.8.17-dev+58 version: 1.8.18-dev+59
environment: environment:
sdk: ">=2.17.0 <3.0.0" sdk: ">=2.17.0 <3.0.0"

Loading…
Cancel
Save