一、数据的导入与导出
1.库位数据导出与导入
申通导入模板文件
说明:库区对应的就是鸟系统上的仓库区域,库位就对应的鸟系统上的仓库容器,他们没有过道的信息
其中,库区模板中面积以及行、列、层数后期均可以修改,可以先填写固定一个数值
鸟系统库区信息导出
(1)连接线上数据库
(2)执行sqlSELECT zone.NAME AS "编码", zone.NAME AS "名称", 500 AS "面积", 3 AS "行数", 30 AS "列数", 3 AS "层数" FROM zone LEFT JOIN warehouse ON warehouse.id = zone.warehouse_id WHERE warehouse.company_id = {company_id} AND zone.STATUS = "ACTIVE";
其中{company_id}表示具体的站点ID
(3)示例数据如下,将生成的结果复制到库区模板,并根据需要修改编码及名称,这个编码在后续库位导入会需要用到鸟系统库区信息导入申通系统
联系对方技术或者英仓同事登录申通系统导入即可
鸟系统库位信息导出
(1)连接线上数据库
(2)执行sql,按照一个库区导一份文件的方式来导,因为多个库区的库位信息太多SELECT container.id AS "库位编码", "" AS "库位名称", "{code}" AS "库区编码", 20 AS "长", 10 AS "宽", 15 AS "高", "拣货" AS "类型", "手工" AS "操作方式", "否" AS "机器人库位", "否" AS "租用", "小" AS "大小类型" FROM container LEFT JOIN aisle ON container.aisle_id = aisle.id LEFT JOIN zone ON aisle.zone_id = zone.id LEFT JOIN warehouse ON warehouse.id = zone.warehouse_id WHERE warehouse.company_id = {company_id} AND zone.NAME = "{zone_name}" AND container.STATUS = "ACTIVE";
其中,{code}表示当前要导出的库区的编码(也就是上一步导出的库区编码),{company_id}表示具体的站点ID,{zone_name} 表示的是需要导出的库区对应的鸟系统的仓库区域名称
(3)示例数据如下,将生成的结果复制到库位模板,库区编码以及鸟系统仓库区域名称需要对应好
鸟系统库区信息导入申通系统
联系对方技术或者英仓同事登录申通系统导入即可
2.产品数据导出与导入
申通导入模板文件
鸟系统产品信息导出
(1)连接线上数据库
(2)执行sqlSELECT id AS barcode, id, NAME, IF(length( name_customs )!= char_length( name_customs ), "other", name_customs), "非自带包装", "公制单位", IF(weight = 0, 0.1, weight / 1000 ) AS weight_kg, (IF(length = 0, 0.1, length ) / 10) AS length_cm, (IF(width = 0, 0.1, width ) / 10 ) AS width_cm, (IF(depth = 0, 0.1, depth ) / 10 ) AS height_cm, "", "", "", "", "", "", "否" FROM product WHERE client_id IN ({client_id}) AND STATUS = "ACTIVE";
其中{client_id}表示具体的客户的ID
(3)示例数据如下,将生成的结果复制到产品模板
导入申通系统
登录申通客户端系统,点货品档案,导入按钮,上传文件,等待上传完毕,查看右边日志信息,根据报错信息修改