From bb4dc0fab56e542e784311f95ae6d7e7dd785a8f Mon Sep 17 00:00:00 2001
From: xj qian <qianxj15@sina.com>
Date: 星期二, 29 十月 2024 17:10:33 +0800
Subject: [PATCH] update
---
jrj/project/business/Affair/Business5.cpp | 688 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 688 insertions(+), 0 deletions(-)
diff --git a/jrj/project/business/Affair/Business5.cpp b/jrj/project/business/Affair/Business5.cpp
new file mode 100644
index 0000000..0441872
--- /dev/null
+++ b/jrj/project/business/Affair/Business5.cpp
@@ -0,0 +1,688 @@
+#include <wobject/xstring.hpp>
+#include <xcontrol/xtreeview.hpp>
+#include <xcontrol/xdwgrid.hpp>
+#include <xcontrol/xcell.hpp>
+
+
+#include "vbusiness/vframe/listwin.vframe.vbusiness.hpp"
+#include "viewobject/view.base.hpp"
+
+using xml = KXMLDOMDocument;
+
+ class __declspec(dllexport) Business5Win : public xframe
+ {
+ public:
+ xdwgrid dw_list;
+ xdwgrid dw_processed;
+ xdwgrid dw_message;
+ xdwgrid dw_outbox;
+ xdwgrid dw_Recovery;
+ xnode m_agentNode; //Agent Condition
+ xtreeview tv_folder;
+
+ int hMessage;
+ int hTask;
+
+ xstring agentFor;
+ xstring selectname;
+ xwin sheet;
+
+ public:
+ Business5Win(void* implPtr, HWND hWnd) :xframe(implPtr, hWnd) {}
+ public:
+ static Business5Win* CreateInstance(void* implPtr, void* hWnd)
+ {
+ Business5Win* pWin = new Business5Win(implPtr, (HWND)hWnd);
+ return pWin;
+ }
+
+ int SetAgent()
+ {
+ xstring xfNodeAgentArea = L"agentarea";
+ xnode anode = GetAgentNode(xfNodeAgentArea);
+ if(m_agentNode)
+ {
+ SetAgentNode (anode,m_agentNode);
+ }
+ else
+ {
+ KXMLDOMElement xframeElement = GetElement();
+ KXMLDOMElement agent = xframeElement.selectSingleNode(L"agent/"+xfNodeAgentArea+L"[@for='"+agentFor+L"']/*");
+ if(agent)
+ {
+ xstring s = agent.xml();
+ m_agentNode = SetAgentNode (anode,s);
+ //FillGoodsCarList();
+ }
+ }
+ return 1;
+ }
+
+ //焦点激活处理函数
+ int OnSetFocus(TEvent* evt, LPARAM param)
+ {
+ //重置工具条
+ SetAgent();
+ return 1;
+ }
+ int RetrieveData()
+ {
+ xml x;
+ if(selectname == L"已处理任务")
+ {
+ x = ViewObject::RetrieveData(L"/sale/data/business/list/processedtask");
+ dw_processed.Retrieve(x);
+ dw_processed.Redraw();
+ dw_processed.SetReadOnly(true);
+ }else if(selectname == L"收件箱")
+ {
+ xstring UserNO= publiccode::GetUser().no;
+
+ x = ViewObject::RetrieveData(L"/sale/data/business/list/inbox");
+
+ dw_message.Retrieve(x);
+ dw_message.Redraw();
+ dw_message.SetReadOnly(true);
+ }
+ else if(selectname == L"发件箱")
+ {
+ x = ViewObject::RetrieveData(L"/sale/data/business/list/outbox");
+ dw_outbox.Retrieve(x);
+ dw_outbox.Redraw();
+ dw_outbox.SetReadOnly(true);
+ }
+ else if(selectname == L"回收箱")
+ {
+ x = ViewObject::RetrieveData(L"/sale/data/business/list/Recovery");
+ dw_Recovery.Retrieve(x);
+ dw_Recovery.Redraw();
+ dw_Recovery.SetReadOnly(true);
+ }
+ AdjustTip();
+ return 1;
+ }
+ int OnDelete()
+ {
+ int MB_OKCANCEL = 1;
+ int IDOK = 1;
+ int ret =MessageBox(GetHWND(),L"确认删除消息?",L"提示",MB_OKCANCEL);
+ if(ret == IDOK)
+ {
+ KXMLDOMElement ele = dw_message.GetRowElement(dw_message.GetRow());
+ xstring TaskID = ele.getAttribute(L"guid");
+ xml x = ViewObject::RetrieveData(L"/sale/data/business/message/delete",L"TaskID",TaskID);
+ xstring status = x.xml();
+ if(status.find(L"ok") == 1)
+ {
+ alert(L"删除成功");
+ RetrieveData();
+ }else
+ {
+ alert(L"删除失败");
+ }
+
+ }
+ return 1;
+ }
+
+ int OnUpdateRecovery()
+ {
+ int MB_OKCANCEL = 1;
+ int IDOK = 1;
+ int ret =MessageBox(GetHWND(),L"确认恢复消息?",L"提示",MB_OKCANCEL);
+ if(ret == IDOK)
+ {
+ KXMLDOMElement ele = dw_Recovery.GetRowElement(dw_Recovery.GetRow());
+ xstring TaskID = ele.getAttribute(L"guid");
+ xml x = ViewObject::RetrieveData(L"/sale/data/business/Recovery/UpdateRecovery",L"TaskID",TaskID);
+ xstring status = x.xml();
+ if(status.find(L"ok") == 1)
+ {
+ alert(L"恢复成功");
+ RetrieveData();
+ }else
+ {
+ alert(L"恢复失败");
+ }
+
+ }
+ return 1;
+ }
+
+ int OnDeleteRecovery()
+ {
+ int MB_OKCANCEL = 1;
+ int IDOK = 1;
+ int ret =MessageBox(GetHWND(),L"确认彻底删除消息?",L"提示",MB_OKCANCEL);
+ if(ret == IDOK)
+ {
+ KXMLDOMElement ele = dw_Recovery.GetRowElement(dw_Recovery.GetRow());
+ xstring TaskID = ele.getAttribute(L"guid");
+ xml x = ViewObject::RetrieveData(L"/sale/data/business/Recovery/DeleteRecovery",L"TaskID",TaskID);
+ xstring status = x.xml();
+ if(status.find(L"ok") == 1)
+ {
+ alert(L"删除成功");
+ RetrieveData();
+ }else
+ {
+ alert(L"删除失败");
+ }
+
+ }
+ return 1;
+ }
+
+ int OnAdd()
+ {
+ OpenWindow(L"dev:xpage[message.business.vx]");
+ if(selectname == L"发件箱" || selectname == L"草稿箱") RetrieveData();
+ return 1;
+ }
+
+
+ //命令发布函数
+ int OnCmdDispatch(xstring comdid)
+ {
+ int ret = 0;
+ if(comdid.find(L"action:",0)>=0)
+ {
+ ret =SendMessage(GetHWND(),0x401,(LPARAM)comdid,0);
+ }
+ if(comdid==L"xmRefreshTask")
+ {
+ trace(L"\r\n----refresh task--------");
+ SendMessage(GetHWND(),0x401,(LPARAM)comdid,0);
+ return 1;
+ }
+ if(comdid==L"xmRefresh")
+ {
+ trace(L"\r\n----refresh--------");
+ ret =SendMessage(GetHWND(),0x401, (LPARAM)comdid,0);
+ }
+ if(comdid == L"xmRertieve")
+ {
+ RetrieveData();
+ ret = 1;
+ }
+ if(comdid==L"xmAdd")
+ {
+ OnAdd();
+ ret = 1;
+ }
+ if(comdid == L"xmDelete")
+ {
+ OnDelete();
+ ret = 1;
+ }
+ if(comdid == L"UpdateRecovery")
+ {
+ OnUpdateRecovery();
+ ret = 1;
+ }
+ if(comdid == L"DeleteRecovery")
+ {
+ OnDeleteRecovery();
+ ret = 1;
+ }
+ if(comdid == L"xmImage")
+ {
+ int row = dw_message.GetRow();
+ xstring PriceID = dw_message.GetItemString(row,L"EntityID");
+ xml x = ViewObject::RetrieveData(L"/sale/data/Enquiry/PriceList/GetSkunoByPriceID",L"PriceID",PriceID);
+ KXMLDOMNodeList items = x.selectNodes(L"data/Item");
+ KXMLDOMNode t = items.item(0);
+ xstring skunos = t.selectSingleNode(L"skuno").text();
+ xaserverarg arg_pic;
+
+ arg_pic.AddArg(L"SKUNoList",skunos);
+#if 0
+ arg_pic.AddArg(L"ParentWindow", GetHWND());
+#endif // 0
+
+
+
+ arg_pic.AddArg(L"OpenFlag",L"1");
+ OpenWindow(L"dev:xpage[SKU.PictureView.Product3.vx]",arg_pic );
+ return 1;
+ }
+ else if(comdid == L"xmSearchOne")
+ {
+ OnSearchOne();
+ return 1;
+ }
+ else if(comdid == L"xmSearchTwo")
+ {
+ OnSearchTwo();
+ return 1;
+ }
+ else if(comdid==L"Lognew")
+ {
+ xstring EntityID = dw_processed.GetItemString(dw_processed.GetRow(),L"EntityID");
+ //alert(EntityID);
+
+ xaserverarg args;
+
+ args.AddArg(L"EntityID",EntityID);
+ //OpenWindow(L"dev:xpage[workflow.actionlog.vx]",cast(args as int));
+ OpenWindow(L"dev:xpage[workflow.actionlog_vd.vx]",args);
+
+
+
+ }
+ return ret;
+ }
+
+
+ int OnSearchOne()
+ {
+ xstring searchStr=L"";
+ xaserverarg arg;
+
+ arg.AddArg(L"text", searchStr);
+ OpenWindow(L"dev:xpage[search.dialog.vx]", arg);
+ xstring str = arg.GetArgString(L"text");
+ if(str != searchStr)
+ {
+ searchStr = str;
+ dw_message.Filter(L"*",searchStr);
+ return 1;
+ }
+ return 1;
+ }
+
+ int OnSearchTwo()
+ {
+ xstring searchStr=L"";
+ xaserverarg arg;
+
+ arg.AddArg(L"text", searchStr);
+ OpenWindow(L"dev:xpage[search.dialog.vx]", arg);
+ xstring str = arg.GetArgString(L"text");
+ if(str != searchStr)
+ {
+ searchStr = str;
+ dw_Recovery.Filter(L"*",searchStr);
+ return 1;
+ }
+ return 1;
+ }
+
+ //命令处理事件
+ int OnXCommand(TEvent* evt, LPARAM param)
+ {
+ return OnCmdDispatch(evt->xcommand.pStrID);
+ }
+
+
+ //查找当前树项的顶级目录
+ HTREEITEM LookupTopFolder(HTREEITEM hItem)
+ {
+ HTREEITEM hRoot = tv_folder.GetRootItem();
+ while (tv_folder.GetParentItem(hItem)) hItem = tv_folder.GetParentItem(hItem);
+ return hItem;
+ }
+
+ int ResetAgent(xstring agentAsk)
+ {
+ if(agentFor != agentAsk)
+ {
+ agentFor = agentAsk;
+ m_agentNode = 0;
+ SetAgent();
+ }
+ return 1;
+ }
+
+ int OnTreeSelChanged(TEvent* evt, LPARAM p)
+ {
+ NMTREEVIEW& nmtv = *(NMTREEVIEW*)evt->notify.pnmh;
+ HTREEITEM hItem = nmtv.itemNew.hItem;
+ HTREEITEM hTopItem = LookupTopFolder(hItem);
+
+ xstring data = tv_folder.GetItemData(hItem);
+ trace(L"\r\n"+data);
+ //KXMLDOMElement e = cast(tv_folder.GetItemData(hItem) as KXMLDOMElement);
+ //if(e)trace(e.xml());
+
+ xstring name = tv_folder.GetItemLabel(hTopItem);
+ selectname = tv_folder.GetItemLabel(hItem);
+ if(selectname == L"待处理任务")
+ {
+ SwitchLayer(L"sheet2",L"frame");
+ sheet = GetChildWin(L"sheet2");
+ ResetAgent(L"business1");
+ }else if(selectname == L"已处理任务")
+ {
+ SwitchLayer(L"sheet3",L"frame");
+ RetrieveData();
+ ResetAgent(L"business2");
+ }else if(selectname == L"收件箱")
+ {
+ SwitchLayer(L"sheet4",L"frame");
+ RetrieveData();
+ ResetAgent(L"business3");
+ }else if(selectname == L"发件箱")
+ {
+ SwitchLayer(L"sheet5",L"frame");
+ RetrieveData();
+ ResetAgent(L"business2");
+ }
+ else if(selectname == L"事务")
+ {
+ SwitchLayer(L"sheet1",L"frame");
+ }else if(selectname == L"回收箱")
+ {
+ SwitchLayer(L"sheet6",L"frame");
+ RetrieveData();
+ ResetAgent(L"business5");
+ }
+ return 1;
+ }
+ int OnRowChanged(TEvent* evt, int p)
+ {
+ //fixed one event only one process
+ DWNMHDR& hdr = *(DWNMHDR*)evt->notify.pnmh;
+ int row = hdr.row;
+ KXMLDOMElement ele;
+ if(selectname == L"已处理任务")
+ ele = dw_processed.GetRowElement(row);
+ else if(selectname == L"收件箱")
+ {
+ ele = dw_message.GetRowElement(row);
+ xstring Subject = dw_message.GetItemString(row,L"Subject");
+ if(Subject.find(L"价格单") == -1)
+ {
+ ResetAgent(L"business3");
+ }else{
+ ResetAgent(L"business4");
+ }
+ }
+ else if(selectname == L"回收箱")
+ {
+ ele = dw_Recovery.GetRowElement(row);
+ xstring SubjectOne = dw_Recovery.GetItemString(row,L"Subject");
+ }
+ else if(selectname == L"发件箱")
+ ele = dw_outbox.GetRowElement(row);
+ xaserverarg arg;
+
+ trace(ele.xml());
+ arg.AddArg(L"content",ele.xml());
+ xml doc=new xml;
+ if(getUrl(L"/sale/data/vpage/vstart/task",arg.GetString(),doc)!=1)
+ {
+ trace((xstring)L"error->:"+doc.xml());
+ return 0;
+ }
+ if(doc.xml() == L"")
+ return -1;
+ //trace(doc.xml());
+ htmlctrl ht = GetControl(L"taskinfo");
+ ht.SetContent(doc.xml());
+ ht.Redraw();
+ return 1;
+ }
+ int OnItemAskStyle(TEvent* evt, int p)
+ {
+ int DMS_CSSSTYLE = 0x8;
+ ref DWASKSTYLENMHDR hdr = trust(evt.pnmh as ref DWASKSTYLENMHDR);
+ int row = hdr.row;
+ int col = hdr.col;
+ xstring colname = hdr.colname;
+ int rows = dw_message.GetRowCount();
+ if(row < 1 || row > rows)
+ {
+ return 1;
+ }
+ if(colname==L"flowName" || colname==L"Process" || colname==L"sender" ||
+ colname==L"SendDate"||colname==L"processer"||colname==L"ProcessedDate"||
+ colname==L"Subject"||colname==L"Content")
+ {
+ xstring ReadedFlag = dw_message.GetItemString(row,L"ReadedFlag");
+ if(ReadedFlag != L"Y")
+ {
+ hdr.mask = DMS_CSSSTYLE;
+ //hdr.cssstyle = L"color:#cccccc";
+ hdr.cssstyle = L"font-weight:700";
+
+ }
+ }
+
+ return 1;
+ }
+
+ int OnDWClick(TEvent* evt, int p)
+ {
+ xstring UserNO=publiccode::GetUser().no;
+ if(UserNO !=L"00701")
+ {
+ DWNMHDR& hdr = *(DWNMHDR*)evt->notify.pnmh;
+ xstring value = hdr.data;
+ xstring colname = hdr.colname;
+ int row = hdr.row;
+ KXMLDOMElement ele = dw_message.GetRowElement(row);
+ xstring TaskID = ele.getAttribute(L"guid");
+ xstring ReadedFlag = dw_message.GetItemString(row,L"ReadedFlag");
+ xstring flowName = dw_message.GetItemString(row,L"flowName");
+ if(ReadedFlag != L"Y")
+ {
+ xml x = ViewObject::RetrieveData(L"/sale/data/business/message/read",L"TaskID",TaskID);
+ dw_message.SetItemString(row,L"ReadedFlag",L"Y");
+ if(ReadedFlag != L"Y" && flowName == L"价格单共享")
+ {
+ xml x1 = ViewObject::RetrieveData(L"/sale/data/business/Recovery/MessageStatus",L"TaskID",TaskID);
+ }
+ dw_message.Redraw();
+ //RetrieveData();
+ }
+ AdjustTip();
+ }
+ return 1;
+ }
+
+ int OpenShowroom1(TEvent* evt, int p)
+ {
+ DWNMHDR& hdr = *(DWNMHDR*)evt->notify.pnmh;
+ xstring value = hdr.data;
+ xstring colname = hdr.colname;
+ int row = hdr.row;
+ KXMLDOMElement ele = dw_outbox.GetRowElement(row);
+ xstring TaskID = ele.getAttribute(L"guid");
+ xstring Category = dw_outbox.GetItemString(row,L"flowName");
+ if(Category==L"普通"){
+ xaserverarg arg2;
+
+ if(dw_outbox.GetRowCount() < 1) return 1;
+ KXMLDOMElement ele1 = dw_outbox.GetRowElement(dw_outbox.GetRow());
+ arg2.AddArg(L"EntityID",dw_outbox.GetItemString(dw_outbox.GetRow(),L"EntityID"));
+ arg2.AddArg(L"id",ele1.getAttribute(L"guid"));
+ OpenWindow(L"dev:xpage[message.business.vx]",arg2);
+ return 1;
+ }
+ return 1;
+ }
+
+ int OpenShowroom(TEvent* evt, int p)
+ {
+ DWNMHDR& hdr = *(DWNMHDR*)evt->notify.pnmh;
+ xstring value = hdr.data;
+ xstring colname = hdr.colname;
+ int row = hdr.row;
+ KXMLDOMElement ele = dw_message.GetRowElement(row);
+ xstring TaskID = ele.getAttribute(L"guid");
+ xstring Category = dw_message.GetItemString(row,L"Category");
+ if(Category==L"货号申请"){
+ int p1 ;
+ OpenWindow(L"dev:xpage[UserProductApply.vx]", p1);
+ }
+ if(Category==L"普通"){
+ xaserverarg arg2;
+
+ if(dw_message.GetRowCount() < 1) return 1;
+ KXMLDOMElement ele1 = dw_message.GetRowElement(dw_message.GetRow());
+ arg2.AddArg(L"EntityID",dw_message.GetItemString(dw_message.GetRow(),L"EntityID"));
+ arg2.AddArg(L"id",ele1.getAttribute(L"guid"));
+ OpenWindow(L"dev:xpage[message.business.vx]", arg2);
+ return 1;
+ }
+ else if(Category==L"报价单共享")
+ {
+ if(dw_message.GetRowCount() < 1) return 1;
+ xstring No = dw_message.GetItemString(dw_message.GetRow(),L"No");
+ OpenWindow(L"dev:xpage[EnquiryEx.quote.vx]",cast(No as int));
+ }
+ if(Category==L"SupplierV3")
+ {
+ xaserverarg arg;
+
+ if(dw_message.GetRowCount() < 1) return 1;
+ arg.AddArg(L"EntityID",dw_message.GetItemString(dw_message.GetRow(),L"EntityID"));
+ //OpenWindow(L"dev:xpage[maint.Owner.Supplier.v3.vx]",cast(arg as int));
+ arg.AddArg(L"config",L"/sale/view/SupplierV3/config/supplier/open");
+ OpenWindow(L"dev:xpage[maintex.Owner.Supplier.v3.vx]",arg);
+ }
+ if(Category==L"供应商回退")
+ {
+ xaserverarg arg1;
+
+ if(dw_message.GetRowCount() < 1) return 1;
+ arg1.AddArg(L"EntityID",dw_message.GetItemString(dw_message.GetRow(),L"EntityID"));
+ OpenWindow(L"dev:xpage[maint.Owner.Supplier.v3.vx]",arg1);
+ }
+ return 1;
+ }
+ int OnAttachEvent()
+ {
+ //绑定工具条点击事件
+ AttachEvent(L"WM_XCOMMAND", (FEvent)&Business5Win::OnXCommand);
+ //获取焦点事件,用于重置工具条
+ AttachEvent(L"WM_SETFOCUS", (FEvent)&Business5Win::OnSetFocus);
+ //树选择
+ AttachEvent(L"tv_folder", L"TVN_SELCHANGED", (FEvent)&Business5Win::OnTreeSelChanged);
+ AttachEvent(L"dw_processed",L"DWV_ROWFOCUSCHANGED", (FEvent)&Business5Win::OnRowChanged);
+ AttachEvent(L"dw_message",L"DWV_ROWFOCUSCHANGED", (FEvent)&Business5Win::OnRowChanged);
+ AttachEvent(L"dw_outbox",L"DWV_ROWFOCUSCHANGED", (FEvent)&Business5Win::OnRowChanged);
+ AttachEvent(L"dw_Recovery",L"DWV_ROWFOCUSCHANGED", (FEvent)&Business5Win::OnRowChanged);
+ AttachEvent(L"dw_message",L"DWV_ASKSTYLE", (FEvent)&Business5Win::OnItemAskStyle);
+ AttachEvent(L"dw_message",L"DWV_CLICKED", (FEvent)&Business5Win::OnDWClick);
+ AttachEvent(L"dw_message",L"DWV_DOUBLECLICKED", (FEvent)&Business5Win::OpenShowroom);
+ AttachEvent(L"dw_outbox",L"DWV_DOUBLECLICKED", (FEvent)&Business5Win::OpenShowroom1);
+
+ return 1;
+ }
+
+
+ int OnRetrieve()
+ {
+
+ return 1;
+ }
+
+ int InitialFolder()
+ {
+ KXMLDOMElement xframeElement = GetElement();
+ KXMLDOMElement e = xframeElement.selectSingleNode(L"//xtree[@name='tv_folder']/initial");
+
+ //KXMLDOMElement e = xframeElement.selectSingleNode(L"//xtree[@name='tv_folder']/data/item[@name='"+L"']");
+ //trace(e.xml());
+ if(e)
+ ExpandChildFolder(0,e);
+ return 1;
+ }
+
+ int ExpandChildFolder(int hItem, KXMLDOMElement pElement)
+ {
+ KXMLDOMNodeList nlist = pElement.selectNodes(L"Item");
+ int len = nlist.length();
+ for (int i = 0; i < len; i++)
+ {
+ KXMLDOMElement e = nlist.item(i);
+ xstring name = e.getAttribute(L"name");
+ xstring sImage = e.getAttribute(L"image");
+ xstring child = e.getAttribute(L"child");
+ int image = 15;
+ if(sImage) image = sImage.toInt();
+ int h= tv_folder.InsertChildItem(tv_folder.GetId(),hItem,name, trust(e as int),image);
+ if(child !=L"no" ) tv_folder.SetItemChild(h,1);
+ ExpandChildFolder(h,e);
+ }
+ return 1;
+ }
+
+ int AdjustTip()
+ {
+ xml x = ViewObject::RetrieveData(L"/sale/data/business/list/AdjustTipNotify");
+ KXMLDOMNodeList nlist = x.selectNodes(L"/data/Item");
+ KXMLDOMNode t = nlist.item(0);
+ xstring informationQuantity =t.selectSingleNode(L"informationQuantity").text();
+ tv_folder.SetItemLabel(hMessage, L"消息"+L"(L"+informationQuantity+L")L");
+
+ xml x1 = ViewObject::RetrieveData(L"/sale/data/business/list/AdjustTipTask");
+ //alert(x1.xml());
+ KXMLDOMNodeList nlist1 = x1.selectNodes(L"/data/Item");
+ KXMLDOMNode t1= nlist1.item(0);
+ xstring informationQuantityTask =t1.selectSingleNode(L"informationQuantityTask").text();
+ tv_folder.SetItemLabel(hTask, L"任务"+L"(L"+informationQuantityTask+L")L");
+
+ /*select count(*) from bpm_task where typ='notify' and process='N'
+ and charindex('|'+'00303'+'|','|' + rtrim(receiver) +'|')>=1*/
+ return 1;
+ }
+
+ int onload()
+ {
+ agentFor = L"business";
+ OnAttachEvent();
+ dw_list = GetControl(L"dw_list");
+ dw_processed = GetControl(L"dw_processed");
+ dw_processed.openUrl(L"/sale/view/Business3/template/processedtask");
+ dw_processed.SetColumnState(L"EntityID",false);
+ dw_processed.SetColumnState(L"Category",false);
+
+ dw_message = GetControl(L"dw_message");
+ dw_message.openUrl(L"/sale/view/Business3/template/message");
+ dw_message.SetAskStyle(true);
+ dw_message.SetColumnState(L"EntityID",false);
+ dw_message.SetColumnState(L"Category",false);
+ dw_message.SetColumnState(L"ReadedFlag",false);
+
+ dw_outbox = GetControl(L"dw_outbox");
+ dw_outbox.openUrl(L"/sale/view/Business3/template/outbox");
+ dw_outbox.SetColumnState(L"EntityID",false);
+
+ dw_Recovery = GetControl(L"dw_Recovery");
+ dw_Recovery.openUrl(L"/sale/view/Business3/template/message");
+ dw_Recovery.SetColumnState(L"EntityID",false);
+ dw_Recovery.SetColumnState(L"Category",false);
+ dw_Recovery.SetColumnState(L"ReadedFlag",false);
+ dw_Recovery.SetColumnState(L"No",false);
+
+
+ tv_folder = GetControl(L"tv_folder");
+ tv_folder.SetLineAtRoot(true);
+ sheet = GetChildWin(L"sheet1");
+
+ int hItem = tv_folder.GetRootItem();
+ tv_folder.ExpandItem(hItem);
+ int hcItem =tv_folder.GetChildItem(hItem);
+ hTask = hcItem;
+ tv_folder.ExpandItemAll(hcItem);
+ tv_folder.ItemFocus(tv_folder.GetChildItem(hcItem));
+ hcItem = tv_folder.GetNextItem(hcItem);
+ hMessage = hcItem;
+ tv_folder.ExpandItemAll(hcItem);
+
+ AdjustTip();
+
+ return 1;
+ }
+
+ int onloaded()
+ {
+ SetAgent();
+
+
+ return 1;
+ }
+ };
\ No newline at end of file
--
Gitblit v1.9.3