Browse Source

Merge branch 'developer' of https://gitlab.com/Arisono/SkWeiChat-Baidu into feature

# Conflicts:
#	WeiChat/version.properties
#	app_core/common/src/main/java/com/core/net/http/ViewUtil.java
Arison 8 years ago
parent
commit
52b45efa2c
69 changed files with 913 additions and 682 deletions
  1. 1 1
      WeiChat/src/main/AndroidManifest.xml
  2. BIN
      WeiChat/src/main/assets/gif_splash_welcome.gif
  3. 33 2
      WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/MainActivity.java
  4. 158 22
      WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/SplashActivity.java
  5. 1 1
      WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/circle/BusinessCircleActivity.java
  6. 5 3
      WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/activity/oa/OAActivity.java
  7. 0 4
      WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/fragment/WorkPlatFragment.java
  8. BIN
      WeiChat/src/main/res/drawable-hdpi/ic_meeting_address.png
  9. BIN
      WeiChat/src/main/res/drawable-hdpi/ic_meeting_time.png
  10. BIN
      WeiChat/src/main/res/drawable-hdpi/ic_metting_label.png
  11. BIN
      WeiChat/src/main/res/drawable-hdpi/ic_metting_people.png
  12. BIN
      WeiChat/src/main/res/drawable-xhdpi/ic_meeting_address.png
  13. BIN
      WeiChat/src/main/res/drawable-xhdpi/ic_meeting_time.png
  14. BIN
      WeiChat/src/main/res/drawable-xhdpi/ic_metting_label.png
  15. BIN
      WeiChat/src/main/res/drawable-xhdpi/ic_metting_people.png
  16. BIN
      WeiChat/src/main/res/drawable-xxhdpi/ic_meeting_address.png
  17. BIN
      WeiChat/src/main/res/drawable-xxhdpi/ic_meeting_time.png
  18. BIN
      WeiChat/src/main/res/drawable-xxhdpi/ic_metting_label.png
  19. BIN
      WeiChat/src/main/res/drawable-xxhdpi/ic_metting_people.png
  20. 0 4
      WeiChat/src/main/res/layout/activity_book_add.xml
  21. 12 5
      WeiChat/src/main/res/layout/activity_expense_reimbursement.xml
  22. 1 0
      WeiChat/src/main/res/layout/activity_workdaily_detail.xml
  23. 0 18
      WeiChat/src/main/res/layout/item_approval_enclosure.xml
  24. 31 5
      WeiChat/src/main/res/layout/item_mission.xml
  25. 0 1
      WeiChat/src/main/res/layout/item_pop_list.xml
  26. 40 49
      WeiChat/src/main/res/layout/layout_menu_send_qzone_message.xml
  27. 1 1
      WeiChat/src/main/res/values/styles.xml
  28. 58 3
      app_core/common/src/main/java/com/common/file/FileUtils.java
  29. 7 1
      app_core/common/src/main/java/com/core/app/Constants.java
  30. 23 0
      app_core/common/src/main/java/com/core/base/EasyFragment.java
  31. 21 0
      app_core/common/src/main/java/com/core/utils/CommonUtil.java
  32. 1 1
      app_core/common/src/main/java/com/core/utils/NotificationManage.java
  33. 8 3
      app_core/common/src/main/res/drawable/oa_next.xml
  34. 15 11
      app_core/common/src/main/res/layout/act_taskerp_add.xml
  35. 2 0
      app_core/common/src/main/res/layout/activity_common_docui.xml
  36. 2 1
      app_core/common/src/main/res/layout/activity_setting.xml
  37. 0 18
      app_core/common/src/main/res/layout/item_approval_enclosure.xml
  38. 40 49
      app_core/common/src/main/res/layout/layout_menu_send_qzone_message.xml
  39. 2 2
      app_core/common/src/main/res/layout/view_loading.xml
  40. 1 1
      app_core/common/src/main/res/menu/menu_list.xml
  41. 3 0
      app_core/common/src/main/res/values/colors.xml
  42. 42 0
      app_core/network/src/main/java/com/me/network/app/base/HttpParams.java
  43. 3 0
      app_core/network/src/main/java/com/me/network/app/http/HttpRequest.java
  44. 1 1
      app_modular/appbooking/src/main/java/com/modular/booking/activity/services/BServicesActivity.java
  45. 0 5
      app_modular/appbooking/src/main/res/layout/activity_bbooking_add.xml
  46. 2 0
      app_modular/appcontact/src/main/java/com/uas/appcontact/ui/fragment/GroupChatFragment.java
  47. 32 28
      app_modular/appme/src/main/java/com/uas/appme/settings/activity/SettingActivity.java
  48. 8 8
      app_modular/appme/src/main/res/menu/bsetting_more.xml
  49. 20 23
      app_modular/appmessages/src/main/java/com/modular/appmessages/activity/Subscription2Activity.java
  50. 36 1
      app_modular/appmessages/src/main/java/com/modular/appmessages/adapter/ApprovalAdapter.java
  51. 0 185
      app_modular/appmessages/src/main/java/com/modular/appmessages/adapter/MessageAdapter.java
  52. 54 8
      app_modular/appmessages/src/main/java/com/modular/appmessages/adapter/MessageNewAdapter.java
  53. 1 3
      app_modular/appmessages/src/main/java/com/modular/appmessages/presenter/MessagePresenter.java
  54. 27 0
      app_modular/appmessages/src/main/res/layout/item_approval_enclosure.xml
  55. 1 1
      app_modular/appmessages/src/main/res/layout/item_message_header.xml
  56. 19 7
      app_modular/appworks/src/main/java/com/uas/appworks/CRM/erp/activity/UserSelectActivity.java
  57. 8 1
      app_modular/appworks/src/main/java/com/uas/appworks/CRM/erp/adapter/HListViewOneAdapter.java
  58. 2 1
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/ExpenseReimbursementActivity.java
  59. 9 14
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/FlightsActivity.java
  60. 13 7
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/MeetingActivity.java
  61. 30 32
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/OfficeAddressSettingsActivity.java
  62. 27 27
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/SignSeniorSettingActivity.java
  63. 16 19
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/WorkDailyShowActivity.java
  64. 73 89
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/WorkReportAddActivity.java
  65. 5 0
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/form/DataFormDetailActivity.java
  66. 11 11
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/form/FormListSelectActivity.java
  67. 0 1
      app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/utils/approvautils/NodeAdapter.java
  68. 2 0
      app_modular/appworks/src/main/java/com/uas/appworks/OA/platform/activity/PurchaseDetailsActivity.java
  69. 5 4
      app_modular/appworks/src/main/java/com/uas/appworks/activity/CustomerInquiryDetailActivity.java

+ 1 - 1
WeiChat/src/main/AndroidManifest.xml

@@ -110,7 +110,7 @@
     <application
         android:name="com.core.app.MyApplication"
         android:allowBackup="true"
-        android:hardwareAccelerated="false"
+        android:hardwareAccelerated="true"
         android:icon="@drawable/uuu"
         android:label="@string/app_name"
         android:largeHeap="true"

BIN
WeiChat/src/main/assets/gif_splash_welcome.gif


+ 33 - 2
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/MainActivity.java

@@ -14,6 +14,7 @@ import android.os.Build;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.IBinder;
+import android.os.Looper;
 import android.os.Message;
 import android.os.Messenger;
 import android.os.PersistableBundle;
@@ -67,6 +68,7 @@ import com.core.model.User;
 import com.core.model.WorkModel;
 import com.core.net.NetWorkObservable;
 import com.core.net.http.ViewUtil;
+import com.core.net.http.http.OAHttpHelper;
 import com.core.net.volley.ArrayResult;
 import com.core.net.volley.FastVolley;
 import com.core.net.volley.Result;
@@ -107,6 +109,8 @@ import java.util.HashMap;
 import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
+import java.util.Timer;
+import java.util.TimerTask;
 
 import static android.view.View.GONE;
 
@@ -284,12 +288,39 @@ public class MainActivity extends BaseActivity implements ImStatusListener, NetW
 //      animation.setRepeatCount(-1);//设置重复次数
         animation.setFillAfter(true);//动画执行完后是否停留在执行完的状态
         animation.setStartOffset(0);//执行前的等待时间
-        view.setTag(R.id.tag_key,animation);
+        view.setTag(R.id.tag_key, animation);
         return animation;
     }
 
+    private Timer delayTimer;
+    private Runnable uiRunnable=new Runnable() {
+        @Override
+        public void run() {
+            if (main_tab_three != null) {
+                main_tab_three.startAnimation(getImgAnimation(main_tab_three));
+            }
+        }
+    };
+
+    private void delay() {
+        if (delayTimer == null) {
+            delayTimer = new Timer();
+        }
+        delayTimer.schedule(new TimerTask() {
+            @Override
+            public void run() {
+                OAHttpHelper.getInstance().post(uiRunnable);
+            }
+        }, 100);
+    }
+
     private void startAnimator(View view) {
-        view.startAnimation(getImgAnimation(view));
+        if (view != null && main_tab_three == view) {
+            delay();
+        } else {
+            view.startAnimation(getImgAnimation(view));
+
+        }
     }
 
     /**

+ 158 - 22
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/SplashActivity.java

@@ -3,6 +3,7 @@ package com.xzjmyk.pm.activity.ui;
 import android.Manifest;
 import android.annotation.SuppressLint;
 import android.content.Intent;
+import android.graphics.Bitmap;
 import android.os.Bundle;
 import android.os.Handler;
 import android.text.TextUtils;
@@ -13,11 +14,13 @@ import android.view.animation.AnimationUtils;
 import android.widget.RelativeLayout;
 
 import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONArray;
 import com.alibaba.fastjson.JSONObject;
 import com.android.volley.Response;
 import com.android.volley.VolleyError;
 import com.common.LogUtil;
 import com.common.data.JSONUtil;
+import com.common.file.FileUtils;
 import com.common.hmac.Md5Util;
 import com.common.preferences.PreferenceUtils;
 import com.common.system.SystemUtil;
@@ -29,6 +32,8 @@ import com.core.dao.UserDao;
 import com.core.model.ConfigBean;
 import com.core.model.LoginRegisterResult;
 import com.core.model.User;
+import com.core.net.ProgressDownloader;
+import com.core.net.ProgressResponseBody;
 import com.core.net.volley.ObjectResult;
 import com.core.net.volley.Result;
 import com.core.net.volley.StringJsonObjectRequest;
@@ -46,7 +51,10 @@ import com.xzjmyk.pm.activity.R;
 import com.xzjmyk.pm.activity.ui.erp.activity.ADActivity;
 import com.xzjmyk.pm.activity.ui.me.TimeStatisticsActivity;
 
+import java.io.File;
+import java.io.IOException;
 import java.util.HashMap;
+import java.util.List;
 
 import pl.droidsonroids.gif.AnimationListener;
 import pl.droidsonroids.gif.GifDrawable;
@@ -58,7 +66,7 @@ import pl.droidsonroids.gif.GifImageView;
  * @author Dean Tao
  * @version 1.0
  */
