yang_div лет назад: 8
Родитель
Сommit
ec7f96be48

BIN
app/app-sheep-release.apk


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

@@ -321,6 +321,7 @@
         <activity android:name="com.sheep.gamegroup.view.activity.SignCardAct" android:screenOrientation="portrait"/>
         <activity android:name="com.sheep.gamegroup.view.activity.SignRankingsAct" android:screenOrientation="portrait"/>
         <activity android:name="com.sheep.gamegroup.view.activity.SignRecordAct" android:screenOrientation="portrait"/>
+        <activity android:name="com.sheep.gamegroup.view.activity.SignRechargeAct" android:screenOrientation="portrait"/>
 
 
         <!--友盟start-->

+ 1 - 0
app/src/main/java/com/kfzs/duanduan/event/EventTypes.java

@@ -29,4 +29,5 @@ public enum EventTypes {
     TASK_AGAIN_UPLOAD_FILE,//任务审核上传图片 通知
     TASK_AGAIN_UPLOAD_FILE_DATA,//任务审核上传图片 通知
     REFRESH_DATA_PHONE,//刷新手机
+    REFRESH_DATA_SIGN,//签到对话框
 }

+ 2 - 1
app/src/main/java/com/kfzs/duanduan/fragment/FgtPersonalCenter.java

@@ -141,7 +141,8 @@ public class FgtPersonalCenter extends BaseCompatFragment {
                 Jump2View.getInstance().goTaskList2View(getActivity(), null);
                 break;
             case R.id.proxy_service_layout://代理
-//                Jump2View.getInstance().goSignCardAct(getActivity(), null);
+                Jump2View.getInstance().goSignCardAct(getActivity(), "3");
+//                Jump2View.getInstance().goSignCardAct(activity, balance);
                 G.showToast("敬请期待!");
                 break;
             case R.id.abourt_us_layout://关于我们

+ 7 - 2
app/src/main/java/com/kfzs/duanduan/fragment/FgtSmallSheep.java

@@ -233,11 +233,14 @@ public class FgtSmallSheep extends BaseCompatFragment implements SmallSheepContr
     }
 
 
+    String balance ="0";//余额
+
     private void refalsh() {
 
         if (myPrice == null || userEntity == null) {
             return;
         }
+        balance = userEntity.getBalance();
         myPrice.setText(userEntity.getBalance() + " 元");
         myAllPrice.setText("累计资产 " + userEntity.getTotal_asset() + " 元");
         nameTv.setText(userEntity.getNickname() + "");//绵羊号:123456789
@@ -858,7 +861,7 @@ public class FgtSmallSheep extends BaseCompatFragment implements SmallSheepContr
             @Override
             public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
                 SlideshowEty clickedGameObj = slideshowEtyLists.get(position);
-
+                showToast("-->打卡赚钱:"+clickedGameObj.getType());
                 UMConfigUtils.onEvent(UMConfigUtils.Event.BANNER_CLICK_HORIZONTAL);
                 switch (clickedGameObj.getType()) {// 0,类型 1跳转试玩赚钱、2单个任务详情、3信用卡办理、4 H5页面、5 微信二维码任务
                     case 1:
@@ -904,7 +907,9 @@ public class FgtSmallSheep extends BaseCompatFragment implements SmallSheepContr
                                 .goTryplayView(activity, 1);
                         break;
                     case 9://打卡赚钱
-                        Jump2View.getInstance().goSignCardAct(activity, null);
+                        showToast("打卡赚钱");
+                        Jump2View.getInstance().goSignCardAct(activity, balance);
+                        break;
                 }
             }
         });

+ 12 - 0
app/src/main/java/com/sheep/gamegroup/util/Jump2View.java

@@ -61,6 +61,7 @@ import com.sheep.gamegroup.view.activity.RechargeQAct;
 import com.sheep.gamegroup.view.activity.RechargeResultAct;
 import com.sheep.gamegroup.view.activity.SignCardAct;
 import com.sheep.gamegroup.view.activity.SignRankingsAct;
+import com.sheep.gamegroup.view.activity.SignRechargeAct;
 import com.sheep.gamegroup.view.activity.SignRecordAct;
 import com.sheep.gamegroup.view.activity.TaskDetailAct;
 import com.sheep.gamegroup.view.activity.TaskDetailAddQQAct;
