
class HeavyUserEntity {

  String projectId;
  String userId;
  String userRole;
  String mtCompanyId;
  String isMonitor;
  String userName;
  List<AttendanceRecord> attendanceRecord;

	HeavyUserEntity.fromJsonMap(Map<String, dynamic> map): 
		projectId = map["projectId"],
		userId = map["userId"],
		userRole = map["userRole"],
		mtCompanyId = map["mtCompanyId"],
		isMonitor = map["isMonitor"],
		userName = map["userName"],
		attendanceRecord = List<AttendanceRecord>.from((map["attendanceRecord"]??[]).map((it) => AttendanceRecord.fromJsonMap(it)));

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		data['projectId'] = projectId;
		data['userId'] = userId;
		data['userRole'] = userRole;
		data['mtCompanyId'] = mtCompanyId;
		data['isMonitor'] = isMonitor;
		data['userName'] = userName;
		data['attendanceRecord'] = attendanceRecord != null ? 
			this.attendanceRecord.map((v) => v.toJson()).toList()
			: null;
		return data;
	}
}

class AttendanceRecord {

	String createDate;
	String creatorId;
	String updateDate;
	String updateId;
	String id;
	String mtCompanyId;
	String projectId;
	String userId;
	String coordinate;
	String address;
	String signDate;
	String approachTime;
	String leavingTime;

	AttendanceRecord.fromJsonMap(Map<String, dynamic> map):
				createDate = map["createDate"],
				creatorId = map["creatorId"],
				updateDate = map["updateDate"],
				updateId = map["updateId"],
				id = map["id"],
				mtCompanyId = map["mtCompanyId"],
				projectId = map["projectId"],
				userId = map["userId"],
				coordinate = map["coordinate"],
				address = map["address"],
				signDate = map["signDate"],
				approachTime = map["approachTime"],
				leavingTime = map["leavingTime"];

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		data['createDate'] = createDate;
		data['creatorId'] = creatorId;
		data['updateDate'] = updateDate;
		data['updateId'] = updateId;
		data['id'] = id;
		data['mtCompanyId'] = mtCompanyId;
		data['projectId'] = projectId;
		data['userId'] = userId;
		data['coordinate'] = coordinate;
		data['address'] = address;
		data['signDate'] = signDate;
		data['approachTime'] = approachTime;
		data['leavingTime'] = leavingTime;
		return data;
	}
}
