From 06ac0840848d1799bad3bae43d51e7386cfa4c0d Mon Sep 17 00:00:00 2001
From: LiFan <2308045698@qq.com>
Date: 星期四, 11 七月 2024 16:25:21 +0800
Subject: [PATCH] updaet
---
jrj/project/total3/ViewTotalWin.cpp | 6 +
jrj/ext-jrj/ext-jrj.vcxproj | 13 +++-
jrj/project/business/File/trade.document3.cpp | 1
jrj/project/total3/ViewTotalArgWin.cpp | 137 +++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 151 insertions(+), 6 deletions(-)
diff --git a/jrj/ext-jrj/ext-jrj.vcxproj b/jrj/ext-jrj/ext-jrj.vcxproj
index 8e912af..9da560c 100644
--- a/jrj/ext-jrj/ext-jrj.vcxproj
+++ b/jrj/ext-jrj/ext-jrj.vcxproj
@@ -415,9 +415,15 @@
<ClCompile Include="..\project\business\Expense\TestExpenseBase2.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">false</ExcludedFromBuild>
</ClCompile>
- <ClCompile Include="..\project\business\File\trade.document3.cpp" />
- <ClCompile Include="..\project\business\File\trade.help3.cpp" />
- <ClCompile Include="..\project\business\File\trade.helpEx.cpp" />
+ <ClCompile Include="..\project\business\File\trade.document3.cpp">
+ <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
+ </ClCompile>
+ <ClCompile Include="..\project\business\File\trade.help3.cpp">
+ <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
+ </ClCompile>
+ <ClCompile Include="..\project\business\File\trade.helpEx.cpp">
+ <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
+ </ClCompile>
<ClCompile Include="..\project\business\GDN3.list.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">false</ExcludedFromBuild>
</ClCompile>
@@ -669,6 +675,7 @@
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">false</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="..\project\start.vframe.vbusiness.cpp" />
+ <ClCompile Include="..\project\total3\ViewTotalArgWin.cpp" />
<ClCompile Include="..\project\total3\ViewTotalWin.cpp" />
<ClCompile Include="..\project\tradedocument\DocFileSaveDlg.cpp" />
<ClCompile Include="..\project\tradedocument\DocSelectDlg.cpp" />
diff --git a/jrj/project/business/File/trade.document3.cpp b/jrj/project/business/File/trade.document3.cpp
index 6247ec0..f23fbc3 100644
--- a/jrj/project/business/File/trade.document3.cpp
+++ b/jrj/project/business/File/trade.document3.cpp
@@ -390,7 +390,6 @@
int OnTreeSelChanged(TEvent* evt, LPARAM p)
{
- xstring name;
lv_view.DeleteItemAll();
diff --git a/jrj/project/total3/ViewTotalArgWin.cpp b/jrj/project/total3/ViewTotalArgWin.cpp
new file mode 100644
index 0000000..a590612
--- /dev/null
+++ b/jrj/project/total3/ViewTotalArgWin.cpp
@@ -0,0 +1,137 @@
+#include <wobject/xstring.hpp>
+#include <xcontrol/xtreeview.hpp>
+#include <xcontrol/xdwgrid.hpp>
+
+#include "vbusiness/vframe/listwin.vframe.vbusiness.hpp"
+#include "viewobject/view.base.hpp"
+#include "vbusiness/vframe/frame.vframe.vbusiness.hpp"
+
+
+using xml = KXMLDOMDocument;
+ class __declspec(dllexport) ViewTotalArgWin : public xframe
+ {
+ public:
+ xdwtable dw_arg;
+ xaserverarg arg;
+ xnode m_agentNode; //Agent Condition
+ public:
+ ViewTotalArgWin(void* implPtr, HWND hWnd) :xframe(implPtr, hWnd) {}
+ public:
+ static ViewTotalArgWin* CreateInstance(void* implPtr, void* hWnd)
+ {
+ ViewTotalArgWin* pWin = new ViewTotalArgWin(implPtr, (HWND)hWnd);
+ return pWin;
+ }
+ /*int SetAgent()
+ {
+ string xfNodeAgentArea = L"agentarea";
+ xnode anode = GetAgentNode(xfNodeAgentArea);
+ if(m_agentNode)
+ {
+ SetAgentNodeContent (anode,m_agentNode);
+ }
+ else
+ {
+ msxml::IXMLDOMElement xframeElement = GetElement();
+ msxml::IXMLDOMElement agent = xframeElement.selectSingleNode(L"agent/"+xfNodeAgentArea+L"[1]/*");
+ if(agent)
+ {
+ string s = agent.xml;
+ m_agentNode = SetAgentNodeContent (anode,s);
+ }
+ }
+ return 1;
+ }*/
+
+ //焦点激活处理函数
+ int OnSetFocus(TEvent * evt, int param)
+ {
+ //重置工具条
+ //SetAgent();
+ return 1;
+ }
+
+ //命令发布函数
+ int OnCmdDispatch(string comdid)
+ {
+ if (comdid == L"xmOk")
+ {
+ xml x;
+
+ dw_arg.AcceptText();
+ dw_arg.DwUpdateAllTo(x);
+ //trace(L"--------" + x.xml());
+ arg.AddArg(L"arg", x.xml());
+ arg.AddArg(L"action", L"ok");
+ CloseWindow();
+
+ return 1;
+ }
+ else if (comdid == L"xmCancel")
+ {
+ arg.AddArg(L"action", L"cancel");
+ CloseWindow();
+ return 1;
+ }
+ return 0;
+ }
+
+ //命令处理事件
+ int OnXCommand(TEvent* evt, int param)
+ {
+ return OnCmdDispatch(evt->xcommand.pStrID);
+ }
+
+ int OnAttachEvent()
+ {
+ //绑定工具条点击事件
+ AttachEvent(L"WM_XCOMMAND", (FEvent)&ViewTotalArgWin::OnXCommand);
+ //获取焦点事件,用于重置工具条
+ AttachEvent(L"WM_SETFOCUS", (FEvent)&ViewTotalArgWin::OnSetFocus);
+ return 1;
+ }
+
+ int onload()
+ {
+ SetArg();
+ dw_arg = GetControl(L"dw_arg");
+
+ if (GetWinParam())
+ {
+ arg = GetArg();
+ string dw = arg.GetArgString(L"argurl");
+ dw_arg.openUrl(dw);
+
+ dw_arg.SetColHeaderHeight(0);
+ dw_arg.SetRowSelectorWidth(0);
+ dw_arg.SetHScrollState(false);
+ dw_arg.SetVScrollState(false);
+
+ string d = arg.GetArgString(L"arg");
+ if (d != L"")
+ {
+ xml x ;
+
+ x.loadXML(d);
+ dw_arg.Retrieve(x);
+ }
+ }
+ dw_arg.SetEditUpperMode(true);
+ dw_arg.SetItemString(1, L"QuoteSuccess/type", L"是");
+ dw_arg.SetItemString(1, L"ApprovalStatusName", L"6");
+ dw_arg.SetItemDisplayString(1, L"ApprovalStatusName", L"已审核");
+ dw_arg.SetItemString(1, L"GDN.ETD/type", L"日期范围");
+ dw_arg.SetItemString(1, L"QuoteSuccess/type", L"是");
+
+ OnAttachEvent();
+
+ return 1;
+ }
+
+ int onloaded()
+ {
+ //SetAgent();
+
+ return 1;
+ }
+ };
\ No newline at end of file
diff --git a/jrj/project/total3/ViewTotalWin.cpp b/jrj/project/total3/ViewTotalWin.cpp
index e8e4699..a94ff6b 100644
--- a/jrj/project/total3/ViewTotalWin.cpp
+++ b/jrj/project/total3/ViewTotalWin.cpp
@@ -15,11 +15,13 @@
{
public:
ViewTotalWin(void* implPtr, HWND hWnd) :xwin(implPtr, hWnd) {}
+public:
static ViewTotalWin* CreateInstance(void* implPtr, void* hWnd)
{
- return new ViewTotalWin(implPtr, (HWND)hWnd);
+ ViewTotalWin* pWin = new ViewTotalWin(implPtr, (HWND)hWnd);
+ return pWin;
}
-
+public:
xdwgrid dw_list;
xoffice dw_office;
xcell dw_cell;
--
Gitblit v1.9.3