Browse Source

RMS开发功能 商机详情

Arisono 9 years ago
parent
commit
823739dc15

+ 28 - 12
WeiChat/src/main/AndroidManifest.xml

@@ -69,7 +69,7 @@
         android:allowBackup="true"
         android:icon="@drawable/uuu"
         android:label="@string/app_name"
-        android:theme="@style/AppTheme">
+        android:theme="@style/AppTheme" >
         <meta-data
             android:name="UMENG_APPKEY"
             android:value="574504a167e58eec520017df" />
@@ -80,7 +80,7 @@
         <!-- 启动页面 -->
         <activity
             android:name=".ui.SplashActivity"
-            android:theme="@style/SplashTheme">
+            android:theme="@style/SplashTheme" >
             <intent-filter>
                 <action android:name="android.intent.action.MAIN" />
 
@@ -240,7 +240,7 @@
             android:exported="true"
             android:icon="@drawable/ic_chooser"
             android:label="@string/choose_file"
-            android:theme="@style/ChooserTheme">
+            android:theme="@style/ChooserTheme" >
             <intent-filter>
                 <action android:name="android.intent.action.GET_CONTENT" />
 
@@ -257,13 +257,13 @@
             android:enabled="@bool/use_provider"
             android:exported="true"
             android:grantUriPermissions="true"
-            android:permission="android.permission.MANAGE_DOCUMENTS">
+            android:permission="android.permission.MANAGE_DOCUMENTS" >
             <intent-filter>
                 <action android:name="android.content.action.DOCUMENTS_PROVIDER" />
             </intent-filter>
         </provider>
 
-        <receiver android:name=".broadcast.ScrenLockedBroadCastReceiver">
+        <receiver android:name=".broadcast.ScrenLockedBroadCastReceiver" >
             <intent-filter>
                 <action android:name="android.intent.action.SCREEN_OFF" />
                 <action android:name="android.intent.action.SCREEN_ON" />
@@ -290,7 +290,7 @@
         <!-- 用于接收系统消息以保证PushService正常运行 -->
         <receiver
             android:name="com.baidu.android.pushservice.PushServiceReceiver"
-            android:process=":bdservice_v1">
+            android:process=":bdservice_v1" >
             <intent-filter>
                 <action android:name="android.intent.action.BOOT_COMPLETED" />
                 <action android:name="android.net.conn.CONNECTIVITY_CHANGE" />
@@ -306,7 +306,7 @@
         <!-- Push服务接收客户端发送的各种请求 -->
         <receiver
             android:name="com.baidu.android.pushservice.RegistrationReceiver"
-            android:process=":bdservice_v1">
+            android:process=":bdservice_v1" >
             <intent-filter>
                 <action android:name="com.baidu.android.pushservice.action.METHOD" />
                 <action android:name="com.baidu.android.pushservice.action.BIND_SYNC" />
@@ -325,7 +325,7 @@
             android:name="com.baidu.android.pushservice.PushService"
             android:exported="true"
             android:persistent="true"
-            android:process=":bdservice_v1">
+            android:process=":bdservice_v1" >
             <intent-filter>
                 <action android:name="com.baidu.android.pushservice.action.PUSH_SERVICE" />
             </intent-filter>
@@ -339,7 +339,7 @@
 
 
         <!-- 此处Receiver名字修改为当前包名路径 -->
-        <receiver android:name=".ui.PushNetMessageReceiver">
+        <receiver android:name=".ui.PushNetMessageReceiver" >
             <intent-filter>
 
                 <!-- 接收push消息 -->
@@ -360,7 +360,7 @@
             </intent-filter>
         </activity>
         -->
-        <activity android:name=".ui.message.SelectCardActivity">
+        <activity android:name=".ui.message.SelectCardActivity" >
             <intent-filter>
                 <action android:name="com.xzjmyk.pm.activity.ui.message.SelectCardActivity" />
             </intent-filter>
@@ -384,7 +384,7 @@
 
         <receiver
             android:name="com.baidu.autoupdatesdk.receiver.BDBroadcastReceiver"
-            android:exported="false">
+            android:exported="false" >
             <intent-filter>
                 <action android:name="com.baidu.autoupdatesdk.ACTION_NEW_UPDATE" />
                 <action android:name="com.baidu.autoupdatesdk.ACTION_DOWNLOAD_COMPLETE" />
@@ -399,13 +399,29 @@
         <activity android:name=".ui.erp.activity.SubscribeActivity" />
         <activity android:name=".ui.message.SubscriptionActivity" />
         <activity android:name=".ui.circle.PhoneSelectActivity" />
-        <activity android:name=".ui.erp.activity.ClientActivity" />
+        <activity
+            android:name=".ui.erp.activity.ClientActivity"
+            android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
         <activity
             android:name=".ui.erp.activity.SigninActivity"
             android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
         <activity
             android:name=".ui.erp.activity.OA_AlarmaActivity"
             android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
+        <activity
+            android:name=".ui.erp.activity.MeetingActivity"
+            android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
+        <activity
+            android:name=".ui.erp.activity.AddMeetingActivity"
+            android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
+        <activity
+            android:name=".ui.erp.activity.OAActivity"
+            android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
+        <activity
+            android:name=".ui.erp.activity.StatisticsActivity"
+            android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
+        <activity android:name=".ui.erp.activity.TextErpActivity" >
+        </activity>
         <activity android:name=".ui.erp.activity.crm.BusinessActivity" />
         <activity android:name=".ui.erp.activity.crm.BusinessDetailActivty" />
         <activity android:name=".ui.erp.activity.crm.BusinessDetailInfoActivity"></activity>

