Prechádzať zdrojové kódy

用户标签本地测试通过

zengjiebin 7 rokov pred
rodič
commit
6e38137433

+ 11 - 11
app/build.gradle

@@ -212,15 +212,15 @@ dependencies {
     compile 'com.flipboard:bottomsheet-commons:1.5.3'
     compile 'com.google.protobuf:protobuf-java:3.2.0'
 
-    compile files('libs/open_sdk_r5923_lite.jar')
-    compile files('libs/wechat-sdk-android-with-mta-1.1.6.jar')
-    compile files('libs/umeng_social_tool.jar')
-    compile files('libs/umeng_social_shareboard.jar')
-    compile files('libs/umeng_social_net.jar')
-    compile files('libs/umeng_social_api.jar')
-    compile files('libs/umeng_shareboard_widget.jar')
-    compile files('libs/SocialSDK_WeiXin_Full.jar')
-    compile files('libs/SocialSDK_QQ_Full.jar')
+//    compile files('libs/open_sdk_r5923_lite.jar')
+//    compile files('libs/wechat-sdk-android-with-mta-1.1.6.jar')
+//    compile files('libs/umeng_social_tool.jar')
+//    compile files('libs/umeng_social_shareboard.jar')
+//    compile files('libs/umeng_social_net.jar')
+//    compile files('libs/umeng_social_api.jar')
+//    compile files('libs/umeng_shareboard_widget.jar')
+//    compile files('libs/SocialSDK_WeiXin_Full.jar')
+//    compile files('libs/SocialSDK_QQ_Full.jar')
     compile 'com.zhy:okhttputils:2.6.2'
     //umeng share
     compile files('libs/umeng-share-core-6.9.2.jar')
@@ -229,7 +229,7 @@ dependencies {
     compile files('libs/umeng-shareboard-widget-6.9.2.jar')
     compile files('libs/umeng-sharetool-6.9.2.jar')
     compile files('libs/SecurityEnvSDK-release-1.1.0.jar')
-    compile files('libs/utdid4all-1.1.5.3_proguard.jar')
+//    compile files('libs/utdid4all-1.1.5.3_proguard.jar')
 
     //    compile 'com.kf.framework:kf-utils:latest.integration@aar'
     compile 'com.kf.framework:kf-utils:1.4.5@aar'
@@ -243,7 +243,7 @@ dependencies {
     compile files('libs/jackson-dataformat-xml-2.1.2.jar')
     compile 'io.reactivex:rxandroid:1.2.1'
     compile 'com.github.ithedan:TextViewDrawable:v1.0'
-    compile 'com.github.zhangkexpz:LayoutScroll:v1.0'
+//    compile 'com.github.zhangkexpz:LayoutScroll:v1.0'
     compile 'me.iwf.photopicker:PhotoPicker:0.9.12@aar'
     compile 'com.github.bumptech.glide:glide:4.1.1'
 

+ 3 - 1
app/proguard-rules.pro

@@ -448,4 +448,6 @@
 #==================gson && protobuf==========================
 -dontwarn com.google.**
 -keep class com.google.gson.** {*;}
--keep class com.google.protobuf.** {*;}
+-keep class com.google.protobuf.** {*;}
+#==================libs/utdid4all-1.1.5.3_proguard.jar==========================
+-keep class com.ta.utdid2.** {*;}

+ 7 - 6
app/src/main/java/com/kfzs/duanduan/fragment/FgtPersonalCenter.java

@@ -259,12 +259,13 @@ public class FgtPersonalCenter extends BaseCompatFragment {
                     Jump2View.getInstance().goWeb(getActivity(), "http://smallstation.kfzs.com/h5_faq/#/faq", "FAQ帮助");
                 break;
             case R.id.abourt_us_layout://关于我们
-                Jump2View.getInstance()
-                        .goWebview(
-                                getActivity(),
-                                new WebviewEntity(
-                                        1,
-                                        "关于我们"));
+                Jump2View.getInstance().goNewAboutUs(getActivity());
+//                Jump2View.getInstance()
+//                        .goWebview(
+//                                getActivity(),
+//                                new WebviewEntity(
+//                                        1,
+//                                        "关于我们"));
                 break;
             case R.id.feedbook_layout://意见反馈
                 Jump2View.getInstance()

+ 5 - 0
app/src/main/java/com/sheep/gamegroup/model/api/ApiService.java

@@ -495,6 +495,11 @@ public interface ApiService {
     @GET("app/user/label")
     Observable<BaseMessage> getLabelList();
     /**
+     * 查询标签列表
+     */
+    @POST("app/user/label")
+    Observable<BaseMessage> postLabelList(@Body JSONObject jsonObject);
+    /**
      * 关于我们
      */
     @GET("app/about_us/new_about_us")

+ 89 - 0
app/src/main/java/com/sheep/gamegroup/model/entity/NewAboutUs.java

@@ -0,0 +1,89 @@
+package com.sheep.gamegroup.model.entity;
+
+/**
+ * Created by realicing on 2018/6/8.
+ * realicing@sina.com
+ */
+public class NewAboutUs {
+    private String WechatPlatform;
+
+    private String OfficialAddress;
+
+    private String ComplaintQq;
+
+    private String Title;
+
+    private String Content;
+
+    private String Mailbox;
+
+    private String CooperationQq;
+
+    private int CreateTime;
+
+    private int UpdateTime;
+
+    private int Id;
+
+    public void setWechatPlatform(String WechatPlatform){
+        this.WechatPlatform = WechatPlatform;
+    }
+    public String getWechatPlatform(){
+        return this.WechatPlatform;
+    }
+    public void setOfficialAddress(String OfficialAddress){
+        this.OfficialAddress = OfficialAddress;
+    }
+    public String getOfficialAddress(){
+        return this.OfficialAddress;
+    }
+    public void setComplaintQq(String ComplaintQq){
+        this.ComplaintQq = ComplaintQq;
+    }
+    public String getComplaintQq(){
+        return this.ComplaintQq;
+    }
+    public void setTitle(String Title){
+        this.Title = Title;
+    }
+    public String getTitle(){
+        return this.Title;
+    }
+    public void setContent(String Content){
+        this.Content = Content;
+    }
+    public String getContent(){
+        return this.Content;
+    }
+    public void setMailbox(String Mailbox){
+        this.Mailbox = Mailbox;
+    }
+    public String getMailbox(){
+        return this.Mailbox;
+    }
+    public void setCooperationQq(String CooperationQq){
+        this.CooperationQq = CooperationQq;
+    }
+    public String getCooperationQq(){
+        return this.CooperationQq;
+    }
+    public void setCreateTime(int CreateTime){
+        this.CreateTime = CreateTime;
+    }
+    public int getCreateTime(){
+        return this.CreateTime;
+    }
+    public void setUpdateTime(int UpdateTime){
+        this.UpdateTime = UpdateTime;
+    }
+    public int getUpdateTime(){
+        return this.UpdateTime;
+    }
+    public void setId(int Id){
+        this.Id = Id;
+    }
+    public int getId(){
+        return this.Id;
+    }
+
+}

+ 60 - 32
app/src/main/java/com/sheep/gamegroup/util/Jump2View.java

@@ -9,7 +9,6 @@ import android.net.Uri;
 import android.os.Build;
 import android.os.Bundle;
 import android.provider.Settings;
-import android.support.v4.app.FragmentActivity;
 import android.text.TextUtils;
 import android.view.View;
 import android.view.WindowManager;
@@ -18,7 +17,6 @@ import com.alibaba.fastjson.JSON;
 import com.kfzs.duanduan.ActMain;
 import com.kfzs.duanduan.ActPicturesEnlarge;
 import com.kfzs.duanduan.bean.KFIntentKeys;
-import com.kfzs.duanduan.utils.ApkUtils;
 import com.sheep.gamegroup.absBase.BaseActivity;
 import com.sheep.gamegroup.model.entity.Advertising;
 import com.sheep.gamegroup.model.entity.Agreement;
@@ -26,12 +24,12 @@ import com.sheep.gamegroup.model.entity.BaseMessage;
 import com.sheep.gamegroup.model.entity.CheckUserLabel;
 import com.sheep.gamegroup.model.entity.CreditCard;
 import com.sheep.gamegroup.model.entity.DialogEntity;
+import com.sheep.gamegroup.model.entity.NewAboutUs;
 import com.sheep.gamegroup.model.entity.NewbieTask;
 import com.sheep.gamegroup.model.entity.NewbieTaskRecord;
 import com.sheep.gamegroup.model.entity.TaskAcceptedEty;
 import com.sheep.gamegroup.model.entity.TaskEty;
 import com.sheep.gamegroup.model.entity.UserEntity;
-import com.sheep.gamegroup.model.entity.UserLabelList;
 import com.sheep.gamegroup.model.entity.VersionInfo;
 import com.sheep.gamegroup.model.entity.WebviewEntity;
 import com.sheep.gamegroup.model.util.SheepSubscriber;
@@ -200,29 +198,39 @@ public class Jump2View {
             newbie_task_record.setUser_id((String)o);
             newbie_task_record.setDontShowNewbieTaskDialog(false);
             MyDbManager.getInstance().saveOrUpdate(newbie_task_record);
-            //是否展示协议
-            tryShowAgreement((Activity) context, new Action1<String>() {
-                @Override
-                public void call(String msg) {
-                    if(msg == null || TextUtils.equals(msg, "404")) {
-                        checkLabel((Activity) context, new Action1<BaseMessage>() {
-                            @Override
-                            public void call(BaseMessage baseMessage) {
-                                context.startActivity(intent);
-                            }
-                        });
-                    }else {
-                        G.showToast(msg);
-                        SheepApp.getInstance().quit();
-                    }
-                }
-            });
+            checkOrGoHomePage((Activity) context);
         } else {
             context.startActivity(intent);
         }
     }
 
     /**
+     * 进入主页前需要检查协议或者用户标签
+     * @param activity
+     */
+    private void checkOrGoHomePage(final Activity activity) {
+        //是否展示协议
+        tryShowAgreement(activity, new Action1<String>() {
+            @Override
+            public void call(String msg) {
+                if(msg == null || TextUtils.equals(msg, "404")) {
+                    checkLabel(activity, new Action1<BaseMessage>() {
+                        @Override
+                        public void call(BaseMessage baseMessage) {
+                            final Intent intent = new Intent(activity, ActMain.class);
+                            activity.startActivity(intent);
+                            activity.finish();
+                        }
+                    });
+                }else {
+                    G.showToast(msg);
+                    SheepApp.getInstance().quit();
+                }
+            }
+        });
+    }
+
+    /**
      * 跳到手机登录页面
      * @param context
      * @param o:  0:登录,1:旧手机号,2:新手机号
@@ -1049,14 +1057,14 @@ public class Jump2View {
     }
 
     public void gotoGuide(final Activity activity) {
-        if(BuildConfig.DEBUG){
-            checkLabel(activity, new Action1<BaseMessage>() {
-                @Override
-                public void call(BaseMessage baseMessage) {
-                    gotoMain(activity);
-                }
-            });
-        } else
+//        if(BuildConfig.DEBUG){
+//            checkLabel(activity, new Action1<BaseMessage>() {
+//                @Override
+//                public void call(BaseMessage baseMessage) {
+//                    gotoMain(activity);
+//                }
+//            });
+//        } else
         if(SysAppUtil.isNewSmallSheep(true)){
             Intent intent = new Intent(activity, ActGuide.class);
             activity.startActivity(intent);
@@ -1068,9 +1076,7 @@ public class Jump2View {
     public void gotoMain(Activity activity) {
         String openId = SpUtils.getOpenId(SheepApp.getInstance());
         if (!TextUtils.isEmpty(openId)) {
-            Intent intent = new Intent(activity, com.kfzs.duanduan.ActMain.class);
-            activity.startActivity(intent);
-            activity.finish();
+            checkOrGoHomePage(activity);
         } else {
             goLoginView(activity, null);
             activity.finish();
@@ -1134,7 +1140,7 @@ public class Jump2View {
                         LogUtil.println("baseMessage onNext "+ JSON.toJSONString(baseMessage));
                         CheckUserLabel checkLabel = baseMessage.getData(CheckUserLabel.class);
                         if(
-                                BuildConfig.DEBUG ||
+//                                BuildConfig.DEBUG ||
                                         checkLabel != null && checkLabel.isNeed_set_label()){//需要设置用户标签
                             Jump2View.getInstance().gotoUserLabelList(activity, baseMessage);
                         } else if(action1 != null) {
@@ -1151,4 +1157,26 @@ public class Jump2View {
                     }
                 });
     }
+
+    public void goNewAboutUs(Activity activity) {
+        SheepApp.getInstance().getNetComponent().getApiService().getNewAboutUs()
+                        .subscribeOn(Schedulers.io())
+                        .observeOn(AndroidSchedulers.mainThread())
+                        .subscribe(new SheepSubscriber<BaseMessage>(SheepApp.getInstance()) {
+                            @Override
+                            public void onNext(BaseMessage baseMessage) {
+                                LogUtil.println("baseMessage onNext "+JSON.toJSONString(baseMessage));
+                                NewAboutUs newAboutUs = baseMessage.getData(NewAboutUs.class);
+                                if(newAboutUs != null){
+
+                                }
+                            }
+
+                            @Override
+                            public void onError(BaseMessage baseMessage) {
+                                LogUtil.println("baseMessage onError "+JSON.toJSONString(baseMessage));
+                                G.showToast(baseMessage);
+                            }
+                        });
+    }
 }

+ 1 - 1
app/src/main/java/com/sheep/gamegroup/util/ListUtil.java

@@ -52,7 +52,7 @@ public class ListUtil {
         return size(list) == position + 1;
     }
 
-    private static <T> int size(List<T> list) {
+    public static <T> int size(List<T> list) {
         return isEmpty(list) ? 0 : list.size();
     }
 }

+ 93 - 38
app/src/main/java/com/sheep/gamegroup/view/activity/ActUserLabelList.java

@@ -1,17 +1,16 @@
 package com.sheep.gamegroup.view.activity;
 
+import android.support.v7.widget.LinearLayoutManager;
+import android.support.v7.widget.RecyclerView;
+import android.view.LayoutInflater;
 import android.view.View;
-import android.view.ViewGroup;
-import android.widget.AdapterView;
-import android.widget.Checkable;
-import android.widget.CheckedTextView;
-import android.widget.CompoundButton;
-import android.widget.GridView;
-import android.widget.ListView;
-import android.widget.RadioButton;
 import android.widget.TextView;
 
 import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONObject;
+import com.kfzs.android.view.tag.FlowLayout;
+import com.kfzs.android.view.tag.TagAdapter;
+import com.kfzs.android.view.tag.TagFlowLayout;
 import com.sheep.gamegroup.absBase.BaseActivity;
 import com.sheep.gamegroup.model.entity.BaseMessage;
 import com.sheep.gamegroup.model.entity.UserLabel;
@@ -20,8 +19,10 @@ import com.sheep.gamegroup.model.util.SheepSubscriber;
 import com.sheep.gamegroup.util.Jump2View;
 import com.sheep.gamegroup.util.ListUtil;
 import com.sheep.gamegroup.util.LogUtil;
+import com.sheep.gamegroup.util.ViewHolder;
 import com.sheep.gamegroup.util.ViewUtil;
-import com.sheep.gamegroup.view.adapter.ArrayAdapter;
+import com.sheep.gamegroup.view.adapter.AdbCommonRecycler;
+import com.sheep.jiuyan.samllsheep.BuildConfig;
 import com.sheep.jiuyan.samllsheep.R;
 import com.sheep.jiuyan.samllsheep.SheepApp;
 import com.sheep.jiuyan.samllsheep.utils.G;
@@ -30,6 +31,7 @@ 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;
 
@@ -45,14 +47,14 @@ public class ActUserLabelList extends BaseActivity {
 
 
     @BindView(R.id.user_label_list)
-    ListView user_label_list;
+    RecyclerView user_label_list;
 
     @Override
     public void initView() {
         TitleBarUtils
                 .getInstance()
-                .setTitle(this, "请选择用户标签")
-                .setTitleFinish(this);
+                .setTitle(this, "请选择您喜欢的标签")
+                .setTitleListen(this, -2,null);
     }
 
     @Override
@@ -82,41 +84,94 @@ public class ActUserLabelList extends BaseActivity {
                     }
                 });
     }
-
+    private List<UserLabelList> checkLabelList;
     private void loadData(List<UserLabelList> checkLabelList) {
-        user_label_list.setAdapter(new ArrayAdapter<UserLabelList>(this, R.layout.user_label_item, checkLabelList) {
+        this.checkLabelList = checkLabelList;
+        user_label_list.setLayoutManager(new LinearLayoutManager(SheepApp.getInstance()));
+        user_label_list.setAdapter(new AdbCommonRecycler<UserLabelList>(SheepApp.getInstance(), checkLabelList){
+
             @Override
-            public boolean convert(final int position, final View rootConvertView, ViewGroup parent, final UserLabelList item) {
-                TextView user_label_tv = (TextView) rootConvertView.findViewById(R.id.user_label_tv);
-                GridView user_label_gv = (GridView) rootConvertView.findViewById(R.id.user_label_gv);
-                ViewUtil.setText(user_label_tv, item.getLabel_type_name());
-                user_label_gv.setAdapter(new ArrayAdapter<UserLabel>(ActUserLabelList.this, R.layout.user_label, item.getLabels()) {
-                    @Override
-                    public boolean convert(int position, final View convertView, ViewGroup parent, final UserLabel item) {
-                        if (convertView instanceof TextView) {
-                            ViewUtil.setText((TextView) convertView, item.getLabel_name());
+            public int getViewIdByType(int type) {
+                return R.layout.user_label_item;
+            }
+
+            @Override
+            public void convert(ViewHolder holder, final UserLabelList userLabelList) {
+                View rootConvertView = holder.itemView;
+                TextView user_label_tv = rootConvertView.findViewById(R.id.user_label_tv);
+                ViewUtil.setText(user_label_tv, userLabelList.getLabel_type_name());
+
+                TagFlowLayout tagList = rootConvertView.findViewById(R.id.user_label_tagflow_layout);
+                if(tagList != null) {
+                    TagAdapter adapter = new TagAdapter<UserLabel>(userLabelList.getLabels()) {
+                        @Override
+                        public View getView(FlowLayout parent, int position, UserLabel userLabel) {
+
+                            TextView tv = (TextView) LayoutInflater.from(ActUserLabelList.this).inflate(R.layout.user_label, parent, false);
+                            ViewUtil.setText(tv, userLabel.getLabel_name());
+                            return tv;
                         }
-                        return true;
-                    }
-                });
-                user_label_gv.setOnItemClickListener(new AdapterView.OnItemClickListener() {
-                    @Override
-                    public void onItemClick(AdapterView<?> adapterView, View view, int i, long l) {
-                        UserLabel userLabel;
-                        if ((userLabel = ListUtil.getIndex(item.getLabels(), i)) != null) {
-                            userLabel.setChecked(!userLabel.isChecked());
+                    };
+
+                    tagList.setAdapter(adapter);
+                    tagList.setOnTagClickListener(new TagFlowLayout.OnTagClickListener() {
+                        @Override
+                        public boolean onTagClick(View view, int position, FlowLayout parent) {
+                            UserLabel userLabel = ListUtil.getIndex(userLabelList.getLabels(), position);
+                            if(userLabel != null) {
+                                userLabel.setChecked(!userLabel.isChecked());
+                                return true;
+                            }
+                            return false;
                         }
-                        if(view instanceof CheckedTextView)
-                            ((CheckedTextView) view).setChecked(userLabel != null && userLabel.isChecked());
-                    }
-                });
-                return true;
+                    });
+                }
             }
         });
+
+    }
+    @OnClick({R.id.user_label_commit_tv})
+    public void onViewClicked(View view) {
+        switch (view.getId()) {
+            case R.id.user_label_commit_tv:
+                toCommit();
+                break;
+        }
+    }
+
+    private void toCommit() {
+        List<Integer> list = ListUtil.emptyList();
+        for (UserLabelList userLabelList : checkLabelList) {
+            for (UserLabel userLabel : userLabelList.getLabels()) {
+                if(userLabel.isChecked()) {
+                    list.add(userLabel.getLabel_id());
+                }
+            }
+        }
+        LogUtil.println("用户标签:"+list.size());
+        JSONObject jsonObject = new JSONObject();
+        jsonObject.put("label_ids", list);
+        SheepApp.getInstance().getNetComponent().getApiService().postLabelList(jsonObject)
+                        .subscribeOn(Schedulers.io())
+                        .observeOn(AndroidSchedulers.mainThread())
+                        .subscribe(new SheepSubscriber<BaseMessage>(SheepApp.getInstance()) {
+                            @Override
+                            public void onNext(BaseMessage baseMessage) {
+                                LogUtil.println("baseMessage onNext "+JSON.toJSONString(baseMessage));
+                                finish();
+                            }
+
+                            @Override
+                            public void onError(BaseMessage baseMessage) {
+                                LogUtil.println("baseMessage onError "+JSON.toJSONString(baseMessage));
+                                G.showToast(baseMessage);
+                            }
+                        });
     }
 
     @Override
     public void finish() {
-        Jump2View.getInstance().gotoMain(this);
+        Jump2View.getInstance().goHomePageView(ActUserLabelList.this, null);
+        super.finish();
     }
 }

+ 0 - 1
app/src/main/java/com/sheep/gamegroup/view/activity/LoginAct.java

@@ -174,7 +174,6 @@ public class LoginAct extends BaseUMActivity implements LoginContract.View {
         showToast(msg);
         hideProgress();
         Jump2View.getInstance().goHomePageView(this, invitation_code);
-        finish();
 
     }
 

+ 0 - 2
app/src/main/java/com/sheep/gamegroup/view/activity/PhoneAct.java

@@ -259,8 +259,6 @@ public class PhoneAct extends BaseActivity implements PhoneContract.View {
         }
 
         Jump2View.getInstance().goHomePageView(this, EntityUtils.getUserCode(loginEty));
-        ActivityManager.getInstance().endActivity(LoginAct.class);
-        finish();
         Log.e("---login_-", o.toString());
     }
 

+ 4 - 0
app/src/main/java/com/sheep/gamegroup/view/adapter/AdbCommonRecycler.java

@@ -21,6 +21,10 @@ public abstract class AdbCommonRecycler<T> extends RecyclerView.Adapter<ViewHold
     public AdbCommonRecycler(Context context) {
         this.context = context;
     }
+    public AdbCommonRecycler(Context context, List<T> list) {
+        this.context = context;
+        listDatas = list;
+    }
     public Context getContext(){
         return context;
     }

+ 23 - 0
app/src/main/res/drawable/layer_list_check_rectgangle.xml

@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
+    <!--第一层-->
+    <item>
+        <shape
+            android:shape="rectangle">
+            <corners android:radius="@dimen/radius_25" />
+            <solid
+                android:color="@color/theme_app_highlight_more_trans" />
+        </shape>
+    </item>
+    <!--第二层-->
+    <item>
+        <shape xmlns:android="http://schemas.android.com/apk/res/android"
+            android:shape="rectangle">
+            <corners android:radius="@dimen/radius_25" />
+            <stroke
+                android:width="1dp"
+                android:color="@color/theme_app_highlight_more" />
+        </shape>
+    </item>
+
+</layer-list>

+ 1 - 6
app/src/main/res/drawable/selector_check_stroke_main.xml

@@ -1,10 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
 <selector xmlns:android="http://schemas.android.com/apk/res/android" >
-  <item android:state_enabled="false" android:drawable="@drawable/button_full_normal_gray" />
-  <item android:state_activated="true" android:drawable="@drawable/btn_main_stroke_click" />
-  <item android:state_focused="true" android:drawable="@drawable/btn_main_stroke_click" />
-  <item android:state_checked="true" android:drawable="@drawable/btn_main_stroke_click"/>
-  <item android:state_selected="true" android:drawable="@drawable/btn_main_stroke_click"/>
-  <item android:state_pressed="true" android:drawable="@drawable/btn_main_stroke_click"/>
+  <item android:state_checked="true" android:drawable="@drawable/layer_list_check_rectgangle"/>
   <item android:drawable="@drawable/btn_main_stroke_no_check"/>
 </selector>

+ 7 - 4
app/src/main/res/layout/act_user_label_list.xml

@@ -6,11 +6,14 @@
 
     <include layout="@layout/title" />
 
-    <ListView
+    <android.support.v7.widget.RecyclerView
         android:id="@+id/user_label_list"
         android:layout_width="match_parent"
-        android:layout_height="match_parent"
-        android:listSelector="@android:color/transparent"
+        android:layout_height="0dp"
+        android:layout_weight="1"
         android:layout_margin="@dimen/content_padding_10"/>
-
+    <TextView
+        android:id="@+id/user_label_commit_tv"
+        style="@style/style_button"
+        android:text="选好了进入首页"/>
 </LinearLayout>

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

@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<CheckedTextView xmlns:android="http://schemas.android.com/apk/res/android"
+<TextView xmlns:android="http://schemas.android.com/apk/res/android"
     android:id="@+id/user_label_tv"
     style="@style/style_check_stroke"
     android:text="小标签" />

+ 26 - 18
app/src/main/res/layout/user_label_item.xml

@@ -1,29 +1,37 @@
 <?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
-    android:padding="@dimen/content_padding_10"
-    android:minHeight="100dp"
-    android:orientation="horizontal">
+    xmlns:app="http://schemas.android.com/apk/res-auto"
+    android:paddingStart="@dimen/content_padding_20"
+    android:paddingEnd="@dimen/content_padding_20"
+    android:paddingTop="@dimen/content_padding_20"
+    android:paddingBottom="@dimen/content_padding_10"
+    android:layout_marginTop="@dimen/content_padding_10"
+    android:background="@drawable/x_shap_shadow_bg_rectgangle_white">
+    <ImageView
+        android:id="@+id/user_label_iv"
+        android:layout_width="20dp"
+        android:layout_height="20dp"
+        app:layout_constraintStart_toStartOf="parent"
+        android:src="@mipmap/user_label"/>
     <TextView
         android:id="@+id/user_label_tv"
-        android:layout_width="0dp"
+        android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:layout_weight="1"
         android:textSize="20sp"
         android:textColor="@color/black_6_3"
         android:layout_gravity="center_vertical"
-        android:text="标签"/>
-    <com.kfzs.duanduan.view.diag.MyGridview
-        android:id="@+id/user_label_gv"
-        android:layout_width="0dp"
-        android:layout_height="match_parent"
-        android:layout_gravity="start|top"
+        app:layout_constraintTop_toTopOf="@+id/user_label_iv"
+        app:layout_constraintBottom_toBottomOf="@+id/user_label_iv"
         android:layout_marginStart="@dimen/content_padding_10"
-        android:horizontalSpacing="@dimen/content_padding_20"
-        android:verticalSpacing="@dimen/content_padding_10"
-        android:listSelector="@android:color/transparent"
-        android:layout_weight="3"
-        android:numColumns="3"/>
+        app:layout_constraintStart_toEndOf="@id/user_label_iv"
+        android:text="标签"/>
+    <com.kfzs.android.view.tag.TagFlowLayout
+        android:id="@+id/user_label_tagflow_layout"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        app:layout_constraintTop_toBottomOf="@+id/user_label_iv"
+        android:layout_marginTop="@dimen/content_padding_10" />
 
-</LinearLayout>
+</android.support.constraint.ConstraintLayout>

BIN
app/src/main/res/mipmap-xxhdpi/user_label.webp


+ 1 - 0
app/src/main/res/values/color_app_theme_colors.xml

@@ -10,6 +10,7 @@
     <color name="theme_app_highlight_more">#34a5e7</color>
     <color name="theme_app_highlight_transparent">#cc29d6fd</color>
     <color name="theme_app_highlight_more_transparent">#cc34a5e7</color>
+    <color name="theme_app_highlight_more_trans">#1134a5e7</color>
 
     <!--app theme info color-->
     <color name="theme_app_info_dark">#3b93e5</color>

+ 5 - 2
app/src/main/res/values/dd_styles.xml

@@ -32,9 +32,12 @@
         <item name="android:textSize">@dimen/text_size_15</item>
     </style>
     <style name="style_check_stroke">
-        <item name="android:layout_width">match_parent</item>
+        <item name="android:layout_width">wrap_content</item>
         <item name="android:layout_height">wrap_content</item>
-        <item name="android:padding">5dp</item>
+        <item name="android:paddingTop">5dp</item>
+        <item name="android:paddingBottom">5dp</item>
+        <item name="android:paddingStart">20dp</item>
+        <item name="android:paddingEnd">20dp</item>
         <item name="android:gravity">center</item>
         <item name="android:textAlignment">center</item>
         <item name="android:textColor">@color/selector_color_main_tab</item>