47">1447
                                iv_pgrade.setVisibility(View.GONE);
1448
                            } else {
1449
                                double d = Double.parseDouble(grade);
1450
                                if (d == 0) {
1451
                                    iv_pgrade.setVisibility(View.GONE);
1452
                                } else {
1453
                                    if (d > 0 && d < 1) {
1454
                                        iv_pgrade.setImageResource(R.drawable.icon_05xing);
1455
                                        iv_pgrade.setVisibility(View.VISIBLE);
1456
                                    } else if (d >= 1 && d < 1.5) {
1457
                                        iv_pgrade.setVisibility(View.VISIBLE);
1458
                                        iv_pgrade.setImageResource(R.drawable.icon_1xing);
1459
                                    } else if (d >= 1.5 && d < 2) {
1460
                                        iv_pgrade.setVisibility(View.VISIBLE);
1461
                                        iv_pgrade.setImageResource(R.drawable.icon_15xing);
1462
                                    } else if (d >= 2 && d < 2.5) {
1463
                                        iv_pgrade.setVisibility(View.VISIBLE);
1464
                                        iv_pgrade.setImageResource(R.drawable.icon_2xing);
1465
                                    } else if (d >= 2.5 && d < 3) {
1466
                                        iv_pgrade.setVisibility(View.VISIBLE);
1467
                                        iv_pgrade.setImageResource(R.drawable.icon_25xing);
1468
                                    } else if (d >= 3 && d < 3.5) {
1469
                                        iv_pgrade.setVisibility(View.VISIBLE);
1470
                                        iv_pgrade.setImageResource(R.drawable.icon_3xing);
1471
                                    } else if (d >= 3.5 && d < 4) {
1472
                                        iv_pgrade.setVisibility(View.VISIBLE);
1473
                                        iv_pgrade.setImageResource(R.drawable.icon_35xing);
1474
                                    } else if (d >= 4 && d < 4.5) {
1475
                                        iv_pgrade.setVisibility(View.VISIBLE);
1476
                                        iv_pgrade.setImageResource(R.drawable.icon_4xing);
1477
                                    } else if (d >= 4.5 && d < 5) {
1478
                                        iv_pgrade.setVisibility(View.VISIBLE);
1479
                                        iv_pgrade.setImageResource(R.drawable.icon_45xing);
1480
                                    } else {
1481
                                        iv_pgrade.setVisibility(View.VISIBLE);
1482
                                        iv_pgrade.setImageResource(R.drawable.icon_5xing);
1483
                                    }
1484
                                }
1485
                            }
1486
                        }else{
1487
                            rl_new_comment.setVisibility(View.GONE);
1488
                        }
1489
                    } catch (Exception e) {
1490
1491
                    }
1297 1492
                }
1298 1493
            }
1299
        }).start();
1494
        });
1300 1495
    }
1301 1496
1302 1497
    @Override

+ 9 - 1
app/src/main/java/com/electric/chargingpile/fragment/ZhanCommentFragment.java

