From 858d5b84cb2f9311d6e00d90c6f9527e2e6f57b4 Mon Sep 17 00:00:00 2001
From: lifan <2308045698@qq.com>
Date: 星期四, 04 九月 2025 17:50:13 +0800
Subject: [PATCH] update
---
jrj/project/workflow/workflow.chkdlg.cpp | 137 ++++++++++++++++++++++++---------------------
1 files changed, 74 insertions(+), 63 deletions(-)
diff --git a/jrj/project/workflow/workflow.chkdlg.cpp b/jrj/project/workflow/workflow.chkdlg.cpp
index 5b60cd1..7c8d23d 100644
--- a/jrj/project/workflow/workflow.chkdlg.cpp
+++ b/jrj/project/workflow/workflow.chkdlg.cpp
@@ -1,68 +1,79 @@
-class workflow_chkdlg : public win__
+#include <wobject/xwin.hpp>
+#include <xcontrol/xdwgrid.hpp>
+#include <xcontrol/xflowchart.hpp>
+#include <xcontrol/ximageview.hpp>
+
+using xml = KXMLDOMDocument;
+class __declspec(dllexport) workflow_chkdlg : public xwin
+{
+public:
+ workflow_chkdlg(void* implPtr, HWND hWnd) :xwin(implPtr, hWnd) {}
+ static workflow_chkdlg* CreateInstance(void* implPtr, void* hWnd)
+ {
+ workflow_chkdlg* pWin = new workflow_chkdlg(implPtr, (HWND)hWnd);
+ return pWin;
+ }
+public:
+
+ //命令发布函数
+ int OnCmdDispatch(xstring comdid)
+ {
+ if (GetWinParam())
{
- //命令发布函数
- int OnCmdDispatch(string comdid)
+ xaserverarg arg = GetArg();
+ if (comdid == L"xmOK")
{
- if(this.GetParam())
- {
- if(comdid=="xmOK")
- {
- control__ xc = new control__;
- xc.setNativePointer(GetControl("content"));
- string str = ""+xc.GetText();
- //trace(str);
- xaserverarg__ arg = this.GetParam();
- arg.AddArg("content",str);
- }
- arg.AddArg("comdid",comdid);
- }
- CloseWindow();
- return 0;
+ xcontrol xc = GetControl(L"content");
+ xstring str = xc.GetText();
+ if (str == L"")str = L".";
+ arg.AddArg(L"content", str);
}
-
- //命令处理事件
- int OnXCommand(ref TXCommandEvent evt,int param)
- {
- return OnCmdDispatch(evt.pStrID);
- }
+ arg.AddArg(L"comdid", comdid);
+ }
+ CloseWindow();
+ return 0;
+ }
- int OnAttachEvent()
- {
- //绑定工具条点击事件
- AttachEvent("WM_XCOMMAND",OnXCommand);
- }
-
-
- int onload()
- {
- OnAttachEvent();
- xaserverarg__ arg;
- if(this.GetParam())
- {
- arg = this.GetParam();
- control__ xc = new control__;
- xc.setNativePointer(GetControl("content"));
- xc.SetText(""+arg.GetArgString("content"));
- }
-
- xdwgrid__ dw_loglist = new xdwgrid__;
- dw_loglist.setNativePointer(GetControl("dw_loglist"));
- dw_loglist.openUrl("/sale/view/workflow.view/template/chkdlg/loglist");
-
- if(this.GetParam())
- {
- xaserverarg__ argx = new xaserverarg__;
- argx.setNativePointer(argx.CreateInstance());
- arg = this.GetParam();
- argx.AddArg("EntityID",arg.GetArgString("EntityID"));
- xml__ x = new xml__;
- x.setNativePointer(xml__ ::CreateInstance());
- url::get("/sale/data/workflow.core/workflow/chk/loglist", argx.GetString(), x);
- dw_loglist.Retrieve(x);
- dw_loglist.SetReadOnly(true);
- }
-
- return 1;
- }
+ //命令处理事件
+ int OnXCommand(TEvent* evt, int param)
+ {
+ return OnCmdDispatch(evt->xcommand.pStrID);
+ }
- }
\ No newline at end of file
+ int OnAttachEvent()
+ {
+ //绑定工具条点击事件
+ AttachEvent(L"WM_XCOMMAND", (FEvent)&workflow_chkdlg::OnXCommand);
+ return 1;
+ }
+
+
+ int onload()
+ {
+ SetArg();
+ OnAttachEvent();
+ xaserverarg arg;
+ if (GetWinParam())
+ {
+ arg = GetArg();
+ xcontrol xc = GetControl(L"content");
+ xc.SetText(arg.GetArgString(L"content"));
+ }
+
+ xdwgrid dw_loglist = GetControl(L"dw_loglist");
+ dw_loglist.openUrl(L"/sale/view/workflow.view/template/chkdlg/loglist");
+
+ if (GetWinParam())
+ {
+ xaserverarg argx;
+ arg = GetArg();
+ argx.AddArg(L"EntityID", arg.GetArgString(L"EntityID"));
+ xml x ;
+ xurl::get(L"/sale/data/workflow.core/workflow/chk/loglist", argx.GetString(), x);
+ dw_loglist.Retrieve(x);
+ dw_loglist.SetReadOnly(true);
+ }
+
+ return 1;
+ }
+};
\ No newline at end of file
--
Gitblit v1.9.3