@@ -949,6 +950,7 @@ public class Jump2View {
      */
     public void goSignCardAct(Context context, Object o){
         Intent intent = new Intent(context, SignCardAct.class);
+        intent.putExtra("balance",o.toString());
         context.startActivity(intent);
     }
 
@@ -974,5 +976,15 @@ public class Jump2View {
         context.startActivity(intent);
     }
 
+    /**
+     * (一元报名充值界面)
+     * @param context
+     * @param o
+     */
+    public void goSignRechargeAct(Context context, Object o){
+        Intent intent = new Intent(context, SignRechargeAct.class);
+        context.startActivity(intent);
+    }
+
 
 }

+ 97 - 0
app/src/main/java/com/sheep/gamegroup/util/ViewUtil.java

@@ -204,4 +204,101 @@ public class ViewUtil {
     public static boolean isH5Content(String content) {
         return content.trim().startsWith("<html>") || content.trim().startsWith("<!DOCTYPE html>");
     }
+
+
+    public static void showSignPay(final Activity activity) {
+        AlertDialog.Builder builder = new AlertDialog.Builder(activity);
+        View view = View.inflate(activity, R.layout.x_sign_type_dialog, null);
+        builder.setView(view);
+        final AlertDialog dialog = builder.create();
+        ImageView iv = view.findViewById(R.id.iv_close);
+        TextView dialog_sure = view.findViewById(R.id.dialog_sure);
+        dialog_sure.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                dialog.dismiss();
+            }
+        });
+        dialog.show();
+        Window window = dialog.getWindow();
+        if(window != null) {
+            android.view.WindowManager.LayoutParams p = window.getAttributes();
+            p.height = WindowManager.LayoutParams.WRAP_CONTENT;
+            p.width = WindowManager.LayoutParams.MATCH_PARENT;
+            dialog.getWindow().setAttributes(p);     //设置生效
+        }
+        iv.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                dialog.dismiss();
+            }
+        });
+
+
+    }
+
+    //打卡 -》未报名提示对话框
+    public static void showSignAlert(final Activity activity) {
+        AlertDialog.Builder builder = new AlertDialog.Builder(activity);
+        View view = View.inflate(activity, R.layout.x_sign_alert_dialog, null);
+        builder.setView(view);
+        final AlertDialog dialog = builder.create();
+        ImageView iv = view.findViewById(R.id.iv_close);
+        TextView dialog_sure = view.findViewById(R.id.dialog_sure);
+        dialog_sure.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                dialog.dismiss();
+            }
+        });
+        dialog.show();
+        Window window = dialog.getWindow();
+        if(window != null) {
+            android.view.WindowManager.LayoutParams p = window.getAttributes();
+            p.height = WindowManager.LayoutParams.WRAP_CONTENT;
+            p.width = WindowManager.LayoutParams.MATCH_PARENT;
+            dialog.getWindow().setAttributes(p);     //设置生效
+        }
+        iv.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                dialog.dismiss();
+            }
+        });
+    }
+
+    //打卡->超出时间提示对话框
+    public static void showSignTimeAlert(final Activity activity, String personCount, final View.OnClickListener onClickListener) {
+        AlertDialog.Builder builder = new AlertDialog.Builder(activity);
+        View view = View.inflate(activity, R.layout.x_sign_alerttime_dialog, null);
+        builder.setView(view);
+        final AlertDialog dialog = builder.create();
+        ImageView iv = view.findViewById(R.id.iv_close);
+        TextView dialog_sure = view.findViewById(R.id.dialog_sure);
+        TextView sign_tv_count = view.findViewById(R.id.sign_tv_count);
+        sign_tv_count.setText("今天已有"+personCount+"人成功打卡");
+        dialog_sure.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                dialog.dismiss();
+            }
+        });
+        dialog.show();
+        Window window = dialog.getWindow();
+        if(window != null) {
+            android.view.WindowManager.LayoutParams p = window.getAttributes();
+            p.height = WindowManager.LayoutParams.WRAP_CONTENT;
+            p.width = WindowManager.LayoutParams.MATCH_PARENT;
+            dialog.getWindow().setAttributes(p);     //设置生效
+        }
+        iv.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                if(onClickListener != null){
+                    onClickListener.onClick(v);
+                }
+                dialog.dismiss();
+            }
+        });
+    }
 }

