Skip to content

Commit

Permalink
[FEAT] #9-setOnClickListener on Button for Intent
Browse files Browse the repository at this point in the history
  • Loading branch information
librarywon committed May 26, 2023
1 parent c4b0d6e commit afde3d6
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
package com.sopt.carrot.presentation.review

import android.content.Context
import android.content.Intent
import android.os.Bundle
import android.widget.Toast
import androidx.activity.viewModels
import androidx.appcompat.app.AppCompatActivity
import com.sopt.carrot.databinding.ActivityReviewBinding
import com.sopt.carrot.presentation.page.PageActivity
import com.sopt.carrot.presentation.review.adapter.ReviewAdapter
import com.sopt.carrot.presentation.review.model.ReviewViewModel
import com.sopt.carrot.util.toast
Expand Down Expand Up @@ -45,6 +47,11 @@ class ReviewActivity : AppCompatActivity() {
viewModel.errorResult.observe(this) { errorResult ->
context.toast(errorResult.message)
}

binding.btnReviewBack.setOnClickListener {
val intent = Intent(this, PageActivity::class.java)
startActivity(intent)
}
}

private fun getUserIdFromPage(): Long {
Expand Down

0 comments on commit afde3d6

Please sign in to comment.