Browse Source

1.根据测试反馈,处理关于审批流详情界面显示异常的问题
2.根据测试反馈,处理关于在切换新旧版本时候出现的显示问题

Bitliker 8 years ago
parent
commit
d785f67dd2

+ 12 - 7
WeiChat/src/main/java/com/xzjmyk/pm/activity/helper/AvatarHelper.java

@@ -94,6 +94,7 @@ public class AvatarHelper {
 //            return;
 
     }
+
     public void displayRoomAvatar(String userId, final ImageView imageView, final boolean isThumb) {
         final String url = getAvatarUrl(userId, isThumb);
         if (TextUtils.isEmpty(url)) {
@@ -137,6 +138,7 @@ public class AvatarHelper {
             display(url, imageView, isThumb);
         }
     }
+
     public void displayAvatar(String userId, final ImageView imageView, final boolean isThumb) {
         final String url = getAvatarUrl(userId, isThumb);
         if (TextUtils.isEmpty(url)) {
@@ -184,7 +186,7 @@ public class AvatarHelper {
 
     public void displayAvatarPng(String userId, final ImageView imageView, final boolean isThumb) {
         final String url = getAvatarUrlPng(userId, isThumb);
-        Log.i("Arison","AvatarHelper:displayAvatar:140:"+url);
+        Log.i("Arison", "AvatarHelper:displayAvatar:140:" + url);
         if (TextUtils.isEmpty(url)) {
             return;
         }
@@ -280,12 +282,13 @@ public class AvatarHelper {
 
     /**
      * 图片的url 转 Bitmap对象
+     *
      * @param userId
      * @param isThumb
      * @return
      */
-    public static Bitmap returnBitmap(String userId,boolean isThumb){
-        final  String urlpath = getAvatarUrl(userId, isThumb);
+    public static Bitmap returnBitmap(String userId, boolean isThumb) {
+        final String urlpath = getAvatarUrl(userId, isThumb);
         Bitmap mBitmap = null;
         try {
             URL url = new URL(urlpath);
@@ -302,10 +305,11 @@ public class AvatarHelper {
 
     /**
      * 图片的 Bitmap对象转 url
+     *
      * @param bitmap
      * @return
      */
-    public static String doBitmapTurnToStringurl(Bitmap bitmap){
+    public static String doBitmapTurnToStringurl(Bitmap bitmap) {
         ByteArrayOutputStream baos = new ByteArrayOutputStream();// outputstream
         bitmap.compress(Bitmap.CompressFormat.PNG, 100, baos);
         byte[] appicon = baos.toByteArray();// 转为byte数组
@@ -362,15 +366,17 @@ public class AvatarHelper {
             display(url, imageAware, isThumb);
         }
     }
+
     public static String getRoomAvatarUrl(String userId, boolean isThumb) {
         String url = null;
         if (isThumb) {
-            url = MyApplication.getInstance().getConfig().AVATAR_THUMB_PREFIX + "/" +  "/" + userId + ".jpg";
+            url = MyApplication.getInstance().getConfig().AVATAR_THUMB_PREFIX + "/" + "/" + userId + ".jpg";
         } else {
-            url = MyApplication.getInstance().getConfig().AVATAR_ORIGINAL_PREFIX + "/" +   "/" + userId + ".jpg";
+            url = MyApplication.getInstance().getConfig().AVATAR_ORIGINAL_PREFIX + "/" + "/" + userId + ".jpg";
         }
         return url;
     }
+
     public static String getAvatarUrl(String userId, boolean isThumb) {
         if (TextUtils.isEmpty(userId)) {
             return null;
@@ -421,7 +427,6 @@ public class AvatarHelper {
     }
 
 
-
     // // 无用
     // public void displayResumeAvatar(String userId, ImageView imageView, boolean isThumb) {
     // String url = getResumeAvatar(userId, isThumb);

+ 7 - 2
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/presenter/ApprovaPresenter.java

@@ -201,17 +201,21 @@ public class ApprovaPresenter implements OnHttpResultListener {
 
     /*提交更新必填字段 submiting*/
     public void loadProcessUpdate(String nodeLog, List<Approval> approvals) {
-        if (!canSubmit()) return;
+        if (!canSubmit())
+            return;
         submit = true;
         StringBuilder pointsBuilder = new StringBuilder();
-        if (!inputAllPoints(pointsBuilder, approvals))
+        if (!inputAllPoints(pointsBuilder, approvals)) {
+            submit = false;
             return;
+        }
         chchePoints = pointsBuilder.toString();
         String url = "common/processUpdate.action";
         Map<String, Object> param = new HashMap<>();
         List<Map<String, Object>> params = new ArrayList<>();
         Map<String, Object> formStore = new HashMap<>();
         if (!inputAllInput(params, formStore, approvals)) {
+            submit = false;
             return;
         }
         if ((formStore.isEmpty() || formStore.size() <= 1) && ListUtils.isEmpty(params)) {
@@ -1025,6 +1029,7 @@ public class ApprovaPresenter implements OnHttpResultListener {
     private int getImByCode(String emCode) {
         if (manager == null) manager = new DBManager();
         String whichsys = CommonUtil.getMaster();
+        if (StringUtils.isEmpty(emCode) || StringUtils.isEmpty(whichsys)) return 0;
         String[] selectionArgs = {emCode, whichsys};
         String selection = "em_code=? and whichsys=?";
         EmployeesEntity employeesEntity = manager.selectForEmployee(selectionArgs, selection);

BIN
WeiChat/src/main/res/drawable-hdpi/avatar_normal.png


BIN
WeiChat/src/main/res/drawable-xhdpi/avatar_normal.png


BIN
WeiChat/src/main/res/drawable-xxhdpi/avatar_normal.png


+ 16 - 14
WeiChat/src/main/res/layout/pop_crm_list.xml

@@ -4,21 +4,23 @@
     xmlns:app="http://schemas.android.com/apk/res-auto"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
-    app:sl_shadowRadius="3dp"
-    app:sl_shadowColor="@color/shadow"
+    app:sl_cornerRadius="0dp"
     app:sl_dx="-1dp"
     app:sl_dy="3dp"
-    app:sl_cornerRadius="0dp">
-<LinearLayout
-    android:layout_width="match_parent"
-    android:layout_height="wrap_content"
-    android:background="@drawable/shape_pop_ll"
-    android:padding="0.5dp"
-    android:orientation="vertical">
-    <ListView
+    app:sl_shadowColor="@color/shadow"
+    app:sl_shadowRadius="3dp">
+
+    <LinearLayout
+        android:layout_width="match_parent"
         android:layout_height="wrap_content"
-        android:dividerHeight="0dp"
-        android:id="@+id/mList"
-        style="@style/ListViewBasic"></ListView>
-</LinearLayout>
+        android:background="@drawable/shape_pop_ll"
+        android:orientation="vertical"
+        android:padding="0.5dp">
+
+        <ListView
+            android:id="@+id/mList"
+            style="@style/ListViewBasic"
+            android:layout_height="wrap_content"
+            android:dividerHeight="0dp"></ListView>
+    </LinearLayout>
 </com.xzjmyk.pm.activity.view.shadow.ShadowLayout>