Browse Source

1.我的相关

shihuiyun 2 years ago
parent
commit
36b690c88a
44 changed files with 2870 additions and 457 deletions
  1. 2 0
      app/src/main/AndroidManifest.xml
  2. 491 0
      app/src/main/java/com/hdl/xl/activity/LotsDetailsActivity.kt
  3. 56 0
      app/src/main/java/com/hdl/xl/activity/PartakeActivity.kt
  4. 43 0
      app/src/main/java/com/hdl/xl/activity/RosterActivity.kt
  5. 22 20
      app/src/main/java/com/hdl/xl/activity/TibetanDetailsActivity.kt
  6. 36 0
      app/src/main/java/com/hdl/xl/adapter/PartakeAdapter.kt
  7. 64 42
      app/src/main/java/com/hdl/xl/adapter/RecommedAdapter.kt
  8. 39 0
      app/src/main/java/com/hdl/xl/adapter/RosterAdapter.kt
  9. 1 0
      app/src/main/java/com/hdl/xl/config/ConfigRx.kt
  10. 6 3
      app/src/main/java/com/hdl/xl/fragment/HomeGoodFragmet.kt
  11. 0 1
      app/src/main/java/com/hdl/xl/fragment/MyCalendarFragment.kt
  12. 27 12
      app/src/main/java/com/hdl/xl/fragment/RecommendFragment.kt
  13. 3 1
      app/src/main/java/com/hdl/xl/model/CollectionList.kt
  14. 19 0
      app/src/main/java/com/hdl/xl/model/PartackBean.kt
  15. 13 0
      app/src/main/java/com/hdl/xl/model/RosterBean.kt
  16. 2 0
      app/src/main/java/com/hdl/xl/model/TibetaDetails.kt
  17. 3 2
      app/src/main/java/com/hdl/xl/model/bean/PayTypeBen.kt
  18. 1 1
      app/src/main/java/com/hdl/xl/utils/PopuBuyIntegralUtils.kt
  19. 19 11
      app/src/main/java/com/hdl/xl/utils/PopuBuyUtils.kt
  20. 81 0
      app/src/main/java/com/hdl/xl/utils/PopuPaySuesstils.kt
  21. 49 0
      app/src/main/java/com/hdl/xl/utils/TimeUtils.kt
  22. 24 0
      app/src/main/java/com/hdl/xl/utils/net/ApiService.kt
  23. 6 0
      app/src/main/java/com/hdl/xl/vmodel/HomeFirstVModel.kt
  24. 245 0
      app/src/main/java/com/hdl/xl/vmodel/LotsDetailsVModel.kt
  25. 44 0
      app/src/main/java/com/hdl/xl/vmodel/PartakeVModel.kt
  26. 33 0
      app/src/main/java/com/hdl/xl/vmodel/RosterVModel.kt
  27. 28 7
      app/src/main/java/com/hdl/xl/vmodel/TibetanDetailsVModel.kt
  28. BIN
      app/src/main/res/drawable-xxhdpi/ct_chou_one.png
  29. BIN
      app/src/main/res/drawable-xxhdpi/ct_chou_three.png
  30. BIN
      app/src/main/res/drawable-xxhdpi/ct_chou_two.png
  31. BIN
      app/src/main/res/drawable-xxhdpi/ct_jilu.png
  32. 810 0
      app/src/main/res/layout/activity_lots_details.xml
  33. 7 7
      app/src/main/res/layout/activity_my_collect.xml
  34. 43 0
      app/src/main/res/layout/activity_partake.xml
  35. 31 0
      app/src/main/res/layout/activity_roster.xml
  36. 387 340
      app/src/main/res/layout/activity_setting.xml
  37. 10 7
      app/src/main/res/layout/activity_tibetan_details.xml
  38. 4 3
      app/src/main/res/layout/fragment_home_first.xml
  39. 26 0
      app/src/main/res/layout/item_partake.xml
  40. 2 0
      app/src/main/res/layout/item_pop_buy.xml
  41. 52 0
      app/src/main/res/layout/item_roster.xml
  42. 126 0
      app/src/main/res/layout/popu_suess_pay.xml
  43. 3 0
      base/src/main/java/com/ysnows/base/net/Resp.kt
  44. 12 0
      base/src/main/java/com/ysnows/base/widget/tablayout/TabLayout.java

+ 2 - 0
app/src/main/AndroidManifest.xml

@@ -118,6 +118,8 @@
         <activity android:name=".activity.DrawActivity"/>
         <activity android:name=".activity.SecurityActivity"/>
         <activity android:name=".activity.UpCellActivity"/>
+        <activity android:name=".activity.LotsDetailsActivity"/>
+        <activity android:name=".activity.RosterActivity"/>
 
 
         <activity

+ 491 - 0
app/src/main/java/com/hdl/xl/activity/LotsDetailsActivity.kt

@@ -0,0 +1,491 @@
+package com.hdl.xl.activity
+
+import android.os.Bundle
+import android.os.Handler
+import android.os.Message
+import android.text.TextUtils
+import android.util.Log
+import android.view.KeyEvent
+import android.view.View
+import android.widget.Toast
+import androidx.lifecycle.lifecycleScope
+import coil.request.Disposable
+import com.hdl.xl.R
+import com.hdl.xl.base.MBActivity
+import com.hdl.xl.config.ConfigRx
+import com.hdl.xl.databinding.ActivityLotsDetailsBinding
+import com.hdl.xl.databinding.ActivityTibetanDetailsBinding
+import com.hdl.xl.model.User
+import com.hdl.xl.model.bean.PayTypeBen
+import com.hdl.xl.utils.AppUtils
+import com.hdl.xl.utils.MD5Utils
+import com.hdl.xl.utils.glide.GlideUtils
+import com.hdl.xl.utils.net.NetEngine
+import com.hdl.xl.vmodel.LotsDetailsVModel
+import com.hdl.xl.vmodel.TibetanDetailsVModel
+import com.hwangjr.rxbus.annotation.Subscribe
+import com.hwangjr.rxbus.annotation.Tag
+import com.pay.paytypelibrary.base.OnPayResultListener
+import com.pay.paytypelibrary.base.OrderInfo
+import com.pay.paytypelibrary.base.PayUtil
+import com.qmuiteam.qmui.kotlin.onClick
+import com.ysnows.base.utils.B
+import com.ysnows.base.utils.UiSwitch
+import com.ysnows.base.utils.UiUtils
+import kotlinx.coroutines.launch
+import org.json.JSONObject
+import java.text.DecimalFormat
+import java.util.*
+
+
+/**
+ * 藏品详情--抽签
+ *on 2022/7/23
+ */
+class LotsDetailsActivity : MBActivity<LotsDetailsVModel, ActivityLotsDetailsBinding>() {
+
+    var sumSecond = 300//5分钟的总的秒数
+    var disposable: Disposable? = null
+    var islide = true //是否滑动的时候标题改变
+    var screenHeightPixels = 0
+
+
+    override fun init(savedInstanceState: Bundle?) {
+        super.init(savedInstanceState)
+
+        titleBar()?.imgRight?.visibility = View.VISIBLE
+        titleBar()?.imgRight?.setImageResource(R.drawable.ct_share)
+        screenHeightPixels = UiUtils.getScreenHeightPixels()
+
+
+        vm.ll = binding.ll
+         vm.id = intent?.extras?.getString("id")
+        vm.getInfo()
+        vm.getCertificate()
+
+        vm.data.observe(this) {
+
+            //设置详情图片
+
+            GlideUtils.lImg(this, it.describe[0], 16, binding.imgDeatils)
+            //设置头 图片
+
+            GlideUtils.lImg(this, it.cover, 20, binding.imageView)
+
+
+        }
+
+
+        val uri = intent.data
+        if (uri != null) {
+            // scheme 协议
+            val scheme = uri.scheme
+            // 获取所有参数
+            val query = uri.query
+            Log.i("-shy-", "query: $query")
+            //获取指定参数值
+            val payCode = uri.getQueryParameter("payCode") // 支付宝支付完后返回app后 所传的code
+            Log.e("-shy-", "payCode:$payCode") //  2为成功
+        }
+
+        vm.bean.observe(this) {
+
+            var amount = it.pay.body.totalAmount.toFloat() * 0.01
+            var name = User.get()?.true_name
+            var certNo = User.get()?.id_card
+            //创建用户支付订单信息
+            //amount:订单金额
+            //orderNumber:商户订单号
+            //createTime: 订单创建时间
+            //goodsName:商品名称
+            //name:真实姓名
+            //certNo:身份证号 //6888803045944  16938552
+            cashierPay("MD5", "16938552", "06030001", amount.toString(),
+                    it.pay.body.orderCode, it.pay.head.respTime, "象链数购买藏品", name!!, certNo!!)
+
+
+
+
+        }
+        vm.orderNo.observe(this) {
+
+            UiSwitch.bundle(
+                    context(), PaySuessActivity::class.java,
+                    B().putString("orderid", it)
+                            .putString("type", "2")
+                            .putString("price", vm.data.value?.price)
+                            .ok()
+            )
+
+        }
+
+
+    }
+
+
+    override fun listeners() {
+        super.listeners()
+
+
+        titleBar()?.imgLeft?.onClick {
+
+            finishActivity()
+        }
+
+        binding.butBuy.onClick {
+            //todo:测
+
+            var user = User.get()
+            if (user?.is_auth.equals("0")) {
+                toast("实名认证之后才能支持购买数字藏品!")
+                return@onClick
+            }
+
+            vm.toBuy(binding.butBuy)
+        }
+        titleBar()?.imgRight?.onClick {
+            //分享
+            vm.getUrl()
+
+        }
+
+    }
+
+
+    override fun binding(): ActivityLotsDetailsBinding {
+        return ActivityLotsDetailsBinding.inflate(layoutInflater)
+    }
+
+    override fun vmClass(): Class<LotsDetailsVModel> {
+        return LotsDetailsVModel::class.java
+    }
+
+    override fun title(): String? {
+        return "藏品详情"
+    }
+
+    override val isRxbus: Boolean
+        get() = true
+
+    //倒计时
+
+
+    fun initOrderCancelTime(pay_time_long: String?) {
+        //-------
+
+        sumSecond = pay_time_long!!.toInt()
+
+        vm.time.value = "请在 " + formatTime(sumSecond) + "内支付"
+
+
+        addProgress()
+    }
+
+    private fun addProgress() {
+
+
+        Log.e("-shy-", "isUp=" + vm.isUp)
+        if (sumSecond == 0) {
+            //结束 todo:
+//            vm.isUp = false
+//
+//            vm.bean.value?.state = 9
+            //去取消订单
+            // vm.toCancerOrderTo()
+
+        } else {
+            if (vm.isUp) {
+                sumSecond--
+                handler.sendEmptyMessageDelayed(0x101, 1000)
+            }
+
+        }
+    }
+
+    private val handler: Handler = object : Handler() {
+        override fun handleMessage(msg: Message) {
+            super.handleMessage(msg)
+            //计算进度
+
+
+            vm.time.value = "请在 " + formatTime(sumSecond) + "内支付"
+            addProgress()
+        }
+    }
+
+    /**
+     * 将秒转化为 HH:mm:io.agora.rtc.ss 的格式
+     *
+     * @param time 秒
+     * @return
+     */
+    /**
+     * 将秒转化为 HH:mm:io.agora.rtc.ss 的格式
+     *
+     * @param time 秒
+     * @return
+     */
+    var decimalFormat: DecimalFormat? = null
+
+    private fun formatTime(time: Int): String? {
+        if (decimalFormat == null) {
+            decimalFormat = DecimalFormat("00")
+        }
+        val hh: String = decimalFormat!!.format(time / 3600)
+        val mm: String = decimalFormat!!.format(time % 3600 / 60)
+        val ss: String = decimalFormat!!.format(time % 60)
+        // return "$hh:$mm:$io.agora.rtc.ss"
+        return "$mm:$ss"
+    }
+
+
+    @Subscribe(tags = [Tag(ConfigRx.CHOSE_PAY_TYPE)])
+    fun setChosePay(bean: PayTypeBen) {
+
+        ////1支付宝 2微信  //默认支付宝  3钱包
+
+        if (bean.choseType == 4) {//杉德的快捷支付
+
+
+            lifecycleScope.launch {
+
+
+                val it = vm.repository().lreq {
+                    NetEngine.service.setCreateOrder(
+                            "app", vm.data.value?.id, bean.num,
+                            "sd"
+                    )
+                }
+                if(vm.data.value?.issue_mode==2){//抽签发行
+
+                    if (it.ok(true)) {
+                        vm.popuBuyUtils?.setDisMiss()
+                    }
+
+                }else{//普通发行
+                    if (it.ok()) {
+                        vm.toPayOrder(it.data?.order_no, "sd")
+
+                    }
+                }
+
+
+
+            }
+
+
+            return
+        }
+
+        if (bean.choseType == 3) {
+
+            lifecycleScope.launch {
+
+
+                val it = vm.repository().lreq {
+                    NetEngine.service.setCreateOrder(
+                            "app", vm.data.value?.id, bean.num,
+                            "wallet",
+                    )
+                }
+                if(vm.data.value?.issue_mode==2){//抽签发行
+
+                    if (it.ok(true)) {
+                        vm.popuBuyUtils?.setDisMiss()
+                    }
+
+                }else{//普通发行
+                    if (it.ok()) {
+
+                        vm.toPayOrder(it.data?.order_no, "wallet")
+
+                    }
+                }
+
+
+            }
+
+        }
+
+
+    }
+
+
+    @Subscribe(tags = [Tag(ConfigRx.PAY_COMPLETE)])
+    fun setPayComplete(money: String) {//充值了保证金后刷新
+        //刷新 todo:
+        toast("支付完成")
+    }
+
+    @Subscribe(tags = [Tag(ConfigRx.PAY_COMPLETE_CLOSE)])
+    fun setPayCompleteClose(type: String) {//关闭
+        //刷新 todo:
+        finish()
+    }
+
+    override fun onKeyDown(keyCode: Int, event: KeyEvent?): Boolean {
+        return if (keyCode == KeyEvent.KEYCODE_BACK) {
+            if (null != disposable) {
+                disposable?.dispose()
+            }
+            finishActivity()
+            return false
+        } else {
+            super.onKeyDown(keyCode, event)
+        }
+    }
+
+
+    override fun onDestroy() {
+        super.onDestroy()
+        if (null != disposable) {
+            disposable?.dispose()
+        }
+    }
+
+
+    //"MD5","16938552", "06030001"
+    //amount:订单金额
+    //orderNumber:商户订单号
+    //createTime: 订单创建时间
+    //goodsName:商品名称
+    //name:真实姓名
+    //certNo:身份证号
+    private fun cashierPay(
+            signType: String, merNo: String, productCode: String, amount: String,
+            orderNumber: String, createTime: String, goodsName: String, name: String,
+            certNo: String,
+    ) {
+
+
+        val orderJson = JSONObject()
+        try {
+            orderJson.put("version", "10")
+            orderJson.put("sign_type", signType)
+            orderJson.put("mer_no", merNo) // 商户编号
+            orderJson.put("mer_key", "Xx52CDtWRH1etGu4IfFEB4OeRrnbr+EUd5VO7cBQFCqxfDl5FJcJaUjKJbHapVsyxSODBEbssNk=") // 商户密钥
+            orderJson.put("mer_order_no", orderNumber) // 商户订单号
+            orderJson.put("create_time", createTime) // 订单创建时间
+            orderJson.put("expire_time", AppUtils.getOrderExpireTime()) // 订单失效时间
+            orderJson.put("order_amt", amount) // 订单金额
+            orderJson.put("notify_url", "http://sandcash/notify") // 回调地址
+            orderJson.put("return_url", "https://www.taobao.com") // 支付完成后跳转到商户页面  一键快捷不能传空
+            orderJson.put("create_ip", "172_12_12_12") // 客户端的真实IP
+            orderJson.put("goods_name", goodsName) // 商品名称
+            orderJson.put("store_id", "100001") // 门店号
+            orderJson.put("product_code", productCode) // 支付产品编码
+            orderJson.put("clear_cycle", "0") // 清算模式
+            val payExtraJson = JSONObject()
+//            if (!TextUtils.isEmpty(cardNo)) {
+//                payExtraJson.put("cardNo", cardNo) //付款卡号
+//            }
+            orderJson.put("pay_extra", payExtraJson.toString())
+
+            orderJson.put("accsplit_flag", "NO") // 分账标识 NO无分账,YES有分账
+            orderJson.put("jump_scheme", "tibetan://spay") //参数值可以自定义,和android:scheme、android:host保持一致
+            orderJson.put("activity_no", "") //营销活动编码
+            orderJson.put("benefit_amount", "") //优惠金额
+            orderJson.put("extend", "123") //扩展字段,非必传
+            orderJson.put("limit_pay", "5") //微信传1屏蔽信用卡,支付宝传5屏蔽部分信用卡以及花呗,支付宝传4屏蔽花呗,支付宝传1屏蔽部分信用卡,银联不支持屏蔽   不参与签名
+            //            orderJson.put("channel_mid", ""); //非必传
+            val extendParamJson = JSONObject()
+            val payerVerificationInfoJson = JSONObject()
+            payerVerificationInfoJson.put("needCheckFlag", "0")
+            payerVerificationInfoJson.put("name", name) //姓名
+            payerVerificationInfoJson.put("certNo", certNo) //证件号
+            payerVerificationInfoJson.put("certType", "01")
+            extendParamJson.put("payerVerificationInfo", payerVerificationInfoJson.toString())
+            orderJson.put("extend_params", extendParamJson.toString()) //支付宝实名信息字段,非必传,不参与签名
+            val signKey: String
+            signKey = if ("6888800012098" == merNo) {
+                "PZdBctMl2c0ma9b9+25FBgH2twQBTmhzn/qNSS6xANEGMqBi/S9IhyhDi1aBb1H9gxmcvjxmMk305pcUaISEmjm6gacvTBPHj0zSgRk//7ZYF0Go/X03BZt5mTdcmslgH81l03NMtaRixuz+UKFTiw=="
+            } else {
+                "UZfTHiut04dIJSOqwT2KVn6Bf4OBGBrUvjaUibKc5UFinTz/EY8j/5P1nOAZxsgRJKC6qKPhB7NJAPxc7RyrM8BDgM+UhiKrzR/MvvQhFMgTDfQFoDZYEYW2z+pi4zany5c0bz6FNidixuz+UKFTiw=="
+            }
+
+            //计算签名
+            val signMap: MutableMap<String, String> = HashMap()
+            signMap["version"] = orderJson.getString("version")
+            signMap["mer_no"] = orderJson.getString("mer_no")
+            if ("MD5" == signType) {
+                signMap["mer_key"] = orderJson.getString("mer_key")
+            }
+            signMap["mer_order_no"] = orderJson.getString("mer_order_no")
+            signMap["create_time"] = orderJson.getString("create_time")
+            signMap["order_amt"] = orderJson.getString("order_amt")
+            signMap["notify_url"] = orderJson.getString("notify_url")
+            signMap["return_url"] = orderJson.getString("return_url")
+            signMap["create_ip"] = orderJson.getString("create_ip")
+            signMap["store_id"] = orderJson.getString("store_id")
+            signMap["pay_extra"] = orderJson.getString("pay_extra")
+            signMap["accsplit_flag"] = orderJson.getString("accsplit_flag")
+            signMap["sign_type"] = orderJson.getString("sign_type")
+            signMap["mer_order_no"] = orderJson.getString("mer_order_no")
+            signMap["create_time"] = orderJson.getString("create_time")
+            signMap["order_amt"] = orderJson.getString("order_amt")
+            signMap["notify_url"] = orderJson.getString("notify_url")
+            signMap["return_url"] = orderJson.getString("return_url")
+            signMap["create_ip"] = orderJson.getString("create_ip")
+            signMap["store_id"] = orderJson.getString("store_id")
+            signMap["pay_extra"] = orderJson.getString("pay_extra")
+            signMap["accsplit_flag"] = orderJson.getString("accsplit_flag")
+            signMap["sign_type"] = orderJson.getString("sign_type")
+            if (!TextUtils.isEmpty(orderJson.optString("activity_no"))) {
+                signMap["activity_no"] = orderJson.getString("activity_no")
+            }
+            if (!TextUtils.isEmpty(orderJson.optString("benefit_amount"))) {
+                signMap["benefit_amount"] = orderJson.getString("benefit_amount")
+            }
+            if (!TextUtils.isEmpty(orderJson.optString("extend"))) {
+                signMap["extend"] = orderJson.getString("extend")
+            }
+            if (!TextUtils.isEmpty(orderJson.optString("channel_mid"))) {
+                signMap["channel_mid"] = orderJson.getString("channel_mid")
+            }
+            val list = MD5Utils.sortMap(signMap)
+            val signBuilder = StringBuilder()
+            for ((key, value) in list) {
+                signBuilder.append(key)
+                signBuilder.append("=")
+                signBuilder.append(value)
+                signBuilder.append("&")
+            }
+
+            signBuilder.append("key")
+            signBuilder.append("=")
+            signBuilder.append(signKey)
+            orderJson.put("sign", MD5Utils.getMD5(signBuilder.toString()).toUpperCase()) // MD5签名结果
+
+        } catch (e: Exception) {
+            e.stackTrace
+        }
+
+//        • PayUtil.CashierPaySingle
+//        传入单个支付产品,直接拉起支付,无过渡页,调用方需要自己添加进度加载框;
+//        在Listener的onSuccess拉起支付(支付宝除外)。
+//
+//        • PayUtil.CashierPayMulti
+//        传入多个支付产品,也可传入单个,跳转sdk自带的收银台页面;
+//        在onActivityResult拉起支付(支付宝除外)。
+//
+//        调用方有自己的收银台页面时建议使用Single,否则使用Multi。
+//        两个API二选一即可。 (demo是为了演示用法,所以两种都写了)
+
+
+        PayUtil.CashierPaySingle(this@LotsDetailsActivity, orderJson.toString(), object : OnPayResultListener {
+            override fun onSuccess(orderInfo: OrderInfo) {
+                //支付宝、H5快捷、一键快捷、快捷充值、云账户,支付完成不走这里!
+                Toast.makeText(this@LotsDetailsActivity, "支付成功", Toast.LENGTH_LONG).show()
+
+            }
+
+            override fun onError(retMsg: String) {
+                Toast.makeText(this@LotsDetailsActivity, retMsg, Toast.LENGTH_LONG).show()
+
+            }
+        })
+
+    }
+
+
+}

