Commit ef7e1afd8426de2ff39ab7255ccbaeb2f92e23ee

Authored by 徐烜
1 parent 4fa4687e

update

src/main/java/com/bsth/controller/BaseController.java
1 1 package com.bsth.controller;
2 2  
3   -import java.io.Serializable;
4   -import java.util.Map;
5   -
  3 +import com.bsth.common.ResponseCode;
  4 +import com.bsth.service.BaseService;
  5 +import com.bsth.service.schedule.utils.DataImportExportService;
6 6 import org.springframework.beans.factory.annotation.Autowired;
7 7 import org.springframework.data.domain.Page;
8 8 import org.springframework.data.domain.PageRequest;
... ... @@ -12,8 +12,12 @@ import org.springframework.web.bind.annotation.PathVariable;
12 12 import org.springframework.web.bind.annotation.RequestMapping;
13 13 import org.springframework.web.bind.annotation.RequestMethod;
14 14 import org.springframework.web.bind.annotation.RequestParam;
  15 +import org.springframework.web.multipart.MultipartFile;
15 16  
16   -import com.bsth.service.BaseService;
  17 +import java.io.File;
  18 +import java.io.Serializable;
  19 +import java.util.HashMap;
  20 +import java.util.Map;
17 21  
18 22 /**
19 23 *
... ... @@ -29,6 +33,8 @@ public class BaseController<T, ID extends Serializable> {
29 33  
30 34 @Autowired
31 35 BaseService<T, ID> baseService;
  36 + @Autowired
  37 + DataImportExportService dataImportExportService;
32 38  
33 39 /**
34 40 *
... ... @@ -105,5 +111,41 @@ public class BaseController&lt;T, ID extends Serializable&gt; {
105 111 public Map<String, Object> delete(@PathVariable("id") ID id){
106 112 return baseService.delete(id);
107 113 }
  114 +
  115 + /**
  116 + * 上传数据文件,并使用ktr转换文件导入数据。
  117 + * @param file
  118 + * @return
  119 + * @throws Exception
  120 + */
  121 + @RequestMapping(value = "/dataImport", method = RequestMethod.POST)
  122 + public Map<String, Object> uploadDataAndImport(MultipartFile file) throws Exception {
  123 + Map<String, Object> resultMap = new HashMap<>();
  124 +
  125 + try {
  126 + // 获取ktr转换文件绝对路径
  127 + File ktrfile = new File(this.getClass().getResource(getDataImportKtrClasspath()).toURI());
  128 + System.out.println(ktrfile.getAbsolutePath());
  129 + // 导入数据
  130 + dataImportExportService.fileDataImport(file, ktrfile);
  131 +
  132 + resultMap.put("status", ResponseCode.SUCCESS);
  133 + resultMap.put("msg", "导入成功");
  134 + } catch (Exception exp) {
  135 + exp.printStackTrace();
  136 + resultMap.put("status", ResponseCode.ERROR);
  137 + resultMap.put("msg", exp.getLocalizedMessage());
  138 + }
  139 +
  140 + return resultMap;
  141 + }
  142 +
  143 + /**
  144 + * @return 数据导入的ktr转换文件类路径。
  145 + */
  146 + protected String getDataImportKtrClasspath() {
  147 + // 默认返回异常,子类如果要使用导入功能,必须覆写此方法,指定ktr文件类路径
  148 + throw new RuntimeException("必须override,并指定ktr classpath");
  149 + }
108 150  
109 151 }
... ...
src/main/java/com/bsth/controller/CarsController.java
1 1 package com.bsth.controller;
2 2  
3   -import com.bsth.common.ResponseCode;
4 3 import com.bsth.entity.Cars;
5 4 import com.bsth.service.schedule.utils.DataImportExportService;
6 5 import com.bsth.service.schedule.utils.DataToolsProperties;
7 6 import org.springframework.beans.factory.annotation.Autowired;
8 7 import org.springframework.boot.context.properties.EnableConfigurationProperties;
9 8 import org.springframework.web.bind.annotation.*;
10   -import org.springframework.web.multipart.MultipartFile;
11 9  
12   -import java.io.File;
13   -import java.util.HashMap;
14 10 import java.util.Map;
15 11  
16 12 /**
... ... @@ -51,28 +47,8 @@ public class CarsController extends BaseController&lt;Cars, Integer&gt; {
51 47 return baseService.validateEquale(map);
52 48 }
53 49  
54   - // 上传图片
55   - @RequestMapping(value = "/dataImport", method = RequestMethod.POST)
56   - public Map<String, Object> uploadPic(MultipartFile file) throws Exception {
57   - Map<String, Object> resultMap = new HashMap<>();
58   -
59   - try {
60   - // 获取ktr转换文件绝对路径
61   - File ktrfile = new File(this.getClass().getResource(
62   - dataToolsProperties.getCarsDatainputktr()).toURI());
63   - System.out.println(ktrfile.getAbsolutePath());
64   - // 导入数据
65   - dataImportExportService.fileDataImport(file, ktrfile);
66   -
67   - resultMap.put("status", ResponseCode.SUCCESS);
68   - resultMap.put("msg", "导入成功");
69   - } catch (Exception exp) {
70   - exp.printStackTrace();
71   - resultMap.put("status", ResponseCode.ERROR);
72   - resultMap.put("msg", exp.getLocalizedMessage());
73   - }
74   -
75   - return resultMap;
  50 + @Override
  51 + protected String getDataImportKtrClasspath() {
  52 + return dataToolsProperties.getCarsDatainputktr();
76 53 }
77   -
78 54 }
... ...
src/main/java/com/bsth/controller/PersonnelController.java
1 1 package com.bsth.controller;
2 2  
3 3 import com.bsth.entity.Personnel;
  4 +import com.bsth.service.schedule.utils.DataImportExportService;
  5 +import com.bsth.service.schedule.utils.DataToolsProperties;
  6 +import org.springframework.beans.factory.annotation.Autowired;
  7 +import org.springframework.boot.context.properties.EnableConfigurationProperties;
4 8 import org.springframework.web.bind.annotation.*;
5 9  
6 10 import java.util.Map;
... ... @@ -10,7 +14,14 @@ import java.util.Map;
10 14 */
11 15 @RestController
12 16 @RequestMapping("personnel")
  17 +@EnableConfigurationProperties(DataToolsProperties.class)
