struct MeetingCheckInMemberModel:Equatable {
var id = 0
var meetingId = 0
var accountId = 0
var avatarVersion = 0
var name = ""
var nBought = 0
var timeAttend = ""
var bNeedCheckIn = 0
var isCheckIn:Bool{
return { if self.timeAttend == "" || self.timeAttend == "0"{
return false
}else{
return true
}
}()
}
}
func ==(m1: MeetingCheckInMemberModel, m2: MeetingCheckInMemberModel) -> Bool{
if m1.meetingId == m2.meetingId && m1.accountId == m2.accountId {
return true
}else{
return false
}
}
//判断2个对象或者结构体相等只需要实现Equatable协议就好,但是协议的实现在方法外面请注意
网友评论