Skip to content
本页内容

流程发送后做数据推送

应用场景

在流程成功发送后,根据业务需求需要我们执行数据推送操作,将数据实时或定时地推送到指定的目标系统或平台。

扩展接口实现

java
package com.kqgeo.co.ext.controller;

import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.node.ArrayNode;
import com.fasterxml.jackson.databind.node.ObjectNode;
import com.kqgeo.co.ext.config.Description;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("ext/co/flow")
public class FlowDemo {

	/**
	 * 流程发送后数据推送
	 * @param parameter
	 * @return
	 * @throws JsonProcessingException
	 */
	@RequestMapping(value = "/send/destroy/push-data", method = RequestMethod.POST)
	@Description(describe = "流程发送前数据校验", instructions = "SendCommit:DESTROY", requestType = "post", requestUrl = "/ext/co/flow/send/destroy/push-data")
	public KqcoParm send_destroy_push_data(@RequestBody ObjectNode parameter) {

		//数据推送
		//to do

		String m_sTicket ="tiket-5c396f8c702840fd9ae6523f9a70dac4";
		KqcoApi kqcoApi = KqcoApiUtils.getKocoApi(m_sTicket);
		ParmImpl kqcoParm = (ParmImpl)kqcoApi.getKqcoParm();
		return kqcoParm;
	}
}

package com.kqgeo.co.ext.controller;

import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.node.ArrayNode;
import com.fasterxml.jackson.databind.node.ObjectNode;
import com.kqgeo.co.ext.config.Description;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("ext/co/flow")
public class FlowDemo {

	/**
	 * 流程发送后数据推送
	 * @param parameter
	 * @return
	 * @throws JsonProcessingException
	 */
	@RequestMapping(value = "/send/destroy/push-data", method = RequestMethod.POST)
	@Description(describe = "流程发送前数据校验", instructions = "SendCommit:DESTROY", requestType = "post", requestUrl = "/ext/co/flow/send/destroy/push-data")
	public KqcoParm send_destroy_push_data(@RequestBody ObjectNode parameter) {

		//数据推送
		//to do

		String m_sTicket ="tiket-5c396f8c702840fd9ae6523f9a70dac4";
		KqcoApi kqcoApi = KqcoApiUtils.getKocoApi(m_sTicket);
		ParmImpl kqcoParm = (ParmImpl)kqcoApi.getKqcoParm();
		return kqcoParm;
	}
}

Powerd by Vitepress.