deason 1 vuosi sitten
vanhempi
commit
031196c404

+ 4 - 3
examcloud-core-basic-api-provider/src/main/java/cn/com/qmth/examcloud/core/basic/api/controller/OrgController.java

@@ -463,13 +463,14 @@ public class OrgController extends ControllerSupport {
         List<OrgEntity> list = orgRepo.findByParentId(rootOrgId);
         List<Object[]> lines = new ArrayList<>();
         for (OrgEntity info : list) {
-            lines.add(new Object[]{info.getName(), info.getCode(), info.getContacts(), info.getTelephone()});
+            lines.add(new Object[]{info.getName(), info.getCode(), info.getContacts(), info.getTelephone(),
+                    info.getEnable() ? "是" : "否"});
         }
 
         String filePath = systemConfig.getTempDataDir() + File.separator + System.currentTimeMillis() + ".xlsx";
         File file = new File(filePath);
-        ExcelWriter.write(new String[]{"机构名称", "机构代码", "联系人", "联系电话"},
-                new Class[]{String.class, String.class, String.class, String.class}, lines, new File(filePath));
+        ExcelWriter.write(new String[]{"机构名称", "机构代码", "联系人", "联系电话", "是否启用"},
+                new Class[]{String.class, String.class, String.class, String.class, String.class}, lines, new File(filePath));
         exportFile("学习中心列表.xlsx", file);
         FileUtils.deleteQuietly(file);
     }