|
|
|
@ -154,29 +154,34 @@ public class KjController {
|
|
|
|
|
errBuff.append("当前项目中物料提前请购单BOM视图版本未发布,不允许创建框架BOM.\n");flag = false;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
OkHttpClient client = new OkHttpClient();
|
|
|
|
|
String preference = ChintPreferenceUtil.getPreference("CHINT_PIUrl", session);
|
|
|
|
|
Request request = new Request.Builder()
|
|
|
|
|
.url(preference + "/api/open/task/getTaskInfo/" + projectId)
|
|
|
|
|
.build();
|
|
|
|
|
Response response = client.newCall(request).execute();
|
|
|
|
|
String string = response.body().string();
|
|
|
|
|
System.out.println(string);
|
|
|
|
|
JSONObject parseObject = JSON.parseObject(string);
|
|
|
|
|
JSONArray datas = parseObject.getJSONArray("data");
|
|
|
|
|
idName.clear();
|
|
|
|
|
if(datas!=null) {
|
|
|
|
|
for(int t=0;t<datas.size();t++) {
|
|
|
|
|
JSONObject jsonObject = datas.getJSONObject(t);
|
|
|
|
|
String string2 = jsonObject.getString("userid");
|
|
|
|
|
if(string2!=null && !string2.equals("")) {
|
|
|
|
|
idName.put(jsonObject.getString("taskname"),string2);
|
|
|
|
|
try {
|
|
|
|
|
OkHttpClient client = new OkHttpClient();
|
|
|
|
|
String preference = ChintPreferenceUtil.getPreference("CHINT_PIUrl", session);
|
|
|
|
|
Request request = new Request.Builder()
|
|
|
|
|
.url(preference + "/api/open/task/getTaskInfo/" + projectId)
|
|
|
|
|
.build();
|
|
|
|
|
Response response = client.newCall(request).execute();
|
|
|
|
|
String string = response.body().string();
|
|
|
|
|
System.out.println(string);
|
|
|
|
|
JSONObject parseObject = JSON.parseObject(string);
|
|
|
|
|
JSONArray datas = parseObject.getJSONArray("data");
|
|
|
|
|
if(datas != null) {
|
|
|
|
|
for(int t = 0;t < datas.size(); t++) {
|
|
|
|
|
JSONObject jsonObject = datas.getJSONObject(t);
|
|
|
|
|
String string2 = jsonObject.getString("userid");
|
|
|
|
|
if(string2!=null && !string2.equals("")) {
|
|
|
|
|
idName.put(jsonObject.getString("taskname"),string2);
|
|
|
|
|
}
|
|
|
|
|
System.out.println(jsonObject.getString("taskname")+"====="+string2);
|
|
|
|
|
}
|
|
|
|
|
System.out.println(jsonObject.getString("taskname")+"====="+string2);
|
|
|
|
|
}
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
// Auto-generated catch block
|
|
|
|
|
e.printStackTrace();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
System.out.println(idName.toString());
|
|
|
|
|
System.out.println("idName==>" + idName.toString());
|
|
|
|
|
List<CBean> beanList = kjBean.cbeans;
|
|
|
|
|
// ZT2_Requisition
|
|
|
|
|
for(CBean bean : beanList) {
|
|
|
|
@ -196,7 +201,7 @@ public class KjController {
|
|
|
|
|
fMap.put(bean.cId, fodlers.get(folderName));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
System.out.println(nameUser.toString());
|
|
|
|
|
System.out.println("nameUser==>" + nameUser.toString());
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
// Auto-generated catch block
|
|
|
|
|
e.printStackTrace();
|
|
|
|
|