Laurent 1 year ago
commit cf970f6033
  1. 4
      PadelClub.xcodeproj/project.pbxproj
  2. 7
      PadelClub/Views/Shared/SupportButtonView.swift
  3. 6
      PadelClub/Views/Tournament/Shared/TournamentBroadcastRowView.swift

@ -1901,7 +1901,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 58; CURRENT_PROJECT_VERSION = 59;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEFINES_MODULE = YES; DEFINES_MODULE = YES;
DEVELOPMENT_ASSET_PATHS = "\"PadelClub/Preview Content\""; DEVELOPMENT_ASSET_PATHS = "\"PadelClub/Preview Content\"";
@ -1941,7 +1941,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 58; CURRENT_PROJECT_VERSION = 59;
DEFINES_MODULE = YES; DEFINES_MODULE = YES;
DEVELOPMENT_ASSET_PATHS = "\"PadelClub/Preview Content\""; DEVELOPMENT_ASSET_PATHS = "\"PadelClub/Preview Content\"";
DEVELOPMENT_TEAM = BQ3Y44M3Q6; DEVELOPMENT_TEAM = BQ3Y44M3Q6;

@ -51,7 +51,7 @@ struct SupportButtonView: View {
Text(message) Text(message)
} }
.sheet(item: $zipFilePath) { zipFilePath in .sheet(item: $zipFilePath) { zipFilePath in
MailComposeView(recipients: ["support@padelclub.app"], bccRecipients: nil, body: nil, subject: _getSubject(), attachmentURL: zipFilePath) { result in MailComposeView(recipients: ["support@padelclub.app"], bccRecipients: nil, body: _getBody(), subject: _getSubject(), attachmentURL: zipFilePath) { result in
switch result { switch result {
case .cancelled, .saved: case .cancelled, .saved:
self.zipFilePath = nil self.zipFilePath = nil
@ -78,6 +78,11 @@ struct SupportButtonView: View {
} }
private func _getBody() -> String {
let separator = "---------------------------------------------"
return ["token", Store.main.token(), separator, "userId", Store.main.userId, separator, "dataStore userId", DataStore.shared.user.id].compacted().joined(separator: "\n\n")
}
private func _getDeviceIdentifier() -> String { private func _getDeviceIdentifier() -> String {
var systemInfo = utsname() var systemInfo = utsname()
uname(&systemInfo) uname(&systemInfo)

@ -15,8 +15,8 @@ struct TournamentBroadcastRowView: View {
NavigationLink(value: Screen.broadcast) { NavigationLink(value: Screen.broadcast) {
LabeledContent { LabeledContent {
if Store.main.userId == nil { if Store.main.userId == nil {
Image(systemName: "xmark.circle.fill") Image(systemName: "exclamationmark.circle.fill")
.foregroundStyle(.logoRed) .foregroundStyle(.master)
} else { } else {
if tournament.isPrivate { if tournament.isPrivate {
Text("tournoi privé").foregroundStyle(.logoRed) Text("tournoi privé").foregroundStyle(.logoRed)
@ -27,7 +27,7 @@ struct TournamentBroadcastRowView: View {
} label: { } label: {
Text("Publication") Text("Publication")
if Store.main.userId == nil { if Store.main.userId == nil {
Text("Un compte Padel Club est nécessaire") Text("Créez un compte pour publier !")
} }
} }
} }

Loading…
Cancel
Save