Commit f89be70e authored by shigemi miura's avatar shigemi miura

Web表示関連更新

parent 179391e5
...@@ -86,6 +86,9 @@ ...@@ -86,6 +86,9 @@
D52D213A2AEBAC0500324D58 /* HttpRequestType.swift in Sources */ = {isa = PBXBuildFile; fileRef = D52D21392AEBAC0500324D58 /* HttpRequestType.swift */; }; D52D213A2AEBAC0500324D58 /* HttpRequestType.swift in Sources */ = {isa = PBXBuildFile; fileRef = D52D21392AEBAC0500324D58 /* HttpRequestType.swift */; };
D52D213F2AEBB7D700324D58 /* RegisteredEca.swift in Sources */ = {isa = PBXBuildFile; fileRef = D52D213E2AEBB7D700324D58 /* RegisteredEca.swift */; }; D52D213F2AEBB7D700324D58 /* RegisteredEca.swift in Sources */ = {isa = PBXBuildFile; fileRef = D52D213E2AEBB7D700324D58 /* RegisteredEca.swift */; };
D52D21412AEDE18F00324D58 /* EcaCoordinatesTable.swift in Sources */ = {isa = PBXBuildFile; fileRef = D52D21402AEDE18F00324D58 /* EcaCoordinatesTable.swift */; }; D52D21412AEDE18F00324D58 /* EcaCoordinatesTable.swift in Sources */ = {isa = PBXBuildFile; fileRef = D52D21402AEDE18F00324D58 /* EcaCoordinatesTable.swift */; };
D5384AFC2B306CEF006228C6 /* TermsView.html in Resources */ = {isa = PBXBuildFile; fileRef = D5384AFB2B306CEF006228C6 /* TermsView.html */; };
D5384AFE2B3121F2006228C6 /* PrivacyView.html in Resources */ = {isa = PBXBuildFile; fileRef = D5384AFD2B3121F2006228C6 /* PrivacyView.html */; };
D5384B012B312F2D006228C6 /* MenuLocalHtmlView.swift in Sources */ = {isa = PBXBuildFile; fileRef = D5384B002B312F2D006228C6 /* MenuLocalHtmlView.swift */; };
D545FC742B09C74300F206D0 /* AlertManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = D545FC732B09C74300F206D0 /* AlertManager.swift */; }; D545FC742B09C74300F206D0 /* AlertManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = D545FC732B09C74300F206D0 /* AlertManager.swift */; };
D545FC762B09C81300F206D0 /* PushNotificationTypes.swift in Sources */ = {isa = PBXBuildFile; fileRef = D545FC752B09C81300F206D0 /* PushNotificationTypes.swift */; }; D545FC762B09C81300F206D0 /* PushNotificationTypes.swift in Sources */ = {isa = PBXBuildFile; fileRef = D545FC752B09C81300F206D0 /* PushNotificationTypes.swift */; };
D55135202B15B030007B66B1 /* SetEcaArea.swift in Sources */ = {isa = PBXBuildFile; fileRef = D551351F2B15B030007B66B1 /* SetEcaArea.swift */; }; D55135202B15B030007B66B1 /* SetEcaArea.swift in Sources */ = {isa = PBXBuildFile; fileRef = D551351F2B15B030007B66B1 /* SetEcaArea.swift */; };
...@@ -236,6 +239,9 @@ ...@@ -236,6 +239,9 @@
D52D21392AEBAC0500324D58 /* HttpRequestType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = HttpRequestType.swift; path = Sailassist/Http/HttpRequestType.swift; sourceTree = SOURCE_ROOT; }; D52D21392AEBAC0500324D58 /* HttpRequestType.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = HttpRequestType.swift; path = Sailassist/Http/HttpRequestType.swift; sourceTree = SOURCE_ROOT; };
D52D213E2AEBB7D700324D58 /* RegisteredEca.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = RegisteredEca.swift; path = Sailassist/ECA/RegisteredEca.swift; sourceTree = SOURCE_ROOT; }; D52D213E2AEBB7D700324D58 /* RegisteredEca.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = RegisteredEca.swift; path = Sailassist/ECA/RegisteredEca.swift; sourceTree = SOURCE_ROOT; };
D52D21402AEDE18F00324D58 /* EcaCoordinatesTable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = EcaCoordinatesTable.swift; path = Sailassist/ECA/EcaCoordinatesTable.swift; sourceTree = SOURCE_ROOT; }; D52D21402AEDE18F00324D58 /* EcaCoordinatesTable.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = EcaCoordinatesTable.swift; path = Sailassist/ECA/EcaCoordinatesTable.swift; sourceTree = SOURCE_ROOT; };
D5384AFB2B306CEF006228C6 /* TermsView.html */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.html; name = TermsView.html; path = SailAssist/html/TermsView.html; sourceTree = SOURCE_ROOT; };
D5384AFD2B3121F2006228C6 /* PrivacyView.html */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.html; name = PrivacyView.html; path = SailAssist/html/PrivacyView.html; sourceTree = SOURCE_ROOT; };
D5384B002B312F2D006228C6 /* MenuLocalHtmlView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = MenuLocalHtmlView.swift; path = Sailassist/Menu/View/MenuLocalHtmlView.swift; sourceTree = SOURCE_ROOT; };
D53ACA752B0AECF8008DCB18 /* Sailassist.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = Sailassist.entitlements; path = Sailassist/Sailassist.entitlements; sourceTree = "<group>"; }; D53ACA752B0AECF8008DCB18 /* Sailassist.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = Sailassist.entitlements; path = Sailassist/Sailassist.entitlements; sourceTree = "<group>"; };
D545FC732B09C74300F206D0 /* AlertManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = AlertManager.swift; path = Sailassist/VoiceManager/AlertManager.swift; sourceTree = SOURCE_ROOT; }; D545FC732B09C74300F206D0 /* AlertManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = AlertManager.swift; path = Sailassist/VoiceManager/AlertManager.swift; sourceTree = SOURCE_ROOT; };
D545FC752B09C81300F206D0 /* PushNotificationTypes.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = PushNotificationTypes.swift; path = Sailassist/DataSource/PushNotificationTypes.swift; sourceTree = SOURCE_ROOT; }; D545FC752B09C81300F206D0 /* PushNotificationTypes.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = PushNotificationTypes.swift; path = Sailassist/DataSource/PushNotificationTypes.swift; sourceTree = SOURCE_ROOT; };
...@@ -324,6 +330,7 @@ ...@@ -324,6 +330,7 @@
020B98122AD8C3140029DE4C /* SailAssist */ = { 020B98122AD8C3140029DE4C /* SailAssist */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
D5384AFF2B3121FA006228C6 /* html */,
D545FC722B09C6DA00F206D0 /* VoiceManager */, D545FC722B09C6DA00F206D0 /* VoiceManager */,
D51AA4052B099F6D00EBBDD4 /* DataSource */, D51AA4052B099F6D00EBBDD4 /* DataSource */,
D51AA4022B099DA600EBBDD4 /* SignalR */, D51AA4022B099DA600EBBDD4 /* SignalR */,
...@@ -592,6 +599,7 @@ ...@@ -592,6 +599,7 @@
D5E008732B2ADD3F00C4070A /* MenuManualECDISView.swift */, D5E008732B2ADD3F00C4070A /* MenuManualECDISView.swift */,
D5E008752B2ADD5900C4070A /* MenuManualRADARView.swift */, D5E008752B2ADD5900C4070A /* MenuManualRADARView.swift */,
D5E008772B2B022200C4070A /* MenuAboutAppView.swift */, D5E008772B2B022200C4070A /* MenuAboutAppView.swift */,
D5384B002B312F2D006228C6 /* MenuLocalHtmlView.swift */,
); );
path = View; path = View;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -685,6 +693,15 @@ ...@@ -685,6 +693,15 @@
path = ECA; path = ECA;
sourceTree = "<group>"; sourceTree = "<group>";
}; };
D5384AFF2B3121FA006228C6 /* html */ = {
isa = PBXGroup;
children = (
D5384AFB2B306CEF006228C6 /* TermsView.html */,
D5384AFD2B3121F2006228C6 /* PrivacyView.html */,
);
path = html;
sourceTree = "<group>";
};
D545FC722B09C6DA00F206D0 /* VoiceManager */ = { D545FC722B09C6DA00F206D0 /* VoiceManager */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
...@@ -827,6 +844,8 @@ ...@@ -827,6 +844,8 @@
isa = PBXResourcesBuildPhase; isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
D5384AFE2B3121F2006228C6 /* PrivacyView.html in Resources */,
D5384AFC2B306CEF006228C6 /* TermsView.html in Resources */,
020B981B2AD8C3190029DE4C /* Preview Assets.xcassets in Resources */, 020B981B2AD8C3190029DE4C /* Preview Assets.xcassets in Resources */,
020B98182AD8C3190029DE4C /* Assets.xcassets in Resources */, 020B98182AD8C3190029DE4C /* Assets.xcassets in Resources */,
); );
...@@ -1001,6 +1020,7 @@ ...@@ -1001,6 +1020,7 @@
D5E008762B2ADD5900C4070A /* MenuManualRADARView.swift in Sources */, D5E008762B2ADD5900C4070A /* MenuManualRADARView.swift in Sources */,
D59908C62B19EA70000E13DD /* ResPushHistory.swift in Sources */, D59908C62B19EA70000E13DD /* ResPushHistory.swift in Sources */,
020B986C2ADD3E810029DE4C /* InTextLib.swift in Sources */, 020B986C2ADD3E810029DE4C /* InTextLib.swift in Sources */,
D5384B012B312F2D006228C6 /* MenuLocalHtmlView.swift in Sources */,
02C3E5D12AFCC16800AF7837 /* ChatTitleView.swift in Sources */, 02C3E5D12AFCC16800AF7837 /* ChatTitleView.swift in Sources */,
024EDE1D2B0C42F70013BAC8 /* MenuGpsSelectView.swift in Sources */, 024EDE1D2B0C42F70013BAC8 /* MenuGpsSelectView.swift in Sources */,
020B98472AD8FEE30029DE4C /* ColorSet.swift in Sources */, 020B98472AD8FEE30029DE4C /* ColorSet.swift in Sources */,
...@@ -1187,6 +1207,7 @@ ...@@ -1187,6 +1207,7 @@
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UIRequiresFullScreen = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait; INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
IPHONEOS_DEPLOYMENT_TARGET = 16.4; IPHONEOS_DEPLOYMENT_TARGET = 16.4;
LD_RUNPATH_SEARCH_PATHS = ( LD_RUNPATH_SEARCH_PATHS = (
...@@ -1229,6 +1250,7 @@ ...@@ -1229,6 +1250,7 @@
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UIRequiresFullScreen = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait; INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
IPHONEOS_DEPLOYMENT_TARGET = 16.4; IPHONEOS_DEPLOYMENT_TARGET = 16.4;
LD_RUNPATH_SEARCH_PATHS = ( LD_RUNPATH_SEARCH_PATHS = (
...@@ -1414,6 +1436,7 @@ ...@@ -1414,6 +1436,7 @@
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES; INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UIRequiresFullScreen = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait; INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
IPHONEOS_DEPLOYMENT_TARGET = 16.4; IPHONEOS_DEPLOYMENT_TARGET = 16.4;
LD_RUNPATH_SEARCH_PATHS = ( LD_RUNPATH_SEARCH_PATHS = (
......
...@@ -37,6 +37,7 @@ struct ContentView: View { ...@@ -37,6 +37,7 @@ struct ContentView: View {
selectedTabModel.activeTab = .task selectedTabModel.activeTab = .task
}, content: { }, content: {
LoginView(isLogin: $loginViewModel.isLogin) LoginView(isLogin: $loginViewModel.isLogin)
.environmentObject(selectedTabModel)
}) })
} }
} }
......
...@@ -10,11 +10,11 @@ import Foundation ...@@ -10,11 +10,11 @@ import Foundation
// TODO: サイトのアドレスを変更 // TODO: サイトのアドレスを変更
#if CANARY #if CANARY
enum HttpRequestType : String { enum HttpRequestType : String {
case Terms = "https://tacmistorage.blob.core.windows.net/$web/terms/terms.mobile.html?sv=2021-10-04&st=2023-11-22T06%3A26%3A32Z&se=2023-11-23T06%3A26%3A32Z&sr=b&sp=r&sig=wS6kbbT5SvNVTkRsnRk%2BiDceZAsQ3Y56vrqTUO1X50E%3D" // case Terms = "https://tacmistorage.blob.core.windows.net/$web/terms/terms.mobile.html?sv=2021-10-04&st=2023-11-22T06%3A26%3A32Z&se=2023-11-23T06%3A26%3A32Z&sr=b&sp=r&sig=wS6kbbT5SvNVTkRsnRk%2BiDceZAsQ3Y56vrqTUO1X50E%3D"
case RegisterLogin = "https://ssv-canary-web.azurewebsites.net/sailassistlogin" case RegisterLogin = "https://ssv-canary-web.azurewebsites.net/sailassistlogin"
case SitePolicy = "https://ssv-canary-web.azurewebsites.net/sitepolicy" case SitePolicy = "https://ssv-canary-web.azurewebsites.net/sitepolicy"
case CookiePolicy = "https://ssv-canary-web.azurewebsites.net/cookiepolicy" case CookiePolicy = "https://ssv-canary-web.azurewebsites.net/cookiepolicy"
case PrivacyPolicy = "https://ssv-canary-web.azurewebsites.net/inapp?" //+バージョン番号 // case PrivacyPolicy = "https://ssv-canary-web.azurewebsites.net/inapp?" //+バージョン番号
case TaskList = "https://ssv-canary-web.azurewebsites.net/api/sailassist/tasklist/XXXXX" case TaskList = "https://ssv-canary-web.azurewebsites.net/api/sailassist/tasklist/XXXXX"
case EcaArea = "https://ssv-canary-web.azurewebsites.net/api/sailassist/ecaarea/XXXXX" case EcaArea = "https://ssv-canary-web.azurewebsites.net/api/sailassist/ecaarea/XXXXX"
case ShipStatus = "https://ssv-canary-web.azurewebsites.net/api/sailassist/shipstatus/XXXXX" case ShipStatus = "https://ssv-canary-web.azurewebsites.net/api/sailassist/shipstatus/XXXXX"
...@@ -26,14 +26,16 @@ enum HttpRequestType : String { ...@@ -26,14 +26,16 @@ enum HttpRequestType : String {
case ConnectionString = "Endpoint=sb://ssv-canary-notification.servicebus.windows.net/;SharedAccessKeyName=DefaultListenSharedAccessSignature;SharedAccessKey=zHzVMA757FciMum5jVG4NMl82YpYVzclUgCiKOVRKf8=" case ConnectionString = "Endpoint=sb://ssv-canary-notification.servicebus.windows.net/;SharedAccessKeyName=DefaultListenSharedAccessSignature;SharedAccessKey=zHzVMA757FciMum5jVG4NMl82YpYVzclUgCiKOVRKf8="
case HubName = "ssv-canary-sailassist-notification" case HubName = "ssv-canary-sailassist-notification"
case storage = "https://ssvcanarystorage.z1.web.core.windows.net/" case storage = "https://ssvcanarystorage.z1.web.core.windows.net/"
case ContactPage = "https://www.jmarinecloud.com/eng/contact.php?type=ssv_mobile"
case ApachLicens = "https://raw.githubusercontent.com/Azure/azure-notificationhubs-ios/main/LICENSE"
} }
#elseif QC #elseif QC
enum HttpRequestType : String { enum HttpRequestType : String {
case Terms = "https://tacmistorage.blob.core.windows.net/$web/terms/terms.mobile.html?sv=2021-10-04&st=2023-11-22T06%3A26%3A32Z&se=2023-11-23T06%3A26%3A32Z&sr=b&sp=r&sig=wS6kbbT5SvNVTkRsnRk%2BiDceZAsQ3Y56vrqTUO1X50E%3D" // case Terms = "https://tacmistorage.blob.core.windows.net/$web/terms/terms.mobile.html?sv=2021-10-04&st=2023-11-22T06%3A26%3A32Z&se=2023-11-23T06%3A26%3A32Z&sr=b&sp=r&sig=wS6kbbT5SvNVTkRsnRk%2BiDceZAsQ3Y56vrqTUO1X50E%3D"
case RegisterLogin = "https://ssv-qc-web.azurewebsites.net/sailassistlogin" case RegisterLogin = "https://ssv-qc-web.azurewebsites.net/sailassistlogin"
case SitePolicy = "https://ssv-qc-web.azurewebsites.net/sitepolicy" case SitePolicy = "https://ssv-qc-web.azurewebsites.net/sitepolicy"
case CookiePolicy = "https://ssv-qc-web.azurewebsites.net/cookiepolicy" case CookiePolicy = "https://ssv-qc-web.azurewebsites.net/cookiepolicy"
case PrivacyPolicy = "https://ssv-qc-web.azurewebsites.net/inapp?" //+バージョン番号 // case PrivacyPolicy = "https://ssv-qc-web.azurewebsites.net/inapp?" //+バージョン番号
case TaskList = "https://ssv-qc-web.azurewebsites.net/api/sailassist/tasklist/XXXXX" case TaskList = "https://ssv-qc-web.azurewebsites.net/api/sailassist/tasklist/XXXXX"
case EcaArea = "https://ssv-qc-web.azurewebsites.net/api/sailassist/ecaarea" case EcaArea = "https://ssv-qc-web.azurewebsites.net/api/sailassist/ecaarea"
case ShipStatus = "https://ssv-qc-web.azurewebsites.net/api/sailassist/shipstatus/XXXXX" case ShipStatus = "https://ssv-qc-web.azurewebsites.net/api/sailassist/shipstatus/XXXXX"
...@@ -45,15 +47,17 @@ enum HttpRequestType : String { ...@@ -45,15 +47,17 @@ enum HttpRequestType : String {
case ConnectionString = "Endpoint=sb://ssv-qc-notification.servicebus.windows.net/;SharedAccessKeyName=DefaultListenSharedAccessSignature;SharedAccessKey=qjI5K38IyGfh2arFherVgp5tNUBE2U4eVClgTEQip54=" case ConnectionString = "Endpoint=sb://ssv-qc-notification.servicebus.windows.net/;SharedAccessKeyName=DefaultListenSharedAccessSignature;SharedAccessKey=qjI5K38IyGfh2arFherVgp5tNUBE2U4eVClgTEQip54="
case HubName = "ssv-qc-sailassist-notification" case HubName = "ssv-qc-sailassist-notification"
case storage = "https://tacmiquaritycheckstorage.z31.web.core.windows.net/" case storage = "https://tacmiquaritycheckstorage.z31.web.core.windows.net/"
case ContactPage = "https://www.jmarinecloud.com/eng/contact.php?type=ssv_mobile"
case ApachLicens = "https://raw.githubusercontent.com/Azure/azure-notificationhubs-ios/main/LICENSE"
} }
#else #else
//MARK: 運用サーバー用 //MARK: 運用サーバー用
enum HttpRequestType : String { enum HttpRequestType : String {
case Terms = "https://tacmistorage.blob.core.windows.net/$web/terms/terms.mobile.html?sv=2021-10-04&st=2023-11-22T06%3A26%3A32Z&se=2023-11-23T06%3A26%3A32Z&sr=b&sp=r&sig=wS6kbbT5SvNVTkRsnRk%2BiDceZAsQ3Y56vrqTUO1X50E%3D" // case Terms = "https://tacmistorage.blob.core.windows.net/$web/terms/terms.mobile.html?sv=2021-10-04&st=2023-11-22T06%3A26%3A32Z&se=2023-11-23T06%3A26%3A32Z&sr=b&sp=r&sig=wS6kbbT5SvNVTkRsnRk%2BiDceZAsQ3Y56vrqTUO1X50E%3D"
case RegisterLogin = "https://ssv.jmarinecloud.com/sailassistlogin" case RegisterLogin = "https://ssv.jmarinecloud.com/sailassistlogin"
case SitePolicy = "https://ssv.jmarinecloud.com/sitepolicy" case SitePolicy = "https://ssv.jmarinecloud.com/sitepolicy"
case CookiePolicy = "https://ssv.jmarinecloud.com/cookiepolicy" case CookiePolicy = "https://ssv.jmarinecloud.com/cookiepolicy"
case PrivacyPolicy = "https://ssv.jmarinecloud.com/inapp?" //+バージョン番号 // case PrivacyPolicy = "https://ssv.jmarinecloud.com/inapp?" //+バージョン番号
case TaskList = "https://ssv.jmarinecloud.com/api/sailassist/tasklist/XXXXX" case TaskList = "https://ssv.jmarinecloud.com/api/sailassist/tasklist/XXXXX"
case EcaArea = "https://ssv.jmarinecloud.com/api/sailassist/ecaarea" case EcaArea = "https://ssv.jmarinecloud.com/api/sailassist/ecaarea"
case ShipStatus = "https://ssv.jmarinecloud.com/api/sailassist/shipstatus/XXXXX" case ShipStatus = "https://ssv.jmarinecloud.com/api/sailassist/shipstatus/XXXXX"
...@@ -65,5 +69,7 @@ enum HttpRequestType : String { ...@@ -65,5 +69,7 @@ enum HttpRequestType : String {
case ConnectionString = "Endpoint=sb://ssv-notification.servicebus.windows.net/;SharedAccessKeyName=DefaultListenSharedAccessSignature;SharedAccessKey=IzbO7Lo+PenhlIaHBw1MA7+NE9XaLikwieOFwCzZC50=" case ConnectionString = "Endpoint=sb://ssv-notification.servicebus.windows.net/;SharedAccessKeyName=DefaultListenSharedAccessSignature;SharedAccessKey=IzbO7Lo+PenhlIaHBw1MA7+NE9XaLikwieOFwCzZC50="
case HubName = "ssv-sailassist-notification" case HubName = "ssv-sailassist-notification"
case storage = "https://tacmistorage.z31.web.core.windows.net/" case storage = "https://tacmistorage.z31.web.core.windows.net/"
case ContactPage = "https://www.jmarinecloud.com/eng/contact.php?type=ssv_mobile"
case ApachLicens = "https://raw.githubusercontent.com/Azure/azure-notificationhubs-ios/main/LICENSE"
} }
#endif #endif
...@@ -22,9 +22,8 @@ class LocationViewModel: NSObject, ObservableObject, CLLocationManagerDelegate { ...@@ -22,9 +22,8 @@ class LocationViewModel: NSObject, ObservableObject, CLLocationManagerDelegate {
super.init() super.init()
} }
func requestPermission() -> (alert: Bool, type: AlertType) { func requestPermission() -> Bool {
var alert = false var alert = true
let type: AlertType = .gpsPermission
locationManager.requestWhenInUseAuthorization() locationManager.requestWhenInUseAuthorization()
locationManager.requestAlwaysAuthorization() // バックグラウンド実行中も座標取得する場合はこちら locationManager.requestAlwaysAuthorization() // バックグラウンド実行中も座標取得する場合はこちら
...@@ -32,18 +31,15 @@ class LocationViewModel: NSObject, ObservableObject, CLLocationManagerDelegate { ...@@ -32,18 +31,15 @@ class LocationViewModel: NSObject, ObservableObject, CLLocationManagerDelegate {
let status = CLLocationManager().authorizationStatus let status = CLLocationManager().authorizationStatus
switch status { switch status {
case .authorizedAlways : case .authorizedAlways :
alert = false
print(debug: "authorizationStatus : .authorizedAlways") //常に利用許可 print(debug: "authorizationStatus : .authorizedAlways") //常に利用許可
case .notDetermined: case .notDetermined:
alert = true
print(debug: "authorizationStatus : .notDetermined") //一度だけ許可 print(debug: "authorizationStatus : .notDetermined") //一度だけ許可
case .restricted: case .restricted:
alert = true
print(debug: "authorizationStatus : .restricted") //ペアレンタルコントロールなどの影響で制限中 print(debug: "authorizationStatus : .restricted") //ペアレンタルコントロールなどの影響で制限中
case .denied: case .denied:
alert = true
print(debug: "authorizationStatus : .denied") //利用拒否 print(debug: "authorizationStatus : .denied") //利用拒否
case .authorizedWhenInUse: case .authorizedWhenInUse:
alert = true
print(debug: "authorizationStatus : .authorizedWhenInUse") //使用中のみ利用許可 print(debug: "authorizationStatus : .authorizedWhenInUse") //使用中のみ利用許可
@unknown default: @unknown default:
print(debug: "authorizationStatus : Unknown") print(debug: "authorizationStatus : Unknown")
...@@ -63,7 +59,7 @@ class LocationViewModel: NSObject, ObservableObject, CLLocationManagerDelegate { ...@@ -63,7 +59,7 @@ class LocationViewModel: NSObject, ObservableObject, CLLocationManagerDelegate {
locationManager.startUpdatingLocation() locationManager.startUpdatingLocation()
} }
return(alert, type) return alert
} }
func locationManagerDidChangeAuthorization(_ manager: CLLocationManager) { func locationManagerDidChangeAuthorization(_ manager: CLLocationManager) {
......
...@@ -21,7 +21,6 @@ enum AlertType: String { ...@@ -21,7 +21,6 @@ enum AlertType: String {
case QrFailure case QrFailure
case ClientError case ClientError
case Expired case Expired
case gpsPermission
} }
class LoginViewParam: ObservableObject{ class LoginViewParam: ObservableObject{
...@@ -35,6 +34,7 @@ let TimerInterval = 60.0 * 10.0 ...@@ -35,6 +34,7 @@ let TimerInterval = 60.0 * 10.0
struct LoginView: View { struct LoginView: View {
@ObservedObject var scannerViewModel = ScannerViewModel() @ObservedObject var scannerViewModel = ScannerViewModel()
@EnvironmentObject var locationViewModel: LocationViewModel @EnvironmentObject var locationViewModel: LocationViewModel
@EnvironmentObject var selectedTabModel: SelectedTabModel
@Binding var isLogin: Bool @Binding var isLogin: Bool
@State var isQrRead: Bool = false @State var isQrRead: Bool = false
@State var viewMode: LoginViewMode = .SelectType @State var viewMode: LoginViewMode = .SelectType
...@@ -87,7 +87,10 @@ struct LoginView: View { ...@@ -87,7 +87,10 @@ struct LoginView: View {
if !isProgressView { if !isProgressView {
Link("Site policy", destination: URL(string: HttpRequestType.SitePolicy.rawValue)!) Link("Site policy", destination: URL(string: HttpRequestType.SitePolicy.rawValue)!)
Link("Cookie policy", destination: URL(string: HttpRequestType.CookiePolicy.rawValue)!) Link("Cookie policy", destination: URL(string: HttpRequestType.CookiePolicy.rawValue)!)
Link("Privacy policy", destination: URL(string: HttpRequestType.PrivacyPolicy.rawValue)!) if let htmlPath = Bundle.main.path(forResource: "PrivacyView", ofType: "html") {
Link("Privacy policy", destination: URL(fileURLWithPath: htmlPath))
}
// Link("Privacy policy", destination: URL(string: HttpRequestType.CookiePolicy.rawValue)!)
} else { } else {
EmptyView() EmptyView()
} }
...@@ -122,11 +125,6 @@ struct LoginView: View { ...@@ -122,11 +125,6 @@ struct LoginView: View {
message: Text("Expired."), message: Text("Expired."),
dismissButton: .default(Text("OK"), action: {viewMode = .SelectType}) dismissButton: .default(Text("OK"), action: {viewMode = .SelectType})
) )
case .gpsPermission:
return Alert(title: Text("Location"),
message: Text("To use ECA,set the permission to use location information to Always."),
dismissButton: .default(Text("Next"), action: {locationViewModel.requestPermission()})
)
} }
} }
} }
...@@ -137,9 +135,7 @@ struct LoginView: View { ...@@ -137,9 +135,7 @@ struct LoginView: View {
}) })
.onAppear() { .onAppear() {
LoginCheck() LoginCheck()
let result = locationViewModel.requestPermission() selectedTabModel.isLocationAlert = locationViewModel.requestPermission()
isAlert = result.alert
alertType = result.type
} }
.preferredColorScheme(.dark) .preferredColorScheme(.dark)
} }
...@@ -302,4 +298,5 @@ fileprivate struct Triangle: Shape{ ...@@ -302,4 +298,5 @@ fileprivate struct Triangle: Shape{
#Preview { #Preview {
LoginView(isLogin: .constant(false)) LoginView(isLogin: .constant(false))
.environmentObject(SelectedTabModel())
} }
...@@ -86,7 +86,7 @@ struct MenuView: View { ...@@ -86,7 +86,7 @@ struct MenuView: View {
NavigationStack(path: $path){ NavigationStack(path: $path){
VStack(spacing: 0) { VStack(spacing: 0) {
MenuTitleView(path: $path) MenuTitleView(path: $path)
HStack { HStack {
VStack(alignment: .leading, spacing: 10){ VStack(alignment: .leading, spacing: 10){
Text(SharingData.my.shipName) Text(SharingData.my.shipName)
...@@ -100,7 +100,7 @@ struct MenuView: View { ...@@ -100,7 +100,7 @@ struct MenuView: View {
.padding(.vertical, 17) .padding(.vertical, 17)
Spacer() Spacer()
} }
Divider() Divider()
.background(ColorSet.LineColor04.color) .background(ColorSet.LineColor04.color)
Button{ Button{
...@@ -108,25 +108,25 @@ struct MenuView: View { ...@@ -108,25 +108,25 @@ struct MenuView: View {
}label: { }label: {
MenuContentView(content: .Manual) MenuContentView(content: .Manual)
} }
Button{ Button{
path.append(.Information) path.append(.Information)
}label: { }label: {
MenuContentView(content: .Information) MenuContentView(content: .Information)
} }
Button{ Button{
path.append(.Setting) path.append(.Setting)
}label: { }label: {
MenuContentView(content: .Setting) MenuContentView(content: .Setting)
} }
Button{ Button{
isSignout = true isSignout = true
}label: { }label: {
MenuContentView(content: .SignOut) MenuContentView(content: .SignOut)
} }
Spacer() Spacer()
} }
.background(ColorSet.BackgroundPrimary.color) .background(ColorSet.BackgroundPrimary.color)
...@@ -151,10 +151,18 @@ struct MenuView: View { ...@@ -151,10 +151,18 @@ struct MenuView: View {
}else if goto == .AboutApp{ }else if goto == .AboutApp{
MenuAboutAppView(path: $path) MenuAboutAppView(path: $path)
.navigationBarHidden(true) .navigationBarHidden(true)
}else if goto == .TermsOfUse{
MenuLocalHtmlView(path: $path)
.navigationBarHidden(true)
}else if goto == .PrivacyStatement{
MenuLocalHtmlView(path: $path)
.navigationBarHidden(true)
}else if goto == .ContactUs{
WebView(isLoading: .constant(false), url: HttpRequestType.ContactPage.rawValue)
}else{ }else{
VStack(spacing: 0) { VStack(spacing: 0) {
MenuTitleView(path: $path, title: goto.title) MenuTitleView(path: $path, title: goto.title)
if let url = Preferences.ECDISBasicUrl{ if let url = Preferences.ECDISBasicUrl{
PDFViewer(url: url) PDFViewer(url: url)
}else{ }else{
...@@ -165,11 +173,11 @@ struct MenuView: View { ...@@ -165,11 +173,11 @@ struct MenuView: View {
.background(ColorSet.BackgroundPrimary.color) .background(ColorSet.BackgroundPrimary.color)
} }
} }
.alert("Sign Out", isPresented: $isSignout) { .alert("Sign Out", isPresented: $isSignout) {
Button("Yes") { Button("Yes") {
Preferences.Id = "" Preferences.Id = ""
Preferences.Password = "" Preferences.Password = ""
Preferences.UserName = ""
loginViewModel.isLogin = false loginViewModel.isLogin = false
sceneDelegate.tabWindow?.isHidden = true sceneDelegate.tabWindow?.isHidden = true
} }
......
...@@ -18,11 +18,11 @@ struct MenuAboutAppView: View { ...@@ -18,11 +18,11 @@ struct MenuAboutAppView: View {
HStack { HStack {
VStack(alignment: .leading, spacing: 10){ VStack(alignment: .leading, spacing: 10){
Text("Version") Text("Version")
.font(FontStyle.EmphasisText.font) .font(FontStyle.SupplementText.font)
.foregroundColor(ColorSet.BodyDescriptiion.color) .foregroundColor(ColorSet.BodyDescriptiion.color)
#if CANARY #if CANARY
Text("\(version)" + " Canary") Text("\(version)" + " Canary")
.font(FontStyle.EmphasisText.font) .font(FontStyle.SupplementText.font)
.foregroundColor(ColorSet.Body.color) .foregroundColor(ColorSet.Body.color)
#elseif QC #elseif QC
Text("\(version)" + " QC") Text("\(version)" + " QC")
...@@ -44,7 +44,7 @@ struct MenuAboutAppView: View { ...@@ -44,7 +44,7 @@ struct MenuAboutAppView: View {
Spacer().frame(height: 50) Spacer().frame(height: 50)
Text("Policy") Text("Policy")
.font(FontStyle.EmphasisText.font) .font(FontStyle.SupplementText.font)
.foregroundColor(ColorSet.BodyDescriptiion.color) .foregroundColor(ColorSet.BodyDescriptiion.color)
.frame(maxWidth: .infinity, alignment: .leading) .frame(maxWidth: .infinity, alignment: .leading)
.padding(.leading, 30) .padding(.leading, 30)
...@@ -64,7 +64,7 @@ struct MenuAboutAppView: View { ...@@ -64,7 +64,7 @@ struct MenuAboutAppView: View {
Spacer().frame(height: 50) Spacer().frame(height: 50)
Text("Open Source Licenses") Text("Open Source Licenses")
.font(FontStyle.EmphasisText.font) .font(FontStyle.SupplementText.font)
.foregroundColor(ColorSet.BodyDescriptiion.color) .foregroundColor(ColorSet.BodyDescriptiion.color)
.frame(maxWidth: .infinity, alignment: .leading) .frame(maxWidth: .infinity, alignment: .leading)
.padding(.leading, 30) .padding(.leading, 30)
...@@ -77,6 +77,11 @@ struct MenuAboutAppView: View { ...@@ -77,6 +77,11 @@ struct MenuAboutAppView: View {
.foregroundColor(ColorSet.Body.color) .foregroundColor(ColorSet.Body.color)
.frame(maxWidth: .infinity, alignment: .leading) .frame(maxWidth: .infinity, alignment: .leading)
.padding(.leading, 30) .padding(.leading, 30)
VStack(spacing: 30) {
Link("https://github.com/Azure/azure-notificationhubs-ios/blob/main/LICENSE", destination: URL(string: HttpRequestType.ApachLicens.rawValue)!)
}
.font(FontStyle.RadioButtonText.font)
.foregroundColor(ColorSet.Body.color)
Spacer() Spacer()
} }
.background(ColorSet.BackgroundPrimary.color) .background(ColorSet.BackgroundPrimary.color)
......
//
// MenuLocalHtmlView.swift
// Sailassist
//
// Created by 三浦薫巳 on 2023/12/19.
//
import Foundation
import SwiftUI
struct MenuLocalHtmlView: View {
@State var isAlert: Bool = false
@Binding var path : [MenuPath]
var body: some View {
VStack{
let aaa = path
MenuTitleView(path: $path, title: MenuPath.ManualRADAR.title)
// if content.rawValue != "TermsOfUse" {
// if let htmlPath = Bundle.main.path(forResource: "TermsView", ofType: "html") {
// WebView(isLoading: .constant(false), url: htmlPath)
// }
// } else if content.rawValue != "PrivacyStatement" {
// if let htmlPath = Bundle.main.path(forResource: "PrivacyView", ofType: "html") {
// WebView(isLoading: .constant(false), url: htmlPath)
// }
// }
Spacer()
}
.background(ColorSet.BackgroundPrimary.color)
.alert("delete", isPresented: $isAlert) {
Button(role: .destructive) {
} label: {
Text("delete")
}
} message: {
Text("eca delete")
}
}
}
#Preview {
MenuLocalHtmlView(path: .constant([.ManualRADAR]))
}
...@@ -16,14 +16,16 @@ struct SailassistApp: App { ...@@ -16,14 +16,16 @@ struct SailassistApp: App {
@State private var isPrivAgree = Preferences.privacyPolicyAgreeDate != nil @State private var isPrivAgree = Preferences.privacyPolicyAgreeDate != nil
let locationViewModel = LocationViewModel() let locationViewModel = LocationViewModel()
// let signalRService = SignalRService() let signalRService = SignalRService()
var body: some Scene { var body: some Scene {
WindowGroup { WindowGroup {
if !isTermsAgree{ if !isTermsAgree{
VStack(spacing: 0){ VStack(spacing: 0){
WebView(isLoading: .constant(false), url: HttpRequestType.Terms.rawValue) if let htmlPath = Bundle.main.path(forResource: "TermsView", ofType: "html") {
WebView(isLoading: .constant(false), url: htmlPath)
}
YesNoButtons(yesTitle: "Accept", noTitle: "Cancel") { YesNoButtons(yesTitle: "Accept", noTitle: "Cancel") {
Preferences.termsAgreeDate_Int64 = DateTextLib.Date2UnixTime(date: Date()) Preferences.termsAgreeDate_Int64 = DateTextLib.Date2UnixTime(date: Date())
isTermsAgree = true isTermsAgree = true
...@@ -35,7 +37,9 @@ struct SailassistApp: App { ...@@ -35,7 +37,9 @@ struct SailassistApp: App {
}else if !isPrivAgree{ }else if !isPrivAgree{
VStack(spacing: 0){ VStack(spacing: 0){
WebView(isLoading: .constant(false), url: HttpRequestType.Terms.rawValue) if let htmlPath = Bundle.main.path(forResource: "PrivacyView", ofType: "html") {
WebView(isLoading: .constant(false), url: htmlPath)
}
YesNoButtons(yesTitle: "Accept", noTitle: "Cancel") { YesNoButtons(yesTitle: "Accept", noTitle: "Cancel") {
Preferences.privacyPolicyAgreeDate_Int64 = DateTextLib.Date2UnixTime(date: Date()) Preferences.privacyPolicyAgreeDate_Int64 = DateTextLib.Date2UnixTime(date: Date())
......
...@@ -110,12 +110,11 @@ struct CustomTabBar: View { ...@@ -110,12 +110,11 @@ struct CustomTabBar: View {
} message: { } message: {
Text("Do you change an emargency mode?") Text("Do you change an emargency mode?")
} }
.alert("location", isPresented: $isLocationAlert) { .alert("location", isPresented: $selectedTabModel.isLocationAlert) {
Button("Next") { Button("OK") {
print("")
} }
} message: { } message: {
Text("To use ECA,set the permission to use location information to Always.") Text("To use ECA,set the permission to use location information to ALWAYS.")
} }
} }
} }
......
...@@ -11,4 +11,5 @@ import SwiftUI ...@@ -11,4 +11,5 @@ import SwiftUI
class SelectedTabModel: ObservableObject { class SelectedTabModel: ObservableObject {
@Published var activeTab: Tab = .task @Published var activeTab: Tab = .task
@Published var isShowChangeEmrMode: Bool = false @Published var isShowChangeEmrMode: Bool = false
@Published var isLocationAlert: Bool = false
} }
...@@ -13,7 +13,13 @@ struct WebView: UIViewRepresentable { ...@@ -13,7 +13,13 @@ struct WebView: UIViewRepresentable {
var url : String var url : String
func makeUIView(context: Context) -> WKWebView { func makeUIView(context: Context) -> WKWebView {
let request = URLRequest(url: URL(string: url)!) var address: URL
if url.contains("https://") {
address = URL(string: url)!
} else {
address = URL(fileURLWithPath: url)
}
let request = URLRequest(url: address)
let webView = WKWebView() let webView = WKWebView()
webView.navigationDelegate = context.coordinator webView.navigationDelegate = context.coordinator
webView.load(request) webView.load(request)
......
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Privacy Statement</title>
</head>
<body>
<h1>Privacy Statement</h1>
</body>
</html>
\ No newline at end of file
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment