File tree Expand file tree Collapse file tree 3 files changed +10
-11
lines changed Expand file tree Collapse file tree 3 files changed +10
-11
lines changed Original file line number Diff line number Diff line change 11<?xml version =" 1.0" encoding =" utf-8" ?>
22<manifest xmlns : android =" http://schemas.android.com/apk/res/android"
33 xmlns : tools =" http://schemas.android.com/tools" >
4- <uses-permission android : name =" android.permission.INTERNET" />
4+
5+ <uses-permission android : name =" android.permission.INTERNET" />
56
67 <application
7- android : allowBackup =" true"
8+ android : name =" ytemplate.android.YTemplate"
9+ android : allowBackup =" false"
810 android : dataExtractionRules =" @xml/data_extraction_rules"
911 android : fullBackupContent =" @xml/backup_rules"
1012 android : icon =" @mipmap/ic_launcher"
1113 android : label =" @string/app_name"
1214 android : roundIcon =" @mipmap/ic_launcher_round"
1315 android : supportsRtl =" true"
14- android : name =" ytemplate.android.YTemplate"
1516 android : theme =" @style/Theme.YTemplate"
1617 tools : targetApi =" 31" >
1718 <activity
2425 <category android : name =" android.intent.category.LAUNCHER" />
2526 </intent-filter >
2627
27- <meta-data
28- android : name =" android.app.lib_name"
29- android : value =" " />
3028 </activity >
3129 </application >
3230
Original file line number Diff line number Diff line change 11package ytemplate.android.data.datasource
22
3-
4- import io.ktor.client.*
5- import io.ktor.client.call.*
6- import io.ktor.client.request.*
3+ import io.ktor.client.HttpClient
4+ import io.ktor.client.call.body
5+ import io.ktor.client.request.get
6+ import io.ktor.client.request.url
7+ import javax.inject.Inject
78import ytemplate.android.data.model.PostDTO
89import ytemplate.android.data.model.PostRequest
910import ytemplate.android.infra.AppResult
1011import ytemplate.android.infra.Routes
11- import javax.inject.Inject
1212
1313/* *
1414 * RemotePostDataSource will take care all post related remote operation.
Original file line number Diff line number Diff line change @@ -43,6 +43,7 @@ fun MyModelScreen(viewModel: MyPostViewModel = hiltViewModel()) {
4343 key2 = viewModel,
4444 producer = {
4545 lifecycle.repeatOnLifecycle(state = Lifecycle .State .STARTED ) {
46+ viewModel.getAllPost()
4647 viewModel.uiState.collect {
4748 value = it
4849 }
You can’t perform that action at this time.
0 commit comments