feat: refactor code

This commit is contained in:
2026-06-17 12:57:28 +03:30
parent e9f294fa19
commit 519752b478
106 changed files with 3459 additions and 2309 deletions
@@ -0,0 +1,18 @@
import '../../domain/entities/user_entity.dart';
/// مدلِ داده‌ی کاربر؛ از JSON ساخته شده و به UserEntity نگاشت می‌شود.
class UserModel extends UserEntity {
const UserModel({
required super.id,
required super.mobile,
super.firstName,
super.avatar,
});
factory UserModel.fromJson(Map<String, dynamic> j) => UserModel(
id: (j['id'] ?? 0) as int,
mobile: (j['mobile'] ?? '') as String,
firstName: j['first_name'] as String?,
avatar: j['avatar'] as String?,
);
}