{ "type" : "page", "title" : "实名制扬尘监控历史记录", "body" : { "type" : "crud", "api" : "/api/flow/GB_SENNOR_HISTORY_SEARCH", "syncLocation" : false, "selectable" : true, "checkOnItemClick" : true, "filter" : { "title" : "查询", "body" : [ { "name" : "CREATETIME", "label" : "更新时间", "type" : "input-date-range" }, { "name" : "DATA1", "label" : "PM2.5", "type" : "input-number", "precision" : 2 }, { "name" : "DATA2", "label" : "PM10", "type" : "input-number", "precision" : 2 }, { "name" : "DATA3", "label" : "噪声", "type" : "input-number", "precision" : 2 }, { "name" : "DATA4", "label" : "温度", "type" : "input-number", "precision" : 2 }, { "name" : "DATA5", "label" : "湿度", "type" : "input-number", "precision" : 2 }, { "name" : "DATA6", "label" : "风向", "type" : "select", "clearable" : true, "source" : "/api/poc/dict/GB_SENNOR_WIND" }, { "name" : "DATA7", "label" : "风速", "type" : "input-number", "precision" : 2 }, { "name" : "DATA8", "label" : "扬尘(TSP)", "type" : "input-number", "precision" : 2 }, { "name" : "DATA9", "label" : "气压", "type" : "input-number", "precision" : 2 } ] }, "columns" : [ { "name" : "GB_SENNOR_HISTORY_ID", "label" : "主键", "width" : 200, "toggled" : false }, { "name" : "GB_SENNORID_DISPLAY__", "label" : "扬尘监控设备", "width" : 200 }, { "name" : "CREATETIME", "label" : "更新时间", "width" : 200, "type" : "datetime", "format" : "YYYY-MM-DD HH:mm", "inputFormat" : "YYYY-MM-DDTHH:mm:ss.SSSZ" }, { "name" : "DATA1", "label" : "PM2.5(ug/m3)", "width" : 200 }, { "name" : "DATA2", "label" : "PM10(ug/m3)", "width" : 200 }, { "name" : "DATA3", "label" : "噪声(dB)", "width" : 200 }, { "name" : "DATA4", "label" : "温度(℃)", "width" : 200 }, { "name" : "DATA5", "label" : "湿度(%RH)", "width" : 200 }, { "name" : "DATA6", "label" : "风向", "width" : 200, "type" : "mapping", "map" : { "1" : "正北", "2" : "东北偏北", "3" : "东北", "4" : "东北偏东", "5" : "正东", "6" : "东南偏东", "7" : "东南", "8" : "东南偏南", "9" : "正南", "10" : "西南偏南", "11" : "西南", "12" : "西南偏西", "13" : "正西", "14" : "西北偏西", "15" : "西北", "16" : "西北偏北" } }, { "name" : "DATA7", "label" : "风速(m/s)", "width" : 200 }, { "name" : "DATA10", "label" : "风级(级)", "width" : 200 }, { "name" : "DATA8", "label" : "扬尘(TSP)(ug/m3)", "width" : 200 }, { "name" : "DATA9", "label" : "气压(Kpa)", "width" : 200 }, { "name" : "ISSYNC", "label" : "已上传", "width" : 50, "type" : "mapping", "map" : { "0" : "否", "1" : "是", "false" : "否", "true" : "是" } } ], "headerToolbar" : [ { "type" : "button", "id" : "查看", "label" : "查看", "actionType" : "dialog", "disabledOn" : "${!selectedItems || selectedItems.length === 0}", "dialog" : { "type" : "dialog", "title" : "查看", "size" : "lg", "data" : { "&" : "${selectedItems[0]}", "__readonly" : true }, "body" : { "type" : "service", "schemaApi" : "get:/api/page/schema/189fe579-e6a1-43b9-85e2-d001eab1ffcd?format=amis", "static" : true, "api" : { "method" : "post", "url" : "/api/flow/GB_SENNOR_HISTORY_LOAD?__egtpl=189fe579-e6a1-43b9-85e2-d001eab1ffcd", "data" : { "GB_SENNOR_HISTORY_ID" : "${GB_SENNOR_HISTORY_ID}" }, "responseData" : { "&" : "${result}" } } } } }, { "type" : "button", "id" : "上传数据", "label" : "上传数据", "actionType" : "ajax", "disabled" : true, "confirmText" : "确认要上传此记录吗?", "api" : { "method" : "post", "url" : "/api/flow/GB_KQTEMPCOUNT_SYNCSENNOR", "data" : { "GB_SENNOR_HISTORY_ID" : "${selectedItems[0].GB_SENNOR_HISTORY_ID}" } } }, "pagination" ], "primaryField" : "GB_SENNOR_HISTORY_ID", "onEvent" : { "selectedChange" : { "actions" : [ { "actionType" : "disabled", "componentId" : "上传数据" }, { "actionType" : "ajax", "api" : { "method" : "post", "url" : "/api/script/execute-template", "data" : { "seq" : 1, "item" : "${event.data.selectedItems[0]}", "templateId" : "e981569f-d2e8-49d5-810c-3f5eb6515c34" } }, "outputVar" : "scriptResult1" }, { "actionType" : "replayScriptCommands", "args" : { "commands" : "${event.data.scriptResult1.commands}" } } ] } } } }