梦幻许愿池未开启则直接跳转普通许愿
This commit is contained in:
@@ -1545,7 +1545,12 @@ public class HomePartyRoomFragment extends BaseMvpFragment<IHomePartyView, HomeP
|
||||
* 房间许愿池
|
||||
*/
|
||||
public void onClickBox() {
|
||||
if (getFragmentManager() != null) {
|
||||
|
||||
String openTime = GoldBoxHelper.getBoxOpenTime();
|
||||
int startTime = Integer.parseInt(openTime.substring(0, openTime.indexOf("-")).replace(":", ""));
|
||||
int endTime = Integer.parseInt(openTime.substring(openTime.indexOf("-") + 1).replace(":", ""));
|
||||
|
||||
if (getFragmentManager() != null && TimeUtils.getTimeLimit(startTime, endTime)) {
|
||||
ChooseTreasureBoxDialogFragment chooseTreasureBoxDialogFragment = new ChooseTreasureBoxDialogFragment(GoldBoxHelper.getBoxOpenTime());
|
||||
chooseTreasureBoxDialogFragment.setOnTreasureBoxChooseListener(type -> {
|
||||
if (type == 0) {// 幸运许愿池(默认)
|
||||
|
@@ -144,6 +144,9 @@ public class TreasureBoxActivity extends BaseBindingActivity<ActivityTreasureBox
|
||||
case R.id.iv_title:
|
||||
//do nothing
|
||||
break;
|
||||
case R.id.ll_get_key:
|
||||
DialogWebViewActivity.start(this, UriProvider.getBoxKey());
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@@ -244,6 +244,36 @@
|
||||
tools:background="@color/white"
|
||||
tools:visibility="gone" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_get_key"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="20dp"
|
||||
android:orientation="horizontal"
|
||||
android:onClick="@{click}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/view_bg">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="参与活动获得"
|
||||
android:textColor="#ffffffff"
|
||||
android:textSize="13sp" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/treasure_box_meteor" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="流星>"
|
||||
android:textColor="#ffffffff"
|
||||
android:textSize="13sp" />
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
|
Reference in New Issue
Block a user