+ 56 - 0
app/src/main/java/com/hdl/xl/activity/PartakeActivity.kt

@@ -0,0 +1,56 @@
+package com.hdl.xl.activity
+
+import android.os.Bundle
+import android.view.View
+import com.hdl.xl.adapter.PartakeAdapter
+import com.hdl.xl.adapter.SellOrderAdapter
+import com.hdl.xl.base.MBActivity
+import com.hdl.xl.databinding.ActivityAccountSafeBinding
+import com.hdl.xl.databinding.ActivityPartakeBinding
+import com.hdl.xl.databinding.ActivitySecurityBinding
+import com.hdl.xl.vmodel.AccountSafeVModel
+import com.hdl.xl.vmodel.PartakeVModel
+import com.hdl.xl.vmodel.SecurityVModel
+
+/**
+ *Created by shihuiyun
+ */
+class PartakeActivity : MBActivity<PartakeVModel, ActivityPartakeBinding>() {
+
+    var adapter: PartakeAdapter? = null
+
+    override fun init(savedInstanceState: Bundle?) {
+        super.init(savedInstanceState)
+        vm.coll_id=intent.extras?.getString("coll_id","0")
+        vm.is_ballot=intent.extras?.getString("is_ballot","1")
+
+        adapter = PartakeAdapter()
+        binding.recyclerView.adapter = adapter
+
+        vm.list.observe(this){
+            if(it.isEmpty() ||null==it){
+                binding.listEmpty.visibility= View.VISIBLE
+            }else{
+                binding.listEmpty.visibility= View.GONE
+            }
+            adapter?.addData(it)
+        }
+
+
+    }
+
+    override fun binding(): ActivityPartakeBinding {
+       return ActivityPartakeBinding.inflate(layoutInflater)
+    }
+
+    override fun vmClass(): Class<PartakeVModel> {
+        return PartakeVModel::class.java
+    }
+
+    override fun title(): String? {
+        return "参与人数"
+    }
+
+
+
+}

+ 43 - 0
app/src/main/java/com/hdl/xl/activity/RosterActivity.kt

@@ -0,0 +1,43 @@
+package com.hdl.xl.activity
+
+import android.os.Bundle
+import com.hdl.xl.R
+import com.hdl.xl.adapter.MsgAdapter
+import com.hdl.xl.adapter.RosterAdapter
+import com.hdl.xl.base.MBRActivity
+import com.hdl.xl.databinding.ActivityMsgBinding
+import com.hdl.xl.databinding.ActivityRosterBinding
+import com.hdl.xl.vmodel.MsgVModel
+import com.hdl.xl.vmodel.RosterVModel
+
+class RosterActivity : MBRActivity<RosterVModel, RosterAdapter, ActivityRosterBinding>() {
+
+
+    override fun init(savedInstanceState: Bundle?) {
+        super.init(savedInstanceState)
+
+        vm.coll_id=intent.extras?.getString("coll_id","0")
+        vm.is_ballot=intent.extras?.getString("is_ballot","1")
+
+    }
+
+    override fun vmClass(): Class<RosterVModel> {
+        return RosterVModel::class.java
+    }
+    override fun binding(): ActivityRosterBinding {
+        return ActivityRosterBinding.inflate(layoutInflater)
+    }
+
+    override fun initAdapter(): RosterAdapter {
+        return RosterAdapter(vm)
+    }
+
+
+    override fun title(): String? {
+        return "中签名单"
+    }
+
+    override val isRxbus: Boolean
+        get() = true
+
+}

+ 22 - 20
app/src/main/java/com/hdl/xl/activity/TibetanDetailsActivity.kt

@@ -18,6 +18,7 @@ import com.hdl.xl.model.User
 import com.hdl.xl.model.bean.PayTypeBen
 import com.hdl.xl.utils.AppUtils
 import com.hdl.xl.utils.MD5Utils
+import com.hdl.xl.utils.PopuPaySuesstils
 import com.hdl.xl.utils.glide.GlideUtils
 import com.hdl.xl.utils.net.NetEngine
 import com.hdl.xl.vmodel.TibetanDetailsVModel
@@ -37,7 +38,7 @@ import java.util.*
 
 
 /**
- * 藏品详情
+ * 藏品详情--普通
  *on 2022/7/23
  */
 class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanDetailsBinding>() {
@@ -57,8 +58,8 @@ class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanD
 
 
         vm.ll = binding.ll
-        var id = intent?.extras?.getString("id")
-        vm.getInfo(id!!)
+        vm.id= intent?.extras?.getString("id")
+        vm.getInfo()
         vm.getCertificate()
 
         vm.data.observe(this) {
@@ -67,13 +68,11 @@ class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanD
 
             GlideUtils.lImg(this, it.describe[0], 16, binding.imgDeatils)
             //设置头 图片
-
             GlideUtils.lImg(this, it.cover, 20, binding.imageView)
 
 
         }
 
-
         val uri = intent.data
         if (uri != null) {
             // scheme 协议
@@ -102,19 +101,22 @@ class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanD
                     it.pay.body.orderCode, it.pay.head.respTime, "象链数购买藏品", name!!, certNo!!)
 
 
-
-
         }
