Added login and setup screens

This commit is contained in:
Deniz Duezgoeren
2019-09-21 14:04:49 +02:00
parent 7acddfbfd9
commit c064164858
16 changed files with 442 additions and 23 deletions
+12
View File
@@ -9,6 +9,9 @@
/* Begin PBXBuildFile section */ /* Begin PBXBuildFile section */
1BF3A6CA97BA41C38482C1A6 /* Pods_AvH_PlanTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D9D6269E96544A9242A29611 /* Pods_AvH_PlanTests.framework */; }; 1BF3A6CA97BA41C38482C1A6 /* Pods_AvH_PlanTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D9D6269E96544A9242A29611 /* Pods_AvH_PlanTests.framework */; };
2E65263AFD35D6B542E89AE4 /* Pods_AvH_Plan.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7605BB0678C9E27A1D3E9DAA /* Pods_AvH_Plan.framework */; }; 2E65263AFD35D6B542E89AE4 /* Pods_AvH_Plan.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7605BB0678C9E27A1D3E9DAA /* Pods_AvH_Plan.framework */; };
A9378D352336015000C07D07 /* LoginViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A9378D342336015000C07D07 /* LoginViewController.swift */; };
A9378D37233619F300C07D07 /* WebKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A9378D36233619F300C07D07 /* WebKit.framework */; };
A9378D392336300700C07D07 /* FirstTimeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A9378D382336300700C07D07 /* FirstTimeViewController.swift */; };
A957A75122DDC15500E0A2ED /* MenuViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A957A74F22DDC15500E0A2ED /* MenuViewCell.swift */; }; A957A75122DDC15500E0A2ED /* MenuViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = A957A74F22DDC15500E0A2ED /* MenuViewCell.swift */; };
A957A75222DDC15500E0A2ED /* MenuViewCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = A957A75022DDC15500E0A2ED /* MenuViewCell.xib */; }; A957A75222DDC15500E0A2ED /* MenuViewCell.xib in Resources */ = {isa = PBXBuildFile; fileRef = A957A75022DDC15500E0A2ED /* MenuViewCell.xib */; };
A958A92222DF5388007052B0 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = A958A92422DF5388007052B0 /* Localizable.strings */; }; A958A92222DF5388007052B0 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = A958A92422DF5388007052B0 /* Localizable.strings */; };
@@ -70,6 +73,9 @@
589FBD2CE6A9C73CD9B81441 /* Pods-AvH PlanUITests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AvH PlanUITests.release.xcconfig"; path = "Target Support Files/Pods-AvH PlanUITests/Pods-AvH PlanUITests.release.xcconfig"; sourceTree = "<group>"; }; 589FBD2CE6A9C73CD9B81441 /* Pods-AvH PlanUITests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AvH PlanUITests.release.xcconfig"; path = "Target Support Files/Pods-AvH PlanUITests/Pods-AvH PlanUITests.release.xcconfig"; sourceTree = "<group>"; };
74EDE3D8134812AB76BEB988 /* Pods_AvH_PlanUITests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AvH_PlanUITests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 74EDE3D8134812AB76BEB988 /* Pods_AvH_PlanUITests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AvH_PlanUITests.framework; sourceTree = BUILT_PRODUCTS_DIR; };
7605BB0678C9E27A1D3E9DAA /* Pods_AvH_Plan.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AvH_Plan.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 7605BB0678C9E27A1D3E9DAA /* Pods_AvH_Plan.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_AvH_Plan.framework; sourceTree = BUILT_PRODUCTS_DIR; };
A9378D342336015000C07D07 /* LoginViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = LoginViewController.swift; sourceTree = "<group>"; };
A9378D36233619F300C07D07 /* WebKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = WebKit.framework; path = System/Library/Frameworks/WebKit.framework; sourceTree = SDKROOT; };
A9378D382336300700C07D07 /* FirstTimeViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FirstTimeViewController.swift; sourceTree = "<group>"; };
A957A74F22DDC15500E0A2ED /* MenuViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MenuViewCell.swift; sourceTree = "<group>"; }; A957A74F22DDC15500E0A2ED /* MenuViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MenuViewCell.swift; sourceTree = "<group>"; };
A957A75022DDC15500E0A2ED /* MenuViewCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MenuViewCell.xib; sourceTree = "<group>"; }; A957A75022DDC15500E0A2ED /* MenuViewCell.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MenuViewCell.xib; sourceTree = "<group>"; };
A958A92322DF5388007052B0 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/Localizable.strings; sourceTree = "<group>"; }; A958A92322DF5388007052B0 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/Localizable.strings; sourceTree = "<group>"; };
@@ -117,6 +123,7 @@
isa = PBXFrameworksBuildPhase; isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647; buildActionMask = 2147483647;
files = ( files = (
A9378D37233619F300C07D07 /* WebKit.framework in Frameworks */,
2E65263AFD35D6B542E89AE4 /* Pods_AvH_Plan.framework in Frameworks */, 2E65263AFD35D6B542E89AE4 /* Pods_AvH_Plan.framework in Frameworks */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
@@ -156,6 +163,7 @@
A7F8C8C9CE4E171D98EE659D /* Frameworks */ = { A7F8C8C9CE4E171D98EE659D /* Frameworks */ = {
isa = PBXGroup; isa = PBXGroup;
children = ( children = (
A9378D36233619F300C07D07 /* WebKit.framework */,
7605BB0678C9E27A1D3E9DAA /* Pods_AvH_Plan.framework */, 7605BB0678C9E27A1D3E9DAA /* Pods_AvH_Plan.framework */,
D9D6269E96544A9242A29611 /* Pods_AvH_PlanTests.framework */, D9D6269E96544A9242A29611 /* Pods_AvH_PlanTests.framework */,
74EDE3D8134812AB76BEB988 /* Pods_AvH_PlanUITests.framework */, 74EDE3D8134812AB76BEB988 /* Pods_AvH_PlanUITests.framework */,
@@ -212,6 +220,8 @@
A9B0465322E448EC005FB0DB /* GenericViewCell.swift */, A9B0465322E448EC005FB0DB /* GenericViewCell.swift */,
A9B033D622E4D0AB009ACF8A /* ColourViewCell.swift */, A9B033D622E4D0AB009ACF8A /* ColourViewCell.swift */,
A9B033D722E4D0AB009ACF8A /* ColourViewCell.xib */, A9B033D722E4D0AB009ACF8A /* ColourViewCell.xib */,
A9378D342336015000C07D07 /* LoginViewController.swift */,
A9378D382336300700C07D07 /* FirstTimeViewController.swift */,
); );
path = "AvH Plan"; path = "AvH Plan";
sourceTree = "<group>"; sourceTree = "<group>";
@@ -483,6 +493,7 @@
A9B0465422E448EC005FB0DB /* GenericViewCell.swift in Sources */, A9B0465422E448EC005FB0DB /* GenericViewCell.swift in Sources */,
A9B0464E22E1F75A005FB0DB /* CustomizationViewController.swift in Sources */, A9B0464E22E1F75A005FB0DB /* CustomizationViewController.swift in Sources */,
A96133802299867400B541D4 /* AppDelegate.swift in Sources */, A96133802299867400B541D4 /* AppDelegate.swift in Sources */,
A9378D352336015000C07D07 /* LoginViewController.swift in Sources */,
A9A3496C22D4859200F35AE0 /* SubstModel.swift in Sources */, A9A3496C22D4859200F35AE0 /* SubstModel.swift in Sources */,
A9C1D30022D656DD00139043 /* MenuViewController.swift in Sources */, A9C1D30022D656DD00139043 /* MenuViewController.swift in Sources */,
A957A75122DDC15500E0A2ED /* MenuViewCell.swift in Sources */, A957A75122DDC15500E0A2ED /* MenuViewCell.swift in Sources */,
@@ -493,6 +504,7 @@
A9C1D30222D7237200139043 /* DataFetcher.swift in Sources */, A9C1D30222D7237200139043 /* DataFetcher.swift in Sources */,
A96D4CCA22DDE184006BAB34 /* PersonalPlanViewController.swift in Sources */, A96D4CCA22DDE184006BAB34 /* PersonalPlanViewController.swift in Sources */,
A9B033D822E4D0AB009ACF8A /* ColourViewCell.swift in Sources */, A9B033D822E4D0AB009ACF8A /* ColourViewCell.swift in Sources */,
A9378D392336300700C07D07 /* FirstTimeViewController.swift in Sources */,
A9B0465022E21207005FB0DB /* ColourPickerView.swift in Sources */, A9B0465022E21207005FB0DB /* ColourPickerView.swift in Sources */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
@@ -0,0 +1,23 @@
{
"images" : [
{
"idiom" : "universal",
"filename" : "idea1x.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "idea2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "idea3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.8 KiB

@@ -0,0 +1,23 @@
{
"images" : [
{
"idiom" : "universal",
"filename" : "whiteidea1x.png",
"scale" : "1x"
},
{
"idiom" : "universal",
"filename" : "whiteidea2x.png",
"scale" : "2x"
},
{
"idiom" : "universal",
"filename" : "whiteidea3x.png",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

+261 -3
View File
@@ -84,14 +84,14 @@
<fontDescription key="fontDescription" type="system" pointSize="14"/> <fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/> <textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/>
</textField> </textField>
<textField opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your classes" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="bCV-w1-hVY"> <textField opaque="NO" contentMode="scaleToFill" horizontalCompressionResistancePriority="749" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your classes" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="bCV-w1-hVY">
<rect key="frame" x="24" y="62" width="328" height="30"/> <rect key="frame" x="24" y="62" width="328" height="30"/>
<accessibility key="accessibilityConfiguration" hint="Classes"/> <accessibility key="accessibilityConfiguration" hint="Classes"/>
<nil key="textColor"/> <nil key="textColor"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/> <fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/> <textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/>
</textField> </textField>
<textField opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your courses" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="69O-Fo-TQF"> <textField opaque="NO" contentMode="scaleToFill" horizontalCompressionResistancePriority="749" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your courses" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="69O-Fo-TQF">
<rect key="frame" x="24" y="108" width="328" height="30"/> <rect key="frame" x="24" y="108" width="328" height="30"/>
<accessibility key="accessibilityConfiguration" hint="Courses"/> <accessibility key="accessibilityConfiguration" hint="Courses"/>
<nil key="textColor"/> <nil key="textColor"/>
@@ -356,7 +356,7 @@
<!--AvH Plan--> <!--AvH Plan-->
<scene sceneID="yl2-sM-qoP"> <scene sceneID="yl2-sM-qoP">
<objects> <objects>
<tabBarController title="AvH Plan" id="49e-Tb-3d3" customClass="CustomTabBarController" customModule="AvH_Plan" customModuleProvider="target" sceneMemberID="viewController"> <tabBarController storyboardIdentifier="AppTabBarController" title="AvH Plan" id="49e-Tb-3d3" customClass="CustomTabBarController" customModule="AvH_Plan" customModuleProvider="target" sceneMemberID="viewController">
<tabBar key="tabBar" contentMode="scaleToFill" id="W28-zg-YXA"> <tabBar key="tabBar" contentMode="scaleToFill" id="W28-zg-YXA">
<rect key="frame" x="0.0" y="975" width="768" height="49"/> <rect key="frame" x="0.0" y="975" width="768" height="49"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES"/> <autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES"/>
@@ -445,6 +445,264 @@
</objects> </objects>
<point key="canvasLocation" x="704" y="1221"/> <point key="canvasLocation" x="704" y="1221"/>
</scene> </scene>
<!--Navigation Controller-->
<scene sceneID="a7C-oq-pZj">
<objects>
<navigationController storyboardIdentifier="Login" id="wrP-Kj-tyh" sceneMemberID="viewController">
<navigationBar key="navigationBar" contentMode="scaleToFill" insetsLayoutMarginsFromSafeArea="NO" largeTitles="YES" id="ir2-yb-Qay">
<rect key="frame" x="0.0" y="44" width="414" height="96"/>
<autoresizingMask key="autoresizingMask"/>
</navigationBar>
<connections>
<segue destination="71z-sS-Hw4" kind="relationship" relationship="rootViewController" id="FU3-fX-fr5"/>
</connections>
</navigationController>
<placeholder placeholderIdentifier="IBFirstResponder" id="ORQ-eI-3d1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="2677" y="206"/>
</scene>
<!--Hello there!-->
<scene sceneID="HUz-Mf-yIW">
<objects>
<viewController id="71z-sS-Hw4" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="C2s-yU-WXK">
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="ZIX-7y-psY">
<rect key="frame" x="20" y="156" width="374" height="142.33333333333337"/>
<string key="text">Please click the button above to enter your username and password to verify that you're occupied at the Alexander-von-Humboldt-Gymnasium.
This login is only required once and your information will not be shared with anybody.</string>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="ZIX-7y-psY" firstAttribute="top" secondItem="ztZ-EJ-0pf" secondAttribute="top" constant="16" id="Eh3-2Q-QgV"/>
<constraint firstItem="ztZ-EJ-0pf" firstAttribute="trailing" secondItem="ZIX-7y-psY" secondAttribute="trailing" constant="20" id="aCZ-3M-AHf"/>
<constraint firstItem="ZIX-7y-psY" firstAttribute="leading" secondItem="ztZ-EJ-0pf" secondAttribute="leading" constant="20" id="rK9-Xu-Rbv"/>
</constraints>
<viewLayoutGuide key="safeArea" id="ztZ-EJ-0pf"/>
</view>
<navigationItem key="navigationItem" title="Hello there!" id="AmM-kS-Dd7">
<barButtonItem key="rightBarButtonItem" title="Log in" id="NUo-Rl-vf4">
<connections>
<segue destination="VcC-PU-4w2" kind="show" id="Gdj-21-S6j"/>
</connections>
</barButtonItem>
</navigationItem>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="knw-eA-DLK" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="3494" y="206"/>
</scene>
<!--Navigation Controller-->
<scene sceneID="1iA-SY-pPa">
<objects>
<placeholder placeholderIdentifier="IBFirstResponder" id="43X-Sp-rFd" userLabel="First Responder" sceneMemberID="firstResponder"/>
<navigationController storyboardIdentifier="FirstTime" id="Jo3-et-Mdy" sceneMemberID="viewController">
<navigationBar key="navigationBar" contentMode="scaleToFill" insetsLayoutMarginsFromSafeArea="NO" largeTitles="YES" id="Vmw-90-CHR">
<rect key="frame" x="0.0" y="44" width="414" height="96"/>
<autoresizingMask key="autoresizingMask"/>
</navigationBar>
<connections>
<segue destination="rnZ-JC-kBT" kind="relationship" relationship="rootViewController" id="72E-26-83i"/>
</connections>
</navigationController>
</objects>
<point key="canvasLocation" x="2608" y="884"/>
</scene>
<!--Welcome!-->
<scene sceneID="SpA-gw-oPv">
<objects>
<viewController id="rnZ-JC-kBT" customClass="FirstTimeViewController" customModule="AvH_Plan" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="Ir0-QI-oGC">
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="IP4-V7-jcg">
<rect key="frame" x="0.0" y="140" width="414" height="722"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="0cy-QE-LNr">
<rect key="frame" x="0.0" y="0.0" width="414" height="465.33333333333331"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="szd-aA-XdS">
<rect key="frame" x="20" y="16" width="374" height="61"/>
<string key="text">First, let's setup some things.
Tell me your name.</string>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<textField opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your name" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="pH1-JE-B6v">
<rect key="frame" x="20" y="93" width="374" height="30"/>
<nil key="textColor"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/>
</textField>
<textField opaque="NO" contentMode="scaleToFill" horizontalCompressionResistancePriority="749" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your grade" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="b6K-FB-rfo">
<rect key="frame" x="20" y="175.33333333333331" width="336" height="30"/>
<nil key="textColor"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/>
</textField>
<textField opaque="NO" contentMode="scaleToFill" horizontalCompressionResistancePriority="749" contentHorizontalAlignment="left" contentVerticalAlignment="center" borderStyle="roundedRect" placeholder="Your course" textAlignment="natural" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="dWO-0U-i1C">
<rect key="frame" x="20" y="298.33333333333331" width="336" height="30"/>
<nil key="textColor"/>
<fontDescription key="fontDescription" type="system" pointSize="14"/>
<textInputTraits key="textInputTraits" autocorrectionType="no" spellCheckingType="no" smartDashesType="no" smartInsertDeleteType="no" smartQuotesType="no"/>
</textField>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Next, tell me which grade you're in." textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="QEa-bk-RFE">
<rect key="frame" x="20" y="139" width="374" height="20.333333333333343"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="If you're in senior phase (E-Phase, Q-Phase), please also tell me which courses you're enrolled in." textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="F3r-Ao-Iih">
<rect key="frame" x="20" y="221.33333333333331" width="374" height="61"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" textAlignment="natural" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Eor-Sq-zqK">
<rect key="frame" x="20" y="344.33333333333331" width="374" height="61"/>
<string key="text">Lastly, please pick the type of substitution plan you want to see when you launch the app. Click the button at the top to finish setup.</string>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<nil key="textColor"/>
<nil key="highlightedColor"/>
</label>
<segmentedControl opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="top" segmentControlStyle="plain" selectedSegmentIndex="0" translatesAutoresizingMaskIntoConstraints="NO" id="xXa-1j-Cw3">
<rect key="frame" x="20" y="421.33333333333337" width="374" height="29"/>
<segments>
<segment title="General"/>
<segment title="Personal"/>
</segments>
</segmentedControl>
<button opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="detailDisclosure" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="5ow-Mz-5J9">
<rect key="frame" x="372" y="179.33333333333331" width="22" height="22"/>
<connections>
<action selector="gradeInfoButton:" destination="rnZ-JC-kBT" eventType="touchUpInside" id="Ec2-kW-LH4"/>
<action selector="groupHelpButton:" destination="8XB-jK-YFD" eventType="touchUpInside" id="P6s-da-euY"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="detailDisclosure" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="vTq-Xg-Vnx">
<rect key="frame" x="372" y="302.33333333333331" width="22" height="22"/>
<connections>
<action selector="courseInfoButton:" destination="rnZ-JC-kBT" eventType="touchUpInside" id="jDC-Pi-wy4"/>
<action selector="groupHelpButton:" destination="8XB-jK-YFD" eventType="touchUpInside" id="au7-hN-6i5"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="szd-aA-XdS" secondAttribute="trailing" constant="20" id="0SL-bt-sNa"/>
<constraint firstAttribute="trailing" secondItem="5ow-Mz-5J9" secondAttribute="trailing" constant="20" id="6Tx-rq-hb5"/>
<constraint firstItem="dWO-0U-i1C" firstAttribute="top" secondItem="F3r-Ao-Iih" secondAttribute="bottom" constant="16" id="Avc-hf-rsn"/>
<constraint firstItem="vTq-Xg-Vnx" firstAttribute="leading" secondItem="dWO-0U-i1C" secondAttribute="trailing" constant="16" id="Bvv-0C-QmI"/>
<constraint firstItem="xXa-1j-Cw3" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="DAS-rO-WAJ"/>
<constraint firstItem="dWO-0U-i1C" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="Gcq-XF-mAS"/>
<constraint firstItem="vTq-Xg-Vnx" firstAttribute="centerY" secondItem="dWO-0U-i1C" secondAttribute="centerY" id="HhW-G9-jct"/>
<constraint firstItem="pH1-JE-B6v" firstAttribute="top" secondItem="szd-aA-XdS" secondAttribute="bottom" constant="16" id="IwP-WZ-3jo"/>
<constraint firstAttribute="trailing" secondItem="F3r-Ao-Iih" secondAttribute="trailing" constant="20" id="LUE-92-eFj"/>
<constraint firstItem="b6K-FB-rfo" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="PNr-5M-9in"/>
<constraint firstAttribute="trailing" secondItem="QEa-bk-RFE" secondAttribute="trailing" constant="20" id="R4z-V5-m4e"/>
<constraint firstAttribute="bottom" secondItem="xXa-1j-Cw3" secondAttribute="bottom" constant="16" id="SiS-pf-hok"/>
<constraint firstItem="Eor-Sq-zqK" firstAttribute="top" secondItem="dWO-0U-i1C" secondAttribute="bottom" constant="16" id="Tpw-VV-kPx"/>
<constraint firstItem="b6K-FB-rfo" firstAttribute="top" secondItem="QEa-bk-RFE" secondAttribute="bottom" constant="16" id="WPg-z6-Rpu"/>
<constraint firstItem="QEa-bk-RFE" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="XjI-nU-Vdo"/>
<constraint firstItem="xXa-1j-Cw3" firstAttribute="top" secondItem="Eor-Sq-zqK" secondAttribute="bottom" constant="16" id="Yxd-w9-EvV"/>
<constraint firstItem="szd-aA-XdS" firstAttribute="top" secondItem="0cy-QE-LNr" secondAttribute="top" constant="16" id="cAa-3e-cHr"/>
<constraint firstItem="F3r-Ao-Iih" firstAttribute="top" secondItem="b6K-FB-rfo" secondAttribute="bottom" constant="16" id="d4c-P1-633"/>
<constraint firstItem="QEa-bk-RFE" firstAttribute="top" secondItem="pH1-JE-B6v" secondAttribute="bottom" constant="16" id="etI-AB-KSH"/>
<constraint firstAttribute="trailing" secondItem="vTq-Xg-Vnx" secondAttribute="trailing" constant="20" id="f0V-jY-CFs"/>
<constraint firstItem="5ow-Mz-5J9" firstAttribute="leading" secondItem="b6K-FB-rfo" secondAttribute="trailing" constant="16" id="hgD-hV-eim"/>
<constraint firstAttribute="trailing" secondItem="pH1-JE-B6v" secondAttribute="trailing" constant="20" id="iHo-dn-sQx"/>
<constraint firstItem="pH1-JE-B6v" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="iaX-1o-DSG"/>
<constraint firstItem="szd-aA-XdS" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="pan-pR-Rbc"/>
<constraint firstItem="5ow-Mz-5J9" firstAttribute="centerY" secondItem="b6K-FB-rfo" secondAttribute="centerY" id="r2k-2w-jgK"/>
<constraint firstItem="F3r-Ao-Iih" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="s5S-a8-xWn"/>
<constraint firstAttribute="trailing" secondItem="xXa-1j-Cw3" secondAttribute="trailing" constant="20" id="yzN-nu-Qer"/>
<constraint firstAttribute="trailing" secondItem="Eor-Sq-zqK" secondAttribute="trailing" constant="20" id="zvY-cb-3fF"/>
<constraint firstItem="Eor-Sq-zqK" firstAttribute="leading" secondItem="0cy-QE-LNr" secondAttribute="leading" constant="20" id="zxw-5P-fVF"/>
</constraints>
</view>
</subviews>
<constraints>
<constraint firstItem="0cy-QE-LNr" firstAttribute="leading" secondItem="IP4-V7-jcg" secondAttribute="leading" id="4wk-aK-BJP"/>
<constraint firstAttribute="trailing" secondItem="0cy-QE-LNr" secondAttribute="trailing" id="QKj-by-SeU"/>
<constraint firstItem="0cy-QE-LNr" firstAttribute="top" secondItem="IP4-V7-jcg" secondAttribute="top" id="lh5-B4-Oxr"/>
<constraint firstAttribute="bottom" secondItem="0cy-QE-LNr" secondAttribute="bottom" id="t0x-X0-UyW"/>
<constraint firstItem="0cy-QE-LNr" firstAttribute="width" secondItem="IP4-V7-jcg" secondAttribute="width" id="uzR-B5-E7m"/>
</constraints>
</scrollView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="TDO-88-aox" firstAttribute="bottom" secondItem="IP4-V7-jcg" secondAttribute="bottom" id="Fil-Gb-KbO"/>
<constraint firstItem="TDO-88-aox" firstAttribute="trailing" secondItem="IP4-V7-jcg" secondAttribute="trailing" id="Ndv-NW-j3L"/>
<constraint firstItem="IP4-V7-jcg" firstAttribute="top" secondItem="TDO-88-aox" secondAttribute="top" id="cu9-Ae-FdJ"/>
<constraint firstItem="IP4-V7-jcg" firstAttribute="leading" secondItem="TDO-88-aox" secondAttribute="leading" id="plD-iI-hap"/>
</constraints>
<viewLayoutGuide key="safeArea" id="TDO-88-aox"/>
</view>
<navigationItem key="navigationItem" title="Welcome!" id="KbA-z7-Ss6">
<barButtonItem key="rightBarButtonItem" title="Finish" id="6Ce-T9-ZJX">
<connections>
<action selector="finishSetupButton:" destination="rnZ-JC-kBT" id="SIY-pC-6Pk"/>
</connections>
</barButtonItem>
</navigationItem>
<connections>
<outlet property="courseTextField" destination="dWO-0U-i1C" id="yCS-kN-Gf6"/>
<outlet property="defaultPlanSegmentedControl" destination="xXa-1j-Cw3" id="8Ve-4Z-4cT"/>
<outlet property="gradeTextField" destination="b6K-FB-rfo" id="PbA-qF-Wgb"/>
<outlet property="nameTextField" destination="pH1-JE-B6v" id="bgN-VN-Cfn"/>
<outlet property="scrollView" destination="IP4-V7-jcg" id="Xxo-ES-TSj"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="nGa-db-93s" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="3495.652173913044" y="881.91964285714278"/>
</scene>
<!--Log in-->
<scene sceneID="WEH-5u-Eyk">
<objects>
<viewController title="Log in" id="VcC-PU-4w2" customClass="LoginViewController" customModule="AvH_Plan" customModuleProvider="target" sceneMemberID="viewController">
<view key="view" contentMode="scaleToFill" id="Aey-S6-YoJ">
<rect key="frame" x="0.0" y="0.0" width="414" height="896"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<wkWebView contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="xo2-qg-VPG">
<rect key="frame" x="0.0" y="140" width="414" height="722"/>
<color key="backgroundColor" red="0.36078431370000003" green="0.38823529410000002" blue="0.4039215686" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<wkWebViewConfiguration key="configuration" allowsAirPlayForMediaPlayback="NO" allowsPictureInPictureMediaPlayback="NO">
<dataDetectorTypes key="dataDetectorTypes"/>
<audiovisualMediaTypes key="mediaTypesRequiringUserActionForPlayback" none="YES"/>
<wkPreferences key="preferences"/>
</wkWebViewConfiguration>
</wkWebView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="xo2-qg-VPG" firstAttribute="top" secondItem="VDO-P3-vAV" secondAttribute="top" id="Nbq-Zh-Ucu"/>
<constraint firstItem="xo2-qg-VPG" firstAttribute="leading" secondItem="VDO-P3-vAV" secondAttribute="leading" id="hMN-dw-MDN"/>
<constraint firstItem="VDO-P3-vAV" firstAttribute="trailing" secondItem="xo2-qg-VPG" secondAttribute="trailing" id="rkx-1r-79R"/>
<constraint firstItem="VDO-P3-vAV" firstAttribute="bottom" secondItem="xo2-qg-VPG" secondAttribute="bottom" id="u4N-Kz-mgQ"/>
</constraints>
<viewLayoutGuide key="safeArea" id="VDO-P3-vAV"/>
</view>
<connections>
<outlet property="webView" destination="xo2-qg-VPG" id="Dad-AD-hcK"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="Ufs-OB-0N6" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="4246" y="207"/>
</scene>
</scenes> </scenes>
<resources> <resources>
<image name="ic_idea" width="16.666666030883789" height="25"/> <image name="ic_idea" width="16.666666030883789" height="25"/>
+3 -10
View File
@@ -32,11 +32,11 @@ class CustomizationViewController: UIViewController, UICollectionViewDataSource,
} }
@IBAction func groupHelpButton(_ sender: UIButton) { @IBAction func groupHelpButton(_ sender: UIButton) {
self.present(self.getAlert(for: "grade"), animated: true) self.present(self.df.getInfoAlert(for: "grade"), animated: true)
} }
@IBAction func courseHelpButton(_ sender: UIButton) { @IBAction func courseHelpButton(_ sender: UIButton) {
self.present(self.getAlert(for: "course"), animated: true) self.present(self.df.getInfoAlert(for: "course"), animated: true)
} }
func textFieldDidBeginEditing(_ textField: UITextField) { func textFieldDidBeginEditing(_ textField: UITextField) {
@@ -73,7 +73,7 @@ class CustomizationViewController: UIViewController, UICollectionViewDataSource,
self.txtCourses.text = prefs.string(forKey: "courses") self.txtCourses.text = prefs.string(forKey: "courses")
self.defaultSegments.selectedSegmentIndex = prefs.integer(forKey: "default-plan") self.defaultSegments.selectedSegmentIndex = prefs.integer(forKey: "default-plan")
NotificationCenter.default.addObserver(self, selector: #selector(loadList), name:NSNotification.Name(rawValue: "load"), object: nil) NotificationCenter.default.addObserver(self, selector: #selector(loadList), name: NSNotification.Name(rawValue: "load"), object: nil)
} }
@objc func loadList(notification: NSNotification){ @objc func loadList(notification: NSNotification){
@@ -137,11 +137,4 @@ class CustomizationViewController: UIViewController, UICollectionViewDataSource,
cell.backgroundColor = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0) cell.backgroundColor = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0)
return cell return cell
} }
func getAlert(for type: String) -> UIAlertController {
let alert = UIAlertController(title: NSLocalizedString("enter_\(type)_title", comment: ""), message: NSLocalizedString("enter_\(type)_help", comment: ""), preferredStyle: .alert)
alert.addAction(UIAlertAction(title: NSLocalizedString("dismiss", comment: ""), style: .default) { action in
})
return alert
}
} }
+7
View File
@@ -400,4 +400,11 @@ class DataFetcher {
return nil return nil
} }
} }
func getInfoAlert(for type: String) -> UIAlertController {
let alert = UIAlertController(title: NSLocalizedString("enter_\(type)_title", comment: ""), message: NSLocalizedString("enter_\(type)_help", comment: ""), preferredStyle: .alert)
alert.addAction(UIAlertAction(title: NSLocalizedString("dismiss", comment: ""), style: .default) { action in
})
return alert
}
} }
+51
View File
@@ -0,0 +1,51 @@
//
// FirstTimeViewController.swift
// AvH Plan
//
// Created by Deniz Duezgoeren on 21.09.19.
// Copyright © 2019 Deniz Duezgoeren. All rights reserved.
//
import UIKit
class FirstTimeViewController: UIViewController {
@IBOutlet weak var scrollView: UIScrollView!
let df = DataFetcher.sharedInstance
let prefs = UserDefaults.standard
@IBAction func gradeInfoButton(_ sender: UIButton) {
self.present(self.df.getInfoAlert(for: "grade"), animated: true)
}
@IBAction func courseInfoButton(_ sender: UIButton) {
self.present(self.df.getInfoAlert(for: "course"), animated: true)
}
@IBOutlet weak var nameTextField: UITextField!
@IBOutlet weak var gradeTextField: UITextField!
@IBOutlet weak var courseTextField: UITextField!
@IBOutlet weak var defaultPlanSegmentedControl: UISegmentedControl!
@IBAction func finishSetupButton(_ sender: UIBarButtonItem) {
self.prefs.set(self.nameTextField.text, forKey: "username")
self.prefs.set(self.gradeTextField.text, forKey: "classes")
self.prefs.set(self.courseTextField.text, forKey: "courses")
self.prefs.set(self.defaultPlanSegmentedControl.selectedSegmentIndex, forKey: "default-plan")
self.prefs.set(true, forKey: "setup_finished")
self.prefs.synchronize()
if let s = storyboard?.instantiateViewController(withIdentifier: "AppTabBarController") as? CustomTabBarController {
self.present(s, animated: true)
}
}
override func viewDidLoad() {
super.viewDidLoad()
self.scrollView.isDirectionalLockEnabled = true
}
}
+41
View File
@@ -0,0 +1,41 @@
//
// LoginViewController.swift
// AvH Plan
//
// Created by Deniz Duezgoeren on 21.09.19.
// Copyright © 2019 Deniz Duezgoeren. All rights reserved.
//
import UIKit
import WebKit
class LoginViewController: UIViewController, WKNavigationDelegate {
@IBOutlet weak var webView: WKWebView!
let prefs = UserDefaults.standard
override func viewDidLoad() {
super.viewDidLoad()
let request = URLRequest(url: URL(string: "https://307.joomla.schule.bremen.de/index.php/component/users/#top")!)
self.webView.load(request)
self.webView.navigationDelegate = self
}
func webView(_ webView: WKWebView, didFinish navigation: WKNavigation!) {
self.webView.configuration.websiteDataStore.httpCookieStore.getAllCookies { cookies in
for cookie in cookies {
if cookie.name == "joomla_user_state" && cookie.value == "logged_in" {
self.success()
}
}
}
}
private func success() {
self.prefs.set(true, forKey: "logged_in")
if let s = storyboard?.instantiateViewController(withIdentifier: "FirstTime") as? UINavigationController {
self.present(s, animated: true)
}
}
}
@@ -10,8 +10,6 @@ import UIKit
class PersonalPlanViewController: PlanViewController { class PersonalPlanViewController: PlanViewController {
let prefs = UserDefaults.standard
@IBAction func customize(_ sender: UIBarButtonItem) { @IBAction func customize(_ sender: UIBarButtonItem) {
if let s = storyboard?.instantiateViewController(withIdentifier: "Customize") as? CustomizationViewController { if let s = storyboard?.instantiateViewController(withIdentifier: "Customize") as? CustomizationViewController {
self.present(s, animated: true) self.present(s, animated: true)
+17 -4
View File
@@ -21,6 +21,7 @@ class PlanViewController : UICollectionViewController, UICollectionViewDelegateM
var url = "" var url = ""
var indexOfPSA: Int? = nil var indexOfPSA: Int? = nil
let cancellations = ["eigenverantwortliches arbeiten", "entfall", "entfällt", "fällt aus", "freisetzung", "vtr. ohne lehrer"] let cancellations = ["eigenverantwortliches arbeiten", "entfall", "entfällt", "fällt aus", "freisetzung", "vtr. ohne lehrer"]
let prefs = UserDefaults.standard
required init?(coder decoder: NSCoder) { required init?(coder decoder: NSCoder) {
super.init(coder: decoder) super.init(coder: decoder)
@@ -28,12 +29,26 @@ class PlanViewController : UICollectionViewController, UICollectionViewDelegateM
} }
override func viewWillAppear(_ animated: Bool) { override func viewWillAppear(_ animated: Bool) {
if !self.prefs.bool(forKey: "logged_in") {
if let s = storyboard?.instantiateViewController(withIdentifier: "Login") as? UINavigationController {
self.present(s, animated: true)
}
} else if !self.prefs.bool(forKey: "setup_finished") {
if let s = storyboard?.instantiateViewController(withIdentifier: "FirstTime") as? UINavigationController {
self.present(s, animated: true)
}
}
super.viewWillAppear(animated) super.viewWillAppear(animated)
if self.prefs.bool(forKey: "logged_in") {
Messaging.messaging().subscribe(toTopic: "substitutions-ios") Messaging.messaging().subscribe(toTopic: "substitutions-ios")
Messaging.messaging().subscribe(toTopic: "substitutions-broadcast") Messaging.messaging().subscribe(toTopic: "substitutions-broadcast")
Crashlytics.sharedInstance().setUserIdentifier(UserDefaults.standard.string(forKey: "username")) Crashlytics.sharedInstance().setUserIdentifier(UserDefaults.standard.string(forKey: "username"))
// check if these can be put in AppDelegate // check if these can be put in AppDelegate
}
view.addSubview(collectionView) view.addSubview(collectionView)
collectionView.translatesAutoresizingMaskIntoConstraints = true collectionView.translatesAutoresizingMaskIntoConstraints = true
@@ -65,6 +80,7 @@ class PlanViewController : UICollectionViewController, UICollectionViewDelegateM
override func viewDidLoad() { override func viewDidLoad() {
super.viewDidLoad() super.viewDidLoad()
self.extendedLayoutIncludesOpaqueBars = true self.extendedLayoutIncludesOpaqueBars = true
self.collectionView.contentInsetAdjustmentBehavior = .always self.collectionView.contentInsetAdjustmentBehavior = .always
self.df.setTabBarBadge(for: self.tabBarController?.tabBar.items) self.df.setTabBarBadge(for: self.tabBarController?.tabBar.items)
@@ -128,7 +144,7 @@ class PlanViewController : UICollectionViewController, UICollectionViewDelegateM
url = "\(dateString[dateString.index(dateString.startIndex, offsetBy: 3)...])" url = "\(dateString[dateString.index(dateString.startIndex, offsetBy: 3)...])"
indexOfPSA = indexPath.item indexOfPSA = indexPath.item
} }
image = UIImage(named: "ic_idea_w") image = UIImage(named: "ic_idea_psa_white")
cell.tintView.backgroundColor = #colorLiteral(red: 0, green: 0.4784313725, blue: 1, alpha: 1) cell.tintView.backgroundColor = #colorLiteral(red: 0, green: 0.4784313725, blue: 1, alpha: 1)
cell.group.textColor = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0) cell.group.textColor = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0)
cell.course.textColor = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0) cell.course.textColor = #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0)
@@ -195,9 +211,6 @@ class PlanViewController : UICollectionViewController, UICollectionViewDelegateM
courseImage.append(NSAttributedString(string: " ")) courseImage.append(NSAttributedString(string: " "))
let courseString = mutableStrings[2] let courseString = mutableStrings[2]
courseImage.append(courseString) courseImage.append(courseString)
if psa == true {
courseImage.addAttribute(NSAttributedString.Key.foregroundColor, value: #colorLiteral(red: 1.0, green: 1.0, blue: 1.0, alpha: 1.0), range: NSMakeRange(0, 3))
}
courseText = courseImage courseText = courseImage
} else { } else {