@ -374,7 +374,15 @@ public class ZhanCommentFragment extends Fragment {
374 374
375 375
                                for (int j = 0; j < jsonArray.length(); j++) {
376 376
                                    JSONObject jsonObject = (JSONObject) jsonArray.opt(j);
377
                                    datas.add(jsonObject);
377
                                    String is_play = TextUtils.isEmpty( jsonObject.getString("is_play"))?"": jsonObject.getString("is_play")  ; //0 审核未通过 item隐藏,1 审核通过,item显示
378
                                    String type = TextUtils.isEmpty(jsonObject.getString("type"))?"":jsonObject.getString("type"); //23 视频,24 图片
379
                                    if (type.equals("23")){
380
                                        if (is_play.equals("1")){
381
                                            datas.add(jsonObject);
382
                                        }
383
                                    }else{
384
                                        datas.add(jsonObject);
385
                                    }
378 386
                                }
379 387
380 388
                                if (isClear == false) {

+ 10 - 0
app/src/main/res/drawable/bg_main_notification.xml

@ -0,0 +1,10 @@
1
<?xml version="1.0" encoding="utf-8"?>
2
<shape xmlns:android="http://schemas.android.com/apk/res/android"
3
    android:shape="rectangle" >
4
5
    <!-- 表示shape的四个角的角度。只适用于矩形shape,这里的角度是指圆角的程度 -->
6
    <corners android:radius="20dp" />
7
8
    <!-- 这个标签表示纯色填充,通过android:color即可指定shape中填充的颜色 -->
9
    <solid android:color="#FDF6EE" />
10
</shape>

+ 36 - 0
app/src/main/res/layout/activity_main_map.xml

@ -1519,6 +1519,42 @@
1519 1519
                android:src="@drawable/icon_main_oreder_more" />
1520 1520
1521 1521
        </RelativeLayout>
1522
        <RelativeLayout
1523
            android:layout_marginStart="54dp"
1524
            android:layout_marginEnd="54dp"
1525
            android:id="@+id/layoutNotification"
1526
            tools:visibility="visible"
1527
            android:layout_width="match_parent"
1528
            android:layout_height="wrap_content"
1529
            android:layout_marginLeft="15dp"
1530
            android:layout_marginRight="15dp"
1531
            android:background="@drawable/bg_main_notification"
1532
            android:visibility="gone">
1533
1534
            <TextView
1535
                android:paddingStart="20dp"
1536
                android:id="@+id/tvNotification"
1537
                android:paddingEnd="25dp"
1538
                android:maxLines="1"
1539
                android:ellipsize="end"
1540
                android:layout_width="wrap_content"
1541
                android:layout_height="34dp"
1542
                android:gravity="center"
1543
                android:text="您有一笔订单正在进行中您有一笔订单正在进行中,点击查看详情..."
1544
                android:textColor="@color/huimain"
1545
                android:textSize="13sp" />
1546
1547
            <ImageView
1548
                android:id="@+id/imgNotification"
1549
                android:tint="#707070"
1550
                android:layout_width="15dp"
1551
                android:layout_height="15dp"
1552
                android:layout_alignParentRight="true"
1553
                android:layout_centerVertical="true"
1554
                android:layout_marginRight="8dp"
1555
                android:src="@drawable/icon_close" />
1556
1557
        </RelativeLayout>
1522 1558
1523 1559
        <ImageView
1524 1560
            android:id="@+id/tv_person"

+ 5 - 112
app/src/main/res/layout/fragmen_details_new.xml

@ -667,6 +667,7 @@
667 667
                android:background="@color/ui_f4" />
668 668
669 669
            <RelativeLayout
670
                tools:visibility="visible"
670 671
                android:id="@+id/rl_new_comment"
671 672
                android:layout_width="match_parent"
672 673
                android:layout_height="wrap_content"
@ -696,120 +697,12 @@
696 697
                    android:textColor="@color/ui_68"
697 698
                    android:textSize="14sp" />
698 699
699
                <RelativeLayout
700
                    android:id="@+id/rl_icon"
701
                    android:layout_width="35dp"
702
                    android:layout_height="35dp"
703
                    android:layout_below="@+id/tv_new"
704
                    android:layout_alignParentStart="true"
705
                    android:layout_alignParentLeft="true"
706
                    android:layout_gravity="center_vertical"
707
                    android:layout_marginTop="10dp">
708
709
                    <com.electric.chargingpile.view.CircleImageView
710
                        android:id="@+id/iv_new_icon"
711
                        android:layout_width="35dp"
712
                        android:layout_height="35dp"
713
                        android:src="@drawable/icon_touxiang0128"
714
                        app:border_color="@color/white" />
715
716
                    <ImageView
717
                        android:id="@+id/iv_level_img"
718
                        android:layout_width="15dp"
719
                        android:layout_height="15dp"
720
                        android:layout_alignParentRight="true"
721
                        android:layout_alignParentBottom="true" />
722 700
723
724
                </RelativeLayout>
725
726
727
                <TextView
728
                    android:id="@+id/tv_new_name"
729
                    android:layout_width="wrap_content"
730
                    android:layout_height="wrap_content"
731
                    android:layout_alignTop="@+id/rl_icon"
732
                    android:layout_gravity="center_vertical"
733
                    android:layout_marginLeft="10dp"
734
                    android:layout_toEndOf="@+id/rl_icon"
735
                    android:layout_toRightOf="@+id/rl_icon"
736
                    android:text="EV200车主"
737
                    android:textAppearance="?android:attr/textAppearanceSmall"
738
                    android:textColor="@color/ui_65"
739
                    android:textSize="13sp" />
740
741
                <TextView
742
                    android:id="@+id/tv_new_car"
743
                    android:layout_width="wrap_content"
744
                    android:layout_height="wrap_content"
745
                    android:layout_alignTop="@+id/tv_new_name"
746
                    android:layout_gravity="center_vertical"
747
                    android:layout_marginLeft="5dp"
748
                    android:layout_toEndOf="@+id/tv_new_name"
749
                    android:layout_toRightOf="@+id/tv_new_name"
750
                    android:text="北京市"
751
                    android:textAppearance="?android:attr/textAppearanceSmall"
752
                    android:textColor="#888888"
753
                    android:textSize="13sp" />
754
755
                <ImageView
756
                    android:id="@+id/iv_new_pingfen"
757
                    android:layout_width="wrap_content"
758
                    android:layout_height="wrap_content"
759
                    android:layout_alignTop="@+id/tv_new_name"
760
                    android:layout_alignParentRight="true"
761
                    android:layout_gravity="center_vertical"
762
                    android:src="@drawable/icon_5xing"
763
                    android:textAppearance="?android:attr/textAppearanceSmall" />
764
765
                <TextView
766
                    android:id="@+id/tv_new_comment"
767
                    android:layout_width="wrap_content"
768
                    android:layout_height="wrap_content"
769
                    android:layout_below="@+id/tv_new_name"
770
                    android:layout_alignStart="@+id/tv_new_name"
771
                    android:layout_alignLeft="@+id/tv_new_name"
772
                    android:layout_marginTop="10dp"
773
                    android:layout_marginRight="15dp"
774
                    android:text=""
775
                    android:textAppearance="?android:attr/textAppearanceSmall"
776
                    android:textSize="15sp"
777
                    android:visibility="gone" />
778
779
                <com.zhy.view.flowlayout.TagFlowLayout
780
                    android:id="@+id/id_flowlayout_activity"
781
                    android:layout_width="fill_parent"
782
                    android:layout_height="wrap_content"
783
                    android:layout_below="@+id/tv_new_comment"
784
                    android:layout_alignLeft="@+id/tv_new_comment"
785
                    android:layout_marginTop="10dp"
786
                    tools:max_select="-1">
787
788
                </com.zhy.view.flowlayout.TagFlowLayout>
789
790
                <ImageView
791
                    android:id="@+id/iv_commentPic"
792
                    android:layout_width="65dp"
793
                    android:layout_height="65dp"
794
                    android:layout_below="@+id/id_flowlayout_activity"
795
                    android:layout_alignLeft="@+id/tv_new_comment"
796
                    android:layout_marginTop="10dp"
797
                    android:scaleType="centerCrop"
798
                    android:visibility="gone" />
799
800
                <TextView
801
                    android:id="@+id/tv_new_time"
802
                    android:layout_width="wrap_content"
701
                <include
702
                    android:layout_below="@+id/tv_new"
703
                    layout="@layout/item_zhancomments"
803 704
                    android:layout_height="wrap_content"
804
                    android:layout_below="@+id/iv_commentPic"
805
                    android:layout_alignStart="@+id/tv_new_comment"
806
                    android:layout_alignLeft="@+id/tv_new_comment"
807
                    android:layout_marginTop="10dp"
808
                    android:layout_marginBottom="8dp"
809
                    android:text="15分钟前"
810
                    android:textAppearance="?android:attr/textAppearanceSmall"
811
                    android:textColor="@color/ui_68"
812
                    android:textSize="12sp" />
705
                    android:layout_width="wrap_content" />
813 706
814 707
            </RelativeLayout>
815 708

Entrar - Gogs: Go Git Service

Entrar