This commit is contained in:
2020-08-25 15:39:59 +08:00
parent 1b3d934692
commit fcf262d438
7 changed files with 51 additions and 70 deletions

View File

@@ -178,7 +178,6 @@ public class MainActivity extends BaseActivity implements View.OnClickListener{
mTvMap.setTextColor(getResources().getColor(R.color.colorhui)); mTvMap.setTextColor(getResources().getColor(R.color.colorhui));
mTvMy.setTextColor(getResources().getColor(R.color.colorhui)); mTvMy.setTextColor(getResources().getColor(R.color.colorhui));
hideFragment(mHomeFragment, fragmentTransaction); hideFragment(mHomeFragment, fragmentTransaction);
hideFragment(mSendFragment, fragmentTransaction); hideFragment(mSendFragment, fragmentTransaction);
hideFragment(traceFragment, fragmentTransaction); hideFragment(traceFragment, fragmentTransaction);

View File

@@ -13,24 +13,14 @@ import com.fenghoo.seven.R;
import com.fenghoo.seven.main.find.ui.FindFragmenttwo; import com.fenghoo.seven.main.find.ui.FindFragmenttwo;
import com.fenghoo.seven.main.kehu.activity.ShowAty; import com.fenghoo.seven.main.kehu.activity.ShowAty;
import com.fenghoo.seven.test.BaseFragment; import com.fenghoo.seven.test.BaseFragment;
import com.zaaach.citypicker.model.HotCity;
import java.util.ArrayList;
import java.util.List;
/** /**
* 发现 * 发现
*/ */
public class FindFragment extends BaseFragment { public class FindFragment extends BaseFragment {
private int anim;
private boolean enable;
private List<HotCity> hotCities;
private String city;
private String province;
private String adCode;
Context mContext; Context mContext;
View view; View view;
private RelativeLayout rl_privateletter; private RelativeLayout rl_live;
private String pagetype="0";//0是家居 1是私信 private String pagetype="0";//0是家居 1是私信
private RelativeLayout dianpubuju; private RelativeLayout dianpubuju;
private LinearLayout dianyuanbuju; private LinearLayout dianyuanbuju;
@@ -54,24 +44,15 @@ public class FindFragment extends BaseFragment {
view = inflater.inflate(R.layout.criclefragment, container, false); view = inflater.inflate(R.layout.criclefragment, container, false);
getActivity().getSupportFragmentManager().beginTransaction().replace(R.id.container,new FindFragmenttwo()).commit(); getActivity().getSupportFragmentManager().beginTransaction().replace(R.id.container,new FindFragmenttwo()).commit();
initView(view); initView(view);
HotCity();
return view; return view;
} }
private void HotCity() {
hotCities = new ArrayList<>();
hotCities.add(new HotCity("北京", "北京", "101010100"));
hotCities.add(new HotCity("上海", "上海", "101020100"));
hotCities.add(new HotCity("广州", "广东", "101280101"));
hotCities.add(new HotCity("深圳", "广东", "101280601"));
hotCities.add(new HotCity("杭州", "浙江", "101210101"));
}
private void initView(View mContentView) { private void initView(View mContentView) {
marking_fragment = (TextView)view.findViewById(R.id.marking_fragment); marking_fragment = (TextView)view.findViewById(R.id.marking_fragment);
dianpubuju = (RelativeLayout)view.findViewById(R.id.dianpubuju); dianpubuju = (RelativeLayout)view.findViewById(R.id.dianpubuju);
dianyuanbuju = (LinearLayout)view.findViewById(R.id.dianyuanbuju); dianyuanbuju = (LinearLayout)view.findViewById(R.id.dianyuanbuju);
rl_privateletter = (RelativeLayout)view.findViewById(R.id.rl_privateletter); rl_live = (RelativeLayout)view.findViewById(R.id.rl_live);
rl_privateletter.setOnClickListener(new View.OnClickListener() { rl_live.setOnClickListener(new View.OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
if(pagetype.equals("0")){ if(pagetype.equals("0")){
@@ -103,10 +84,7 @@ public class FindFragment extends BaseFragment {
public void onClick(View view) { public void onClick(View view) {
// ShowAty.CloundSolutionActivity(getActivity()); // ShowAty.CloundSolutionActivity(getActivity());
ShowAty.MainActivitytwot(getActivity()); ShowAty.MainActivitytwot(getActivity());
} }
}); });
} }
} }

View File

@@ -8,17 +8,17 @@ import android.view.ViewGroup;
import android.widget.RelativeLayout; import android.widget.RelativeLayout;
import com.fenghoo.seven.R; import com.fenghoo.seven.R;
import com.fenghoo.seven.base.BaseFragment;
import com.fenghoo.seven.main.find.ui.PrivateletterFragment; import com.fenghoo.seven.main.find.ui.PrivateletterFragment;
import com.fenghoo.seven.test.BaseFragment;
/** /**
* 私信 * 视频评论(页面)
*/ */
public class PriLetFragment extends BaseFragment { public class PriLetFragment extends BaseFragment {
Context mContext; Context mContext;
View view; View view;
private RelativeLayout rl_live; private RelativeLayout rl_privateletter;
@Override @Override
@@ -43,7 +43,7 @@ public class PriLetFragment extends BaseFragment {
} }
private void initView(View mContentView) { private void initView(View mContentView) {
rl_live = (RelativeLayout)view.findViewById(R.id.rl_live); rl_privateletter = (RelativeLayout)view.findViewById(R.id.rl_privateletter);
} }
@@ -52,7 +52,7 @@ public class PriLetFragment extends BaseFragment {
} }
public void cutover(final ClickCallback callback) { public void cutover(final ClickCallback callback) {
rl_live.setOnClickListener(new View.OnClickListener() { rl_privateletter.setOnClickListener(new View.OnClickListener() {
@Override @Override
public void onClick(View v) { public void onClick(View v) {
callback.onsuccess(); callback.onsuccess();

View File

@@ -19,6 +19,9 @@ import java.util.List;
import androidx.recyclerview.widget.LinearLayoutManager; import androidx.recyclerview.widget.LinearLayoutManager;
/**
* 私信页面
*/
public class FindFragmenttwo extends MobanFragment { public class FindFragmenttwo extends MobanFragment {
@@ -70,8 +73,9 @@ public class FindFragmenttwo extends MobanFragment {
@Override @Override
public void enterCusDetail(CustomerListBean.ResultBean.DataBean item) { public void enterCusDetail(CustomerListBean.ResultBean.DataBean item) {
//进入查看评论
ShowAty.CommentActivity(getActivity(),20); //进入回话页
ShowAty.ConversationActivity(getActivity());
} }
}); });
} }

View File

@@ -20,7 +20,7 @@ import java.util.List;
import androidx.recyclerview.widget.LinearLayoutManager; import androidx.recyclerview.widget.LinearLayoutManager;
/** /**
* 私信 * 视频评论(列表)
*/ */
public class PrivateletterFragment extends MobanFragment { public class PrivateletterFragment extends MobanFragment {
@@ -72,8 +72,8 @@ public class PrivateletterFragment extends MobanFragment {
@Override @Override
public void enterCusDetail(CustomerListBean.ResultBean.DataBean item) { public void enterCusDetail(CustomerListBean.ResultBean.DataBean item) {
//进入回话页 //进入查看评论
ShowAty.ConversationActivity(getActivity()); ShowAty.CommentActivity(getActivity(),20);
} }
}); });
} }

View File

@@ -14,36 +14,24 @@
android:layout_height="48dp" android:layout_height="48dp"
android:background="@color/colorWhite"> android:background="@color/colorWhite">
<TextView
android:id="@+id/marking_fragment"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="12dp"
android:drawableRight="@mipmap/marking_down_pic"
android:drawablePadding="6dp"
android:text="全国"
android:textColor="#ff333333"
android:textSize="14sp" />
<TextView <TextView
android:id="@+id/marking_fragment_title" android:id="@+id/marking_fragment_title"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_centerInParent="true" android:layout_centerInParent="true"
android:drawableRight="@mipmap/marking_down_pic"
android:drawablePadding="6dp" android:drawablePadding="6dp"
android:text="家居" android:text="私信"
android:textColor="#ff333333" android:textColor="#ff333333"
android:textSize="14sp" /> android:textSize="14sp" />
<RelativeLayout <RelativeLayout
android:id="@+id/rl_privateletter" android:id="@+id/rl_live"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_alignParentRight="true" android:layout_alignParentRight="true"
android:layout_centerVertical="true" android:layout_marginRight="18dp"
android:layout_marginRight="18dp"> android:layout_centerVertical="true">
<ImageView <ImageView
android:id="@+id/message_ivtwo" android:id="@+id/message_ivtwo"
@@ -51,7 +39,7 @@
android:layout_height="21dp" android:layout_height="21dp"
android:layout_centerVertical="true" android:layout_centerVertical="true"
android:layout_marginLeft="12dp" android:layout_marginLeft="12dp"
android:src="@mipmap/icon_watch_k" /> android:src="@mipmap/icon_live" />
<RelativeLayout <RelativeLayout
android:id="@+id/message_num_rltwo" android:id="@+id/message_num_rltwo"
@@ -61,24 +49,12 @@
android:layout_marginTop="13dp" android:layout_marginTop="13dp"
android:layout_toRightOf="@id/message_ivtwo"> android:layout_toRightOf="@id/message_ivtwo">
<TextView
android:id="@+id/left_tvtwo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:background="@mipmap/message_remind"
android:gravity="center"
android:text="0"
android:textColor="@color/colorWhite"
android:textSize="10sp" />
</RelativeLayout> </RelativeLayout>
</RelativeLayout> </RelativeLayout>
</RelativeLayout> </RelativeLayout>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/container" android:id="@+id/container"
android:layout_width="match_parent" android:layout_width="match_parent"

View File

@@ -4,30 +4,43 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<RelativeLayout <RelativeLayout
android:id="@+id/titlebar" android:id="@+id/titlebar"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="48dp" android:layout_height="48dp"
android:background="@color/colorWhite"> android:background="@color/colorWhite">
<TextView
android:id="@+id/marking_fragment"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="12dp"
android:drawableRight="@mipmap/marking_down_pic"
android:drawablePadding="6dp"
android:text="全国"
android:textColor="#ff333333"
android:textSize="14sp" />
<TextView <TextView
android:id="@+id/marking_fragment_title" android:id="@+id/marking_fragment_title"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_centerInParent="true" android:layout_centerInParent="true"
android:drawableRight="@mipmap/marking_down_pic"
android:drawablePadding="6dp" android:drawablePadding="6dp"
android:text="私信" android:text="家居"
android:textColor="#ff333333" android:textColor="#ff333333"
android:textSize="14sp" /> android:textSize="14sp" />
<RelativeLayout <RelativeLayout
android:id="@+id/rl_live" android:id="@+id/rl_privateletter"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="match_parent" android:layout_height="match_parent"
android:layout_alignParentRight="true" android:layout_alignParentRight="true"
android:layout_marginRight="18dp" android:layout_centerVertical="true"
android:layout_centerVertical="true"> android:layout_marginRight="18dp">
<ImageView <ImageView
android:id="@+id/message_ivtwo" android:id="@+id/message_ivtwo"
@@ -35,7 +48,7 @@
android:layout_height="21dp" android:layout_height="21dp"
android:layout_centerVertical="true" android:layout_centerVertical="true"
android:layout_marginLeft="12dp" android:layout_marginLeft="12dp"
android:src="@mipmap/icon_live" /> android:src="@mipmap/icon_watch_k" />
<RelativeLayout <RelativeLayout
android:id="@+id/message_num_rltwo" android:id="@+id/message_num_rltwo"
@@ -45,6 +58,17 @@
android:layout_marginTop="13dp" android:layout_marginTop="13dp"
android:layout_toRightOf="@id/message_ivtwo"> android:layout_toRightOf="@id/message_ivtwo">
<TextView
android:id="@+id/left_tvtwo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:background="@mipmap/message_remind"
android:gravity="center"
android:text="0"
android:textColor="@color/colorWhite"
android:textSize="10sp" />
</RelativeLayout> </RelativeLayout>
</RelativeLayout> </RelativeLayout>