Browse Source

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

Bitliker 9 years ago
parent
commit
2b87fa20d0

+ 24 - 13
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/activity/crm/BusinessAddActivity.java

@@ -507,27 +507,38 @@ public class BusinessAddActivity extends BaseActivity implements View.OnClickLis
      * @author:Arison on 2016/7/20
      */
     public void loadManGenJin() {
-//        progressDialog.show();
-//        String url = Constants.getAppBaseUrl(ct) + "/mobile/crm/getBusinessChanceRecorder.action";
-//        Map<String, Object> params = new HashMap<>();
-//        params.put("caller", "employee");
-//        params.put("condition", "1=1");
-//        LinkedHashMap<String, Object> headers = new LinkedHashMap<>();
-//        headers.put("Cookie", "JSESSIONID=" + CommonUtil.getSharedPreferences(ct, "sessionId"));
-//        ViewUtil.httpSendRequest(ct, url, params, mHandler, headers, LOAD_MANGENJIN, null, null, "post");
+//        HashMap param = new HashMap<>();
+//        param.put("caller", "employee");
+//        param.put("condition", "1=1");
+//        Bundle bundle = new Bundle();
+//        bundle.putSerializable("param", param);
+//        Intent intent = new Intent(ct, SelectActivity.class);
+//        intent.putExtra("type", 1);
+//        intent.putExtra("reid", R.style.OAThemeMeet);
+//        intent.putExtras(bundle);
+//        intent.putExtra("key", "recorders");
+//        intent.putExtra("showKey", "BC_DOMAN");
+//        intent.putExtra("action", "/mobile/crm/getBusinessChanceRecorder.action");
+//        intent.putExtra("title", "商机跟进入");
+//        startActivityForResult(intent, 0x23);
 
         HashMap param = new HashMap<>();
-        param.put("caller", "employee");
+        param.put("caller", "Ask4leave");
+        param.put("which", "form");
+        param.put("field", "va_emcode");
         param.put("condition", "1=1");
+        param.put("page", "1");
+        param.put("pageSize", "100");
+        param.put("sessionId", CommonUtil.getSharedPreferences(ct, "sessionId"));
         Bundle bundle = new Bundle();
         bundle.putSerializable("param", param);
         Intent intent = new Intent(ct, SelectActivity.class);
         intent.putExtra("type", 1);
         intent.putExtra("reid", R.style.OAThemeMeet);
         intent.putExtras(bundle);
-        intent.putExtra("key", "recorders");
-        intent.putExtra("showKey", "BC_DOMAN");
-        intent.putExtra("action", "/mobile/crm/getBusinessChanceRecorder.action");
+        intent.putExtra("key", "");
+        intent.putExtra("showKey", "em_name");
+        intent.putExtra("action", "common/dbfind.action");
         intent.putExtra("title", "商机跟进入");
         startActivityForResult(intent, 0x23);
     }
@@ -680,7 +691,7 @@ public class BusinessAddActivity extends BaseActivity implements View.OnClickLis
                         break;
                     case 0x23://跟进入
                      // enterManCode
-                        enterManCode=  JSON.parseObject(b.getJson()).getString("EM_CODE");
+                        enterManCode=  JSON.parseObject(b.getJson()).getString("em_code");
                         et_business_enterMan.setText(b.getName());
                         break;
                     case 0x22://当前阶段

+ 1 - 0
WeiChat/src/main/java/com/xzjmyk/pm/activity/ui/erp/activity/form/DataFormDetailActivity.java

@@ -1279,6 +1279,7 @@ public class DataFormDetailActivity extends BaseActivity implements View.OnClick
             }
             double result= (double) (DateFormatUtil.getDifferenceNum(startDate, endDate, 1))/60;
             LogUtil.d("当天加班时数:" + result);
+            if (wod_count==0)return;
             mAdapter.getmListData().get(groupId).getDatas().get(wod_count - 1).setValue(new DecimalFormat("0.0").format(result));
             mAdapter.notifyDataSetChanged();
         }

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

@@ -259,7 +259,11 @@ public class SelectActivity extends BaseActivity {
             System.out.println("value" + i + ":" + datas.getJSONObject(i).getString(fieldkey));
             bean = new SelectBean();
             bean.setId(id);
-            bean.setName(datas.getJSONObject(i).getString(fieldkey));
+            if (StringUtils.isEmpty(datas.getJSONObject(i).getString(fieldkey))){
+                bean.setName(datas.getJSONObject(i).getString(showKey));
+            }else{
+                bean.setName(datas.getJSONObject(i).getString(fieldkey));
+            }
             bean.setObject(JSON.toJSONString(datas.get(i)));
             bean.setJson(JSON.toJSONString(datas.get(i)));
             formBeaan.add(bean);