13 18 public class PersonnelController extends BaseController<Personnel, Integer> {
  19 +
  20 + @Autowired
  21 + private DataImportExportService dataImportExportService;
  22 + @Autowired
  23 + private DataToolsProperties dataToolsProperties;
  24 +
14 25 /**
15 26 * 覆写方法,因为form提交的方式参数不全,改用 json形式提交 @RequestBody
16 27 * @Title: save
... ... @@ -35,4 +46,9 @@ public class PersonnelController extends BaseController&lt;Personnel, Integer&gt; {
35 46 // 一般比较相同公司下工号是否相同
36 47 return baseService.validateEquale(map);
37 48 }
  49 +
  50 + @Override
  51 + protected String getDataImportKtrClasspath() {
  52 + return dataToolsProperties.getEmployeesDatainputktr();
  53 + }
38 54 }
... ...
src/main/java/com/bsth/service/schedule/utils/DataToolsProperties.java
... ... @@ -28,6 +28,11 @@ public class DataToolsProperties {
28 28 /** 车辆信息导入ktr转换 */
29 29 @NotNull
30 30 private String carsDatainputktr;
  31 + /** 人员信息导入ktr转换 */
  32 + @NotNull
  33 + private String employeesDatainputktr;
  34 +
  35 + // TODO:
31 36  
32 37 public String getFileuploadDir() {
33 38 return fileuploadDir;
... ... @@ -60,4 +65,12 @@ public class DataToolsProperties {
60 65 public void setCarsDatainputktr(String carsDatainputktr) {
61 66 this.carsDatainputktr = carsDatainputktr;
62 67 }
  68 +
  69 + public String getEmployeesDatainputktr() {
  70 + return employeesDatainputktr;
  71 + }
  72 +
  73 + public void setEmployeesDatainputktr(String employeesDatainputktr) {
  74 + this.employeesDatainputktr = employeesDatainputktr;
  75 + }
63 76 }
... ...
src/main/resources/datatools/config.properties
... ... @@ -11,7 +11,7 @@ datatools.temp_datainputktr=/datatools/ktrs/test.ktr
11 11 # 车辆信息导入ktr转换
12 12 datatools.cars_datainputktr=/datatools/ktrs/carsDataInput.ktr
13 13 # 人员信息导入
14   -
  14 +datatools.employees_datainputktr=/datatools/ktrs/employeesDataInput.ktr
15 15 # 时刻表基础信息导入
16 16  
17 17 # 时刻明细信息导入
... ...
src/main/resources/datatools/ktrs/carsDataInput.ktr
... ... @@ -12,7 +12,7 @@
12 12 <parameter>
13 13 <name>erroroutputdir</name>
14 14 <default_value/>
15   - <description>ktr&#x914d;&#x7f6e;&#x7684;&#x9519;&#x8bef;&#x8f93;&#x51fa;&#x76ee;&#x5f55;</description>
  15 + <description>ktr step&#x914d;&#x7f6e;&#x7684;&#x9519;&#x8bef;&#x8f93;&#x51fa;&#x76ee;&#x5f55;</description>
16 16 </parameter>
17 17 <parameter>
18 18 <name>filepath</name>
... ... @@ -80,7 +80,7 @@
80 80 <created_date>2016&#x2f;06&#x2f;23 17&#x3a;44&#x3a;46.781</created_date>
81 81 <modified_user>-</modified_user>
82 82 <modified_date>2016&#x2f;06&#x2f;23 17&#x3a;44&#x3a;46.781</modified_date>
83   - <key_for_session_key/>
  83 + <key_for_session_key>H4sIAAAAAAAAAAMAAAAAAAAAAAA&#x3d;</key_for_session_key>
84 84 <is_key_private>N</is_key_private>
85 85 </info>
86 86 <notepads>
... ... @@ -1323,6 +1323,51 @@
1323 1323 </step>
1324 1324  
1325 1325 <step>
  1326 + <name>&#x83b7;&#x53d6;&#x53d8;&#x91cf;</name>
  1327 + <type>GetVariable</type>
  1328 + <description/>
  1329 + <distribute>Y</distribute>
  1330 + <custom_distribution/>
  1331 + <copies>1</copies>
  1332 + <partitioning>
  1333 + <method>none</method>
  1334 + <schema_name/>
  1335 + </partitioning>
  1336 + <fields>
  1337 + <field>
  1338 + <name>filepath_</name>
  1339 + <variable>&#x24;&#x7b;filepath&#x7d;</variable>
  1340 + <type>String</type>
  1341 + <format/>
  1342 + <currency/>
  1343 + <decimal/>
  1344 + <group/>
  1345 + <length>-1</length>
  1346 + <precision>-1</precision>
  1347 + <trim_type>none</trim_type>
  1348 + </field>
  1349 + <field>
  1350 + <name>erroroutputdir_</name>
  1351 + <variable>&#x24;&#x7b;erroroutputdir&#x7d;</variable>
  1352 + <type>String</type>
  1353 + <format/>
  1354 + <currency/>
  1355 + <decimal/>
  1356 + <group/>
  1357 + <length>-1</length>
  1358 + <precision>-1</precision>
  1359 + <trim_type>none</trim_type>
  1360 + </field>
  1361 + </fields>
  1362 + <cluster_schema/>
  1363 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  1364 + <xloc>134</xloc>
  1365 + <yloc>183</yloc>
  1366 + <draw>Y</draw>
  1367 + </GUI>
  1368 + </step>
  1369 +
  1370 + <step>
1326 1371 <name>&#x9519;&#x8bef;&#x8f93;&#x51fa;</name>
1327 1372 <type>ExcelOutput</type>
1328 1373 <description/>
... ... @@ -1579,51 +1624,6 @@
1579 1624 </GUI>
1580 1625 </step>
1581 1626  
1582   - <step>
1583   - <name>&#x83b7;&#x53d6;&#x53d8;&#x91cf;</name>
1584   - <type>GetVariable</type>
1585   - <description/>
1586   - <distribute>Y</distribute>
1587   - <custom_distribution/>
1588   - <copies>1</copies>
1589   - <partitioning>
1590   - <method>none</method>
1591   - <schema_name/>
1592   - </partitioning>
1593   - <fields>
1594   - <field>
1595   - <name>filepath_</name>
1596   - <variable>&#x24;&#x7b;filepath&#x7d;</variable>
1597   - <type>String</type>
1598   - <format/>
1599   - <currency/>
1600   - <decimal/>
1601   - <group/>
1602   - <length>-1</length>
1603   - <precision>-1</precision>
1604   - <trim_type>none</trim_type>
1605   - </field>
1606   - <field>
1607   - <name>erroroutputdir_</name>
1608   - <variable>&#x24;&#x7b;erroroutputdir&#x7d;</variable>
1609   - <type>String</type>
1610   - <format/>
1611   - <currency/>
1612   - <decimal/>
1613   - <group/>
1614   - <length>-1</length>
1615   - <precision>-1</precision>
1616   - <trim_type>none</trim_type>
1617   - </field>
1618   - </fields>
1619   - <cluster_schema/>
1620   - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
1621   - <xloc>134</xloc>
1622   - <yloc>183</yloc>
1623   - <draw>Y</draw>
1624   - </GUI>
1625   - </step>
1626   -
1627 1627 <step_error_handling>
1628 1628 <error>
1629 1629 <source_step>&#x63d2;&#x5165;&#x2f;&#x66f4;&#x65b0;bsth_c_cars</source_step>
... ...
src/main/resources/datatools/ktrs/employeesDataInput.ktr 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<transformation>
  3 + <info>
  4 + <name>employeesDataInput</name>
  5 + <description>&#x4eba;&#x5458;&#x57fa;&#x7840;&#x4fe1;&#x606f;&#x5bfc;&#x5165;</description>
  6 + <extended_description>&#x4eba;&#x5458;&#x57fa;&#x7840;&#x4fe1;&#x606f;</extended_description>
  7 + <trans_version/>
  8 + <trans_type>Normal</trans_type>
  9 + <trans_status>0</trans_status>
  10 + <directory>&#x2f;</directory>
  11 + <parameters>
  12 + <parameter>
  13 + <name>erroroutputdir</name>
  14 + <default_value/>
  15 + <description>ktr step&#x914d;&#x7f6e;&#x7684;&#x9519;&#x8bef;&#x8f93;&#x51fa;&#x76ee;&#x5f55;</description>
  16 + </parameter>
  17 + <parameter>
  18 + <name>filepath</name>
  19 + <default_value/>
  20 + <description>&#x5f85;&#x5904;&#x7406;&#x5bfc;&#x5165;&#x7684;excel&#x6587;&#x4ef6;</description>
  21 + </parameter>
  22 + </parameters>
  23 + <log>
  24 +<trans-log-table><connection/>
  25 +<schema/>
  26 +<table/>
  27 +<size_limit_lines/>
  28 +<interval/>
  29 +<timeout_days/>
  30 +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STATUS</id><enabled>Y</enabled><name>STATUS</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name><subject/></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name><subject/></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name><subject/></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name><subject/></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name><subject/></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name><subject/></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>STARTDATE</id><enabled>Y</enabled><name>STARTDATE</name></field><field><id>ENDDATE</id><enabled>Y</enabled><name>ENDDATE</name></field><field><id>LOGDATE</id><enabled>Y</enabled><name>LOGDATE</name></field><field><id>DEPDATE</id><enabled>Y</enabled><name>DEPDATE</name></field><field><id>REPLAYDATE</id><enabled>Y</enabled><name>REPLAYDATE</name></field><field><id>LOG_FIELD</id><enabled>Y</enabled><name>LOG_FIELD</name></field><field><id>EXECUTING_SERVER</id><enabled>N</enabled><name>EXECUTING_SERVER</name></field><field><id>EXECUTING_USER</id><enabled>N</enabled><name>EXECUTING_USER</name></field><field><id>CLIENT</id><enabled>N</enabled><name>CLIENT</name></field></trans-log-table>
  31 +<perf-log-table><connection/>
  32 +<schema/>
  33 +<table/>
  34 +<interval/>
  35 +<timeout_days/>
  36 +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>SEQ_NR</id><enabled>Y</enabled><name>SEQ_NR</name></field><field><id>LOGDATE</id><enabled>Y</enabled><name>LOGDATE</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STEPNAME</id><enabled>Y</enabled><name>STEPNAME</name></field><field><id>STEP_COPY</id><enabled>Y</enabled><name>STEP_COPY</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>INPUT_BUFFER_ROWS</id><enabled>Y</enabled><name>INPUT_BUFFER_ROWS</name></field><field><id>OUTPUT_BUFFER_ROWS</id><enabled>Y</enabled><name>OUTPUT_BUFFER_ROWS</name></field></perf-log-table>
  37 +<channel-log-table><connection/>
  38 +<schema/>
  39 +<table/>
  40 +<timeout_days/>
  41 +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>LOGGING_OBJECT_TYPE</id><enabled>Y</enabled><name>LOGGING_OBJECT_TYPE</name></field><field><id>OBJECT_NAME</id><enabled>Y</enabled><name>OBJECT_NAME</name></field><field><id>OBJECT_COPY</id><enabled>Y</enabled><name>OBJECT_COPY</name></field><field><id>REPOSITORY_DIRECTORY</id><enabled>Y</enabled><name>REPOSITORY_DIRECTORY</name></field><field><id>FILENAME</id><enabled>Y</enabled><name>FILENAME</name></field><field><id>OBJECT_ID</id><enabled>Y</enabled><name>OBJECT_ID</name></field><field><id>OBJECT_REVISION</id><enabled>Y</enabled><name>OBJECT_REVISION</name></field><field><id>PARENT_CHANNEL_ID</id><enabled>Y</enabled><name>PARENT_CHANNEL_ID</name></field><field><id>ROOT_CHANNEL_ID</id><enabled>Y</enabled><name>ROOT_CHANNEL_ID</name></field></channel-log-table>
  42 +<step-log-table><connection/>
  43 +<schema/>
  44 +<table/>
  45 +<timeout_days/>
  46 +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STEPNAME</id><enabled>Y</enabled><name>STEPNAME</name></field><field><id>STEP_COPY</id><enabled>Y</enabled><name>STEP_COPY</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>LOG_FIELD</id><enabled>N</enabled><name>LOG_FIELD</name></field></step-log-table>
  47 +<metrics-log-table><connection/>
  48 +<schema/>
  49 +<table/>
  50 +<timeout_days/>
  51 +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>METRICS_DATE</id><enabled>Y</enabled><name>METRICS_DATE</name></field><field><id>METRICS_CODE</id><enabled>Y</enabled><name>METRICS_CODE</name></field><field><id>METRICS_DESCRIPTION</id><enabled>Y</enabled><name>METRICS_DESCRIPTION</name></field><field><id>METRICS_SUBJECT</id><enabled>Y</enabled><name>METRICS_SUBJECT</name></field><field><id>METRICS_TYPE</id><enabled>Y</enabled><name>METRICS_TYPE</name></field><field><id>METRICS_VALUE</id><enabled>Y</enabled><name>METRICS_VALUE</name></field></metrics-log-table>
  52 + </log>
  53 + <maxdate>
  54 + <connection/>
  55 + <table/>
  56 + <field/>
  57 + <offset>0.0</offset>
  58 + <maxdiff>0.0</maxdiff>
  59 + </maxdate>
  60 + <size_rowset>10000</size_rowset>
  61 + <sleep_time_empty>50</sleep_time_empty>
  62 + <sleep_time_full>50</sleep_time_full>
  63 + <unique_connections>N</unique_connections>
  64 + <feedback_shown>Y</feedback_shown>
  65 + <feedback_size>50000</feedback_size>
  66 + <using_thread_priorities>Y</using_thread_priorities>
  67 + <shared_objects_file/>
  68 + <capture_step_performance>N</capture_step_performance>
  69 + <step_performance_capturing_delay>1000</step_performance_capturing_delay>
  70 + <step_performance_capturing_size_limit>100</step_performance_capturing_size_limit>
  71 + <dependencies>
  72 + </dependencies>
  73 + <partitionschemas>
  74 + </partitionschemas>
  75 + <slaveservers>
  76 + </slaveservers>
  77 + <clusterschemas>
  78 + </clusterschemas>
  79 + <created_user>-</created_user>
  80 + <created_date>2016&#x2f;06&#x2f;29 10&#x3a;18&#x3a;56.974</created_date>
  81 + <modified_user>-</modified_user>
  82 + <modified_date>2016&#x2f;06&#x2f;29 10&#x3a;18&#x3a;56.974</modified_date>
  83 + <key_for_session_key/>
  84 + <is_key_private>N</is_key_private>
  85 + </info>
  86 + <notepads>
  87 + <notepad>
  88 + <note>&#x539f;&#x7cfb;&#x7edf;&#x5bfc;&#x51fa;&#x7684;&#x8868;&#xff0c;&#x6709;&#x4e9b;&#x5b57;&#x6bb5;&#x662f;&#x6ca1;&#x6709;&#x7684;&#xff0c;&#xa;&#x4eba;&#x5458;&#x7f16;&#x7801; &#x6682;&#x65f6;&#x6ca1;&#x6709;&#x7a7a;&#x7740;&#xa;&#x7167;&#x7247;&#x5730;&#x5740; &#x6682;&#x65f6;&#x6ca1;&#x6709;&#x7a7a;&#x7740;&#xa;&#x7ebf;&#x8def;&#x7f16;&#x53f7; &#x6682;&#x65f6;&#x6ca1;&#x6709;&#x7a7a;&#x7740;&#xa;&#x8054;&#x7cfb;&#x7535;&#x8bdd; &#x6682;&#x65f6;&#x6ca1;&#x6709;&#x7a7a;&#x7740;&#xa;&#xa;&#x5b57;&#x5178;&#xa;&#x6027;&#x522b;sexType &#x7537;&#x6027; 1&#xa;&#x6027;&#x522b;sexType &#x5973;&#x6027; 2&#xa;&#xa;&#x5de5;&#x79cd;gzType &#x516c;&#x5171;&#x6c7d;&#x7535;&#x8f66;&#x9a7e;&#x9a76;&#x5458; 1&#xa;&#x5de5;&#x79cd;gzType &#x516c;&#x5171;&#x6c7d;&#x7535;&#x8f66;&#x8c03;&#x5ea6;&#x5458; 2&#xa;&#x5de5;&#x79cd;gzType &#x516c;&#x5171;&#x6c7d;&#x7535;&#x8f66;&#x552e;&#x7968;&#x5458; 3&#xa;&#x5de5;&#x79cd;gzType &#x7ad9;&#x5458; 4&#xa;&#x5de5;&#x79cd;gzType &#x7ba1;&#x7406;&#x5458; 5&#xa;&#x5de5;&#x79cd;gzType &#x5b89;&#x68c0;&#x5458; 6&#xa;&#x5de5;&#x79cd;gzType &#x673a;&#x52a1; 7&#xa;&#x5de5;&#x79cd;gzType &#x5f15;&#x5bfc;&#x5458; 8&#xa;&#x5de5;&#x79cd;gzType &#x4e58;&#x52a1;&#x5458; 9&#xa;&#x5de5;&#x79cd;gzType &#x8f66;&#x961f;&#x957f;&#xff08;&#x7ebf;&#x957f;&#x3001;&#x4e3b; 10&#xa;&#x5de5;&#x79cd;gzType &#x516c;&#x53f8;&#x7ba1;&#x7406;&#x4eba;&#x5458; 11&#xa;&#x5de5;&#x79cd;gzType &#x8b66;&#x6d88;&#x4eba;&#x5458; 12&#xa;&#x5de5;&#x79cd;gzType &#x7968;&#x52a1;&#x4eba;&#x5458; 13&#xa;&#x5de5;&#x79cd;gzType &#x5176;&#x4ed6;&#x670d;&#x52a1;&#x4eba;&#x5458; 14</note>
  89 + <xloc>288</xloc>
  90 + <yloc>139</yloc>
  91 + <width>214</width>
  92 + <heigth>394</heigth>
  93 + <fontname>YaHei Consolas Hybrid</fontname>
  94 + <fontsize>12</fontsize>
  95 + <fontbold>N</fontbold>
  96 + <fontitalic>N</fontitalic>
  97 + <fontcolorred>0</fontcolorred>
  98 + <fontcolorgreen>0</fontcolorgreen>
  99 + <fontcolorblue>0</fontcolorblue>
  100 + <backgroundcolorred>255</backgroundcolorred>
  101 + <backgroundcolorgreen>205</backgroundcolorgreen>
  102 + <backgroundcolorblue>112</backgroundcolorblue>
  103 + <bordercolorred>100</bordercolorred>
  104 + <bordercolorgreen>100</bordercolorgreen>
  105 + <bordercolorblue>100</bordercolorblue>
  106 + <drawshadow>Y</drawshadow>
  107 + </notepad>
  108 + </notepads>
  109 + <connection>
  110 + <name>bus_control_&#x516c;&#x53f8;_201</name>
  111 + <server>192.168.168.201</server>
  112 + <type>MYSQL</type>
  113 + <access>Native</access>
  114 + <database>control</database>
  115 + <port>3306</port>
  116 + <username>root</username>
  117 + <password>Encrypted 2be98afc86aa7f2e4cb79ff228dc6fa8c</password>
  118 + <servername/>
  119 + <data_tablespace/>
  120 + <index_tablespace/>
  121 + <attributes>
  122 + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute>
  123 + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute>
  124 + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute>
  125 + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute>
  126 + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute>
  127 + <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute>
  128 + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute>
  129 + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute>
  130 + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute>
  131 + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute>
  132 + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute>
  133 + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute>
  134 + </attributes>
  135 + </connection>
  136 + <connection>
  137 + <name>xlab_mysql_youle</name>
  138 + <server>101.231.124.8</server>
  139 + <type>MYSQL</type>
  140 + <access>Native</access>
  141 + <database>xlab_youle</database>
  142 + <port>45687</port>
  143 + <username>xlab-youle</username>
  144 + <password>Encrypted 2be98afc86aa78a88aa1be369d187a3df</password>
  145 + <servername/>
  146 + <data_tablespace/>
  147 + <index_tablespace/>
  148 + <attributes>
  149 + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute>
  150 + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute>
  151 + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute>
  152 + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute>
  153 + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute>
  154 + <attribute><code>PORT_NUMBER</code><attribute>45687</attribute></attribute>
  155 + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute>
  156 + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute>
  157 + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute>
  158 + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>N</attribute></attribute>
  159 + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>N</attribute></attribute>
  160 + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute>
  161 + </attributes>
  162 + </connection>
  163 + <connection>
  164 + <name>xlab_mysql_youle&#xff08;&#x672c;&#x673a;&#xff09;</name>
  165 + <server>localhost</server>
  166 + <type>MYSQL</type>
  167 + <access>Native</access>
  168 + <database>xlab_youle</database>
  169 + <port>3306</port>
  170 + <username>root</username>
  171 + <password>Encrypted </password>
  172 + <servername/>
  173 + <data_tablespace/>
  174 + <index_tablespace/>
  175 + <attributes>
  176 + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute>
  177 + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute>
  178 + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute>
  179 + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute>
  180 + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute>
  181 + <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute>
  182 + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute>
  183 + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute>
  184 + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute>
  185 + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>N</attribute></attribute>
  186 + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>N</attribute></attribute>
  187 + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute>
  188 + </attributes>
  189 + </connection>
  190 + <connection>
  191 + <name>xlab_youle</name>
  192 + <server/>
  193 + <type>MYSQL</type>
  194 + <access>JNDI</access>
  195 + <database>xlab_youle</database>
  196 + <port>1521</port>
  197 + <username/>
  198 + <password>Encrypted </password>
  199 + <servername/>
  200 + <data_tablespace/>
  201 + <index_tablespace/>
  202 + <attributes>
  203 + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute>
  204 + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute>
  205 + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute>
  206 + <attribute><code>PORT_NUMBER</code><attribute>1521</attribute></attribute>
  207 + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute>
  208 + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute>
  209 + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute>
  210 + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute>
  211 + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute>
  212 + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute>
  213 + </attributes>
  214 + </connection>
  215 + <order>
  216 + <hop> <from>&#x516c;&#x4ea4;&#x4f01;&#x4e1a;&#x4ee3;&#x7801;</from><to>&#x503c;&#x6620;&#x5c04;</to><enabled>Y</enabled> </hop>
  217 + <hop> <from>&#x539f;&#x59cb;&#x7cfb;&#x7edf;&#x5bfc;&#x51fa;&#x7684;Excel&#x8f93;&#x5165;</from><to>&#x5b57;&#x6bb5;&#x9009;&#x62e9;</to><enabled>Y</enabled> </hop>
  218 + <hop> <from>&#x5b57;&#x6bb5;&#x9009;&#x62e9;</from><to>&#x6027;&#x522b;&#x4ee3;&#x7801;</to><enabled>Y</enabled> </hop>
  219 + <hop> <from>&#x6027;&#x522b;&#x4ee3;&#x7801;</from><to>&#x516c;&#x4ea4;&#x4f01;&#x4e1a;&#x4ee3;&#x7801;</to><enabled>Y</enabled> </hop>
  220 + <hop> <from>&#x63d2;&#x5165;&#x2f;&#x66f4;&#x65b0;bsth_c_personnel</from><to>&#x9519;&#x8bef;&#x8f93;&#x51fa;</to><enabled>Y</enabled> </hop>
  221 + <hop> <from>&#x503c;&#x6620;&#x5c04;</from><to>&#x63d2;&#x5165;&#x2f;&#x66f4;&#x65b0;bsth_c_personnel</to><enabled>Y</enabled> </hop>
  222 + <hop> <from>&#x83b7;&#x53d6;&#x53d8;&#x91cf;</from><to>&#x539f;&#x59cb;&#x7cfb;&#x7edf;&#x5bfc;&#x51fa;&#x7684;Excel&#x8f93;&#x5165;</to><enabled>Y</enabled> </hop>
  223 + </order>
  224 + <step>
  225 + <name>&#x516c;&#x4ea4;&#x4f01;&#x4e1a;&#x4ee3;&#x7801;</name>
  226 + <type>ValueMapper</type>
  227 + <description/>
  228 + <distribute>Y</distribute>
  229 + <custom_distribution/>
  230 + <copies>1</copies>
  231 + <partitioning>
  232 + <method>none</method>
  233 + <schema_name/>
  234 + </partitioning>
  235 + <field_to_use>company</field_to_use>
  236 + <target_field>companyCode</target_field>
  237 + <non_match_default/>
  238 + <fields>
  239 + <field>
  240 + <source_value>&#x4e0a;&#x5357;&#x516c;&#x53f8;</source_value>
  241 + <target_value>55</target_value>
  242 + </field>
  243 + <field>
  244 + <source_value>&#x91d1;&#x9ad8;&#x516c;&#x53f8;</source_value>
  245 + <target_value>22</target_value>
  246 + </field>
  247 + <field>
  248 + <source_value>&#x6768;&#x9ad8;&#x516c;&#x53f8;</source_value>
  249 + <target_value>05</target_value>
  250 + </field>
  251 + <field>
  252 + <source_value>&#x5357;&#x6c47;&#x516c;&#x53f8;</source_value>
  253 + <target_value>26</target_value>
  254 + </field>
  255 + <field>
  256 + <source_value>&#x516c;&#x4ea4;&#x516c;&#x53f8;</source_value>
  257 + <target_value>88</target_value>
  258 + </field>
  259 + <field>
  260 + <source_value>&#x95f5;&#x884c;&#x516c;&#x4ea4;</source_value>
  261 + <target_value>77</target_value>
  262 + </field>
  263 + </fields>
  264 + <cluster_schema/>
  265 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  266 + <xloc>539</xloc>
  267 + <yloc>56</yloc>
  268 + <draw>Y</draw>
  269 + </GUI>
  270 + </step>
  271 +
  272 + <step>
  273 + <name>&#x539f;&#x59cb;&#x7cfb;&#x7edf;&#x5bfc;&#x51fa;&#x7684;Excel&#x8f93;&#x5165;</name>
  274 + <type>ExcelInput</type>
  275 + <description/>
  276 + <distribute>Y</distribute>
  277 + <custom_distribution/>
  278 + <copies>1</copies>
  279 + <partitioning>
  280 + <method>none</method>
  281 + <schema_name/>
  282 + </partitioning>
  283 + <header>Y</header>
  284 + <noempty>Y</noempty>
  285 + <stoponempty>N</stoponempty>
  286 + <filefield/>
  287 + <sheetfield/>
  288 + <sheetrownumfield/>
  289 + <rownumfield/>
  290 + <sheetfield/>
  291 + <filefield/>
  292 + <limit>0</limit>
  293 + <encoding/>
  294 + <add_to_result_filenames>Y</add_to_result_filenames>
  295 + <accept_filenames>Y</accept_filenames>
  296 + <accept_field>filepath_</accept_field>
  297 + <accept_stepname>&#x83b7;&#x53d6;&#x53d8;&#x91cf;</accept_stepname>
  298 + <file>
  299 + <name/>
  300 + <filemask/>
  301 + <exclude_filemask/>
  302 + <file_required>N</file_required>
  303 + <include_subfolders>N</include_subfolders>
  304 + </file>
  305 + <fields>
  306 + <field>
  307 + <name>&#x59d3;&#x540d;</name>
  308 + <type>String</type>
  309 + <length>-1</length>
  310 + <precision>-1</precision>
  311 + <trim_type>none</trim_type>
  312 + <repeat>N</repeat>
  313 + <format/>
  314 + <currency/>
  315 + <decimal/>
  316 + <group/>
  317 + </field>
  318 + <field>
  319 + <name>&#x5de5;&#x53f7;</name>
  320 + <type>String</type>
  321 + <length>-1</length>
  322 + <precision>-1</precision>
  323 + <trim_type>none</trim_type>
  324 + <repeat>N</repeat>
  325 + <format/>
  326 + <currency/>
  327 + <decimal/>
  328 + <group/>
  329 + </field>
  330 + <field>
  331 + <name>&#x6027;&#x522b;</name>
  332 + <type>String</type>
  333 + <length>-1</length>
  334 + <precision>-1</precision>
  335 + <trim_type>none</trim_type>
  336 + <repeat>N</repeat>
  337 + <format/>
  338 + <currency/>
  339 + <decimal/>
  340 + <group/>
  341 + </field>
  342 + <field>
  343 + <name>&#x6240;&#x5c5e;&#x516c;&#x53f8;</name>
  344 + <type>String</type>
  345 + <length>-1</length>
  346 + <precision>-1</precision>
  347 + <trim_type>none</trim_type>
  348 + <repeat>N</repeat>
  349 + <format/>
  350 + <currency/>
  351 + <decimal/>
  352 + <group/>
  353 + </field>
  354 + <field>
  355 + <name>&#x6240;&#x5c5e;&#x5206;&#x516c;&#x53f8;</name>
  356 + <type>String</type>
  357 + <length>-1</length>
  358 + <precision>-1</precision>
  359 + <trim_type>none</trim_type>
  360 + <repeat>N</repeat>
  361 + <format/>
  362 + <currency/>
  363 + <decimal/>
  364 + <group/>
  365 + </field>
  366 + <field>
  367 + <name>&#x4e00;&#x5361;&#x901a;&#x53f7;</name>
  368 + <type>String</type>
  369 + <length>-1</length>
  370 + <precision>-1</precision>
  371 + <trim_type>none</trim_type>
  372 + <repeat>N</repeat>
  373 + <format/>
  374 + <currency/>
  375 + <decimal/>
  376 + <group/>
  377 + </field>
  378 + <field>
  379 + <name>&#x8fd0;&#x8425;&#x670d;&#x52a1;&#x8bc1;&#x53f7;</name>
  380 + <type>String</type>
  381 + <length>-1</length>
  382 + <precision>-1</precision>
  383 + <trim_type>none</trim_type>
  384 + <repeat>N</repeat>
  385 + <format/>
  386 + <currency/>
  387 + <decimal/>
  388 + <group/>
  389 + </field>
  390 + <field>
  391 + <name>&#x5c97;&#x4f4d;</name>
  392 + <type>String</type>
  393 + <length>-1</length>
  394 + <precision>-1</precision>
  395 + <trim_type>none</trim_type>
  396 + <repeat>N</repeat>
  397 + <format/>
  398 + <currency/>
  399 + <decimal/>
  400 + <group/>
  401 + </field>
  402 + <field>
  403 + <name>&#x5907;&#x6ce8;</name>
  404 + <type>String</type>
  405 + <length>-1</length>
  406 + <precision>-1</precision>
  407 + <trim_type>none</trim_type>
  408 + <repeat>N</repeat>
  409 + <format/>
  410 + <currency/>
  411 + <decimal/>
  412 + <group/>
  413 + </field>
  414 + </fields>
  415 + <sheets>
  416 + <sheet>
  417 + <name>&#x5de5;&#x4f5c;&#x8868;1</name>
  418 + <startrow>0</startrow>
  419 + <startcol>0</startcol>
  420 + </sheet>
  421 + </sheets>
  422 + <strict_types>N</strict_types>
  423 + <error_ignored>N</error_ignored>
  424 + <error_line_skipped>N</error_line_skipped>
  425 + <bad_line_files_destination_directory/>
  426 + <bad_line_files_extension>warning</bad_line_files_extension>
  427 + <error_line_files_destination_directory/>
  428 + <error_line_files_extension>error</error_line_files_extension>
  429 + <line_number_files_destination_directory/>
  430 + <line_number_files_extension>line</line_number_files_extension>
  431 + <shortFileFieldName/>
  432 + <pathFieldName/>
  433 + <hiddenFieldName/>
  434 + <lastModificationTimeFieldName/>
  435 + <uriNameFieldName/>
  436 + <rootUriNameFieldName/>
  437 + <extensionFieldName/>
  438 + <sizeFieldName/>
  439 + <spreadsheet_type>JXL</spreadsheet_type>
  440 + <cluster_schema/>
  441 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  442 + <xloc>158</xloc>
  443 + <yloc>57</yloc>
  444 + <draw>Y</draw>
  445 + </GUI>
  446 + </step>
  447 +
  448 + <step>
  449 + <name>&#x5b57;&#x6bb5;&#x9009;&#x62e9;</name>
  450 + <type>SelectValues</type>
  451 + <description/>
  452 + <distribute>Y</distribute>
  453 + <custom_distribution/>
  454 + <copies>1</copies>
  455 + <partitioning>
  456 + <method>none</method>
  457 + <schema_name/>
  458 + </partitioning>
  459 + <fields> <field> <name>&#x59d3;&#x540d;</name>
  460 + <rename>personnelName</rename>
  461 + <length>-2</length>
  462 + <precision>-2</precision>
  463 + </field> <field> <name>&#x5de5;&#x53f7;</name>
  464 + <rename>jobCode</rename>
  465 + <length>-2</length>
  466 + <precision>-2</precision>
  467 + </field> <field> <name>&#x6027;&#x522b;</name>
  468 + <rename>personnelType</rename>
  469 + <length>-2</length>
  470 + <precision>-2</precision>
  471 + </field> <field> <name>&#x6240;&#x5c5e;&#x516c;&#x53f8;</name>
  472 + <rename>company</rename>
  473 + <length>-2</length>
  474 + <precision>-2</precision>
  475 + </field> <field> <name>&#x6240;&#x5c5e;&#x5206;&#x516c;&#x53f8;</name>
  476 + <rename>brancheCompany</rename>
  477 + <length>-2</length>
  478 + <precision>-2</precision>
  479 + </field> <field> <name>&#x4e00;&#x5361;&#x901a;&#x53f7;</name>
  480 + <rename>icCardCode</rename>
  481 + <length>-2</length>
  482 + <precision>-2</precision>
  483 + </field> <field> <name>&#x8fd0;&#x8425;&#x670d;&#x52a1;&#x8bc1;&#x53f7;</name>
  484 + <rename>papersCode</rename>
  485 + <length>-2</length>
  486 + <precision>-2</precision>
  487 + </field> <field> <name>&#x5c97;&#x4f4d;</name>
  488 + <rename>posts</rename>
  489 + <length>-2</length>
  490 + <precision>-2</precision>
  491 + </field> <field> <name>&#x5907;&#x6ce8;</name>
  492 + <rename>descriptions</rename>
  493 + <length>-2</length>
  494 + <precision>-2</precision>
  495 + </field> <select_unspecified>N</select_unspecified>
  496 + </fields> <cluster_schema/>
  497 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  498 + <xloc>286</xloc>
  499 + <yloc>58</yloc>
  500 + <draw>Y</draw>
  501 + </GUI>
  502 + </step>
  503 +
  504 + <step>
  505 + <name>&#x6027;&#x522b;&#x4ee3;&#x7801;</name>
  506 + <type>ValueMapper</type>
  507 + <description/>
  508 + <distribute>Y</distribute>
  509 + <custom_distribution/>
  510 + <copies>1</copies>
  511 + <partitioning>
  512 + <method>none</method>
  513 + <schema_name/>
  514 + </partitioning>
  515 + <field_to_use>personnelType</field_to_use>
  516 + <target_field>personnelCode</target_field>
  517 + <non_match_default/>
  518 + <fields>
  519 + <field>
  520 + <source_value>&#x7537;&#x6027;</source_value>
  521 + <target_value>1</target_value>
  522 + </field>
  523 + <field>
  524 + <source_value>&#x5973;&#x6027;</source_value>
  525 + <target_value>2</target_value>
  526 + </field>
  527 + </fields>
  528 + <cluster_schema/>
  529 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  530 + <xloc>413</xloc>
  531 + <yloc>58</yloc>
  532 + <draw>Y</draw>
  533 + </GUI>
  534 + </step>
  535 +
  536 + <step>
  537 + <name>&#x63d2;&#x5165;&#x2f;&#x66f4;&#x65b0;bsth_c_personnel</name>
  538 + <type>InsertUpdate</type>
  539 + <description/>
  540 + <distribute>Y</distribute>
  541 + <custom_distribution/>
  542 + <copies>1</copies>
  543 + <partitioning>
  544 + <method>none</method>
  545 + <schema_name/>
  546 + </partitioning>
  547 + <connection>bus_control_&#x516c;&#x53f8;_201</connection>
  548 + <commit>5000</commit>
  549 + <update_bypassed>N</update_bypassed>
  550 + <lookup>
  551 + <schema/>
  552 + <table>bsth_c_personnel</table>
  553 + <key>
  554 + <name>jobCode</name>
  555 + <field>job_code</field>
  556 + <condition>&#x3d;</condition>
  557 + <name2/>
  558 + </key>
  559 + <key>
  560 + <name>companyCode</name>
  561 + <field>company_code</field>
  562 + <condition>&#x3d;</condition>
  563 + <name2/>
  564 + </key>
  565 + <value>
  566 + <name>personnel_name</name>
  567 + <rename>personnelName</rename>
  568 + <update>Y</update>
  569 + </value>
  570 + <value>
  571 + <name>job_code</name>
  572 + <rename>jobCode</rename>
  573 + <update>Y</update>
  574 + </value>
  575 + <value>
  576 + <name>personnel_type</name>
  577 + <rename>personnelCode</rename>
  578 + <update>Y</update>
  579 + </value>
  580 + <value>
  581 + <name>company</name>
  582 + <rename>company</rename>
  583 + <update>Y</update>
  584 + </value>
  585 + <value>
  586 + <name>branche_company</name>
  587 + <rename>brancheCompany</rename>
  588 + <update>Y</update>
  589 + </value>
  590 + <value>
  591 + <name>ic_card_code</name>
  592 + <rename>icCardCode</rename>
  593 + <update>Y</update>
  594 + </value>
  595 + <value>
  596 + <name>papers_code</name>
  597 + <rename>papersCode</rename>
  598 + <update>Y</update>
  599 + </value>
  600 + <value>
  601 + <name>posts</name>
  602 + <rename>posts</rename>
  603 + <update>Y</update>
  604 + </value>
  605 + <value>
  606 + <name>descriptions</name>
  607 + <rename>descriptions</rename>
  608 + <update>Y</update>
  609 + </value>
  610 + <value>
  611 + <name>company_code</name>
  612 + <rename>companyCode</rename>
  613 + <update>Y</update>
  614 + </value>
  615 + </lookup>
  616 + <cluster_schema/>
  617 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  618 + <xloc>713</xloc>
  619 + <yloc>56</yloc>
  620 + <draw>Y</draw>
  621 + </GUI>
  622 + </step>
  623 +
  624 + <step>
  625 + <name>&#x9519;&#x8bef;&#x8f93;&#x51fa;</name>
  626 + <type>ExcelOutput</type>
  627 + <description/>
  628 + <distribute>Y</distribute>
  629 + <custom_distribution/>
  630 + <copies>1</copies>
  631 + <partitioning>
  632 + <method>none</method>
  633 + <schema_name/>
  634 + </partitioning>
  635 + <header>Y</header>
  636 + <footer>N</footer>
  637 + <encoding>UTF-8</encoding>
  638 + <append>N</append>
  639 + <add_to_result_filenames>Y</add_to_result_filenames>
  640 + <file>
  641 + <name>&#x24;&#x7b;erroroutputdir&#x7d;&#x2f;&#x4eba;&#x5458;&#x57fa;&#x7840;&#x4fe1;&#x606f;_&#x9519;&#x8bef;</name>
  642 + <extention>xls</extention>
  643 + <do_not_open_newfile_init>N</do_not_open_newfile_init>
  644 + <create_parent_folder>N</create_parent_folder>
  645 + <split>N</split>
  646 + <add_date>N</add_date>
  647 + <add_time>N</add_time>
  648 + <SpecifyFormat>N</SpecifyFormat>
  649 + <date_time_format/>
  650 + <sheetname>Sheet1</sheetname>
  651 + <autosizecolums>N</autosizecolums>
  652 + <nullisblank>N</nullisblank>
  653 + <protect_sheet>N</protect_sheet>
  654 + <password>Encrypted </password>
  655 + <splitevery>0</splitevery>
  656 + <usetempfiles>N</usetempfiles>
  657 + <tempdirectory/>
  658 + </file>
  659 + <template>
  660 + <enabled>N</enabled>
  661 + <append>N</append>
  662 + <filename>template.xls</filename>
  663 + </template>
  664 + <fields>
  665 + <field>
  666 + <name>personnelName</name>
  667 + <type>String</type>
  668 + <format/>
  669 + </field>
  670 + <field>
  671 + <name>jobCode</name>
  672 + <type>String</type>
  673 + <format/>
  674 + </field>
  675 + <field>
  676 + <name>personnelType</name>
  677 + <type>String</type>
  678 + <format/>
  679 + </field>
  680 + <field>
  681 + <name>company</name>
  682 + <type>String</type>
  683 + <format/>
  684 + </field>
  685 + <field>
  686 + <name>brancheCompany</name>
  687 + <type>String</type>
  688 + <format/>
  689 + </field>
  690 + <field>
  691 + <name>icCardCode</name>
  692 + <type>String</type>
  693 + <format/>
  694 + </field>
  695 + <field>
  696 + <name>papersCode</name>
  697 + <type>String</type>
  698 + <format/>
  699 + </field>
  700 + <field>
  701 + <name>posts</name>
  702 + <type>String</type>
  703 + <format/>
  704 + </field>
  705 + <field>
  706 + <name>descriptions</name>
  707 + <type>String</type>
  708 + <format/>
  709 + </field>
  710 + <field>
  711 + <name>companyCode</name>
  712 + <type>String</type>
  713 + <format/>
  714 + </field>
  715 + <field>
  716 + <name>error_count</name>
  717 + <type>Integer</type>
  718 + <format/>
  719 + </field>
  720 + <field>
  721 + <name>error_desc</name>
  722 + <type>String</type>
  723 + <format/>
  724 + </field>
  725 + <field>
  726 + <name>error_column1</name>
  727 + <type>String</type>
  728 + <format/>
  729 + </field>
  730 + <field>
  731 + <name>error_column2</name>
  732 + <type>String</type>
  733 + <format/>
  734 + </field>
  735 + </fields>
  736 + <custom>
  737 + <header_font_name>arial</header_font_name>
  738 + <header_font_size>10</header_font_size>
  739 + <header_font_bold>N</header_font_bold>
  740 + <header_font_italic>N</header_font_italic>
  741 + <header_font_underline>no</header_font_underline>
  742 + <header_font_orientation>horizontal</header_font_orientation>
  743 + <header_font_color>black</header_font_color>
  744 + <header_background_color>none</header_background_color>
  745 + <header_row_height>255</header_row_height>
  746 + <header_alignment>left</header_alignment>
  747 + <header_image/>
  748 + <row_font_name>arial</row_font_name>
  749 + <row_font_size>10</row_font_size>
  750 + <row_font_color>black</row_font_color>
  751 + <row_background_color>none</row_background_color>
  752 + </custom>
  753 + <cluster_schema/>
  754 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  755 + <xloc>715</xloc>
  756 + <yloc>223</yloc>
  757 + <draw>Y</draw>
  758 + </GUI>
  759 + </step>
  760 +
  761 + <step>
  762 + <name>&#x503c;&#x6620;&#x5c04;</name>
  763 + <type>ValueMapper</type>
  764 + <description/>
  765 + <distribute>Y</distribute>
  766 + <custom_distribution/>
  767 + <copies>1</copies>
  768 + <partitioning>
  769 + <method>none</method>
  770 + <schema_name/>
  771 + </partitioning>
  772 + <field_to_use>posts</field_to_use>
  773 + <target_field/>
  774 + <non_match_default/>
  775 + <fields>
  776 + <field>
  777 + <source_value>&#x516c;&#x5171;&#x6c7d;&#x7535;&#x8f66;&#x9a7e;&#x9a76;&#x5458;</source_value>
  778 + <target_value>1</target_value>
  779 + </field>
  780 + <field>
  781 + <source_value>&#x516c;&#x5171;&#x6c7d;&#x7535;&#x8f66;&#x8c03;&#x5ea6;&#x5458;</source_value>
  782 + <target_value>2</target_value>
  783 + </field>
  784 + <field>
  785 + <source_value>&#x516c;&#x5171;&#x6c7d;&#x7535;&#x8f66;&#x552e;&#x7968;&#x5458;</source_value>
  786 + <target_value>3</target_value>
  787 + </field>
  788 + <field>
  789 + <source_value>&#x7ad9;&#x5458;</source_value>
  790 + <target_value>4</target_value>
  791 + </field>
  792 + <field>
  793 + <source_value>&#x7ba1;&#x7406;&#x5458;</source_value>
  794 + <target_value>5</target_value>
  795 + </field>
  796 + <field>
  797 + <source_value>&#x5b89;&#x68c0;&#x5458;</source_value>
  798 + <target_value>6</target_value>
  799 + </field>
  800 + <field>
  801 + <source_value>&#x673a;&#x52a1;</source_value>
  802 + <target_value>7</target_value>
  803 + </field>
  804 + <field>
  805 + <source_value>&#x5f15;&#x5bfc;&#x5458;</source_value>
  806 + <target_value>8</target_value>
  807 + </field>
  808 + <field>
  809 + <source_value>&#x4e58;&#x52a1;&#x5458;</source_value>
  810 + <target_value>9</target_value>
  811 + </field>
  812 + <field>
  813 + <source_value>&#x8f66;&#x961f;&#x957f;&#xff08;&#x7ebf;&#x957f;&#x3001;&#x4e3b;</source_value>
  814 + <target_value>10</target_value>
  815 + </field>
  816 + <field>
  817 + <source_value>&#x516c;&#x53f8;&#x7ba1;&#x7406;&#x4eba;&#x5458;</source_value>
  818 + <target_value>11</target_value>
  819 + </field>
  820 + <field>
  821 + <source_value>&#x8b66;&#x6d88;&#x4eba;&#x5458;</source_value>
  822 + <target_value>12</target_value>
  823 + </field>
  824 + <field>
  825 + <source_value>&#x7968;&#x52a1;&#x4eba;&#x5458;</source_value>
  826 + <target_value>13</target_value>
  827 + </field>
  828 + <field>
  829 + <source_value>&#x5176;&#x4ed6;&#x670d;&#x52a1;&#x4eba;&#x5458;</source_value>
  830 + <target_value>14</target_value>
  831 + </field>
  832 + </fields>
  833 + <cluster_schema/>
  834 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  835 + <xloc>543</xloc>
  836 + <yloc>152</yloc>
  837 + <draw>Y</draw>
  838 + </GUI>
  839 + </step>
  840 +
  841 + <step>
  842 + <name>&#x83b7;&#x53d6;&#x53d8;&#x91cf;</name>
  843 + <type>GetVariable</type>
  844 + <description/>
  845 + <distribute>Y</distribute>
  846 + <custom_distribution/>
  847 + <copies>1</copies>
  848 + <partitioning>
  849 + <method>none</method>
  850 + <schema_name/>
  851 + </partitioning>
  852 + <fields>
  853 + <field>
  854 + <name>filepath_</name>
  855 + <variable>&#x24;&#x7b;filepath&#x7d;</variable>
  856 + <type>String</type>
  857 + <format/>
  858 + <currency/>
  859 + <decimal/>
  860 + <group/>
  861 + <length>-1</length>
  862 + <precision>-1</precision>
  863 + <trim_type>none</trim_type>
  864 + </field>
  865 + <field>
  866 + <name>erroroutputdir_</name>
  867 + <variable>&#x24;&#x7b;erroroutputdir&#x7d;</variable>
  868 + <type>String</type>
  869 + <format/>
  870 + <currency/>
  871 + <decimal/>
  872 + <group/>
  873 + <length>-1</length>
  874 + <precision>-1</precision>
  875 + <trim_type>none</trim_type>
  876 + </field>
  877 + </fields>
  878 + <cluster_schema/>
  879 + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI>
  880 + <xloc>90</xloc>
  881 + <yloc>148</yloc>
  882 + <draw>Y</draw>
  883 + </GUI>
  884 + </step>
  885 +
  886 + <step_error_handling>
  887 + <error>
  888 + <source_step>&#x63d2;&#x5165;&#x2f;&#x66f4;&#x65b0;bsth_c_personnel</source_step>
  889 + <target_step>&#x9519;&#x8bef;&#x8f93;&#x51fa;</target_step>
  890 + <is_enabled>Y</is_enabled>
  891 + <nr_valuename>error_count</nr_valuename>
  892 + <descriptions_valuename>error_desc</descriptions_valuename>
  893 + <fields_valuename>error_column1</fields_valuename>
  894 + <codes_valuename>error_column2</codes_valuename>
  895 + <max_errors/>
  896 + <max_pct_errors/>
  897 + <min_pct_rows/>
  898 + </error>
  899 + </step_error_handling>
  900 + <slave-step-copy-partition-distribution>
  901 +</slave-step-copy-partition-distribution>
  902 + <slave_transformation>N</slave_transformation>
  903 +
  904 +</transformation>
... ...
src/main/resources/static/pages/scheduleApp/module/basicInfo/busInfoManage/dataImport.html
1 1 <div class="modal-header">
2   - <h3 class="modal-title">excel数据导入</h3>
  2 + <h3 class="modal-title">车辆基础信息excel数据导入</h3>
3 3 </div>
4 4 <div class="modal-body">
5 5 <div class="col-md-6">
... ...
src/main/resources/static/pages/scheduleApp/module/basicInfo/employeeInfoManage/dataImport.html 0 → 100644
  1 +<div class="modal-header">
  2 + <h3 class="modal-title">人员基础信息excel数据导入</h3>
  3 +</div>
  4 +<div class="modal-body">
  5 + <div class="col-md-6">
  6 + <div class="input-group">
  7 + <input type="file" class="form-control" nv-file-select="" uploader="ctrl.uploader"/>
  8 + <span class="input-group-btn">
  9 + <button type="button" ng-click="ctrl.clearInputFile()" class="btn btn-default">
  10 + <span class="glyphicon glyphicon-trash"></span>
  11 + </button>
  12 + </span>
  13 + </div>
  14 + </div>
  15 +
  16 + <div class="table-scrollable table-scrollable-borderless">
  17 + <table class="table table-hover table-light">
  18 + <thead>
  19 + <tr class="uppercase">
  20 + <th width="50%">文件名</th>
  21 + <th ng-show="ctrl.uploader.isHTML5">大小(M)</th>
  22 + <th ng-show="ctrl.uploader.isHTML5">进度</th>
  23 + <th>状态</th>
  24 + <th>操作</th>
  25 + </tr>
  26 + </thead>
  27 + <tbody>
  28 + <tr ng-repeat="item in ctrl.uploader.queue">
  29 + <td>
  30 + <strong>{{ item.file.name }}</strong>
  31 + </td>
  32 + <td ng-show="ctrl.uploader.isHTML5" nowrap>{{ item.file.size/1024/1024|number:2 }} MB</td>
  33 + <td ng-show="ctrl.uploader.isHTML5">
  34 + <div class="progress progress-sm" style="margin-bottom: 0;">
  35 + <div class="progress-bar progress-bar-info" role="progressbar"
  36 + ng-style="{ 'width': item.progress + '%' }"></div>
  37 + </div>
  38 + </td>
  39 + <td class="text-center">
  40 + <span ng-show="item.isSuccess" class="text-success">
  41 + <i class="glyphicon glyphicon-ok"></i>
  42 + </span>
  43 + <span ng-show="item.isCancel" class="text-info">
  44 + <i class="glyphicon glyphicon-ban-circle"></i>
  45 + </span>
  46 + <span ng-show="item.isError" class="text-danger">
  47 + <i class="glyphicon glyphicon-remove"></i>
  48 + </span>
  49 + </td>
  50 + <td nowrap>
  51 + <button type="button" class="btn btn-success btn-xs" ng-click="item.upload()"
  52 + ng-disabled="item.isReady || item.isUploading || item.isSuccess">
  53 + <span class="glyphicon glyphicon-upload"></span> 上传
  54 + </button>
  55 + <button type="button" class="btn btn-warning btn-xs" ng-click="item.cancel()"
  56 + ng-disabled="!item.isUploading">
  57 + <span class="glyphicon glyphicon-ban-circle"></span> 取消
  58 + </button>
  59 + <button type="button" class="btn btn-danger btn-xs" ng-click="item.remove()">
  60 + <span class="glyphicon glyphicon-trash"></span> 删除
  61 + </button>
  62 + </td>
  63 + </tr>
  64 + </tbody>
  65 + </table>
  66 + </div>
  67 +
  68 +</div>
  69 +
  70 +<div class="modal-footer">
  71 + <button class="btn btn-primary" ng-click="ctrl.close()">关闭</button>
  72 +</div>
0 73 \ No newline at end of file
... ...
src/main/resources/static/pages/scheduleApp/module/basicInfo/employeeInfoManage/employeeInfoManage.js
... ... @@ -29,6 +29,7 @@ angular.module(&#39;ScheduleApp&#39;).factory(&#39;EmployeeInfoManageService&#39;, [&#39;EmployeeInf
29 29 for (key in currentSearchCondition) {
30 30 currentSearchCondition[key] = "";
31 31 }
  32 + currentPageNo = 1;
32 33 },
33 34 /**
34 35 * 设置当前页码。
... ... @@ -68,7 +69,7 @@ angular.module(&#39;ScheduleApp&#39;).factory(&#39;EmployeeInfoManageService&#39;, [&#39;EmployeeInf
68 69  
69 70 }]);
70 71  
71   -angular.module('ScheduleApp').controller('EmployeeInfoManageCtrl', ['EmployeeInfoManageService', '$state', function(employeeInfoManageService, $state) {
  72 +angular.module('ScheduleApp').controller('EmployeeInfoManageCtrl', ['EmployeeInfoManageService', '$state', '$uibModal', function(employeeInfoManageService, $state, $uibModal) {
72 73 var self = this;
73 74  
74 75 // 切换到form状态
... ... @@ -76,6 +77,67 @@ angular.module(&#39;ScheduleApp&#39;).controller(&#39;EmployeeInfoManageCtrl&#39;, [&#39;EmployeeInf
76 77 //alert("切换");
77 78 $state.go("employeeInfoManage_form");
78 79 }
  80 +
  81 + // 导入excel
  82 + self.importData = function() {
  83 + // large方式弹出模态对话框
  84 + var modalInstance = $uibModal.open({
  85 + templateUrl: '/pages/scheduleApp/module/basicInfo/employeeInfoManage/dataImport.html',
  86 + size: "lg",
  87 + animation: true,
  88 + backdrop: 'static',
  89 + resolve: {
  90 + // 可以传值给controller
  91 + },
  92 + windowClass: 'center-modal',
  93 + controller: "EmployInfoManageToolsCtrl",
  94 + controllerAs: "ctrl",
  95 + bindToController: true
  96 + });
  97 + modalInstance.result.then(
  98 + function() {
  99 + console.log("dataImport.html打开");
  100 + },
  101 + function() {
  102 + console.log("dataImport.html消失");
  103 + }
  104 + );
  105 + };
  106 +}]);
  107 +
  108 +angular.module('ScheduleApp').controller('EmployInfoManageToolsCtrl', ['$modalInstance', 'FileUploader', function($modalInstance, FileUploader) {
  109 + var self = this;
  110 +
  111 + // 关闭窗口
  112 + self.close = function() {
  113 + $modalInstance.dismiss("cancel");
  114 + };
  115 +
  116 + self.clearInputFile = function() {
  117 + angular.element("input[type='file']").val(null);
  118 + };
  119 +
  120 + // 上传文件组件
  121 + self.uploader = new FileUploader({
  122 + url: "/personnel/dataImport",
  123 + filters: [] // 用于过滤文件,比如只允许导入excel
  124 + });
  125 + self.uploader.onAfterAddingFile = function(fileItem)
  126 + {
  127 + console.info('onAfterAddingFile', fileItem);
  128 + console.log(self.uploader.queue.length);
  129 + if (self.uploader.queue.length > 1)
  130 + self.uploader.removeFromQueue(0);
  131 + };
  132 + self.uploader.onSuccessItem = function(fileItem, response, status, headers)
  133 + {
  134 + console.info('onSuccessItem', fileItem, response, status, headers);
  135 + };
  136 + self.uploader.onErrorItem = function(fileItem, response, status, headers)
  137 + {
  138 + console.info('onErrorItem', fileItem, response, status, headers);
  139 + };
  140 +
79 141 }]);
80 142  
81 143 angular.module('ScheduleApp').controller('EmployeeInfoManageListCtrl', ['EmployeeInfoManageService', function(employeeInfoManageService) {
... ... @@ -124,7 +186,9 @@ angular.module(&#39;ScheduleApp&#39;).controller(&#39;EmployeeInfoManageListCtrl&#39;, [&#39;Employe
124 186 };
125 187 // 重置查询条件
126 188 self.resetSearchCondition = function() {
127   - return employeeInfoManageService.resetSearchCondition();
  189 + employeeInfoManageService.resetSearchCondition();
  190 + self.pageInfo.currentPage = 1;
  191 + self.pageChanaged();
128 192 };
129 193 }]);
130 194  
... ...
src/main/resources/static/pages/scheduleApp/module/basicInfo/employeeInfoManage/index.html
... ... @@ -40,6 +40,12 @@
40 40 </a>
41 41 <ul class="dropdown-menu pull-right">
42 42 <li>
  43 + <a href="javascript:" class="tool-action" ng-click="ctrl.importData()">
  44 + <i class="fa fa-file-excel-o"></i>
  45 + 导入excel
  46 + </a>
  47 + </li>
  48 + <li>
43 49 <a href="javascript:" class="tool-action">
44 50 <i class="fa fa-file-excel-o"></i>
45 51 导出excel
... ... @@ -48,8 +54,8 @@
48 54 <li class="divider"></li>
49 55 <li>
50 56 <a href="javascript:" class="tool-action">
51   - <i class="fa fa-refresh"></i>
52   - 刷行数据
  57 + <i class="fa fa-download"></i>
  58 + excel模版
53 59 </a>
54 60 </li>
55 61 </ul>
... ...
src/main/resources/static/pages/scheduleApp/module/main.js
... ... @@ -143,6 +143,7 @@ ScheduleApp.config([&#39;$stateProvider&#39;, &#39;$urlRouterProvider&#39;, function($stateProvi
143 143 name: 'employeeInfoManage_module',
144 144 insertBefore: '#ng_load_plugins_before', // 动态载入模块时放置的位置
145 145 files: [
  146 + "assets/bower_components/angular-file-upload/dist/angular-file-upload.min.js",
146 147 "pages/scheduleApp/module/basicInfo/employeeInfoManage/employeeInfoManage.js"
147 148 ]
148 149 });
... ...