+ 19 - 0
WeiChat/src/main/java/com/xzjmyk/pm/activity/db/dao/SubscriptionDao.java

@@ -129,6 +129,25 @@ public class SubscriptionDao {
         return k;
     }
 
+    public long UpdateStatus(String id, boolean status) {
+        long k = 0;
+        SQLiteDatabase db = sqliteHelper.getWritableDatabase();
+        ContentValues values = new ContentValues();
+        if (status)
+            values.put("status_", -1);
+        else
+            values.put("status_", 0);
+        String where = "id_=?";
+        String[] whereArgs = {id};
+        try {
+            k = db.update(titleName, values, where, whereArgs);
+        } catch (SQLException e) {
+
+        } finally {
+            db.close();
+        }
+        return k;
+    }
 
     public ArrayList<SubscriptionMessage> findAll() {
         ArrayList<SubscriptionMessage> messages = new ArrayList<>();

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

@@ -73,7 +73,6 @@ import java.util.regex.Pattern;
  * @author Dean Tao
  */
 public class BasicInfoActivity extends BaseActivity implements NewFriendListener {
-
     private ImageView mAvatarImg;
     private RelativeLayout tel_rl;
     private TextView mNameTv;

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

@@ -23,13 +23,9 @@ public class TextErpActivity extends BaseActivity implements View.OnClickListene
         switch (view.getId()) {
             case R.id.btn1:
                 String url = Constants.getAppBaseUrl(ct);
-                url = "http://192.168.253.233:8080/ERP//";
-//                http://218.17.158.219:8090/ERP//+"mobile/login.action";
-//                UAS
                 ViewUtil.ct = ct;
                 ViewUtil.LoginERPTask(ct, url, "UAS", "15972129063", 1 + "");
                 break;
-
         }
     }
 }

+ 47 - 6
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/activity/WebViewCommActivity.java

@@ -4,7 +4,8 @@ import android.annotation.SuppressLint;
 import android.content.Context;
 import android.content.Intent;
 import android.os.Bundle;
-import android.util.Log;
+import android.os.Handler;
+import android.os.Message;
 import android.view.View;
 import android.webkit.CookieManager;
 import android.webkit.CookieSyncManager;
@@ -15,14 +16,19 @@ import android.widget.ImageView;
 import android.widget.ProgressBar;
 import android.widget.TextView;
 
+import com.alibaba.fastjson.JSON;
 import com.handmark.pulltorefresh.library.PullToRefreshWebView;
 import com.xzjmyk.pm.activity.MyApplication;
 import com.xzjmyk.pm.activity.R;
 import com.xzjmyk.pm.activity.ui.MainActivity;
 import com.xzjmyk.pm.activity.ui.base.BaseActivity;
+import com.xzjmyk.pm.activity.ui.erp.net.ViewUtil;
+import com.xzjmyk.pm.activity.ui.erp.util.CommonUtil;
 import com.xzjmyk.pm.activity.ui.erp.util.StringUtils;
 
 import org.apache.http.cookie.Cookie;
+import org.json.JSONException;
+import org.json.JSONObject;
 
 /**
  * Created by Administrator on 2016/4/5.
@@ -37,6 +43,39 @@ public class WebViewCommActivity extends BaseActivity {
     private TextView tck_icon;
     private boolean isStartApp = false;
     private boolean isCookie;
+    private int reCode = 201;
+    Handler hander = new Handler() {
+        @Override
+        public void handleMessage(Message msg) {
+            if (msg.what == reCode) {
+                //登录成功
+                String result = msg.getData().getString("result");
+                try {
+                    JSONObject jsonObject = new JSONObject(result);
+                    boolean success = JSON.parseObject(result).getBoolean("success");
+                    if (success) {
+                        if (!jsonObject.isNull("sessionId")) {
+                            CommonUtil.setSharedPreferences(WebViewCommActivity.this, "sessionId", jsonObject.getString("sessionId"));
+
+                        }
+//                        doNextLoadURL();  //不敢加   当第一次加载出现错误登录erp然后进行第二次登录操作后再次加载操作
+                    }
+                } catch (JSONException e) {
+                    e.printStackTrace();
+                }
+
+            }
+        }
+    };
+
+    private void doNextLoadURL() {
+        if (isCookie) {
+            synCookies(this, url);
+        } else {
+            clearCookie();
+        }
+        webView.getRefreshableView().loadUrl(url);
+    }
 
     @SuppressLint("SetJavaScriptEnabled")
     @Override
@@ -64,7 +103,7 @@ public class WebViewCommActivity extends BaseActivity {
         if (p != null) {
             getSupportActionBar().setTitle(p);
         }
-        if (StringUtils.isEmpty(url)) {
+        if (StringUtils.isEmpty(url)) {//为空时默认为b2b平台的
             url = "http://www.baidu.com";
         }
         webView.getRefreshableView().getSettings().setJavaScriptEnabled(true);
@@ -80,7 +119,6 @@ public class WebViewCommActivity extends BaseActivity {
         webView.getRefreshableView().loadUrl(url);
         webView.getRefreshableView().setWebViewClient(new WebViewClient() {
             public boolean shouldOverrideUrlLoading(WebView view, String url) {
-                System.out.println("link url=" + url);
                 if (!url.equals("http://www.ubtob.com/signin#")) {
                     if (isCookie) {
                         synCookies(WebViewCommActivity.this, url);
@@ -115,7 +153,6 @@ public class WebViewCommActivity extends BaseActivity {
     public class WebChromeClient extends android.webkit.WebChromeClient {
         @Override
         public void onProgressChanged(WebView view, int newProgress) {
-
             pb.setProgress(newProgress);
             if (newProgress == 100) {
                 pb.setProgress(newProgress);
@@ -130,8 +167,11 @@ public class WebViewCommActivity extends BaseActivity {
      * 同步一下cookie
      */
     public void synCookies(Context context, String url) {
-        if (MyApplication.cookieERP == null) return;
-        Log.i("gongpengming", "没有retuen");
+        if (MyApplication.cookieERP == null) {
+            ViewUtil.ct = this;
+            ViewUtil.LoginERPTask(this, hander, reCode);
+            return;
+        }
         CookieSyncManager.createInstance(context);
         CookieManager cookieManager = CookieManager.getInstance();
         cookieManager.setAcceptCookie(true);
@@ -163,4 +203,5 @@ public class WebViewCommActivity extends BaseActivity {
         }
     }
 
+
 }

+ 3 - 3
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/fragment/WorksFragment.java

@@ -17,7 +17,7 @@ import com.xzjmyk.pm.activity.ui.MainActivity;
 import com.xzjmyk.pm.activity.ui.base.XutilsFragment;
 import com.xzjmyk.pm.activity.ui.circle.BusinessCircleActivity;
 import com.xzjmyk.pm.activity.ui.erp.activity.ClientActivity;
-import com.xzjmyk.pm.activity.ui.erp.activity.ErpMenActivity;
+import com.xzjmyk.pm.activity.ui.erp.activity.OAActivity;
 import com.xzjmyk.pm.activity.ui.erp.net.ViewUtil;
 import com.xzjmyk.pm.activity.ui.erp.util.CommonUtil;
 import com.xzjmyk.pm.activity.util.PreferenceUtils;
@@ -94,8 +94,8 @@ public class WorksFragment extends XutilsFragment implements View.OnClickListene
                 ViewUtil.WebLinks(ct, url, "我的商务");
                 break;
             case R.id.rl_uas_sys:
-                ct.startActivity(new Intent(ct, ErpMenActivity.class));
-//                ct.startActivity(new Intent(ct, OAActivity.class));
+//                ct.startActivity(new Intent(ct, ErpMenActivity.class));
+                ct.startActivity(new Intent(ct, OAActivity.class));
                 break;
             case R.id.my_client_rl:
                 ct.startActivity(new Intent(ct, ClientActivity.class));

+ 1 - 2
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/net/HttpClient.java

@@ -332,8 +332,7 @@ public class HttpClient {
             cookieStore = ((AbstractHttpClient) httpclient).getCookieStore();
             Log.i("Arison", "cookies:" + JSON.toJSONString(cookieStore));
             for (int i = 0; i < cookieStore.getCookies().size(); i++) {
-                Log.i("gongpengming", cookieStore.getCookies().get(i)
-                        .getDomain());
+
                 if ("www.ubtob.com".equals(cookieStore.getCookies().get(i)
                         .getDomain())) {
                     // 保存b2b平台的cookie

+ 46 - 15
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/net/ViewUtil.java

@@ -319,9 +319,22 @@ public class ViewUtil {
                 bundle, "get");
     }
 
+    public static void LoginTaskERP(String user_phone, String user_password, Context ct) {
+        ViewUtil.ct = ct;
+        String url = Constants.BASE_URL_LOGIN;
+        Map<String, String> params = new HashMap<String, String>();
+        params.put("user", user_phone);
+        params.put("password", user_password);
+        Message message = new Message();
+        Bundle bundle = new Bundle();
+        bundle.putString("phone", user_phone);
+        bundle.putString("password", user_password);
+        startNetThread(url, params, handler, Constants.SUCCESS_LOGIN, message,
+                bundle, "get");
+    }
+
     // 登录B2B
     public static void LoginB2BTask(String phone, String password) {
-
         mdProcessDialog.setContent("正在验证B2B...");
         String url = Constants.serviceURL;
         Map<String, String> params = new HashMap<String, String>();
@@ -331,18 +344,6 @@ public class ViewUtil {
                 "post");
     }
 
-    // 登录ERP
-    public static void LoginERPTask(String url, String master, String username,
-                                    String password) {
-        mdProcessDialog.setContent("正在验证ERP...");
-        url = url + "mobile/login.action";
-        Map<String, String> params = new HashMap<String, String>();
-        params.put("username", username);
-        params.put("password", password);
-        params.put("master", master);
-        startNetThread(url, params, handler, Constants.SUCCESS_ERP, null, null,
-                "post");
-    }
 
     private static List<LoginEntity> erpEntities;
     public static Handler handler = new Handler() {
@@ -381,6 +382,10 @@ public class ViewUtil {
     };
 
     public static void ChangeStatusERP(String result) {
+        ChangeStatusERP(result, true);
+    }
+
+    public static void ChangeStatusERP(String result, boolean isBrodcast) {
         if (mdProcessDialog != null) {
             mdProcessDialog.setContent("UAS验证成功!");
         }
@@ -424,7 +429,8 @@ public class ViewUtil {
                 ct.startActivity(new Intent(ct, DataDownloadActivity.class));
             }
         }
-        sendBrodcast("ERP");
+        if (isBrodcast)
+            sendBrodcast("ERP");
     }
 
     public static void ChangeStatusB2B(String result) {
@@ -767,7 +773,6 @@ public class ViewUtil {
             ViewUtil.ct = ct;
             String url = Constants.getAppBaseUrl(ct);
             String master = CommonUtil.getSharedPreferences(ct, "erp_master");
-
             String phone = CommonUtil.getSharedPreferences(ct, "user_phone");
             String password = CommonUtil.getSharedPreferences(ct, "user_password");
             Log.i("LoginErp", "自动登录..." + url);
@@ -789,6 +794,32 @@ public class ViewUtil {
         httpSendRequest(ct, url, params, handler, null, Constants.SUCCESS_ERP, null, null, "post");
     }
 
+    // 登录ERP gongpengming
+    public static void LoginERPTask(Context ct, Handler handler, int what) {
+        String url = Constants.getAppBaseUrl(ct) + "mobile/login.action";
+        String master = CommonUtil.getSharedPreferences(ct, "erp_master");
+        String phone = CommonUtil.getSharedPreferences(ct, "user_phone");
+        String password = CommonUtil.getSharedPreferences(ct, "user_password");
+        Map<String, String> params = new HashMap<String, String>();
+        params.put("username", phone);
+        params.put("password", password);
+        params.put("master", master);
+        startNetThread(url, params, handler, what, null, null, "post");
+    }
+
+    // 登录ERP
+    public static void LoginERPTask(String url, String master, String username,
+                                    String password) {
+        mdProcessDialog.setContent("正在验证ERP...");
+        url = url + "mobile/login.action";
+        Map<String, String> params = new HashMap<String, String>();
+        params.put("username", username);
+        params.put("password", password);
+        params.put("master", master);
+        startNetThread(url, params, handler, Constants.SUCCESS_ERP, null, null,
+                "post");
+    }
+
 
     /**
      * @注释:跳转嵌入网页页面

+ 3 - 3
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/message/MessageFragment.java

@@ -10,7 +10,6 @@ import android.os.Message;
 import android.text.Editable;
 import android.text.TextUtils;
 import android.text.TextWatcher;
-import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
@@ -653,7 +652,6 @@ public class MessageFragment extends EasyFragment {
     }
 
 
-
     private final int load_success_erpMsgNum = 5;
     private Handler handler = new Handler() {
         @Override
@@ -847,6 +845,7 @@ public class MessageFragment extends EasyFragment {
 
     public void getErpMsgNums(Message msg) {
         String reString = msg.getData().getString("result");
+
         if (reString != null && !reString.equals("500")) {
             Map<String, Object> results = FlexJsonUtil.fromJson(reString);
             if (results.get("allProcess") != null) {
@@ -863,7 +862,8 @@ public class MessageFragment extends EasyFragment {
                         task_num++;
                     } else if (allProcesses.get(i).getTypecode()
                             .contains("dingyue")) {
-                        pagin_num++;
+                        if (allProcesses.get(i).getStatus() == "0")
+                            pagin_num++;
                     } else {
                         daiban_num++;
                     }

+ 32 - 10
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/message/SubscriptionActivity.java

@@ -5,6 +5,7 @@ import android.content.DialogInterface;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Message;
+import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
@@ -62,12 +63,14 @@ public class SubscriptionActivity extends BaseActivity {
         @Override
         public void handleMessage(Message msg) {
             String message = (String) msg.getData().get("result");
+
             if (msg.what == 2) {
                 try {
                     JSONObject object = new JSONObject(message);
                     JSONArray array = object.getJSONArray("data");
                     SubscriptionMessages = (ArrayList<SubscriptionMessage>) JSON.parseArray(array.toString(), SubscriptionMessage.class);
                     setData();
+                    Log.i("gongpengming", message);
                 } catch (JSONException e) {
                     e.printStackTrace();
                 }
@@ -80,7 +83,7 @@ public class SubscriptionActivity extends BaseActivity {
                     adapter = new SubscriptionAdapter();
                     listView.setAdapter(adapter);
                 } else {
-                    adapter.notifyDataSetChanged();
+                    notifyAdapter();
                 }
                 listView.onRefreshComplete();
             }
@@ -88,6 +91,7 @@ public class SubscriptionActivity extends BaseActivity {
     };
     String mLoginUserId;
     private String emCode;
+    private TextView emptyView;
 
     @Override//设置右划退出
     public void setTouch(boolean b) {
@@ -106,6 +110,8 @@ public class SubscriptionActivity extends BaseActivity {
     private void initView() {
         listView = (PullToRefreshListView) findViewById(R.id.listview);
         listView.setMode(PullToRefreshBase.Mode.BOTH);
+        emptyView = (TextView) findViewById(R.id.emptyView);
+
         listView.setOnRefreshListener(new PullToRefreshBase.OnRefreshListener2<ListView>() {
             @Override
             public void onPullDownToRefresh(PullToRefreshBase<ListView> refreshView) {
@@ -226,14 +232,21 @@ public class SubscriptionActivity extends BaseActivity {
         });
     }
 
+    private void notifyAdapter() {
+        if (sortSubsrciprions == null || sortSubsrciprions.size() <= 0) {
+            emptyView.setVisibility(View.VISIBLE);
+        } else {
+            emptyView.setVisibility(View.GONE);
+        }
+        if (adapter != null)
+            adapter.notifyDataSetChanged();
+    }
+
     private void setData() {//网络获取数据时候
         if (SubscriptionMessages == null || SubscriptionMessages.size() <= 0) {
             ToastMessage("没有更多内容");
             listView.onRefreshComplete();
-            View emptyView = LayoutInflater.from(mContext).inflate(R.layout.subscription_empty, null);
-            listView.setEmptyView(emptyView);
-            if (adapter != null)
-                adapter.notifyDataSetChanged();
+            notifyAdapter();
             return;
         }
 
@@ -242,6 +255,8 @@ public class SubscriptionActivity extends BaseActivity {
         saveDataToDB(SubscriptionMessages);
         if (sortSubsrciprions == null) {
             sortSubsrciprions = new ArrayList<>();
+        } else {
+            sortSubsrciprions.clear();
         }
         if (isRef) refresh();
         else loadMore();
@@ -268,7 +283,7 @@ public class SubscriptionActivity extends BaseActivity {
                         if (!(sortSubsrciprions.get(position).beans.size() > 0)) {
                             sortSubsrciprions.remove(position);
                         }
-                        adapter.notifyDataSetChanged();
+                        notifyAdapter();
                     }
                 }).create().show();
     }
@@ -414,7 +429,6 @@ public class SubscriptionActivity extends BaseActivity {
                 } else {
                     isRe = "已读";
                     isReColor = R.color.text_color;
-
                 }
                 holder.isre_tv.setText(isRe);
                 holder.big_isre_tv.setTextColor(getResources().getColor(isReColor));
@@ -425,11 +439,19 @@ public class SubscriptionActivity extends BaseActivity {
                 @Override
                 public void onClick(View view) {
                     SubscriptionMessage bean = sortSubsrciprions.get(position).beans.get(i);
-//                    218.17.158.219:8090/ERP    http://192.168.253.233:8080
                     String url = baseUrl + "common/charts/mobileCharts.action?" + "numId=" + bean.getNUM_ID_() +
                             "&mainId=" + bean.getINSTANCE_ID_() + "&insId=" + bean.getID_() +
-                            "&title=" + bean.getSON_TITLE_();
-                    ViewUtil.WebLinks(activity, url, "订阅", true);
+                            "&title=" + bean.getTITLE_();
+                    String title = TimeUtils.ym_long_2_str(sortSubsrciprions.get(position).tiem) + "  " + bean.getTITLE_();
+                    ViewUtil.WebLinks(activity, url, title, true);
+                    Log.i("gongpengming", "bean.g" + bean.getSTATUS_());
+
+                    if (bean.getSTATUS_() == 0) {//当点击未读消息
+                        Log.i("gongpengming", "bean.getSTATUS_() == 0");
+                        SubscriptionDao.getInstance().UpdateStatus(bean.getID_() + "", true);
+                        sortSubsrciprions.get(position).beans.get(i).setSTATUS_(-1);
+                        notifyDataSetChanged();
+                    }
                 }
             });
             contextView.setOnLongClickListener(new View.OnLongClickListener() {

+ 4 - 0
WeiChat/src/main/java/com/xzjmyk/pm/activity/util/TimeUtils.java

@@ -22,6 +22,7 @@ public class TimeUtils {
     public static final SimpleDateFormat s_format = new SimpleDateFormat("yyyy-MM-dd");
     public static final SimpleDateFormat f_format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
     public static final SimpleDateFormat int_format = new SimpleDateFormat("yyyyMMdd");
+    public static final SimpleDateFormat ym_format = new SimpleDateFormat("yyyyMM");
 
 
     public static String getWeek(String date) { //yyyy-MM-dd
@@ -84,6 +85,9 @@ public class TimeUtils {
     public static int int_long_2_str(long timestamp) {
         return Integer.parseInt(int_format.format(new Date(timestamp)));
     }
+public static int ym_long_2_str(long timestamp) {
+        return Integer.parseInt(ym_format.format(new Date(timestamp)));
+    }
 
     public static long f_str_2_long(String dateString) {
         try {

+ 63 - 0
WeiChat/src/main/java/com/xzjmyk/pm/activity/volley/Result.java

@@ -6,7 +6,20 @@ import android.util.Log;
 import android.widget.Toast;
 
 import com.alibaba.fastjson.JSON;
+import com.android.volley.Response;
+import com.android.volley.VolleyError;
+import com.xzjmyk.pm.activity.AppConfig;
+import com.xzjmyk.pm.activity.MyApplication;
 import com.xzjmyk.pm.activity.R;
+import com.xzjmyk.pm.activity.bean.LoginRegisterResult;
+import com.xzjmyk.pm.activity.bean.User;
+import com.xzjmyk.pm.activity.db.dao.UserDao;
+import com.xzjmyk.pm.activity.helper.LoginHelper;
+import com.xzjmyk.pm.activity.sp.UserSp;
+import com.xzjmyk.pm.activity.util.DeviceInfoUtil;
+import com.xzjmyk.pm.activity.util.Md5Util;
+
+import java.util.HashMap;
 
 public class Result {
     /**
@@ -55,6 +68,7 @@ public class Result {
         } else if (result.resultCode == CODE_TOKEN_ERROR) {// Token过期或错误
             //TODO 发出异常登录的广播
             Log.i("gongpengming", "发出异常登录的广播2");
+            loginIM(context);
 //			LoginHelper.broadcastToken(context);
 //			LoginHelper.broadcastConflict(context);
             if (showToast)
@@ -70,6 +84,55 @@ public class Result {
         }
     }
 
+    //当发现taken过期时候重新登陆
+    public static void loginIM(final Context context) {
+        String userId = UserSp.getInstance(context).getUserId("");
+        User user = UserDao.getInstance().getUserByUserId(userId);
+        final String phoneNumber = user.getTelephone();
+        final String password = user.getPassword();
+        AppConfig mConfig = MyApplication.getInstance().getConfig();
+        // 加密之后的密码
+        final String requestTag = "login";
+        HashMap<String, String> params = new HashMap<String, String>();
+        params.put("telephone", Md5Util.toMD5(phoneNumber));// 账号登陆的时候需要MD5加密,服务器需求
+        params.put("password", password);
+        // 附加信息
+        params.put("model", DeviceInfoUtil.getModel());
+        params.put("osVersion", DeviceInfoUtil.getOsVersion());
+        params.put("serial", DeviceInfoUtil.getDeviceId(context));
+        // 地址信息
+        double latitude = MyApplication.getInstance().getBdLocationHelper().getLatitude();
+        double longitude = MyApplication.getInstance().getBdLocationHelper().getLongitude();
+        if (latitude != 0)
+            params.put("latitude", String.valueOf(latitude));
+        if (longitude != 0)
+            params.put("longitude", String.valueOf(longitude));
+        final StringJsonObjectRequest<LoginRegisterResult> request = new StringJsonObjectRequest<LoginRegisterResult>(mConfig.USER_LOGIN,
+                new Response.ErrorListener() {
+                    @Override
+                    public void onErrorResponse(VolleyError arg0) {
+                    }
+                }, new StringJsonObjectRequest.Listener<LoginRegisterResult>() {
+            @Override
+            public void onResponse(ObjectResult<LoginRegisterResult> result) {
+                if (result == null) {
+                    return;
+                }
+                boolean success = false;
+                if (result.getResultCode() == Result.CODE_SUCCESS) {
+                    success = LoginHelper.setLoginUser(context, phoneNumber, password, result);// 设置登陆用户信息
+                }
+                if (success) {// 登陆IM成功
+
+                } else {// 登录失败
+
+                }
+            }
+        }, LoginRegisterResult.class, params);
+        request.setTag(requestTag);
+        MyApplication.getInstance().getFastVolley().addDefaultRequest("Result", request);
+    }
+
     private static void showResultToast(Context context, Result result) {
         if (TextUtils.isEmpty(result.resultMsg)) {
             Toast.makeText(context, context.getString(R.string.data_exception), Toast.LENGTH_SHORT).show();

+ 214 - 409
WeiChat/src/main/res/layout/activity_add_meeting.xml

@@ -1,426 +1,231 @@
 <?xml version="1.0" encoding="utf-8"?>
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:tools="http://schemas.android.com/tools"
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:whatever="http://schemas.android.com/apk/res-auto"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
     android:background="@drawable/bg_main"
-    tools:context="com.xzjmyk.pm.activity.ui.erp.activity.AddMeetingActivity">
+    android:orientation="vertical">
 
-    <RelativeLayout
-        android:id="@+id/top"
-        android:layout_width="match_parent"
-        android:layout_height="?attr/actionBarSize"
-        android:background="@color/text_black">
-
-        <TextView
-            android:id="@+id/oa_back"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_centerVertical="true"
-            android:layout_marginLeft="10dp"
-            android:clickable="true"
-            android:drawableLeft="@drawable/back"
-            android:text="取消"
-            android:textColor="@color/white"
-            android:textSize="20sp" />
-
-        <TextView
-            android:id="@+id/oa_title_tv"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_centerInParent="true"
-            android:clickable="true"
-            android:text="新建会议"
-            android:textColor="@color/white"
-            android:textSize="20sp" />
-
-        <TextView
-            android:id="@+id/oa_rili_img"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_alignParentRight="true"
-            android:layout_centerVertical="true"
-            android:layout_marginRight="8dp"
-            android:text="保存"
-            android:textColor="@color/white"
-            android:textSize="20sp" />
-
-    </RelativeLayout>
-
-    <ScrollView
+    <com.xzjmyk.pm.activity.ui.erp.view.CustomerScrollView
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:layout_below="@id/top">
+        android:fillViewport="true">
 
         <LinearLayout
             android:layout_width="match_parent"
-            android:layout_height="match_parent"
+            android:layout_height="wrap_content"
             android:orientation="vertical">
 
-            <RelativeLayout
-                android:id="@+id/oa_meet"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="会议名称"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/next_img1"
-                    android:layout_toRightOf="@+id/oa_meet_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/next_img1"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
-
-            <RelativeLayout
-                android:id="@+id/oa_start_time"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_start_time_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="开始时间"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_start_time_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/next_img2"
-                    android:layout_toRightOf="@+id/oa_start_time_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/next_img2"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
-
-            <RelativeLayout
-                android:id="@+id/oa_end_time"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_end_time_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="结束时间"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_end_time_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img3"
-                    android:layout_toRightOf="@+id/oa_end_time_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img3"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
-
-            <RelativeLayout
-                android:id="@+id/oa_meet_addr"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_addr_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="会议地点"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_addr_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img4"
-                    android:layout_toRightOf="@+id/oa_meet_addr_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img4"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
+            <LinearLayout
+                android:id="@+id/ly_head_display"
                 android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
+                android:layout_height="wrap_content"
+                android:orientation="vertical">
+
+                <RelativeLayout
+                    android:id="@+id/ry_leave_man"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color1">
+
+
+                    <TextView
+                        android:id="@+id/tv_leave_man"
+                        style="@style/form_relative_left_text"
+                        android:text="会议名称:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_man"
+                        style="@style/form_relative_right_text"
+                        editTextFormExample:testType="nocheck" />
+                </RelativeLayout>
+
+                <!--<ImageView style="@style/app_comm_list_line_gray" />-->
+
+                <RelativeLayout
+                    android:id="@+id/ry_set_startTime"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color1">
+
+
+                    <TextView
+                        android:id="@+id/tv_set_"
+                        style="@style/form_relative_left_text"
+                        android:text="开始时间:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/tv_start_time"
+                        style="@style/form_relative_right_text"
+                        editTextFormExample:customFormat="yyyy-MM-dd HH:mm"
+                        editTextFormExample:testType="date" />
+                </RelativeLayout>
+
+
+                <RelativeLayout
+                    android:id="@+id/ry_set_endTime"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color2">
+
+                    <TextView
+                        android:id="@+id/tv_date_gh"
+                        style="@style/form_relative_left_text"
+                        android:text="结束时间:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText
+                        xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/tv_end_time"
+                        style="@style/form_relative_right_text"
+                        editTextFormExample:customFormat="yyyy-MM-dd HH:mm"
+                        editTextFormExample:testType="date" />
+                </RelativeLayout>
+
+                <RelativeLayout
+                    android:id="@+id/ry_leave_mankind"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color2">
+                    <TextView
+                        android:id="@+id/tv_leave_mankind"
+                        style="@style/form_relative_left_text"
+                        android:text="会议地点:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_mankind"
+                        style="@style/form_relative_right_text"
+                        editTextFormExample:testType="nocheck" />
+                </RelativeLayout>
+
+                <RelativeLayout
+                    android:id="@+id/ry_leave_type"
+                    style="@style/form_relative_customer"
+                    android:visibility="gone">
+
+
+                    <TextView
+                        android:id="@+id/tv_leave_type"
+                        style="@style/form_relative_left_text"
+                        android:text="请假类型:" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_type"
+                        style="@style/form_relative_right_text"
+                        android:focusableInTouchMode="false"
+                        editTextFormExample:testType="nocheck" />
+                </RelativeLayout>
+
+
+                <RelativeLayout
+                    android:id="@+id/ry_leave_category"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color1">
+                    <TextView
+                        android:id="@+id/tv_leave_category"
+                        style="@style/form_relative_left_text"
+                        android:text="假期类别:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_category"
+                        style="@style/form_relative_right_text"
+                        editTextFormExample:testType="nocheck" />
+                </RelativeLayout>
+
+                <!--<ImageView style="@style/app_comm_list_line_gray" />-->
+
+                <RelativeLayout
+                    android:id="@+id/ry_set_website"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color2">
+
+
+                    <TextView
+                        android:id="@+id/tv_iv_leave_days"
+                        style="@style/form_relative_left_text"
+                        android:text="请假天数:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_days"
+                        style="@style/form_relative_right_text"
+                        whatever:customRegexp="^(([0-9])|([0-9]+\\.?[0-9]+))$"
+                        whatever:testErrorString="@string/error_only_numeric_digits_allowed"
+                        whatever:testType="regexp" />
+                </RelativeLayout>
+
+                <!--<ImageView style="@style/app_comm_list_line_gray" />-->
+
+                <RelativeLayout
+                    android:id="@+id/ry_leave_hours"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color1">
+
+
+                    <TextView
+                        android:id="@+id/tv_leave_hours"
+                        style="@style/form_relative_left_text"
+
+                        android:text="请假时数:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_hours"
+                        style="@style/form_relative_right_text"
+
+                        whatever:customRegexp="^(([0-9])|([0-9]+\\.?[0-9]+))$"
+                        whatever:testErrorString="@string/error_only_numeric_digits_allowed"
+                        whatever:testType="regexp" />
+                </RelativeLayout>
+
+                <!--<ImageView style="@style/app_comm_list_line_gray" />-->
+
+                <RelativeLayout
+                    android:id="@+id/ry_leave_reason"
+                    style="@style/form_relative_customer"
+                    android:background="@color/item_color2">
+
+
+                    <TextView
+                        android:id="@+id/tv_leave_reason"
+                        style="@style/form_relative_left_text"
+                        android:text="请假原因:"
+                        android:textColor="@color/text_main"
+                        android:textSize="@dimen/text_main" />
+
+                    <com.andreabaccega.widget.FormEditText xmlns:editTextFormExample="http://schemas.android.com/apk/res-auto"
+                        android:id="@+id/et_leave_reason"
+                        style="@style/form_relative_right_text"
+                        editTextFormExample:testType="nocheck" />
+                </RelativeLayout>
 
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="10dp" />
-
-            <RelativeLayout
-                android:id="@+id/oa_meet_num"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_num_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:layout_marginTop="10dp"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="参会人员"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_num_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img5"
-                    android:layout_toRightOf="@+id/oa_meet_num_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img5"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
-
-            <RelativeLayout
-                android:id="@+id/oa_meet_meam"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_meam_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:layout_marginTop="10dp"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="管理员"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_meam_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img6"
-                    android:layout_toRightOf="@+id/oa_meet_meam_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img6"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
 
+            </LinearLayout>
+
+            <LinearLayout
+                android:id="@+id/ly_bottom_display"
+                style="@style/form_linear_customer">
+
+            </LinearLayout>
+
+            <LinearLayout
+                android:id="@+id/ly_bottom_save"
+                style="@style/form_linear_customer">
+
+                <Button
+                    android:id="@+id/bt_save"
+                    style="@style/from_button_base_bule"
+                    android:text="保  存" />
+            </LinearLayout>
+
+            <include layout="@layout/item_work_view" />
 
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="10dp" />
-
-            <RelativeLayout
-                android:id="@+id/oa_meet_note"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_note_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:layout_marginTop="10dp"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="会议标签"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_note_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img7"
-                    android:layout_toRightOf="@+id/oa_meet_note_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img7"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
-
-            <RelativeLayout
-                android:id="@+id/oa_meet_sub"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_sub_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:layout_marginTop="10dp"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="管理员"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_sub_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img9"
-                    android:layout_toRightOf="@+id/oa_meet_sub_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img9"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
-
-            <RelativeLayout
-                android:id="@+id/oa_meet_about"
-                style="@style/IMTbleLine_UP">
-
-                <TextView
-                    android:id="@+id/oa_meet_about_name"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_centerVertical="true"
-                    android:layout_marginTop="10dp"
-                    android:drawablePadding="10dp"
-                    android:gravity="center"
-                    android:text="管理员"
-                    android:textColor="@color/text_main"
-                    android:textSize="@dimen/text_main" />
-
-                <TextView
-                    android:id="@+id/oa_meet_about_name_tv"
-                    style="@style/IMTbleLine_TextValue"
-                    android:layout_toLeftOf="@+id/oa_next_img8"
-                    android:layout_toRightOf="@+id/oa_meet_about_name"
-                    android:textColor="@color/text_hine"
-                    android:textSize="@dimen/text_hine" />
-
-                <ImageView
-                    android:id="@+id/oa_next_img8"
-                    android:layout_width="@dimen/next_width"
-                    android:layout_height="@dimen/next_height"
-                    android:layout_alignParentRight="true"
-                    android:layout_centerVertical="true"
-                    android:alpha="0.26"
-                    android:background="@drawable/set_list_next"
-                    android:contentDescription="@string/app_name" />
-            </RelativeLayout>
-
-            <View
-                android:layout_width="match_parent"
-                android:layout_height="1px"
-                android:background="@color/item_line" />
         </LinearLayout>
-    </ScrollView>
-</RelativeLayout>
+    </com.xzjmyk.pm.activity.ui.erp.view.CustomerScrollView>
+</LinearLayout>

+ 25 - 14
WeiChat/src/main/res/layout/activity_subscription.xml

@@ -1,18 +1,29 @@
 <?xml version="1.0" encoding="utf-8"?>
-<com.handmark.pulltorefresh.library.PullToRefreshListView xmlns:android="http://schemas.android.com/apk/res/android"
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:ptr="http://schemas.android.com/apk/res-auto"
-    android:id="@+id/listview"
     android:layout_width="match_parent"
-    android:padding="10dp"
-    android:layout_height="match_parent"
-    android:layout_above="@+id/bottom_view"
-    android:scrollbars="none"
-    android:divider="#00000000" />
-<!--    ptr:ptrAnimationStyle="flip"
-    ptr:ptrDrawableEnd="@drawable/default_ptr_rotate"
-    ptr:ptrDrawableStart="@drawable/default_ptr_flip"
-    ptr:ptrHeaderTextColor="@color/black"
-    ptr:ptrOverScroll="false"
+    android:layout_height="match_parent">
 
-    ptr:ptrShowIndicator="false"-->
-    <!--ptr:ptrMode="both"-->
+    <TextView
+        android:id="@+id/emptyView"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_gravity="center_horizontal|top"
+        android:drawableBottom="@drawable/icon_not_found"
+        android:drawablePadding="5dp"
+        android:gravity="center"
+        android:padding="10dp"
+        android:text="今天暂时没有数据 \n向上拉取前一天数据"
+        android:textColor="@color/black"
+        android:textSize="@dimen/SmallerTextSize"
+        android:visibility="gone" />
+
+    <com.handmark.pulltorefresh.library.PullToRefreshListView
+        android:id="@+id/listview"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:layout_above="@+id/bottom_view"
+        android:divider="#00000000"
+        android:padding="10dp"
+        android:scrollbars="none" />
+</FrameLayout>

+ 0 - 19
WeiChat/src/main/res/layout/subscription_empty.xml

@@ -1,19 +0,0 @@
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:tools="http://schemas.android.com/tools"
-    android:layout_width="match_parent"
-    android:layout_height="match_parent"
-    android:orientation="horizontal">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_gravity="center_horizontal|top"
-        android:drawableBottom="@drawable/icon_not_found"
-        android:drawablePadding="5dp"
-        android:gravity="center"
-        android:padding="10dp"
-        android:text="今天暂时没有数据 \n向上拉取前一天数据"
-        android:textColor="@color/black"
-        android:textSize="@dimen/SmallerTextSize" />
-
-</FrameLayout>