-        vm.orderNo.observe(this) {
-
-            UiSwitch.bundle(
-                    context(), PaySuessActivity::class.java,
-                    B().putString("orderid", it)
-                            .putString("type", "2")
-                            .putString("price", vm.data.value?.price)
-                            .ok()
-            )
+//        vm.orderNo.observe(this) {//钱包支付成功后的提示
+//
+//
+//            UiSwitch.bundle(
+//                    context(), PaySuessActivity::class.java,
+//                    B().putString("orderid", it)
+//                            .putString("type", "2")
+//                            .putString("price", vm.data.value?.price)
+//                            .ok()
+//            )
+//
+//        }
 
+        vm.myBean.observe(this){
+            PopuPaySuesstils.show(this,binding.ll,it)
         }
 
 
@@ -240,6 +242,7 @@ class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanD
     @Subscribe(tags = [Tag(ConfigRx.CHOSE_PAY_TYPE)])
     fun setChosePay(bean: PayTypeBen) {
 
+
         ////1支付宝 2微信  //默认支付宝  3钱包
 
         if (bean.choseType == 4) {//杉德的快捷支付
@@ -254,6 +257,7 @@ class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanD
                             "sd"
                     )
                 }
+
                 if (it.ok()) {
                     vm.toPayOrder(it.data?.order_no, "sd")
 
@@ -276,16 +280,14 @@ class TibetanDetailsActivity : MBActivity<TibetanDetailsVModel, ActivityTibetanD
                             "wallet",
                     )
                 }
-                if(it.code==0){
-                    toast(it.msg)
-                }
+
                 if (it.ok()) {
 
                     vm.toPayOrder(it.data?.order_no, "wallet")
 
-
                 }
 
+
             }
 
         }

+ 36 - 0
app/src/main/java/com/hdl/xl/adapter/PartakeAdapter.kt

@@ -0,0 +1,36 @@
+package com.hdl.xl.adapter
+
+import android.graphics.Color
+import android.graphics.Typeface
+import android.os.Bundle
+import android.text.Spannable
+import android.text.SpannableStringBuilder
+import android.text.Spanned
+import android.text.style.AbsoluteSizeSpan
+import android.text.style.ForegroundColorSpan
+import android.text.style.StyleSpan
+import com.chad.library.adapter.base.viewholder.BaseDataBindingHolder
+import com.google.gson.Gson
+import com.hdl.xl.R
+import com.hdl.xl.activity.ArticleDetailActivity
+import com.hdl.xl.databinding.ItemMsgBinding
+import com.hdl.xl.databinding.ItemPartakeBinding
+import com.hdl.xl.databinding.ItemSellOrderBinding
+import com.hdl.xl.model.MsgList
+import com.hdl.xl.model.MyCollection
+import com.hdl.xl.model.PartackBean
+import com.hdl.xl.vmodel.MsgVModel
+import com.hdl.xl.vmodel.SellOrderVModel
+import com.qmuiteam.qmui.kotlin.onClick
+import com.ysnows.base.base.BAdapter
+import com.ysnows.base.utils.UiSwitch
+
+class PartakeAdapter() : BAdapter<PartackBean.ListBean, BaseDataBindingHolder<ItemPartakeBinding>>(R.layout.item_partake) {
+
+    override fun convert(holder: BaseDataBindingHolder<ItemPartakeBinding>, item: PartackBean.ListBean) {
+        holder.dataBinding?.item = item
+
+
+
+    }
+}

+ 64 - 42
app/src/main/java/com/hdl/xl/adapter/RecommedAdapter.kt

@@ -6,6 +6,7 @@ import com.ysnows.base.base.BAdapter
 import com.hdl.xl.R
 import com.hdl.xl.databinding.ItemRecommedBinding
 import com.hdl.xl.model.CollectionList
+import com.hdl.xl.utils.TimeUtils
 import com.hdl.xl.utils.glide.GlideUtils
 
 
@@ -19,61 +20,82 @@ class RecommedAdapter() : BAdapter<CollectionList,
 
         GlideUtils.lImg(context, item.cover,18, holder.dataBinding?.imgBg!!)
 
+        if(item.issue_mode==2){
 
+            //判断 sell_time时间是否小于当前时间
 
-//        holder.dataBinding?.imgBg?.load(item.cover){
-//           // 圆角
-//            //size(300,300)
-//            transformations(RoundedCornersTransformation(20f))
-//            placeholder(R.drawable.bg_need_error)
-//            error(R.drawable.bg_need_error)
-//        }
+            if(TimeUtils.timeCompare(item.sell_time,TimeUtils.getTime())==3){
+                holder.dataBinding?.tvState?.text = "已结束"
+                holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#FF6A6A"))
+                holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_chou_three)
 
-//        Thread {
-//            val url = URL(item.cover)
-//            val conn: URLConnection = url.openConnection()
-//            conn.connect()
-//            val input: InputStream = conn.getInputStream()
-//            val options = BitmapFactory.Options()
-//            options.inSampleSize = 10
-//            var originalImage = BitmapFactory.decodeStream(input, null, options)
-//            holder.dataBinding?.imgBg?.setImageBitmap(originalImage)
-//        }.start()
+            }else{
 
+                when (item.state) {
+                    "1" -> {
+                        holder.dataBinding?.tvState?.text = "进行中  "
+                        holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#FFF488"))
+                        holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_chou_two)
+                    }
+                    "2" -> {
+                        holder.dataBinding?.tvState?.text = "未开始 " + item.sell_time
+                        holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#BEE88D"))
+                        holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_chou_one)
+                    }
+                    "3" -> {
 
+                        holder.dataBinding?.tvState?.text = "已结束 "
+                        holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#FF6A6A"))
+                        holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_stop)
+                    }
+                    else -> {
+                        holder.dataBinding?.tvState?.text = "已结束 "
+                        holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#FF6A6A"))
+                        holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_stop)
 
-        //设置图片
-//        holder.dataBinding?.imgBg?.load(item.cover) {
-//            size(100,100)
-//            error(R.drawable.bg_need_error) //加载错误占位图
-//        }
+                    }
 
-        when (item.state) {
-            "1" -> {
-                holder.dataBinding?.tvState?.text = "热卖中 "
-                holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#FFF488"))
-                holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_ing)
-            }
-            "2" -> {
-                holder.dataBinding?.tvState?.text = "即将开售 " + item.sell_time
-                holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#62FFF0"))
-                holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time)
-            }
-            "3" -> {
+                }
 
-                holder.dataBinding?.tvState?.text = "已售罄 "
-                holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#999999"))
-                holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_stop)
             }
-            else -> {
-                holder.dataBinding?.tvState?.text = "已售罄 "
-                holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#999999"))
-                holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_stop)
 
-            }
 
+
+
+        }else{
+            when (item.state) {
+                "1" -> {
+                    holder.dataBinding?.tvState?.text = "热卖中 "
+                    holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#FFF488"))
+                    holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_ing)
+                }
+                "2" -> {
+                    holder.dataBinding?.tvState?.text = "即将开售 " + item.sell_time
+                    holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#62FFF0"))
+                    holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time)
+                }
+                "3" -> {
+
+                    holder.dataBinding?.tvState?.text = "已售罄 "
+                    holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#999999"))
+                    holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_stop)
+                }
+                else -> {
+                    holder.dataBinding?.tvState?.text = "已售罄 "
+                    holder.dataBinding?.tvState?.setTextColor(Color.parseColor("#999999"))
+                    holder.dataBinding?.imgState?.setImageResource(R.drawable.ct_time_stop)
+
+                }
+
+            }
         }
 
+
+
+
+
+
+
     }
 
 

+ 39 - 0
app/src/main/java/com/hdl/xl/adapter/RosterAdapter.kt

@@ -0,0 +1,39 @@
+package com.hdl.xl.adapter
+
+import android.app.Activity
+import android.graphics.Color
+import android.graphics.Typeface
+import android.os.Bundle
+import android.text.Spannable
+import android.text.SpannableStringBuilder
+import android.text.Spanned
+import android.text.style.AbsoluteSizeSpan
+import android.text.style.ForegroundColorSpan
+import android.text.style.StyleSpan
+import com.chad.library.adapter.base.viewholder.BaseDataBindingHolder
+import com.google.gson.Gson
+import com.hdl.xl.R
+import com.hdl.xl.activity.ArticleDetailActivity
+import com.hdl.xl.activity.BankActivity
+import com.hdl.xl.activity.WithdrawalActivity
+import com.hdl.xl.config.MIntentAction
+import com.hdl.xl.databinding.ItemMsgBinding
+import com.hdl.xl.databinding.ItemRosterBinding
+import com.hdl.xl.model.MsgList
+import com.hdl.xl.model.RosterBean
+import com.hdl.xl.vmodel.MsgVModel
+import com.hdl.xl.vmodel.RosterVModel
+import com.qmuiteam.qmui.kotlin.onClick
+import com.ysnows.base.base.BAdapter
+import com.ysnows.base.utils.UiSwitch
+
+class RosterAdapter(var vm: RosterVModel) : BAdapter<RosterBean, BaseDataBindingHolder<ItemRosterBinding>>(R.layout.item_roster) {
+
+    override fun convert(holder: BaseDataBindingHolder<ItemRosterBinding>, item: RosterBean) {
+        holder.dataBinding?.vm = vm
+        holder.dataBinding?.item = item
+
+
+
+    }
+}

+ 1 - 0
app/src/main/java/com/hdl/xl/config/ConfigRx.kt

@@ -42,6 +42,7 @@ object ConfigRx {
     const val PAY_SELL_CLOSE = "PAY_SELL_CLOSE" //回到首页
 
     const val SECOND_REFRESH = "SECOND_REFRESH" //刷新二级市场订单
+    const val REFRESH_HOME_LIST = "REFRESH_HOME_LIST" //刷新首页列表
 
 
 

+ 6 - 3
app/src/main/java/com/hdl/xl/fragment/HomeGoodFragmet.kt

@@ -31,11 +31,14 @@ class HomeGoodFragmet : MBFragment<HomeGoodVModel, FragmentHomeGoodBinding>() {
 
         vm.list.observe(this) {
             //刷新
+
             if(it.isEmpty() ||null==it){
                 binding.listEmpty.visibility= View.VISIBLE
             }else{
                 binding.listEmpty.visibility= View.GONE
             }
+
+            adapter?.clearList()
             adapter?.addData(it)
         }
 
@@ -46,7 +49,7 @@ class HomeGoodFragmet : MBFragment<HomeGoodVModel, FragmentHomeGoodBinding>() {
         super.listeners()
 
         binding.tvAll.onClick {
-            adapter?.clearList()
+
             vm.list.value = ArrayList<MyCollectionGroupBy.ListBean>()
             binding.tvAll.setBackgroundResource(R.drawable.bg_chose_gray)
             binding.tvOne.setBackgroundResource(R.drawable.bg_chose_white)
@@ -55,7 +58,7 @@ class HomeGoodFragmet : MBFragment<HomeGoodVModel, FragmentHomeGoodBinding>() {
                 vm.getMyCollection("0")
         }
         binding.tvOne.onClick {
-            adapter?.clearList()
+
             vm.list.value = ArrayList<MyCollectionGroupBy.ListBean>()
             binding.tvAll.setBackgroundResource(R.drawable.bg_chose_white)
             binding.tvOne.setBackgroundResource(R.drawable.bg_chose_gray)
@@ -66,7 +69,7 @@ class HomeGoodFragmet : MBFragment<HomeGoodVModel, FragmentHomeGoodBinding>() {
 
         }
         binding.tvTwo.onClick {
-            adapter?.clearList()
+
             vm.list.value = ArrayList<MyCollectionGroupBy.ListBean>()
             binding.tvAll.setBackgroundResource(R.drawable.bg_chose_white)
             binding.tvOne.setBackgroundResource(R.drawable.bg_chose_white)

+ 0 - 1
app/src/main/java/com/hdl/xl/fragment/MyCalendarFragment.kt

@@ -7,7 +7,6 @@ import android.view.ViewGroup
 import androidx.recyclerview.widget.RecyclerView
 import com.ysnows.base.utils.B
 import com.ysnows.base.utils.UiSwitch
-import com.hdl.xl.activity.TibetanDetailsActivity
 import com.hdl.xl.adapter.CalenAdapter
 import com.hdl.xl.adapter.RecommedAdapter
 import com.hdl.xl.adapter.SellOrderAdapter

+ 27 - 12
app/src/main/java/com/hdl/xl/fragment/RecommendFragment.kt

@@ -5,14 +5,18 @@ import android.view.LayoutInflater
 import android.view.View
 import android.view.ViewGroup
 import androidx.recyclerview.widget.RecyclerView
+import com.hdl.xl.activity.LotsDetailsActivity
 import com.ysnows.base.utils.B
 import com.ysnows.base.utils.UiSwitch
 import com.hdl.xl.activity.TibetanDetailsActivity
 import com.hdl.xl.adapter.RecommedAdapter
 import com.hdl.xl.base.MBFragment
+import com.hdl.xl.config.ConfigRx
 import com.hdl.xl.databinding.FragmentRecommendBinding
 import com.hdl.xl.model.CollectionList
 import com.hdl.xl.vmodel.RecommendVModel
+import com.hwangjr.rxbus.annotation.Subscribe
+import com.hwangjr.rxbus.annotation.Tag
 
 
 /**
@@ -23,10 +27,10 @@ import com.hdl.xl.vmodel.RecommendVModel
 class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>() {
 
 
-    var  page:Int=1
-    var listTo=ArrayList<CollectionList>()//未加载到界面的剩余的数据
-    var listTwo=ArrayList<CollectionList>()
-    var adapter:RecommedAdapter? = null
+    var page: Int = 1
+    var listTo = ArrayList<CollectionList>()//未加载到界面的剩余的数据
+    var listTwo = ArrayList<CollectionList>()
+    var adapter: RecommedAdapter? = null
     override fun init(savedInstanceState: Bundle?) {
         super.init(savedInstanceState)
         //禁止下拉刷新和下拉加载
@@ -34,7 +38,7 @@ class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>(
 //        val linearLayoutManager = LinearLayoutManager(context, LinearLayoutManager.VERTICAL, false)
 //        binding.recyclerRecommend.layoutManager = linearLayoutManager
 
-         adapter = RecommedAdapter()
+        adapter = RecommedAdapter()
         binding.recyclerRecommend.adapter = adapter
 
         vm.toGetCollectionList()
@@ -57,7 +61,8 @@ class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>(
 //                setAdapter(list)
 //                return@Observer
 //            }
-           setAdapter(it)
+            adapter?.clearList()
+            setAdapter(it)
 
         })
 
@@ -65,7 +70,6 @@ class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>(
     }
 
 
-
     override fun listeners() {
         super.listeners()
 
@@ -85,7 +89,6 @@ class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>(
 //        })
 
 
-
 //        binding.recyclerRecommend.addOnScrollListener(object : RecyclerView.OnScrollListener() {
 //            override fun onScrollStateChanged(recyclerView: RecyclerView, newState: Int) {
 //                super.onScrollStateChanged(recyclerView, newState)
@@ -129,16 +132,21 @@ class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>(
     fun setAdapter(list: List<CollectionList>) {
 
 
-
         adapter?.addData(list)
         adapter?.setOnItemClickListener { adapter, view, position ->
 
 
             vm.list.value?.get(position)?.id
 
-            UiSwitch.bundle(context, TibetanDetailsActivity::class.java,
-                    B().putString("id", vm.list.value?.get(position)?.id)
-                            .ok())
+            if (vm.list.value?.get(position)?.issue_mode == 1) {
+                UiSwitch.bundle(context, TibetanDetailsActivity::class.java,
+                        B().putString("id", vm.list.value?.get(position)?.id)
+                                .ok())
+            } else {
+                UiSwitch.bundle(context, LotsDetailsActivity::class.java,
+                        B().putString("id", vm.list.value?.get(position)?.id)
+                                .ok())
+            }
         }
 
 
@@ -159,4 +167,11 @@ class RecommendFragment : MBFragment<RecommendVModel, FragmentRecommendBinding>(
     override fun title(): String? {
         return null
     }
+
+    @Subscribe(tags = [Tag(ConfigRx.REFRESH_HOME_LIST)])
+    fun setRefreshList(type: String) {
+
+        vm.toGetCollectionList()
+
+    }
 }

+ 3 - 1
app/src/main/java/com/hdl/xl/model/CollectionList.kt

@@ -4,13 +4,15 @@ import com.ysnows.base.inter.IModel
 
 /**
  * 首页精选数据-精选推荐
+ * issue_mode  1普通发行2抽签发行
  */
 data class CollectionList(var id:String, var cover :String, var name:String,
                           var type:String, var label :String, var price:String,
                           var inventory:String, var now_inventory :String, var state:String,
                           var sell_time:String, var advance_info :String, var auth_name:String,
-                          var auth_img:String, var issue_mode :String, var apply_st :String,
+                          var auth_img:String, var apply_st :String,
                           var before_time :String, var is_remind :Boolean,
+                          var issue_mode:Int,
                           ) : IModel {
 
 

+ 19 - 0
app/src/main/java/com/hdl/xl/model/PartackBean.kt

@@ -0,0 +1,19 @@
+package com.hdl.xl.model
+
+import com.ysnows.base.inter.IModel
+
+/**
+ *on 2022/8/2
+ */
+data class PartackBean(
+        var list:List<ListBean>
+                      ):IModel {
+                          data class ListBean(
+                                  var id:String, var sell_time:String, var code:String,
+                                  var create_at:String, var is_ballot:String, var coll_id:String,
+                                  var cover:String, var price:String, var user_name:String,
+                                  var headimg:String
+                          ):IModel{
+
+                          }
+}

+ 13 - 0
app/src/main/java/com/hdl/xl/model/RosterBean.kt

@@ -0,0 +1,13 @@
+package com.hdl.xl.model
+
+import com.ysnows.base.inter.IModel
+
+/**
+ *on 2022/8/2
+ */
+data class RosterBean(var id:String,var sell_time:String,var code:String,
+                      var create_at:String,var is_ballot:String,var coll_id:String,
+                      var cover:String,var price:String,var user_name:String,
+                      var headimg:String
+                      ):IModel {
+}

+ 2 - 0
app/src/main/java/com/hdl/xl/model/TibetaDetails.kt

@@ -16,5 +16,7 @@ data class TibetaDetails(var auth_name:String, var auth_img:String, var buy_coun
                          var price:String, var sell_time:String, var share_img:String,
                          var state:Int, var warm_prompt:String,var inventory:String,
                          var now_inventory:String,var is_remind:Boolean,
+                         var issue_mode:Int,var all_apply:String,var apply_st:String,
+                         var apply_end:String,var has_apply:Int,var ballot_status:Int
 ): IModel {
 }

+ 3 - 2
app/src/main/java/com/hdl/xl/model/bean/PayTypeBen.kt

@@ -4,9 +4,10 @@ package com.hdl.xl.model.bean
  *Created by shihuiyun
  *on 2020/9/9
  * //1支付宝 2微信  //默认支付宝  3钱包
- * num:数量
+ * num:总数量
+ * money:总钱数
  */
-open class PayTypeBen (var choseType: Int, var num: String,var second_password:String? )
+open class PayTypeBen (var choseType: Int, var num: String, var money:String)
 
 
 

+ 1 - 1
app/src/main/java/com/hdl/xl/utils/PopuBuyIntegralUtils.kt

@@ -104,7 +104,7 @@ object PopuBuyIntegralUtils {
                 PopuSureUtils.show(context,view, object :ChoiceData{
                     override fun onRestuse(password: String?) {
                        //todo:
-                        var payTypeBen= PayTypeBen(choseType,all_nums,password)
+                        var payTypeBen= PayTypeBen(choseType,all_nums,password!!)
 
                         RxBus.get().post(ConfigRx.CHOSE_PAY_TYPE,payTypeBen)
 

+ 19 - 11
app/src/main/java/com/hdl/xl/utils/PopuBuyUtils.kt

@@ -20,17 +20,18 @@ import com.hdl.xl.R
 import com.hdl.xl.config.ConfigRx
 import com.hdl.xl.inte.ChoiceData
 import com.hdl.xl.model.bean.PayTypeBen
+import com.qmuiteam.qmui.widget.popup.QMUIFullScreenPopup
 
 
 /***
  *on 2020/9/21
  */
 object PopuBuyUtils {
-
+    var mNormalPopup: QMUIFullScreenPopup? = null
 
     fun show(context: Context, cover: String?, name: String?, price: String?, view: View) {
 
-        var mNormalPopup = QMUIPopups.fullScreenPopup(context)
+         mNormalPopup = QMUIPopups.fullScreenPopup(context)
         val builder: QMUISkinValueBuilder = QMUISkinValueBuilder.acquire()
         val frameLayout = QMUIFrameLayout(context)
         //自定义布局
@@ -193,11 +194,14 @@ object PopuBuyUtils {
             //输入支付密码
             if(choseType==3||choseType==4){//钱包支付
 
-                var payTypeBen= PayTypeBen(choseType,all_nums,"")
+
+
+                var money=all_nums.toInt()*price!!.toDouble()
+                var payTypeBen= PayTypeBen(choseType,all_nums,money.toString())
 
                 RxBus.get().post(ConfigRx.CHOSE_PAY_TYPE,payTypeBen)
 
-                mNormalPopup.dismiss()
+              //  mNormalPopup?.dismiss()
 
 //                PopuSureUtils.show(context,view, object :ChoiceData{
 //                    override fun onRestuse(password: String?) {
@@ -222,10 +226,10 @@ object PopuBuyUtils {
         }
 
         butCancel.onClick {
-            mNormalPopup.dismiss()
+            mNormalPopup?.dismiss()
         }
         ll.onClick {
-            mNormalPopup.dismiss()
+            mNormalPopup?.dismiss()
         }
 
         builder.release();
@@ -239,17 +243,21 @@ object PopuBuyUtils {
         frameLayout.addView(layout, lp)
 
 
-        mNormalPopup.addView(frameLayout)
-        mNormalPopup.onDismiss() {
+        mNormalPopup?.addView(frameLayout)
+        mNormalPopup?.onDismiss() {
         }
 
-        mNormalPopup.dismissIfOutsideTouch(false)
-        mNormalPopup.animStyle(QMUIPopup.ANIM_GROW_FROM_CENTER)
-        mNormalPopup.show(view)
+        mNormalPopup?.dismissIfOutsideTouch(false)
+        mNormalPopup?.animStyle(QMUIPopup.ANIM_GROW_FROM_CENTER)
+        mNormalPopup?.show(view)
 
 
     }
 
+    fun setDisMiss(){
+        mNormalPopup?.dismiss()
+    }
+
 
 
 

+ 81 - 0
app/src/main/java/com/hdl/xl/utils/PopuPaySuesstils.kt

@@ -0,0 +1,81 @@
+package com.hdl.xl.utils
+
+import android.content.Context
+import android.text.TextUtils
+import android.view.LayoutInflater
+import android.view.View
+import android.widget.*
+import com.qmuiteam.qmui.kotlin.onClick
+import com.qmuiteam.qmui.layout.QMUIFrameLayout
+import com.qmuiteam.qmui.skin.QMUISkinValueBuilder
+import com.qmuiteam.qmui.util.QMUIDisplayHelper
+import com.qmuiteam.qmui.widget.popup.QMUIPopup
+import com.qmuiteam.qmui.widget.popup.QMUIPopups
+import com.ysnows.base.widget.DelEditText
+import com.hdl.xl.R
+import com.hdl.xl.inte.ChoiceData
+import com.hdl.xl.model.MyOrderListDetail
+import com.hdl.xl.model.TibetaDetails
+
+/**
+ *Created by shihuiyun
+ *on 2020/9/21
+ */
+object PopuPaySuesstils {
+
+    fun show(context: Context, view: View,bean: MyOrderListDetail) {
+
+        var mNormalPopup = QMUIPopups.fullScreenPopup(context)
+        val builder: QMUISkinValueBuilder = QMUISkinValueBuilder.acquire()
+        val frameLayout = QMUIFrameLayout(context)
+        //自定义布局
+        val layoutInflater = context?.getSystemService(Context.LAYOUT_INFLATER_SERVICE) as LayoutInflater
+        var layout = layoutInflater.inflate(R.layout.popu_suess_pay, null)
+
+        val tvMoney: TextView = layout.findViewById(R.id.tv_money)
+        val tvNumber: TextView = layout.findViewById(R.id.tv_number)
+        val tvTime: TextView = layout.findViewById(R.id.tv_time)
+        val tvPay: TextView = layout.findViewById(R.id.tv_pay)
+        val tvSure: TextView = layout.findViewById(R.id.tv_sure)
+
+        tvMoney.text=bean.pay_price
+        tvNumber.text="订单编号:"+bean.order_no
+        tvTime.text="下单时间:"+bean.create_at
+
+        if(bean.pay_type == "wallet"){
+            tvPay.text="支付方式:钱包余额"
+        }
+        if(bean.pay_type == "sd"){
+            tvPay.text="快捷支付"
+        }
+
+        tvSure.onClick {
+
+            mNormalPopup.dismiss()
+        }
+
+
+        builder.release();
+
+
+        val size = QMUIDisplayHelper.getScreenWidth(context)
+        val height = QMUIDisplayHelper.getScreenHeight(context)
+
+
+        val lp: FrameLayout.LayoutParams = FrameLayout.LayoutParams(size,
+                height)
+        frameLayout.addView(layout, lp)
+
+        mNormalPopup.addView(frameLayout)
+        mNormalPopup.onDismiss() {
+        }
+
+        mNormalPopup.dismissIfOutsideTouch(false)
+        mNormalPopup.animStyle(QMUIPopup.ANIM_GROW_FROM_CENTER)
+        mNormalPopup.show(view)
+
+
+    }
+
+
+}

+ 49 - 0
app/src/main/java/com/hdl/xl/utils/TimeUtils.kt

@@ -0,0 +1,49 @@
+package com.hdl.xl.utils
+
+import android.util.Log
+import java.text.SimpleDateFormat
+import java.util.*
+
+/**
+ *on 2022/8/2
+ */
+object  TimeUtils {
+
+    /**
+     * 判断2个时间大小
+     * yyyy-MM-dd HH:mm 格式(自己可以修改成想要的时间格式)
+     * @param startTime
+     * @param endTime
+     * @return
+     */
+    fun timeCompare(startTime: String?, endTime: String?): Int {
+        var i = 0
+        //注意:传过来的时间格式必须要和这里填入的时间格式相同
+        val dateFormat = SimpleDateFormat("yyyy-MM-dd HH:mm:ss")
+        try {
+            val date1: Date = dateFormat.parse(startTime) //开始时间
+            val date2: Date = dateFormat.parse(endTime) //结束时间
+            // 1 结束时间小于开始时间 2 开始时间与结束时间相同 3 结束时间大于开始时间
+            if (date2.time < date1.time) {
+                //结束时间小于开始时间
+                i = 1
+            } else if (date2.time === date1.time) {
+                //开始时间与结束时间相同
+                i = 2
+            } else if (date2.time > date1.time) {
+                //结束时间大于开始时间
+                i = 3
+            }
+        } catch (e: Exception) {
+            Log.e("-shy-", "shy="+e )
+        }
+        Log.e("-shy-", "shy=i="+i )
+        return i
+    }
+
+    fun getTime():String{
+        val sDateFormat = SimpleDateFormat("yyyy-MM-dd   HH:mm:ss")
+        return sDateFormat.format(Date())
+    }
+
+}

+ 24 - 0
app/src/main/java/com/hdl/xl/utils/net/ApiService.kt

@@ -478,6 +478,30 @@ interface ApiService {
     @GET("Synthetic/synList")
     suspend fun synList(): Resp<List<SynList>>
 
+    /**
+     * 参与人数
+     * @return
+     */
+
+    @GET("Collect_draw/getCollectApplyList")
+    suspend fun getCollectApplyList(
+            @Query("coll_id") coll_id: String?,
+            @Query("is_ballot") is_ballot: String?,
+            @Query("page_num") page_num: Int?,
+            @Query("page") page: Int?
+    ): PageResp<RosterBean>
+
+
+    @GET("Collect_draw/getCollectApplyList")
+    suspend fun getCollectApplyListTo(
+            @Query("coll_id") coll_id: String?,
+            @Query("is_ballot") is_ballot: String?,
+            @Query("page_num") page_num: Int?,
+            @Query("page") page: Int?
+    ): Resp<PartackBean>
+
+
+
 
 
 

+ 6 - 0
app/src/main/java/com/hdl/xl/vmodel/HomeFirstVModel.kt

@@ -16,7 +16,9 @@ import com.ysnows.base.utils.UiSwitch
 import com.hdl.xl.activity.CertificationActivity
 import com.hdl.xl.activity.LoginActivity
 import com.hdl.xl.activity.MsgActivity
+import com.hdl.xl.config.ConfigRx
 import com.hdl.xl.model.MessageListBean
+import com.hwangjr.rxbus.RxBus
 import kotlinx.coroutines.launch
 
 /**
@@ -58,7 +60,11 @@ open class HomeFirstVModel(application: Application) : BViewModel<BRepository>(a
 
     override fun firstReq() {
         super.firstReq()
+        RxBus.get().post(ConfigRx.REFRESH_HOME_LIST,"")
+
         toGetBanner()
+        getMessageList()
+
     }
 
     fun toCertification() {

+ 245 - 0
app/src/main/java/com/hdl/xl/vmodel/LotsDetailsVModel.kt

@@ -0,0 +1,245 @@
+package com.hdl.xl.vmodel
+
+import android.app.Activity
+import android.app.Application
+import android.content.ClipData
+import android.content.ClipboardManager
+import android.content.Context
+import android.graphics.Color
+import android.text.TextUtils
+import android.view.View
+import android.widget.LinearLayout
+import androidx.lifecycle.MutableLiveData
+import androidx.lifecycle.viewModelScope
+import com.hdl.xl.R
+import com.hdl.xl.activity.ArticleDetailActivity
+import com.hdl.xl.activity.PartakeActivity
+import com.hdl.xl.activity.RosterActivity
+import com.hdl.xl.model.PayOrder
+import com.ysnows.base.base.BRepository
+import com.ysnows.base.base.BViewModel
+import com.hdl.xl.model.TibetaDetails
+import com.hdl.xl.utils.PopuBuyUtils
+import com.hdl.xl.utils.PopuDownWxUtils
+import com.hdl.xl.utils.TimeUtils
+import com.hdl.xl.utils.net.NetEngine
+import com.ysnows.base.utils.B
+import com.ysnows.base.utils.UiSwitch
+import kotlinx.coroutines.launch
+
+class LotsDetailsVModel(application: Application) : BViewModel<BRepository>(application)  {
+    var ll: LinearLayout? = null
+
+    var link= MutableLiveData<String>()
+    var linkName= MutableLiveData<String>()
+
+    var id:String?=null
+
+    var data= MutableLiveData<TibetaDetails>()
+    //倒计时
+    var isUp = true
+    var time = MutableLiveData<String>()
+
+    var  bean=MutableLiveData<PayOrder>()
+
+    var  orderNo=MutableLiveData<String>()
+
+    var  is_remind=MutableLiveData<Boolean>()
+
+
+    fun isHasApply(has_apply:Int?,sell_time:String?):Int{
+
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) == 3) {//抽签结束了
+            return View.GONE
+        }
+        if(has_apply==1){//已经报名
+            return View.VISIBLE
+        }
+        return View.GONE
+    }
+
+    fun isShowEnd(state:Int?,sell_time:String?):Int{//已经结束
+
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) == 3) {
+            return View.VISIBLE
+        }
+
+        if(state == 3){
+            return View.VISIBLE
+        }
+        return View.GONE
+
+    }
+
+
+    fun isShowIng(state:Int?,sell_time:String?,has_apply:Int?):Int{//立即购买
+
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) == 3) {
+            return View.GONE
+        }
+        if(has_apply==1){//已经报名
+            return View.GONE
+        }
+        if(state == 1){
+            return View.VISIBLE
+        }
+        return View.GONE
+
+    }
+
+    fun isShowStart(state:Int?,sell_time:String?):Int{//即将开始
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) == 3) {
+            return View.GONE
+        }
+        if(state==2){
+            return View.VISIBLE
+        }
+        return View.GONE
+
+
+    }
+    fun toShowMing(state:Int?,sell_time:String?):Int{//中奖名单
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) == 3) {
+            return View.VISIBLE
+        }
+        if(state!=2){
+            return View.VISIBLE
+        }
+        return View.GONE
+
+    }
+
+    fun isShowNo(state:Int?,ballot_status:Int?,sell_time:String?):Int{//未中签
+
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) != 3&&state==1&&ballot_status==0) {//没结束
+            return View.VISIBLE
+        }
+        if (TimeUtils.timeCompare(sell_time, TimeUtils.getTime()) == 3&&ballot_status==0) {//已结束
+            return View.VISIBLE
+        }
+
+        return View.GONE
+    }
+
+
+
+
+    fun toCopy(){
+        if(TextUtils.isEmpty(link.value)){
+            toast("合约地址为空")
+            return
+        }
+
+        val cm: ClipboardManager? = repository().context?.getSystemService(Context.CLIPBOARD_SERVICE) as ClipboardManager?
+        val mClipData = ClipData.newPlainText("Label",link.value )
+        cm?.setPrimaryClip(mClipData)
+        toast("文字已复制到粘贴板")
+    }
+
+    fun toClose(){
+
+        (repository().context as Activity).finish()
+    }
+
+    fun getInfo(){
+        viewModelScope.launch {
+            var it=repository().lreq { NetEngine.service.CollectionDetail(id) }
+            if(it.ok()){
+
+                data.value=it.data
+                is_remind.value=it.data?.is_remind
+
+            }
+
+        }
+    }
+    var popuBuyUtils:PopuBuyUtils?=null
+
+    fun  toBuy(view :View){//支付弹框
+        popuBuyUtils= PopuBuyUtils
+        popuBuyUtils?.show(repository().context!!, data.value?.cover,data.value?.name,data.value?.price, view)
+
+     // PopuBuyUtils.show(repository().context!!, data.value?.cover,data.value?.name,data.value?.price, view)
+    }
+
+    fun getUrl() {
+
+        toShareCode(data.value?.cover)
+    }
+
+
+    fun toShareCode(shareUrl: String?) {
+        if (TextUtils.isEmpty(shareUrl)) {
+            return
+        }
+        PopuDownWxUtils.show(repository().context!!,
+                shareUrl!!,data.value?.name,data.value?.id,
+                "https://xlapi.xiangliannft.com/h5/pages/index/goodsinfo",
+                ll!!,repository().context!!.contentResolver)
+
+       // PopuShareWxUtils.show(repository().context!!, shareUrl!!, ll!!,repository().context!!.contentResolver)
+    }
+
+    fun getCertificate(){
+        viewModelScope.launch {
+            var it=repository().lreq { NetEngine.service.certificate() }
+            if(it.ok()){
+                link.value=it.data?.link
+                linkName.value=it.data?.name
+            }
+        }
+    }
+
+    //设置购买提醒
+    fun toBuyTime(){
+          viewModelScope.launch {
+
+              var it=repository().lreq { NetEngine.service.setRemind(data.value?.id) }
+              if(it.ok(true)){
+                  //刷新
+                  is_remind.value=true
+              }
+
+          }
+
+
+    }
+
+    fun toPayOrder(order_no:String?,from:String?){
+        viewModelScope.launch {
+            var it=repository().lreq { NetEngine.service.payOrder(order_no,from) }
+            if(it.code==0){
+                toast(it.msg)
+                return@launch
+            }
+            if(it.ok(true)){
+                if("sd" == from) {
+                    bean.value = it.data
+
+                }else{
+                    orderNo.value =order_no
+                }
+                popuBuyUtils?.setDisMiss()
+
+            }
+        }
+
+    }
+
+    fun toLookRoster(){//中签名单
+
+        UiSwitch.bundle(repository().context, RosterActivity::class.java,
+                B().putString("coll_id",id)
+                        .putString("is_ballot","1")
+                        .ok())
+    }
+
+    fun toLookPeople(){
+
+        UiSwitch.bundle(repository().context, PartakeActivity::class.java,
+                B().putString("coll_id",id)
+                        .putString("is_ballot","1")
+                        .ok())
+    }
+
+}

+ 44 - 0
app/src/main/java/com/hdl/xl/vmodel/PartakeVModel.kt

@@ -0,0 +1,44 @@
+package com.hdl.xl.vmodel
+
+import android.app.Activity
+import android.app.Application
+import android.text.TextUtils
+import androidx.databinding.Bindable
+import androidx.lifecycle.MutableLiveData
+import androidx.lifecycle.viewModelScope
+import com.hwangjr.rxbus.RxBus
+import com.ysnows.base.base.BRepository
+import com.ysnows.base.base.BViewModel
+import com.hdl.xl.BR
+import com.hdl.xl.activity.AccountSafeActivity
+import com.hdl.xl.activity.UpCellActivity
+import com.hdl.xl.config.ConfigRx
+import com.hdl.xl.model.MyCollection
+import com.hdl.xl.model.PartackBean
+import com.hdl.xl.utils.net.NetEngine
+import com.ysnows.base.utils.UiSwitch
+import kotlinx.coroutines.launch
+
+class PartakeVModel(application: Application) : BViewModel<BRepository>(application)  {
+    var is_ballot:String?=""
+    var coll_id:String?="1"
+
+    var list= MutableLiveData<List<PartackBean.ListBean>>()
+
+
+
+    fun getInfo(){
+        viewModelScope.launch {
+            var it=NetEngine.service.getCollectApplyListTo(coll_id,is_ballot,10,1)
+
+              if(it.ok()){
+                  list.value=it.data?.list
+              }
+
+        }
+    }
+
+
+
+
+}

+ 33 - 0
app/src/main/java/com/hdl/xl/vmodel/RosterVModel.kt

@@ -0,0 +1,33 @@
+package com.hdl.xl.vmodel
+
+import android.app.Application
+import android.graphics.Color
+import androidx.lifecycle.viewModelScope
+import com.hwangjr.rxbus.RxBus
+import com.hdl.xl.config.ConfigRx
+import com.hdl.xl.utils.net.NetEngine
+import com.ysnows.base.base.BRRepository
+import com.ysnows.base.base.BRViewModel
+import com.ysnows.base.net.IResp
+import kotlinx.coroutines.launch
+
+/**
+ *Created by shihuiyun
+ *on 2020/9/25
+ */
+class RosterVModel(application: Application) : BRViewModel<BRRepository>(application) {
+
+
+    var is_ballot:String?=""
+    var coll_id:String?="1"
+
+
+
+
+
+    override fun apiFunc(): suspend () -> IResp<*> {
+        return { NetEngine.service.getCollectApplyList(coll_id,is_ballot,10,repository().page) }
+    }
+
+
+}

+ 28 - 7
app/src/main/java/com/hdl/xl/vmodel/TibetanDetailsVModel.kt

@@ -10,6 +10,7 @@ import android.view.View
 import android.widget.LinearLayout
 import androidx.lifecycle.MutableLiveData
 import androidx.lifecycle.viewModelScope
+import com.hdl.xl.model.MyOrderListDetail
 import com.hdl.xl.model.PayOrder
 import com.ysnows.base.base.BRepository
 import com.ysnows.base.base.BViewModel
@@ -21,6 +22,7 @@ import kotlinx.coroutines.launch
 
 class TibetanDetailsVModel(application: Application) : BViewModel<BRepository>(application)  {
     var ll: LinearLayout? = null
+    var id:String?=null
 
     var link= MutableLiveData<String>()
     var linkName= MutableLiveData<String>()
@@ -33,11 +35,12 @@ class TibetanDetailsVModel(application: Application) : BViewModel<BRepository>(a
 
     var  bean=MutableLiveData<PayOrder>()
 
-    var  orderNo=MutableLiveData<String>()
 
-    var  is_remind=MutableLiveData<Boolean>()
 
+    var  is_remind=MutableLiveData<Boolean>()
 
+    //支付成功后是否显示弹框
+    var myBean=MutableLiveData<MyOrderListDetail>()
 
 
     fun toCopy(){
@@ -57,7 +60,7 @@ class TibetanDetailsVModel(application: Application) : BViewModel<BRepository>(a
         (repository().context as Activity).finish()
     }
 
-    fun getInfo(id:String){
+    fun getInfo(){
         viewModelScope.launch {
             var it=repository().lreq { NetEngine.service.CollectionDetail(id) }
             if(it.ok()){
@@ -69,9 +72,13 @@ class TibetanDetailsVModel(application: Application) : BViewModel<BRepository>(a
 
         }
     }
+    var popuBuyUtils:PopuBuyUtils?=null
 
     fun  toBuy(view :View){//支付弹框
-        PopuBuyUtils.show(repository().context!!, data.value?.cover,data.value?.name,data.value?.price, view)
+        popuBuyUtils= PopuBuyUtils
+        popuBuyUtils?.show(repository().context!!, data.value?.cover,data.value?.name,data.value?.price, view)
+
+     // PopuBuyUtils.show(repository().context!!, data.value?.cover,data.value?.name,data.value?.price, view)
     }
 
     fun getUrl() {
@@ -126,17 +133,31 @@ class TibetanDetailsVModel(application: Application) : BViewModel<BRepository>(a
                 return@launch
             }
             if(it.ok(true)){
-                if("sd" == from) {
+                popuBuyUtils?.setDisMiss()
+                if("sd" == from) {//杉德支付
                     bean.value = it.data
-                }else{
-                    orderNo.value =order_no
 
+                }else{
+                    //刷新数据
+                    getMyOrder(order_no)
                 }
 
+
             }
         }
 
     }
 
+    fun getMyOrder(order_no:String?){
+        viewModelScope.launch {
+            var it = repository().lreq { NetEngine.service.setMyOrderListDetail(order_no, "2") }
+            if (it.ok()) {
+                myBean.value = it.data
+            }
+
+        }
+
+    }
+
 
 }

BIN
app/src/main/res/drawable-xxhdpi/ct_chou_one.png


BIN
app/src/main/res/drawable-xxhdpi/ct_chou_three.png


BIN
app/src/main/res/drawable-xxhdpi/ct_chou_two.png


BIN
app/src/main/res/drawable-xxhdpi/ct_jilu.png


+ 810 - 0
app/src/main/res/layout/activity_lots_details.xml

@@ -0,0 +1,810 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    xmlns:tools="http://schemas.android.com/tools">
+
+    <data>
+
+        <variable
+            name="vm"
+            type="com.hdl.xl.vmodel.LotsDetailsVModel" />
+
+        <import type="android.view.View" />
+
+    </data>
+
+    <LinearLayout
+        android:id="@+id/ll"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:background="@color/c_bg"
+        android:orientation="vertical">
+
+
+        <FrameLayout
+            android:layout_width="match_parent"
+            android:layout_height="0dp"
+            android:layout_weight="1">
+
+
+            <com.hdl.xl.view.MyScrollView
+                android:id="@+id/scroll"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:scrollbars="none">
+
+
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="match_parent"
+                    android:orientation="vertical">
+
+
+                    <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="wrap_content"
+                        android:layout_marginStart="15dp"
+                        android:layout_marginTop="22dp"
+                        android:layout_marginEnd="15dp"
+                        android:orientation="vertical"
+                        android:paddingStart="20dp"
+                        android:paddingTop="20dp"
+                        android:paddingEnd="20dp"
+                        android:paddingBottom="23dp"
+                        app:qmui_backgroundColor="#B3444444"
+                        app:qmui_borderColor="#B3979797"
+                        app:qmui_borderWidth="@dimen/dp_1"
+                        app:qmui_radius="20sp">
+
+
+                        <FrameLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content">
+
+
+                            <ImageView
+                                android:id="@+id/image_view"
+                                android:layout_width="match_parent"
+                                android:layout_height="305dp"
+                                android:scaleType="centerCrop"
+                                android:src="@drawable/bg_need_error" />
+
+
+                            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundButton
+                                android:layout_width="100dp"
+                                app:qmui_radius="17dp"
+                                android:onClick="@{v->vm.toLookRoster()}"
+                                app:qmui_borderColor="@color/translucent"
+                                app:qmui_backgroundColor="#66000000"
+                                android:textColor="@color/white"
+                                android:visibility="@{vm.toShowMing(vm.data.state,vm.data.sell_time)}"
+                                android:text="查看中签名单"
+                                android:textSize="13sp"
+                                android:layout_gravity="bottom|right"
+                                android:layout_marginBottom="10dp"
+                                android:layout_marginEnd="10dp"
+                                android:layout_height="34dp"/>
+
+
+                        </FrameLayout>
+
+                        <LinearLayout
+                            android:layout_width="match_parent"
+                            android:orientation="horizontal"
+                            android:layout_marginTop="16dp"
+                            android:layout_height="wrap_content">
+
+                            <TextView
+                                android:layout_width="0dp"
+                                android:layout_weight="1"
+                                android:layout_height="wrap_content"
+                                android:text="@{vm.data.name}"
+                                android:textColor="@color/white"
+                                android:textSize="22sp"
+                                android:textStyle="bold" />
+
+                            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                                android:layout_width="wrap_content"
+                                app:qmui_borderWidth="@dimen/dp_1"
+                                app:qmui_radius="2dp"
+                                app:qmui_borderColor="#999999"
+                                android:onClick="@{v->vm.toLookPeople()}"
+                                android:paddingStart="7dp"
+                                android:paddingEnd="7dp"
+                                android:paddingTop="2dp"
+                                android:paddingBottom="@dimen/dp_2"
+                                android:layout_height="wrap_content">
+                                <TextView
+                                    android:text="@{vm.data.all_apply+`人参与`}"
+                                    android:textSize="12sp"
+                                    android:textColor="@color/white"
+                                    android:layout_width="wrap_content"
+                                    android:layout_height="wrap_content"/>
+
+                            </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+                        </LinearLayout>
+
+
+                        <LinearLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_gravity="center_horizontal"
+                            android:layout_marginTop="10dp"
+                           >
+
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:background="@drawable/bg_three_but"
+                                android:paddingStart="9dp"
+                                android:paddingTop="2dp"
+                                android:paddingEnd="9dp"
+                                android:paddingBottom="2dp"
+                                android:text="发售量"
+                                android:textColor="#333333"
+                                android:textSize="10sp" />
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:layout_marginEnd="12dp"
+                                android:background="@drawable/bg_kuang_blue"
+                                android:hint="100份"
+                                android:paddingStart="2dp"
+                                android:paddingTop="2dp"
+                                android:paddingEnd="2dp"
+                                android:paddingBottom="2dp"
+                                android:text="@{vm.data.inventory+`份`}"
+                                android:textColor="#54D7E9"
+                                android:textColorHint="#54D7E9"
+                                android:textSize="@dimen/dp_10" />
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:background="@drawable/bg_three_but"
+                                android:paddingStart="2dp"
+                                android:paddingTop="2dp"
+                                android:paddingEnd="2dp"
+                                android:paddingBottom="2dp"
+                                android:text="流通量"
+                                android:textColor="#333333"
+                                android:textSize="10sp" />
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:layout_marginEnd="12dp"
+                                android:background="@drawable/bg_kuang_blue"
+                                android:hint="100份"
+                                android:paddingStart="2dp"
+                                android:paddingTop="2dp"
+                                android:paddingEnd="2dp"
+                                android:paddingBottom="2dp"
+                                android:text="@{vm.data.now_inventory+`份`}"
+                                android:textColor="#54D7E9"
+                                android:textColorHint="#54D7E9"
+                                android:textSize="@dimen/dp_10" />
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:background="@drawable/bg_three_but"
+                                android:paddingStart="2dp"
+                                android:paddingTop="2dp"
+                                android:paddingEnd="2dp"
+                                android:paddingBottom="2dp"
+                                android:text="限购量"
+                                android:textColor="#333333"
+                                android:textSize="10sp" />
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:background="@drawable/bg_kuang_blue"
+                                android:hint="100份"
+                                android:paddingStart="2dp"
+                                android:paddingTop="2dp"
+                                android:paddingEnd="2dp"
+                                android:paddingBottom="2dp"
+                                android:text="@{vm.data.buy_count+`份`}"
+                                android:textColor="#54D7E9"
+                                android:textColorHint="#54D7E9"
+                                android:textSize="@dimen/dp_10" />
+
+                        </LinearLayout>
+
+                        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                            android:layout_width="match_parent"
+                            android:layout_marginTop="20dp"
+                            app:qmui_borderColor="@color/white"
+                            app:qmui_backgroundColor="#333333"
+                            app:qmui_radius="3dp"
+                            android:paddingStart="10dp"
+                            android:paddingEnd="10dp"
+                            android:layout_height="wrap_content">
+                            
+                            <ImageView
+                                android:src="@drawable/ct_jilu"
+                                android:layout_width="14dp"
+                                android:layout_height="14dp"/>
+                            <TextView
+                                android:text="@{`报名:`+vm.data.apply_st+`至`+vm.data.apply_end}"
+                                android:textSize="10sp"
+                                android:layout_marginStart="5dp"
+                                android:textColor="@color/white"
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"/>
+
+
+                        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+                    </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+                    <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="wrap_content"
+                        android:layout_marginStart="15dp"
+                        android:layout_marginTop="12dp"
+                        android:layout_marginEnd="15dp"
+                        android:orientation="vertical"
+                        android:paddingStart="10dp"
+                        android:paddingTop="10dp"
+                        android:paddingEnd="10dp"
+                        android:paddingBottom="15dp"
+                        app:qmui_backgroundColor="#141414"
+                        app:qmui_borderColor="#141414"
+                        app:qmui_borderWidth="@dimen/dp_1"
+                        app:qmui_radius="16sp">
+
+                        <androidx.constraintlayout.widget.ConstraintLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:layout_marginStart="17dp"
+                                android:text="认证信息"
+                                android:textColor="@color/white"
+                                android:textSize="18sp"
+                                android:textStyle="bold"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+                            <ImageView
+                                android:id="@+id/img_tag"
+                                android:layout_width="22dp"
+                                android:layout_height="23dp"
+                                android:src="@drawable/ct_tags"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+
+                        </androidx.constraintlayout.widget.ConstraintLayout>
+
+
+                        <LinearLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="16dp"
+                            android:gravity="center_vertical"
+                            android:orientation="horizontal">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:text="区块链"
+                                android:textColor="#999999"
+                                android:textSize="13sp" />
+
+                            <TextView
+                                android:layout_width="match_parent"
+                                android:layout_height="wrap_content"
+                                android:gravity="right"
+                                android:text="@{vm.linkName}"
+                                android:textColor="@color/white"
+                                android:textSize="12sp" />
+
+
+                        </LinearLayout>
+
+                        <LinearLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="14dp"
+                            android:gravity="center_vertical"
+                            android:orientation="horizontal"
+                            android:visibility="gone"
+                            tools:visibility="visible">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:text="合约地址"
+                                android:textColor="#999999"
+                                android:textSize="12sp" />
+
+                            <TextView
+                                android:layout_width="0dp"
+                                android:layout_height="wrap_content"
+                                android:layout_marginStart="12dp"
+                                android:layout_marginEnd="6dp"
+                                android:layout_weight="1"
+                                android:gravity="right"
+                                android:text="@{vm.link}"
+                                android:textColor="@color/white"
+                                android:textSize="13sp" />
+
+                            <ImageView
+                                android:layout_width="17dp"
+                                android:layout_height="17dp"
+                                android:onClick="@{v->vm.toCopy()}"
+                                android:src="@drawable/ct_copy" />
+
+
+                        </LinearLayout>
+
+
+                    </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+                    <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="wrap_content"
+                        android:layout_marginStart="15dp"
+                        android:layout_marginTop="12dp"
+                        android:layout_marginEnd="15dp"
+                        android:orientation="vertical"
+                        android:paddingStart="10dp"
+                        android:paddingTop="10dp"
+                        android:paddingEnd="10dp"
+                        android:paddingBottom="12dp"
+                        app:qmui_backgroundColor="#141414"
+                        app:qmui_borderColor="#141414"
+                        app:qmui_borderWidth="@dimen/dp_1"
+                        app:qmui_radius="16sp">
+
+                        <androidx.constraintlayout.widget.ConstraintLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:layout_marginStart="17dp"
+                                android:text="藏品详情"
+                                android:textColor="@color/white"
+                                android:textSize="18sp"
+                                android:textStyle="bold"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+                            <ImageView
+                                android:layout_width="22dp"
+                                android:layout_height="23dp"
+                                android:src="@drawable/ct_tags"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+
+                        </androidx.constraintlayout.widget.ConstraintLayout>
+
+                        <androidx.appcompat.widget.AppCompatImageView
+                            android:id="@+id/img_deatils"
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="14dp"
+                            android:adjustViewBounds="true"
+                            android:scaleType="fitXY"
+                            android:src="@drawable/bg_need_error" />
+
+                        <LinearLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="15dp"
+                            android:gravity="center_vertical"
+                            android:orientation="horizontal">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:text="发行方"
+                                android:textColor="#999999"
+                                android:textSize="13sp" />
+
+                            <TextView
+                                android:layout_width="match_parent"
+                                android:layout_height="wrap_content"
+                                android:layout_marginEnd="14dp"
+                                android:gravity="right"
+                                android:text="@{vm.data.auth_name}"
+                                android:textColor="@color/white"
+                                android:textSize="13sp" />
+
+
+                        </LinearLayout>
+
+                        <LinearLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="14dp"
+                            android:gravity="center_vertical"
+                            android:orientation="horizontal">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:text="发行时间"
+                                android:textColor="#999999"
+                                android:textSize="13sp" />
+
+                            <TextView
+                                android:layout_width="match_parent"
+                                android:layout_height="wrap_content"
+                                android:layout_marginEnd="14dp"
+                                android:gravity="right"
+                                android:text="@{vm.data.sell_time}"
+                                android:textColor="@color/white"
+                                android:textSize="13sp" />
+
+
+                        </LinearLayout>
+
+
+                    </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+                    <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="wrap_content"
+                        android:layout_marginStart="15dp"
+                        android:layout_marginTop="12dp"
+                        android:layout_marginEnd="15dp"
+                        android:orientation="vertical"
+                        android:paddingStart="10dp"
+                        android:paddingTop="10dp"
+                        android:paddingEnd="10dp"
+                        android:paddingBottom="9dp"
+                        app:qmui_backgroundColor="#141414"
+                        app:qmui_borderColor="#141414"
+                        app:qmui_borderWidth="@dimen/dp_1"
+                        app:qmui_radius="16sp">
+
+                        <androidx.constraintlayout.widget.ConstraintLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:layout_marginStart="17dp"
+                                android:text="权益说明"
+                                android:textColor="@color/white"
+                                android:textSize="18sp"
+                                android:textStyle="bold"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+                            <ImageView
+                                android:layout_width="22dp"
+                                android:layout_height="23dp"
+                                android:src="@drawable/ct_tags"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+
+                        </androidx.constraintlayout.widget.ConstraintLayout>
+
+                        <TextView
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="6dp"
+                            android:text="@{vm.data.instructions}"
+                            android:textColor="#B5B5B5"
+                            android:textSize="11sp" />
+
+
+                    </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+                    <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                        android:layout_width="match_parent"
+                        android:layout_height="wrap_content"
+                        android:layout_marginStart="15dp"
+                        android:layout_marginTop="12dp"
+                        android:layout_marginEnd="15dp"
+                        android:orientation="vertical"
+                        android:paddingStart="10dp"
+                        android:paddingTop="10dp"
+                        android:paddingEnd="10dp"
+                        android:paddingBottom="9dp"
+                        app:qmui_backgroundColor="#141414"
+                        app:qmui_borderColor="#141414"
+                        app:qmui_borderWidth="@dimen/dp_1"
+                        app:qmui_radius="16sp">
+
+                        <androidx.constraintlayout.widget.ConstraintLayout
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content">
+
+                            <TextView
+                                android:layout_width="wrap_content"
+                                android:layout_height="wrap_content"
+                                android:layout_marginStart="17dp"
+                                android:text="购买须知"
+                                android:textColor="@color/white"
+                                android:textSize="18sp"
+                                android:textStyle="bold"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+                            <ImageView
+                                android:layout_width="22dp"
+                                android:layout_height="23dp"
+                                android:src="@drawable/ct_tags"
+                                app:layout_constraintLeft_toLeftOf="parent"
+                                app:layout_constraintTop_toTopOf="parent" />
+
+
+                        </androidx.constraintlayout.widget.ConstraintLayout>
+
+                        <TextView
+                            android:layout_width="match_parent"
+                            android:layout_height="wrap_content"
+                            android:layout_marginTop="6dp"
+                            android:text="@{vm.data.buy_notice}"
+                            android:textColor="#B5B5B5"
+                            android:textSize="11sp" />
+
+
+                    </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+                </LinearLayout>
+
+            </com.hdl.xl.view.MyScrollView>
+            <!--             滑动时候显示的   -->
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                android:id="@+id/qmll_one"
+                android:layout_width="match_parent"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:gravity="center"
+                android:visibility="@{vm.isShowStart(vm.data.state,vm.data.sell_time)}"
+                app:qmui_backgroundColor="#4D000000"
+                app:qmui_borderColor="#979797"
+                app:qmui_borderWidth="@dimen/dp_1"
+                app:qmui_radius="22dp"
+                android:layout_height="44dp">
+                <TextView
+                    android:text="中签公布时间:"
+                    android:textColor="@color/white"
+                    android:textSize="16sp"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"/>
+                <TextView
+                    android:text="@{vm.data.sell_time}"
+                    android:textColor="#39C0FB"
+                    android:textSize="16sp"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"/>
+
+            </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                android:id="@+id/qmll_two"
+                android:layout_width="match_parent"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+
+                android:visibility="@{vm.data.ballot_status==2?View.VISIBLE:View.GONE}"
+
+                android:gravity="center"
+                app:qmui_backgroundColor="#4D000000"
+                app:qmui_borderColor="#979797"
+                app:qmui_borderWidth="@dimen/dp_1"
+                app:qmui_radius="22dp"
+                android:layout_height="44dp">
+                <TextView
+                    android:text="未中签"
+                    android:textColor="#999999"
+                    android:textSize="16sp"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"/>
+
+
+            </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                android:id="@+id/qmll_three"
+                android:layout_width="match_parent"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:gravity="center"
+                android:visibility="@{vm.data.ballot_status==1?View.VISIBLE:View.GONE}"
+                app:qmui_backgroundColor="#4D000000"
+                app:qmui_borderColor="#979797"
+                app:qmui_borderWidth="@dimen/dp_1"
+                app:qmui_radius="22dp"
+                android:layout_height="44dp">
+                <TextView
+                    android:text="恭喜!您已中签"
+                    android:textColor="#999999"
+                    android:textSize="16sp"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"/>
+
+
+            </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+                android:layout_width="match_parent"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+
+                android:gravity="center"
+                android:visibility="@{vm.isShowNo(vm.data.state,vm.data.ballot_status,vm.data.sell_time)}"
+                app:qmui_backgroundColor="#4D000000"
+                app:qmui_borderColor="#979797"
+                app:qmui_borderWidth="@dimen/dp_1"
+                app:qmui_radius="22dp"
+                android:layout_height="44dp">
+                <TextView
+                    android:text="未参与抽签"
+                    android:textColor="#999999"
+                    android:textSize="16sp"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"/>
+
+
+            </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+        </FrameLayout>
+
+
+        <!--        参与成功-->
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="81dp"
+            android:visibility="@{vm.isHasApply(vm.data.has_apply,vm.data.sell_time)}"
+            android:orientation="horizontal"
+            >
+
+            <TextView
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="14dp"
+                android:layout_marginStart="16dp"
+                android:layout_weight="1"
+                android:text="@{`¥`+vm.data.price}"
+                android:textColor="@color/white"
+                android:textSize="30sp" />
+
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundButton
+                android:layout_width="180dp"
+                android:layout_height="40dp"
+                android:layout_marginStart="25dp"
+                android:layout_marginEnd="25dp"
+                android:layout_marginTop="6dp"
+                android:text="参与成功"
+                android:textColor="@color/white"
+                android:textSize="16sp"
+                app:qmui_backgroundColor="#666666"
+                app:qmui_borderColor="@color/translucent"
+                app:qmui_radius="14dp" />
+
+        </LinearLayout>
+
+        <!--        已结束-->
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="81dp"
+            android:visibility="@{vm.isShowEnd(vm.data.state,vm.data.sell_time)}"
+            android:orientation="horizontal"
+            >
+
+            <TextView
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="14dp"
+                android:layout_marginStart="16dp"
+                android:layout_weight="1"
+                android:text="@{`¥`+vm.data.price}"
+                android:textColor="@color/white"
+                android:textSize="30sp" />
+
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundButton
+                android:layout_width="180dp"
+                android:layout_height="40dp"
+                android:layout_marginStart="25dp"
+                android:layout_marginEnd="25dp"
+                android:layout_marginTop="6dp"
+                android:text="已结束"
+                android:textColor="@color/white"
+                android:textSize="16sp"
+                app:qmui_backgroundColor="#666666"
+                app:qmui_borderColor="@color/translucent"
+                app:qmui_radius="14dp" />
+
+        </LinearLayout>
+
+        <!--        立即参与-->
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="81dp"
+            android:orientation="horizontal"
+            android:visibility="@{vm.isShowIng(vm.data.state,vm.data.sell_time,vm.data.has_apply)}"
+            tools:visibility="visible">
+
+            <TextView
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="14dp"
+                android:layout_marginStart="16dp"
+                android:layout_weight="1"
+                android:text="@{`¥`+vm.data.price}"
+                android:textColor="@color/white"
+                android:textSize="30sp" />
+
+            <TextView
+                android:id="@+id/but_buy"
+                android:layout_width="180dp"
+                android:layout_height="40dp"
+                android:layout_marginTop="6dp"
+                android:layout_marginEnd="25dp"
+                android:background="@drawable/bg_logo_but"
+                android:gravity="center"
+                android:text="去支付"
+                android:textColor="#000000"
+                android:textSize="16sp" />
+
+
+        </LinearLayout>
+
+        <!--        未开始-->
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="81dp"
+            android:visibility="@{vm.isShowStart(vm.data.state,vm.data.sell_time)}"
+            android:orientation="horizontal"
+            >
+
+            <TextView
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="14dp"
+                android:layout_marginStart="16dp"
+                android:layout_weight="1"
+                android:text="@{`¥`+vm.data.price}"
+                android:textColor="@color/white"
+                android:textSize="30sp" />
+
+
+            <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundButton
+                android:layout_width="180dp"
+                android:layout_height="40dp"
+                android:layout_marginStart="25dp"
+                android:layout_marginEnd="25dp"
+                android:layout_marginTop="6dp"
+                android:text="未开始"
+                android:textColor="@color/white"
+                android:textSize="16sp"
+                app:qmui_backgroundColor="#666666"
+                app:qmui_borderColor="@color/translucent"
+                app:qmui_radius="14dp" />
+
+        </LinearLayout>
+
+
+
+    </LinearLayout>
+</layout>

+ 7 - 7
app/src/main/res/layout/activity_my_collect.xml

@@ -13,12 +13,12 @@
         android:background="@color/c_bg"
         android:orientation="vertical" >
 
-        <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
-            android:id="@+id/refresh_layout"
-            android:layout_width="match_parent"
-            android:layout_marginTop="@dimen/dp_12"
-            android:layout_marginStart="12dp"
-            android:layout_height="match_parent" >
+<!--        <androidx.swiperefreshlayout.widget.SwipeRefreshLayout-->
+<!--            android:id="@+id/refresh_layout"-->
+<!--            android:layout_width="match_parent"-->
+<!--            android:layout_marginTop="@dimen/dp_12"-->
+<!--            android:layout_marginStart="12dp"-->
+<!--            android:layout_height="match_parent" >-->
 
             <androidx.recyclerview.widget.RecyclerView
                 android:id="@+id/recycler_view"
@@ -28,7 +28,7 @@
                 app:spanCount="2"
                 tools:listitem="@layout/item_my_collect" />
 
-        </androidx.swiperefreshlayout.widget.SwipeRefreshLayout >
+<!--        </androidx.swiperefreshlayout.widget.SwipeRefreshLayout >-->
     </LinearLayout >
 
 </layout >

+ 43 - 0
app/src/main/res/layout/activity_partake.xml

@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:tools="http://schemas.android.com/tools"
+    xmlns:app="http://schemas.android.com/apk/res-auto">
+
+    <data>
+
+
+    </data>
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:background="@color/c_bg"
+        android:orientation="vertical">
+
+        <FrameLayout
+            android:layout_width="match_parent"
+            android:layout_marginTop="12dp"
+            android:layout_height="match_parent">
+
+
+            <androidx.recyclerview.widget.RecyclerView
+                android:id="@+id/recycler_view"
+                android:layout_width="match_parent"
+                android:layout_marginStart="15dp"
+                android:layout_height="match_parent"
+                app:layoutManager="androidx.recyclerview.widget.GridLayoutManager"
+                app:spanCount="6"
+                tools:listitem="@layout/item_partake" />
+
+            <com.hdl.xl.view.ListEmptyView
+                android:id="@+id/list_empty"
+                android:visibility="gone"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"/>
+
+
+        </FrameLayout>
+
+
+    </LinearLayout>
+</layout>

+ 31 - 0
app/src/main/res/layout/activity_roster.xml

@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    xmlns:tools="http://schemas.android.com/tools" >
+
+    <data >
+
+    </data >
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:background="@color/c_bg"
+        android:orientation="vertical" >
+
+        <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
+            android:id="@+id/refresh_layout"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent" >
+
+            <androidx.recyclerview.widget.RecyclerView
+                android:id="@+id/recycler_view"
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
+                tools:listitem="@layout/item_roster" />
+
+        </androidx.swiperefreshlayout.widget.SwipeRefreshLayout >
+    </LinearLayout >
+
+</layout >

+ 387 - 340
app/src/main/res/layout/activity_setting.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
-<layout xmlns:app="http://schemas.android.com/apk/res-auto"
-    xmlns:tools="http://schemas.android.com/tools"
-    xmlns:android="http://schemas.android.com/apk/res/android">
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    xmlns:tools="http://schemas.android.com/tools">
 
     <data>
 
@@ -20,359 +20,406 @@
         android:orientation="vertical">
 
 
-        <LinearLayout
+        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
             android:layout_width="match_parent"
-            android:layout_height="50dp"
+            android:layout_height="100dp"
             android:layout_marginTop="@dimen/dp_12"
-            android:background="#1B1A1B"
             android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:onClick="@{v->vm.toMyInfo()}"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="账户信息"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:background="#1B1A1B"
-            android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:paddingStart="15dp"
-            android:onClick="@{v->vm.toBindBank()}"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="绑定银行卡"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-
-
-
-        <LinearLayout
+            android:orientation="vertical"
+            app:qmui_backgroundColor="#1B1A1B"
+            app:qmui_borderColor="#1B1A1B"
+            app:qmui_radius="16dp">
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toMyInfo()}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="账户信息"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+            <View
+                android:layout_width="match_parent"
+                android:layout_height="@dimen/dp_1"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:background="#222222" />
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toBindBank()}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="绑定银行卡"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
             android:layout_width="match_parent"
-            android:layout_height="50dp"
+            android:layout_height="100dp"
             android:layout_marginTop="12dp"
-            android:background="#1B1A1B"
             android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:onClick="@{v->vm.toAccountSafe()}"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="账户安全"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-
-
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:background="#1B1A1B"
-            android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:onClick="@{v->vm.toChangePassword()}"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="二级密码"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-
-
-
-        <LinearLayout
-            android:id="@+id/ll_to_update"
-            android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:layout_marginTop="@dimen/dp_12"
-            android:background="#1B1A1B"
-            android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="检查更新"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_marginEnd="8dp"
-                android:text="@{BuildConfig.VERSION_NAME}"
-                android:textColor="#999999"
-                android:textSize="15sp"
-                tools:text="v1.0.1.11" />
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-        <LinearLayout
-            android:id="@+id/ll_clear_size"
+            android:orientation="vertical"
+            app:qmui_backgroundColor="#1B1A1B"
+            app:qmui_borderColor="#1B1A1B"
+            app:qmui_radius="16dp">
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toAccountSafe()}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="账户安全"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+            <View
+                android:layout_width="match_parent"
+                android:layout_height="@dimen/dp_1"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:background="#222222" />
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toChangePassword()}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="二级密码"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
             android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:background="#1B1A1B"
-            android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="清除缓存"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <TextView
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_marginEnd="8dp"
-                android:text="@{vm.cacheSize}"
-                android:textColor="#999999"
-                android:textSize="15sp"
-                tools:text="v1.0.1.11" />
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-
-
-
-
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:layout_marginTop="@dimen/dp_12"
-            android:background="#1B1A1B"
-            android:gravity="center_vertical"
-            android:onClick="@{v->vm.toAgree(2)}"
-            android:orientation="horizontal"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="使用条款"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:background="#1B1A1B"
+            android:layout_height="100dp"
+            android:layout_marginTop="12dp"
             android:gravity="center_vertical"
-            android:onClick="@{v->vm.toAgree(1)}"
-            android:orientation="horizontal"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="隐私协议"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
+            android:orientation="vertical"
+            app:qmui_backgroundColor="#1B1A1B"
+            app:qmui_borderColor="#1B1A1B"
+            app:qmui_radius="16dp">
+
+            <LinearLayout
+                android:id="@+id/ll_to_update"
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="检查更新"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginEnd="8dp"
+                    android:text="@{BuildConfig.VERSION_NAME}"
+                    android:textColor="#999999"
+                    android:textSize="15sp"
+                    tools:text="v1.0.1.11" />
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+            <View
+                android:layout_width="match_parent"
+                android:layout_height="@dimen/dp_1"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:background="#222222" />
+
+            <LinearLayout
+                android:id="@+id/ll_clear_size"
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="清除缓存"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginEnd="8dp"
+                    android:text="@{vm.cacheSize}"
+                    android:textColor="#999999"
+                    android:textSize="15sp"
+                    tools:text="v1.0.1.11" />
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
             android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="50dp"
-            android:background="#1B1A1B"
+            android:layout_height="200dp"
+            android:layout_marginTop="12dp"
             android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:paddingStart="15dp"
-            android:onClick="@{v->vm.toAgree(4)}"
-            android:paddingEnd="14dp">
-
-            <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="违规处罚"
-                android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-        <View
-            android:background="#222222"
-            android:layout_marginEnd="15dp"
-            android:layout_marginStart="15dp"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/dp_1"/>
-        <LinearLayout
+            android:orientation="vertical"
+            app:qmui_backgroundColor="#1B1A1B"
+            app:qmui_borderColor="#1B1A1B"
+            app:qmui_radius="16dp">
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toAgree(2)}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="使用条款"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+            <View
+                android:layout_width="match_parent"
+                android:layout_height="@dimen/dp_1"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:background="#222222" />
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toAgree(1)}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="隐私协议"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+            <View
+                android:layout_width="match_parent"
+                android:layout_height="@dimen/dp_1"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:background="#222222" />
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toAgree(4)}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="违规处罚"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+            <View
+                android:layout_width="match_parent"
+                android:layout_height="@dimen/dp_1"
+                android:layout_marginStart="15dp"
+                android:layout_marginEnd="15dp"
+                android:background="#222222" />
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center_vertical"
+                android:onClick="@{v->vm.toAgree(3)}"
+                android:orientation="horizontal"
+                android:paddingStart="15dp"
+                android:paddingEnd="14dp">
+
+                <TextView
+                    android:layout_width="0dp"
+                    android:layout_height="wrap_content"
+                    android:layout_weight="1"
+                    android:text="关于我们"
+                    android:textColor="@color/white"
+                    android:textSize="15sp" />
+
+
+                <ImageView
+                    android:layout_width="6dp"
+                    android:layout_height="12dp"
+                    android:src="@drawable/ct_back_right" />
+
+
+            </LinearLayout>
+
+        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
             android:layout_width="match_parent"
             android:layout_height="50dp"
-            android:background="#1B1A1B"
+            android:layout_marginTop="12dp"
             android:gravity="center_vertical"
-            android:orientation="horizontal"
-            android:onClick="@{v->vm.toAgree(3)}"
-            android:paddingStart="15dp"
-            android:paddingEnd="14dp">
+            android:onClick="@{v->vm.toExitLogin()}"
+            android:orientation="vertical"
+            app:qmui_backgroundColor="#1B1A1B"
+            app:qmui_borderColor="#1B1A1B"
+            app:qmui_radius="16dp">
 
             <TextView
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:text="关于我们"
+                android:layout_width="match_parent"
+                android:layout_height="45dp"
+                android:background="#1B1A1B"
+                android:gravity="center"
+                android:text="退出登录"
                 android:textColor="@color/white"
-                android:textSize="15sp" />
-
-
-            <ImageView
-                android:layout_width="6dp"
-                android:layout_height="12dp"
-                android:src="@drawable/ct_back_right" />
-
-
-        </LinearLayout>
-
-       <TextView
-           android:layout_width="match_parent"
-           android:textSize="18sp"
-           android:background="#1B1A1B"
-           android:textColor="@color/white"
-           android:layout_marginTop="12dp"
-           android:text="退出登录"
-           android:onClick="@{v->vm.toExitLogin()}"
-           android:gravity="center"
-           android:layout_height="50dp"/>
-
-
-
+                android:textSize="18sp" />
+        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
 
 
     </LinearLayout>

+ 10 - 7
app/src/main/res/layout/activity_tibetan_details.xml

@@ -501,14 +501,16 @@
         <!--        已售罄-->
         <LinearLayout
             android:layout_width="match_parent"
-            android:layout_height="60dp"
+            android:layout_height="91dp"
+            android:layout_marginBottom="10dp"
             android:gravity="center_vertical"
             android:visibility="@{vm.data.state==3?View.VISIBLE:View.GONE}">
 
             <TextView
                 android:layout_width="0dp"
                 android:layout_height="wrap_content"
-                android:layout_gravity="center_vertical"
+                android:layout_marginTop="14dp"
+
                 android:layout_marginStart="16dp"
                 android:layout_weight="1"
                 android:text="@{`¥`+vm.data.price}"
@@ -534,7 +536,7 @@
         <!--        立即购买-->
         <LinearLayout
             android:layout_width="match_parent"
-            android:layout_height="48dp"
+            android:layout_height="91dp"
             android:layout_marginBottom="10dp"
             android:orientation="horizontal"
             android:visibility="@{vm.data.state==1?View.VISIBLE:View.GONE}"
@@ -543,7 +545,7 @@
             <TextView
                 android:layout_width="0dp"
                 android:layout_height="wrap_content"
-                android:layout_gravity="center_vertical"
+                android:layout_marginTop="14dp"
                 android:layout_marginStart="16dp"
                 android:layout_weight="1"
                 android:text="@{`¥`+vm.data.price}"
@@ -586,7 +588,8 @@
             <TextView
                 android:layout_width="0dp"
                 android:layout_height="wrap_content"
-                android:layout_gravity="center_vertical"
+                android:layout_marginTop="14dp"
+
                 android:layout_marginStart="16dp"
                 android:layout_weight="1"
                 android:text="@{`¥`+vm.data.price}"
@@ -633,7 +636,7 @@
             <TextView
                 android:layout_width="0dp"
                 android:layout_height="wrap_content"
-                android:layout_gravity="center_vertical"
+                android:layout_marginTop="14dp"
                 android:layout_marginStart="16dp"
                 android:layout_weight="1"
                 android:text="@{`¥`+vm.data.price}"
@@ -653,7 +656,7 @@
                 <TextView
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:text="设置提醒"
+                    android:text="设置购买提醒"
                     android:textColor="#DFDFDF"
                     android:textSize="16sp" />
 

+ 4 - 3
app/src/main/res/layout/fragment_home_first.xml

@@ -51,8 +51,8 @@
                             android:orientation="horizontal">
 
                             <com.qmuiteam.qmui.widget.QMUIRadiusImageView
-                                android:layout_width="24dp"
-                                android:layout_height="24dp"
+                                android:layout_width="18dp"
+                                android:layout_height="18dp"
                                 android:layout_marginStart="15dp"
                                 android:src="@drawable/ic_default_avatar"
                                 app:qmui_border_color="@color/translucent"
@@ -64,7 +64,7 @@
                                 android:layout_width="wrap_content"
                                 android:layout_height="wrap_content"
                                 android:layout_marginStart="6dp"
-                                android:text="@{vm.name}"
+                                android:text="象链"
                                 android:textColor="@color/white"
                                 android:textSize="18sp" />
 
@@ -145,6 +145,7 @@
                                     android:layout_width="12dp"
                                     android:layout_height="12dp"
                                     android:layout_marginStart="6dp"
+                                    android:layout_marginEnd="6dp"
                                     android:src="@drawable/ct_msg_more" />
 
                             </LinearLayout>

+ 26 - 0
app/src/main/res/layout/item_partake.xml

@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    xmlns:tools="http://schemas.android.com/tools" >
+
+    <data >
+        <import type="android.view.View" />
+
+
+        <variable
+            name="item"
+            type="com.hdl.xl.model.PartackBean.ListBean" />
+
+    </data >
+
+    <com.qmuiteam.qmui.widget.QMUIRadiusImageView
+        android:layout_width="45dp"
+        app:qmui_is_oval="true"
+        android:layout_marginEnd="15dp"
+        app:url="@{item.headimg}"
+        app:qmui_border_color="@color/translucent"
+        android:src="#D8D8D8"
+        android:layout_marginBottom="12dp"
+        android:layout_height="45dp"/>
+
+</layout >

+ 2 - 0
app/src/main/res/layout/item_pop_buy.xml

@@ -261,6 +261,7 @@
                 <ImageView
                     android:layout_width="20dp"
                     android:layout_height="20dp"
+                    android:visibility="gone"
                     android:src="@drawable/ct_wallet" />
 
                 <TextView
@@ -297,6 +298,7 @@
                 <ImageView
                     android:layout_width="20dp"
                     android:layout_height="20dp"
+                    android:visibility="gone"
                     android:src="@drawable/ct_wallet" />
 
                 <TextView

+ 52 - 0
app/src/main/res/layout/item_roster.xml

@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    xmlns:tools="http://schemas.android.com/tools" >
+
+    <data >
+        <import type="android.view.View" />
+
+        <variable
+            name="vm"
+            type="com.hdl.xl.vmodel.RosterVModel" />
+
+        <variable
+            name="item"
+            type="com.hdl.xl.model.RosterBean" />
+
+    </data >
+    <LinearLayout
+        android:id="@+id/ll"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="15dp"
+        android:layout_marginEnd="15dp"
+        android:layout_marginBottom="20dp"
+        android:paddingTop="10dp"
+        android:gravity="center_vertical"
+        android:orientation="horizontal">
+
+        <com.qmuiteam.qmui.widget.QMUIRadiusImageView
+            android:layout_width="40dp"
+            android:layout_height="40dp"
+            app:url="@{item.headimg}"
+            android:src="@drawable/ic_default_avatar"
+            app:qmui_border_color="@color/translucent"
+            app:qmui_is_oval="true" />
+
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_marginStart="12dp"
+            android:text="@{item.user_name}"
+            android:textColor="@color/white"
+            android:textSize="15sp" />
+
+
+
+
+
+
+    </LinearLayout>
+
+</layout >

+ 126 - 0
app/src/main/res/layout/popu_suess_pay.xml

@@ -0,0 +1,126 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:background="@color/c_bg"
+    android:gravity="center"
+    android:orientation="vertical">
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="0dp"
+        android:layout_weight="1" />
+
+
+    <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:orientation="vertical"
+        app:qmui_backgroundColor="@color/white"
+        app:qmui_radius="12dp">
+
+        <ImageView
+            android:layout_width="48dp"
+            android:layout_height="48dp"
+            android:layout_gravity="center_horizontal"
+            android:layout_marginTop="60dp"
+            android:src="@drawable/ct_pay_suess" />
+
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_gravity="center_horizontal"
+            android:layout_marginTop="12dp"
+            android:text="支付成功"
+            android:textColor="#222222"
+            android:textSize="16sp" />
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="10dp"
+            android:gravity="center_horizontal"
+            android:orientation="horizontal">
+
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="¥"
+                android:textColor="#222222"
+                android:textSize="14sp" />
+
+            <TextView
+                android:id="@+id/tv_money"
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="79.9"
+                android:textColor="#222222"
+                android:textSize="30sp" />
+
+        </LinearLayout>
+
+        <com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginStart="25dp"
+            android:layout_marginTop="60dp"
+            android:layout_marginEnd="25dp"
+            android:orientation="vertical"
+            android:paddingStart="15dp"
+            android:paddingTop="20dp"
+            android:paddingEnd="15dp"
+            android:paddingBottom="20dp"
+            app:qmui_backgroundColor="#F3F3F3"
+            app:qmui_radius="14dp">
+
+            <TextView
+                android:id="@+id/tv_number"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:text="订单编号:"
+                android:textColor="#333333"
+                android:textSize="14sp" />
+
+            <TextView
+                android:id="@+id/tv_time"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="12dp"
+                android:text="下单时间:"
+
+                android:textColor="#333333"
+                android:textSize="14sp" />
+
+            <TextView
+                android:id="@+id/tv_pay"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="12dp"
+                android:text="支付方式:"
+                android:textColor="#333333"
+                android:textSize="14sp" />
+
+
+        </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+        <TextView
+            android:id="@+id/tv_sure"
+            android:layout_width="match_parent"
+            android:layout_height="46dp"
+            android:layout_marginStart="15dp"
+            android:layout_marginTop="60dp"
+            android:layout_marginEnd="30dp"
+            android:layout_marginBottom="22dp"
+            android:background="@drawable/bg_logo_but"
+            android:gravity="center"
+            android:text="确定"
+            android:textColor="@color/text_title"
+            android:textSize="20sp" />
+
+
+    </com.qmuiteam.qmui.widget.roundwidget.QMUIRoundLinearLayout>
+
+
+</LinearLayout>

+ 3 - 0
base/src/main/java/com/ysnows/base/net/Resp.kt

@@ -23,6 +23,9 @@ open class Resp<D>(
         if (showError) {//状态成功的时候也可以提示
             Toasts.toast(BApp.instance(), msg())
         }
+        if(code==0){
+            Toasts.toast(BApp.instance(), msg())
+        }
 
 //        val ok = status == 1
 //

+ 12 - 0
base/src/main/java/com/ysnows/base/widget/tablayout/TabLayout.java

@@ -4,12 +4,14 @@ import android.content.Context;
 import android.content.res.TypedArray;
 import android.util.AttributeSet;
 import android.view.View;
+import android.widget.Toast;
 
 import com.chad.library.adapter.base.BaseQuickAdapter;
 import com.chad.library.adapter.base.listener.OnItemClickListener;
 import com.hwangjr.rxbus.RxBus;
 import com.qmuiteam.qmui.widget.tab.QMUITab;
 import com.ysnows.base.R;
+import com.ysnows.base.utils.Toasts;
 
 import java.util.ArrayList;
 
@@ -35,16 +37,19 @@ public class TabLayout extends RecyclerView implements OnItemClickListener {
 
     public TabLayout(Context context) {
         super(context);
+
         init(context, null, 0);
     }
 
     public TabLayout(Context context, AttributeSet attrs) {
         super(context, attrs);
+
         init(context, attrs, 0);
     }
 
     public TabLayout(Context context, AttributeSet attrs, int defStyleAttr) {
         super(context, attrs, defStyleAttr);
+
         init(context, attrs, defStyleAttr);
     }
 
@@ -130,6 +135,11 @@ public class TabLayout extends RecyclerView implements OnItemClickListener {
             if (tabIndex == i) {
                 tab.setSelected(true);
 
+                if(tabIndex==1){
+                    Toast.makeText(getContext(),"暂未开放,敬请期待",Toast.LENGTH_SHORT).show();
+                    return;
+                }
+
                 if (fragment == null) {
                     fragment = tab.fragment;
                     transaction.add(R.id.container, fragment, "tab_" + tabIndex);
@@ -151,6 +161,8 @@ public class TabLayout extends RecyclerView implements OnItemClickListener {
 
     @Override
     public void onItemClick(@NonNull BaseQuickAdapter<?, ?> adapter, @NonNull View view, int position) {
+
+
         switchTab(position);