Commit 36c4d707 authored by hongguangwu's avatar hongguangwu

MVP1.6.3-HCM HCM的出差接口-历史单子出行工具、人员,置为空,人数为1

parent 5cef4e44
...@@ -301,18 +301,20 @@ public class QiWeiServiceImpl extends ServiceImpl<EkpQiweiChuchaiMapper, EkpQiwi ...@@ -301,18 +301,20 @@ public class QiWeiServiceImpl extends ServiceImpl<EkpQiweiChuchaiMapper, EkpQiwi
formData = JSON.parseObject(datas.getString("formData")); formData = JSON.parseObject(datas.getString("formData"));
try { try {
toolList = JSON.parseArray(formData.getString("随行人员"), JSONObject.class); try {
int i = 0; toolList = JSON.parseArray(formData.getString("随行人员"), JSONObject.class);
if (toolList != null && !toolList.isEmpty()) { int i = 0;
for (JSONObject tool : toolList) { if (toolList != null && !toolList.isEmpty()) {
if (i++ == 0) { for (JSONObject tool : toolList) {
person = tool.getString("name"); if (i++ == 0) {
} else { person = tool.getString("name");
person += "," + tool.getString("name"); } else {
person += "," + tool.getString("name");
}
renShu++;
} }
renShu++;
} }
} else { } catch (Exception e) {
person = formData.getString("随行人员"); person = formData.getString("随行人员");
renShu = 1; renShu = 1;
if (Common.isNotNull(person)) { if (Common.isNotNull(person)) {
...@@ -327,7 +329,7 @@ public class QiWeiServiceImpl extends ServiceImpl<EkpQiweiChuchaiMapper, EkpQiwi ...@@ -327,7 +329,7 @@ public class QiWeiServiceImpl extends ServiceImpl<EkpQiweiChuchaiMapper, EkpQiwi
} }
toolList = JSON.parseArray(formData.getString("出行工具"), JSONObject.class); toolList = JSON.parseArray(formData.getString("出行工具"), JSONObject.class);
i = 0; int i = 0;
if (toolList != null && !toolList.isEmpty()) { if (toolList != null && !toolList.isEmpty()) {
for (JSONObject tool : toolList) { for (JSONObject tool : toolList) {
if (i++ == 0) { if (i++ == 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment