提交 325c7698 编写于 作者: ibiz4j's avatar ibiz4j

tj

上级 74c981f0
......@@ -31,7 +31,7 @@ public class DictHtmlResource {
{{#each app.dicts}}
@ApiOperation(value = "字典:{{name}}[{{pascalCase codeName}}Dict]", tags = {"数据字典" }, notes = "字典:{{name}}[{{pascalCase codeName}}Dict]")
@RequestMapping(method = RequestMethod.GET, value = "/{{pascalCase codeName}}Dict.html")
public ResponseEntity<String> get{{pascalCase codeName}}Dict() {
public ResponseEntity<String> show{{pascalCase codeName}}Dict() {
List<String> tr=new ArrayList<>();
new {{pascalCase codeName}}Dict().getAllItems().forEach(item->tr.add(String.format(templateItem,item.getValue(),item.getLabel(),item.getParent()==null?"":item.getParent())));
return ResponseEntity.ok(String.format(html,String.format(template,"{{pascalCase codeName}}Dict","字典:{{name}}[{{pascalCase codeName}}Dict]",String.join("",tr))));
......
......@@ -42,6 +42,11 @@ import {{packageName}}.api.{{apps}}.dict.*;
@ApiSupport(order = 99)
public class DictResource {
/**
{{#each app.dicts}}
INSERT INTO ibzdictcatalog (CID, CCODE, CNAME, CGROUP, ENABLE) VALUES ('{{pascalCase codeName}}Dict', '{{pascalCase codeName}}Dict', '{{name}}', 'link', 1);
{{/each}}
*/
{{#each app.dicts}}
@ApiOperation(value = "字典:{{name}}[{{pascalCase codeName}}Dict]", tags = {"数据字典" }, notes = "字典:{{name}}[{{pascalCase codeName}}Dict]&nbsp;&nbsp;<a href=\"/xftong/link/dict/{{pascalCase codeName}}Dict.html\" target=\"_blank\">查看展示清单</a>&nbsp;&nbsp;<a href=\"/xftong/link/dict/{{pascalCase codeName}}Dict\" target=\"_blank\">查看json</a>")
......
......@@ -7,6 +7,7 @@ import cn.ibizlab.edge.api.link.dto.ex.*;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import com.github.xiaoymin.knife4j.annotations.ApiSort;
import com.github.xiaoymin.knife4j.annotations.ApiSupport;
import org.springframework.security.access.prepost.PreAuthorize;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
......@@ -28,9 +29,19 @@ import java.util.List;
@ApiSupport(order = 1)
public class G1ResResource {
/**
{{#each app.exModel as |item|}}
INSERT INTO dataresource (C_ID, C_VALUE, C_TOPIC, C_DOC_PATH, C_CATALOG_ID, C_POSITION) VALUES ('TOPIC_WSXF_RESOURCE_{{upperCase @key}}', '{{item}}', 'TOPIC_WSXF_RESOURCE_{{upperCase @key}}', 'pull{{@key}}UsingGET', 'xfyw', 1{{@index}});
{{/each}}
{{#each app.exModel as |item|}}
INSERT INTO datasubscription (C_ID, C_ACCESS_ID, C_RESOURCE_ID, C_CRON, C_TARGET) VALUES ('hbxfdpt0068-{{upperCase @key}}', 'hbxfdpt0068', 'TOPIC_WSXF_RESOURCE_{{upperCase @key}}', '20 3 * * *', null);
{{/each}}
*/
{{#each app.exModel as |item|}}
@ApiOperationSupport(order = 1{{@index}})
@ApiOperation(value = "{{item}}", tags = {"资源目录" }, notes = "topic主题:TOPIC_WSXF_RESOURCE_{{upperCase @key}}")
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','TOPIC_WSXF_RESOURCE_{{upperCase @key}}')")
@RequestMapping(method = RequestMethod.GET, value = "/mq/topic/TOPIC_WSXF_RESOURCE_{{upperCase @key}}/pullconsumer")
public ResponseEntity<List<{{@key}}Dto>> pull{{@key}}(@ApiParam("oauth2第三方接入token") @RequestHeader("Access-Token") String accessToken,
@ApiParam(value = "偏移量,不提供或0时默认计算",example = "0") @RequestParam(value = "offset",required = false,defaultValue = "0") Long offset,
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册