| | |
| | | package com.dayu.general.activity |
| | | |
| | | import android.content.Intent |
| | | import android.os.Bundle |
| | | import android.view.LayoutInflater |
| | | import android.view.View |
| | | import android.view.ViewGroup |
| | | import androidx.fragment.app.Fragment |
| | | import com.dayu.general.databinding.FragmentCardBinding |
| | | |
| | | /** |
| | | * @author: zuo |
| | | * @desc: 制卡首页 |
| | | * @since:2025/3/6 |
| | | */ |
| | | class BSCardFragment :Fragment() { |
| | | |
| | | private lateinit var binding: FragmentCardBinding |
| | | override fun onCreate(savedInstanceState: Bundle?) { |
| | | super.onCreate(savedInstanceState) |
| | | } |
| | | |
| | | override fun onCreateView( |
| | | inflater: LayoutInflater, |
| | | container: ViewGroup?, |
| | | savedInstanceState: Bundle? |
| | | ): View? { |
| | | binding = FragmentCardBinding.inflate(LayoutInflater.from(context), container, false) |
| | | initView() |
| | | return binding?.root |
| | | } |
| | | |
| | | private fun initView() { |
| | | binding.homeNewCard.setOnClickListener { |
| | | val intent = Intent(context, SearchUserListActivity::class.java).apply { |
| | | putExtra("type", "newUser") |
| | | } |
| | | startActivity(intent) |
| | | } |
| | | binding.homeManage.setOnClickListener { |
| | | val intent = Intent(context, ManageListActivity::class.java) |
| | | startActivity(intent) |
| | | } |
| | | binding.homeLossLL.setOnClickListener { |
| | | val intent = Intent(context, SearchCardListActivity::class.java).apply{ |
| | | putExtra("type", "loss") |
| | | } |
| | | startActivity(intent) |
| | | } |
| | | binding.homeReplaceLL.setOnClickListener{ |
| | | val intent = Intent(context, SearchCardListActivity::class.java).apply{ |
| | | putExtra("type", "replace") |
| | | } |
| | | startActivity(intent) |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | } |