Skip to content
Snippets Groups Projects
Commit a9f63b48 authored by Bintang Hijriawan's avatar Bintang Hijriawan
Browse files

fix: fix merge

parent 21d4b970
2 merge requests!7Feat/chart,!6Feat/navbar,scan,email
......@@ -15,18 +15,6 @@
</deviceKey>
</Target>
</targetSelectedWithDropDown>
<timeTargetWasSelectedWithDropDown value="2024-04-03T18:27:02.041955500Z" />
<runningDeviceTargetSelectedWithDropDown>
<Target>
<type value="RUNNING_DEVICE_TARGET" />
<deviceKey>
<Key>
<type value="SERIAL_NUMBER" />
<value value="emulator-5554" />
</Key>
</deviceKey>
</Target>
</runningDeviceTargetSelectedWithDropDown>
<timeTargetWasSelectedWithDropDown value="2024-04-03T17:57:13.057353Z" />
</State>
</entry>
......
......@@ -117,13 +117,6 @@ class TransactionFragment : Fragment() {
loadDatas()
}
private fun loadDatas() {
listTransaction.clear()
listTransaction.addAll(database.transactionDao().getAll())
adapter.notifyDataSetChanged()
}
private fun loadDatas() {
listTransaction.clear()
......
......@@ -7,11 +7,7 @@ import androidx.room.RoomDatabase
import com.example.bondoman.retrofit.data.dao.TransactionDao
import com.example.bondoman.retrofit.data.entity.TransactionEntity
<<<<<<< app/src/main/java/com/example/bondoman/retrofit/data/TransactionDB.kt
@Database(entities = [TransactionEntity::class], version = 2)
=======
@Database(entities = [TransactionEntity::class], version = 1)
>>>>>>> app/src/main/java/com/example/bondoman/retrofit/data/TransactionDB.kt
abstract class TransactionDB : RoomDatabase() {
abstract fun transactionDao(): TransactionDao
......
......@@ -12,9 +12,9 @@ enum class Category {
@Entity
data class TransactionEntity(
@PrimaryKey(autoGenerate = true) var id: Int? = null,
@ColumnInfo(name = "name") var name: String? = null,
@ColumnInfo(name = "category") var category: Category? = null,
@ColumnInfo(name = "date") var date: String? = null,
@ColumnInfo(name = "price") var price: Int? = null,
@ColumnInfo(name = "location") var location: String? = null
@ColumnInfo(name = "nama_transaksi") var name: String? = null,
@ColumnInfo(name = "kategori_transaksi") var category: Category? = null,
@ColumnInfo(name = "tanggal_transaksi") var date: String? = null,
@ColumnInfo(name = "nominal_transaksi") var price: Int? = null,
@ColumnInfo(name = "lokasi_transaksi") var location: String? = null
)
\ No newline at end of file
package com.example.bondoman.retrofit.data.entity
import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.PrimaryKey
enum class Category {
Pemasukan,
Pengeluaran
}
@Entity
data class TransactionEntity(
@PrimaryKey(autoGenerate = true) var id: Int? = null,
@ColumnInfo(name = "nama_transaksi") var name: String? = null,
@ColumnInfo(name = "kategori_transaksi") var category: Category? = null,
@ColumnInfo(name = "tanggal_transaksi") var date: String? = null,
@ColumnInfo(name = "nominal_transaksi") var price: Int? = null,
@ColumnInfo(name = "lokasi_transaksi") var location: String? = null
)
\ No newline at end of file
......@@ -2,5 +2,4 @@
plugins {
id("com.android.application") version "8.2.2" apply false
id("org.jetbrains.kotlin.android") version "1.9.22" apply false
}
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment