|
|
|
|
@ -1662,11 +1662,11 @@ defer { |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public func initSettings(templateTournament: Tournament?) { |
|
|
|
|
public func initSettings(templateTournament: Tournament?, overrideTeamCount: Bool = true) { |
|
|
|
|
setupDefaultPrivateSettings(templateTournament: templateTournament) |
|
|
|
|
setupUmpireSettings(defaultTournament: nil) //default is not template, default is for event sharing settings |
|
|
|
|
if let templateTournament { |
|
|
|
|
setupRegistrationSettings(templateTournament: templateTournament) |
|
|
|
|
setupRegistrationSettings(templateTournament: templateTournament, overrideTeamCount: overrideTeamCount) |
|
|
|
|
} |
|
|
|
|
setupFederalSettings() |
|
|
|
|
} |
|
|
|
|
@ -1739,7 +1739,7 @@ defer { |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public func setupRegistrationSettings(templateTournament: Tournament) { |
|
|
|
|
public func setupRegistrationSettings(templateTournament: Tournament, overrideTeamCount: Bool = true) { |
|
|
|
|
self.enableOnlineRegistration = templateTournament.enableOnlineRegistration |
|
|
|
|
self.unregisterDeltaInHours = templateTournament.unregisterDeltaInHours |
|
|
|
|
self.accountIsRequired = templateTournament.accountIsRequired |
|
|
|
|
@ -1748,7 +1748,9 @@ defer { |
|
|
|
|
self.maximumPlayerPerTeam = templateTournament.maximumPlayerPerTeam |
|
|
|
|
self.waitingListLimit = templateTournament.waitingListLimit |
|
|
|
|
self.teamCountLimit = templateTournament.teamCountLimit |
|
|
|
|
self.teamCount = templateTournament.teamCount |
|
|
|
|
if overrideTeamCount { |
|
|
|
|
self.teamCount = templateTournament.teamCount |
|
|
|
|
} |
|
|
|
|
self.enableOnlinePayment = templateTournament.enableOnlinePayment |
|
|
|
|
self.onlinePaymentIsMandatory = templateTournament.onlinePaymentIsMandatory |
|
|
|
|
self.enableOnlinePaymentRefund = templateTournament.enableOnlinePaymentRefund |
|
|
|
|
|