From 7a91c3a1ed37b0332d4ff0ebeae60bd6da3665c0 Mon Sep 17 00:00:00 2001 From: xj qian <qianxj15@sina.com> Date: 星期二, 16 七月 2024 18:28:58 +0800 Subject: [PATCH] Merge branch 'master' of http://116.62.18.175:6699/r/mis-prj --- jrj/project/business/BasicCode/BrandInforMaint.cpp | 100 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 100 insertions(+), 0 deletions(-) diff --git a/jrj/project/business/BasicCode/BrandInforMaint.cpp b/jrj/project/business/BasicCode/BrandInforMaint.cpp new file mode 100644 index 0000000..5784bec --- /dev/null +++ b/jrj/project/business/BasicCode/BrandInforMaint.cpp @@ -0,0 +1,100 @@ +#include <wobject/xstring.hpp> +#include <xcontrol/xtreeview.hpp> +#include <xcontrol/xdwgrid.hpp> +#include <wobject/xdouble.hpp> +#include <xcontrol/xlayersheet.hpp> + +#include "vbusiness/vframe/listwin.vframe.vbusiness.hpp" +#include "viewobject/view.base.hpp" + +using xml = KXMLDOMDocument; +class __declspec(dllexport) BrandInforMaint : public xframe +{ +public: + + KXMLDOMDocument m_configDoc; + xstring m_userid; + xstring m_username; + xstring ContactID; + xdwtable dw_base; + xcell dw_cell; +public: + BrandInforMaint(void* implPtr, HWND hWnd) :xframe(implPtr, hWnd) {} +public: + static BrandInforMaint* CreateInstance(void* implPtr, void* hWnd) + { + BrandInforMaint* pWin = new BrandInforMaint(implPtr, (HWND)hWnd); + return pWin; + } + int alert(xstring str) + { + //win::MessageBox(GetHWND(),str,L"提示22:",0); + TApp::alert(this, str); + return 0; + } + int ViewUpdate(param pr, xstring updateItem, xaserverarg arg) + { + if (updateItem == L"update") + { + + dw_base.ResetUpdateStatus(); + return 1; + } + } + xstring GetEntityData(param pr) + { + xml x; + + dw_base.DwUpdateAllTo(x); + //trace(L"------x"); + trace(x.xml()); + return x.xml(); + } + int onload() + { + maint::onload(); + dw_base = new xdwtable; + dw_base.setNativePointer(GetControl(L"dw_base")); + + dw_base.SetColHeaderHeight(0); + dw_base.SetRowSelectorWidth(0); + + dw_base.SetScrollState(false); + + + /*if (!maint::m_EntityID) + { + //xstring suserid = publiccode::GetUser().id; + xstring suserid = xaserver::GetUserId(); + xstring susername = publiccode::GetUser().name; + xstring sdate = publiccode::GetCurrentDate(); + dw_base.SetItemString(dw_base.GetRow(),L"CreatorID",suserid);//Party + dw_base.SetItemDisplayString(dw_base.GetRow(),L"CreatorID",susername); + dw_base.SetItemString(dw_base.GetRow(),L"CreateDate",sdate); + xml x; + + xaserverarg arg; + + arg.AddArg(L"id", suserid); + if(xaserver::ExecXQuery(L"",L"[OrgInfo.xq]",arg.GetString(),x)!=1) + { + trace(x.xml()); + return nil; + } + //alert(x.xml()); + KXMLDOMElement e= x.documentElement(); + trace(e.xml); + if(e.selectSingleNode(L"orgid")) + { + xstring orgid= e.selectSingleNode(L"orgid").text(); + dw_base.SetItemString(1,L"OrgID",orgid); + } + + if(e.selectSingleNode(L"orgname")) + { + xstring orgname = e.selectSingleNode(L"orgname").text(); + dw_base.SetItemDisplayString(1,L"OrgID",orgname); + } + }*/ + } +}; \ No newline at end of file -- Gitblit v1.9.3