Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HELP] How to add a new protocol in the Type drop-down box?? #1530

Open
DuXiaoChuang opened this issue Sep 19, 2024 · 7 comments
Open

[HELP] How to add a new protocol in the Type drop-down box?? #1530

DuXiaoChuang opened this issue Sep 19, 2024 · 7 comments

Comments

@DuXiaoChuang
Copy link

How to add a new protocol in the Type drop-down box??
image

@yhliyr
Copy link
Contributor

yhliyr commented Sep 19, 2024

perhaps you could try adding a new connector type at gateway-widget.model.ts-ConnectorType and gateway-widget.model.ts-GatewayConnectorDefaultTypesTranslatesMap in the thingsboard platform project

@DuXiaoChuang
Copy link
Author

perhaps you could try adding a new connector type at gateway-widget.model.ts-ConnectorType and gateway-widget.model.ts-GatewayConnectorDefaultTypesTranslatesMap in the thingsboard platform project

How to add a new protocol in the Type drop-down box??
image

@yhliyr
Copy link
Contributor

yhliyr commented Sep 20, 2024

@DuXiaoChuang You can't do this on the web page, you have to modify the Thingsboard project code as i mentioned above, and compile the ui-ngx project and redeploy the whole project. 在页面上是不能手动添加的,只能改代码重新编译项目打包,改动的位置就是上面我提的两个地方,加两行就行了

or maybe you can try using the CUSTOM type, 或许可以试试 CUSTOM 类型,这个可以指定自定义连接器class的,不过我没试过,我也正在搞自定义connector

@DuXiaoChuang
Copy link
Author

DuXiaoChuang commented Sep 20, 2024

@DuXiaoChuang You can't do this on the web page, you have to modify the Thingsboard project code as i mentioned above, and compile the ui-ngx project and redeploy the whole project. 在页面上是不能手动添加的,只能改代码重新编译项目打包,改动的位置就是上面我提的两个地方,加两行就行了

or maybe you can try using the CUSTOM type, 或许可以试试 CUSTOM 类型,这个可以指定自定义连接器class的,不过我没试过,我也正在搞自定义connector

我按照你说的加了,没效果啊,下拉框里还是没有新增的协议。很奇怪,是其他哪里还要修改吗?而且目前代码和你的代码有版本上的差异。

@DuXiaoChuang
Copy link
Author

DuXiaoChuang commented Sep 24, 2024

@DuXiaoChuang You can't do this on the web page, you have to modify the Thingsboard project code as i mentioned above, and compile the ui-ngx project and redeploy the whole project. 在页面上是不能手动添加的,只能改代码重新编译项目打包,改动的位置就是上面我提的两个地方,加两行就行了

or maybe you can try using the CUSTOM type, 或许可以试试 CUSTOM 类型,这个可以指定自定义连接器class的,不过我没试过,我也正在搞自定义connector

I added the connector and named it with custom, but this TAB still has no data, which is strange.

image
image

@yhliyr
Copy link
Contributor

yhliyr commented Sep 25, 2024

@DuXiaoChuang You can't do this on the web page, you have to modify the Thingsboard project code as i mentioned above, and compile the ui-ngx project and redeploy the whole project. 在页面上是不能手动添加的,只能改代码重新编译项目打包,改动的位置就是上面我提的两个地方,加两行就行了
or maybe you can try using the CUSTOM type, 或许可以试试 CUSTOM 类型,这个可以指定自定义连接器class的,不过我没试过,我也正在搞自定义connector

I added the connector and named it with custom, but this TAB still has no data, which is strange.

image image

it show "focas", the class name is "focas" right? You can add a new ConnectorType here by 'Edit Component'
这里应该就把类名 focas 当作一种类型了,这里编辑部件可以手动添加连接器类型的

@DuXiaoChuang
Copy link
Author

@DuXiaoChuang You can't do this on the web page, you have to modify the Thingsboard project code as i mentioned above, and compile the ui-ngx project and redeploy the whole project. 在页面上是不能手动添加的,只能改代码重新编译项目打包,改动的位置就是上面我提的两个地方,加两行就行了
or maybe you can try using the CUSTOM type, 或许可以试试 CUSTOM 类型,这个可以指定自定义连接器class的,不过我没试过,我也正在搞自定义connector

I added the connector and named it with custom, but this TAB still has no data, which is strange.
image image

it show "focas", the class name is "focas" right? You can add a new ConnectorType here by 'Edit Component' 这里应该就把类名 focas 当作一种类型了,这里编辑部件可以手动添加连接器类型的

ok, thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants