master
周文涛 2 years ago
parent 86a347c86e
commit 32bdec0855

@ -70,7 +70,7 @@ public class Main {
String password = "Nomi1234"; String password = "Nomi1234";
//2.选择表配置 //2.选择表配置
//String json="{\"oqc_spot_check_record\":\"抽检记录\",\"oqc_shipment_record\":\"成品出货记录\",\"oqc_1008_record\":\"1008仓台账\",\"oqc_after_sales_record\":\"售后记录\",\"oqc_special_sample\":\"特殊样件\",\"oqc_product_record\":\"产品追溯\",\"oqc_ncr_record\":\"NCR明细\",\"oqc_qrqc_record\":\"QRQC明细\"}"; //String json="{\"oqc_spot_check_record\":\"抽检记录\",\"oqc_shipment_record\":\"成品出货记录\",\"oqc_1008_record\":\"1008仓台账\",\"oqc_after_sales_record\":\"售后记录\",\"oqc_special_sample\":\"特殊样件\",\"oqc_product_record\":\"产品追溯\",\"oqc_ncr_record\":\"NCR明细\",\"oqc_qrqc_record\":\"QRQC明细\"}";
String json="{\"oqc_inspection_task\":\"检验任务\"}"; String json="{\"oqc_shipment_inspection\":\"出货检验\"}";
JSONObject tables = JSONObject.parseObject(json); JSONObject tables = JSONObject.parseObject(json);
for (String table : tables.keySet()) { for (String table : tables.keySet()) {
String entityName = TableFieldUtil.tableNameToEntityName(table); String entityName = TableFieldUtil.tableNameToEntityName(table);

@ -45,24 +45,8 @@ public class TableFieldUtil {
public static void main(String[] args) { public static void main(String[] args) {
String[] fields=new String[]{"highest_unit","processing_unit","pn_name","pn_remark","num","basic_unit","stock_type","desc_type","batch","receiving_time","hand_measure","delivery_time","target_location","deal_node","responsible_user_id","marking"}; String[] fields=new String[]{"id","pn_code","box_num","basic_unit","batch_num","status","warehouse_type","in_warehouse_time","responsible_user_id","factory_code","location_code","dn","stock_type","start_time","end_time"};
String[] fieldNames=new String[]{"主键id", String[] fieldNames=new String[]{"主键id","产品编码","箱数","基本计量单位","批次数量","检验单状态","仓库流转类型","入库时间","责任人id","厂区编码","库位编码","DN","库存类型","检验开始时间","检验结束时间"};
"最高处理单元",
"处理单元",
"产品",
"产品简短描述",
"数量",
"基本计量单位",
"库存类型",
"Desc.SType",
"批次",
"收货时间",
"处理措施",
"出库时间",
"目标库位",
"处理时间节点",
"责任人id",
"marking描述"};
for (int i = 0; i < fields.length; i++) { for (int i = 0; i < fields.length; i++) {
String s = CaseFormat.LOWER_UNDERSCORE.to(CaseFormat.LOWER_CAMEL, fields[i]); String s = CaseFormat.LOWER_UNDERSCORE.to(CaseFormat.LOWER_CAMEL, fields[i]);
String fieldName = fieldNames[i]; String fieldName = fieldNames[i];

Loading…
Cancel
Save