+ 0 - 7
app/src/main/java/com/sheep/gamegroup/view/activity/RechargeAct.java

@@ -1,9 +1,5 @@
 package com.sheep.gamegroup.view.activity;
 
-import android.os.Bundle;
-import android.text.Editable;
-import android.text.TextUtils;
-import android.text.TextWatcher;
 import android.view.View;
 import android.widget.AdapterView;
 import android.widget.EditText;
@@ -15,10 +11,8 @@ import com.sheep.gamegroup.alipay.PayResult;
 import com.sheep.gamegroup.model.entity.BaseMessage;
 import com.sheep.gamegroup.model.entity.RechargeEntity;
 import com.sheep.gamegroup.model.entity.RechargePriceEntity;
-import com.sheep.gamegroup.model.entity.RechargeQEntity;
 import com.sheep.gamegroup.model.util.SheepSubscriber;
 import com.sheep.gamegroup.util.Jump2View;
-import com.sheep.gamegroup.util.ListUtil;
 import com.sheep.gamegroup.util.MyGridview;
 import com.sheep.gamegroup.view.adapter.RechargeAdapter;
 import com.sheep.gamegroup.view.adapter.RechargePriceAdapter;
@@ -31,7 +25,6 @@ import java.util.ArrayList;
 import java.util.List;
 
 import butterknife.BindView;
-import butterknife.ButterKnife;
 import butterknife.OnClick;
 import rx.android.schedulers.AndroidSchedulers;
 import rx.schedulers.Schedulers;

+ 62 - 7
app/src/main/java/com/sheep/gamegroup/view/activity/SignCardAct.java

@@ -13,19 +13,30 @@ import android.util.Log;
 import android.view.View;
 import android.widget.TextView;
 
+import com.kfzs.duanduan.event.BigEvent;
+import com.kfzs.duanduan.event.EventTypes;
+import com.kfzs.duanduan.view.DialogStorageLow;
 import com.sheep.gamegroup.absBase.BaseActivity;
 import com.sheep.gamegroup.di.components.DaggerSignCardComponent;
 import com.sheep.gamegroup.di.modules.SignCardModule;
 import com.sheep.gamegroup.model.entity.BaseMessage;
+import com.sheep.gamegroup.model.entity.DialogEntity;
 import com.sheep.gamegroup.model.entity.PunchAndSign;
 import com.sheep.gamegroup.presenter.SignCardContract;
 import com.sheep.gamegroup.presenter.SignCardPresenter;
 import com.sheep.gamegroup.util.Jump2View;
+import com.sheep.gamegroup.util.MathUtil;
+import com.sheep.gamegroup.util.ViewUtil;
 import com.sheep.jiuyan.samllsheep.R;
 import com.sheep.jiuyan.samllsheep.SheepApp;
 import com.sheep.jiuyan.samllsheep.utils.G;
 import com.sheep.jiuyan.samllsheep.utils.TitleBarUtils;
 
+import org.greenrobot.eventbus.EventBus;
+import org.greenrobot.eventbus.Subscribe;
+
+import java.util.Calendar;
+
 import javax.inject.Inject;
 
 import butterknife.BindView;
@@ -56,6 +67,9 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
     @BindView(R.id.sign_tv_yybm)
     TextView signTvYybm;
 
