Compare commits

...

588 Commits
1.1.4 ... 1.7.2

Author SHA1 Message Date
4b795d6ef5 Merge branch 'release/1.7.2' 2022-08-30 13:34:20 +02:00
d139bd5b14 Version 1.7.2 2022-08-30 13:34:10 +02:00
bf34cb0c1e New Crowdin updates (#1953)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2022-08-30 12:11:32 +02:00
eed091aad2 Update row in mailboxes table on primary key conflict (#1954) 2022-08-30 09:07:24 +02:00
535206056d Fix selecting student mailbox based on studentName field (#1958) 2022-08-30 09:07:07 +02:00
f2cb3b4f9e Change message draft key in shared preferences (#1959) 2022-08-30 09:06:29 +02:00
54372e0a55 Bump kotlinx-serialization-json from 1.3.3 to 1.4.0 (#1950) 2022-08-29 13:40:14 +00:00
5c17c38d1d Bump mockk from 1.12.5 to 1.12.7 (#1955) 2022-08-29 13:30:56 +00:00
f68a8e4215 Bump robolectric from 4.8.1 to 4.8.2 (#1956) 2022-08-29 13:30:28 +00:00
70c2cb7dbf Bump desugar_jdk_libs from 1.1.6 to 1.1.8 (#1957) 2022-08-29 13:30:00 +00:00
7f6fd60821 Merge branch 'release/1.7.1' into develop 2022-08-23 00:56:29 +02:00
62c04fb205 Merge branch 'release/1.7.1' 2022-08-23 00:56:20 +02:00
10c36f19bf Version 1.7.1 2022-08-23 00:56:12 +02:00
37d756b8fe New Crowdin updates (#1952) 2022-08-23 00:54:19 +02:00
de1bc4809f Fix ads translations (#1951) 2022-08-23 00:08:39 +02:00
3d6ec93cde Merge branch 'release/1.7.0' into develop 2022-08-22 17:58:51 +02:00
c293c76398 Merge branch 'release/1.7.0' 2022-08-22 17:58:41 +02:00
09e07a1713 Version 1.7.0 2022-08-22 17:58:35 +02:00
71f1a55437 New Crowdin updates (#1895) 2022-08-22 16:45:59 +02:00
d9e22af5ef Bump desugar_jdk_libs from 1.1.5 to 1.1.6 (#1948) 2022-08-22 13:28:58 +00:00
bc0689a30d Bump coil from 2.1.0 to 2.2.0 (#1949) 2022-08-22 13:28:27 +00:00
9d47127921 Add support for messages plus API (#1945) 2022-08-22 14:30:50 +02:00
08a3bd77bd Bump appcompat from 1.4.2 to 1.5.0 (#1946) 2022-08-22 07:00:10 +00:00
9fe1151a04 Bump fragment-ktx from 1.5.1 to 1.5.2 (#1947) 2022-08-19 22:22:47 +00:00
793952cb44 Fix typo in README DE.md (#1936)
* Update README.de.md

* Change in README-DE.md file
2022-08-14 22:16:47 +02:00
d64a21b50c Bump hianalytics from 6.6.0.300 to 6.7.0.300 (#1944) 2022-08-10 09:56:20 +00:00
274f9dde07 Bump agconnect-crash from 1.7.0.300 to 1.7.1.300 (#1943) 2022-08-10 09:48:02 +00:00
5a884a4c56 Bump agcp from 1.7.0.300 to 1.7.1.300 (#1938) 2022-08-10 09:38:15 +00:00
c55fd98179 Bump about_libraries from 10.3.1 to 10.4.0 (#1941) 2022-08-10 09:37:53 +00:00
ffc0cd840b Update workflow dependency (#1937)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2022-08-10 11:28:22 +02:00
96067946d0 Bump firebase-bom from 30.3.1 to 30.3.2 (#1940) 2022-08-10 09:27:46 +00:00
9339e7d916 Bump gradle from 7.2.1 to 7.2.2 (#1942) 2022-08-10 09:27:24 +00:00
b4117aa62e Bump flow-preferences from 1.7.0 to 1.8.0 (#1925) 2022-08-03 10:56:41 +00:00
dc3a941e24 Bump core-splashscreen from 1.0.0-rc01 to 1.0.0 (#1929) 2022-08-01 21:36:28 +00:00
b67ecbba4b Bump room from 2.4.2 to 2.4.3 (#1928) 2022-08-01 21:26:37 +00:00
1175740ba2 Bump activity-ktx from 1.5.0 to 1.5.1 (#1926) 2022-08-01 21:26:34 +00:00
378ed0100f Bump huawei-publish-gradle-plugin from 1.3.3 to 1.3.4 (#1934) 2022-08-01 21:26:15 +00:00
cf87339ac4 Bump hilt_version from 2.43 to 2.43.1 (#1927) 2022-08-01 21:18:52 +00:00
c23a90f104 Bump fragment-ktx from 1.5.0 to 1.5.1 (#1930) 2022-08-01 21:17:35 +00:00
d337be0f40 Bump firebase-bom from 30.3.0 to 30.3.1 (#1931) 2022-08-01 21:17:20 +00:00
cf7c6f78ea Bump lifecycle-livedata-ktx from 2.5.0 to 2.5.1 (#1932) 2022-08-01 21:17:00 +00:00
efa68f5044 Bump mockk from 1.12.4 to 1.12.5 (#1933) 2022-08-01 21:16:46 +00:00
b9be85d99c Bump hilt_version from 2.42 to 2.43 (#1923) 2022-07-27 10:09:28 +00:00
dfc4553fc6 Bump firebase-bom from 30.2.0 to 30.3.0 (#1920) 2022-07-21 21:28:53 +00:00
08c9539abe Bump coroutines from 1.6.3 to 1.6.4 (#1921) 2022-07-21 21:28:37 +00:00
fd18583df2 Bump play-services-ads from 21.0.0 to 21.1.0 (#1922) 2022-07-21 21:28:20 +00:00
7c4f1c7b22 Add auto refresh to reporting units (#1916) 2022-07-12 12:23:55 +02:00
bdb6c962ea Bump hianalytics from 6.5.0.300 to 6.6.0.300 (#1919) 2022-07-12 10:20:42 +00:00
f1c217b087 Bump kotlin_version from 1.7.0 to 1.7.10 (#1918) 2022-07-12 10:20:28 +00:00
4b6277abf5 Bump activity-ktx from 1.4.0 to 1.5.0 (#1912) 2022-07-09 07:34:24 +00:00
344e0d55ff Bump lifecycle-livedata-ktx from 2.4.1 to 2.5.0 (#1911) 2022-07-09 07:34:03 +00:00
89a6a98bbf Bump google-services from 4.3.10 to 4.3.13 (#1913) 2022-07-09 07:33:46 +00:00
fcc7dc0913 Bump fragment-ktx from 1.4.1 to 1.5.0 (#1915) 2022-07-09 07:33:27 +00:00
1b74bffc06 Fix no mobile devices on parent account (#1896) 2022-07-02 19:10:57 +02:00
0f11f14c3e Bump firebase-bom from 30.1.0 to 30.2.0 (#1909) 2022-06-28 15:07:33 +00:00
e70fe6f097 Bump firebase-crashlytics-gradle from 2.9.0 to 2.9.1 (#1910) 2022-06-28 15:06:20 +00:00
b70649f136 Bump about_libraries from 10.3.0 to 10.3.1 (#1907) 2022-06-28 15:05:51 +00:00
7b13684137 Fix ads tile (#1905) 2022-06-26 15:50:35 +02:00
c4689fcbb3 Bump agconnect-crash from 1.6.6.200 to 1.7.0.300 (#1899) 2022-06-26 12:44:06 +00:00
d8f644c5b4 Add ads to dashboard (#1815) 2022-06-26 13:28:35 +02:00
c808bf2e61 Fix timetable widget day reset (#1862)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2022-06-26 13:06:43 +02:00
0fb55bd6c6 Fix doubled announcements (#1897) 2022-06-26 12:12:11 +02:00
c5dfea788c Bump annotation from 1.3.0 to 1.4.0 (#1900) 2022-06-23 12:09:50 +00:00
120e5c9171 Bump coroutines from 1.6.2 to 1.6.3 (#1902) 2022-06-23 12:09:25 +00:00
a97039a727 Fix jumping point in notes on refresh (#1898) 2022-06-19 21:04:05 +02:00
e9ba65f8f6 Fix multiline address in student info (#1891) 2022-06-18 12:12:21 +02:00
a264abf814 Fix typo in average description (#1892) 2022-06-18 12:12:04 +02:00
0a2eb07844 Fix date in attendance and timetable when day is changing (#1893) 2022-06-18 12:11:46 +02:00
bfab265ccf Fix case sensitive domain checker (#1894) 2022-06-18 11:54:08 +02:00
cd59166efb Bump sonarqube-gradle-plugin from 3.3 to 3.4.0.2513 (#1888) 2022-06-16 22:15:18 +00:00
06ed5f6079 Bump logging-interceptor from 4.9.3 to 4.10.0 (#1889) 2022-06-16 21:53:21 +00:00
6b70583573 New Crowdin updates (#1873) 2022-06-13 07:43:40 +02:00
c3cbaa6ac2 Update dependencies (#1887) 2022-06-13 07:43:12 +02:00
f61d820d6f Bump core-ktx from 1.7.0 to 1.8.0 (#1882) 2022-06-13 05:07:54 +00:00
03ad5527f8 Bump appcompat from 1.4.1 to 1.4.2 (#1883) 2022-06-13 04:59:50 +00:00
cce736410b Bump material from 1.6.0 to 1.6.1 (#1884) 2022-06-13 04:59:31 +00:00
8c515bd03f Bump coroutines from 1.6.1 to 1.6.2 (#1875) 2022-05-31 13:52:09 +00:00
8dcb3ed45d Bump firebase-crashlytics-gradle from 2.8.1 to 2.9.0 (#1874) 2022-05-31 13:51:12 +00:00
4f3f24ac10 Bump about_libraries from 10.2.0 to 10.3.0 (#1876) 2022-05-31 13:50:52 +00:00
d074e5c9b3 Bump play-services-ads from 20.6.0 to 21.0.0 (#1877) 2022-05-31 13:50:22 +00:00
d2d1d1dba7 Bump firebase-bom from 30.0.2 to 30.1.0 (#1878) 2022-05-31 13:50:03 +00:00
891e241d1a Hide account selector in MessagePreviewView and SendMessageView (#1866)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2022-05-28 02:03:42 +02:00
5c4a3d578b Add grade sorting by average (#1863) 2022-05-27 22:19:22 +02:00
fcf0adfd80 Bump gradle from 7.1.3 to 7.2.0 (#1857) 2022-05-26 05:26:52 +00:00
c42a47ac48 Bump material from 1.5.0 to 1.6.0 (#1846) 2022-05-26 04:18:37 +00:00
fa48b033af Bump constraintlayout from 2.1.3 to 2.1.4 (#1869) 2022-05-24 08:44:17 +00:00
808927a58a Bump coil from 2.0.0 to 2.1.0 (#1870) 2022-05-24 08:43:52 +00:00
dc717c9fb5 Bump core-splashscreen from 1.0.0-beta02 to 1.0.0-rc01 (#1871) 2022-05-24 08:43:32 +00:00
a2804d813a Bump firebase-bom from 30.0.1 to 30.0.2 (#1872) 2022-05-24 08:41:23 +00:00
847ab6149a Merge branch 'release/1.6.4' into develop 2022-05-16 23:42:51 +02:00
dc74d2877b Merge branch 'release/1.6.4' 2022-05-16 23:42:46 +02:00
6534176685 Version 1.6.4 2022-05-16 23:42:40 +02:00
9542b9f231 Set "no data" string if attendance subject is blank (#1864) 2022-05-16 23:23:49 +02:00
dbba61a99f Bump coil from 1.4.0 to 2.0.0 (#1855) 2022-05-14 14:48:58 +00:00
c2496a15b8 Bump flow-preferences from 1.6.0 to 1.7.0 (#1859) 2022-05-14 14:36:09 +00:00
facf84d9a8 Bump about_libraries from 8.9.4 to 10.2.0 (#1858) 2022-05-14 14:35:58 +00:00
459c8330f9 Bump hianalytics from 6.4.1.302 to 6.5.0.300 (#1852) 2022-05-14 13:53:13 +00:00
0c8e2632a2 Bump firebase-bom from 30.0.0 to 30.0.1 (#1851) 2022-05-14 13:52:58 +00:00
b17e9deca0 Bump kotlinx-serialization-json from 1.3.2 to 1.3.3 (#1853) 2022-05-14 13:52:41 +00:00
c296e72c30 Bump mockk from 1.12.2 to 1.12.4 (#1854) 2022-05-14 13:52:16 +00:00
637125e1fc Bump hilt_version from 2.41 to 2.42 (#1856) 2022-05-14 13:51:39 +00:00
445bfda801 New Crowdin updates (#1840) 2022-05-12 21:07:14 +02:00
ebde42328a Bump agcp from 1.6.5.300 to 1.6.6.200 (#1845) 2022-05-12 19:06:15 +00:00
a0bf14b576 Bump agconnect-crash from 1.6.5.300 to 1.6.6.200 (#1843) 2022-05-12 19:05:59 +00:00
2e7caabde3 Bump firebase-bom from 29.3.1 to 30.0.0 (#1844) 2022-05-12 19:05:40 +00:00
bb052fd4c9 Bump robolectric from 4.8 to 4.8.1 (#1842) 2022-05-12 19:05:20 +00:00
28ef8c6761 Bump kotlin_version from 1.6.20 to 1.6.21 (#1837) 2022-05-03 11:46:03 +00:00
15e8e096ed Bump robolectric from 4.7.3 to 4.8 (#1839) 2022-05-03 11:38:18 +00:00
6007de017f Merge branch 'release/1.6.3' into develop 2022-04-19 09:56:12 +02:00
775b5122ef Merge branch 'release/1.6.3' 2022-04-19 09:56:06 +02:00
fed00122d7 Version 1.6.3 2022-04-19 09:56:01 +02:00
426bee882c Display timetable header as HTML on dashboard tile (#1835) 2022-04-18 16:52:28 +02:00
d37de197fc Bump firebase-bom from 29.3.0 to 29.3.1 (#1836) 2022-04-18 14:52:06 +00:00
447ece3696 Replace destination parcelable with destination json string (#1833) 2022-04-16 12:17:22 +02:00
a73f39e59c Bump agconnect-crash from 1.6.5.200 to 1.6.5.300 (#1830) 2022-04-14 02:13:09 +00:00
f912aac140 Bump gradle from 7.1.2 to 7.1.3 (#1829) 2022-04-14 02:12:20 +00:00
3caabd3e0e Bump coroutines from 1.6.0 to 1.6.1 (#1828) 2022-04-14 02:06:04 +00:00
88576271e2 Bump agcp from 1.6.5.200 to 1.6.5.300 (#1831) 2022-04-14 02:05:12 +00:00
b088551005 Bump hianalytics from 6.4.1.301 to 6.4.1.302 (#1832) 2022-04-14 02:04:53 +00:00
130e11a629 Merge branch 'release/1.6.2' into develop 2022-04-10 20:37:21 +02:00
d5e0ae7b37 Merge branch 'release/1.6.2' 2022-04-10 20:37:17 +02:00
e6f56a74a4 Version 1.6.2 2022-04-10 20:37:10 +02:00
1bc59cfa7f Another attempt to fix destination crash (#1826) 2022-04-10 20:23:46 +02:00
41bae262a5 Merge branch 'release/1.6.1' into develop 2022-04-06 17:28:55 +02:00
ae65228805 Merge branch 'release/1.6.1' 2022-04-06 17:28:50 +02:00
391ee6e621 Version 1.6.1 2022-04-06 17:27:27 +02:00
0a87df3d82 New Crowdin updates (#1817) 2022-04-06 17:19:38 +02:00
cb4ae21903 Replace Serializable to Parcelable in Destination (#1823) 2022-04-06 08:01:41 +02:00
679cf2554d Fix text in lucky number widget (#1825) 2022-04-06 08:01:11 +02:00
d473d53879 Add standard register variant as translatable string (#1824) 2022-04-05 13:56:11 +02:00
6531061b48 Fix text aligment in exam dialog (#1821) 2022-04-05 10:30:49 +02:00
3347e8fba8 Bump kotlin_version from 1.6.10 to 1.6.20 (#1818) 2022-04-05 08:10:07 +00:00
84067126a1 Bump hianalytics from 6.4.1.300 to 6.4.1.301 (#1819) 2022-04-05 08:09:46 +00:00
da9bebe923 Merge branch 'release/1.6.0' into develop 2022-04-02 22:02:01 +02:00
b371fd6709 Merge branch 'release/1.6.0' 2022-04-02 22:01:53 +02:00
884d443c5b Version 1.6.0 2022-04-02 22:01:34 +02:00
df58aa78ae New Crowdin updates (#1783) 2022-03-31 09:00:41 +02:00
2131e892ad Add option to select multiple messages to delete (#1780) 2022-03-28 19:30:20 +02:00
63380d3e12 Bump agcp from 1.6.4.300 to 1.6.5.200 (#1812) 2022-03-28 13:53:57 +00:00
c572a91b38 Bump agconnect-crash from 1.6.4.300 to 1.6.5.200 (#1811) 2022-03-28 13:53:42 +00:00
20dde6e896 Resource refactor (#1589) 2022-03-27 15:33:32 +02:00
042b66ca5c Bump core-splashscreen from 1.0.0-beta01 to 1.0.0-beta02 (#1810) 2022-03-26 22:37:53 +00:00
8d8990761a Bump firebase-bom from 29.2.1 to 29.3.0 (#1809) 2022-03-26 22:37:22 +00:00
a07741b5c5 Bump WhatTheStack from 1.0.0-alpha03 to 1.0.0-alpha04 (#1807) 2022-03-22 17:49:32 +00:00
f851a4d2c5 Bump huawei-publish-gradle-plugin from 1.3.1 to 1.3.3 (#1806) 2022-03-22 12:47:27 -05:00
c8d069c787 Bump hianalytics from 6.4.0.300 to 6.4.1.300 (#1805) 2022-03-20 00:25:31 +00:00
5ce30a3000 Bump firebase-bom from 29.2.0 to 29.2.1 (#1804) 2022-03-20 00:25:11 +00:00
26e0f43fa0 Bump firebase-bom from 29.1.0 to 29.2.0 (#1803) 2022-03-17 18:28:26 +00:00
08c1bedca1 Add the option to quickly add a calendar event from the exam details (#1802)
* Extract intent utils to separate file

* Add add to calendar button in exam details dialog

* Set 8:00-8:45 start/end time
2022-03-14 00:38:40 +01:00
15537586c4 Add exam date field to exam details dialog (#1801) 2022-03-13 22:47:54 +01:00
a04ba4ae10 Login improvements (#1800)
* Update sdk

* Change default register variant name

* Change symbol hint message and email template
2022-03-13 22:43:57 +01:00
57ea6379ab Timetable timer refactor (#1785) 2022-03-13 04:01:14 +01:00
c3abe50ed4 Bump gradle from 7.1.1 to 7.1.2 (#1790) 2022-02-28 18:59:53 +00:00
f48caf9f70 Bump play-services-ads from 20.5.0 to 20.6.0 (#1792) 2022-02-28 18:41:16 +00:00
9a413c14c3 Bump agcp from 1.6.4.200 to 1.6.4.300 (#1791) 2022-02-28 18:37:29 +00:00
8915c5dd8e Bump agconnect-crash from 1.6.4.200 to 1.6.4.300 (#1793) 2022-02-28 18:32:31 +00:00
e7561d4794 Bump room from 2.4.1 to 2.4.2 (#1794) 2022-02-28 18:32:08 +00:00
820b99dbc7 Bump hilt_version from 2.40.5 to 2.41 (#1786) 2022-02-21 19:35:02 +00:00
aff0fb3a60 Add information about student in grade statistics pie chart (#1749)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2022-02-15 13:08:44 +01:00
d3bf5c3e0a Bump lifecycle-livedata-ktx from 2.4.0 to 2.4.1 (#1781) 2022-02-14 20:06:05 +00:00
dec2703cc7 Bump firebase-bom from 29.0.4 to 29.1.0 (#1782) 2022-02-14 20:05:45 +00:00
edd1c9442e Fix calc vulcan average in second semester (#1779) 2022-02-12 22:22:15 +01:00
18568c86be New Crowdin updates (#1776) 2022-02-12 12:19:25 +01:00
84d0ba525f Fix blank description in exam details (#1778) 2022-02-10 07:36:44 +01:00
6290663f02 Bump gradle from 7.1.0 to 7.1.1 (#1777) 2022-02-07 04:41:09 +00:00
be046a1ddd Update date in LICENSE file (#1775) 2022-02-07 03:16:17 +01:00
96ee4bd9e5 Keep reacting to live changes in dashboard after a force refresh (#1594)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2022-02-02 02:44:14 +00:00
923af85d18 Bump fragment-ktx from 1.4.0 to 1.4.1 (#1774) 2022-02-02 01:53:16 +00:00
ce36e86bb2 Bump preference-ktx from 1.1.1 to 1.2.0 (#1773) 2022-01-29 05:38:55 +00:00
a4f455b38f Bump hianalytics from 6.3.2.300 to 6.4.0.300 (#1771) 2022-01-29 04:55:02 +00:00
01b8bd9d4a Bump agconnect-crash from 1.6.3.300 to 1.6.4.200 (#1770) 2022-01-29 04:47:56 +00:00
cfcc051ce4 Bump gradle from 7.0.4 to 7.1.0 (#1769) 2022-01-29 04:47:26 +00:00
0b0993be9a Bump agcp from 1.6.3.300 to 1.6.4.200 (#1772) 2022-01-29 04:47:00 +00:00
d07b0dbc98 Bump WhatTheStack from 1.0.0-alpha02 to 1.0.0-alpha03 (#1768) 2022-01-29 04:46:09 +00:00
daa7b54dab Refactor notification destinations (#1709)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2022-01-28 13:43:56 +01:00
de9fcb9af9 Add what-the-stack library (#1767) 2022-01-28 12:07:48 +01:00
40e0934504 Bump fuzzywuzzy from 1.3.3 to 1.4.0 (#1765) 2022-01-28 11:07:22 +00:00
009ec433be Bump firebase-bom from 29.0.3 to 29.0.4 (#1766) 2022-01-27 12:06:30 +00:00
e1d82d70ee New translations strings.xml (German) (#1746) 2022-01-23 20:04:01 +01:00
7a9ba04ff4 Bump material from 1.4.0 to 1.5.0 (#1757) 2022-01-23 02:17:14 +00:00
513b4b7d3e Bump coordinatorlayout from 1.1.0 to 1.2.0 (#1756) 2022-01-23 01:43:30 +00:00
ce4157933f Bump core-splashscreen from 1.0.0-alpha02 to 1.0.0-beta01 (#1752) 2022-01-23 01:39:16 +00:00
5d1085a64a Bump fuzzywuzzy from 1.3.1 to 1.3.3 (#1754) 2022-01-23 00:58:12 +00:00
a00f2dcbda Bump core from 1.10.2 to 1.10.3 (#1753) 2022-01-23 00:57:40 +00:00
b52a6f7f61 Bump room from 2.4.0 to 2.4.1 (#1755) 2022-01-23 00:57:17 +00:00
5146e44574 Bump agconnect-crash from 1.6.3.200 to 1.6.3.300 (#1758) 2022-01-23 00:56:57 +00:00
90e1cea679 Bump appcompat from 1.4.0 to 1.4.1 (#1759) 2022-01-23 00:56:37 +00:00
c9b506ae10 Bump agcp from 1.6.3.200 to 1.6.3.300 (#1760) 2022-01-23 00:56:16 +00:00
14ebdad7b2 Bump constraintlayout from 2.1.2 to 2.1.3 (#1761) 2022-01-23 00:55:58 +00:00
210308695b Bump huawei-publish-gradle-plugin from 1.3.0 to 1.3.1 (#1750) 2022-01-11 11:12:48 +00:00
d5cc2263f5 Bump mockk from 1.12.1 to 1.12.2 (#1747) 2022-01-04 10:13:31 +00:00
47e3f2dc58 Merge branch 'release/1.5.0' into develop 2022-01-01 17:51:19 +01:00
6dc16b288d Merge branch 'release/1.5.0' 2022-01-01 17:51:11 +01:00
daf97be9ad Version 1.5.0 2022-01-01 17:50:02 +01:00
2bb2190410 New Crowdin updates (#1745) 2022-01-01 17:48:58 +01:00
aff1a7030d Add a custom error message for ssl errors due to invalid clock setting (#1742) 2022-01-01 15:46:08 +01:00
8877322357 Differentiate school announcements by userLoginId (#1744) 2022-01-01 13:52:51 +01:00
bc672e94f8 Strip html from school announcements notifications (#1743) 2022-01-01 13:48:58 +01:00
a03bcf8e62 Display comment after entry in grade notifications (#1741) 2021-12-31 11:36:14 +00:00
20673c4ead Add basic support for kindergarten students (#1738) 2021-12-31 12:21:52 +01:00
5321d00ee9 Fix play flavor build (#1740) 2021-12-31 12:10:56 +01:00
e6b2acabd5 Block app timezone to polish timezone (#1598) 2021-12-31 11:53:09 +01:00
bfd7f688ab Move webview locale fix to account recovery fragment (#1739) 2021-12-31 10:24:02 +00:00
ba02531aa4 Fix timetable widget crash when there are no lessons for the day (#1737) 2021-12-31 09:40:15 +01:00
210c3a0e28 Remove HiltBroadcastReceiver (#1736) 2021-12-30 12:50:06 +01:00
68f0ecc45c If only one student exists, don't show student name in timetable notification (#1711)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2021-12-29 15:44:43 +01:00
0965d03f1a New Crowdin updates (#1734) 2021-12-29 11:57:17 +01:00
496641f594 Fix notification spam after login (#1715) 2021-12-29 08:31:43 +01:00
684c258e2d Remove admin message offline first cache (#1735) 2021-12-28 18:56:59 +01:00
5e96917508 Fix overlapping text in the error dialog (#1708) 2021-12-28 12:16:52 +01:00
17096ad11b New Crowdin updates (#1729) 2021-12-27 14:06:20 +01:00
bd883c9f38 Add option to remove notifications captured from vulcan.hebe (#1716) 2021-12-27 07:48:47 +00:00
6520f8a0d7 Fix that an incorrect day would be selected in MaterialDatePicker (#1723) 2021-12-27 08:10:30 +01:00
2eee50ad81 Replace view pager in login activity with simple fragment transactions (#1686) 2021-12-27 07:58:57 +01:00
8560fd7e81 Bump coroutines from 1.5.2 to 1.6.0 (#1731) 2021-12-25 08:38:27 +00:00
f718147ae9 Bump agcp from 1.6.2.300 to 1.6.3.200 (#1730) 2021-12-25 05:55:01 +00:00
cd12c4c891 Bump agconnect-crash from 1.6.2.300 to 1.6.3.200 (#1732) 2021-12-25 05:54:34 +00:00
65f114ce05 Bump kotlinx-serialization-json from 1.3.1 to 1.3.2 (#1733) 2021-12-25 05:54:17 +00:00
497083be97 Update timetable to next day if there is no more lessons today (#1551) 2021-12-25 05:46:24 +00:00
e26860ea5a Fix state restoring in GradeStatistics (#1667)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2021-12-23 13:58:26 +01:00
094df212b4 Add additional lessons feature (#1550) 2021-12-21 00:36:59 +01:00
cc22985dc5 Bump firebase-bom from 29.0.2 to 29.0.3 (#1728) 2021-12-20 20:22:56 +00:00
ad9a2711c4 New Crowdin updates (#1687) 2021-12-19 22:46:41 +01:00
daf44c531c Merge branch 'release/1.4.4' into develop 2021-12-19 22:25:56 +01:00
4e12eb1552 Merge branch 'release/1.4.4' 2021-12-19 22:25:52 +01:00
c846cc999f Version 1.4.4 2021-12-19 22:25:47 +01:00
47d430292c Update template of login issue email (#1724)
* Update sdk

* Update template of login issue email
2021-12-19 22:08:39 +01:00
5e1ff2243f Fix exception in TimetableAdapter (#1721) 2021-12-12 23:09:34 +01:00
a35bef58f2 Bump gradle from 7.0.3 to 7.0.4 (#1718) 2021-12-12 14:06:15 +00:00
0005d84974 Bump hilt_version from 2.40.4 to 2.40.5 (#1719) 2021-12-12 14:05:53 +00:00
19558cb871 Bump firebase-bom from 29.0.1 to 29.0.2 (#1720) 2021-12-12 14:05:35 +00:00
45e884127f After deselecting fakelog, clear credentials from login form (#1713) 2021-12-12 15:04:31 +01:00
c87085a226 Fix invalid order of school announcements (#1689) 2021-12-11 17:35:55 +01:00
79b970256f More strongly typed data in preferences (#1697) 2021-12-11 16:14:46 +00:00
70f038f15f Remove useless group property from NotificationType (#1714) 2021-12-11 17:12:47 +01:00
9cabd7ef08 Deduplicate timetable time left string (#1710) 2021-12-11 16:42:33 +01:00
d89e4ccfdf Fix grade sorting by date (#1717) 2021-12-11 11:54:07 +01:00
1bcc4d199e When replying to a message use Re instead of RE (#1712) 2021-12-10 16:24:39 +01:00
2e85e88c5d Bump agcp from 1.6.2.200 to 1.6.2.300 (#1693) 2021-12-08 10:21:00 +00:00
6ab67fe25b Bump firebase-bom from 29.0.0 to 29.0.1 (#1696) 2021-12-08 10:04:29 +00:00
8563277a89 Bump robolectric from 4.7.2 to 4.7.3 (#1695) 2021-12-08 10:04:10 +00:00
e458cc90b0 Bump agconnect-crash from 1.6.2.200 to 1.6.2.300 (#1694) 2021-12-08 10:03:42 +00:00
651e3a21b9 Bump firebase-crashlytics-gradle from 2.8.0 to 2.8.1 (#1692) 2021-12-08 10:03:06 +00:00
f6b969cfb1 Bump hilt_version from 2.40.2 to 2.40.4 (#1691) 2021-12-08 10:02:43 +00:00
d2aa940d46 Convert from a stringly typed grade color to enum GradeColorTheme (#1672) 2021-11-27 10:11:17 +01:00
ab435a72ea Merge branch 'release/1.4.3' into develop 2021-11-26 22:29:13 +01:00
a56f4b8745 Merge branch 'release/1.4.3' 2021-11-26 22:29:09 +01:00
d003b0897c Version 1.4.3 2021-11-26 22:29:03 +01:00
581bb2de77 New Crowdin updates (#1669) 2021-11-26 20:22:54 +01:00
495e385228 Fix snackbar crash in grade statistics view (#1682) 2021-11-25 23:48:08 +01:00
10ba36ba44 Bump hianalytics from 6.3.0.303 to 6.3.2.300 (#1684) 2021-11-25 22:46:30 +00:00
eae396424f Bump hilt_version from 2.40.1 to 2.40.2 (#1683) 2021-11-25 22:46:17 +00:00
a7891bb266 Update viewpager2 library to fix duplicated menu bug (#1681) 2021-11-24 09:53:16 +01:00
6e82409dbc Bump play-services-ads from 20.4.0 to 20.5.0 (#1675) 2021-11-23 02:02:03 +00:00
984db18be3 Bump agcp from 1.6.1.300 to 1.6.2.200 (#1674) 2021-11-23 01:55:49 +00:00
c99bc96c08 Bump logging-interceptor from 4.9.2 to 4.9.3 (#1676) 2021-11-23 01:55:10 +00:00
3e7030abc2 Bump agconnect-crash from 1.6.1.300 to 1.6.2.200 (#1677) 2021-11-23 01:54:47 +00:00
6dad3b299b Bump robolectric from 4.7 to 4.7.2 (#1678) 2021-11-23 01:54:26 +00:00
5e997f5a3e Merge branch 'release/1.4.2' into develop 2021-11-21 13:31:56 +01:00
601d573283 Merge branch 'release/1.4.2' 2021-11-21 13:31:51 +01:00
6ae6ca7fbb Version 1.4.2 2021-11-21 13:31:45 +01:00
c3d38afc3d New Crowdin updates (#1658) 2021-11-21 13:23:43 +01:00
4e19964249 Make admin messages dissmisable (#1661) 2021-11-21 09:02:12 +01:00
a6c0efcb81 Fix empty student list in LoginStudentSelect view (#1668) 2021-11-21 07:47:23 +00:00
fcc71c0d5f Add ads limit (#1662) 2021-11-21 08:34:28 +01:00
a59d10b6c1 Disable personalized ads in single support advert (#1665) 2021-11-20 16:46:14 +01:00
a48e4eb4ee Probably fix snackbar crash in grade statistics view (#1663) 2021-11-20 16:42:21 +01:00
2a3668bb18 Fix nul login data in login symbol view (#1664) 2021-11-20 16:41:12 +01:00
804d0d9113 Add multiline to support ad preference (#1651) 2021-11-18 20:23:09 +01:00
88b893e6c0 Fix upcoming lesson notifications on Android 12 (#1650) 2021-11-18 20:22:15 +01:00
2874a7495e Add Czech and Slovak README (#1631) 2021-11-18 19:38:51 +01:00
40d8f7a93d German readme version (#1629) 2021-11-18 16:31:59 +01:00
84cd51205f Bump appcompat from 1.4.0-rc01 to 1.4.0 (#1654) 2021-11-18 01:02:12 +00:00
bac1832f27 Bump mockk from 1.12.0 to 1.12.1 (#1653) 2021-11-18 00:40:59 +00:00
8bf1e22407 Bump flow-preferences from 1.5.0 to 1.6.0 (#1657) 2021-11-18 00:40:38 +00:00
e9f43f925c Bump constraintlayout from 2.1.1 to 2.1.2 (#1656) 2021-11-18 00:37:26 +00:00
aa632edf5c Bump fragment-ktx from 1.4.0-rc01 to 1.4.0 (#1655) 2021-11-18 00:36:18 +00:00
57315d75c6 Bump work_manager from 2.7.0 to 2.7.1 (#1652) 2021-11-18 00:36:00 +00:00
4552bc85b0 Bump kotlin_version from 1.5.31 to 1.6.0 (#1635) 2021-11-18 01:34:55 +01:00
6b7795118c Merge branch 'release/1.4.1' into develop 2021-11-16 23:29:22 +01:00
1960782d8e Merge branch 'release/1.4.1' 2021-11-16 23:29:17 +01:00
8836be3766 Version 1.4.1 2021-11-16 23:29:12 +01:00
8697993149 Add missing env for google play build (#1647) 2021-11-16 23:28:03 +01:00
b88c7eb4e4 Merge branch 'release/1.4.0' into develop 2021-11-16 22:49:58 +01:00
9066bce0d5 Merge branch 'release/1.4.0' 2021-11-16 22:49:53 +01:00
f15b90782a Version 1.4.0 2021-11-16 22:40:30 +01:00
0642bf7d73 New Crowdin updates (#1646) 2021-11-16 22:38:53 +01:00
981d6d559c Login improvements (#1645) 2021-11-16 21:05:00 +00:00
39327ff3ea School and teachers UI fixes (#1644) 2021-11-16 21:45:14 +01:00
b098ac029b Fix displaying errors in GradeDetailsPresenter (#1600) 2021-11-16 20:42:06 +00:00
7e0e2fbb67 Fix saved state in main and splash activity (#1633) 2021-11-16 18:13:10 +01:00
8a181c747c Remove deprecated usage of LifecycleObserver (#1641) 2021-11-16 00:38:52 +01:00
68fdb167c2 Sort items in homework and grade tiles on the dashboard (#1634) 2021-11-15 22:35:01 +01:00
17563d1a4b Bump hianalytics from 6.3.0.302 to 6.3.0.303 (#1636) 2021-11-15 13:56:39 +00:00
370881104e Bump hilt_version from 2.40 to 2.40.1 (#1637) 2021-11-15 13:56:03 +00:00
62b1b18326 Bump kotlinx-serialization-json from 1.3.0 to 1.3.1 (#1638) 2021-11-15 13:55:45 +00:00
214e43bd4b Bump robolectric from 4.6.1 to 4.7 (#1639) 2021-11-15 13:55:18 +00:00
358e0850ad Bump appcompat from 1.4.0-beta01 to 1.4.0-rc01 (#1640) 2021-11-15 13:40:51 +00:00
c183428107 Prevent changing the current day by accident when excusing absences (#1599) 2021-11-13 19:56:17 +01:00
6de937703a Fix admin messages caching (#1632) 2021-11-13 19:50:26 +01:00
10cb2b70f1 New Crowdin updates (#1630) 2021-11-13 10:36:19 +01:00
9230db3f99 Do not show student's name in notifications if there's only one student (#1609) 2021-11-13 10:06:59 +01:00
66e58ab74e Bump activity-ktx from 1.3.1 to 1.4.0 (#1620) 2021-11-13 03:15:14 +00:00
99b7af64c0 Bump lifecycle-livedata-ktx from 2.3.1 to 2.4.0 (#1618) 2021-11-13 02:25:38 +00:00
4295dd6246 New Crowdin updates (#1566) 2021-11-11 15:56:56 +01:00
fb2d92c749 Fix homework sync (#1627) 2021-11-11 15:52:46 +01:00
07b1969a35 Bump core-ktx from 1.6.0 to 1.7.0 (#1622) 2021-11-11 14:33:01 +00:00
886403bf1e Bump annotation from 1.2.0 to 1.3.0 (#1628) 2021-11-11 14:32:19 +00:00
e8b21c1429 Bump coil from 1.3.2 to 1.4.0 (#1573) 2021-11-11 14:32:04 +00:00
007d62e61d Update project to Android SDK 31 (#1570) 2021-11-11 15:23:20 +01:00
f88d44f0ec Add timetable changes, attendance notifications and refactor notification deeplinks (#1547) 2021-11-06 22:21:34 +01:00
4401df6203 Migrate from ViewPager to ViewPager2 (#1601) 2021-11-06 19:07:26 +01:00
e6f23ab35b Add support for user ca in debug flavor(#1624) 2021-11-04 03:09:47 +01:00
eea20ced57 Notifications settings reorganize and strings update (#1616) 2021-11-04 03:06:54 +01:00
b7134221cb Bump hilt_version from 2.39.1 to 2.40 (#1617) 2021-11-01 17:05:57 +00:00
8be605629a Bump firebase-crashlytics-gradle from 2.7.1 to 2.8.0 (#1623) 2021-11-01 16:56:18 +00:00
1a3d580116 Bump firebase-bom from 28.4.2 to 29.0.0 (#1619) 2021-11-01 16:54:43 +00:00
a62ed54d07 Bump hianalytics from 6.3.0.301 to 6.3.0.302 (#1621) 2021-11-01 16:54:10 +00:00
36a570eeb0 Allow selecting text in error dialog (#1615) 2021-11-01 01:46:23 +01:00
8ed8b5a33c Error messages content wrap in error dialog (#1577) 2021-10-31 20:28:01 +01:00
26c749c219 Fix about header layout to support long app names (for DEV builds) (#1602)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2021-10-29 20:30:27 +02:00
1d910f8d66 Fix excuse button showing up despite no lessons available to excuse (#1607)
This was happening when there was an unexcused lesson that you excused until the teacher sent a response (accepted or denied it)
2021-10-27 10:07:04 +02:00
de11644e9b Bump agconnect-crash from 1.6.1.200 to 1.6.1.300 (#1605) 2021-10-26 09:53:16 +00:00
621db49fbf Bump agcp from 1.6.1.200 to 1.6.1.300 (#1606) 2021-10-26 09:52:55 +00:00
b593795844 Bump about_libraries from 8.9.3 to 8.9.4 (#1604) 2021-10-26 09:51:36 +00:00
0f800b61f6 Allow expanding multiple subject' grades at once (#1584) 2021-10-24 01:23:36 +02:00
94fd303f8e Add single support advert (#1484) 2021-10-21 10:51:00 +02:00
09a134d442 Fix last sync date to save only successful sync (#1595) 2021-10-21 10:47:37 +02:00
58ea2c530e Bump hianalytics from 6.3.0.300 to 6.3.0.301 (#1593) 2021-10-19 06:36:46 +00:00
84e4167dbd Mi Band notification improvements (#1579) 2021-10-18 00:11:46 +02:00
54e9ea6478 Use FloatingActionButton.{show,hide} instead of using setVisibility (#1591) 2021-10-16 11:17:00 +02:00
4c8d9c8f7f Fix infinite refresh when admin messages list is empty (#1587) 2021-10-14 16:25:09 +02:00
e7550f7a43 Bump gradle from 7.0.2 to 7.0.3 (#1586) 2021-10-14 00:10:22 +00:00
ac86737050 Fix NPE in SyncPresenter (#1582) 2021-10-14 01:44:34 +02:00
e3122127c0 Add admin messages (#1553) 2021-10-13 23:58:24 +02:00
d6918077bf Set upcoming lesson notification visibility to public (#1581) 2021-10-13 21:47:03 +02:00
9d0366d010 Bump firebase-bom from 28.4.1 to 28.4.2 (#1574) 2021-10-11 15:44:19 +00:00
3d0cd11ba4 Bump Treessence from 1.0.4 to 1.0.5 (#1575) 2021-10-11 15:44:03 +00:00
64dbbd54b4 Bump hianalytics from 6.2.0.301 to 6.3.0.300 (#1576) 2021-10-11 15:43:29 +00:00
539be586ce Fix text color of time left indicator on dashboard timetable card (#1572) 2021-10-11 14:39:54 +02:00
a240fd5d5f Add build timestamp as build config field (#1567) 2021-10-09 18:37:27 +02:00
4e69cfe23c Change text when there are no lessons today and tomorrow in dashboard (#1571) 2021-10-09 15:36:22 +00:00
2ab0a57a41 Separate calculated average settings (#1558) 2021-10-09 01:55:00 +02:00
ebf9e741c2 Fix homework last item padding (#1568) 2021-10-09 01:04:04 +02:00
e8075e30e4 Add "add homework" feature (#1564) 2021-10-08 11:19:49 +02:00
1839d7cb8f Migrate from moshi to kotlinx serialization (#1557) 2021-10-04 17:13:31 +02:00
2d84b0775a Bump hilt_version from 2.38.1 to 2.39.1 (#1561) 2021-10-04 14:51:31 +00:00
426379ec17 Bump about_libraries from 8.9.1 to 8.9.3 (#1560) 2021-10-04 14:45:09 +00:00
8315759c83 Bump agcp from 1.6.0.300 to 1.6.1.200 (#1562) 2021-10-04 14:44:15 +00:00
04393e60bb Bump agconnect-crash from 1.6.0.300 to 1.6.1.200 (#1563) 2021-10-04 14:43:46 +00:00
031a17ea50 Change text to bold in notifications center (#1546) 2021-10-04 16:35:37 +02:00
60501fcd72 Set buildTimestamp through manifest meta (#1556) 2021-10-03 14:13:42 +02:00
8e607d48f7 Add coroutines scope to presenter (#1554) 2021-10-03 10:36:17 +02:00
e02d93f979 Add Czech and Slovak listings (#1555) 2021-10-03 01:07:45 +02:00
76514e2d72 Merge branch 'release/1.3.0' into develop 2021-09-28 23:26:22 +02:00
689012131f Merge branch 'release/1.3.0' 2021-09-28 23:26:18 +02:00
6cdcf92782 Version 1.3.0 2021-09-28 23:26:10 +02:00
9c8bcbfdd3 New Crowdin updates (#1544) 2021-09-28 21:11:59 +00:00
0b83a66b85 Remove disappearing teachers workaround from timetable repository (#1545) 2021-09-28 23:10:11 +02:00
9711cc868c New Crowdin updates (#1522) 2021-09-28 22:42:06 +02:00
f8cb7599e6 Add missing auto refresh to recipients, subjects and teachers (#1540) 2021-09-28 22:40:43 +02:00
7636618e23 Update License (#1542) 2021-09-28 21:55:40 +02:00
5bc54c12f1 Add option to make upcoming lesson notification not persistent (#1537) 2021-09-28 11:48:25 +02:00
e10e530dee Remove seconds from timetable timer (#1539) 2021-09-27 23:03:59 +02:00
d69118b085 Add notifications center (#1524) 2021-09-27 20:58:25 +02:00
dc90549b9d Fix hiding last element in messages (#1538) 2021-09-27 17:56:43 +02:00
b552dbc904 Bump constraintlayout from 2.1.0 to 2.1.1 (#1535) 2021-09-27 15:56:11 +00:00
a6a1678b47 Bump core from 1.10.1 to 1.10.2 (#1536) 2021-09-27 15:51:06 +00:00
7a46ef5f19 Add calculated average help dialog (#1379)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2021-09-25 17:19:21 +02:00
f9e0f7b390 Don't stop loading the timetable when error occurs in upcoming lessons notification scheduling (#1532) 2021-09-25 15:18:40 +02:00
9211baf7ec Add notification piggyback (#1503) 2021-09-25 14:02:38 +02:00
de6131f4f5 Add transparency to lucky number widget (#1530) 2021-09-25 13:46:35 +02:00
2cb11e443c Mark teacher with yellow when new and old are the same (#1529) 2021-09-25 13:46:11 +02:00
a43ffcdef4 Display bad credentials error in the message box above login form (#1525) 2021-09-24 21:02:51 +02:00
6615e68430 Bump kotlin_version from 1.5.30 to 1.5.31 (#1528) 2021-09-22 09:25:54 +02:00
36daa7ccc1 Always include all language resources in app bundle (#1527) 2021-09-22 09:25:16 +02:00
6e5481f345 Upgrade Gradle Play Publisher to 3.6.0 (#1526) 2021-09-20 11:38:13 +02:00
ba1c14ca0e Merge branch 'release/1.2.3' into develop 2021-09-16 12:01:58 +02:00
c69bb2ef71 Merge branch 'release/1.2.3' 2021-09-16 12:01:54 +02:00
9cb4754132 Version 1.2.3 2021-09-16 12:01:49 +02:00
5ba8289c87 Display info in timetable as-is when lesson has change flag (#1521) 2021-09-16 11:59:23 +02:00
258782c648 New Crowdin updates (#1482) 2021-09-16 11:30:05 +02:00
c568bc1515 Fix ghost account after logout not current student (#1518) 2021-09-16 11:29:11 +02:00
da668f93cf Fix bugs in dashboard (#1517) 2021-09-16 11:24:52 +02:00
037dbd792f Add conference dialog (#1519) 2021-09-16 10:51:38 +02:00
7ec7afed87 Bump firebase-bom from 28.4.0 to 28.4.1 (#1520) 2021-09-16 08:22:06 +00:00
bea50e6db5 Merge branch 'release/1.2.2' into develop 2021-09-13 14:53:38 +02:00
6a00e75816 Merge branch 'release/1.2.2' 2021-09-13 14:53:32 +02:00
957adaf6ee Version 1.2.2 2021-09-13 14:53:27 +02:00
827fb33eeb Fix login process after was interrupted (#1505) 2021-09-13 14:36:31 +02:00
19c96ee83f Unlock sunday in navigation datepicker (#1506) 2021-09-13 14:19:46 +02:00
5a7f52c773 Update help email pre-filled content (#1507) 2021-09-13 14:19:24 +02:00
dddeff802f Fix date picker crash after saved state (#1502) 2021-09-12 17:29:46 +02:00
91f6310892 Restore lucky number in more view (#1504) 2021-09-11 19:43:05 +02:00
0389642543 Fix empty list on excuse submit (#1501) 2021-09-11 19:40:09 +02:00
8528e0beff Fix crash in school info when dialer is unavailable (#1500) 2021-09-10 09:49:22 +00:00
e665a8f18b Fix error view in attendance summary (#1492) 2021-09-10 00:48:29 +02:00
6d5acbad2c Fix overlapping error view (#1493) 2021-09-10 00:36:44 +02:00
7217d0f753 Fix NPE in timetable dashboard tile (#1498) 2021-09-10 00:27:48 +02:00
16a5d88dfb Fix overlapping shadow in dashboard (#1494) 2021-09-10 00:25:23 +02:00
646a46727f Update material chips input (#1495) 2021-09-08 09:13:52 +02:00
f5e9197f98 Bump work_manager from 2.5.0 to 2.6.0 (#1478) 2021-09-06 23:38:10 +00:00
b47f26684b Change AppGallery deploy format to aab (#1483) 2021-09-06 03:27:54 +02:00
3a03b5f1c6 Merge branch 'release/1.2.1' into develop 2021-09-05 23:29:30 +02:00
3d0dcead50 Merge branch 'release/1.2.1' 2021-09-05 23:29:23 +02:00
b64b41c11c Version 1.2.1 2021-09-05 23:29:15 +02:00
77c5330f91 Dashboard fixes (#1463) 2021-09-05 23:24:03 +02:00
2b55ec02ff New translations strings.xml (Polish) (#1474) 2021-09-05 23:06:44 +02:00
49ebae6e63 Fix overlaping empty and error view in grade statistics (#1475)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2021-09-05 19:59:03 +00:00
44a9db48a6 Bump hianalytics from 6.2.0.300 to 6.2.0.301 (#1476) 2021-09-05 18:17:18 +00:00
0008a72be1 Bump kotlinx-coroutines-test from 1.5.1 to 1.5.2 (#1477) 2021-09-05 18:10:22 +00:00
a43acaaa07 Bump kotlinx-coroutines-android from 1.5.1 to 1.5.2 (#1479) 2021-09-05 18:10:05 +00:00
e6c9abb4e5 Bump core from 1.10.0 to 1.10.1 (#1480) 2021-09-05 18:09:42 +00:00
3b9451184c Fix preview of second student guardian when first guardian is null (#1473) 2021-09-05 03:15:40 +02:00
45d1727dbe Add missing school announcement dialog (#1470) 2021-09-04 15:54:37 +02:00
8d7b611c44 Fix showing error view in timetable (#1472) 2021-09-04 15:54:05 +02:00
c3adb9b6d6 Bump agp to 7.0.2 (#1469) 2021-09-03 22:54:29 +02:00
d87283eb31 Fix opening twitter link from about on android 11 (#1460) 2021-08-30 00:20:13 +02:00
d139c22782 Bump hianalytics from 6.1.1.300 to 6.2.0.300 (#1457) 2021-08-29 19:37:18 +00:00
e557021ad9 Bump huawei-publish-gradle-plugin from 1.2.4 to 1.3.0 (#1458) 2021-08-29 19:37:01 +00:00
37af5de25c Merge branch 'release/1.2.0' into develop 2021-08-29 21:08:23 +02:00
db6c84775b Merge branch 'release/1.2.0' 2021-08-29 21:08:18 +02:00
72d8b4aa84 Version 1.2.0 2021-08-29 21:08:08 +02:00
170b7c4379 New Crowdin updates (#1459) 2021-08-29 21:06:33 +02:00
79e9e1a780 New Crowdin updates (#1321) 2021-08-29 20:01:36 +02:00
98dcc62bb7 Add excuse function to "not excusable" account (#1429) 2021-08-29 19:47:14 +02:00
ea0fb00bde Fix crash on opening date pickers during holidays (#1456) 2021-08-29 19:31:28 +02:00
4aa6b0b995 Hide keyboard on opening login host dropdown (#1455) 2021-08-29 19:00:30 +02:00
57d11e825b Update readBy and unreadBy fields during message list fetch (#1452) 2021-08-29 15:40:28 +02:00
2f43b6e552 Change display name for MRmlik12 (#1451) 2021-08-29 14:08:48 +02:00
765f8a2d1f Add in app review (#1435) 2021-08-29 00:43:58 +02:00
04c727a0c8 Exams and homework notification fixes (#1292) 2021-08-29 00:41:58 +02:00
55518cb044 Add missing dashboard item in default view settings (#1450) 2021-08-28 21:43:10 +02:00
cebd1aa75d Remove lithuanian lang (#1449) 2021-08-28 12:14:01 +02:00
4a38a0be70 Add change password snackbar (#1336) 2021-08-26 17:35:41 +00:00
b4b9d91ea6 Update dependencies (#1448) 2021-08-25 20:49:44 +02:00
a6a2bcff3b Remove Zachowanie from all count of subjects (#1447) 2021-08-24 19:51:08 +02:00
2979d8b62a Show information when the recipient has read the message (#1430) 2021-08-23 16:16:41 +00:00
aba2068a84 New timetable widget design (#1384) 2021-08-23 16:02:21 +00:00
076948a680 Bump gradle from 7.0.0 to 7.0.1 (#1445) 2021-08-23 13:53:04 +00:00
1cfabe43a5 Add captions for averages from how many items have been counted (#1437) 2021-08-23 15:48:48 +02:00
02b87c8c6a Bump firebase-bom from 28.3.1 to 28.4.0 (#1446) 2021-08-23 13:42:20 +00:00
eb94e06d54 Fix buggy timers in timetable (#1428)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2021-08-22 16:33:12 +02:00
d3b3939d26 Bump timber from 4.7.1 to 5.0.1 (#1440) 2021-08-17 13:44:06 +00:00
9c5d2fbf84 Bump google-services from 4.3.9 to 4.3.10 (#1439) 2021-08-17 13:32:48 +00:00
428e40d7fe Bump hianalytics from 6.1.0.300 to 6.1.1.300 (#1441) 2021-08-17 13:32:34 +00:00
9c819835ca Add last sync date in sync settings (#1436) 2021-08-15 13:59:32 +00:00
626169de11 Add drag and drop to dashboard tiles (#1415) 2021-08-10 11:55:51 +02:00
72ef5f428e Bump firebase-bom from 28.3.0 to 28.3.1 (#1431) 2021-08-09 13:55:03 +00:00
4ae3f7b016 Bump google-services from 4.3.8 to 4.3.9 (#1432) 2021-08-09 13:54:48 +00:00
7c94837af0 Bump coil from 1.3.1 to 1.3.2 (#1433) 2021-08-09 13:54:31 +00:00
2a91346155 Bump activity-ktx from 1.3.0 to 1.3.1 (#1434) 2021-08-09 13:53:54 +00:00
ec6d18968f Fix filter search bug (#1427)
* Fix filter search bug

* refractor
2021-08-07 10:27:51 +02:00
b61e63249c Add messages sorting (#1262) 2021-08-04 15:16:54 +02:00
d73aa605f9 Change dashboard no data strings (#1426) 2021-08-03 18:55:20 +02:00
14f4808434 Add student nick-or-name to notification summary (#1425) 2021-08-03 15:48:11 +02:00
2bc6d7ad0d Bump gradle from 4.2.2 to 7.0.0 (#1419) 2021-08-02 16:28:12 +00:00
888052cd9c Bump agcp from 1.5.3.200 to 1.6.0.300 (#1424) 2021-08-02 15:18:29 +00:00
bdc2281fdc Bump agconnect-crash from 1.5.3.200 to 1.6.0.300 (#1423) 2021-08-02 15:18:18 +00:00
d01edc2312 Bump activity-ktx from 1.2.4 to 1.3.0 (#1422) 2021-08-02 15:17:05 +00:00
484a3aa731 Bump chucker from 3.5.1 to 3.5.2 (#1417) 2021-08-02 13:26:33 +00:00
51be23470f Bump hilt_version from 2.38 to 2.38.1 (#1418) 2021-08-02 13:25:19 +00:00
19495ffce9 Bump constraintlayout from 2.1.0-beta02 to 2.1.0 (#1420) 2021-08-02 13:24:31 +00:00
bd766d33db Bump coil from 1.3.0 to 1.3.1 (#1421) 2021-08-02 13:23:25 +00:00
ff8b3f8837 Send mutltiple notifications instead of summary notification (#1365) 2021-08-01 13:19:46 +02:00
e678e6d7f9 Fix margin and attedance destination (#1414) 2021-07-31 20:19:05 +02:00
f6f3447f1d Fix sorting notes in loading state (#1413) 2021-07-31 18:08:35 +02:00
e1c1f305c4 Add draft message (#1306) 2021-07-31 18:00:22 +02:00
c8c9001277 Add twitter page link to about fragment (#1411) 2021-07-30 19:13:06 +02:00
3422951e47 Add dashboard (#1267) 2021-07-30 18:49:19 +02:00
3278c11cce Bump hilt_version from 2.37 to 2.38 (#1405) 2021-07-27 08:39:37 +00:00
e00dea51f1 Bump appcompat from 1.3.0 to 1.3.1 (#1409) 2021-07-26 19:55:08 +00:00
5bf411039d Bump fragment-ktx from 1.3.5 to 1.3.6 (#1404) 2021-07-26 19:54:50 +00:00
62ca394c9a Bump appcompat-resources from 1.3.0 to 1.3.1 (#1403) 2021-07-26 19:48:14 +00:00
255b89bbb3 Bump about_libraries from 8.9.0 to 8.9.1 (#1406) 2021-07-26 19:42:25 +00:00
f7987f4b29 Bump chucker from 3.5.0 to 3.5.1 (#1407) 2021-07-26 19:42:11 +00:00
0b583439dd Bump firebase-bom from 28.2.1 to 28.3.0 (#1408) 2021-07-26 19:41:55 +00:00
ca481dc6f5 Bump activity-ktx from 1.2.3 to 1.2.4 (#1410) 2021-07-26 19:41:28 +00:00
f6a92a4cc3 Bump hianalytics from 6.0.0.301 to 6.1.0.300 (#1402) 2021-07-21 07:21:49 +00:00
55a6219a42 Bump kotlin_version from 1.5.20 to 1.5.21 (#1401) 2021-07-21 07:21:25 +00:00
ad653f10df Bump firebase-bom from 28.2.0 to 28.2.1 (#1400) 2021-07-12 22:44:06 +02:00
7a780486f6 Bump kotlinx-coroutines-android from 1.5.0 to 1.5.1-native-mt (#1395) 2021-07-12 19:54:35 +00:00
c01b0eff9d Bump agconnect-crash from 1.5.2.300 to 1.5.3.200 (#1399) 2021-07-12 19:53:03 +00:00
3a4614e2b7 Bump robolectric from 4.5.1 to 4.6.1 (#1392) 2021-07-12 19:52:39 +00:00
44ee8859b1 Bump junit from 1.1.2 to 1.1.3 (#1389) 2021-07-12 19:52:25 +00:00
3dd7878ae5 Bump mockk from 1.11.0 to 1.12.0 (#1387) 2021-07-12 19:47:16 +00:00
0305a005ab Bump agcp from 1.5.2.300 to 1.5.3.200 (#1398) 2021-07-12 19:47:04 +00:00
2229f0e3e9 Bump coil from 1.2.2 to 1.3.0 (#1397) 2021-07-12 19:46:13 +00:00
d9aab7afa2 Bump runner from 1.3.0 to 1.4.0 (#1386) 2021-07-12 19:45:36 +00:00
0558f30646 Bump material from 1.3.0 to 1.4.0 (#1390) 2021-07-12 19:44:04 +00:00
238f257c6c Bump hianalytics from 5.3.1.300 to 6.0.0.301 (#1394) 2021-07-12 19:43:46 +00:00
40372e7cea Bump core-ktx from 1.5.0 to 1.6.0 (#1388) 2021-07-12 19:40:32 +00:00
b65a060fca Bump chucker from 3.4.0 to 3.5.0 (#1385) 2021-07-12 19:40:15 +00:00
c1ed748188 Bump gradle from 4.2.1 to 4.2.2 (#1393) 2021-07-12 19:39:19 +00:00
b911521ccc Bump core from 1.3.0 to 1.4.0 (#1391) 2021-07-12 19:39:02 +00:00
b046679542 Bump kotlin_version from 1.5.10 to 1.5.20 (#1381) 2021-06-27 20:09:46 +00:00
3decc95a20 Bump firebase-crashlytics-gradle from 2.7.0 to 2.7.1 (#1382) 2021-06-27 19:37:24 +00:00
c301198006 Bump firebase-bom from 28.1.0 to 28.2.0 (#1383) 2021-06-27 19:33:51 +00:00
190a5f2067 Bump fragment-ktx from 1.3.4 to 1.3.5 (#1380) 2021-06-22 20:37:21 +00:00
27e1a07eec Add notifications debug screen (#1370) 2021-06-21 10:29:04 +02:00
64feae9f1c Bump hilt_version from 2.36 to 2.37 (#1376) 2021-06-12 12:31:59 +00:00
085158721e Bump sonarqube-gradle-plugin from 3.2.0 to 3.3 (#1378) 2021-06-11 11:45:25 +00:00
44888b048d Add "I forgot my password" button in upper bar (#1375) 2021-06-11 09:53:11 +02:00
b9a12e46bf Upgrade gradle to 6.9 (#1371) 2021-06-09 09:46:16 +02:00
2fe5e62e72 Bump recyclerview from 1.2.0 to 1.2.1 (#1366) 2021-06-08 10:02:09 +00:00
6305e1a908 Bump firebase-bom from 28.0.1 to 28.1.0 (#1367) 2021-06-08 10:01:12 +00:00
6bf7a2e26c Bump firebase-crashlytics-gradle from 2.6.1 to 2.7.0 (#1368) 2021-06-08 10:00:27 +00:00
34487175d8 Bump coil from 1.2.1 to 1.2.2 (#1369) 2021-06-08 10:00:10 +00:00
f02db914bf Fix treessence upgrade (#1361) 2021-06-02 12:45:16 +02:00
18e0a59e2b Bump hilt_version from 2.35.1 to 2.36 (#1362) 2021-06-02 09:12:01 +00:00
e4371af284 Bump about_libraries from 8.8.5 to 8.9.0 (#1363) 2021-06-02 08:21:34 +00:00
44d5f69de1 Remove jcenter repository and unused code from gradle config (#1360) 2021-05-28 10:57:25 +02:00
d13e0adb00 Bump appcompat from 1.2.0 to 1.3.0 (#1357) 2021-05-28 07:09:47 +00:00
e60e573ac0 Bump appcompat-resources from 1.2.0 to 1.3.0 (#1359) 2021-05-28 07:01:57 +00:00
91dbc9e3d7 Bump core-ktx from 1.3.2 to 1.5.0 (#1356) 2021-05-28 06:15:18 +00:00
8ccbea2c21 Bump fragment-ktx from 1.3.3 to 1.3.4 (#1358) 2021-05-25 11:10:52 +00:00
211cb5e4f2 Merge branch 'hotfix/messages-send' into develop 2021-05-21 14:09:45 +02:00
b60c59216d Merge branch 'hotfix/messages-send' 2021-05-21 14:08:00 +02:00
d20f3180cf Version 1.1.6 2021-05-21 14:03:13 +02:00
17761af9d6 Bump sdk 2021-05-21 12:35:57 +02:00
067817bace Bump huawei-publish-gradle-plugin from 1.2.2 to 1.2.4 (#1314)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
(cherry picked from commit 022a4d1ea2)
2021-05-21 12:30:36 +02:00
51800d91b2 Bump gradle from 4.1.3 to 4.2.1 (#1339) 2021-05-19 22:40:21 +00:00
3640c4f249 Update dependabot config (#1353) 2021-05-18 09:40:08 +00:00
05aa38b591 Add arrows to student family list items (#1338) 2021-05-17 15:35:36 +02:00
983dcd8656 Add conferences and announcements notifications (#1330) 2021-05-17 15:19:39 +02:00
59cf4fb222 Bump kotlinx-coroutines-android from 1.5.0-RC to 1.5.0 (#1348) 2021-05-17 11:33:27 +00:00
d6ebcc97e3 Bump firebase-crashlytics-gradle from 2.5.2 to 2.6.1 (#1342) 2021-05-17 11:32:03 +00:00
047579c394 Bump agcp from 1.5.2.201 to 1.5.2.300 (#1349) 2021-05-17 11:24:31 +00:00
a90fd4b776 Bump agconnect-crash from 1.5.2.201 to 1.5.2.300 (#1350) 2021-05-17 11:21:48 +00:00
03d3a5db11 Bump firebase-bom from 27.1.0 to 28.0.1 (#1341) 2021-05-17 11:21:31 +00:00
bf5e61490d Bump google-services from 4.3.5 to 4.3.8 (#1344) 2021-05-17 11:18:08 +00:00
d87fa589a8 Bump hianalytics from 5.3.0.300 to 5.3.1.300 (#1332) 2021-05-10 11:50:20 +00:00
1fff1c2b14 Bump kotlin_version from 1.4.32 to 1.5.0 (#1310) 2021-05-06 11:02:08 +00:00
58d66b6e70 Bump work_hilt from 1.0.0-beta01 to 1.0.0 (#1329) 2021-05-05 22:23:31 +00:00
202d13d509 Bump activity-ktx from 1.2.2 to 1.2.3 (#1328) 2021-05-05 22:21:48 +00:00
db808de06c Fix no info text position in school announcements (#1327) 2021-05-05 20:18:16 +02:00
d8dae09f39 Add notification icons (#1276)
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2021-05-03 18:24:54 +02:00
32640e0796 Change mobile devices item order (#1324)
* Change more items order

* Resolve conflicts
2021-05-03 18:23:09 +02:00
4e80441167 Add school announcements (#1323) 2021-05-03 17:24:01 +02:00
075cfb20b1 Fix missing snackbar in sync settings fragment (#1325) 2021-05-03 16:42:59 +02:00
56e4e9be5e Fix homework dialog attachments margin (#1322) 2021-05-02 21:56:41 +02:00
53c798ebdb Change titles in Student Info (#1121) 2021-05-02 14:09:42 +00:00
022a4d1ea2 Bump huawei-publish-gradle-plugin from 1.2.2 to 1.2.4 (#1314)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mikołaj Pich <m.pich@outlook.com>
2021-05-02 13:49:28 +02:00
dfa25d8445 New Crowdin updates (#1268) 2021-05-02 12:53:53 +02:00
b2efe0d981 Probably fix list divider color (#1270)
Co-authored-by: Rafał Borcz <RafalBO99@outlook.com>
2021-05-02 12:33:27 +02:00
2a7f846d3f Bump hilt_version from 2.35 to 2.35.1 (#1313) 2021-04-30 14:05:08 +00:00
da5817d08a Bump sonarqube-gradle-plugin from 3.1.1 to 3.2.0 (#1315) 2021-04-30 13:59:46 +00:00
cacf2f651a Bump agcp from 1.5.1.300 to 1.5.2.201 (#1311) 2021-04-30 13:57:51 +00:00
605c816a32 Bump coil from 1.2.0 to 1.2.1 (#1312) 2021-04-30 13:57:35 +00:00
1587be2fa8 Bump hianalytics from 5.2.0.301 to 5.3.0.300 (#1319) 2021-04-30 13:53:54 +00:00
00b23ca20c Bump agconnect-crash from 1.5.1.300 to 1.5.2.201 (#1316) 2021-04-30 13:46:30 +00:00
34db20ab0c Upgrade to GitHub-native Dependabot (#1309) 2021-04-30 13:23:57 +00:00
0d271d925a Bump room from 2.3.0-rc01 to 2.3.0 (#1302) 2021-04-25 01:31:48 +02:00
b7da43a52a Bump hilt_version from 2.34.1-beta to 2.35 (#1303) 2021-04-24 12:57:55 +00:00
44af5d59fb Bump fragment-ktx from 1.3.2 to 1.3.3 (#1304) 2021-04-24 12:57:41 +00:00
bc776993a9 Bump firebase-bom from 27.0.0 to 27.1.0 (#1305) 2021-04-24 12:57:21 +00:00
9a19ce9ca4 Fix Homework dialog buttons layout (#1297) 2021-04-19 16:09:14 +00:00
6855296de4 Merge branch 'hotfix/all-year-average' into develop 2021-04-18 20:43:29 +02:00
800a31f160 Merge branch 'hotfix/all-year-average' 2021-04-18 20:40:02 +02:00
8b83b37b09 Version 1.1.5 2021-04-18 20:38:18 +02:00
43e95cfdc6 Fix all year average 2021-04-18 19:36:02 +02:00
ae2a697e01 Merge pull request #1295 from wulkanowy/rbo/update-workflow
Update github action workflow
2021-04-18 19:34:32 +02:00
b695c7f600 Bump hilt_version from 2.34-beta to 2.34.1-beta (#1293) 2021-04-17 20:45:38 +00:00
3a1a383383 Bump recyclerview from 1.1.0 to 1.2.0 (#1287) 2021-04-14 18:59:12 +00:00
97810d02ab Bump moshi from 1.11.0 to 1.12.0 (#1284) 2021-04-14 18:58:54 +00:00
30b337a364 Bump about_libraries from 8.8.4 to 8.8.5 (#1281) 2021-04-13 11:55:39 +00:00
8f6c847562 Bump agconnect-crash from 1.5.1.200 to 1.5.1.300 (#1283) 2021-04-13 11:44:01 +00:00
e5d54c95f3 Bump firebase-bom from 26.8.0 to 27.0.0 (#1285) 2021-04-13 11:43:09 +00:00
eb5ad81ec1 Bump agcp from 1.5.1.200 to 1.5.1.300 (#1286) 2021-04-13 11:42:48 +00:00
3aa9f0ca2f Bump coil from 1.1.1 to 1.2.0 (#1282) 2021-04-13 11:42:21 +00:00
8e587358aa Bump hilt_version from 2.33-beta to 2.34-beta (#1280) 2021-04-13 11:39:14 +00:00
4492f4a864 Dialogs adjustments to meet MD rules (#1227) 2021-04-12 20:06:28 +00:00
b453225941 Student info and Teachers screens unification (#1279) 2021-04-12 19:58:58 +00:00
13ccfda009 Migrate material date picker (#1277) 2021-04-12 21:43:52 +02:00
95ffb0a687 Ignore all throwable from WebView (#1275) 2021-04-08 10:41:49 +02:00
f131edf857 Add system settings shortcut (#1271) 2021-04-07 11:56:33 +00:00
bd2d26418a Cleanup github workflows (#1272) 2021-04-07 13:25:48 +02:00
aeb3b2a030 Display day header from website in timetable (#1269) 2021-04-05 15:07:29 +02:00
7bc5219d81 Add new notifications (#1243) 2021-04-04 14:15:07 +00:00
6cb4ea4b0f Drop support for android 4.x (#1232) 2021-04-03 09:56:07 +00:00
0bdd33ef4a Migrate to material components bottom navigation (#1244) 2021-04-03 11:46:36 +02:00
792de4cd3d Merge branch 'hotfix/fix-recovery-visibility' into develop 2021-04-01 22:40:33 +02:00
3071e19584 Implement a toggleable setting to count an arithmetic average of grades when all weights are equal to zero (#1186) 2021-03-30 13:59:36 +02:00
f2130998ec Bump firebase-crashlytics-gradle from 2.5.1 to 2.5.2 (#1264) 2021-03-30 10:49:40 +00:00
8a5ca8c91f Bump firebase-bom from 26.7.0 to 26.8.0 (#1263) 2021-03-30 10:48:12 +00:00
fada13e2d3 Update issue templates (#1257) 2021-03-29 18:39:08 +02:00
6e19eb943d Add deploy to AppGallery github actions config (#1259) 2021-03-29 17:37:26 +02:00
c70fe3430c Merge branch 'release/1.1.3' into develop 2021-03-28 20:13:43 +02:00
699 changed files with 62054 additions and 8807 deletions

12
.editorconfig Normal file
View File

@ -0,0 +1,12 @@
[*]
charset=utf-8
end_of_line=lf
insert_final_newline=true
indent_style=space
indent_size=4
[*.json]
indent_size=2
[*.{kt,kts}]
disabled_rules=import-ordering,no-wildcard-imports

View File

@ -1,3 +1,12 @@
---
name: Bug report
about: Utwórz raport błędu, aby pomóc nam ulepszyć Wulkanowego
title: ''
labels: ''
assignees: ''
---
## Co powinno się dziać

View File

@ -0,0 +1,20 @@
---
name: Feature request
about: Zaproponuj nowy pomysł dla Wulkanowego
title: ''
labels: ''
assignees: ''
---
** Czy Twoja prośba o funkcję jest związana z problemem? Proszę opisz.**
Jasny i zwięzły opis problemu. Np. Zawsze jestem sfrustrowany, gdy [...]
** Opisz żądane rozwiązanie **
Jasny i zwięzły opis tego, co chcesz, aby się wydarzyło.
** Opisz alternatywy, które rozważałeś **
Jasny i zwięzły opis wszelkich rozważanych alternatywnych rozwiązań lub funkcji.
** Dodatkowy kontekst **
Dodaj inny kontekst lub zrzuty ekranu dotyczące żądania funkcji tutaj.

12
.github/dependabot.yml vendored Normal file
View File

@ -0,0 +1,12 @@
version: 2
updates:
- package-ecosystem: gradle
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 10
target-branch: develop
ignore:
- dependency-name: io.github.wulkanowy:sdk
reviewers:
- Faierbel

79
.github/workflows/deploy-store.yml vendored Normal file
View File

@ -0,0 +1,79 @@
name: Deploy release
on:
release:
types: [ created ]
jobs:
deploy-google-play:
name: Google Play
runs-on: ubuntu-latest
timeout-minutes: 10
environment: google-play
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Decrypt keys
env:
ENCRYPT_KEY: ${{ secrets.ENCRYPT_KEY }}
SERVICES_ENCRYPT_KEY: ${{ secrets.SERVICES_ENCRYPT_KEY }}
run: |
gpg --yes --batch --passphrase=$SERVICES_ENCRYPT_KEY ./app/src/release/google-services.json.gpg
gpg --yes --batch --passphrase=$ENCRYPT_KEY ./app/upload-key.jks.gpg
- name: Upload apk to google play
env:
PLAY_STORE_PASSWORD: ${{ secrets.PLAY_STORE_PASSWORD }}
PLAY_KEY_ALIAS: ${{ secrets.PLAY_KEY_ALIAS }}
PLAY_KEY_PASSWORD: ${{ secrets.PLAY_KEY_PASSWORD }}
ANDROID_PUBLISHER_CREDENTIALS: ${{ secrets.ANDROID_PUBLISHER_CREDENTIALS }}
ADMOB_PROJECT_ID: ${{ secrets.ADMOB_PROJECT_ID }}
SINGLE_SUPPORT_AD_ID: ${{ secrets.SINGLE_SUPPORT_AD_ID }}
DASHBOARD_TILE_AD_ID: ${{ secrets.DASHBOARD_TILE_AD_ID }}
SET_BUILD_TIMESTAMP: ${{ secrets.SET_BUILD_TIMESTAMP }}
run: ./gradlew publishPlayReleaseApps -PenableFirebase --stacktrace;
deploy-app-gallery:
name: AppGallery
runs-on: ubuntu-latest
timeout-minutes: 10
environment: app-gallery
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Decrypt keys
env:
ENCRYPT_KEY: ${{ secrets.ENCRYPT_KEY }}
SERVICES_ENCRYPT_KEY: ${{ secrets.SERVICES_ENCRYPT_KEY }}
run: |
gpg --yes --batch --passphrase=$SERVICES_ENCRYPT_KEY ./app/src/release/agconnect-services.json.gpg
gpg --yes --batch --passphrase=$ENCRYPT_KEY ./app/upload-key.jks.gpg
- name: Prepare credentials
env:
AGC_CREDENTIALS: ${{ secrets.AGC_CREDENTIALS }}
run: echo $AGC_CREDENTIALS > ./app/src/release/agconnect-credentials.json
- name: Build and publish HMS version
env:
PLAY_STORE_PASSWORD: ${{ secrets.PLAY_STORE_PASSWORD }}
PLAY_KEY_ALIAS: ${{ secrets.PLAY_KEY_ALIAS }}
PLAY_KEY_PASSWORD: ${{ secrets.PLAY_KEY_PASSWORD }}
SET_BUILD_TIMESTAMP: ${{ secrets.SET_BUILD_TIMESTAMP }}
run: ./gradlew bundleHmsRelease --stacktrace && ./gradlew publishHuaweiAppGalleryHmsRelease --stacktrace

146
.github/workflows/deploy-test.yml vendored Normal file
View File

@ -0,0 +1,146 @@
name: Deploy DEV
on:
push:
# branches: [ develop ]
branches: [ '!*' ]
pull_request_target:
# branches: [ develop ]
branches: [ '!*' ]
workflow_dispatch:
jobs:
deploy-appcenter:
name: App Center
runs-on: ubuntu-latest
timeout-minutes: 10
environment: app-center
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Set run number with offset
env:
BUILD_NUMBER_OFFSET: ${{ secrets.BUILD_NUMBER_OFFSET }}
run: echo "RUN_NUMBER=$((GITHUB_RUN_NUMBER+BUILD_NUMBER_OFFSET))" >> $GITHUB_ENV
- name: Prepare build configuration
run: |
sed -i -e "s#applicationIdSuffix \".dev\"#applicationIdSuffix \".${GITHUB_HEAD_REF//[-.\/]/_}\"#" app/build.gradle
sed -i -e "s#.dev\"#.${GITHUB_HEAD_REF//[-.\/]/_}\"#" app/src/debug/google-services.json
sed -i -e "s#.dev\"#.${GITHUB_HEAD_REF//[-.\/]/_}\"#" app/src/debug/agconnect-services.json
sed -i -e '/versionNameSuffix/d' app/build.gradle
- name: Add signing config
run: |
cat >> app/build.gradle <<EOF
android.signingConfigs.debug {
storeFile file("bitrise.jks")
storePassword System.getenv("BITRISE_KEYSTORE_PASSWORD")
keyAlias System.getenv("BITRISE_KEY_ALIAS")
keyPassword System.getenv("BITRISE_KEY_PASSWORD")
}
EOF
- name: Decrypt keys
env:
BITRISE_ENCRYPT_KEY: ${{ secrets.BITRISE_ENCRYPT_KEY }}
run: |
gpg --yes --batch --passphrase=$BITRISE_ENCRYPT_KEY ./app/bitrise.jks.gpg
- name: Bump version
uses: chkfung/android-version-actions@v1.1
with:
gradlePath: app/build.gradle
versionCode: ${{ env.RUN_NUMBER }}
versionName: ${{ env.RUN_NUMBER }}-${{ github.head_ref }}
- name: Build apk
env:
BITRISE_KEYSTORE_PASSWORD: ${{ secrets.BITRISE_KEYSTORE_PASSWORD }}
BITRISE_KEY_ALIAS: ${{ secrets.BITRISE_KEY_ALIAS }}
BITRISE_KEY_PASSWORD: ${{ secrets.BITRISE_KEY_PASSWORD }}
run: ./gradlew assembleFdroidDebug --stacktrace
- name: Upload apk to github artifacts
uses: actions/upload-artifact@v3
with:
name: wulkanowyDEV-${{ env.RUN_NUMBER }}.apk
path: app/build/outputs/apk/fdroid/debug/app-fdroid-debug.apk
- name: Deploy to app center
uses: wzieba/AppCenter-Github-Action@v1
with:
appName: wulkanowy/wulkanowy
token: ${{ secrets.APP_CENTER_TOKEN }}
group: Testers
file: app/build/outputs/apk/fdroid/debug/app-fdroid-debug.apk
notifyTesters: true
debug: true
deploy-app-distribution:
name: App Distribution
runs-on: ubuntu-latest
timeout-minutes: 10
environment: app-distribution
if: github.event_name != 'pull_request_target'
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Set run number with offset
env:
BUILD_NUMBER_OFFSET: ${{ secrets.BUILD_NUMBER_OFFSET }}
run: echo "RUN_NUMBER=$((GITHUB_RUN_NUMBER+BUILD_NUMBER_OFFSET))" >> $GITHUB_ENV
- name: Add signing config
run: |
cat >> app/build.gradle <<EOF
android.signingConfigs.debug {
storeFile file("bitrise.jks")
storePassword System.getenv("BITRISE_KEYSTORE_PASSWORD")
keyAlias System.getenv("BITRISE_KEY_ALIAS")
keyPassword System.getenv("BITRISE_KEY_PASSWORD")
}
EOF
- name: Decrypt keys
env:
BITRISE_ENCRYPT_KEY: ${{ secrets.BITRISE_ENCRYPT_KEY }}
BITRISE_SERVICES_ENCRYPT_KEY: ${{ secrets.BITRISE_SERVICES_ENCRYPT_KEY }}
run: |
gpg --yes --batch --passphrase=$BITRISE_SERVICES_ENCRYPT_KEY ./app/src/debug/google-services.json.gpg
gpg --yes --batch --passphrase=$BITRISE_ENCRYPT_KEY ./app/bitrise.jks.gpg
- name: Bump version
uses: chkfung/android-version-actions@v1.1
with:
gradlePath: app/build.gradle
versionCode: ${{ env.RUN_NUMBER }}
versionName: ${{ env.RUN_NUMBER }}
- name: Build apk
env:
BITRISE_KEYSTORE_PASSWORD: ${{ secrets.BITRISE_KEYSTORE_PASSWORD }}
BITRISE_KEY_ALIAS: ${{ secrets.BITRISE_KEY_ALIAS }}
BITRISE_KEY_PASSWORD: ${{ secrets.BITRISE_KEY_PASSWORD }}
run: ./gradlew assemblePlayDebug -PenableFirebase --stacktrace
- name: Upload apk to github artifacts
uses: actions/upload-artifact@v3
with:
name: wulkanowyDEV-${{ env.RUN_NUMBER }}-dev.apk
path: app/build/outputs/apk/play/debug/app-play-debug.apk
- name: Deploy to app distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1
with:
appId: ${{ secrets.FIREBASE_APP_ID }}
token: ${{ secrets.FIREBASE_TOKEN }}
groups: discord
file: app/build/outputs/apk/play/debug/app-play-debug.apk

View File

@ -1,27 +1,27 @@
name: Test and deploy
name: Tests
on:
push:
branches: [ develop ]
branches: [ master, develop ]
tags: [ '*' ]
pull_request:
branches: [ develop ]
workflow_dispatch:
branches: [ master, develop ]
jobs:
unit-tests:
name: Unit tests
tests-fdroid:
name: F-Droid
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: fkirc/skip-duplicate-actions@master
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: gradle/wrapper-validation-action@v1
- uses: actions/setup-java@v1
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
@ -29,174 +29,60 @@ jobs:
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Unit tests
run: |
./gradlew --build-cache -Pcoverage testFdroidDebugUnitTest --stacktrace
./gradlew --build-cache -Pcoverage jacocoTestReport --stacktrace
- uses: codecov/codecov-action@v1
./gradlew testFdroidDebugUnitTest --stacktrace
./gradlew jacocoTestReport --stacktrace
- uses: codecov/codecov-action@v3
with:
flags: unit
deploy-google-play:
name: Deploy to google play
tests-play:
name: Play
runs-on: ubuntu-latest
timeout-minutes: 10
environment: google-play
needs: [ unit-tests ]
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
- uses: fkirc/skip-duplicate-actions@master
- uses: actions/checkout@v3
- uses: gradle/wrapper-validation-action@v1
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Decrypt keys
env:
ENCRYPT_KEY: ${{ secrets.ENCRYPT_KEY }}
SERVICES_ENCRYPT_KEY: ${{ secrets.SERVICES_ENCRYPT_KEY }}
- name: Unit tests
run: |
gpg --yes --batch --passphrase=$SERVICES_ENCRYPT_KEY ./app/src/release/google-services.json.gpg
gpg --yes --batch --passphrase=$ENCRYPT_KEY ./app/key.p12.gpg
gpg --yes --batch --passphrase=$ENCRYPT_KEY ./app/upload-key.jks.gpg
- name: Upload apk to google play
env:
PLAY_KEY_ALIAS: ${{ secrets.PLAY_KEY_ALIAS }}
PLAY_KEY_PASSWORD: ${{ secrets.PLAY_KEY_PASSWORD }}
PLAY_SERVICE_ACCOUNT_EMAIL: ${{ secrets.PLAY_SERVICE_ACCOUNT_EMAIL }}
PLAY_STORE_PASSWORD: ${{ secrets.PLAY_STORE_PASSWORD }}
run: ./gradlew publishPlayRelease -PenableFirebase --stacktrace;
./gradlew testPlayDebugUnitTest --stacktrace
./gradlew jacocoTestReport --stacktrace
- uses: codecov/codecov-action@v3
with:
flags: unit
deploy-appcenter:
name: Deploy to App Center
tests-hms:
name: HMS
runs-on: ubuntu-latest
timeout-minutes: 10
environment: app-center
if: github.ref != 'refs/heads/develop'
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
- uses: fkirc/skip-duplicate-actions@master
- uses: actions/checkout@v3
- uses: gradle/wrapper-validation-action@v1
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Set run number with offset
env:
BUILD_NUMBER_OFFSET: ${{ secrets.BUILD_NUMBER_OFFSET }}
run: echo "RUN_NUMBER=$((GITHUB_RUN_NUMBER+BUILD_NUMBER_OFFSET))" >> $GITHUB_ENV
- name: Prepare build configuration
- name: Unit tests
run: |
sed -i -e "s#applicationIdSuffix \".dev\"#applicationIdSuffix \".${GITHUB_HEAD_REF//[-.\/]/_}\"#" app/build.gradle
sed -i -e "s#.dev\"#.${GITHUB_HEAD_REF//[-.\/]/_}\"#" app/src/debug/google-services.json
sed -i -e "s#.dev\"#.${GITHUB_HEAD_REF//[-.\/]/_}\"#" app/src/debug/agconnect-services.json
sed -i -e '/versionNameSuffix/d' app/build.gradle
- name: Add signing config
run: |
cat >> app/build.gradle <<EOF
android.signingConfigs.debug {
storeFile file("bitrise.jks")
storePassword System.getenv("BITRISE_KEYSTORE_PASSWORD")
keyAlias System.getenv("BITRISE_KEY_ALIAS")
keyPassword System.getenv("BITRISE_KEY_PASSWORD")
}
EOF
- name: Decrypt keys
env:
BITRISE_ENCRYPT_KEY: ${{ secrets.BITRISE_ENCRYPT_KEY }}
run: |
gpg --yes --batch --passphrase=$BITRISE_ENCRYPT_KEY ./app/bitrise.jks.gpg
- name: Bump version
uses: chkfung/android-version-actions@v1.1
./gradlew testHmsDebugUnitTest --stacktrace
./gradlew jacocoTestReport --stacktrace
- uses: codecov/codecov-action@v3
with:
gradlePath: app/build.gradle
versionCode: ${{ env.RUN_NUMBER }}
versionName: ${{ env.RUN_NUMBER }}-${{ github.head_ref }}
- name: Build apk
env:
BITRISE_KEYSTORE_PASSWORD: ${{ secrets.BITRISE_KEYSTORE_PASSWORD }}
BITRISE_KEY_ALIAS: ${{ secrets.BITRISE_KEY_ALIAS }}
BITRISE_KEY_PASSWORD: ${{ secrets.BITRISE_KEY_PASSWORD }}
run: ./gradlew assembleFdroidDebug --stacktrace
- name: Upload apk to github artifacts
uses: actions/upload-artifact@v2
with:
name: wulkanowyDEV-${{ env.RUN_NUMBER }}.apk
path: app/build/outputs/apk/fdroid/debug/app-fdroid-debug.apk
- name: Deploy to app center
uses: wzieba/AppCenter-Github-Action@v1
with:
appName: wulkanowy/wulkanowy
token: ${{ secrets.APP_CENTER_TOKEN }}
group: Testers
file: app/build/outputs/apk/fdroid/debug/app-fdroid-debug.apk
notifyTesters: true
debug: true
deploy-app-distribution:
name: Deploy to AppDistribution
runs-on: ubuntu-latest
timeout-minutes: 10
environment: app-distribution
if: github.ref == 'refs/heads/develop'
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: 11
- uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*') }}
- name: Set run number with offset
env:
BUILD_NUMBER_OFFSET: ${{ secrets.BUILD_NUMBER_OFFSET }}
run: echo "RUN_NUMBER=$((GITHUB_RUN_NUMBER+BUILD_NUMBER_OFFSET))" >> $GITHUB_ENV
- name: Add signing config
run: |
cat >> app/build.gradle <<EOF
android.signingConfigs.debug {
storeFile file("bitrise.jks")
storePassword System.getenv("BITRISE_KEYSTORE_PASSWORD")
keyAlias System.getenv("BITRISE_KEY_ALIAS")
keyPassword System.getenv("BITRISE_KEY_PASSWORD")
}
EOF
- name: Decrypt keys
env:
BITRISE_ENCRYPT_KEY: ${{ secrets.BITRISE_ENCRYPT_KEY }}
BITRISE_SERVICES_ENCRYPT_KEY: ${{ secrets.BITRISE_SERVICES_ENCRYPT_KEY }}
run: |
gpg --yes --batch --passphrase=$BITRISE_SERVICES_ENCRYPT_KEY ./app/src/debug/google-services.json.gpg
gpg --yes --batch --passphrase=$BITRISE_ENCRYPT_KEY ./app/bitrise.jks.gpg
- name: Bump version
uses: chkfung/android-version-actions@v1.1
with:
gradlePath: app/build.gradle
versionCode: ${{ env.RUN_NUMBER }}
versionName: ${{ env.RUN_NUMBER }}
- name: Build apk
env:
BITRISE_KEYSTORE_PASSWORD: ${{ secrets.BITRISE_KEYSTORE_PASSWORD }}
BITRISE_KEY_ALIAS: ${{ secrets.BITRISE_KEY_ALIAS }}
BITRISE_KEY_PASSWORD: ${{ secrets.BITRISE_KEY_PASSWORD }}
run: ./gradlew assemblePlayDebug -PenableFirebase --stacktrace
- name: Upload apk to github artifacts
uses: actions/upload-artifact@v2
with:
name: wulkanowyDEV-${{ env.RUN_NUMBER }}-dev.apk
path: app/build/outputs/apk/play/debug/app-play-debug.apk
- name: Deploy to app distribution
uses: wzieba/Firebase-Distribution-Github-Action@v1
with:
appId: ${{ secrets.FIREBASE_APP_ID }}
token: ${{ secrets.FIREBASE_TOKEN }}
groups: discord
file: app/build/outputs/apk/play/debug/app-play-debug.apk
flags: unit

2
.gitignore vendored
View File

@ -117,3 +117,5 @@ Thumbs.db
app/src/release/agconnect-services.json
app/src/release/agconnect-credentials.json
.idea/deploymentTargetDropDown.xml

View File

@ -2,23 +2,6 @@
<code_scheme name="Project" version="173">
<option name="LINE_SEPARATOR" value="&#10;" />
<JetCodeStyleSettings>
<option name="PACKAGES_TO_USE_STAR_IMPORTS">
<value>
<package name="kotlinx.android.synthetic" alias="false" withSubpackages="true" />
</value>
</option>
<option name="PACKAGES_IMPORT_LAYOUT">
<value>
<package name="" alias="false" withSubpackages="true" />
<package name="java" alias="false" withSubpackages="true" />
<package name="javax" alias="false" withSubpackages="true" />
<package name="kotlin" alias="false" withSubpackages="true" />
<package name="" alias="true" withSubpackages="true" />
</value>
</option>
<option name="NAME_COUNT_TO_USE_STAR_IMPORT" value="2147483647" />
<option name="NAME_COUNT_TO_USE_STAR_IMPORT_FOR_MEMBERS" value="2147483647" />
<option name="WRAP_ELVIS_EXPRESSIONS" value="0" />
<option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
</JetCodeStyleSettings>
<codeStyleSettings language="XML">
@ -135,13 +118,6 @@
</codeStyleSettings>
<codeStyleSettings language="kotlin">
<option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
<option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1" />
<option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
<option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="0" />
<option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
<indentOptions>
<option name="CONTINUATION_INDENT_SIZE" value="4" />
</indentOptions>
</codeStyleSettings>
</code_scheme>
</component>

View File

@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2019 Wulkanowy
Copyright 2022 Wulkanowy
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.

78
README.cs.md Normal file
View File

@ -0,0 +1,78 @@
[English version of README](README.en.md)
[Deutsche Version von README](README.de.md)
[Polska wersja README](README.md)
[Slovenská verzia README](README.sk.md)
# Wulkanowy
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Tests/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![Codecov](https://img.shields.io/codecov/c/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://codecov.io/gh/wulkanowy/wulkanowy)
[![Discord](https://img.shields.io/discord/390889354199040011.svg?style=flat-square)](https://discord.gg/vccAQBr)
[![F-Droid](https://img.shields.io/f-droid/v/io.github.wulkanowy.svg?style=flat-square)](https://f-droid.org/packages/io.github.wulkanowy/)
[![Last release](https://img.shields.io/github/release/wulkanowy/wulkanowy.svg?logo=github&style=flat-square)](https://github.com/wulkanowy/wulkanowy/releases)
Neoficiální klient deníku VULCAN UONET+ pro žáka a rodiče
## Funkce
* přihlášení pomocí emailu a hesla
* funkce z webové stránky deníku:
* známky
* statistiky známek
* frekvence
* procento frekvence
* zkoušky
* plán lekce
* dokončené lekce
* zprávy
* domácí úkoly
* poznámky
* šťastné číslo
* další lekce
* školní setkání
* informace o žáku a škole
* výpočet průměru nezávisle na preferencích školy
* upozornění, např. o nových známkách
* podpora více účtů s možností přejmenování žáků
* tmavý a černý (AMOLED) motiv
* offline režim
* žádné reklamy
## Stáhnout
Aktuální verzi si můžete stáhnout z Google Play, F-Droid nebo Huawei AppGallery
[<img src="https://play.google.com/intl/cs-CZ/badges/images/generic/cs_badge_web_generic.png"
alt="Nyní na Google Play"
height="80">](https://play.google.com/store/apps/details?id=io.github.wulkanowy)
[<img src="https://fdroid.gitlab.io/artwork/badge/get-it-on.png"
alt="Stáhnout s F-Droid"
height="80">](https://f-droid.org/packages/io.github.wulkanowy/)
[<img src="https://i.imgur.com/baTGiDP.png"
alt="Objevuj v AppGallery"
height="80">](https://appgallery.cloud.huawei.com/ag/n/app/C101440411?channelId=Badge&id=1b3f7fbb700849a9be0dba6b520b2282&s=EB1D3BF9ED9D1564D869B7B94B18016D3CABFCA5AEFB8E29F675FA04E0DC131D&detailType=0&v=)
Můžete si také stáhnout [vývojovou verzi](https://wulkanowy.github.io/#download), která zahrnuje nové funkce připravované pro příští vydání
## Postaveno s
* [Wulkanowy SDK](https://github.com/wulkanowy/sdk)
* [Kotlin Coroutines](https://kotlinlang.org/docs/reference/coroutines-overview.html)
* [Hilt](https://dagger.dev/hilt/)
* [Room](https://developer.android.com/topic/libraries/architecture/room)
* [WorkManager](https://developer.android.com/topic/libraries/architecture/workmanager)
## Spolupráce
Přispějte do projektu vytvořením PR nebo odesláním issue na GitHub.
Pro zájemce o překlad aplikace do různých jazyků poskytujeme Crowdin:
https://crowdin.com/project/wulkanowy2
## Licence
Tento projekt je licencován pod licencí Apache License 2.0 - podrobnosti v souboru [LICENSE](LICENSE)

74
README.de.md Normal file
View File

@ -0,0 +1,74 @@
[Polska wersja README](README.md)
[English version of README](README.en.md)
# Wulkanowy
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Tests/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![Codecov](https://img.shields.io/codecov/c/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://codecov.io/gh/wulkanowy/wulkanowy)
[![Discord](https://img.shields.io/discord/390889354199040011.svg?style=flat-square)](https://discord.gg/vccAQBr)
[![F-Droid](https://img.shields.io/f-droid/v/io.github.wulkanowy.svg?style=flat-square)](https://f-droid.org/packages/io.github.wulkanowy/)
[![Last release](https://img.shields.io/github/release/wulkanowy/wulkanowy.svg?logo=github&style=flat-square)](https://github.com/wulkanowy/wulkanowy/releases)
Inoffizieller Android VULCAN UONET+ Registrierungsclient für Schüler und ihre Eltern
## Merkmale
* Einloggen mit E-Mail und Passwort
* Funktionen von der Registerwebsite:
* Noten
* Notenstatistik
* Anwesenheit
* Prozentsatz der Anwesenheit
* Prüfungen
* Stundenplan
* Unterricht abgeschlossen
* Nachrichten
* Hausaufgaben
* Anmerkungen
* Glückszahl
* Zusätzliche Lektionen
* Schulkonferenzen
* Schüler- und Schulinformationen
* Berechnung des Durchschnitts unabhängig von den Präferenzen der Schule
* Benachrichtigungen, z. B. über eine neue Note
* Unterstützung für mehrere Konten mit der Möglichkeit, den Namen des Schülers zu ändern
* dunkles und schwarzes (AMOLED) Thema
* Offline-Modus
* keine Werbung
## Herunterladen
Die aktuelle Version können Sie von der Google Play, F-Droid oder Huawei AppGallery store herunterladen
[<img src="https://play.google.com/intl/en_us/badges/images/generic/en_badge_web_generic.png"
alt="Get it on Google Play"
height="80">](https://play.google.com/store/apps/details?id=io.github.wulkanowy)
[<img src="https://fdroid.gitlab.io/artwork/badge/get-it-on.png"
alt="Get it on F-Droid"
height="80">](https://f-droid.org/packages/io.github.wulkanowy/)
[<img src="appgallery_badge.png"
alt="Explore it on AppGallery"
height="80">](https://appgallery.cloud.huawei.com/ag/n/app/C101440411?channelId=Badge&id=1b3f7fbb700849a9be0dba6b520b2282&s=EB1D3BF9ED9D1564D869B7B94B18016D3CABFCA5AEFB8E29F675FA04E0DC131D&detailType=0&v=)
Sie können auch eine [Entwicklungsversion herunterladen](https://wulkanowy.github.io/#download) die beinhaltet neue Funktionen, die für die nächste Version vorbereitet werden
## Gebaut mit
* [Wulkanowy SDK](https://github.com/wulkanowy/sdk)
* [Kotlin Coroutines](https://kotlinlang.org/docs/reference/coroutines-overview.html)
* [Hilt](https://dagger.dev/hilt/)
* [Room](https://developer.android.com/topic/libraries/architecture/room)
* [WorkManager](https://developer.android.com/topic/libraries/architecture/workmanager)
## Beitragen
Bitte tragen Sie zum Projekt bei, indem Sie entweder eine PR erstellen oder ein Issue auf GitHub einreichen.
Für Personen, die daran interessiert sind, die Anwendung in verschiedene Sprachen zu übersetzen, bieten wir Crowdin
https://crowdin.com/project/wulkanowy2
## Lizenz
Dieses Projekt ist unter der Apache License 2.0 lizenziert - siehe die [LIZENZ](LICENSE) Datei für Details

View File

@ -1,8 +1,14 @@
[Polska wersja README](README.md)
[Deutsche Version von README](README.de.md)
[Česká verze README](README.cs.md)
[Slovenská verzia README](README.sk.md)
# Wulkanowy
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Test%20and%20deploy/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Tests/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![Codecov](https://img.shields.io/codecov/c/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://codecov.io/gh/wulkanowy/wulkanowy)
[![Discord](https://img.shields.io/discord/390889354199040011.svg?style=flat-square)](https://discord.gg/vccAQBr)
[![F-Droid](https://img.shields.io/f-droid/v/io.github.wulkanowy.svg?style=flat-square)](https://f-droid.org/packages/io.github.wulkanowy/)

View File

@ -1,8 +1,14 @@
[English version of README](README.en.md)
[Deutsche Version von README](README.de.md)
[Česká verze README](README.cs.md)
[Slovenská verzia README](README.sk.md)
# Wulkanowy
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Test%20and%20deploy/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Tests/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![Codecov](https://img.shields.io/codecov/c/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://codecov.io/gh/wulkanowy/wulkanowy)
[![Discord](https://img.shields.io/discord/390889354199040011.svg?style=flat-square)](https://discord.gg/vccAQBr)
[![F-Droid](https://img.shields.io/f-droid/v/io.github.wulkanowy.svg?style=flat-square)](https://f-droid.org/packages/io.github.wulkanowy/)

78
README.sk.md Normal file
View File

@ -0,0 +1,78 @@
[English version of README](README.en.md)
[Deutsche Version von README](README.de.md)
[Polska wersja README](README.md)
[Česká verze README](README.cs.md)
# Wulkanowy
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/wulkanowy/wulkanowy/Tests/develop?style=flat-square)](https://github.com/wulkanowy/wulkanowy/actions)
[![Codecov](https://img.shields.io/codecov/c/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://codecov.io/gh/wulkanowy/wulkanowy)
[![Discord](https://img.shields.io/discord/390889354199040011.svg?style=flat-square)](https://discord.gg/vccAQBr)
[![F-Droid](https://img.shields.io/f-droid/v/io.github.wulkanowy.svg?style=flat-square)](https://f-droid.org/packages/io.github.wulkanowy/)
[![Last release](https://img.shields.io/github/release/wulkanowy/wulkanowy.svg?logo=github&style=flat-square)](https://github.com/wulkanowy/wulkanowy/releases)
Neoficiálny klient denníka VULCAN UONET+ pre žiaka a rodičov
## Funkcie
* prihlásenie pomocou emailu a hesla
* funkcie z webovej stránky denníka:
* známky
* štatistiky známok
* frekvencia
* percento frekvencie
* skúšky
* plán lekcie
* dokončené lekcie
* správy
* domáce úlohy
* poznámky
* šťastné číslo
* ďalšie lekcie
* školské stretnutie
* informácie o žiakovi a škole
* výpočet priemeru nezávisle od preferencií školy
* upozornenia, napr. o nových známkach
* podpora viacerých účtov s možnosťou premenovania žiakov
* tmavý a čierny (AMOLED) motív
* offline režim
* žiadne reklamy
## Stiahnuť
Aktuálnu verziu si môžete stiahnuť z Google Play, F-Droid alebo Huawei AppGallery
[<img src="https://play.google.com/intl/sk/badges/images/generic/sk_badge_web_generic.png"
alt="Nyní na Google Play"
height="80">](https://play.google.com/store/apps/details?id=io.github.wulkanowy)
[<img src="https://fdroid.gitlab.io/artwork/badge/get-it-on.png"
alt="Stiahnuť s F-Droid"
height="80">](https://f-droid.org/packages/io.github.wulkanowy/)
[<img src="https://i.imgur.com/sX8UyAw.png"
alt="Objavíte v AppGallery"
height="80">](https://appgallery.cloud.huawei.com/ag/n/app/C101440411?channelId=Badge&id=1b3f7fbb700849a9be0dba6b520b2282&s=EB1D3BF9ED9D1564D869B7B94B18016D3CABFCA5AEFB8E29F675FA04E0DC131D&detailType=0&v=)
Môžete si tiež stiahnuť [vývojovú verziu](https://wulkanowy.github.io/#download), ktorá zahrňuje nové funkcie pripravované pre budúce vydanie
## Postavené s
* [Wulkanowy SDK](https://github.com/wulkanowy/sdk)
* [Kotlin Coroutines](https://kotlinlang.org/docs/reference/coroutines-overview.html)
* [Hilt](https://dagger.dev/hilt/)
* [Room](https://developer.android.com/topic/libraries/architecture/room)
* [WorkManager](https://developer.android.com/topic/libraries/architecture/workmanager)
## Spolupráca
Prispejte do projektu vytvorením PR alebo odoslaním issue na GitHub.
Pre záujemcov o preklad aplikácie do rôznych jazykov poskytujeme Crowdin:
https://crowdin.com/project/wulkanowy2
## Licencia
Tento projekt je licencovaný pod licenciou Apache License 2.0 - podrobnosti v súbore [LICENSE](LICENSE)

Binary file not shown.

View File

@ -1,45 +1,55 @@
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlinx-serialization'
apply plugin: 'kotlin-parcelize'
apply plugin: 'kotlin-kapt'
apply plugin: 'dagger.hilt.android.plugin'
apply plugin: 'com.google.gms.google-services'
apply plugin: 'com.google.firebase.crashlytics'
apply plugin: 'com.github.triplet.play'
apply plugin: 'ru.cian.huawei-publish'
apply plugin: 'com.mikepenz.aboutlibraries.plugin'
apply plugin: 'com.google.gms.google-services'
apply plugin: 'com.huawei.agconnect'
apply from: 'jacoco.gradle'
apply from: 'sonarqube.gradle'
apply from: 'hooks.gradle'
android {
compileSdkVersion 30
buildToolsVersion '30.0.3'
namespace 'io.github.wulkanowy'
compileSdkVersion 32
defaultConfig {
applicationId "io.github.wulkanowy"
testApplicationId "io.github.tests.wulkanowy"
minSdkVersion 17
targetSdkVersion 30
versionCode 90
versionName "1.1.4"
multiDexEnabled true
minSdkVersion 21
targetSdkVersion 32
versionCode 111
versionName "1.7.2"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
resValue "string", "app_name", "Wulkanowy"
buildConfigField "long", "BUILD_TIMESTAMP", String.valueOf(System.currentTimeMillis())
manifestPlaceholders = [
firebase_enabled: project.hasProperty("enableFirebase")
firebase_enabled: project.hasProperty("enableFirebase"),
admob_project_id: ""
]
javaCompileOptions {
annotationProcessorOptions {
arguments += [
"room.schemaLocation": "$projectDir/schemas".toString(),
"room.incremental" : "true"
"room.schemaLocation": "$projectDir/schemas".toString(),
"room.incremental" : "true"
]
}
}
buildConfigField "String", "SINGLE_SUPPORT_AD_ID", "null"
buildConfigField "String", "DASHBOARD_TILE_AD_ID", "null"
if (System.env.SET_BUILD_TIMESTAMP) {
buildConfigField "long", "BUILD_TIMESTAMP", String.valueOf(System.currentTimeMillis())
} else {
buildConfigField "long", "BUILD_TIMESTAMP", "1486235849000"
}
}
sourceSets {
@ -62,13 +72,16 @@ android {
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.release
buildConfigField "String", "MESSAGES_BASE_URL", "\"https://messages.wulkanowy.net.pl\""
}
debug {
resValue "string", "app_name", "Wulkanowy DEV " + defaultConfig.versionCode
minifyEnabled false
shrinkResources false
resValue "string", "app_name", "Wulkanowy DEV"
applicationIdSuffix ".dev"
versionNameSuffix "-dev"
testCoverageEnabled = project.hasProperty('coverage')
ext.enableCrashlytics = project.hasProperty("enableFirebase")
buildConfigField "String", "MESSAGES_BASE_URL", "\"https://messages.wulkanowy.net.pl\""
}
}
@ -77,54 +90,62 @@ android {
productFlavors {
hms {
dimension "platform"
minSdkVersion 19
manifestPlaceholders = [
install_channel: "AppGallery"
]
manifestPlaceholders = [install_channel: "AppGallery"]
}
play {
dimension "platform"
manifestPlaceholders = [
install_channel: "Google Play"
install_channel : "Google Play",
admob_project_id: System.getenv("ADMOB_PROJECT_ID") ?: "ca-app-pub-3940256099942544~3347511713"
]
buildConfigField "String", "SINGLE_SUPPORT_AD_ID", "\"${System.getenv("SINGLE_SUPPORT_AD_ID") ?: "ca-app-pub-3940256099942544/5354046379"}\""
buildConfigField "String", "DASHBOARD_TILE_AD_ID", "\"${System.getenv("DASHBOARD_TILE_AD_ID") ?: "ca-app-pub-3940256099942544/6300978111"}\""
}
fdroid {
dimension "platform"
manifestPlaceholders = [
install_channel: "F-Droid"
]
manifestPlaceholders = [install_channel: "F-Droid"]
}
}
buildFeatures {
viewBinding = true
playConfigs {
play { enabled.set(true) }
}
lintOptions {
disable 'HardwareIds'
buildFeatures {
viewBinding true
}
bundle {
language {
enableSplit = false
}
}
testOptions.unitTests {
includeAndroidResources = true
// workaround HMS test errors https://github.com/robolectric/robolectric/issues/2750
all { jvmArgs '-noverify' }
}
compileOptions {
coreLibraryDesugaringEnabled true
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
kotlinOptions {
useIR = true
jvmTarget = "1.8"
freeCompilerArgs += ["-Xopt-in=kotlin.RequiresOptIn", "-Xjvm-default=all"]
jvmTarget = "11"
freeCompilerArgs += ["-opt-in=kotlin.RequiresOptIn", "-Xjvm-default=all"]
}
packagingOptions {
exclude 'META-INF/library_release.kotlin_module'
exclude 'META-INF/library-core_release.kotlin_module'
resources {
excludes += ['META-INF/library_release.kotlin_module',
'META-INF/library-core_release.kotlin_module']
}
}
aboutLibraries {
@ -132,54 +153,68 @@ android {
}
}
kapt {
correctErrorTypes true
}
play {
serviceAccountEmail = System.getenv("PLAY_SERVICE_ACCOUNT_EMAIL") ?: "jan@fakelog.cf"
serviceAccountCredentials = file('key.p12')
defaultToAppBundles = false
track = 'production'
updatePriority = 3
releaseStatus = com.github.triplet.gradle.androidpublisher.ReleaseStatus.IN_PROGRESS
userFraction = 0.05d
updatePriority = 5
enabled.set(false)
}
huaweiPublish {
instances {
hmsRelease {
credentialsPath = "$rootDir/app/src/release/agconnect-credentials.json"
buildFormat = "aab"
deployType = "draft"
}
}
}
ext {
work_manager = "2.5.0"
work_hilt = "1.0.0-beta01"
room = "2.3.0-rc01"
chucker = "3.4.0"
mockk = "1.11.0"
moshi = "1.11.0"
work_manager = "2.7.1"
android_hilt = "1.0.0"
room = "2.4.3"
chucker = "3.5.2"
mockk = "1.12.7"
coroutines = "1.6.4"
}
dependencies {
implementation "io.github.wulkanowy:sdk:1.1.3"
implementation "io.github.wulkanowy:sdk:1.7.2"
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5'
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.8'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.4.3'
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:1.4.0"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines"
implementation "androidx.core:core-ktx:1.3.2"
implementation "androidx.activity:activity-ktx:1.2.2"
implementation "androidx.appcompat:appcompat:1.2.0"
implementation "androidx.appcompat:appcompat-resources:1.2.0"
implementation "androidx.fragment:fragment-ktx:1.3.2"
implementation "androidx.annotation:annotation:1.2.0"
implementation "androidx.multidex:multidex:2.0.1"
implementation "androidx.core:core-ktx:1.8.0"
implementation 'androidx.core:core-splashscreen:1.0.0'
implementation "androidx.activity:activity-ktx:1.5.1"
implementation "androidx.appcompat:appcompat:1.5.0"
implementation "androidx.fragment:fragment-ktx:1.5.2"
implementation "androidx.annotation:annotation:1.4.0"
implementation "androidx.preference:preference-ktx:1.1.1"
implementation "androidx.recyclerview:recyclerview:1.1.0"
implementation "androidx.viewpager:viewpager:1.0.0"
implementation "androidx.preference:preference-ktx:1.2.0"
implementation "androidx.recyclerview:recyclerview:1.2.1"
implementation "androidx.viewpager2:viewpager2:1.1.0-beta01"
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
implementation "androidx.constraintlayout:constraintlayout:2.0.4"
implementation "androidx.coordinatorlayout:coordinatorlayout:1.1.0"
implementation "com.google.android.material:material:1.3.0"
implementation "com.github.wulkanowy:material-chips-input:2.2.0"
implementation "androidx.constraintlayout:constraintlayout:2.1.4"
implementation "androidx.coordinatorlayout:coordinatorlayout:1.2.0"
implementation "com.google.android.material:material:1.6.1"
implementation "com.github.wulkanowy:material-chips-input:2.3.1"
implementation "com.github.PhilJay:MPAndroidChart:v3.1.0"
implementation 'com.mikhaellopez:circularimageview:4.2.0'
implementation 'com.github.lopspower:CircularImageView:4.2.0'
implementation "androidx.work:work-runtime-ktx:$work_manager"
playImplementation "androidx.work:work-gcm:$work_manager"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:2.3.1"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:2.5.1"
implementation "androidx.room:room-runtime:$room"
implementation "androidx.room:room-ktx:$room"
@ -187,55 +222,58 @@ dependencies {
implementation "com.google.dagger:hilt-android:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"
implementation "androidx.hilt:hilt-work:$work_hilt"
kapt "androidx.hilt:hilt-compiler:$work_hilt"
kapt "androidx.hilt:hilt-compiler:$android_hilt"
implementation "androidx.hilt:hilt-work:$android_hilt"
implementation "com.aurelhubert:ahbottomnavigation:2.3.4"
implementation "com.ncapdevi:frag-nav:3.3.0"
implementation 'com.github.ncapdevi:FragNav:3.3.0'
implementation "com.github.YarikSOffice:lingver:1.3.0"
implementation "com.squareup.moshi:moshi:$moshi"
implementation "com.squareup.moshi:moshi-adapters:$moshi"
kapt "com.squareup.moshi:moshi-kotlin-codegen:$moshi"
implementation "com.jakewharton.timber:timber:4.7.1"
implementation "at.favre.lib:slf4j-timber:1.0.1"
implementation "fr.bipi.treessence:treessence:0.3.2"
implementation "com.mikepenz:aboutlibraries-core:$about_libraries"
implementation 'com.wdullaer:materialdatetimepicker:4.2.3'
implementation "io.coil-kt:coil:1.1.1"
implementation "io.github.wulkanowy:AppKillerManager:3.0.0"
implementation 'me.xdrop:fuzzywuzzy:1.3.1'
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
implementation "com.jakewharton.retrofit:retrofit2-kotlinx-serialization-converter:0.8.0"
implementation "com.squareup.okhttp3:logging-interceptor:4.10.0"
playImplementation platform('com.google.firebase:firebase-bom:26.7.0')
implementation "com.jakewharton.timber:timber:5.0.1"
implementation "at.favre.lib:slf4j-timber:1.0.1"
implementation 'com.github.bastienpaulfr:Treessence:1.0.5'
implementation "com.mikepenz:aboutlibraries-core:$about_libraries"
implementation "io.coil-kt:coil:2.2.0"
implementation "io.github.wulkanowy:AppKillerManager:3.0.0"
implementation 'me.xdrop:fuzzywuzzy:1.4.0'
implementation 'com.fredporciuncula:flow-preferences:1.8.0'
playImplementation platform('com.google.firebase:firebase-bom:30.3.2')
playImplementation 'com.google.firebase:firebase-analytics-ktx'
playImplementation 'com.google.firebase:firebase-messaging:'
playImplementation 'com.google.firebase:firebase-crashlytics:'
playImplementation 'com.google.android.play:core:1.10.3'
playImplementation 'com.google.android.play:core-ktx:1.8.1'
playImplementation 'com.google.android.gms:play-services-ads:21.1.0'
hmsImplementation 'com.huawei.hms:hianalytics:5.2.0.301'
hmsImplementation 'com.huawei.agconnect:agconnect-crash:1.5.1.200'
hmsImplementation 'com.huawei.hms:hianalytics:6.7.0.300'
hmsImplementation 'com.huawei.agconnect:agconnect-crash:1.7.1.300'
releaseImplementation "com.github.ChuckerTeam.Chucker:library-no-op:$chucker"
debugImplementation "com.github.ChuckerTeam.Chucker:library:$chucker"
debugImplementation "com.amitshekhar.android:debug-db:1.0.6"
debugImplementation 'com.github.amitshekhariitbhu.Android-Debug-Database:debug-db:1.0.6'
debugImplementation 'com.github.haroldadmin:WhatTheStack:1.0.0-alpha04'
testImplementation "junit:junit:4.13.2"
testImplementation "io.mockk:mockk:$mockk"
testImplementation 'org.jetbrains.kotlinx:kotlinx-coroutines-test:1.4.2'
testImplementation "org.jetbrains.kotlinx:kotlinx-coroutines-test:$coroutines"
testImplementation "org.jetbrains.kotlin:kotlin-test:$kotlin_version"
testImplementation 'org.robolectric:robolectric:4.5.1'
testImplementation "androidx.test:runner:1.3.0"
testImplementation "androidx.test.ext:junit:1.1.2"
testImplementation "androidx.test:core:1.3.0"
testImplementation 'org.robolectric:robolectric:4.8.2'
testImplementation "androidx.test:runner:1.4.0"
testImplementation "androidx.test.ext:junit:1.1.3"
testImplementation "androidx.test:core:1.4.0"
testImplementation "androidx.room:room-testing:$room"
testImplementation "com.google.dagger:hilt-android-testing:$hilt_version"
kaptTest "com.google.dagger:hilt-android-compiler:$hilt_version"
androidTestImplementation "androidx.test:core:1.3.0"
androidTestImplementation "androidx.test:runner:1.3.0"
androidTestImplementation "androidx.test.ext:junit:1.1.2"
androidTestImplementation "androidx.test:core:1.4.0"
androidTestImplementation "androidx.test:runner:1.4.0"
androidTestImplementation "androidx.test.ext:junit:1.1.3"
androidTestImplementation "io.mockk:mockk-android:$mockk"
androidTestImplementation "org.jetbrains.kotlin:kotlin-test:$kotlin_version"
}

View File

@ -1,8 +1,8 @@
apply plugin: "jacoco"
jacoco {
toolVersion "0.8.5"
reportsDir = file("$buildDir/reports")
toolVersion "0.8.7"
reportsDirectory.set(file("$buildDir/reports"))
}
tasks.withType(Test) {
@ -16,8 +16,8 @@ task jacocoTestReport(type: JacocoReport) {
description = "Generate Jacoco coverage reports"
reports {
xml.enabled = true
html.enabled = true
xml.required.set(true)
html.required.set(true)
}
def excludes = ['**/R.class',

Binary file not shown.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,33 +1,92 @@
{
"agcgw":{
"backurl":"connect-dre.dbankcloud.cn",
"url":"connect-dre.hispace.hicloud.com"
},
"client":{
"cp_id":"890048000024105546",
"product_id":"",
"client_id":"",
"client_secret":"",
"app_id":"101440411",
"package_name":"io.github.wulkanowy.dev",
"api_key":""
},
"service":{
"analytics":{
"collector_url":"datacollector-dre.dt.hicloud.com,datacollector-dre.dt.dbankcloud.cn",
"resource_id":"p1",
"channel_id":""
},
"agcgw": {
"backurl": "connect-dre.hispace.hicloud.com",
"url": "connect-dre.dbankcloud.cn",
"websocketbackurl": "connect-ws-dre.hispace.dbankcloud.com",
"websocketurl": "connect-ws-dre.hispace.dbankcloud.cn"
},
"agcgw_all": {
"CN": "connect-drcn.dbankcloud.cn",
"CN_back": "connect-drcn.hispace.hicloud.com",
"DE": "connect-dre.dbankcloud.cn",
"DE_back": "connect-dre.hispace.hicloud.com",
"RU": "connect-drru.hispace.dbankcloud.ru",
"RU_back": "connect-drru.hispace.dbankcloud.cn",
"SG": "connect-dra.dbankcloud.cn",
"SG_back": "connect-dra.hispace.hicloud.com"
},
"websocketgw_all": {
"CN": "connect-ws-drcn.hispace.dbankcloud.cn",
"CN_back": "connect-ws-drcn.hispace.dbankcloud.com",
"DE": "connect-ws-dre.hispace.dbankcloud.cn",
"DE_back": "connect-ws-dre.hispace.dbankcloud.com",
"RU": "connect-ws-drru.hispace.dbankcloud.ru",
"RU_back": "connect-ws-drru.hispace.dbankcloud.cn",
"SG": "connect-ws-dra.hispace.dbankcloud.cn",
"SG_back": "connect-ws-dra.hispace.dbankcloud.com"
},
"client": {
"cp_id": "890048000024105546",
"product_id": "736430079244736562",
"client_id": "514530959291319360",
"client_secret": "C42522DBF17D3D4BBE9D9C1783A54484B7E6844B388B7A67502D36A633A4186B",
"project_id": "736430079244736562",
"app_id": "106552551",
"api_key": "CgB6e3x9BUNiq+r8ebCHNojjjYsMT4pJSjjNDOkm9owtBb6rVI6LjnASoZBRxbjjhObcrV5gANo99fI/eKZDTbWS",
"package_name": "io.github.wulkanowy.dev"
},
"oauth_client": {
"client_id": "106552551",
"client_type": 1
},
"app_info": {
"app_id": "106552551",
"package_name": "io.github.wulkanowy.dev"
},
"service": {
"analytics": {
"collector_url": "datacollector-dre.dt.hicloud.com,datacollector-dre.dt.dbankcloud.cn",
"collector_url_ru": "datacollector-drru.dt.dbankcloud.ru,datacollector-drru.dt.hicloud.com",
"collector_url_sg": "datacollector-dra.dt.hicloud.com,datacollector-dra.dt.dbankcloud.cn",
"collector_url_de": "datacollector-dre.dt.hicloud.com,datacollector-dre.dt.dbankcloud.cn",
"collector_url_cn": "datacollector-drcn.dt.hicloud.com,datacollector-drcn.dt.dbankcloud.cn",
"resource_id": "p1",
"channel_id": ""
},
"search":{
"url":"https://search-dre.cloud.huawei.com"
},
"cloudstorage":{
"storage_url":"https://ops-dre.agcstorage.link"
},
"ml":{
"mlservice_url":"ml-api-dre.ai.dbankcloud.com,ml-api-dre.ai.dbankcloud.cn"
}
},
"region":"DE",
"configuration_version":"1.0"
"cloudstorage": {
"storage_url_sg_back": "https://agc-storage-dra.cloud.huawei.asia",
"storage_url_ru_back": "https://agc-storage-drru.cloud.huawei.ru",
"storage_url_ru": "https://agc-storage-drru.cloud.huawei.ru",
"storage_url_de_back": "https://agc-storage-dre.cloud.huawei.eu",
"storage_url_de": "https://ops-dre.agcstorage.link",
"storage_url": "https://agc-storage-drcn.platform.dbankcloud.cn",
"storage_url_sg": "https://ops-dra.agcstorage.link",
"storage_url_cn_back": "https://agc-storage-drcn.cloud.huawei.com.cn",
"storage_url_cn": "https://agc-storage-drcn.platform.dbankcloud.cn"
},
"ml": {
"mlservice_url": "ml-api-dre.ai.dbankcloud.com,ml-api-dre.ai.dbankcloud.cn"
}
},
"region": "DE",
"configuration_version": "3.0",
"appInfos": [
{
"package_name": "io.github.wulkanowy.dev",
"client": {
"app_id": "106552551"
},
"app_info": {
"package_name": "io.github.wulkanowy.dev",
"app_id": "106552551"
},
"oauth_client": {
"client_type": 1,
"client_id": "106552551"
}
}
]
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 478 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 652 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 384 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 460 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 426 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 355 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 451 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 297 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 339 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 335 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 588 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 897 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 508 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 586 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 519 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 781 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 692 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 805 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 700 B

View File

@ -0,0 +1,28 @@
package io.github.wulkanowy.utils
import android.content.Context
import android.view.View
import dagger.hilt.android.qualifiers.ApplicationContext
import io.github.wulkanowy.data.repositories.PreferencesRepository
import io.github.wulkanowy.ui.modules.dashboard.DashboardItem
import javax.inject.Inject
@Suppress("unused")
class AdsHelper @Inject constructor(
@ApplicationContext private val context: Context,
private val preferencesRepository: PreferencesRepository
) {
fun initialize() {
preferencesRepository.isAdsEnabled = false
preferencesRepository.isAgreeToProcessData = false
preferencesRepository.selectedDashboardTiles -= DashboardItem.Tile.ADS
}
@Suppress("RedundantSuspendModifier", "UNUSED_PARAMETER")
suspend fun getDashboardTileAdBanner(width: Int): AdBanner {
throw IllegalStateException("Can't get ad banner (F-droid)")
}
}
data class AdBanner(val view: View)

View File

@ -0,0 +1,18 @@
package io.github.wulkanowy.utils
import android.content.Context
import dagger.hilt.android.qualifiers.ApplicationContext
import io.github.wulkanowy.ui.modules.main.MainActivity
import javax.inject.Singleton
import javax.inject.Inject
@Suppress("UNUSED_PARAMETER", "unused")
@Singleton
class InAppReviewHelper @Inject constructor(
@ApplicationContext private val context: Context
) {
fun showInAppReview(activity: MainActivity) {
// do nothing
}
}

View File

@ -0,0 +1,28 @@
package io.github.wulkanowy.utils
import android.content.Context
import android.view.View
import dagger.hilt.android.qualifiers.ApplicationContext
import io.github.wulkanowy.data.repositories.PreferencesRepository
import io.github.wulkanowy.ui.modules.dashboard.DashboardItem
import javax.inject.Inject
@Suppress("unused")
class AdsHelper @Inject constructor(
@ApplicationContext private val context: Context,
private val preferencesRepository: PreferencesRepository
) {
fun initialize() {
preferencesRepository.isAdsEnabled = false
preferencesRepository.isAgreeToProcessData = false
preferencesRepository.selectedDashboardTiles -= DashboardItem.Tile.ADS
}
@Suppress("RedundantSuspendModifier", "UNUSED_PARAMETER")
suspend fun getDashboardTileAdBanner(width: Int): AdBanner {
throw IllegalStateException("Can't get ad banner (HMS)")
}
}
data class AdBanner(val view: View)

View File

@ -3,11 +3,6 @@ package io.github.wulkanowy.utils
import android.util.Log
import com.huawei.agconnect.crash.AGConnectCrash
import fr.bipi.tressence.base.FormatterPriorityTree
import io.github.wulkanowy.sdk.exception.FeatureNotAvailableException
import io.github.wulkanowy.sdk.scrapper.exception.FeatureDisabledException
import java.io.InterruptedIOException
import java.net.SocketTimeoutException
import java.net.UnknownHostException
class CrashLogTree : FormatterPriorityTree(Log.VERBOSE) {
@ -20,21 +15,10 @@ class CrashLogTree : FormatterPriorityTree(Log.VERBOSE) {
}
}
class CrashLogExceptionTree : FormatterPriorityTree(Log.ERROR) {
class CrashLogExceptionTree : FormatterPriorityTree(Log.ERROR, ExceptionFilter) {
private val connectCrash by lazy { AGConnectCrash.getInstance() }
override fun skipLog(priority: Int, tag: String?, message: String, t: Throwable?): Boolean {
return when (t) {
is FeatureDisabledException,
is FeatureNotAvailableException,
is UnknownHostException,
is SocketTimeoutException,
is InterruptedIOException -> true
else -> super.skipLog(priority, tag, message, t)
}
}
override fun log(priority: Int, tag: String?, message: String, t: Throwable?) {
if (skipLog(priority, tag, message, t)) return

View File

@ -0,0 +1,18 @@
package io.github.wulkanowy.utils
import android.content.Context
import dagger.hilt.android.qualifiers.ApplicationContext
import io.github.wulkanowy.ui.modules.main.MainActivity
import javax.inject.Inject
import javax.inject.Singleton
@Singleton
@Suppress("UNUSED_PARAMETER", "unused")
class InAppReviewHelper @Inject constructor(
@ApplicationContext private val context: Context
) {
fun showInAppReview(activity: MainActivity) {
// do nothing
}
}

View File

@ -1,13 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="io.github.wulkanowy"
android:installLocation="internalOnly">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.SCHEDULE_EXACT_ALARM"/>
<queries>
<intent>
@ -37,13 +38,14 @@
android:allowBackup="false"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:networkSecurityConfig="@xml/network_security_config"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="false"
android:theme="@style/WulkanowyTheme"
android:usesCleartextTraffic="true"
tools:ignore="GoogleAppIndexingWarning,UnusedAttribute">
<activity
android:name=".ui.modules.splash.SplashActivity"
android:exported="true"
android:screenOrientation="portrait"
android:theme="@style/WulkanowyTheme.SplashScreen"
tools:ignore="LockedOrientationActivity">
@ -73,6 +75,7 @@
<activity
android:name=".ui.modules.timetablewidget.TimetableWidgetConfigureActivity"
android:excludeFromRecents="true"
android:exported="true"
android:noHistory="true"
android:theme="@style/WulkanowyTheme.WidgetAccountSwitcher">
<intent-filter>
@ -82,6 +85,7 @@
<activity
android:name=".ui.modules.luckynumberwidget.LuckyNumberWidgetConfigureActivity"
android:excludeFromRecents="true"
android:exported="true"
android:noHistory="true"
android:theme="@style/WulkanowyTheme.WidgetAccountSwitcher">
<intent-filter>
@ -92,6 +96,22 @@
<service
android:name=".services.widgets.TimetableWidgetService"
android:permission="android.permission.BIND_REMOTEVIEWS" />
<service
android:name=".services.piggyback.VulcanNotificationListenerService"
android:exported="true"
android:permission="android.permission.BIND_NOTIFICATION_LISTENER_SERVICE">
<intent-filter>
<action android:name="android.service.notification.NotificationListenerService" />
</intent-filter>
</service>
<service
android:name=".services.messaging.AppMessagingService"
android:exported="false"
tools:ignore="MissingClass">
<intent-filter>
<action android:name="com.google.firebase.MESSAGING_EVENT" />
</intent-filter>
</service>
<receiver
android:name=".ui.modules.timetablewidget.TimetableWidgetProvider"
@ -106,6 +126,7 @@
</receiver>
<receiver
android:name=".ui.modules.luckynumberwidget.LuckyNumberWidgetProvider"
android:exported="true"
android:label="@string/lucky_number_title">
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
@ -118,11 +139,9 @@
<receiver android:name=".services.alarm.TimetableNotificationReceiver" />
<provider
android:name="androidx.work.impl.WorkManagerInitializer"
android:authorities="${applicationId}.workmanager-init"
android:exported="false"
android:name="androidx.startup.InitializationProvider"
android:authorities="${applicationId}.androidx-startup"
tools:node="remove" />
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="${applicationId}.fileprovider"
@ -133,44 +152,44 @@
android:resource="@xml/provider_paths" />
</provider>
<meta-data
android:name="install_channel"
android:value="${install_channel}" />
<!-- workaround for https://github.com/firebase/firebase-android-sdk/issues/473 enabled:false -->
<!-- https://firebase.googleblog.com/2017/03/take-control-of-your-firebase-init-on.html -->
<provider
android:name="com.google.firebase.provider.FirebaseInitProvider"
android:authorities="${applicationId}.firebaseinitprovider"
android:enabled="${firebase_enabled}"
android:exported="false" />
android:exported="false"
tools:ignore="MissingClass" />
<meta-data
android:name="install_channel"
android:value="${install_channel}" />
<meta-data
android:name="firebase_analytics_collection_enabled"
android:value="${firebase_enabled}" />
<meta-data
android:name="google_analytics_adid_collection_enabled"
android:value="${firebase_enabled}" />
<meta-data
android:name="firebase_crashlytics_collection_enabled"
android:value="${firebase_enabled}" />
<meta-data
android:name="firebase_messaging_auto_init_enabled"
android:value="${firebase_enabled}" />
<meta-data
android:name="firebase_inapp_messaging_auto_data_collection_enabled"
android:value="${firebase_enabled}" />
<meta-data
android:name="com.google.firebase.messaging.default_notification_icon"
android:resource="@drawable/ic_stat_push" />
android:resource="@drawable/ic_stat_all" />
<meta-data
android:name="com.google.firebase.messaging.default_notification_channel_id"
android:value="push_channel" />
<meta-data
android:name="com.google.android.gms.ads.APPLICATION_ID"
android:value="${admob_project_id}" />
<meta-data
android:name="com.google.android.gms.ads.DELAY_APP_MEASUREMENT_INIT"
android:value="true" />
</application>
</manifest>

View File

@ -36,7 +36,7 @@
"githubUsername": "Luncenok"
},
{
"displayName": "MRmlik12",
"displayName": "Daniel Olczyk",
"githubUsername": "MRmlik12"
},
{
@ -46,5 +46,9 @@
{
"displayName": "Kamil Studziński",
"githubUsername": "studzinskik"
},
{
"displayName": "Tomasz F.",
"githubUsername": "Pengwius"
}
]

View File

@ -1,27 +1,15 @@
package io.github.wulkanowy
import android.annotation.SuppressLint
import android.app.Application
import android.content.Context
import android.util.Log.DEBUG
import android.util.Log.INFO
import android.util.Log.VERBOSE
import android.webkit.WebView
import androidx.fragment.app.FragmentManager
import android.util.Log.*
import androidx.hilt.work.HiltWorkerFactory
import androidx.multidex.MultiDex
import androidx.work.Configuration
import com.yariksoffice.lingver.Lingver
import dagger.hilt.android.HiltAndroidApp
import fr.bipi.tressence.file.FileLoggerTree
import io.github.wulkanowy.data.repositories.PreferencesRepository
import io.github.wulkanowy.ui.base.ThemeManager
import io.github.wulkanowy.utils.ActivityLifecycleLogger
import io.github.wulkanowy.utils.AnalyticsHelper
import io.github.wulkanowy.utils.AppInfo
import io.github.wulkanowy.utils.CrashLogExceptionTree
import io.github.wulkanowy.utils.CrashLogTree
import io.github.wulkanowy.utils.DebugLogTree
import io.github.wulkanowy.utils.*
import timber.log.Timber
import javax.inject.Inject
@ -43,19 +31,15 @@ class WulkanowyApp : Application(), Configuration.Provider {
@Inject
lateinit var analyticsHelper: AnalyticsHelper
override fun attachBaseContext(base: Context?) {
super.attachBaseContext(base)
MultiDex.install(this)
}
@Inject
lateinit var adsHelper: AdsHelper
@SuppressLint("UnsafeOptInUsageWarning")
override fun onCreate() {
super.onCreate()
FragmentManager.enableNewStateManager(false)
initializeAppLanguage()
themeManager.applyDefaultTheme()
adsHelper.initialize()
initLogging()
fixWebViewLocale()
}
private fun initLogging() {
@ -87,15 +71,6 @@ class WulkanowyApp : Application(), Configuration.Provider {
}
}
private fun fixWebViewLocale() {
//https://stackoverflow.com/questions/40398528/android-webview-language-changes-abruptly-on-android-7-0-and-above
try {
WebView(this).destroy()
} catch (e: Exception) {
//Ignore exceptions
}
}
override fun getWorkManagerConfiguration() = Configuration.Builder()
.setWorkerFactory(workerFactory)
.setMinimumLoggingLevel(if (appInfo.isDebug) VERBOSE else INFO)

View File

@ -2,59 +2,99 @@ package io.github.wulkanowy.data
import android.content.Context
import android.content.SharedPreferences
import android.content.res.AssetManager
import android.content.res.Resources
import androidx.preference.PreferenceManager
import com.chuckerteam.chucker.api.ChuckerCollector
import com.chuckerteam.chucker.api.ChuckerInterceptor
import com.chuckerteam.chucker.api.RetentionManager
import com.fredporciuncula.flow.preferences.FlowSharedPreferences
import com.jakewharton.retrofit2.converter.kotlinx.serialization.asConverterFactory
import dagger.Module
import dagger.Provides
import dagger.hilt.InstallIn
import dagger.hilt.android.qualifiers.ApplicationContext
import dagger.hilt.components.SingletonComponent
import io.github.wulkanowy.data.api.AdminMessageService
import io.github.wulkanowy.data.db.AppDatabase
import io.github.wulkanowy.data.db.SharedPrefProvider
import io.github.wulkanowy.data.repositories.PreferencesRepository
import io.github.wulkanowy.sdk.Sdk
import io.github.wulkanowy.utils.AppInfo
import kotlinx.serialization.ExperimentalSerializationApi
import kotlinx.serialization.json.Json
import okhttp3.MediaType.Companion.toMediaType
import okhttp3.OkHttpClient
import okhttp3.logging.HttpLoggingInterceptor
import retrofit2.Retrofit
import retrofit2.create
import timber.log.Timber
import java.util.concurrent.TimeUnit
import javax.inject.Singleton
@Module
@InstallIn(SingletonComponent::class)
internal class RepositoryModule {
internal class DataModule {
@Singleton
@Provides
fun provideSdk(chuckerCollector: ChuckerCollector, @ApplicationContext context: Context): Sdk {
return Sdk().apply {
fun provideSdk(chuckerInterceptor: ChuckerInterceptor) =
Sdk().apply {
androidVersion = android.os.Build.VERSION.RELEASE
buildTag = android.os.Build.MODEL
setSimpleHttpLogger { Timber.d(it) }
// for debug only
addInterceptor(
ChuckerInterceptor.Builder(context)
.collector(chuckerCollector)
.alwaysReadResponseBody(true)
.build(), network = true
)
addInterceptor(chuckerInterceptor, network = true)
}
}
@Singleton
@Provides
fun provideChuckerCollector(
@ApplicationContext context: Context,
prefRepository: PreferencesRepository
): ChuckerCollector {
return ChuckerCollector(
context = context,
showNotification = prefRepository.isDebugNotificationEnable,
retentionPeriod = RetentionManager.Period.ONE_HOUR
)
}
) = ChuckerCollector(
context = context,
showNotification = prefRepository.isDebugNotificationEnable,
retentionPeriod = RetentionManager.Period.ONE_HOUR
)
@Singleton
@Provides
fun provideChuckerInterceptor(
@ApplicationContext context: Context,
chuckerCollector: ChuckerCollector
) = ChuckerInterceptor.Builder(context)
.collector(chuckerCollector)
.alwaysReadResponseBody(true)
.build()
@Singleton
@Provides
fun provideOkHttpClient(chuckerInterceptor: ChuckerInterceptor): OkHttpClient =
OkHttpClient.Builder()
.addNetworkInterceptor(chuckerInterceptor)
.addInterceptor(HttpLoggingInterceptor().apply {
level = HttpLoggingInterceptor.Level.BASIC
})
.connectTimeout(30, TimeUnit.SECONDS)
.readTimeout(30, TimeUnit.SECONDS)
.build()
@OptIn(ExperimentalSerializationApi::class)
@Singleton
@Provides
fun provideRetrofit(
okHttpClient: OkHttpClient,
json: Json,
appInfo: AppInfo
): Retrofit = Retrofit.Builder()
.baseUrl(appInfo.messagesBaseUrl)
.client(okHttpClient)
.addConverterFactory(json.asConverterFactory("application/json".toMediaType()))
.build()
@Singleton
@Provides
fun provideAdminMessageService(retrofit: Retrofit): AdminMessageService = retrofit.create()
@Singleton
@Provides
@ -64,19 +104,22 @@ internal class RepositoryModule {
appInfo: AppInfo
) = AppDatabase.newInstance(context, sharedPrefProvider, appInfo)
@Singleton
@Provides
fun provideResources(@ApplicationContext context: Context): Resources = context.resources
@Singleton
@Provides
fun provideAssets(@ApplicationContext context: Context): AssetManager = context.assets
@Singleton
@Provides
fun provideSharedPref(@ApplicationContext context: Context): SharedPreferences =
PreferenceManager.getDefaultSharedPreferences(context)
@Singleton
@Provides
fun provideFlowSharedPref(sharedPreferences: SharedPreferences) =
FlowSharedPreferences(sharedPreferences)
@Singleton
@Provides
fun provideJson() = Json {
ignoreUnknownKeys = true
}
@Singleton
@Provides
fun provideStudentDao(database: AppDatabase) = database.studentDao
@ -152,7 +195,7 @@ internal class RepositoryModule {
@Singleton
@Provides
fun provideReportingUnitDao(database: AppDatabase) = database.reportingUnitDao
fun provideMailboxesDao(database: AppDatabase) = database.mailboxDao
@Singleton
@Provides
@ -181,4 +224,20 @@ internal class RepositoryModule {
@Singleton
@Provides
fun provideStudentInfoDao(database: AppDatabase) = database.studentInfoDao
@Singleton
@Provides
fun provideTimetableHeaderDao(database: AppDatabase) = database.timetableHeaderDao
@Singleton
@Provides
fun provideSchoolAnnouncementDao(database: AppDatabase) = database.schoolAnnouncementDao
@Singleton
@Provides
fun provideNotificationDao(database: AppDatabase) = database.notificationDao
@Singleton
@Provides
fun provideAdminMessageDao(database: AppDatabase) = database.adminMessagesDao
}

View File

@ -1,23 +1,173 @@
package io.github.wulkanowy.data
data class Resource<T>(val status: Status, val data: T?, val error: Throwable?) {
companion object {
fun <T> success(data: T?): Resource<T> {
return Resource(Status.SUCCESS, data, null)
}
import kotlinx.coroutines.flow.*
import kotlinx.coroutines.sync.Mutex
import kotlinx.coroutines.sync.withLock
import timber.log.Timber
fun <T> error(error: Throwable?, data: T? = null): Resource<T> {
return Resource(Status.ERROR, data, error)
}
sealed class Resource<T> {
fun <T> loading(data: T? = null): Resource<T> {
return Resource(Status.LOADING, data, null)
}
open class Loading<T> : Resource<T>()
data class Intermediate<T>(val data: T) : Loading<T>()
data class Success<T>(val data: T) : Resource<T>()
data class Error<T>(val error: Throwable) : Resource<T>()
}
val <T> Resource<T>.dataOrNull: T?
get() = when (this) {
is Resource.Success -> this.data
is Resource.Intermediate -> this.data
is Resource.Loading -> null
is Resource.Error -> null
}
val <T> Resource<T>.errorOrNull: Throwable?
get() = when (this) {
is Resource.Error -> this.error
else -> null
}
fun <T> resourceFlow(block: suspend () -> T) = flow {
emit(Resource.Loading())
emit(Resource.Success(block()))
}.catch { emit(Resource.Error(it)) }
fun <T> flatResourceFlow(block: suspend () -> Flow<Resource<T>>) = flow {
emit(Resource.Loading())
emitAll(block().filter { it is Resource.Intermediate || it !is Resource.Loading })
}.catch { emit(Resource.Error(it)) }
fun <T, U> Resource<T>.mapData(block: (T) -> U) = when (this) {
is Resource.Success -> Resource.Success(block(this.data))
is Resource.Intermediate -> Resource.Intermediate(block(this.data))
is Resource.Loading -> Resource.Loading()
is Resource.Error -> Resource.Error(this.error)
}
fun <T> Flow<Resource<T>>.logResourceStatus(name: String, showData: Boolean = false) = onEach {
val description = when (it) {
is Resource.Loading -> "started"
is Resource.Intermediate -> "intermediate data received" + if (showData) " (data: `${it.data}`)" else ""
is Resource.Success -> "success" + if (showData) " (data: `${it.data}`)" else ""
is Resource.Error -> "exception occurred: ${it.error}"
}
Timber.i("$name: $description")
}
fun <T, U> Flow<Resource<T>>.mapResourceData(block: (T) -> U) = map {
it.mapData(block)
}
fun <T> Flow<Resource<T>>.onResourceData(block: suspend (T) -> Unit) = onEach {
when (it) {
is Resource.Success -> block(it.data)
is Resource.Intermediate -> block(it.data)
is Resource.Error,
is Resource.Loading -> Unit
}
}
enum class Status {
LOADING,
SUCCESS,
ERROR
fun <T> Flow<Resource<T>>.onResourceLoading(block: suspend () -> Unit) = onEach {
if (it is Resource.Loading) {
block()
}
}
fun <T> Flow<Resource<T>>.onResourceIntermediate(block: suspend (T) -> Unit) = onEach {
if (it is Resource.Intermediate) {
block(it.data)
}
}
fun <T> Flow<Resource<T>>.onResourceSuccess(block: suspend (T) -> Unit) = onEach {
if (it is Resource.Success) {
block(it.data)
}
}
fun <T> Flow<Resource<T>>.onResourceError(block: (Throwable) -> Unit) = onEach {
if (it is Resource.Error) {
block(it.error)
}
}
fun <T> Flow<Resource<T>>.onResourceNotLoading(block: () -> Unit) = onEach {
if (it !is Resource.Loading) {
block()
}
}
suspend fun <T> Flow<Resource<T>>.toFirstResult() = filter { it !is Resource.Loading }.first()
suspend fun <T> Flow<Resource<T>>.waitForResult() = takeWhile { it is Resource.Loading }.collect()
inline fun <ResultType, RequestType> networkBoundResource(
mutex: Mutex = Mutex(),
showSavedOnLoading: Boolean = true,
crossinline isResultEmpty: (ResultType) -> Boolean,
crossinline query: () -> Flow<ResultType>,
crossinline fetch: suspend (ResultType) -> RequestType,
crossinline saveFetchResult: suspend (old: ResultType, new: RequestType) -> Unit,
crossinline onFetchFailed: (Throwable) -> Unit = { },
crossinline shouldFetch: (ResultType) -> Boolean = { true },
crossinline filterResult: (ResultType) -> ResultType = { it }
) = flow {
emit(Resource.Loading())
val data = query().first()
emitAll(if (shouldFetch(data)) {
val filteredResult = filterResult(data)
if (showSavedOnLoading && !isResultEmpty(filteredResult)) {
emit(Resource.Intermediate(filteredResult))
}
try {
val newData = fetch(data)
mutex.withLock { saveFetchResult(query().first(), newData) }
query().map { Resource.Success(filterResult(it)) }
} catch (throwable: Throwable) {
onFetchFailed(throwable)
query().map { Resource.Error(throwable) }
}
} else {
query().map { Resource.Success(filterResult(it)) }
})
}
@JvmName("networkBoundResourceWithMap")
inline fun <ResultType, RequestType, T> networkBoundResource(
mutex: Mutex = Mutex(),
showSavedOnLoading: Boolean = true,
crossinline isResultEmpty: (T) -> Boolean,
crossinline query: () -> Flow<ResultType>,
crossinline fetch: suspend (ResultType) -> RequestType,
crossinline saveFetchResult: suspend (old: ResultType, new: RequestType) -> Unit,
crossinline onFetchFailed: (Throwable) -> Unit = { },
crossinline shouldFetch: (ResultType) -> Boolean = { true },
crossinline mapResult: (ResultType) -> T
) = flow {
emit(Resource.Loading())
val data = query().first()
emitAll(if (shouldFetch(data)) {
val mappedResult = mapResult(data)
if (showSavedOnLoading && !isResultEmpty(mappedResult)) {
emit(Resource.Intermediate(mappedResult))
}
try {
val newData = fetch(data)
mutex.withLock { saveFetchResult(query().first(), newData) }
query().map { Resource.Success(mapResult(it)) }
} catch (throwable: Throwable) {
onFetchFailed(throwable)
query().map { Resource.Error(throwable) }
}
} else {
query().map { Resource.Success(mapResult(it)) }
})
}

View File

@ -0,0 +1,12 @@
package io.github.wulkanowy.data.api
import io.github.wulkanowy.data.db.entities.AdminMessage
import retrofit2.http.GET
import javax.inject.Singleton
@Singleton
interface AdminMessageService {
@GET("/v1.json")
suspend fun getAdminMessages(): List<AdminMessage>
}

View File

@ -1,97 +1,11 @@
package io.github.wulkanowy.data.db
import android.content.Context
import androidx.room.Database
import androidx.room.Room
import androidx.room.RoomDatabase
import androidx.room.*
import androidx.room.RoomDatabase.JournalMode.TRUNCATE
import androidx.room.TypeConverters
import io.github.wulkanowy.data.db.dao.AttendanceDao
import io.github.wulkanowy.data.db.dao.AttendanceSummaryDao
import io.github.wulkanowy.data.db.dao.CompletedLessonsDao
import io.github.wulkanowy.data.db.dao.ConferenceDao
import io.github.wulkanowy.data.db.dao.ExamDao
import io.github.wulkanowy.data.db.dao.GradeDao
import io.github.wulkanowy.data.db.dao.GradePartialStatisticsDao
import io.github.wulkanowy.data.db.dao.GradePointsStatisticsDao
import io.github.wulkanowy.data.db.dao.GradeSemesterStatisticsDao
import io.github.wulkanowy.data.db.dao.GradeSummaryDao
import io.github.wulkanowy.data.db.dao.HomeworkDao
import io.github.wulkanowy.data.db.dao.LuckyNumberDao
import io.github.wulkanowy.data.db.dao.MessageAttachmentDao
import io.github.wulkanowy.data.db.dao.MessagesDao
import io.github.wulkanowy.data.db.dao.MobileDeviceDao
import io.github.wulkanowy.data.db.dao.NoteDao
import io.github.wulkanowy.data.db.dao.RecipientDao
import io.github.wulkanowy.data.db.dao.ReportingUnitDao
import io.github.wulkanowy.data.db.dao.SchoolDao
import io.github.wulkanowy.data.db.dao.SemesterDao
import io.github.wulkanowy.data.db.dao.StudentDao
import io.github.wulkanowy.data.db.dao.StudentInfoDao
import io.github.wulkanowy.data.db.dao.SubjectDao
import io.github.wulkanowy.data.db.dao.TeacherDao
import io.github.wulkanowy.data.db.dao.TimetableAdditionalDao
import io.github.wulkanowy.data.db.dao.TimetableDao
import io.github.wulkanowy.data.db.entities.Attendance
import io.github.wulkanowy.data.db.entities.AttendanceSummary
import io.github.wulkanowy.data.db.entities.CompletedLesson
import io.github.wulkanowy.data.db.entities.Conference
import io.github.wulkanowy.data.db.entities.Exam
import io.github.wulkanowy.data.db.entities.Grade
import io.github.wulkanowy.data.db.entities.GradePartialStatistics
import io.github.wulkanowy.data.db.entities.GradePointsStatistics
import io.github.wulkanowy.data.db.entities.GradeSemesterStatistics
import io.github.wulkanowy.data.db.entities.GradeSummary
import io.github.wulkanowy.data.db.entities.Homework
import io.github.wulkanowy.data.db.entities.LuckyNumber
import io.github.wulkanowy.data.db.entities.Message
import io.github.wulkanowy.data.db.entities.MessageAttachment
import io.github.wulkanowy.data.db.entities.MobileDevice
import io.github.wulkanowy.data.db.entities.Note
import io.github.wulkanowy.data.db.entities.Recipient
import io.github.wulkanowy.data.db.entities.ReportingUnit
import io.github.wulkanowy.data.db.entities.School
import io.github.wulkanowy.data.db.entities.Semester
import io.github.wulkanowy.data.db.entities.Student
import io.github.wulkanowy.data.db.entities.StudentInfo
import io.github.wulkanowy.data.db.entities.Subject
import io.github.wulkanowy.data.db.entities.Teacher
import io.github.wulkanowy.data.db.entities.Timetable
import io.github.wulkanowy.data.db.entities.TimetableAdditional
import io.github.wulkanowy.data.db.migrations.Migration10
import io.github.wulkanowy.data.db.migrations.Migration11
import io.github.wulkanowy.data.db.migrations.Migration12
import io.github.wulkanowy.data.db.migrations.Migration13
import io.github.wulkanowy.data.db.migrations.Migration14
import io.github.wulkanowy.data.db.migrations.Migration15
import io.github.wulkanowy.data.db.migrations.Migration16
import io.github.wulkanowy.data.db.migrations.Migration17
import io.github.wulkanowy.data.db.migrations.Migration18
import io.github.wulkanowy.data.db.migrations.Migration19
import io.github.wulkanowy.data.db.migrations.Migration2
import io.github.wulkanowy.data.db.migrations.Migration20
import io.github.wulkanowy.data.db.migrations.Migration21
import io.github.wulkanowy.data.db.migrations.Migration22
import io.github.wulkanowy.data.db.migrations.Migration23
import io.github.wulkanowy.data.db.migrations.Migration24
import io.github.wulkanowy.data.db.migrations.Migration25
import io.github.wulkanowy.data.db.migrations.Migration26
import io.github.wulkanowy.data.db.migrations.Migration27
import io.github.wulkanowy.data.db.migrations.Migration28
import io.github.wulkanowy.data.db.migrations.Migration29
import io.github.wulkanowy.data.db.migrations.Migration3
import io.github.wulkanowy.data.db.migrations.Migration30
import io.github.wulkanowy.data.db.migrations.Migration31
import io.github.wulkanowy.data.db.migrations.Migration32
import io.github.wulkanowy.data.db.migrations.Migration33
import io.github.wulkanowy.data.db.migrations.Migration34
import io.github.wulkanowy.data.db.migrations.Migration35
import io.github.wulkanowy.data.db.migrations.Migration4
import io.github.wulkanowy.data.db.migrations.Migration5
import io.github.wulkanowy.data.db.migrations.Migration6
import io.github.wulkanowy.data.db.migrations.Migration7
import io.github.wulkanowy.data.db.migrations.Migration8
import io.github.wulkanowy.data.db.migrations.Migration9
import io.github.wulkanowy.data.db.dao.*
import io.github.wulkanowy.data.db.entities.*
import io.github.wulkanowy.data.db.migrations.*
import io.github.wulkanowy.utils.AppInfo
import javax.inject.Singleton
@ -116,7 +30,7 @@ import javax.inject.Singleton
Subject::class,
LuckyNumber::class,
CompletedLesson::class,
ReportingUnit::class,
Mailbox::class,
Recipient::class,
MobileDevice::class,
Teacher::class,
@ -124,6 +38,15 @@ import javax.inject.Singleton
Conference::class,
TimetableAdditional::class,
StudentInfo::class,
TimetableHeader::class,
SchoolAnnouncement::class,
Notification::class,
AdminMessage::class
],
autoMigrations = [
AutoMigration(from = 44, to = 45),
AutoMigration(from = 46, to = 47),
AutoMigration(from = 47, to = 48),
],
version = AppDatabase.VERSION_SCHEMA,
exportSchema = true
@ -132,7 +55,7 @@ import javax.inject.Singleton
abstract class AppDatabase : RoomDatabase() {
companion object {
const val VERSION_SCHEMA = 35
const val VERSION_SCHEMA = 51
fun getMigrations(sharedPrefProvider: SharedPrefProvider, appInfo: AppInfo) = arrayOf(
Migration2(),
@ -168,7 +91,20 @@ abstract class AppDatabase : RoomDatabase() {
Migration32(),
Migration33(),
Migration34(),
Migration35(appInfo)
Migration35(appInfo),
Migration36(),
Migration37(),
Migration38(),
Migration39(),
Migration40(),
Migration41(sharedPrefProvider),
Migration42(),
Migration43(),
Migration44(),
Migration46(),
Migration49(),
Migration50(),
Migration51(),
)
fun newInstance(
@ -219,7 +155,7 @@ abstract class AppDatabase : RoomDatabase() {
abstract val completedLessonsDao: CompletedLessonsDao
abstract val reportingUnitDao: ReportingUnitDao
abstract val mailboxDao: MailboxDao
abstract val recipientDao: RecipientDao
@ -234,4 +170,12 @@ abstract class AppDatabase : RoomDatabase() {
abstract val timetableAdditionalDao: TimetableAdditionalDao
abstract val studentInfoDao: StudentInfoDao
abstract val timetableHeaderDao: TimetableHeaderDao
abstract val schoolAnnouncementDao: SchoolAnnouncementDao
abstract val notificationDao: NotificationDao
abstract val adminMessagesDao: AdminMessageDao
}

View File

@ -1,47 +1,36 @@
package io.github.wulkanowy.data.db
import androidx.room.TypeConverter
import com.squareup.moshi.Moshi
import com.squareup.moshi.Types
import io.github.wulkanowy.data.db.adapters.PairAdapterFactory
import io.github.wulkanowy.ui.modules.Destination
import io.github.wulkanowy.utils.toTimestamp
import kotlinx.serialization.SerializationException
import kotlinx.serialization.decodeFromString
import kotlinx.serialization.encodeToString
import kotlinx.serialization.json.Json
import java.time.*
import java.util.*
import java.time.Instant
import java.time.LocalDate
import java.time.LocalDateTime
import java.time.Month
import java.time.ZoneOffset
import java.util.Date
import java.util.*
class Converters {
private val moshi by lazy { Moshi.Builder().add(PairAdapterFactory).build() }
private val integerListAdapter by lazy {
moshi.adapter<List<Int>>(Types.newParameterizedType(List::class.java, Integer::class.java))
}
private val stringListPairAdapter by lazy {
moshi.adapter<List<Pair<String, String>>>(Types.newParameterizedType(List::class.java, Pair::class.java, String::class.java, String::class.java))
}
private val json = Json
@TypeConverter
fun timestampToDate(value: Long?): LocalDate? = value?.run {
Date(value).toInstant().atZone(ZoneOffset.UTC).toLocalDate()
}
fun timestampToLocalDate(value: Long?): LocalDate? =
value?.let(::Date)?.toInstant()?.atZone(ZoneOffset.UTC)?.toLocalDate()
@TypeConverter
fun dateToTimestamp(date: LocalDate?): Long? {
return date?.atStartOfDay()?.toInstant(ZoneOffset.UTC)?.toEpochMilli()
}
fun dateToTimestamp(date: LocalDate?): Long? = date?.toTimestamp()
@TypeConverter
fun timestampToTime(value: Long?): LocalDateTime? = value?.let {
LocalDateTime.ofInstant(Instant.ofEpochMilli(value), ZoneOffset.UTC)
}
fun instantToTimestamp(instant: Instant?): Long? = instant?.toEpochMilli()
@TypeConverter
fun timeToTimestamp(date: LocalDateTime?): Long? {
return date?.atZone(ZoneOffset.UTC)?.toInstant()?.toEpochMilli()
}
fun timestampToInstant(timestamp: Long?): Instant? = timestamp?.let(Instant::ofEpochMilli)
@TypeConverter
fun monthToInt(month: Month?) = month?.value
@ -51,21 +40,32 @@ class Converters {
@TypeConverter
fun intListToJson(list: List<Int>): String {
return integerListAdapter.toJson(list)
return json.encodeToString(list)
}
@TypeConverter
fun jsonToIntList(value: String): List<Int> {
return integerListAdapter.fromJson(value).orEmpty()
return json.decodeFromString(value)
}
@TypeConverter
fun stringPairListToJson(list: List<Pair<String, String>>): String {
return stringListPairAdapter.toJson(list)
return json.encodeToString(list)
}
@TypeConverter
fun jsonToStringPairList(value: String): List<Pair<String, String>> {
return stringListPairAdapter.fromJson(value).orEmpty()
return try {
json.decodeFromString(value)
} catch (e: SerializationException) {
emptyList() // handle errors from old gson Pair serialized data
}
}
@TypeConverter
fun destinationToString(destination: Destination) = json.encodeToString(destination)
@TypeConverter
fun stringToDestination(destination: String): Destination = json.decodeFromString(destination)
}

View File

@ -20,9 +20,18 @@ class SharedPrefProvider @Inject constructor(
fun getLong(key: String, defaultValue: Long) = sharedPref.getLong(key, defaultValue)
fun getString(key: String, defaultValue: String): String = sharedPref.getString(key, defaultValue) ?: defaultValue
fun getString(key: String) = sharedPref.getString(key, null)
fun putString(key: String, value: String, sync: Boolean = false) {
fun getString(key: String, defaultValue: String): String =
sharedPref.getString(key, defaultValue) ?: defaultValue
fun getBoolean(key: String, defaultValue: Boolean): Boolean =
sharedPref.getBoolean(key, defaultValue)
fun putBoolean(key: String, value: Boolean, sync: Boolean = false) =
sharedPref.edit(sync) { putBoolean(key, value) }
fun putString(key: String, value: String?, sync: Boolean = false) {
sharedPref.edit(sync) { putString(key, value) }
}

View File

@ -1,68 +0,0 @@
package io.github.wulkanowy.data.db.adapters
import com.squareup.moshi.JsonAdapter
import com.squareup.moshi.JsonReader
import com.squareup.moshi.JsonWriter
import com.squareup.moshi.Moshi
import com.squareup.moshi.Types
import java.lang.reflect.ParameterizedType
import java.lang.reflect.Type
object PairAdapterFactory : JsonAdapter.Factory {
override fun create(type: Type, annotations: MutableSet<out Annotation>, moshi: Moshi): JsonAdapter<*>? {
if (type !is ParameterizedType || List::class.java != type.rawType) return null
if (type.actualTypeArguments[0] != Pair::class.java) return null
val listType = Types.newParameterizedType(List::class.java, Map::class.java, String::class.java)
val listAdapter = moshi.adapter<List<Map<String, String>>>(listType)
val mapType = Types.newParameterizedType(MutableMap::class.java, String::class.java, String::class.java)
val mapAdapter = moshi.adapter<Map<String, String>>(mapType)
return PairAdapter(listAdapter, mapAdapter)
}
private class PairAdapter(
private val listAdapter: JsonAdapter<List<Map<String, String>>>,
private val mapAdapter: JsonAdapter<Map<String, String>>,
) : JsonAdapter<List<Pair<String, String>>>() {
override fun toJson(writer: JsonWriter, value: List<Pair<String, String>>?) {
writer.beginArray()
value?.forEach {
writer.beginObject()
writer.name("first").value(it.first)
writer.name("second").value(it.second)
writer.endObject()
}
writer.endArray()
}
override fun fromJson(reader: JsonReader): List<Pair<String, String>>? {
return if (reader.peek() == JsonReader.Token.BEGIN_OBJECT) deserializeMoshiMap(reader)
else deserializeGsonPair(reader)
}
// for compatibility with 0.21.0
private fun deserializeMoshiMap(reader: JsonReader): List<Pair<String, String>>? {
val map = mapAdapter.fromJson(reader) ?: return null
return map.entries.map {
it.key to it.value
}
}
private fun deserializeGsonPair(reader: JsonReader): List<Pair<String, String>>? {
val list = listAdapter.fromJson(reader) ?: return null
return list.map {
require(it.size == 2) {
"pair with more or less than two elements: $list"
}
it["first"].orEmpty() to it["second"].orEmpty()
}
}
}
}

View File

@ -0,0 +1,25 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import androidx.room.Transaction
import io.github.wulkanowy.data.db.entities.AdminMessage
import kotlinx.coroutines.flow.Flow
import javax.inject.Singleton
@Singleton
@Dao
abstract class AdminMessageDao : BaseDao<AdminMessage> {
@Query("SELECT * FROM AdminMessages")
abstract fun loadAll(): Flow<List<AdminMessage>>
@Transaction
open suspend fun removeOldAndSaveNew(
oldMessages: List<AdminMessage>,
newMessages: List<AdminMessage>
) {
deleteAll(oldMessages)
insertAll(newMessages)
}
}

View File

@ -11,6 +11,11 @@ import javax.inject.Singleton
@Dao
interface AttendanceDao : BaseDao<Attendance> {
@Query("SELECT * FROM Attendance WHERE diary_id = :diaryId AND student_id = :studentId AND date >= :from AND date <= :end")
fun loadAll(diaryId: Int, studentId: Int, from: LocalDate, end: LocalDate): Flow<List<Attendance>>
@Query("SELECT * FROM Attendance WHERE diary_id = :diaryId AND student_id = :studentId AND date >= :start AND date <= :end")
fun loadAll(
diaryId: Int,
studentId: Int,
start: LocalDate,
end: LocalDate
): Flow<List<Attendance>>
}

View File

@ -2,11 +2,12 @@ package io.github.wulkanowy.data.db.dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Update
interface BaseDao<T> {
@Insert
@Insert(onConflict = OnConflictStrategy.REPLACE)
suspend fun insertAll(items: List<T>): List<Long>
@Update

View File

@ -4,12 +4,13 @@ import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Conference
import kotlinx.coroutines.flow.Flow
import java.time.Instant
import javax.inject.Singleton
@Dao
@Singleton
interface ConferenceDao : BaseDao<Conference> {
@Query("SELECT * FROM Conferences WHERE diary_id = :diaryId AND student_id = :studentId")
fun loadAll(diaryId: Int, studentId: Int): Flow<List<Conference>>
@Query("SELECT * FROM Conferences WHERE diary_id = :diaryId AND student_id = :studentId AND date >= :startDate")
fun loadAll(diaryId: Int, studentId: Int, startDate: Instant): Flow<List<Conference>>
}

View File

@ -0,0 +1,14 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Mailbox
import javax.inject.Singleton
@Singleton
@Dao
interface MailboxDao : BaseDao<Mailbox> {
@Query("SELECT * FROM Mailboxes WHERE userLoginId = :userLoginId ")
suspend fun loadAll(userLoginId: Int): List<Mailbox>
}

View File

@ -11,9 +11,9 @@ import kotlinx.coroutines.flow.Flow
interface MessagesDao : BaseDao<Message> {
@Transaction
@Query("SELECT * FROM Messages WHERE student_id = :studentId AND message_id = :messageId")
fun loadMessageWithAttachment(studentId: Int, messageId: Int): Flow<MessageWithAttachment?>
@Query("SELECT * FROM Messages WHERE message_global_key = :messageGlobalKey")
fun loadMessageWithAttachment(messageGlobalKey: String): Flow<MessageWithAttachment?>
@Query("SELECT * FROM Messages WHERE student_id = :studentId AND folder_id = :folder ORDER BY date DESC")
fun loadAll(studentId: Int, folder: Int): Flow<List<Message>>
@Query("SELECT * FROM Messages WHERE mailbox_key = :mailboxKey AND folder_id = :folder ORDER BY date DESC")
fun loadAll(mailboxKey: String, folder: Int): Flow<List<Message>>
}

View File

@ -8,6 +8,6 @@ import kotlinx.coroutines.flow.Flow
@Dao
interface MobileDeviceDao : BaseDao<MobileDevice> {
@Query("SELECT * FROM MobileDevices WHERE student_id = :userLoginId ORDER BY date DESC")
@Query("SELECT * FROM MobileDevices WHERE user_login_id = :userLoginId ORDER BY date DESC")
fun loadAll(userLoginId: Int): Flow<List<MobileDevice>>
}

View File

@ -0,0 +1,15 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.Notification
import kotlinx.coroutines.flow.Flow
import javax.inject.Singleton
@Singleton
@Dao
interface NotificationDao : BaseDao<Notification> {
@Query("SELECT * FROM Notifications WHERE student_id = :studentId OR student_id = -1")
fun loadAll(studentId: Long): Flow<List<Notification>>
}

View File

@ -2,6 +2,7 @@ package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.MailboxType
import io.github.wulkanowy.data.db.entities.Recipient
import javax.inject.Singleton
@ -9,6 +10,6 @@ import javax.inject.Singleton
@Dao
interface RecipientDao : BaseDao<Recipient> {
@Query("SELECT * FROM Recipients WHERE student_id = :studentId AND unit_id = :unitId AND role = :role")
suspend fun loadAll(studentId: Int, unitId: Int, role: Int): List<Recipient>
@Query("SELECT * FROM Recipients WHERE type = :type AND studentMailboxGlobalKey = :studentMailboxGlobalKey")
suspend fun loadAll(type: MailboxType, studentMailboxGlobalKey: String): List<Recipient>
}

View File

@ -1,17 +0,0 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.ReportingUnit
import javax.inject.Singleton
@Singleton
@Dao
interface ReportingUnitDao : BaseDao<ReportingUnit> {
@Query("SELECT * FROM ReportingUnits WHERE student_id = :studentId")
suspend fun load(studentId: Int): List<ReportingUnit>
@Query("SELECT * FROM ReportingUnits WHERE student_id = :studentId AND real_id = :unitId")
suspend fun loadOne(studentId: Int, unitId: Int): ReportingUnit?
}

View File

@ -0,0 +1,15 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.SchoolAnnouncement
import kotlinx.coroutines.flow.Flow
import javax.inject.Singleton
@Dao
@Singleton
interface SchoolAnnouncementDao : BaseDao<SchoolAnnouncement> {
@Query("SELECT * FROM SchoolAnnouncements WHERE user_login_id = :userLoginId ORDER BY date DESC")
fun loadAll(userLoginId: Int): Flow<List<SchoolAnnouncement>>
}

View File

@ -1,12 +1,7 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.*
import androidx.room.OnConflictStrategy.ABORT
import androidx.room.Query
import androidx.room.Transaction
import androidx.room.Update
import io.github.wulkanowy.data.db.entities.Student
import io.github.wulkanowy.data.db.entities.StudentNickAndAvatar
import io.github.wulkanowy.data.db.entities.StudentWithSemesters
@ -14,33 +9,43 @@ import javax.inject.Singleton
@Singleton
@Dao
interface StudentDao {
abstract class StudentDao {
@Insert(onConflict = ABORT)
suspend fun insertAll(student: List<Student>): List<Long>
abstract suspend fun insertAll(student: List<Student>): List<Long>
@Delete
suspend fun delete(student: Student)
abstract suspend fun delete(student: Student)
@Update(entity = Student::class)
suspend fun update(studentNickAndAvatar: StudentNickAndAvatar)
abstract suspend fun update(studentNickAndAvatar: StudentNickAndAvatar)
@Query("SELECT * FROM Students WHERE is_current = 1")
suspend fun loadCurrent(): Student?
abstract suspend fun loadCurrent(): Student?
@Query("SELECT * FROM Students WHERE id = :id")
suspend fun loadById(id: Long): Student?
abstract suspend fun loadById(id: Long): Student?
@Query("SELECT * FROM Students")
suspend fun loadAll(): List<Student>
abstract suspend fun loadAll(): List<Student>
@Transaction
@Query("SELECT * FROM Students")
suspend fun loadStudentsWithSemesters(): List<StudentWithSemesters>
abstract suspend fun loadStudentsWithSemesters(): List<StudentWithSemesters>
@Transaction
@Query("SELECT * FROM Students WHERE id = :id")
abstract suspend fun loadStudentWithSemestersById(id: Long): StudentWithSemesters?
@Query("UPDATE Students SET is_current = 1 WHERE id = :id")
suspend fun updateCurrent(id: Long)
abstract suspend fun updateCurrent(id: Long)
@Query("UPDATE Students SET is_current = 0")
suspend fun resetCurrent()
abstract suspend fun resetCurrent()
@Transaction
open suspend fun switchCurrent(id: Long) {
resetCurrent()
updateCurrent(id)
}
}

View File

@ -5,6 +5,7 @@ import androidx.room.Query
import io.github.wulkanowy.data.db.entities.TimetableAdditional
import kotlinx.coroutines.flow.Flow
import java.time.LocalDate
import java.util.UUID
import javax.inject.Singleton
@Dao
@ -12,5 +13,13 @@ import javax.inject.Singleton
interface TimetableAdditionalDao : BaseDao<TimetableAdditional> {
@Query("SELECT * FROM TimetableAdditional WHERE diary_id = :diaryId AND student_id = :studentId AND date >= :from AND date <= :end")
fun loadAll(diaryId: Int, studentId: Int, from: LocalDate, end: LocalDate): Flow<List<TimetableAdditional>>
fun loadAll(
diaryId: Int,
studentId: Int,
from: LocalDate,
end: LocalDate
): Flow<List<TimetableAdditional>>
@Query("DELETE FROM TimetableAdditional WHERE repeat_id = :repeatId")
suspend fun deleteAllByRepeatId(repeatId: UUID)
}

View File

@ -0,0 +1,16 @@
package io.github.wulkanowy.data.db.dao
import androidx.room.Dao
import androidx.room.Query
import io.github.wulkanowy.data.db.entities.TimetableHeader
import kotlinx.coroutines.flow.Flow
import java.time.LocalDate
import javax.inject.Singleton
@Dao
@Singleton
interface TimetableHeaderDao : BaseDao<TimetableHeader> {
@Query("SELECT * FROM TimetableHeaders WHERE diary_id = :diaryId AND student_id = :studentId AND date >= :from AND date <= :end")
fun loadAll(diaryId: Int, studentId: Int, from: LocalDate, end: LocalDate): Flow<List<TimetableHeader>>
}

View File

@ -0,0 +1,40 @@
package io.github.wulkanowy.data.db.entities
import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
import kotlinx.serialization.Serializable
@Serializable
@Entity(tableName = "AdminMessages")
data class AdminMessage(
@PrimaryKey
val id: Int,
val title: String,
val content: String,
@ColumnInfo(name = "version_name")
val versionMin: Int? = null,
@ColumnInfo(name = "version_max")
val versionMax: Int? = null,
@ColumnInfo(name = "target_register_host")
val targetRegisterHost: String? = null,
@ColumnInfo(name = "target_flavor")
val targetFlavor: String? = null,
@ColumnInfo(name = "destination_url")
val destinationUrl: String? = null,
val priority: String,
val type: String,
@ColumnInfo(name = "is_dismissible")
val isDismissible: Boolean = false
)

View File

@ -47,4 +47,7 @@ data class Attendance(
@PrimaryKey(autoGenerate = true)
var id: Long = 0
@ColumnInfo(name = "is_notified")
var isNotified: Boolean = true
}

View File

@ -4,7 +4,7 @@ import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
import java.io.Serializable
import java.time.LocalDateTime
import java.time.Instant
@Entity(tableName = "Conferences")
data class Conference(
@ -27,9 +27,12 @@ data class Conference(
@ColumnInfo(name = "conference_id")
val conferenceId: Int,
val date: LocalDateTime
val date: Instant,
) : Serializable {
@PrimaryKey(autoGenerate = true)
var id: Long = 0
@ColumnInfo(name = "is_notified")
var isNotified: Boolean = true
}

View File

@ -36,4 +36,7 @@ data class Exam(
@PrimaryKey(autoGenerate = true)
var id: Long = 0
@ColumnInfo(name = "is_notified")
var isNotified: Boolean = true
}

View File

@ -24,5 +24,8 @@ data class GradeSemesterStatistics(
var id: Long = 0
@Transient
var average: String = ""
var classAverage: String = ""
@Transient
var studentAverage: String = ""
}

View File

@ -3,7 +3,7 @@ package io.github.wulkanowy.data.db.entities
import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
import java.time.LocalDateTime
import java.time.Instant
@Entity(tableName = "GradesSummary")
data class GradeSummary(
@ -45,8 +45,8 @@ data class GradeSummary(
var isFinalGradeNotified: Boolean = true
@ColumnInfo(name = "predicted_grade_last_change")
var predictedGradeLastChange: LocalDateTime = LocalDateTime.now()
var predictedGradeLastChange: Instant = Instant.now()
@ColumnInfo(name = "final_grade_last_change")
var finalGradeLastChange: LocalDateTime = LocalDateTime.now()
var finalGradeLastChange: Instant = Instant.now()
}

View File

@ -37,4 +37,10 @@ data class Homework(
@ColumnInfo(name = "is_done")
var isDone: Boolean = false
@ColumnInfo(name = "is_notified")
var isNotified: Boolean = true
@ColumnInfo(name = "is_added_by_user")
var isAddedByUser: Boolean = false
}

View File

@ -0,0 +1,25 @@
package io.github.wulkanowy.data.db.entities
import androidx.room.Entity
import androidx.room.PrimaryKey
@Entity(tableName = "Mailboxes")
data class Mailbox(
@PrimaryKey
val globalKey: String,
val fullName: String,
val userName: String,
val userLoginId: Int,
val studentName: String,
val schoolNameShort: String,
val type: MailboxType,
)
enum class MailboxType {
STUDENT,
PARENT,
GUARDIAN,
EMPLOYEE,
UNKNOWN,
}

View File

@ -4,40 +4,31 @@ import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
import java.io.Serializable
import java.time.LocalDateTime
import java.time.Instant
@Entity(tableName = "Messages")
data class Message(
@ColumnInfo(name = "student_id")
val studentId: Long,
@ColumnInfo(name = "message_global_key")
val messageGlobalKey: String,
@ColumnInfo(name = "real_id")
val realId: Int,
@ColumnInfo(name = "mailbox_key")
val mailboxKey: String,
@ColumnInfo(name = "message_id")
val messageId: Int,
@ColumnInfo(name = "sender_name")
val sender: String,
@ColumnInfo(name = "sender_id")
val senderId: Int,
@ColumnInfo(name = "recipient_name")
val recipient: String,
val correspondents: String,
val subject: String,
val date: LocalDateTime,
val date: Instant,
@ColumnInfo(name = "folder_id")
val folderId: Int,
var unread: Boolean,
val removed: Boolean,
@ColumnInfo(name = "has_attachments")
val hasAttachments: Boolean
) : Serializable {
@ -48,11 +39,7 @@ data class Message(
@ColumnInfo(name = "is_notified")
var isNotified: Boolean = true
@ColumnInfo(name = "unread_by")
var unreadBy: Int = 0
@ColumnInfo(name = "read_by")
var readBy: Int = 0
var content: String = ""
var sender: String? = null
var recipients: String? = null
}

View File

@ -12,11 +12,8 @@ data class MessageAttachment(
@ColumnInfo(name = "real_id")
val realId: Int,
@ColumnInfo(name = "message_id")
val messageId: Int,
@ColumnInfo(name = "one_drive_id")
val oneDriveId: String,
@ColumnInfo(name = "message_global_key")
val messageGlobalKey: String,
@ColumnInfo(name = "url")
val url: String,

Some files were not shown because too many files have changed in this diff Show More