-public class SplashActivity extends BaseActivity {
+public class SplashActivity extends BaseActivity implements ProgressResponseBody.ProgressListener {
     private RelativeLayout mSelectLv;
     private GifImageView mGifImageView;
     private final String IS_FIRST = "IS_FIRST";
@@ -67,6 +75,9 @@ public class SplashActivity extends BaseActivity {
     private boolean mConfigReady = false;// 配置获取成功
     private GifDrawable mGifDrawable;
     private boolean mAnimationCompleted = false;
+    private ProgressDownloader mDownloader;
+    private String mSplshUrl;
+    private long mStartTime;
 
     @Override
     protected void onCreate(Bundle savedInstanceState) {
@@ -75,38 +86,135 @@ public class SplashActivity extends BaseActivity {
         getSupportActionBar().hide();
         StatusBarUtil.immersive(this, 0x00000000, 0.0f);
 
+        mStartTime = System.currentTimeMillis();
         new Handler().postDelayed(new Runnable() {
             @Override
             public void run() {
                 jump();
             }
-        }, 3000);
+        }, 2500);
         mGifImageView = findViewById(R.id.splash_gif_view);
+        showSplash();
+        mSelectLv = (RelativeLayout) findViewById(R.id.select_lv);
+        mSelectLv.setVisibility(View.INVISIBLE);
+        initConfig();// 初始化配置
+        updateAccountToken();//更新账户中心token
+        requestSplash();
+    }
+
+    private void showSplash() {
         try {
-            mGifDrawable = new GifDrawable(getAssets(), "gif_splash_welcome.gif");
-            mGifDrawable.setLoopCount(1);
-            mGifDrawable.setSpeed(1f);
-            mGifDrawable.addAnimationListener(new AnimationListener() {
-                @Override
-                public void onAnimationCompleted(int loopNumber) {
-                    Log.d("gifdrawable", "AnimationCompleted");
-                    mAnimationCompleted = true;
-                    if (isJumpable) {
-                        jump();
+            List<String> pictures = FileUtils.getPictures(Constants.SPLASH_FILE_PATH);
+            if (pictures != null && pictures.size() > 0) {
+                String localSplash = pictures.get(0);
+                int dotIndex = localSplash.lastIndexOf(".");
+                if (dotIndex >= 0) {
+                    String resExtension = localSplash.substring(dotIndex + 1).toLowerCase();
+                    if ("gif".equals(resExtension)) {
+                        mGifDrawable = new GifDrawable(new File(localSplash));
+                    } else {
+                        Bitmap localBitmap = FileUtils.getLocalBitmap(localSplash);
+                        mGifImageView.setImageBitmap(localBitmap);
+                        mAnimationCompleted = true;
+                        return;
                     }
+                } else {
+                    mGifDrawable = new GifDrawable(getAssets(), "gif_splash_welcome.gif");
                 }
-            });
-            mGifImageView.setImageDrawable(mGifDrawable);
-
-            mGifDrawable.start();
+            } else {
+                mGifDrawable = new GifDrawable(getAssets(), "gif_splash_welcome.gif");
+            }
         } catch (Exception e) {
+            try {
+                mGifDrawable = new GifDrawable(getAssets(), "gif_splash_welcome.gif");
+            } catch (IOException e1) {
+            }
+        }
+        mGifDrawable.setLoopCount(1);
+        mGifDrawable.setSpeed(1f);
+        mGifDrawable.addAnimationListener(new AnimationListener() {
+            @Override
+            public void onAnimationCompleted(int loopNumber) {
+                mAnimationCompleted = true;
+                if (isJumpable) {
+                    jump();
+                }
+            }
+        });
+        mGifImageView.setImageDrawable(mGifDrawable);
+        mGifDrawable.start();
+    }
 
+    private void requestSplash() {
+        if (!CommonUtil.isNetWorkConnected(mContext)) {
+            return;
         }
+        HttpRequest.getInstance().sendRequest(Constants.IM_BASE_URL,
+                new HttpParams.Builder()
+                        .url("user/appStart")
+                        .method(Method.GET)
+                        .addParam("token", 1)
+                        .build(), new HttpCallback() {
+                    @Override
+                    public void onSuccess(int flag, Object o) throws Exception {
+                        try {
+                            String result = o.toString();
+                            if (JSONUtil.validate(result)) {
+                                JSONObject resultObject = JSON.parseObject(result);
+                                JSONArray resArray = resultObject.getJSONArray("result");
+                                if (resArray != null && resArray.size() > 0) {
+                                    JSONObject resObject = resArray.getJSONObject(0);
+                                    String resUrl = JSONUtil.getText(resObject, "aa_urlc");
+                                    if (!TextUtils.isEmpty(resUrl)) {
+                                        String oldUrl = CommonUtil.getSharedPreferences(mContext, Constants.CACHE.CACHE_SPLASH_URL);
+                                        if (resUrl.equals(oldUrl)) {
+                                            return;
+                                        } else {
+                                            initSplashDir();
+                                            mSplshUrl = resUrl;
+                                            downloadSplash(resUrl);
+                                        }
+                                    } else {
+                                        initSplashDir();
+                                        CommonUtil.setSharedPreferences(mContext, Constants.CACHE.CACHE_SPLASH_URL, "");
+                                    }
+                                } else {
+                                    initSplashDir();
+                                    CommonUtil.setSharedPreferences(mContext, Constants.CACHE.CACHE_SPLASH_URL, "");
+                                }
+                            }
+                        } catch (Exception e) {
+                        }
+                    }
 
-        mSelectLv = (RelativeLayout) findViewById(R.id.select_lv);
-        mSelectLv.setVisibility(View.INVISIBLE);
-        initConfig();// 初始化配置
-        updateAccountToken();//更新账户中心token
+                    @Override
+                    public void onFail(int flag, String failStr) throws Exception {
+                    }
+                });
+    }
+
+    private void initSplashDir() {
+        File directory = new File(Constants.SPLASH_FILE_PATH);
+        if (!directory.exists() && !directory.isDirectory()) {
+            boolean mkdirs = directory.mkdirs();
+        } else {
+            CommonUtil.delAllFile(Constants.SPLASH_FILE_PATH);
+        }
+    }
+
+    private void downloadSplash(String resUrl) {
+        int dotIndex = resUrl.lastIndexOf(".");
+        if (dotIndex >= 0) {
+            String resExtension = resUrl.substring(dotIndex);
+            File splashFile = new File(Constants.SPLASH_FILE_PATH, Constants.SPLASH_FILE_NAME + resExtension);
+            try {
+                splashFile.createNewFile();
+            } catch (IOException e) {
+                e.printStackTrace();
+            }
+            mDownloader = new ProgressDownloader(resUrl, splashFile, SplashActivity.this);
+            mDownloader.download(0L);
+        }
     }
 
     @Override
@@ -192,6 +300,18 @@ public class SplashActivity extends BaseActivity {
             return;
         }
 
+        long currentTime = System.currentTimeMillis();
+        long duration = currentTime - mStartTime;
+        if (duration < 2500) {
+            new Handler().postDelayed(new Runnable() {
+                @Override
+                public void run() {
+                    jump();
+                }
+            }, 2500 - duration);
+            return;
+        }
+
         int userStatus = LoginHelper.prepareUser(mContext);
         switch (userStatus) {
             case LoginHelper.STATUS_USER_FULL://5
@@ -340,7 +460,23 @@ public class SplashActivity extends BaseActivity {
     @Override
     protected void onDestroy() {
         super.onDestroy();
-        mGifDrawable.recycle();
-        mGifDrawable = null;
+        if (mGifDrawable != null) {
+            mGifDrawable.recycle();
+            mGifDrawable = null;
+        }
+    }
+
+    @Override
+    public void onPreExecute(long contentLength) {
+
+    }
+
+    @Override
+    public void update(long totalBytes, boolean done) {
+        if (done) {
+            if (!TextUtils.isEmpty(mSplshUrl)) {
+                CommonUtil.setSharedPreferences(mContext, Constants.CACHE.CACHE_SPLASH_URL, mSplshUrl);
+            }
+        }
     }
 }

+ 1 - 1
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/circle/BusinessCircleActivity.java

@@ -197,7 +197,7 @@ public class BusinessCircleActivity extends BaseActivity implements showCEView {
         sendqzonecancel_tv = (TextView) mMoreMenuView.findViewById(R.id.send_qzone_cancel);
         mMoreWindow = new PopupWindow(mMoreMenuView, LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT, true);
         mMoreWindow.setAnimationStyle(R.style.MenuAnimationFade);
-        mMoreWindow.setBackgroundDrawable(new BitmapDrawable());
+        mMoreWindow.setBackgroundDrawable(mContext.getResources().getDrawable(com.uas.appme.R.drawable.bg_popuwin));
         mMoreWindow.setOnDismissListener(new PopupWindow.OnDismissListener() {
             @Override
             public void onDismiss() {

+ 5 - 3
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/activity/oa/OAActivity.java

@@ -807,6 +807,7 @@ public class OAActivity extends SupportToolBarActivity implements View.OnClickLi
             plist.setOnItemClickListener(new AdapterView.OnItemClickListener() {
                 @Override
                 public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
+                    LogUtil.i("onItemClick");
                     Intent intent = null;
                     popupWindow.dismiss();
                     switch (position) {
@@ -836,14 +837,15 @@ public class OAActivity extends SupportToolBarActivity implements View.OnClickLi
                                     .putExtra("title", name);
                             break;
                     }
-                    if (intent != null)
+                    if (intent != null){
                         startActivityForResult(intent, 0x20);
+                    }
                 }
             });
             popupWindow =new PopupWindow(view);
 //                    new PopupWindow(view, windowManager.getDefaultDisplay().getWidth() / 3, windowManager.getDefaultDisplay().getHeight() / 3);
             popupWindow.setWidth(DisplayUtil.dip2px(ct,140));
-            popupWindow.setHeight(DisplayUtil.dip2px(ct,150));
+            popupWindow.setHeight(DisplayUtil.dip2px(ct,135));
             }
         // 使其聚集
         popupWindow.setFocusable(true);
@@ -860,7 +862,7 @@ public class OAActivity extends SupportToolBarActivity implements View.OnClickLi
         popupWindow.setBackgroundDrawable(getResources().getDrawable(R.drawable.top_bubble));
 //        popupWindow.setHeight(ViewGroup.LayoutParams.WRAP_CONTENT);
         // 显示的位置为:屏幕的宽度的一半-PopupWindow的高度的一半
-        popupWindow.showAsDropDown(parent, windowManager.getDefaultDisplay().getWidth()-DisplayUtil.dip2px(ct,10), 0);
+        popupWindow.showAsDropDown(parent, -DisplayUtil.dip2px(ct,100), 0);
     }
 
     private List<Map<String, Object>> getPopData() {

+ 0 - 4
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/fragment/WorkPlatFragment.java

@@ -158,8 +158,6 @@ public class WorkPlatFragment extends BaseMVPFragment<WorkPlatPresenter> impleme
 
                 @Override
                 public void onHeaderPulling(RefreshHeader header, float percent, int offset, int headerHeight, int extendHeight) {
-                    Log.d("工作台下拉", "offset->" + offset + "||percent->" + percent + "||headerHeight->" + headerHeight + "||extendHeight->" + extendHeight);
-
                     ViewGroup.LayoutParams layoutParams = mHeaderRelativeLayout.getLayoutParams();
                     layoutParams.height = (int) (mHeaderHeight * (1 + percent));
                     mHeaderRelativeLayout.setLayoutParams(layoutParams);
@@ -169,8 +167,6 @@ public class WorkPlatFragment extends BaseMVPFragment<WorkPlatPresenter> impleme
 
                 @Override
                 public void onHeaderReleasing(RefreshHeader header, float percent, int offset, int headerHeight, int extendHeight) {
-                    Log.d("工作台释放", "offset->" + offset + "||percent->" + percent + "||headerHeight->" + headerHeight + "||extendHeight->" + extendHeight);
-
                     ViewGroup.LayoutParams layoutParams = mHeaderRelativeLayout.getLayoutParams();
                     layoutParams.height = (int) (mHeaderHeight * (1 + percent));
                     mHeaderRelativeLayout.setLayoutParams(layoutParams);

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


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


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


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


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


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


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


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


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


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


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


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


+ 0 - 4
WeiChat/src/main/res/layout/activity_book_add.xml

@@ -25,7 +25,6 @@
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:layout_marginLeft="40dp"
-                android:layout_marginTop="@dimen/padding"
                 android:text="*"
                 android:textColor="@color/red" />
             <TextView
@@ -51,7 +50,6 @@
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:layout_marginLeft="40dp"
-                android:layout_marginTop="@dimen/padding"
                 android:text="*"
                 android:textColor="@color/red" />
             <TextView
@@ -78,7 +76,6 @@
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:layout_marginLeft="40dp"
-                android:layout_marginTop="@dimen/padding"
                 android:text="*"
                 android:textColor="@color/red" />
             <TextView
@@ -107,7 +104,6 @@
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:layout_marginLeft="40dp"
-                android:layout_marginTop="@dimen/padding"
                 android:text="*"
                 android:textColor="@color/red" />
             <EditText

+ 12 - 5
WeiChat/src/main/res/layout/activity_expense_reimbursement.xml

@@ -35,7 +35,8 @@
                 <TextView
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_alignTop="@id/name_tv"
+                    android:layout_marginLeft="10dp"
+                    android:layout_marginTop="10dp"
                     android:layout_toRightOf="@id/name_tv"
                     android:text="*"
                     android:textColor="@color/red" />
@@ -50,7 +51,7 @@
                     android:layout_alignParentRight="true"
                     android:background="@null"
                     android:gravity="center_vertical|right"
-                    android:hint="@string/common_input"
+                    android:hint="@string/common_input2"
                     android:maxLength="30"
                     android:padding="10dp"
                     android:textColor="@color/dark_dark_grey"
@@ -77,13 +78,16 @@
                     android:text="@string/Reimbursement_type"
                     android:textColor="@color/text_main"
                     android:textSize="15sp" />
+
                 <TextView
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_alignTop="@id/type_left"
+                    android:layout_marginLeft="10dp"
+                    android:layout_marginTop="3dp"
                     android:layout_toRightOf="@id/type_left"
                     android:text="*"
                     android:textColor="@color/red" />
+
                 <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
                     android:id="@+id/reimbursement_type_fet"
                     android:layout_width="wrap_content"
@@ -93,7 +97,7 @@
                     android:background="@null"
                     android:ellipsize="end"
                     android:gravity="center_vertical|right"
-                    android:hint="@string/common_select"
+                    android:hint="@string/common_select1"
                     android:padding="10dp"
                     android:singleLine="true"
                     android:textColor="@color/dark_dark_grey"
@@ -125,13 +129,16 @@
                     android:text="@string/currency"
                     android:textColor="@color/text_main"
                     android:textSize="15sp" />
+
                 <TextView
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
-                    android:layout_alignTop="@id/reimbursement_type"
+                    android:layout_marginLeft="10dp"
+                    android:layout_marginTop="3dp"
                     android:layout_toRightOf="@id/reimbursement_type"
                     android:text="*"
                     android:textColor="@color/red" />
+
                 <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
                     android:id="@+id/reimbursement_currency_fet"
                     android:layout_width="100dp"

+ 1 - 0
WeiChat/src/main/res/layout/activity_workdaily_detail.xml

@@ -273,6 +273,7 @@
                     android:layout_width="match_parent"
                     android:layout_height="wrap_content"
                     android:visibility="visible"
+                    android:dividerHeight="0dp"
                     android:background="#ebe9e9"
                     >
                 </com.core.widget.MyListView>

+ 0 - 18
WeiChat/src/main/res/layout/item_approval_enclosure.xml

@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              style="@style/approvalStyle">
-
-    <TextView
-        android:id="@+id/nameTv"
-        android:layout_marginTop="8dp"
-        android:layout_marginBottom="8dp"
-        android:layout_width="match_parent"
-        android:layout_height="match_parent"
-        android:gravity="center|left"
-        android:layout_marginLeft="20dp"
-        android:layout_marginRight="20dp"
-        android:textColor="@color/titleBlue"/>
-
-
-
-</LinearLayout>

+ 31 - 5
WeiChat/src/main/res/layout/item_mission.xml

@@ -52,6 +52,13 @@
             android:textColor="@color/text_main"
             android:textSize="@dimen/text_main" />
 
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="match_parent"
+            android:layout_marginLeft="70dp"
+            android:layout_marginTop="4dp"
+            android:text="*"
+            android:textColor="@color/red"/>
         <TextView
             android:id="@+id/item_company_tv"
             android:layout_width="wrap_content"
@@ -62,7 +69,7 @@
             android:drawableRight="@drawable/company"
             android:ellipsize="end"
             android:gravity="center|right"
-            android:hint="@string/common_select"
+            android:hint="@string/common_select1"
             android:maxLines="2"
             android:textColor="@color/text_hine"
             android:textSize="@dimen/text_hine" />
@@ -92,6 +99,13 @@
             android:textColor="@color/text_main"
             android:textSize="@dimen/text_main" />
         <!--android:drawableRight="@drawable/addr_bule"-->
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="match_parent"
+            android:layout_marginLeft="70dp"
+            android:layout_marginTop="4dp"
+            android:text="*"
+            android:textColor="@color/red"/>
         <TextView
             android:id="@+id/item_companyaddr_tv"
             android:layout_width="wrap_content"
@@ -129,7 +143,13 @@
             android:text="@string/visit_aim"
             android:textColor="@color/text_main"
             android:textSize="@dimen/text_main" />
-
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="match_parent"
+            android:layout_marginLeft="70dp"
+            android:layout_marginTop="4dp"
+            android:text="*"
+            android:textColor="@color/red"/>
         <TextView
             android:id="@+id/item_remark_tv"
             android:layout_width="wrap_content"
@@ -138,7 +158,7 @@
             android:layout_toRightOf="@+id/remark_tag"
             android:drawableRight="@drawable/oa_next"
             android:gravity="center|right"
-            android:hint="@string/common_select"
+            android:hint="@string/common_select1"
             android:minHeight="@dimen/misson_item_height"
             android:textColor="@color/text_hine"
             android:textSize="@dimen/text_hine" />
@@ -371,7 +391,13 @@
             android:text="@string/expected_arrival_time"
             android:textColor="@color/text_main"
             android:textSize="@dimen/text_main" />
-
+        <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="match_parent"
+            android:layout_marginLeft="100dp"
+            android:layout_marginTop="4dp"
+            android:text="*"
+            android:textColor="@color/red"/>
         <TextView
             android:id="@+id/item_reckontime_tv"
             android:layout_width="wrap_content"
@@ -379,7 +405,7 @@
             android:layout_alignParentRight="true"
             android:drawableRight="@drawable/oa_next"
             android:gravity="center"
-            android:hint="@string/common_select"
+            android:hint="@string/common_select1"
             android:textColor="@color/text_main"
             android:textSize="@dimen/text_hine" />
     </RelativeLayout>

+ 0 - 1
WeiChat/src/main/res/layout/item_pop_list.xml

@@ -1,7 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
-    android:clickable="true"
     android:background="@drawable/select_weixin_list_item"
     android:layout_height="wrap_content">
     <TextView

+ 40 - 49
WeiChat/src/main/res/layout/layout_menu_send_qzone_message.xml

@@ -1,54 +1,45 @@
 <?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:orientation="vertical"
-    android:background="@color/white">
+<LinearLayout
+    style="@style/commonPopView"
+    xmlns:android="http://schemas.android.com/apk/res/android">
 
-    <TextView
-        android:id="@+id/send_qzone_text"
+    <LinearLayout
         android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:text="@string/qzone_send_word"
-        android:textColor="@color/black"
-        android:textSize="15sp"/>
-    <View
-        android:layout_width="match_parent"
-        android:layout_height="0.3dp"
-        android:background="@color/button_invalid"/>
-    <TextView
-        android:id="@+id/send_qzone_picture"
-        android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:text="@string/qzone_send_picture"
-        android:textColor="@color/black"
-        android:textSize="15sp"/>
-
-    <View
-        android:layout_width="match_parent"
-        android:layout_height="0.3dp"
-        android:background="@color/button_invalid"/>
-    <TextView
-        android:id="@+id/send_qzone_video"
-        android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:textColor="@color/black"
-        android:text="@string/qzone_send_video"
-        android:textSize="15sp"/>
-    <View
-        android:layout_width="match_parent"
-        android:layout_height="10dp"
-        android:background="@color/black_gray"/>
-    <TextView
-        android:id="@+id/send_qzone_cancel"
-        android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:textColor="@color/black"
-        android:text="@string/common_cancel"
-        android:textSize="15sp"/>
+        android:layout_height="wrap_content"
+        android:background="@drawable/shape_common_pop_option_item"
+        android:orientation="vertical">
+        <TextView
+            android:id="@+id/send_qzone_text"
+            style="@style/commonPopItemTop"
+            android:text="@string/qzone_send_word"
+            />
+        <View
+            android:layout_width="match_parent"
+            android:layout_height="0.3dp"
+            android:background="@color/button_invalid"/>
+        <TextView
+            android:id="@+id/send_qzone_picture"
+            style="@style/commonPopItem"
+            android:text="@string/qzone_send_picture"
+            />
 
+        <View
+            android:layout_width="match_parent"
+            android:layout_height="0.3dp"
+            android:background="@color/button_invalid"/>
+        <TextView
+            android:id="@+id/send_qzone_video"
+            style="@style/commonPopItem"
+            android:text="@string/qzone_send_video"
+            />
+        <View
+            android:layout_width="match_parent"
+            android:layout_height="10dp"
+            android:background="@color/black_gray"/>
+        <TextView
+            android:id="@+id/send_qzone_cancel"
+            style="@style/commonPopCancelItem"
+            android:text="@string/common_cancel"
+            />
+    </LinearLayout>
 </LinearLayout>

+ 1 - 1
WeiChat/src/main/res/values/styles.xml

@@ -998,7 +998,7 @@
     </style>
 
     <!--TabPageIndicatorStyle-->
-    <style name="StyledIndicators" parent="@style/AppTheme">
+    <style name="StyledIndicators" parent="@style/MainBaseTheme">
         <item name="vpiTabPageIndicatorStyle">@style/CustomTabPageIndicator</item>
         <item name="vpiUnderlinePageIndicatorStyle">@style/CustomUnderlinePageIndicator</item>
     </style>

+ 58 - 3
app_core/common/src/main/java/com/common/file/FileUtils.java

@@ -1,6 +1,8 @@
 package com.common.file;
 
 import android.content.Intent;
+import android.graphics.Bitmap;
+import android.graphics.BitmapFactory;
 import android.net.Uri;
 import android.os.Environment;
 import android.util.Log;
@@ -13,6 +15,8 @@ import java.io.FileNotFoundException;
 import java.io.FileOutputStream;
 import java.io.IOException;
 import java.text.DecimalFormat;
+import java.util.ArrayList;
+import java.util.List;
 
 /**
  * Created by Bitliker on 2017/8/10.
@@ -46,10 +50,10 @@ public class FileUtils {
     public static String getMIMEType(File f) {
         String type = "";
         String fName = f.getName();
-      /* 取得扩展名 */
+        /* 取得扩展名 */
         String end = fName.substring(fName.lastIndexOf(".") + 1, fName.length()).toLowerCase();
 
-      /* 依扩展名的类型决定MimeType */
+        /* 依扩展名的类型决定MimeType */
         if (end.equals("pdf")) {
             type = "application/pdf";//
         } else if (end.equals("m4a") || end.equals("mp3") || end.equals("mid") ||
@@ -63,7 +67,7 @@ public class FileUtils {
         } else if (end.equals("apk")) {
             type = "application/vnd.android.package-archive";
         } else {
-        /*如果无法直接打开,就跳出软件列表给用户选择 */
+            /*如果无法直接打开,就跳出软件列表给用户选择 */
             type = "*/*";
         }
         LogUtil.d("下载文件类型:" + type);
@@ -234,4 +238,55 @@ public class FileUtils {
             Log.e("deleteFileOrDir", "delete file no exists " + file.getAbsolutePath());
         }
     }
+
+    /**
+     * 获取SDCard中某个目录下图片路径集合
+     */
+
+    public static List<String> getPictures(final String strPath) {
+        try {
+            List<String> list = new ArrayList<String>();
+            File file = new File(strPath);
+            File[] allfiles = file.listFiles();
+            if (allfiles == null) {
+                return null;
+            }
+            for (int i = 0; i < allfiles.length; i++) {
+                final File fi = allfiles[i];
+                if (fi.isFile()) {
+                    int idx = fi.getPath().lastIndexOf(".");
+                    if (idx <= 0) {
+                        continue;
+                    }
+                    String suffix = fi.getPath().substring(idx);
+                    if (suffix.toLowerCase().equals(".jpg") ||
+                            suffix.toLowerCase().equals(".jpeg") ||
+                            suffix.toLowerCase().equals(".bmp") ||
+                            suffix.toLowerCase().equals(".png") ||
+                            suffix.toLowerCase().equals(".gif")) {
+                        list.add(fi.getPath());
+                    }
+                }
+            }
+            return list;
+        } catch (Exception e) {
+            return null;
+        }
+    }
+
+    /**
+     * 加载本地图片
+     *
+     * @param url
+     * @return
+     */
+    public static Bitmap getLocalBitmap(String url) {
+        try {
+            FileInputStream fis = new FileInputStream(url);
+            return BitmapFactory.decodeStream(fis);  ///把流转化为Bitmap图片
+        } catch (FileNotFoundException e) {
+            e.printStackTrace();
+            return null;
+        }
+    }
 }

+ 7 - 1
app_core/common/src/main/java/com/core/app/Constants.java

@@ -1,5 +1,7 @@
 package com.core.app;
 
+import android.os.Environment;
+
 import com.common.config.BaseConfig;
 import com.core.db.DatabaseTables;
 
@@ -10,7 +12,7 @@ public class Constants {
     public static final String BASE_URL_LOGIN = "http://manage.ubtob.com/public/account";
     //账户中心地址
     public static final String ACCOUNT_CENTER_HOST = "https://sso.ubtob.com/";
-//    public static final String ACCOUNT_CENTER_HOST = "http://10.1.51.50:3001/";
+    //    public static final String ACCOUNT_CENTER_HOST = "http://10.1.51.50:3001/";
     //    public static final String ACCOUNT_CENTER_HOST = "https://account.ubtob.com/";
     //IM正式地址
     public static final String IM_BASE_URL = "http://113.105.74.140:8092/";
@@ -472,6 +474,8 @@ public class Constants {
     public static String BASE_CHARIT_ACTIVITY_URL = "http://lj.ubtob.com/mobile#/activity/detail/";
     public static String BASE_CHARIT_PROJECT_URL = "http://lj.ubtob.com/mobile#/project/detail/";
 
+    public static String SPLASH_FILE_PATH = Environment.getExternalStorageDirectory().getAbsolutePath() + "/UU/splash";
+    public static String SPLASH_FILE_NAME = "splash";
 
     public interface FLAG {
         //webview Cookie缓存
@@ -547,5 +551,7 @@ public class Constants {
         String EN_BUSINESS_CODE = "en_business_code";
 
         String MODIFY_PASSWORD_VERIFY_CODE = "modify_password_verify_code";
+
+        String CACHE_SPLASH_URL = "cache_splash_url";
     }
 }

+ 23 - 0
app_core/common/src/main/java/com/core/base/EasyFragment.java

@@ -11,6 +11,9 @@ import android.support.v4.content.ContextCompat;
 import android.util.Log;
 import android.util.SparseArray;
 import android.view.LayoutInflater;
+import android.view.Menu;
+import android.view.MenuInflater;
+import android.view.MenuItem;
 import android.view.View;
 import android.view.ViewGroup;
 
@@ -64,6 +67,26 @@ public abstract class EasyFragment extends Fragment {
 	 */
 	protected abstract void onCreateView(Bundle savedInstanceState, boolean createView);
 
+
+	private MenuItem.OnMenuItemClickListener omOnMenuItemClickListener= new MenuItem.OnMenuItemClickListener() {
+		@Override
+		public boolean onMenuItemClick(MenuItem menuItem) {
+			onOptionsItemSelected(menuItem);
+			return false;
+		}
+	};
+	@Override
+	public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {
+		if (menu!=null){
+			for (int i=0;i<menu.size();i++){
+				MenuItem item = menu.getItem(i);
+				if (item!=null){
+					item.setOnMenuItemClickListener(omOnMenuItemClickListener);
+				}
+			}
+		}
+		super.onCreateOptionsMenu(menu, inflater);
+	}
 	public View getmRootView() {
 		return mRootView;
 	}

+ 21 - 0
app_core/common/src/main/java/com/core/utils/CommonUtil.java

@@ -52,6 +52,7 @@ import com.core.dao.DBManager;
 import com.core.dao.SignAutoLogDao;
 import com.core.interfac.OnVoiceCompleteListener;
 import com.core.model.EmployeesEntity;
+import com.core.net.http.http.OAHttpHelper;
 import com.core.xmpp.model.SignAutoLogEntity;
 import com.core.xmpp.utils.audio.voicerecognition.JsonParser;
 import com.iflytek.cloud.RecognizerResult;
@@ -887,7 +888,27 @@ public class CommonUtil {
         }
 
     }
+    /**
+     * 关闭软键盘
+     *
+     * @param mContext  上下文
+     */
+    public static void closeKeybord( final Activity mContext) {
+
+        if (mContext != null) {
+            LogUtil.i("gong","closeKeybord");
+            OAHttpHelper.getInstance().postDelayed(new Runnable() {
+                @Override
+                public void run() {
+                    InputMethodManager imm = (InputMethodManager) mContext
+                            .getSystemService(Context.INPUT_METHOD_SERVICE);
+                    LogUtil.i("gong", "closeKeybord  showshow");
+                    imm.hideSoftInputFromWindow(mContext.getWindow().getDecorView().getWindowToken(), 0);
+                }
+            }, 100);
+        }
 
+    }
     public static boolean isBiteman() {
         String baseUrl = getSharedPreferences(MyApplication.getInstance(), "erp_base");
         return !StringUtil.isEmpty(baseUrl) && baseUrl.contains("http://202.104.151.184:8099/ERP/");

+ 1 - 1
app_core/common/src/main/java/com/core/utils/NotificationManage.java

@@ -39,7 +39,7 @@ public class NotificationManage {
     private void sendNotification(Context context, int icon, String title, String group, String content, Class<? extends Activity> clazz) {
         NotificationManager mNotificationManager = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
         NotificationCompat.Builder builder = new NotificationCompat.Builder(context.getApplicationContext());
-        builder.setDefaults(Notification.DEFAULT_SOUND | Notification.DEFAULT_VIBRATE);
+//        builder.setDefaults(Notification.DEFAULT_SOUND | Notification.DEFAULT_VIBRATE);
         builder.setAutoCancel(true);
         builder.setContentTitle(title);
         builder.setContentText(content);

+ 8 - 3
app_core/common/src/main/res/drawable/oa_next.xml

@@ -1,4 +1,9 @@
-<vector android:height="24dp" android:viewportHeight="1024"
-    android:viewportWidth="1024" android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
-    <path android:fillColor="#D4D4D4" android:pathData="M769.79,476.03 L416.48,125.92c-18.85,-18.66 -49.22,-18.53 -67.87,0.32 -18.66,18.82 -18.53,49.22 0.32,67.87l319.46,316.58 -318.18,321.06c-18.66,18.82 -18.53,49.22 0.32,67.87 9.34,9.28 21.57,13.92 33.79,13.92 12.35,0 24.7,-4.74 34.08,-14.21l350.11,-353.31c0.51,-0.51 0.67,-1.25 1.18,-1.79 0.13,-0.13 0.29,-0.16 0.42,-0.29C788.74,525.09 788.64,494.69 769.79,476.03z"/>
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+    android:width="10dp"
+    android:height="15dp"
+    android:viewportHeight="1024"
+    android:viewportWidth="1024">
+    <path
+        android:fillColor="#D4D4D4"
+        android:pathData="M769.79,476.03 L416.48,125.92c-18.85,-18.66 -49.22,-18.53 -67.87,0.32 -18.66,18.82 -18.53,49.22 0.32,67.87l319.46,316.58 -318.18,321.06c-18.66,18.82 -18.53,49.22 0.32,67.87 9.34,9.28 21.57,13.92 33.79,13.92 12.35,0 24.7,-4.74 34.08,-14.21l350.11,-353.31c0.51,-0.51 0.67,-1.25 1.18,-1.79 0.13,-0.13 0.29,-0.16 0.42,-0.29C788.74,525.09 788.64,494.69 769.79,476.03z" />
 </vector>

+ 15 - 11
app_core/common/src/main/res/layout/act_taskerp_add.xml

@@ -26,7 +26,8 @@
             <TextView
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:layout_alignTop="@id/tv_title"
+                android:layout_marginLeft="10dp"
+                android:layout_marginTop="6dp"
                 android:layout_toRightOf="@id/tv_title"
                 android:text="*"
                 android:textColor="@color/red" />
@@ -37,7 +38,7 @@
                 android:layout_toRightOf="@+id/tv_title"
                 android:background="@null"
                 android:gravity="right|center_vertical"
-                android:hint="@string/common_input" />
+                android:hint="@string/common_input2" />
         </RelativeLayout>
 
         <RelativeLayout
@@ -56,9 +57,9 @@
             <TextView
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:layout_alignTop="@id/detailsTV"
+                android:layout_marginLeft="10dp"
+                android:layout_marginTop="6dp"
                 android:layout_toRightOf="@id/detailsTV"
-                android:layout_marginTop="@dimen/padding"
                 android:text="*"
                 android:textColor="@color/red" />
             <ImageView
@@ -78,7 +79,7 @@
             android:layout_height="100dp"
             android:layout_marginBottom="10dp"
             android:background="@color/white"
-            android:hint="@string/common_input"
+            android:hint="@string/common_input2"
             android:paddingLeft="10dp"
             android:textSize="15sp" />
 
@@ -96,8 +97,9 @@
                 android:text="@string/task_executor" />
             <TextView
                 android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_alignTop="@id/tv_task_peoples"
+                android:layout_height="wrap_content"      
+                android:layout_marginLeft="2dp"
+                android:layout_marginTop="20dp"
                 android:layout_toRightOf="@id/tv_task_peoples"
                 android:text="*"
                 android:textColor="@color/red" />
@@ -152,7 +154,8 @@
             <TextView
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:layout_alignTop="@id/tv_startime"
+                android:layout_marginLeft="10dp"
+                android:layout_marginTop="6dp"
                 android:layout_toRightOf="@id/tv_startime"
                 android:text="*"
                 android:textColor="@color/red" />
@@ -163,7 +166,7 @@
                 android:layout_toRightOf="@+id/tv_startime"
                 android:background="@null"
                 android:gravity="right"
-                android:hint="@string/common_select" />
+                android:hint="@string/common_select1" />
         </RelativeLayout>
 
         <View
@@ -189,7 +192,8 @@
             <TextView
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
-                android:layout_alignTop="@id/tv_task_startime"
+                android:layout_marginLeft="10dp"
+                android:layout_marginTop="6dp"
                 android:layout_toRightOf="@id/tv_task_startime"
                 android:text="*"
                 android:textColor="@color/red" />
@@ -200,7 +204,7 @@
                 android:layout_toRightOf="@+id/tv_task_startime"
                 android:background="@null"
                 android:gravity="right"
-                android:hint="@string/common_select" />
+                android:hint="@string/common_select1" />
 
         </RelativeLayout>
         <!--

+ 2 - 0
app_core/common/src/main/res/layout/activity_common_docui.xml

@@ -187,6 +187,8 @@
                 android:layout_height="wrap_content"
                 android:layout_marginBottom="10dp"
                 android:background="#ebe9e9"
+                android:divider="@color/white"
+                android:dividerHeight="0dp"
                 android:focusableInTouchMode="false"
                 android:visibility="visible"></com.core.widget.MyListView>
 

+ 2 - 1
app_core/common/src/main/res/layout/activity_setting.xml

@@ -195,7 +195,8 @@
             <RelativeLayout
                 android:id="@+id/businessmen_setting_rl"
                 style="@style/commonSettingItem"
-                android:layout_marginTop="12dp">
+                android:layout_marginTop="12dp"
+                android:visibility="gone">
 
                 <View
                     android:layout_width="match_parent"

+ 0 - 18
app_core/common/src/main/res/layout/item_approval_enclosure.xml

@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              style="@style/approvalStyle">
-
-    <TextView
-        android:id="@+id/nameTv"
-        android:layout_marginTop="8dp"
-        android:layout_marginBottom="8dp"
-        android:layout_width="match_parent"
-        android:layout_height="match_parent"
-        android:gravity="center|left"
-        android:layout_marginLeft="20dp"
-        android:layout_marginRight="20dp"
-        android:textColor="@color/titleBlue"/>
-
-
-
-</LinearLayout>

+ 40 - 49
app_core/common/src/main/res/layout/layout_menu_send_qzone_message.xml

@@ -1,54 +1,45 @@
 <?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:orientation="vertical"
-    android:background="@color/white">
+<LinearLayout
+    style="@style/commonPopView"
+    xmlns:android="http://schemas.android.com/apk/res/android">
 
-    <TextView
-        android:id="@+id/send_qzone_text"
+    <LinearLayout
         android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:text="@string/qzone_send_word"
-        android:textColor="@color/black"
-        android:textSize="15sp"/>
-    <View
-        android:layout_width="match_parent"
-        android:layout_height="0.3dp"
-        android:background="@color/button_invalid"/>
-    <TextView
-        android:id="@+id/send_qzone_picture"
-        android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:text="@string/qzone_send_picture"
-        android:textColor="@color/black"
-        android:textSize="15sp"/>
-
-    <View
-        android:layout_width="match_parent"
-        android:layout_height="0.3dp"
-        android:background="@color/button_invalid"/>
-    <TextView
-        android:id="@+id/send_qzone_video"
-        android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:textColor="@color/black"
-        android:text="@string/qzone_send_video"
-        android:textSize="15sp"/>
-    <View
-        android:layout_width="match_parent"
-        android:layout_height="10dp"
-        android:background="@color/black_gray"/>
-    <TextView
-        android:id="@+id/send_qzone_cancel"
-        android:layout_width="match_parent"
-        android:layout_height="45dp"
-        android:gravity="center"
-        android:textColor="@color/black"
-        android:text="@string/common_cancel"
-        android:textSize="15sp"/>
+        android:layout_height="wrap_content"
+        android:background="@drawable/shape_common_pop_option_item"
+        android:orientation="vertical">
+        <TextView
+            android:id="@+id/send_qzone_text"
+            style="@style/commonPopItemTop"
+            android:text="@string/qzone_send_word"
+            />
+        <View
+            android:layout_width="match_parent"
+            android:layout_height="0.3dp"
+            android:background="@color/button_invalid"/>
+        <TextView
+            android:id="@+id/send_qzone_picture"
+            style="@style/commonPopItem"
+            android:text="@string/qzone_send_picture"
+           />
 
+        <View
+            android:layout_width="match_parent"
+            android:layout_height="0.3dp"
+            android:background="@color/button_invalid"/>
+        <TextView
+            android:id="@+id/send_qzone_video"
+            style="@style/commonPopItem"
+            android:text="@string/qzone_send_video"
+           />
+        <View
+            android:layout_width="match_parent"
+            android:layout_height="10dp"
+            android:background="@color/black_gray"/>
+        <TextView
+            android:id="@+id/send_qzone_cancel"
+            style="@style/commonPopCancelItem"
+            android:text="@string/common_cancel"
+            />
+    </LinearLayout>
 </LinearLayout>

+ 2 - 2
app_core/common/src/main/res/layout/view_loading.xml

@@ -16,8 +16,8 @@
         android:src="@drawable/ic_loading" /> -->
       <ProgressBar
         android:id="@+id/imageViewLoading"
-        android:layout_width="50dp"
-        android:layout_height="50dp"
+        android:layout_width="40dp"
+        android:layout_height="40dp"
         android:layout_centerInParent="true"
         android:indeterminateDrawable="@drawable/frame_loading" />
 

+ 1 - 1
app_core/common/src/main/res/menu/menu_list.xml

@@ -6,7 +6,7 @@
     <item
         android:id="@+id/push"
         android:title="@string/more"
-        android:icon="@drawable/xlist"
+        android:icon="@drawable/ic_oa_list"
         app:showAsAction="ifRoom" />
 
 </menu>

+ 3 - 0
app_core/common/src/main/res/values/colors.xml

@@ -352,4 +352,7 @@
 
     <color name="common_pop_item_normal">#CCFFFFFF</color>
     <color name="common_pop_item_pressed">#D8D8D8</color>
+    <color name="meeting_end_status">#9B9B9B</color>
+    <color name="meeting_start_status">#3BAE7E</color>
+    <color name="meeting_before_status">#FF0000</color>
 </resources>

+ 42 - 0
app_core/network/src/main/java/com/me/network/app/base/HttpParams.java

@@ -10,6 +10,9 @@ import java.util.Map;
  */
 
 public class HttpParams {
+    public static final long CONNECT_TIME_OUT = 30;
+    public static final long READ_TIME_OUT = 30;
+    public static final long WRITE_TIME_OUT = 30;
 
     /**
      * 请求地址
@@ -36,6 +39,12 @@ public class HttpParams {
      */
     private int method;
 
+    private long connectTimeOut = CONNECT_TIME_OUT;
+
+    private long readTimeOut = READ_TIME_OUT;
+
+    private long writeTimeOut = WRITE_TIME_OUT;
+
 
     public HttpParams(Builder builder) {
         this.url = builder.url;
@@ -43,6 +52,9 @@ public class HttpParams {
         this.params = builder.params;
         this.headers = builder.headers;
         this.method = builder.method;
+        this.connectTimeOut = builder.connectTimeOut;
+        this.readTimeOut = builder.readTimeOut;
+        this.writeTimeOut = builder.writeTimeOut;
     }
 
     public String getUrl() {
@@ -65,12 +77,27 @@ public class HttpParams {
         return method;
     }
 
+    public long getConnectTimeOut() {
+        return connectTimeOut;
+    }
+
+    public long getReadTimeOut() {
+        return readTimeOut;
+    }
+
+    public long getWriteTimeOut() {
+        return writeTimeOut;
+    }
+
     public static class Builder {
         private String url;
         private int flag;
         private Map<String, Object> params = new HashMap<>();
         private Map<String, Object> headers = new HashMap<>();
         private int method;
+        private long connectTimeOut = CONNECT_TIME_OUT;
+        private long readTimeOut = READ_TIME_OUT;
+        private long writeTimeOut = WRITE_TIME_OUT;
 
         public Builder url(String val) {
             this.url = val;
@@ -123,6 +150,21 @@ public class HttpParams {
             return this;
         }
 
+        public Builder connectTimeOut(long seconds) {
+            this.connectTimeOut = seconds;
+            return this;
+        }
+
+        public Builder readTimeOut(long seconds) {
+            this.readTimeOut = seconds;
+            return this;
+        }
+
+        public Builder writeTimeOut(long seconds) {
+            this.writeTimeOut = seconds;
+            return this;
+        }
+
         public HttpParams build() {
             return new HttpParams(this);
         }

+ 3 - 0
app_core/network/src/main/java/com/me/network/app/http/HttpRequest.java

@@ -79,6 +79,9 @@ public class HttpRequest {
 
         mHttpClient.Api().send(new HttpClient.Builder()
                 .url(httpParams.getUrl())
+                .connectTimeout(httpParams.getConnectTimeOut())
+                .readTimeout(httpParams.getReadTimeOut())
+                .writeTimeout(httpParams.getWriteTimeOut())
                 .addHeaders(httpParams.getHeaders())
                 .addParams(httpParams.getParams())
                 .method((httpParams.getMethod() == Method.GET) ? Method.GET : Method.POST)

+ 1 - 1
app_modular/appbooking/src/main/java/com/modular/booking/activity/services/BServicesActivity.java

@@ -118,7 +118,7 @@ public class BServicesActivity extends OABaseActivity implements View.OnClickLis
         drawBg = getResources().getDrawable(R.color.antionbarcolor);
         //  drawBg.setAlpha(0);
         // bar.setSplitBackgroundDrawable(new ColorDrawable(Color.parseColor("#330000ff")));
-        bar.setBackgroundDrawable(drawBg);
+//        bar.setBackgroundDrawable(drawBg);
         bar.setCustomView(view);
 
 

+ 0 - 5
app_modular/appbooking/src/main/res/layout/activity_bbooking_add.xml

@@ -33,7 +33,6 @@
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
                     android:layout_marginLeft="40dp"
-                    android:layout_marginTop="@dimen/padding"
                     android:text="*"
                     android:textColor="@color/red" />
                 <TextView
@@ -61,7 +60,6 @@
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
                     android:layout_marginLeft="40dp"
-                    android:layout_marginTop="@dimen/padding"
                     android:text="*"
                     android:textColor="@color/red" />
                 <TextView
@@ -89,7 +87,6 @@
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
                     android:layout_marginLeft="40dp"
-                    android:layout_marginTop="@dimen/padding"
                     android:text="*"
                     android:textColor="@color/red" />
                 <TextView
@@ -120,7 +117,6 @@
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
                     android:layout_marginLeft="40dp"
-                    android:layout_marginTop="@dimen/padding"
                     android:text="*"
                     android:textColor="@color/red" />
                 <TextView
@@ -152,7 +148,6 @@
                     android:layout_width="wrap_content"
                     android:layout_height="wrap_content"
                     android:layout_marginLeft="40dp"
-                    android:layout_marginTop="@dimen/padding"
                     android:text="*"
                     android:textColor="@color/red" />
                 <EditText

+ 2 - 0
app_modular/appcontact/src/main/java/com/uas/appcontact/ui/fragment/GroupChatFragment.java

@@ -21,6 +21,7 @@ import android.widget.TextView;
 
 import com.android.volley.Response.ErrorListener;
 import com.android.volley.VolleyError;
+import com.common.LogUtil;
 import com.common.data.CalendarUtil;
 import com.common.data.StringUtil;
 import com.common.ui.ProgressDialogUtil;
@@ -100,6 +101,7 @@ public class GroupChatFragment extends EasyFragment {
     @Override
     public boolean onOptionsItemSelected(MenuItem item) {
         if (item.getItemId() == R.id.add_item) {
+            LogUtil.i("onOptionsItemSelected");
 //            startActivity(new Intent(getActivity(), SelectContactsActivity.class));
             startActivity(new Intent("com.modular.groupchat.CreateGroupActivity"));
         }

+ 32 - 28
app_modular/appme/src/main/java/com/uas/appme/settings/activity/SettingActivity.java

@@ -2,7 +2,6 @@ package com.uas.appme.settings.activity;
 
 import android.annotation.TargetApi;
 import android.app.ActivityManager;
-import android.app.AlertDialog;
 import android.app.ProgressDialog;
 import android.content.Context;
 import android.content.DialogInterface;
@@ -188,7 +187,7 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
                 PopupWindowHelper.showAlart(SettingActivity.this, getString(R.string.app_name), getString(R.string.exit_tips), new PopupWindowHelper.OnSelectListener() {
                     @Override
                     public void select(boolean selectOk) {
-                        if (selectOk){
+                        if (selectOk) {
                             UserSp.getInstance(mContext).clearUserInfo();
                             ViewUtil.clearAccount(mContext);
                             LoginHelper.broadcastLogout(mContext);
@@ -311,7 +310,7 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
 //                            businessmen_setting_rl.setVisibility(View.VISIBLE);
 //                        } else
 
-                            if ("1".equals(JSON.parseObject(o.toString()).getString("result"))) {
+                        if ("1".equals(JSON.parseObject(o.toString()).getString("result"))) {
                             businessmen_setting_rl.setVisibility(View.VISIBLE);
                         } else {
                             businessmen_setting_rl.setVisibility(View.GONE);
@@ -358,7 +357,7 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
         new MaterialDialog.Builder(this)
                 .title(R.string.app_name)
                 .titleGravity(GravityEnum.CENTER)
-                
+
                 .content(R.string.exit_tips)
                 .positiveText(R.string.common_sure)
                 .positiveColorRes(R.color.white)
@@ -369,7 +368,7 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
                 .negativeText(R.string.common_cancel)
                 .negativeColorRes(R.color.white)
                 .show();
-        
+
 //        new AlertDialog.Builder(mContext)
 //                .setTitle(R.string.app_name)
 //                .setMessage(R.string.exit_tips)
@@ -441,9 +440,17 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
                                                     .getInstallPath())) {
                                     } else if (info != null) {
                                     } else {
-                                        ViewUtil.ShowMessageTitle(
-                                                SettingActivity.this,
-                                                getString(R.string.set_isnewVersion));
+//                                        ViewUtil.ShowMessageTitle(
+//                                                SettingActivity.this,
+//                                                getString(R.string.set_isnewVersion));
+                                        PopupWindowHelper.showAlart(SettingActivity.this,
+                                                getString(R.string.app_dialog_title), getString(R.string.set_isnewVersion)
+                                                , new PopupWindowHelper.OnSelectListener() {
+                                                    @Override
+                                                    public void select(boolean selectOk) {
+
+                                                    }
+                                                });
                                     }
                                     dialog.dismiss();
                                 }
@@ -494,19 +501,15 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
 
     //确认是否清空本地缓存
     private void showclearDialog() {
-        new AlertDialog
-                .Builder(mContext)
-                .setTitle(getString(R.string.common_notice))
-                .setMessage(getString(R.string.cache_msg))
-                .setNegativeButton(getString(R.string.common_cancel), null)
-                .setPositiveButton(getString(R.string.common_sure), new DialogInterface.OnClickListener() {
-
+        PopupWindowHelper.showAlart(this, getString(R.string.common_notice),
+                getString(R.string.cache_msg), new PopupWindowHelper.OnSelectListener() {
                     @Override
-                    public void onClick(DialogInterface dialog, int which) {
-                        clearCache();
-                        Log.i("clearCache", "clearCache");
+                    public void select(boolean selectOk) {
+                        if (selectOk) {
+                            clearCache();
+                        }
                     }
-                }).create().show();
+                });
     }
 
     @TargetApi(Build.VERSION_CODES.HONEYCOMB)
@@ -663,24 +666,25 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
         DisplayUtil.backgroundAlpha(this, 1f);
     }
 
-    private  PopupWindow popupWindow;
+    private PopupWindow popupWindow;
+
     public void showExitPop() {
         View view = null;
         WindowManager windowManager = (WindowManager) getSystemService(Context.WINDOW_SERVICE);
         if (popupWindow == null) {
             LayoutInflater layoutInflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE);
             view = layoutInflater.inflate(R.layout.pop_simple_dialog, null);
-            TextView tv_title= view.findViewById(R.id.tv_title);
-            TextView tv_content= view.findViewById(R.id.tv_content);
-            TextView tv_cancel=view.findViewById(R.id.tv_cancel);
-            TextView tv_sure= view.findViewById(R.id.tv_sure);
+            TextView tv_title = view.findViewById(R.id.tv_title);
+            TextView tv_content = view.findViewById(R.id.tv_content);
+            TextView tv_cancel = view.findViewById(R.id.tv_cancel);
+            TextView tv_sure = view.findViewById(R.id.tv_sure);
             tv_content.setText(R.string.exit_tips);
-            popupWindow = new PopupWindow(view, windowManager.getDefaultDisplay().getWidth()- DensityUtil.dp2px(50), LinearLayout.LayoutParams.MATCH_PARENT);
+            popupWindow = new PopupWindow(view, windowManager.getDefaultDisplay().getWidth() - DensityUtil.dp2px(50), LinearLayout.LayoutParams.MATCH_PARENT);
             tv_sure.setOnClickListener(new View.OnClickListener() {
                 @Override
                 public void onClick(View view) {
                     popupWindow.dismiss();
-                  
+
                 }
             });
             tv_cancel.setOnClickListener(new View.OnClickListener() {
@@ -689,7 +693,7 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
                     popupWindow.dismiss();
                 }
             });
-           
+
         }
 
         popupWindow.setFocusable(true);
@@ -705,5 +709,5 @@ public class SettingActivity extends SupportToolBarActivity implements View.OnCl
         popupWindow.setHeight(ViewGroup.LayoutParams.WRAP_CONTENT);
         popupWindow.showAtLocation(activity.getWindow().getDecorView(), Gravity.CENTER, 0, 0);
     }
-    
+
 }

+ 8 - 8
app_modular/appme/src/main/res/menu/bsetting_more.xml

@@ -1,12 +1,12 @@
 <menu xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:app="http://schemas.android.com/apk/res-auto"
-    xmlns:tools="http://schemas.android.com/tools"
-    tools:context="com.xzjmyk.pm.activity.MainActivity">
+xmlns:app="http://schemas.android.com/apk/res-auto"
+xmlns:tools="http://schemas.android.com/tools"
+tools:context="com.xzjmyk.pm.activity.MainActivity">
 
-    <item
-        android:id="@+id/booking_set_list"
-        android:title="@string/more"
-        android:icon="@drawable/xlist"
-        app:showAsAction="ifRoom" />
+<item
+    android:id="@+id/booking_set_list"
+    android:title="@string/more"
+    android:icon="@drawable/ic_oa_list"
+    app:showAsAction="ifRoom" />
 
 </menu>

+ 20 - 23
app_modular/appmessages/src/main/java/com/modular/appmessages/activity/Subscription2Activity.java

@@ -1,11 +1,9 @@
 package com.modular.appmessages.activity;
 
-import android.content.DialogInterface;
 import android.content.Intent;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Message;
-import android.support.v7.app.AlertDialog;
 import android.support.v7.widget.DefaultItemAnimator;
 import android.support.v7.widget.LinearLayoutManager;
 import android.support.v7.widget.RecyclerView;
@@ -33,6 +31,7 @@ import com.modular.appmessages.R;
 import com.modular.appmessages.adapter.SubscriptionAdapter;
 import com.modular.appmessages.db.SubsDao;
 import com.modular.appmessages.model.SubMessage;
+import com.modular.apputils.utils.PopupWindowHelper;
 import com.module.recyclerlibrary.ui.refresh.BaseRefreshLayout;
 import com.module.recyclerlibrary.ui.refresh.simlpe.SimpleRefreshLayout;
 
@@ -67,7 +66,7 @@ public class Subscription2Activity extends BaseActivity {
                             JSONArray array = JSON.parseObject(message).getJSONArray("data");
                             if (ListUtils.isEmpty(array)) {
                                 updataAdapter();
-                                showToast(  getString(R.string.common_list_empty));
+                                showToast(getString(R.string.common_list_empty));
                                 return;
                             }
                             if (ListUtils.isEmpty(messages)) messages = new ArrayList<>();
@@ -80,7 +79,7 @@ public class Subscription2Activity extends BaseActivity {
                                 reckonData(array, false);
                             }
                         } else {
-                          showToast( message == null ? "" : StringUtil.getChinese(message));
+                            showToast(message == null ? "" : StringUtil.getChinese(message));
                         }
                         break;
                     case Constants.APP_SOCKETIMEOUTEXCEPTION:
@@ -101,11 +100,11 @@ public class Subscription2Activity extends BaseActivity {
 
     @Override
     public boolean onOptionsItemSelected(MenuItem item) {
-        if (item.getItemId()==R.id.subscribe_manage){
+        if (item.getItemId() == R.id.subscribe_manage) {
             Intent intent = new Intent();
             intent.setClass(this, SubcribeManageActivity.class);
             startActivity(intent);
-        }else if (android.R.id.home==item.getItemId()){
+        } else if (android.R.id.home == item.getItemId()) {
             onBackPressed();
         }
         return super.onOptionsItemSelected(item);
@@ -122,8 +121,8 @@ public class Subscription2Activity extends BaseActivity {
 
 
     private void initView() {
-        swiperefresh= (SimpleRefreshLayout) findViewById(R.id.swiperefresh);
-        recycler= (RecyclerView) findViewById(R.id.recycler);
+        swiperefresh = (SimpleRefreshLayout) findViewById(R.id.swiperefresh);
+        recycler = (RecyclerView) findViewById(R.id.recycler);
         ViewUtil.LoginERPTask(this, handler, 0x12);
         LinearLayoutManager layoutManager = new LinearLayoutManager(ct);
         recycler.setLayoutManager(layoutManager);
@@ -181,18 +180,16 @@ public class Subscription2Activity extends BaseActivity {
             public void longClick(View view, SubMessage bean, final int position) {
                 if (bean == null) bean = (SubMessage) view.getTag();
                 if (bean == null) return;
-                AlertDialog.Builder builder = new AlertDialog.Builder(ct);
                 final SubMessage finalBean = bean;
-                builder.setTitle(R.string.prompt_title).setMessage(R.string.delete_prompt).setPositiveButton(R.string.sure, new DialogInterface.OnClickListener() {
-                    @Override
-                    public void onClick(DialogInterface dialogInterface, int i) {
-                        longClickItem(finalBean, position);
-                    }
-                }).setNegativeButton(R.string.cancel, new DialogInterface.OnClickListener() {
-                    @Override
-                    public void onClick(DialogInterface dialogInterface, int i) {
-                    }
-                }).show();
+                PopupWindowHelper.showAlart(Subscription2Activity.this, getString(R.string.common_notice),
+                        getString(R.string.delete_prompt), new PopupWindowHelper.OnSelectListener() {
+                            @Override
+                            public void select(boolean selectOk) {
+                                if (selectOk) {
+                                    longClickItem(finalBean, position);
+                                }
+                            }
+                        });
             }
         });
     }
@@ -229,16 +226,16 @@ public class Subscription2Activity extends BaseActivity {
         if (delete) {
             messages.remove(position);
             updataAdapter();
-            showToast( R.string.delete_all_succ);
+            showToast(R.string.delete_all_succ);
         } else {
-            showToast(  R.string.delete_failed);
+            showToast(R.string.delete_failed);
         }
     }
 
     private void clickItem(SubMessage bean, int position) {
         String url = baseUrl + "common/charts/mobileCharts.action";
         String title = bean.getTitle();
-        Intent intent_web = new Intent("com.modular.main.WebViewCommActivity" );
+        Intent intent_web = new Intent("com.modular.main.WebViewCommActivity");
         intent_web.putExtra("url", url);
         intent_web.putExtra("p", title);
         intent_web.putExtra("cookie", true);
@@ -324,7 +321,7 @@ public class Subscription2Activity extends BaseActivity {
         String url = baseUrl + "common/desktop/subs/getSubs.action";
         final Map<String, Object> param = new HashMap<>();
         param.put("count", 100);
-        param.put("condition", "where to_char(createdate_,'yyyymmdd')='" + DateFormatUtil.long2Str(showTime,"yyyyMMdd") + "'");
+        param.put("condition", "where to_char(createdate_,'yyyymmdd')='" + DateFormatUtil.long2Str(showTime, "yyyyMMdd") + "'");
         param.put("sessionId", CommonUtil.getSharedPreferences(this, "sessionId"));
         LinkedHashMap<String, Object> headers = new LinkedHashMap<>();
         headers.put("Cookie", "JSESSIONID=" + CommonUtil.getSharedPreferences(this, "sessionId"));

+ 36 - 1
app_modular/appmessages/src/main/java/com/modular/appmessages/adapter/ApprovalAdapter.java

@@ -117,6 +117,7 @@ public class ApprovalAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolde
             case Approval.SETUPTASK:
                 return new BaseRVViewHodler(parent);
             case Approval.ENCLOSURE://单行列表
+                return new EnclosureViewHolder(parent);
             case Approval.TAG:
                 return new TagViewHolder(parent);
             case Approval.POINTS:
@@ -137,6 +138,8 @@ public class ApprovalAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolde
                 bindTitleView((TitleViewHolder) holder, position);
             } else if (holder instanceof BaseRVViewHodler) {
                 bindBaseRVView((BaseRVViewHodler) holder, position);
+            } else if (holder instanceof EnclosureViewHolder) {
+                bindEnclosureView((EnclosureViewHolder) holder, position);
             } else if (holder instanceof TagViewHolder) {
                 bindTAGView((TagViewHolder) holder, position);
             } else if (holder instanceof PointsViewHolder) {
@@ -302,6 +305,23 @@ public class ApprovalAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolde
 
     }
 
+    private void bindEnclosureView(EnclosureViewHolder holder, final int position) {
+        String name = approvals.get(position).getCaption();
+        holder.enclosureTv.setText(TextUtils.isEmpty(name) ? "" : name);
+        holder.enclosureTv.setOnClickListener(new View.OnClickListener() {
+            @Override
+            public void onClick(View v) {
+                gotoReadEnclosure(approvals.get(position));
+            }
+        });
+
+        if ((position + 1) < ListUtils.getSize(approvals) && approvals.get(position).getType() != approvals.get(position + 1).getType()) {
+            holder.endView.setVisibility(View.VISIBLE);
+        } else {
+            holder.endView.setVisibility(View.GONE);
+        }
+    }
+
     private void bindTAGView(TagViewHolder holder, final int position) {
         holder.valuesRG.setVisibility(View.GONE);
         String name = approvals.get(position).getCaption();
@@ -499,7 +519,7 @@ public class ApprovalAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolde
             if (isWeb(approval.getValues())) {
                 setViewShowAble(true, holder.valueWeb);
                 setViewShowAble(false, holder.valueEt, holder.valueTv);
-                LogUtil.i(approval.getValues());
+                LogUtil.i("isWeb" + approval.getValues());
                 holder.valueWeb.loadDataWithBaseURL(null, approval.getValues(), "text/html", "utf-8", null);
             } else {
                 setViewShowAble(true, holder.valueTv);
@@ -623,6 +643,21 @@ public class ApprovalAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolde
         }
     }
 
+    private class EnclosureViewHolder extends RecyclerView.ViewHolder {
+        TextView enclosureTv;
+        View endView;
+
+        public EnclosureViewHolder(ViewGroup parent) {
+            this(LayoutInflater.from(ct).inflate(R.layout.item_approval_enclosure, parent, false));
+        }
+
+        public EnclosureViewHolder(View itemView) {
+            super(itemView);
+            enclosureTv = itemView.findViewById(R.id.nameTv);
+            endView = itemView.findViewById(R.id.endView);
+        }
+    }
+
     private class TagViewHolder extends RecyclerView.ViewHolder {
         TextView nameTv;
         View padding, line;

+ 0 - 185
app_modular/appmessages/src/main/java/com/modular/appmessages/adapter/MessageAdapter.java

@@ -1,185 +0,0 @@
-package com.modular.appmessages.adapter;
-
-import android.content.Context;
-import android.text.Html;
-import android.text.TextUtils;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.BaseAdapter;
-import android.widget.ImageView;
-import android.widget.TextView;
-
-import com.common.data.ListUtils;
-import com.common.data.StringUtil;
-import com.core.app.MyApplication;
-import com.core.model.Friend;
-import com.core.model.XmppMessage;
-import com.core.utils.TimeUtils;
-import com.core.utils.helper.AvatarHelper;
-import com.core.utils.sortlist.BaseSortModel;
-import com.core.xmpp.utils.HtmlUtils;
-import com.modular.appmessages.R;
-
-import java.util.List;
-
-/**
- * Created by Bitliker on 2017/3/1.
- */
-
-public class MessageAdapter extends BaseAdapter {
-
-    private List<BaseSortModel<Friend>> mFriendList;
-    private Context mContext;
-
-    public MessageAdapter(List<BaseSortModel<Friend>> mFriendList, Context mContext) {
-        this.mFriendList = mFriendList;
-        this.mContext = mContext;
-    }
-
-    public List<BaseSortModel<Friend>> getmFriendList() {
-        return mFriendList;
-    }
-
-    public void setmFriendList(List<BaseSortModel<Friend>> mFriendList) {
-        this.mFriendList = mFriendList;
-    }
-
-    @Override
-    public int getCount() {
-        return ListUtils.isEmpty(mFriendList) ? 0 : mFriendList.size();
-    }
-
-    @Override
-    public Object getItem(int position) {
-        return mFriendList.get(position).getBean();
-    }
-
-    @Override
-    public long getItemId(int position) {
-        return position;
-    }
-
-    @Override
-    public View getView(int position, View convertView, ViewGroup parent) {
-        Friend friend = (Friend) getItem(position);
-        ViewHolder holder = null;
-        if (convertView == null) {
-            convertView = LayoutInflater.from(mContext).inflate(R.layout.item_message_header, null);
-            holder = new ViewHolder();
-            holder.avatar_img = (ImageView) convertView.findViewById(R.id.headerImg);
-            holder.num_tv = (TextView) convertView.findViewById(R.id.headerNumTv);
-            holder.nick_name_tv = (TextView) convertView.findViewById(R.id.titleTv);
-            holder.content_tv = (TextView) convertView.findViewById(R.id.headerSubTv);
-            holder.time_tv = (TextView) convertView.findViewById(R.id.timeTv);
-            convertView.setTag(holder);
-        } else {
-            holder = (ViewHolder) convertView.getTag();
-        }
-        bindView(holder, friend);
-        return convertView;
-    }
-
-    private void bindView(ViewHolder holder, Friend friend) {
-        holder.avatar_img.setBackgroundResource(R.color.transparent);
-        //设置头像
-        if (friend.getType() == XmppMessage.TYPE_ERP) {
-            doShowMsgPhotos(holder, friend);
-            holder.time_tv.setText(TimeUtils.getFriendlyTimeDesc(MyApplication.getInstance(), friend.getTimeSend()));
-        } else if (friend.getType() == XmppMessage.TYPE_UUHELPER) {
-            holder.time_tv.setText(TimeUtils.getFriendlyTimeDesc(MyApplication.getInstance(), friend.getTimeSend()));
-            holder.avatar_img.setImageResource( R.drawable.icon_uuhelper);
-        } else {
-            if (friend.getRoomFlag() == 0) {// 这是单个人
-                AvatarHelper.getInstance().display(friend.getUserId(), holder.avatar_img, false, false);//每次刷新都会去删除此人缓存
-            } else {
-                if (TextUtils.isEmpty(friend.getRoomCreateUserId())) {
-                    holder.avatar_img.setImageResource(R.drawable.qunliao);
-                } else {
-                    AvatarHelper.getInstance().displayAvatarPng(friend.getRoomCreateUserId(), holder.avatar_img, true);// 目前在备注名放房间的创建者Id
-                }
-            }
-            holder.time_tv.setText(TimeUtils.getFriendlyTimeDesc(MyApplication.getInstance(), friend.getTimeSend()));
-        }
-
-        //设置名字和时间
-        holder.nick_name_tv.setText(friend.getRemarkName() != null ? friend.getRemarkName() : friend.getNickName());
-        //设置内容数据显示
-        CharSequence content = "";
-        if (friend.getType() == XmppMessage.TYPE_TEXT) {
-            String s = StringUtil.replaceSpecialChar(friend.getContent());
-            content = HtmlUtils.transform200SpanString(s.replaceAll("\n", "\r\n"), true);
-        } else {
-            content = friend.getContent();
-        }
-        if (!TextUtils.isEmpty(content)) {
-            holder.content_tv.setText(Html.fromHtml(content.toString()));
-        } else {
-            holder.content_tv.setText("");
-        }
-        //设置红点显示数量
-        if (friend.getUnReadNum() > 0) {
-            String numStr = friend.getUnReadNum() >= 99 ? "99+" : friend.getUnReadNum() + "";
-            holder.num_tv.setText(numStr);
-            holder.num_tv.setVisibility(View.VISIBLE);
-        } else {
-            holder.num_tv.setVisibility(View.GONE);
-        }
-
-    }
-
-    private void doShowMsgPhotos(ViewHolder holder, Friend friend) {
-        String msg_type = friend.getDescription();
-        if (!TextUtils.isEmpty(msg_type)) {
-            int imageurl = 0;
-            switch (msg_type) {
-                case "note": // 通知公告
-                    imageurl = R.drawable.home_image_03_u;
-                    break;
-                case "common": // 普通知会
-                    imageurl = R.drawable.putongzhihui;
-                    break;
-                case "b2b": // b2b提醒
-                    imageurl = R.drawable.b2btixing;
-                    break;
-                case "crm":  // CRM提醒
-                    imageurl = R.drawable.crmtixing;
-                    break;
-                case "kpi": // 考勤提醒
-                    imageurl = R.drawable.kaoqintixing;
-                    break;
-                case "meeting": // 会议提醒
-                    imageurl = R.drawable.huiyitixing;
-                    break;
-                case "process": // 审批知会
-                    imageurl = R.drawable.shenpizhihui;
-                    break;
-                case "job": // 稽核提醒
-                    imageurl = R.drawable.jihetixing;
-                    break;
-                case "system": // 知会消息
-                    imageurl = R.drawable.zhihuixiaoxi;
-                    break;
-                case "task": // 任务提醒
-                    imageurl = R.drawable.home_image_02_u;
-                    break;
-                default:
-                    imageurl = R.drawable.gongzuotixing;
-            }
-            holder.avatar_img.setImageResource(imageurl);
-        }
-    }
-
-    class ViewHolder {
-        //头像
-        ImageView avatar_img;
-        //数目
-        TextView num_tv;
-        //名字
-        TextView nick_name_tv;
-        //内容
-        TextView content_tv;
-        //时间
-        TextView time_tv;
-    }
-}

+ 54 - 8
app_modular/appmessages/src/main/java/com/modular/appmessages/adapter/MessageNewAdapter.java

@@ -1,6 +1,7 @@
 package com.modular.appmessages.adapter;
 
 import android.content.Context;
+import android.graphics.Bitmap;
 import android.support.v7.widget.RecyclerView;
 import android.text.Html;
 import android.text.TextUtils;
@@ -10,6 +11,7 @@ import android.view.ViewGroup;
 import android.widget.ImageView;
 import android.widget.TextView;
 
+import com.common.LogUtil;
 import com.common.data.ListUtils;
 import com.common.data.StringUtil;
 import com.core.app.MyApplication;
@@ -23,6 +25,10 @@ import com.core.xmpp.utils.HtmlUtils;
 import com.modular.appmessages.R;
 import com.modular.appmessages.model.MessageHeader;
 import com.modular.appmessages.model.MessageNew;
+import com.nostra13.universalimageloader.core.DisplayImageOptions;
+import com.nostra13.universalimageloader.core.ImageLoader;
+import com.nostra13.universalimageloader.core.assist.FailReason;
+import com.nostra13.universalimageloader.core.assist.ImageLoadingListener;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -113,24 +119,25 @@ public class MessageNewAdapter extends RecyclerView.Adapter<MessageNewAdapter.Vi
     @Override
     public void onBindViewHolder(ViewHolder viewHolder, int i) {
         MessageNew model = models.get(i);
-        viewHolder.itemView.setTag(R.id.tag_key,i);
-        viewHolder.itemView.setTag(R.id.tag_key2,model);
+        viewHolder.itemView.setTag(R.id.tag_key, i);
+        viewHolder.itemView.setTag(R.id.tag_key2, model);
         if (model != null && model.getT() != null) {
             if (model.getT() instanceof MessageHeader) {
-                bindHeader((MessageHeader) model.getT(), viewHolder);
+                bindHeader((MessageHeader) model.getT(), viewHolder,i);
             } else if (model.getT() instanceof BaseSortModel) {
                 BaseSortModel baseSortModel = (BaseSortModel) model.getT();
                 if (baseSortModel.getBean() instanceof Friend) {
-                    bindView(viewHolder, (Friend) baseSortModel.getBean());
+                    bindView(viewHolder, (Friend) baseSortModel.getBean(), i);
                 }
             }
         }
     }
 
 
-    private void bindHeader(MessageHeader model, ViewHolder hodler) {
+    private void bindHeader(MessageHeader model, ViewHolder hodler,int position) {
         hodler.itemView.setOnLongClickListener(null);
         hodler.itemView.setOnClickListener(mOnClickListener);
+        hodler.headerImg.setTag(position);
         if (model != null) {
             hodler.headerImg.setImageResource(model.getIcon());
             if (model.getRedNum() > 0) {
@@ -183,7 +190,7 @@ public class MessageNewAdapter extends RecyclerView.Adapter<MessageNewAdapter.Vi
         }
     };
 
-    private void bindView(ViewHolder holder, Friend friend) {
+    private void bindView(final ViewHolder holder, Friend friend, final int position) {
         holder.itemView.setOnLongClickListener(mOnLongClickListener);
         holder.itemView.setOnClickListener(mOnClickListener);
         holder.headerImg.setBackgroundResource(R.color.transparent);
@@ -196,7 +203,41 @@ public class MessageNewAdapter extends RecyclerView.Adapter<MessageNewAdapter.Vi
             holder.headerImg.setImageResource(R.drawable.icon_uuhelper);
         } else {
             if (friend.getRoomFlag() == 0) {// 这是单个人
-                AvatarHelper.getInstance().display(friend.getUserId(), holder.headerImg, false, false);//每次刷新都会去删除此人缓存
+                String url = AvatarHelper.getInstance().getAvatarUrl(friend.getUserId(), false);
+                holder.headerImg.setTag(position);
+                ImageLoader.getInstance().displayImage(url, holder.headerImg, mNormalImageOptions, new ImageLoadingListener() {
+                    @Override
+                    public void onLoadingStarted(String s, View view) {
+                        LogUtil.i("gong","onLoadingStarted");
+                    }
+
+                    @Override
+                    public void onLoadingFailed(String s, View view, FailReason failReason) {
+                        LogUtil.i("gong","onLoadingFailed");
+                        if (holder.headerImg.getTag() != null && holder.headerImg.getTag() instanceof Integer) {
+                            int item = (int) holder.headerImg.getTag();
+                            if (item == position) {
+                                holder.headerImg.setImageResource(R.drawable.avatar_round);
+                            }
+                        }
+                    }
+
+                    @Override
+                    public void onLoadingComplete(String s, View view, Bitmap bitmap) {
+                        LogUtil.i("gong","onLoadingComplete");
+                        if (holder.headerImg.getTag() != null && holder.headerImg.getTag() instanceof Integer) {
+                            int item = (int) holder.headerImg.getTag();
+                            if (item == position) {
+                                holder.headerImg.setImageBitmap(bitmap);
+                            }
+                        }
+                    }
+
+                    @Override
+                    public void onLoadingCancelled(String s, View view) {
+                        LogUtil.i("gong","onLoadingCancelled");
+                    }
+                });
             } else {
                 if (TextUtils.isEmpty(friend.getRoomCreateUserId())) {
                     holder.headerImg.setImageResource(R.drawable.qunliao);
@@ -232,7 +273,12 @@ public class MessageNewAdapter extends RecyclerView.Adapter<MessageNewAdapter.Vi
         }
 
     }
-
+    DisplayImageOptions   mNormalImageOptions = new DisplayImageOptions.Builder()
+            .bitmapConfig(Bitmap.Config.RGB_565)
+                .cacheInMemory(true)
+                .cacheOnDisc(true)
+                .resetViewBeforeLoading(false)
+                .build();
     private void doShowMsgPhotos(ViewHolder holder, Friend friend) {
         String msg_type = friend.getDescription();
         if (!TextUtils.isEmpty(msg_type)) {

+ 1 - 3
app_modular/appmessages/src/main/java/com/modular/appmessages/presenter/MessagePresenter.java

@@ -38,10 +38,8 @@ import com.core.model.XmppMessage;
 import com.core.net.http.http.OAHttpHelper;
 import com.core.net.http.http.OnHttpResultListener;
 import com.core.net.http.http.Request;
-import com.core.net.utils.NetUtils;
 import com.core.utils.CommonUtil;
 import com.core.utils.TimeUtils;
-import com.core.utils.ToastUtil;
 import com.core.utils.sortlist.BaseSortModel;
 import com.core.utils.sortlist.PingYinUtil;
 import com.core.xmpp.dao.ChatMessageDao;
@@ -909,7 +907,7 @@ public class MessagePresenter implements OnHttpResultListener {
     }
 
     public WorkModel getCurrentWork() {
-        List<WorkModel> workModels = WorkModelDao.getInstance().queryAuto();
+        List<WorkModel> workModels = WorkModelDao.getInstance().query(true);
         WorkModel workModel = null;
         String newsTime = DateFormatUtil.long2Str(DateFormatUtil.HM);
         if (!ListUtils.isEmpty(workModels)) {

+ 27 - 0
app_modular/appmessages/src/main/res/layout/item_approval_enclosure.xml

@@ -0,0 +1,27 @@
+<?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:orientation="vertical"
+    android:background="@color/white">
+
+    <TextView
+        android:layout_marginTop="2dp"
+        android:layout_marginBottom="2dp"
+        android:id="@+id/nameTv"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="20dp"
+        android:background="@drawable/bg_enclosure"
+        android:paddingLeft="@dimen/padding"
+        android:paddingRight="@dimen/padding"
+        android:text="附件"
+        android:textColor="@color/text_main"
+        android:textSize="12sp" />
+    <View
+        android:layout_width="match_parent"
+        android:layout_height="10dp"
+        android:visibility="gone"
+        android:id="@+id/endView"
+        />
+</LinearLayout>

+ 1 - 1
app_modular/appmessages/src/main/res/layout/item_message_header.xml

@@ -23,7 +23,7 @@
             android:background="@color/transparent"
             android:contentDescription="@string/app_name"
             android:padding="1dp"
-            android:src="@drawable/icon_message_huisuo" />
+            android:src="@drawable/avatar_round" />
 
         <TextView
             android:id="@+id/headerNumTv"

+ 19 - 7
app_modular/appworks/src/main/java/com/uas/appworks/CRM/erp/activity/UserSelectActivity.java

@@ -33,6 +33,7 @@ import com.core.net.http.ViewUtil;
 import com.core.utils.CommonUtil;
 import com.core.utils.FlexJsonUtil;
 import com.core.widget.ClearEditText;
+import com.core.widget.EmptyLayout;
 import com.handmark.pulltorefresh.library.PullToRefreshBase;
 import com.handmark.pulltorefresh.library.PullToRefreshListView;
 import com.uas.appworks.R;
@@ -98,6 +99,8 @@ public class UserSelectActivity extends BaseActivity {
                             listview.setAdapter(adapter);
                         } else
                             adapter.setUsers(list);
+                    }else{
+                        mEmptyLayout.showEmpty();
                     }
 
                     //判断selectList不为空
@@ -125,6 +128,8 @@ public class UserSelectActivity extends BaseActivity {
                             listview.setAdapter(adapter);
                         } else
                             adapter.setUsers(list);
+                    }else{
+                        mEmptyLayout.showEmpty();
                     }
                     if (selectedList != null && selectedList.size() != 0) {
                         for (int i = 0; i < list.size(); i++) {
@@ -145,10 +150,10 @@ public class UserSelectActivity extends BaseActivity {
 
     @Override
     protected void onCreate(Bundle savedInstanceState) {
-        if (getIntent() != null && getIntent().getIntExtra("reid", -1) != -1) {
-            setTheme(getSharedPreferences("cons", MODE_PRIVATE).getInt("theme",
-                    getIntent().getIntExtra("reid", -1)));
-        }
+//        if (getIntent() != null && getIntent().getIntExtra("reid", -1) != -1) {
+//            setTheme(getSharedPreferences("cons", MODE_PRIVATE).getInt("theme",
+//                    getIntent().getIntExtra("reid", -1)));
+//        }
         super.onCreate(savedInstanceState);
         setContentView(R.layout.activity_meet_select);
         listview = (PullToRefreshListView) findViewById(R.id.listview);
@@ -168,14 +173,21 @@ public class UserSelectActivity extends BaseActivity {
         initView();
         init();
     }
-
+private EmptyLayout mEmptyLayout;
     private void initView() {
        setTitle(R.string.select_user);
-        View view = LayoutInflater.from(this).inflate(R.layout.view_empty, null);
-        listview.setEmptyView(view);
+//        View view = LayoutInflater.from(this).inflate(R.layout.view_empty, null);
+//        listview.setEmptyView(view);
         adapter = new MeetSelectAdapter();
         listview.setAdapter(adapter);
         listview.setMode(PullToRefreshBase.Mode.DISABLED);
+
+        mEmptyLayout = new EmptyLayout(this, listview.getRefreshableView());
+        mEmptyLayout.setShowLoadingButton(false);
+        mEmptyLayout.setShowEmptyButton(false);
+        mEmptyLayout.setShowErrorButton(false);
+        mEmptyLayout.setEmptyMessage("暂无数据");
+
         search_edit.addTextChangedListener(new TextWatcher() {
             @Override
             public void beforeTextChanged(CharSequence charSequence, int i, int i1, int i2) {

+ 8 - 1
app_modular/appworks/src/main/java/com/uas/appworks/CRM/erp/adapter/HListViewOneAdapter.java

@@ -85,7 +85,7 @@ public class HListViewOneAdapter extends BaseAdapter {
                     if (index!=0){
                         holder.tv_item[i].setText("●");
                         holder.tv_item[i].setTextSize(TypedValue.COMPLEX_UNIT_DIP, 23);
-                        holder.tv_item[i].setTextColor(Color.parseColor(items.get(i)));
+                        holder.tv_item[i].setTextColor(getColor(items.get(i)));
 //                        holder.tv_item[i].setMinWidth(CommonUtil.dip2px(ct, 50));
 //                        holder.tv_item[i].setMinHeight(CommonUtil.dip2px(ct, 50));
                     }else{
@@ -99,6 +99,13 @@ public class HListViewOneAdapter extends BaseAdapter {
         return view;
     }
 
+    private int getColor(String color){
+        try{
+            return Color.parseColor(color);
+        }catch (Exception e){
+            return 0xe9e9e9;
+        }
+    }
   public  class ViewHolder {
       public TextView[] tv_item;
       public  LinearLayout ll_root;

+ 2 - 1
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/ExpenseReimbursementActivity.java

@@ -1981,7 +1981,8 @@ public class ExpenseReimbursementActivity extends BaseActivity implements View.O
         if (item.getItemId() == R.id.push){
             startActivity(new Intent(mContext, FormListSelectActivity.class)
                     .putExtra("caller", caller)
-                    .putExtra("title", getToolBarTitle().toString()));
+                    .putExtra("title", getToolBarTitle().toString())
+            );
         }
         if (item.getItemId() == android.R.id.home){
 //            if (formid != 0){

+ 9 - 14
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/FlightsActivity.java

@@ -1,9 +1,7 @@
 package com.uas.appworks.OA.erp.activity;
 
-import android.content.DialogInterface;
 import android.content.Intent;
 import android.os.Bundle;
-import android.support.v7.app.AlertDialog;
 import android.support.v7.widget.LinearLayoutManager;
 import android.support.v7.widget.RecyclerView;
 import android.view.Menu;
@@ -15,12 +13,13 @@ import com.core.api.wxapi.ApiPlatform;
 import com.core.api.wxapi.ApiUtils;
 import com.core.base.OABaseActivity;
 import com.core.widget.RecycleViewDivider;
-import com.uas.appworks.R;
+import com.modular.apputils.utils.PopupWindowHelper;
 import com.uas.appworks.OA.erp.adapter.FlightsAdapter;
 import com.uas.appworks.OA.erp.model.FlightsModel;
 import com.uas.appworks.OA.erp.presenter.FlightsPresernter;
 import com.uas.appworks.OA.erp.utils.MostLinearLayoutManager;
 import com.uas.appworks.OA.erp.view.IFlightsView;
+import com.uas.appworks.R;
 
 import java.util.List;
 
@@ -129,19 +128,15 @@ public class FlightsActivity extends OABaseActivity implements IFlightsView, Fli
     }
 
     private void showDeleteDialog(final int position) {
-        AlertDialog.Builder builder = new AlertDialog.Builder(ct);
-        builder.setTitle(R.string.common_dialog_title).setMessage(R.string.delete_back_default_work)
-                .setPositiveButton(R.string.common_sure, new DialogInterface.OnClickListener() {
-                    @Override
-                    public void onClick(DialogInterface dialogInterface, int i) {
-                        presernter.deleteWork(adapter.getModels(), position);
-                    }
-                })
-                .setNegativeButton(R.string.common_cancel, new DialogInterface.OnClickListener() {
+        PopupWindowHelper.showAlart(FlightsActivity.this, getString(R.string.common_dialog_title)
+                , getString(R.string.delete_back_default_work), new PopupWindowHelper.OnSelectListener() {
                     @Override
-                    public void onClick(DialogInterface dialogInterface, int i) {
+                    public void select(boolean selectOk) {
+                        if (selectOk) {
+                            presernter.deleteWork(adapter.getModels(), position);
+                        }
                     }
-                }).show();
+                });
     }
 
     private void endActivity() {

+ 13 - 7
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/MeetingActivity.java

@@ -272,14 +272,20 @@ public class MeetingActivity extends BaseActivity  {
             //当系统时间<开始时间 会议状态为未开始,
             // 当会议开始时间<系统时间会议状态为进行中,当会议发起人点击结束会议按钮,
             // 状态更新为已结束,否则即使超过会议结束时间状态也是进行中
-            String str = entities.get(i).getMa_stage();
-            if (str == null || str.trim().length() <= 0) {
-                if (TimeUtils.f_str_2_long(entities.get(i).getMa_starttime())<= System.currentTimeMillis())
-                    str = getResources().getString(R.string.doing);
-                else
-                    str = getResources().getString(R.string.not_bigan);
+            String status = entities.get(i).getMa_stage();
+            int statusColor=R.color.meeting_end_status;
+            if (status == null || status.trim().length() <= 0) {
+                if (TimeUtils.f_str_2_long(entities.get(i).getMa_starttime())<= System.currentTimeMillis()){
+                    status = getResources().getString(R.string.doing);
+                    statusColor=R.color.meeting_start_status;
+                }
+                else{
+                    status = getResources().getString(R.string.not_bigan);
+                    statusColor=R.color.meeting_end_status;
+                }
             }
-            entities.get(i).setMa_stage(str);
+            entities.get(i).setMa_stage(status);
+            viewholder.oa_meeting_status_tv.setTextColor(getResources().getColor(statusColor));
             viewholder.oa_meeting_status_tv.setText(entities.get(i).getMa_stage());
             long startLong = TimeUtils.f_str_2_long(entities.get(i).getMa_starttime());
             long endLong = TimeUtils.f_str_2_long(entities.get(i).getMa_endtime());

+ 30 - 32
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/OfficeAddressSettingsActivity.java

@@ -1,12 +1,10 @@
 package com.uas.appworks.OA.erp.activity;
 
 import android.app.Activity;
-import android.content.DialogInterface;
 import android.content.Intent;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Message;
-import android.support.v7.app.AlertDialog;
 import android.text.Editable;
 import android.text.Selection;
 import android.text.TextUtils;
@@ -45,9 +43,10 @@ import com.core.widget.view.Activity.SearchLocationActivity;
 import com.core.widget.view.Activity.SelectActivity;
 import com.core.widget.view.model.SearchPoiParam;
 import com.lidroid.xutils.ViewUtils;
-import com.uas.appworks.R;
+import com.modular.apputils.utils.PopupWindowHelper;
 import com.uas.appworks.OA.erp.model.OfficeAddressBean;
 import com.uas.appworks.OA.platform.model.PlatSignAddressBean;
+import com.uas.appworks.R;
 
 import org.json.JSONArray;
 import org.json.JSONException;
@@ -399,7 +398,7 @@ public class OfficeAddressSettingsActivity extends BaseActivity {
                     }
 
                     if (mOfficeAddressBean.getListdata().get(0).getCS_INNERDISTANCE() > 0) {
-                        work_range.setText(mOfficeAddressBean.getListdata().get(0).getCS_INNERDISTANCE() +  getString(R.string.rice));
+                        work_range.setText(mOfficeAddressBean.getListdata().get(0).getCS_INNERDISTANCE() + getString(R.string.rice));
                     } else {
                         work_range.setText(default_work_range + getString(R.string.rice));
                     }
@@ -756,45 +755,44 @@ public class OfficeAddressSettingsActivity extends BaseActivity {
             viewHolder.office_address_delete_im.setOnClickListener(new View.OnClickListener() {
                 @Override
                 public void onClick(View v) {
-                    new AlertDialog.Builder(mContext)
-                            .setTitle(getString(R.string.common_notice))
-                            .setMessage(getString(R.string.delete_address_notice1))
-                            .setNegativeButton(getString(R.string.common_cancel), null)
-                            .setPositiveButton(getString(R.string.common_sure), new DialogInterface.OnClickListener() {
+                    PopupWindowHelper.showAlart(OfficeAddressSettingsActivity.this,
+                            getString(R.string.common_notice), getString(R.string.delete_address_notice1),
+                            new PopupWindowHelper.OnSelectListener() {
                                 @Override
-                                public void onClick(DialogInterface dialog, int which) {
-                                    if (MyApplication.getInstance().isNetworkActive()) {
-                                        mPosition = position;
-                                        progressDialog.show();
-                                        finalViewHolder.office_address_delete_im.setEnabled(false);
-                                        if (mPosition < listdada_size) {
-                                            doDeleteAddress(mPosition, ok);
-                                            finalViewHolder.office_address_delete_im.setEnabled(true);
-                                        } else {
-                                            if (mPosition < address_names.size()) {
-                                                address_names.remove(mPosition);
-                                                address_location.remove(mPosition);
-                                                address_longitude.remove(mPosition);
-                                                address_latitud.remove(mPosition);
-                                                address_id.remove(mPosition);
-                                                myadapter.notifyDataSetChanged();
+                                public void select(boolean selectOk) {
+                                    if (selectOk) {
+                                        if (MyApplication.getInstance().isNetworkActive()) {
+                                            mPosition = position;
+                                            progressDialog.show();
+                                            finalViewHolder.office_address_delete_im.setEnabled(false);
+                                            if (mPosition < listdada_size) {
+                                                doDeleteAddress(mPosition, ok);
                                                 finalViewHolder.office_address_delete_im.setEnabled(true);
-                                                progressDialog.dismiss();
-                                            }
+                                            } else {
+                                                if (mPosition < address_names.size()) {
+                                                    address_names.remove(mPosition);
+                                                    address_location.remove(mPosition);
+                                                    address_longitude.remove(mPosition);
+                                                    address_latitud.remove(mPosition);
+                                                    address_id.remove(mPosition);
+                                                    myadapter.notifyDataSetChanged();
+                                                    finalViewHolder.office_address_delete_im.setEnabled(true);
+                                                    progressDialog.dismiss();
+                                                }
 
+                                            }
+                                        } else {
+                                            ToastMessage(getString(R.string.common_notlinknet));
                                         }
-                                    } else {
-                                        ToastMessage(getString(R.string.common_notlinknet));
                                     }
-
                                 }
-                            }).show();
+                            });
                 }
             });
             return convertView;
         }
 
-        private void doDeleteAddress(int mPosition,Boolean ok) {
+        private void doDeleteAddress(int mPosition, Boolean ok) {
             if (!ok) return;
             delete_position = mPosition;
             if (!platform) {

+ 27 - 27
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/SignSeniorSettingActivity.java

@@ -1,11 +1,9 @@
 package com.uas.appworks.OA.erp.activity;
 
-import android.content.DialogInterface;
 import android.content.Intent;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Message;
-import android.support.v7.app.AlertDialog;
 import android.text.TextUtils;
 import android.view.View;
 import android.widget.Button;
@@ -30,6 +28,7 @@ import com.core.utils.WorkHandlerUtil;
 import com.core.widget.view.Activity.SelectActivity;
 import com.core.widget.view.SwitchView;
 import com.lidroid.xutils.ViewUtils;
+import com.modular.apputils.utils.PopupWindowHelper;
 import com.uas.appworks.R;
 
 import java.util.ArrayList;
@@ -302,33 +301,33 @@ public class SignSeniorSettingActivity extends BaseActivity implements View.OnCl
         }
 
         if (!TextUtils.isEmpty(first_latetime)) {
-            if (Integer.parseInt(first_latetime) > 0){
+            if (Integer.parseInt(first_latetime) > 0) {
                 late_time_tv.setText(first_latetime + getString(R.string.minute));
-            }else {
+            } else {
                 late_time_tv.setText(0 + getString(R.string.minute));
             }
 
         }
         if (!TextUtils.isEmpty(first_overlatetime)) {
-            if (Integer.parseInt(first_overlatetime) > 0){
+            if (Integer.parseInt(first_overlatetime) > 0) {
                 serious_late_time_tv.setText(first_overlatetime + getString(R.string.minute));
-            }else{
+            } else {
                 serious_late_time_tv.setText(0 + getString(R.string.minute));
             }
         }
 
         if (!TextUtils.isEmpty(first_earlyoff)) {
-            if (Integer.parseInt(first_earlyoff) > 0){
+            if (Integer.parseInt(first_earlyoff) > 0) {
                 leave_early_tv.setText(first_earlyoff + getString(R.string.minute));
-            }else {
+            } else {
                 leave_early_tv.setText(0 + getString(R.string.minute));
             }
         }
 
         if (!TextUtils.isEmpty(first_nonclass)) {
-            if (Integer.parseInt(first_nonclass) > 0){
+            if (Integer.parseInt(first_nonclass) > 0) {
                 absenteeism_time_tv.setText(first_nonclass + getString(R.string.minute));
-            }else {
+            } else {
                 absenteeism_time_tv.setText(0 + getString(R.string.minute));
             }
         }
@@ -341,21 +340,21 @@ public class SignSeniorSettingActivity extends BaseActivity implements View.OnCl
     public void onClick(View v) {
         int requestCode = 0;
         String[] time = null;
-        if (v.getId() == R.id.senior_setting_late_time_tv){
+        if (v.getId() == R.id.senior_setting_late_time_tv) {
             time = getResources().getStringArray(R.array.late_time);
             requestCode = LATE_TIME_CODE;
-        }else if (v.getId() == R.id.senior_setting_serious_late_time_tv){
+        } else if (v.getId() == R.id.senior_setting_serious_late_time_tv) {
             time = getResources().getStringArray(R.array.serious_late_time);
             requestCode = ERIOUS_LATE_TIME;
-        }else if (v.getId() == R.id.senior_setting_leave_early_tv){
+        } else if (v.getId() == R.id.senior_setting_leave_early_tv) {
             time = getResources().getStringArray(R.array.serious_leave_early_time);
             requestCode = LEAVE_EARLY_TIME;
-        }else if (v.getId() == R.id.senior_setting_absenteeism_tv){
+        } else if (v.getId() == R.id.senior_setting_absenteeism_tv) {
             time = getResources().getStringArray(R.array.absenteeism_time);
             requestCode = ABSENTEEISM_TIME;
-        }else if (v.getId() == R.id.senior_setting_save_bt){
+        } else if (v.getId() == R.id.senior_setting_save_bt) {
             doTimejudgment();
-        }else if (v.getId() ==  R.id.senior_setting_auto_sign_sw){
+        } else if (v.getId() == R.id.senior_setting_auto_sign_sw) {
             if (!platform) {
                 doCheckjudge();
             } else {
@@ -389,19 +388,20 @@ public class SignSeniorSettingActivity extends BaseActivity implements View.OnCl
 
     private void doCheckjudge() {
         if (auto_sign == 1) {
-            new AlertDialog.Builder(mContext).setTitle(getString(R.string.common_notice)).setMessage(getString(R.string.ss_sign_close_notice2))
-                    .setNegativeButton(getString(R.string.common_cancel), null)
-                    .setPositiveButton(getString(R.string.common_sure), new DialogInterface.OnClickListener() {
+            PopupWindowHelper.showAlart(SignSeniorSettingActivity.this, getString(R.string.common_notice)
+                    , getString(R.string.ss_sign_close_notice2), new PopupWindowHelper.OnSelectListener() {
                         @Override
-                        public void onClick(DialogInterface dialog, int which) {
-                            if (!platform) {
-                                auto_sign = 0;
-                                doAutoSignSetting();
-                            } else {
-                                ToastMessage(getString(R.string.ss_sign_closed));
+                        public void select(boolean selectOk) {
+                            if (selectOk) {
+                                if (!platform) {
+                                    auto_sign = 0;
+                                    doAutoSignSetting();
+                                } else {
+                                    ToastMessage(getString(R.string.ss_sign_closed));
+                                }
                             }
                         }
-                    }).show();
+                    });
         } else if (auto_sign == 0) {
             if (!platform) {
                 auto_sign = 1;
@@ -496,7 +496,7 @@ public class SignSeniorSettingActivity extends BaseActivity implements View.OnCl
 
     @Override
     public void onCheckedChanged(View view, final boolean isChecked) {
-        if (view.getId() == R.id.signin_alert_sv){
+        if (view.getId() == R.id.signin_alert_sv) {
             PreferenceUtils.putBoolean(PreferenceUtils.AUTO_SIGN_SW, isChecked);
         }
     }

+ 16 - 19
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/WorkDailyShowActivity.java

@@ -1,13 +1,11 @@
 package com.uas.appworks.OA.erp.activity;
 
 import android.content.Context;
-import android.content.DialogInterface;
 import android.content.Intent;
 import android.os.Build;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Message;
-import android.support.v7.app.AlertDialog;
 import android.text.Editable;
 import android.text.TextUtils;
 import android.text.TextWatcher;
@@ -38,6 +36,7 @@ import com.core.widget.EmptyLayout;
 import com.core.widget.VoiceSearchView;
 import com.handmark.pulltorefresh.library.PullToRefreshBase;
 import com.handmark.pulltorefresh.library.PullToRefreshListView;
+import com.modular.apputils.utils.PopupWindowHelper;
 import com.uas.appworks.OA.erp.model.WorkReportBean;
 import com.uas.appworks.R;
 
@@ -541,28 +540,26 @@ public class WorkDailyShowActivity extends BaseActivity {
             viewHolder.WorkDailyDelete.setOnClickListener(new View.OnClickListener() {
                 @Override
                 public void onClick(View v) {
-                    new AlertDialog
-                            .Builder(mContext)
-                            .setTitle(mContext.getString(R.string.common_notice))
-                            .setMessage(mContext.getString(R.string.delete_notice1))
-                            .setNegativeButton(mContext.getString(R.string.common_cancel), null)
-                            .setPositiveButton(mContext.getString(R.string.common_sure), new DialogInterface.OnClickListener() {
+                    PopupWindowHelper.showAlart(WorkDailyShowActivity.this, getString(R.string.common_notice),
+                            getString(R.string.delete_notice1), new PopupWindowHelper.OnSelectListener() {
                                 @Override
-                                public void onClick(DialogInterface dialog, int which) {
-                                    if (CommonUtil.isNetWorkConnected(mContext)) {
-                                        int mkeyValue = workReportList.get(position).getReportId();
-                                        mFilterPosition = position;
-                                        for (int i = 0; i < mWorkReportList.size(); i++) {
-                                            if (mWorkReportList.get(i).getReportId() == mkeyValue) {
-                                                mRealPosition = i;
+                                public void select(boolean selectOk) {
+                                    if (selectOk) {
+                                        if (CommonUtil.isNetWorkConnected(mContext)) {
+                                            int mkeyValue = workReportList.get(position).getReportId();
+                                            mFilterPosition = position;
+                                            for (int i = 0; i < mWorkReportList.size(); i++) {
+                                                if (mWorkReportList.get(i).getReportId() == mkeyValue) {
+                                                    mRealPosition = i;
+                                                }
                                             }
+                                            dodelete(mkeyValue);
+                                        } else {
+                                            ToastUtil.showToast(mContext, R.string.networks_out);
                                         }
-                                        dodelete(mkeyValue);
-                                    } else {
-                                        ToastUtil.showToast(mContext, R.string.networks_out);
                                     }
                                 }
-                            }).show();
+                            });
                 }
             });
 

+ 73 - 89
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/WorkReportAddActivity.java

@@ -1,13 +1,11 @@
 package com.uas.appworks.OA.erp.activity;
 
-import android.content.DialogInterface;
 import android.content.Intent;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Message;
 import android.support.annotation.IdRes;
 import android.support.annotation.NonNull;
-import android.support.v7.app.AlertDialog;
 import android.text.Editable;
 import android.text.TextUtils;
 import android.text.TextWatcher;
@@ -45,6 +43,7 @@ import com.me.network.app.http.HttpClient;
 import com.me.network.app.http.Method;
 import com.me.network.app.http.rx.Result2Listener;
 import com.me.network.app.http.rx.ResultSubscriber;
+import com.modular.apputils.utils.PopupWindowHelper;
 import com.uas.appworks.OA.erp.model.WorkReportBean;
 import com.uas.appworks.R;
 
@@ -749,7 +748,7 @@ public class WorkReportAddActivity extends BaseActivity implements View.OnClickL
             mNewScheduleTitleTv.setText(R.string.work_schedule_tomorrow);
             mNewScheduleContentEt.setHint(R.string.please_input_work_schedule_tomorrow);
         } else if (mReportType == Constants.WORK_REPORT_WEEK) {
-           setTitle(R.string.oaworkweekly_title);
+            setTitle(R.string.oaworkweekly_title);
             mCaller = "WorkWeekly";
             mReportTimeBeforeRb.setText(R.string.str_last_week);
             mReportTimePresentRb.setText(R.string.str_this_week);
@@ -1180,17 +1179,15 @@ public class WorkReportAddActivity extends BaseActivity implements View.OnClickL
         } else if (mReportType == Constants.WORK_REPORT_MONTH) {
             submitNotice = String.format(submiString, "月");
         }
-        new AlertDialog
-                .Builder(mContext)
-                .setTitle(getString(R.string.common_notice))
-                .setMessage(submitNotice)
-                .setNegativeButton(getString(R.string.common_cancel), null)
-                .setPositiveButton(getString(R.string.common_sure), new DialogInterface.OnClickListener() {
+        PopupWindowHelper.showAlart(WorkReportAddActivity.this, getString(R.string.common_notice),
+                submitNotice, new PopupWindowHelper.OnSelectListener() {
                     @Override
-                    public void onClick(DialogInterface dialog, int which) {
-                        sendWorkDailyByErp();
+                    public void select(boolean selectOk) {
+                        if (selectOk) {
+                            sendWorkDailyByErp();
+                        }
                     }
-                }).show();
+                });
     }
 
     private void sendWorkDailyByErp() {
@@ -1385,50 +1382,43 @@ public class WorkReportAddActivity extends BaseActivity implements View.OnClickL
         final boolean isResubmit = !TextUtils.isEmpty(resubmit) && ("unsub_tosub".equals(resubmit) || "resubmit".equals(resubmit));
         if ((isResubmit && isUpdateModify) || (mReportTimePresentRb.isChecked() && isPresentExist && isPresentModify)
                 || (mReportTimeBeforeRb.isChecked() && isBeforeExist && isBeforeModify)) {
-
-            new AlertDialog
-                    .Builder(mContext)
-                    .setTitle(getString(R.string.common_notice))
-                    .setMessage("正在离开录入页面,是否更新汇报内容?")
-                    .setNegativeButton(R.string.give_up, new DialogInterface.OnClickListener() {
+            PopupWindowHelper.showAlart(WorkReportAddActivity.this,
+                    getString(R.string.common_notice), "正在离开录入页面,是否更新汇报内容?",
+                    new PopupWindowHelper.OnSelectListener() {
                         @Override
-                        public void onClick(DialogInterface dialog, int which) {
-                            if (isResubmit || isOptionEvent) {
-                                Intent intent1 = new Intent(WorkReportAddActivity.this, WorkDailyShowActivity.class);
-                                intent1.putExtra("caller", mCaller);
-                                intent1.putExtra("report_type", mReportType);
-                                if (isOptionEvent) {
-                                    intent1.putExtra("fromwhere", "nosubmitdaily");
-                                }
-                                startActivityForResult(intent1, WORK_REPORT_LIST);
-                            }
-                            if (!isOptionEvent) {
-                                finish();
-                            }
-                        }
-                    })
-                    .setPositiveButton(R.string.updata, new DialogInterface.OnClickListener() {
-                        @Override
-                        public void onClick(DialogInterface dialog, int which) {
-                            if (mSummaryContentEt.testValidity()) {
-                                if (mNewScheduleContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER &&
-                                        mExperienceContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER) {
-                                    if (CommonUtil.isNetWorkConnected(WorkReportAddActivity.this)) {
-                                        isOnlyUpdate = true;
-                                        progressDialog.show();
-                                        updateWorkReport();
+                        public void select(boolean selectOk) {
+                            if (selectOk) {
+                                if (mSummaryContentEt.testValidity()) {
+                                    if (mNewScheduleContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER &&
+                                            mExperienceContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER) {
+                                        if (CommonUtil.isNetWorkConnected(WorkReportAddActivity.this)) {
+                                            isOnlyUpdate = true;
+                                            progressDialog.show();
+                                            updateWorkReport();
+                                        } else {
+                                            ToastUtil.showToast(WorkReportAddActivity.this, R.string.networks_out);
+                                        }
+
                                     } else {
-                                        ToastUtil.showToast(WorkReportAddActivity.this, R.string.networks_out);
+                                        ToastUtil.showToast(WorkReportAddActivity.this, "字数已超限!");
                                     }
-
-                                } else {
-                                    ToastUtil.showToast(WorkReportAddActivity.this, "字数已超限!");
+                                }
+                            } else {
+                                if (isResubmit || isOptionEvent) {
+                                    Intent intent1 = new Intent(WorkReportAddActivity.this, WorkDailyShowActivity.class);
+                                    intent1.putExtra("caller", mCaller);
+                                    intent1.putExtra("report_type", mReportType);
+                                    if (isOptionEvent) {
+                                        intent1.putExtra("fromwhere", "nosubmitdaily");
+                                    }
+                                    startActivityForResult(intent1, WORK_REPORT_LIST);
+                                }
+                                if (!isOptionEvent) {
+                                    finish();
                                 }
                             }
-
                         }
-                    }).create().show();
-
+                    });
         } else {
             if (((mReportTimePresentRb.isChecked() && !isPresentExist)
                     || (mReportTimeBeforeRb.isChecked() && !isBeforeExist)) && !isResubmit) {
@@ -1437,53 +1427,47 @@ public class WorkReportAddActivity extends BaseActivity implements View.OnClickL
                         mExperienceText.length() > 0) {
                     if (mNewScheduleContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER &&
                             mExperienceContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER) {
-                        new AlertDialog
-                                .Builder(mContext)
-                                .setTitle(getString(R.string.common_notice))
-                                .setMessage(getString(R.string.work_report_exit_notice))
-                                .setNegativeButton(R.string.give_up, new DialogInterface.OnClickListener() {
+                        PopupWindowHelper.showAlart(WorkReportAddActivity.this, getString(R.string.common_notice),
+                                getString(R.string.work_report_exit_notice), new PopupWindowHelper.OnSelectListener() {
                                     @Override
-                                    public void onClick(DialogInterface dialog, int which) {
-                                        boolean isResubmit = !TextUtils.isEmpty(resubmit) && ("unsub_tosub".equals(resubmit) || "resubmit".equals(resubmit));
-                                        if (isResubmit || isOptionEvent) {
-                                            Intent optionIntent = new Intent(WorkReportAddActivity.this, WorkDailyShowActivity.class);
-                                            optionIntent.putExtra("caller", mCaller);
-                                            optionIntent.putExtra("report_type", mReportType);
-                                            if (isOptionEvent) {
-                                                optionIntent.putExtra("fromwhere", "nosubmitdaily");
-                                            }
-                                            startActivityForResult(optionIntent, WORK_REPORT_LIST);
-                                        } else if (!TextUtils.isEmpty(fromqzone) && "fromqzone".equals(fromqzone)) {
+                                    public void select(boolean selectOk) {
+                                        if (selectOk) {
+                                            if (mSummaryContentEt.testValidity()) {
+                                                if (mNewScheduleContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER &&
+                                                        mExperienceContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER) {
+                                                    if (CommonUtil.isNetWorkConnected(WorkReportAddActivity.this)) {
+                                                        progressDialog.show();
+                                                        saveWorkReport();
+                                                    } else {
+                                                        ToastUtil.showToast(WorkReportAddActivity.this, R.string.networks_out);
+                                                    }
+                                                } else {
+                                                    ToastUtil.showToast(WorkReportAddActivity.this, "字数已超限!");
+                                                }
 
+                                            }
                                         } else {
-                                            Intent intent1 = new Intent(WorkReportAddActivity.this, WorkReportMenuActivity.class);
-                                            startActivity(intent1);
-                                        }
-                                        if (!isOptionEvent) {
-                                            finish();
-                                        }
-                                    }
-                                })
-                                .setPositiveButton(R.string.save, new DialogInterface.OnClickListener() {
-
-                                    @Override
-                                    public void onClick(DialogInterface dialog, int which) {
-                                        if (mSummaryContentEt.testValidity()) {
-                                            if (mNewScheduleContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER &&
-                                                    mExperienceContentEt.getText().toString().length() <= WORD_RESTRICTION_NUMBER) {
-                                                if (CommonUtil.isNetWorkConnected(WorkReportAddActivity.this)) {
-                                                    progressDialog.show();
-                                                    saveWorkReport();
-                                                } else {
-                                                    ToastUtil.showToast(WorkReportAddActivity.this, R.string.networks_out);
+                                            boolean isResubmit = !TextUtils.isEmpty(resubmit) && ("unsub_tosub".equals(resubmit) || "resubmit".equals(resubmit));
+                                            if (isResubmit || isOptionEvent) {
+                                                Intent optionIntent = new Intent(WorkReportAddActivity.this, WorkDailyShowActivity.class);
+                                                optionIntent.putExtra("caller", mCaller);
+                                                optionIntent.putExtra("report_type", mReportType);
+                                                if (isOptionEvent) {
+                                                    optionIntent.putExtra("fromwhere", "nosubmitdaily");
                                                 }
+                                                startActivityForResult(optionIntent, WORK_REPORT_LIST);
+                                            } else if (!TextUtils.isEmpty(fromqzone) && "fromqzone".equals(fromqzone)) {
+
                                             } else {
-                                                ToastUtil.showToast(WorkReportAddActivity.this, "字数已超限!");
+                                                Intent intent1 = new Intent(WorkReportAddActivity.this, WorkReportMenuActivity.class);
+                                                startActivity(intent1);
+                                            }
+                                            if (!isOptionEvent) {
+                                                finish();
                                             }
-
                                         }
                                     }
-                                }).show();
+                                });
                     }
                 } else if (!TextUtils.isEmpty(fromqzone) && "fromqzone".equals(fromqzone)) {
                     finish();

+ 5 - 0
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/form/DataFormDetailActivity.java

@@ -1510,6 +1510,11 @@ public class DataFormDetailActivity extends BaseActivity implements View.OnClick
 
     }
 
+    @Override
+    protected void onDestroy() {
+        CommonUtil.closeKeybord(this);
+        super.onDestroy();
+    }
 
     private void paseSelectDbFind(JSONObject object) throws Exception {
         List<Data> tempLists = mAdapter.getmListData().get(0).getDatas();

+ 11 - 11
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/activity/form/FormListSelectActivity.java

@@ -170,17 +170,18 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
 
     private void initIDs() {
         mlistview = findViewById(R.id.lv_sale_list);
-        voiceSearchView =findViewById(R.id.voiceSearchView);
+        voiceSearchView = findViewById(R.id.voiceSearchView);
         ivDeleteText = findViewById(R.id.iv_DeleteText);
     }
 
     private static final String TAG = "FormListSelectActivity";
+
     private void initView() {
         Intent intent = getIntent();
         caller = intent.getStringExtra("caller");
         from = intent.getStringExtra("from");
-        statusKey  =intent.getStringExtra("statusKey");
-        LogUtil.d(TAG,"statusKey:"+statusKey);
+        statusKey = intent.getStringExtra("statusKey");
+        LogUtil.d(TAG, "statusKey:" + statusKey);
         if (!StringUtil.isEmpty(intent.getStringExtra("title"))) {
             setTitle(intent.getStringExtra("title"));
         }
@@ -191,11 +192,11 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
         key = user + master + caller;
         calendar = Calendar.getInstance();
         sBroadcast = new StateBroadcast();
-        
+
         IntentFilter intentFilter = new IntentFilter();
         intentFilter.addAction("com.erp.sale.dataupdate");
         registerReceiver(sBroadcast, intentFilter);
-        
+
         mlistview.setFilterTouchEvents(false);
         mlistview.setMode(PullToRefreshBase.Mode.BOTH);
         mlistview.setOnRefreshListener(new PullToRefreshBase.OnRefreshListener2<ListView>() {
@@ -280,7 +281,6 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
             }
         });
 
-     
 
         voiceSearchView.addTextChangedListener(new TextWatcher() {
             @Override
@@ -310,8 +310,7 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
             }
         });
 
-        
-        
+
         mlistview.setOnItemClickListener(new AdapterView.OnItemClickListener() {
 
             @Override
@@ -341,8 +340,8 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
 //                } else {
 //                    statusKey = "ct_status";
 //                }
-                if (StringUtil.isEmpty(statusKey)){
-                    statusKey="ct_status";
+                if (StringUtil.isEmpty(statusKey)) {
+                    statusKey = "ct_status";
                 }
                 if (StringUtil.isEmpty(pfField)) {
                     pfField = keyField;
@@ -397,7 +396,7 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
                         startActivity(new Intent(mContext,
                                 DataFormDetailActivity.class)
                                 .putExtra("caller", caller)
-                                .putExtra("title",getToolBarTitle().toString())
+                                .putExtra("title", getToolBarTitle().toString())
                                 .putExtra("status", status)
                                 .putExtra("id", keyId));
                     }
@@ -493,6 +492,7 @@ public class FormListSelectActivity extends BaseActivity implements View.OnClick
 
     @Override
     protected void onDestroy() {
+        CommonUtil.closeKeybord(this);
         super.onDestroy();
         unregisterReceiver(sBroadcast);
     }

+ 0 - 1
app_modular/appworks/src/main/java/com/uas/appworks/OA/erp/utils/approvautils/NodeAdapter.java

@@ -74,7 +74,6 @@ public class NodeAdapter extends BaseAdapter {
     private void bindNodeView(NodeViewHolder holder, int position) {
         Approval approval = approvals.get(position);
         holder.padding.setVisibility(View.GONE);
-
         if (position == 0) {
             holder.lineTop.setVisibility(View.GONE);
         } else {

+ 2 - 0
app_modular/appworks/src/main/java/com/uas/appworks/OA/platform/activity/PurchaseDetailsActivity.java

@@ -23,6 +23,7 @@ import com.common.thread.ThreadPool;
 import com.core.api.wxapi.ApiPlatform;
 import com.core.app.Constants;
 import com.core.app.MyApplication;
+import com.core.base.view.AndroidBug5497Workaround;
 import com.core.net.http.http.OAHttpHelper;
 import com.core.utils.CommonUtil;
 import com.core.utils.ToastUtil;
@@ -81,6 +82,7 @@ public class PurchaseDetailsActivity extends BaseNetActivity implements OnSmartH
 
     @Override
     protected void init() throws Exception {
+        AndroidBug5497Workaround.assistActivity(this);
         Intent intent = getIntent();
         initIntent(intent);
         initView();

+ 5 - 4
app_modular/appworks/src/main/java/com/uas/appworks/activity/CustomerInquiryDetailActivity.java

@@ -22,6 +22,7 @@ import com.core.api.wxapi.ApiPlatform;
 import com.core.app.Constants;
 import com.core.app.MyApplication;
 import com.core.base.activity.BaseMVPActivity;
+import com.core.base.view.AndroidBug5497Workaround;
 import com.core.utils.CommonUtil;
 import com.me.network.app.base.HttpCallback;
 import com.me.network.app.base.HttpParams;
@@ -76,7 +77,7 @@ public class CustomerInquiryDetailActivity extends BaseMVPActivity<WorkPlatPrese
 
     @Override
     protected void initView() {
-
+        AndroidBug5497Workaround.assistActivity(this);
         mDataRecyclerView = $(R.id.customer_inquiry_detail_data_rv);
         mQuoteRecyclerView = $(R.id.customer_inquiry_detail_quote_rv);
         mAddImageView = $(R.id.customer_inquiry_detail_add_iv);
@@ -150,7 +151,7 @@ public class CustomerInquiryDetailActivity extends BaseMVPActivity<WorkPlatPrese
                         initEditable(false, View.GONE);
                         break;
                     case Constants.FLAG.STATE_CUSTOMER_INQUIRY_REFUSED:
-                       setTitle(R.string.str_quotation_unadopted);
+                        setTitle(R.string.str_quotation_unadopted);
                         initEditable(false, View.GONE);
                         break;
                     case Constants.FLAG.STATE_CUSTOMER_INQUIRY_INVALID:
@@ -162,7 +163,7 @@ public class CustomerInquiryDetailActivity extends BaseMVPActivity<WorkPlatPrese
                         initEditable(false, View.GONE);
                         break;
                     case Constants.FLAG.STATE_PUBLIC_INQUIRY_TODO:
-                       setTitle(R.string.str_wait_quoted);
+                        setTitle(R.string.str_wait_quoted);
                         initEditable(true, View.VISIBLE);
                         break;
                     case Constants.FLAG.STATE_PUBLIC_INQUIRY_INVALID:
@@ -532,7 +533,7 @@ public class CustomerInquiryDetailActivity extends BaseMVPActivity<WorkPlatPrese
         String result = o.toString();
         LogUtil.prinlnLongMsg("customerdetailsuccess", result);
         if (flag == CUSTOMER_INQUIRY_REPLY) {
-          setTitle(R.string.str_quoted_price);
+            setTitle(R.string.str_quoted_price);
             toast(getString(R.string.quote_success));
             String publicId = "";
             if (Constants.FLAG.STATE_PUBLIC_INQUIRY_TODO.equals(mState)) {