+    String person ="0";
+    String balance;
+
 
     @Override
     protected int getLayoutId() {
@@ -65,11 +79,12 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
     @Override
     public void initView() {
         activity = this;
+        balance = getIntent().getStringExtra("balance");
         TitleBarUtils
                 .getInstance()
                 .setTitle(activity, "每日打卡")
                 .setTitleFinish(activity)
-                .setRightImgBotton(activity, R.drawable.sign_right_record_bg, new View.OnClickListener() {
+                .setRightBotton(activity, "战绩",0, new View.OnClickListener() {
             @Override
             public void onClick(View v) {
                 Jump2View.getInstance().goSignRecordAct(activity, null);
@@ -80,7 +95,7 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
                 .signCardModule(new SignCardModule(this))
                 .build()
                 .inject(this);
-
+        EventBus.getDefault().register(this);
 
     }
 
@@ -104,7 +119,13 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
     public void succSignPunch(BaseMessage o) {
 //        {"code":200,"msg":"OK"}
         if("OK".equals(o.getMsg())){
-            showToast("打卡成功");
+//            showToast("打卡成功");
+                            Jump2View.getInstance()
+                        .goNoticeAct(activity, new DialogEntity("恭喜您",
+                            "今日打卡成功",
+                                    "我知道了",
+                                    "",
+                                EventTypes.REFRESH_DATA_SIGN));
         }else {
             showToast(o.getMsg());
         }
@@ -118,7 +139,8 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
     public void succSignUp(BaseMessage o) {
 //        {"code":200,"msg":"OK"}
         if("OK".equals(o.getMsg())){
-            showToast("报名成功");
+//            showToast("报名成功");
+            ViewUtil.showSignPay(activity);
         }else {
             showToast(o.getMsg());
         }
@@ -142,14 +164,29 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
     @Override
     public void succPunchCanpunch(BaseMessage o) {
         if("1".equals(o.getData().toString())){
-            showToast("未报名");
+          ViewUtil.showSignAlert(activity);//未报名
         }else if("2".equals(o.getData().toString())){
             showToast("已打卡");
         }else if("3".equals(o.getData().toString())){
-            presenter.goSignPunch();
+            Calendar calendar = Calendar.getInstance();
+            int hour = calendar.get(Calendar.HOUR);
+            if(hour >= 7 && hour < 9){//规定时间内去打卡
+                presenter.goSignPunch();
+            }else{//不在规定时间内,提示对话框
+                ViewUtil.showSignTimeAlert(activity, person, new View.OnClickListener() {
+                    @Override
+                    public void onClick(View v) {
+                        presenter.goPunchCanSignUp();
+                    }
+                });
+            }
+
         }
     }
 
+
+
+
     /**
      * 判断今日是否能报名
      *  true可以 false不可以
@@ -191,7 +228,12 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
                 presenter.goPunchCanpunch();
                 break;
             case R.id.sign_tv_yybm://一元报名
-                presenter.goPunchCanSignUp();
+                if(Float.valueOf(balance) >= 1){
+                    presenter.goPunchCanSignUp();
+                }else {
+                    Jump2View.getInstance().goSignRechargeAct(activity,null);
+                }
+
                 break;
         }
     }
@@ -210,4 +252,17 @@ public class SignCardAct extends BaseActivity implements SignCardContract.View {
         return spannableString;
     }
 
+    @Subscribe
+    public void onEventMainThread(BigEvent bigEvent) {
+        if (bigEvent.getEventTypes() == EventTypes.REFRESH_DATA_SIGN) {
+            Jump2View.getInstance().goSignRecordAct(activity, null);
+        }
+    }
+
+
+    @Override
+    protected void onDestroy() {
+        super.onDestroy();
+        EventBus.getDefault().unregister(this);
+    }
 }

+ 199 - 0
app/src/main/java/com/sheep/gamegroup/view/activity/SignRechargeAct.java

@@ -0,0 +1,199 @@
+package com.sheep.gamegroup.view.activity;
+
+import android.view.View;
+import android.widget.AdapterView;
+import android.widget.TextView;
+
+import com.alibaba.fastjson.JSONObject;
+import com.alipay.sdk.app.PayTask;
+import com.sheep.gamegroup.absBase.BaseActivity;
+import com.sheep.gamegroup.alipay.PayResult;
+import com.sheep.gamegroup.model.entity.BaseMessage;
+import com.sheep.gamegroup.model.entity.RechargeEntity;
+import com.sheep.gamegroup.model.util.SheepSubscriber;
+import com.sheep.gamegroup.util.Jump2View;
+import com.sheep.gamegroup.util.MyGridview;
+import com.sheep.gamegroup.view.adapter.RechargeAdapter;
+import com.sheep.jiuyan.samllsheep.R;
+import com.sheep.jiuyan.samllsheep.SheepApp;
+import com.sheep.jiuyan.samllsheep.utils.G;
+import com.sheep.jiuyan.samllsheep.utils.TitleBarUtils;
+
+import java.util.List;
+
+import butterknife.BindView;
+import butterknife.OnClick;
+import rx.android.schedulers.AndroidSchedulers;
+import rx.schedulers.Schedulers;
+
+/**
+ * Created by Administrator on 2018/3/19.
+ * 充值界面
+ */
+
+public class SignRechargeAct extends BaseActivity {
+
+    int mPayType = -1;//选择支付方式的id
+    String mAmount = null;//支付的金额
+
+    @BindView(R.id.recharge_greidview)
+    MyGridview rechargeGreidview;
+
+    RechargeAdapter rechargeAdapter;
+    @BindView(R.id.et_recharge_price)
+    TextView etRechargePrice;
+
+
+    @Override
+    protected int getLayoutId() {
+        return R.layout.signrecharge_act_layout;
+    }
+
+    @Override
+    public void initView() {
+        TitleBarUtils.getInstance()
+                .setTitle(this, "充值")
+                .setTitleFinish(this);
+    }
+
+    @Override
+    public void initListener() {
+    }
+
+    @Override
+    public void initData() {
+
+
+        /**
+         * 支付方式选择
+         */
+        rechargeAdapter = new RechargeAdapter(SignRechargeAct.this);
+        rechargeGreidview.setVerticalSpacing(40);
+        rechargeGreidview.setAdapter(rechargeAdapter);
+        rechargeGreidview.setOnItemClickListener(new AdapterView.OnItemClickListener() {
+            @Override
+            public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
+                RechargeEntity rechargeEntity = (RechargeEntity) parent.getItemAtPosition(position);
+                mPayType = rechargeEntity.getId();
+                rechargeAdapter.setSelect(position);
+                rechargeAdapter.notifyDataSetChanged();
+            }
+        });
+
+
+        showProgress();
+        getRechargePayway();
+    }
+
+    private void getRechargePayway() {
+        // 参数 1:没有绵羊币的,2:是全部
+        SheepApp.getInstance().getNetComponent().getApiService().getRechargePayway("1")
+                .subscribeOn(Schedulers.io())
+                .observeOn(AndroidSchedulers.mainThread())
+                .subscribe(new SheepSubscriber<BaseMessage>(SignRechargeAct.this) {
+                    @Override
+                    public void onNext(BaseMessage baseMessage) {
+                        hideProgress();
+                        List<RechargeEntity> list = baseMessage.getDatas(RechargeEntity.class);
+                        if(list != null && list.size() > 0){
+                            mPayType = list.get(0).getId();
+                            rechargeAdapter.setSelect(0);
+                        }
+                        rechargeAdapter.addAll(list);
+                        if(!list.isEmpty()) {
+                            mPayType = list.get(0).getId();
+                            rechargeAdapter.setSelect(0);
+                            rechargeAdapter.notifyDataSetChanged();
+                        }
+                    }
+
+                    @Override
+                    public void onError(BaseMessage baseMessage) {
+                        hideProgress();
+                        G.showToast(baseMessage.getMsg() + "");
+                    }
+                });
+    }
+
+    private void getRechargeBalance() {
+        JSONObject jsonObject = new JSONObject();
+        jsonObject.put("Amount", Float.valueOf(mAmount));
+        jsonObject.put("PayType", mPayType);
+        SheepApp.getInstance().getNetComponent().getApiService().getRechargeBalance(jsonObject)
+                .subscribeOn(Schedulers.io())
+                .observeOn(AndroidSchedulers.mainThread())
+                .subscribe(new SheepSubscriber<BaseMessage>(SignRechargeAct.this) {
+                    @Override
+                    public void onNext(BaseMessage baseMessage) {
+                        hideProgress();
+                        pay(baseMessage.getData().toString());
+                    }
+
+                    @Override
+                    public void onError(BaseMessage baseMessage) {
+                        hideProgress();
+                        G.showToast(baseMessage.getMsg() + "");
+                    }
+                });
+    }
+
+    @OnClick({R.id.tv_recharge_pay})
+    public void onViewClicked(View view) {
+        switch (view.getId()) {
+
+            case R.id.tv_recharge_pay:
+                if (mPayType == -1) {
+                    G.showToast("请选择支付方式");
+                    return;
+                }
+
+                mAmount = etRechargePrice.getText().toString().trim();
+                if(android.text.TextUtils.isEmpty(mAmount)){
+                    G.showToast("请选择充值金额");
+                    return;
+                }
+
+
+                showProgress();
+                getRechargeBalance();
+                break;
+        }
+    }
+
+    private void pay(final String payInfo) {
+        Runnable payRunnable = new Runnable() {
+
+            @Override
+            public void run() {
+                // 构造PayTask 对象
+                PayTask alipay = new PayTask(SignRechargeAct.this);
+                // 调用支付接口,获取支付结果
+                final String result = alipay.pay(payInfo, true);
+
+                runOnUiThread(new Runnable() {
+
+                    @Override
+                    public void run() {
+
+                        PayResult payResult = new PayResult(result);
+                        /**
+                         * 同步返回的结果必须放置到服务端进行验证(验证的规则请看https://doc.open.alipay.com/doc2/
+                         * detail.htm?spm=0.0.0.0.xdvAU6&treeId=59&articleId=103665&
+                         * docType=1) 建议商户依赖异步通知
+                         */
+//						String resultInfo = payResult.getResult();// 同步返回需要验证的信息
+
+                        String resultStatus = payResult.getResultStatus();
+                        Jump2View.getInstance().goRechargeResultAct(SignRechargeAct.this, resultStatus);
+                        finish();
+                    }
+                });
+            }
+        };
+
+        // 必须异步调用
+        Thread payThread = new Thread(payRunnable);
+        payThread.start();
+    }
+
+}

+ 5 - 0
app/src/main/java/com/sheep/gamegroup/view/adapter/expandadapter/SignRecordAdapter.java

@@ -13,6 +13,8 @@ import android.view.ViewGroup;
 import com.sheep.gamegroup.model.entity.PunchLogEntity;
 import com.sheep.jiuyan.samllsheep.R;
 
+import java.text.SimpleDateFormat;
+import java.util.Date;
 import java.util.List;
 
 
@@ -21,11 +23,13 @@ public class SignRecordAdapter extends BaseRecyclerViewAdapter<String, PunchLogE
 
     private Context ctx;
     private LayoutInflater mInflater;
+    SimpleDateFormat df ;
 
     public SignRecordAdapter(Context ctx, List<RecyclerViewData> datas) {
         super(ctx, datas);
         mInflater = LayoutInflater.from(ctx);
         this.ctx = ctx;
+        df = new SimpleDateFormat("yyyy-MM-dd");//设置日期格式
     }
 
     /**
@@ -56,6 +60,7 @@ public class SignRecordAdapter extends BaseRecyclerViewAdapter<String, PunchLogE
     @Override
     public void onBindChildpHolder(SignRecordViewHolder holder, int groupPos, int childPos, int position, PunchLogEntity childData) {
         holder.sign_child_tv_text.setText(getSpannableString(childData.getAmount()));
+        holder.sign_child_tv_time.setText(df.format(new Date(childData.getCreateTime())));
     }
 
     @Override

+ 1 - 0
app/src/main/res/layout/dialog_notice_layout.xml

@@ -72,6 +72,7 @@
                     android:background="@drawable/sp_bg_gradient_rectangle_blue"
                     android:textSize="@dimen/text_size_15" />
                 <View
+                    android:id="@+id/l_view"
                     android:layout_width="0dp"
                     android:layout_height="wrap_content"
                     android:layout_weight="1"/>

+ 1 - 1
app/src/main/res/layout/sign_card_layout.xml

@@ -168,7 +168,7 @@
                     android:layout_marginTop="@dimen/content_padding_10"
                     android:background="@drawable/sp_rectangle_bg_gray_radius"
                     android:gravity="center"
-                    android:text="明日打报名"
+                    android:text="明日打报名"
                     android:textColor="@color/content"
                     android:textSize="@dimen/text_size_3" />
 

+ 107 - 0
app/src/main/res/layout/signrecharge_act_layout.xml

@@ -0,0 +1,107 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:background="@color/bg_gray"
+    android:fitsSystemWindows="true"
+    android:orientation="vertical">
+
+    <include layout="@layout/title" />
+
+
+    <ScrollView
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:scrollbars="none">
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:gravity="center_horizontal"
+            android:orientation="vertical">
+
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:orientation="vertical"
+                android:padding="@dimen/content_padding_10">
+
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:background="@drawable/x_shap_shadow_bg_rectgangle_white"
+                    android:orientation="vertical"
+                    android:padding="@dimen/content_padding_13">
+
+
+                    <TextView
+                        style="@style/txt_style_15"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="7dp"
+                        android:paddingLeft="@dimen/content_padding_big"
+                        android:text="充值金额" />
+
+
+
+                    <TextView
+                        android:id="@+id/et_recharge_price"
+                        android:layout_width="match_parent"
+                        android:layout_height="40dp"
+                        android:layout_marginTop="@dimen/content_padding_10"
+                        android:background="@null"
+                        android:hint="请输入充值金额"
+                        android:inputType="number"
+                        android:maxLength="5"
+                        android:paddingLeft="@dimen/content_padding_big"
+                        android:textColor="@color/black_444444"
+                        android:textColorHint="@color/disenable_color"
+                        android:textSize="@dimen/text_size_3" />
+                </LinearLayout>
+
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="@dimen/content_padding_10"
+                    android:background="@drawable/x_shap_shadow_bg_rectgangle_white"
+                    android:orientation="vertical"
+                    android:padding="@dimen/content_padding_13">
+
+                    <TextView
+                        style="@style/txt_style_15"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="7dp"
+                        android:paddingLeft="@dimen/content_padding_big"
+                        android:text="支付方式" />
+
+                    <com.sheep.gamegroup.util.MyGridview
+                        android:id="@+id/recharge_greidview"
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="@dimen/content_padding_65"
+                        android:layout_marginRight="@dimen/content_padding_65"
+                        android:layout_marginTop="@dimen/content_padding_20"
+                        android:background="@color/white"
+                        android:gravity="center_horizontal"
+                        android:listSelector="@color/transparent"
+                        android:numColumns="1"
+                        android:scrollbars="none"
+                        android:visibility="visible" />
+                </LinearLayout>
+            </LinearLayout>
+
+            <TextView
+                android:id="@+id/tv_recharge_pay"
+                style="@style/txt_big_btn_style"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_gravity="center_horizontal"
+                android:layout_marginTop="20dp"
+                android:clickable="true"
+                android:gravity="center"
+                android:text="立即支付" />
+
+        </LinearLayout>
+    </ScrollView>
+</LinearLayout>

+ 41 - 0
app/src/main/res/layout/x_sign_alert_dialog.xml

@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:background="#ffffff"
+    android:orientation="vertical">
+
+    <ImageView
+        android:id="@+id/iv_close"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:src="@mipmap/try_dialog_x"
+        android:layout_gravity="right"
+        />
+
+<TextView
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:textColor="@color/black"
+    android:textSize="@dimen/text_size_3"
+    android:text="系统检测到您未报名参与今日打卡,请先参与明日打卡报名,次日再来参与打卡活动哦!"
+    android:layout_marginLeft="10dp"
+    android:layout_marginRight="10dp"
+    android:layout_marginTop="@dimen/content_padding_20"
+    android:lineSpacingExtra="2dp"
+    />
+    <TextView
+        android:id="@+id/dialog_sure"
+        android:layout_width="match_parent"
+        android:layout_marginRight="@dimen/content_padding_20"
+        android:layout_marginLeft="@dimen/content_padding_20"
+        android:layout_marginTop="20dp"
+        android:layout_marginBottom="@dimen/content_padding_20"
+        android:layout_weight="5"
+        android:layout_height="40dp"
+        android:background="@drawable/sp_bg_gradient_rectangle_yellow2"
+        android:gravity="center"
+        android:text="我知道了"
+        android:textColor="@color/white"
+        android:textSize="@dimen/text_size_15" />
+</LinearLayout>

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

@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:background="#ffffff"
+    android:orientation="vertical">
+
+    <ImageView
+        android:id="@+id/iv_close"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_gravity="right"
+        android:src="@mipmap/try_dialog_x" />
+
+    <TextView
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="10dp"
+        android:layout_marginRight="10dp"
+        android:layout_marginTop="@dimen/content_padding_20"
+        android:lineSpacingExtra="2dp"
+        android:textColor="@color/black"
+        android:text="你来晚啦,小懒猪!"
+        android:gravity="center_horizontal"
+        android:textSize="@dimen/text_size_5" />
+
+    <TextView
+        android:id="@+id/sign_tv_count"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="10dp"
+        android:layout_marginRight="10dp"
+        android:layout_marginTop="@dimen/content_padding_20"
+        android:lineSpacingExtra="2dp"
+        android:textColor="@color/black"
+        android:textSize="@dimen/text_size_3" />
+
+    <TextView
+        android:id="@+id/dialog_sure"
+        android:layout_width="match_parent"
+        android:layout_height="40dp"
+        android:layout_marginBottom="@dimen/content_padding_20"
+        android:layout_marginLeft="@dimen/content_padding_20"
+        android:layout_marginRight="@dimen/content_padding_20"
+        android:layout_marginTop="20dp"
+        android:layout_weight="5"
+        android:background="@drawable/sp_bg_gradient_rectangle_yellow2"
+        android:gravity="center"
+        android:text="我知道了"
+        android:textColor="@color/white"
+        android:textSize="@dimen/text_size_15" />
+</LinearLayout>

+ 54 - 0
app/src/main/res/layout/x_sign_type_dialog.xml

@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:background="#ffffff"
+    android:orientation="vertical">
+
+    <ImageView
+        android:id="@+id/iv_close"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_gravity="right"
+        android:src="@mipmap/try_dialog_x" />
+
+    <TextView
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="10dp"
+        android:layout_marginRight="10dp"
+        android:layout_marginTop="@dimen/content_padding_20"
+        android:lineSpacingExtra="2dp"
+        android:textColor="@color/black"
+        android:text="已报名成功!"
+        android:gravity="center_horizontal"
+        android:textSize="@dimen/text_size_5" />
+
+    <TextView
+        android:id="@+id/sign_tv_count"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="10dp"
+        android:layout_marginRight="10dp"
+        android:layout_marginTop="@dimen/content_padding_20"
+        android:lineSpacingExtra="2dp"
+        android:text="记得明日7:00-9:00过来打卡平分奖金哦!"
+        android:gravity="center_horizontal"
+        android:textColor="@color/black"
+        android:textSize="@dimen/text_size_3" />
+
+    <TextView
+        android:id="@+id/dialog_sure"
+        android:layout_width="match_parent"
+        android:layout_height="40dp"
+        android:layout_marginBottom="@dimen/content_padding_20"
+        android:layout_marginLeft="@dimen/content_padding_20"
+        android:layout_marginRight="@dimen/content_padding_20"
+        android:layout_marginTop="20dp"
+        android:layout_weight="5"
+        android:background="@drawable/sp_bg_gradient_rectangle_yellow2"
+        android:gravity="center"
+        android:text="我知道了"
+        android:textColor="@color/white"
+        android:textSize="@dimen/text_size_15" />
+</LinearLayout>

+ 1 - 1
app/src/main/res/values/strings.xml

@@ -30,7 +30,7 @@
     <string name="contact_qq_email">联系QQ/邮箱</string>
     <string name="input_notice_feedback">请留下您的联系方式,我们会不定期地给予优质建议提供丰厚奖励哦!</string>
     <string name="accessibility_desc">小绵羊任务</string>
-    <string name="sign_card_text">·每日00:00-23:59:00之间支付1元,即可有机会参与次日打卡活动;\n·次日凌晨07:00-09:00时间段参与打卡后,可平分前日奖金池内全部现金,
+    <string name="sign_card_text">·每日<font color="red">00:00-23:59:00</font>之间支付<font color="red">1</font>元,即可有机会参与次日打卡活动;\n·次日早晨<font color="red">07:00-09:00</font>时间段参与打卡后,可平分前日奖金池内全部现金,
     打卡失败则不可参与当日奖金分配;\n·每日平分金额于早9点后开始结算,系统将于12小时内发放到个人账户,因网络原因,部分用户
     可能出现不及时到账的情况,可与我们客户联系,感谢您的谅解。\n·本活动最终解释权归橙风有量科技有限公司所有.</string>