func GetMondayfromDate(_ date: Date) -> Date {
var mdate: Date
let calendar = Calendar(identifier: .iso8601)
var components = calendar.dateComponents(in: TimeZone(identifier: "UTC")!, from: date)
components.weekday = 1 //today is Thursday, but weekday == 5 ??
mdate = calendar.date(from: components)!
return mdate
}
の日が月曜日の日付を取得するためにGETしようが、それは動作しません...スウィフト3 - 月曜日
http://stackoverflow.com/questions/33397101/how-to-get-mondays-date-of-the-current-week-in-swift –