Skip to content

数据处理

数据处理前的数据校验及数据发布等相关接口

POST 二次发布数据

POST /admin/tx/data/publish

用于上传时没有勾选"上传即发布"按钮的数据,也可以对数据重新设置转换参数进行二次发布

Body 请求参数

yaml
dataId: 490f9bab0ff4d3b1637bb729a10e769e
cfgJson: "{}"
fileType: 3dtiles
folderId: 503a36882494d6630dcdc74c6f6eb1f2
bizType: "3"

请求参数

名称位置类型必选说明
Authorizationheaderstringnone
bodybodyobjectnone
» dataIdbodystring数据基本ID
» cfgJsonbodystring发布配置
» fileTypebodystring文件类型
» folderIdbodystring新文件ID,上传完成后,数据列表中对应的文件主ID,非dataId
» bizTypebodystring数据类型

返回示例

json
{
  "code": 0,
  "msg": null,
  "data": null,
  "ok": true
}

返回结果

状态码状态码含义说明数据模型
200OKnoneInline

返回数据结构

状态码 200

名称类型必选约束中文名说明
» codeintegertruenonenone
» msgnulltruenonenone
» datanulltruenonenone
» okbooleantruenonenone

GET 判断ZIP是否包含投影文件

GET /admin/tx/data/valid/cadZipIsHavePrj

主要判断上传的cad zip包内是否含有prj或cfg投影文件,前端用来判断相关逻辑

请求参数

名称位置类型必选说明
dataIdquerystring数据ID
Authorizationheaderstringnone

返回示例

json
{
  "code": 1,
  "msg": "数据不存在",
  "data": null,
  "ok": false
}

返回结果

状态码状态码含义说明数据模型
200OKnoneInline

返回数据结构

状态码 200

名称类型必选约束中文名说明
» codeintegertruenonenone
» msgstringtruenonenone
» datanulltruenonenone
» okbooleantruenonenone

GET 数据处理进度

GET /admin/tx/data/getDataProcess

根据新数据ID集合获取数据的实时处理进度

请求参数

名称位置类型必选说明
folderIdsquerystring新数据ID,多个以,分割
Authorizationheaderstringnone

返回示例

json
{
  "code": 0,
  "msg": null,
  "data": {
    "currentTime": "2025-01-10 10:09:02",
    "dataProcessList": [
      {
        "id": "79ee968dc5fb1ffe48896a39120ab465",
        "process": 100,
        "processProgram": null,
        "updateTime": "2025-01-10 10:08:20",
        "status": 52
      }
    ],
    "unzipWaitCount": "0"
  },
  "ok": true
}

返回结果

状态码状态码含义说明数据模型
200OKnoneInline

返回数据结构

状态码 200

名称类型必选约束中文名说明
» codeintegertruenonenone
» msgnulltruenonenone
» dataobjecttruenonenone
»» currentTimestringtruenone当前服务器时间
»» dataProcessList[object]truenone数据处理进度列表
»»» idstringfalsenone新数据ID
»»» processintegerfalsenone处理进度 0-100
»»» processProgramnullfalsenone处理程序
»»» updateTimestringfalsenone更新时间
»»» statusintegerfalsenone数据处理状态
»» unzipWaitCountstringtruenonenone
» okbooleantruenonenone

GET 获取最后一次发布的参数配置

GET /admin/tx/data/getLastDataConfig

主要获取前端存储allParam参数

请求参数

名称位置类型必选说明
folderIdquerystringnone
Authorizationheaderstringnone

返回示例

json
{
  "code": 0,
  "msg": null,
  "data": {
    "id": "2ecaaca293f8bd7a7d65dceb6088c063",
    "dataId": "86079159aae58675e16c5aba9534fc1d",
    "cfgName": "allParam",
    "cfgValue": "%7B%22coordType%22%3A%22Project%22%2C%22srsOriginType%22%3A%22Project%22%2C%22psc_project_temp_SRSORIGIN%22%3A%7B%22x%22%3A%220%22%2C%22y%22%3A%220%22%2C%22z%22%3A%220%22%7D%2C%22psc_project_temp_centerPosition%22%3A%7B%22x%22%3A%2230%22%2C%22y%22%3A%22120%22%7D%2C%22psc_mode_tag%22%3A%22psc_mode_tag_project%22%2C%22CENTERLON_TYPE%22%3A1%7D",
    "cfgDesc": null,
    "folderId": "3a43e94252eddf82397f301c7f6e542f",
    "createBy": "admin",
    "createTime": "2025-01-10 13:11:53",
    "updateBy": "admin",
    "updateTime": "2025-01-10 13:12:05",
    "delFlag": "0"
  },
  "ok": true
}

返回结果

状态码状态码含义说明数据模型
200OKnoneInline

返回数据结构

状态码 200

名称类型必选约束中文名说明
» codeintegertruenonenone
» msgnulltruenonenone
» dataobjecttruenonenone
»» idstringtruenone发布配置ID
»» dataIdstringtruenone源数据ID
»» cfgNamestringtruenone配置名称
»» cfgValuestringtruenone配置值
»» cfgDescnulltruenone描述
»» folderIdstringtruenone新数据ID
»» createBystringtruenonenone
»» createTimestringtruenonenone
»» updateBystringtruenonenone
»» updateTimestringtruenonenone
»» delFlagstringtruenonenone
» okbooleantruenonenone

GET 判断shp数据是否完整

GET /admin/tx/data/valid/shpIsIntegrality

根据数据ID判断对应shp数据是否完整,主要判断该zip是否同时存在"shp", "prj", "shx", "dbf"这四个文件

请求参数

名称位置类型必选说明
dataIdquerystring源数据ID
Authorizationheaderstringnone

返回示例

json
{
  "code": 1,
  "msg": "数据不完整,缺少以下必要文件: shx, prj, dbf, shp",
  "data": null,
  "ok": false
}

返回结果

状态码状态码含义说明数据模型
200OKnoneInline

返回数据结构

状态码 200

名称类型必选约束中文名说明
» codeintegertruenonenone
» msgstringtruenonenone
» datanulltruenonenone
» okbooleantruenonenone

Released under the MIT License.