python插件-通过点击某个按钮弹出一个网址

栏目:云星空知识作者:金蝶来源:金蝶云社区发布:2024-09-16浏览:1

python插件-通过点击某个按钮弹出一个网址

  1. 表单中创建一个按钮并且记住按钮标识

1704951629034.webp

2.新增表单插件

1704951807793.webp

3.代码如下,注意换行符

from Kingdee.BOS.JSON import * 
import sys
import clr
clr.AddReference('System')
clr.AddReference('Kingdee.BOS')
clr.AddReference('Kingdee.BOS.Core')
clr.AddReference('Kingdee.BOS.Contracts')
clr.AddReference('Kingdee.BOS.DataEntity')
from Kingdee.BOS import *
from Kingdee.BOS.Core import *
from Kingdee.BOS.Core.Bill import *
from Kingdee.BOS.Core.DynamicForm.PlugIn import *
from Kingdee.BOS.Core.DynamicForm.PlugIn.ControlModel  import *
import System
from Kingdee.BOS.Orm.DataEntity import *
from Kingdee.BOS.Core.Metadata import *
from Kingdee.BOS.Contracts import *
from System import DateTime
def AfterBarItemClick(e):                           
    if (e.BarItemKey=="PXS_tbButton"):
        this.View.ShowMessage("AAAAAA")
             openUrlArg = JSONObject()
             openUrlArg['url']='https://www.baidu.com/' 
             openUrlArg['title']='outside link'
             openUrlArg['urltitle']='open outside link'
             this.View.AddAction("openUrlWindow", openUrlArg)

python插件-通过点击某个按钮弹出一个网址

表单中创建一个按钮并且记住按钮标识2.新增表单插件3.代码如下,注意换行符from Kingdee.BOS.JSON import * import sysimport clrclr.AddRe...
点击下载文档
确认删除?
回到顶部
客服QQ
  • 客服QQ点击这里给我发消息