天翎MyApps技术社区 - 低代码平台 | 流程管理系统 | BPM软件

 找回密码
 注册成为天翎用户
查看: 1124|回复: 0

[常见问题] 视图自己写的sql列表如何点击列表进入表单?

[复制链接]
lingling17 发表于 2021-2-1 20:17:50 | 显示全部楼层 |阅读模式
本帖最后由 lingling17 于 2021-2-1 20:19 编辑

【myApps/OBPM版本号】:4.4stable sp21
【浏览器类型】:Chrome
【技术QQ群】:182378297
【场景】:视图自己写的sql列表 怎么样才要可以 点击列表进入表单?

【解决方法】:
1、sql查询出来的列表视图 想点击跳转进入对应表单 需要在sql语句上拼上对应表单的id,formid,domainid,applicationid
2、把文档里面的<a>换成<o-action>


  1. # myApps-good皮肤自定义a标签用法


  2. ### 一.视图列值脚本格式

  3. #### (1)以表单的形式打开

  4. ##### 1.参数说明


  5. | 参数        | 说明                                                         |
  6. | ----------- | ------------------------------------------------------------ |
  7. | action-type | opendocument:表单打开                                       |
  8. | appid       | 软件id                                                       |
  9. | formid      | 表单id                                                       |
  10. | docid       | 文档id                                                       |
  11. | isRefresh   | 关闭后是否刷新                                               |
  12. | open-type   | 打开类型:<br />1.open-present:当前页打开<br />2.open-eject :弹出层打开<br />3.open-tab: 标签页打开<br />4.open-blank: 新窗口打开 |
  13. | exparams    | 额外的参数                                                   |
  14. | parentid    | 主表的id                                                     |
  15. ##### 2.值脚本格式
  16. ```html
  17. <a action-type='opendocument' formid='formid' docid='docid' appid='appid' open-type='open-eject' isRefresh='true' dialog-width='600px' dialog-height='400px' exparams='&type=1&test=2' parentid='parentid'>弹出层打开表单</a>
  18. ```

  19. #### (2)以视图的形式打开

  20. ##### 1.参数说明


  21. | 参数        | 说明                                                         |
  22. | ----------- | ------------------------------------------------------------ |
  23. | action-type | openview:视图打开                                           |
  24. | appid       | 软件id                                                       |
  25. | viewid      | 视图id                                                       |
  26. | isRefresh   | 关闭后是否刷新                                               |
  27. | open-type   | 打开类型:<br />1.open-present:当前页打开<br />2.open-eject :弹出层打开<br />3.open-tab: 标签页打开<br />4.open-blank: 新窗口打开 |
  28. | exparams    | 额外的参数                                                   |
  29. ##### 2.值脚本格式
  30. ```html
  31. <a action-type='openview' viewid='viewid' appid='appid' open-type='open-eject' isRefresh='true' dialog-width='600px' dialog-height='400px' exparams='&type=1&test=2'>弹出层打开视图</a>
  32. ```
  33. #### (3)视图选择框的功能

  34. ##### 1.参数说明


  35. | 参数           | 说明                   |
  36. | -------------- | ---------------------- |
  37. | action-type    | viewselect:视图选择框 |
  38. | selectOne      | 视图为单选             |
  39. | viewid         | 视图id                 |
  40. | isRefresh      | 确认后是否刷新         |
  41. | okScript       | 确认条件               |
  42. | callbackScript | 确认后执行脚本         |
  43. | mapping        | 映射字段               |
  44. | dialog-width   | 视图选择框宽           |
  45. | dialog-height  | 视图选择框高           |
  46. ##### 2.值脚本格式
  47. ```html
  48. <a action-type='viewselect' viewid='viewid' isRefresh='true' okScript='(function(){println("ok");})()' mapping='[{id: "NmbxmOaDksosGnhaxai", value: "映射字段"}]'  callbackScript='(function(){println("callback");})()' selectOne='true' dialog-width='600px' dialog-height='400px' >视图选择框</a>
  49. ```
  50. #### (4)跳转类型

  51. ##### 1.参数说明


  52. | 参数        | 说明                                                         |
  53. | ----------- | ------------------------------------------------------------ |
  54. | action-type | jumpto:外部链接打开                                         |
  55. | url         | url地址                                                      |
  56. | title       | 头部信息                                                     |
  57. | isRefresh   | 确认后是否刷新                                               |
  58. | open-type   | 1.open-present:当前页打开<br />2.open-eject :弹出层打开<br />3.open-tab: 标签页打开<br />4.open-blank: 新窗口打开 |
  59. ##### 2.值脚本格式
  60. ```html
  61. <a action-type='jumpto' url='https://www.baidu.com/' title='百度' open-type=‘open-blank’>跳转百度</a>
  62. ```
复制代码

本版积分规则

QQ|手机版|天翎MyApps技术社区 ( 粤ICP备11093750号 )

GMT+8, 2026-8-12 07:28

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表