| | |
| | | #include <xcontrol/xdwgrid.hpp> |
| | | #include <wobject/xdouble.hpp> |
| | | #include <xcontrol/xlayersheet.hpp> |
| | | #include <xcontrol/xcell.hpp> |
| | | |
| | | #include "vbusiness/vframe/listwin.vframe.vbusiness.hpp" |
| | | #include "vbusiness/vframe/maint.vframe.vbusiness.hpp" |
| | | #include "viewobject/view.base.hpp" |
| | | |
| | | using xml = KXMLDOMDocument; |
| | | class __declspec(dllexport) TestingCompanyMaint : public xframe |
| | | class __declspec(dllexport) TestingCompanyMaint : public maint |
| | | { |
| | | public: |
| | | KXMLDOMDocument m_configDoc; |
| | |
| | | xstring ContactID; |
| | | xdwtable dw_base; |
| | | xcell dw_cell; |
| | | xstring m_EntityID = L""; |
| | | public: |
| | | TestingCompanyMaint(void* implPtr, HWND hWnd) :xframe(implPtr, hWnd) {} |
| | | TestingCompanyMaint(void* implPtr, HWND hWnd) :maint(implPtr, hWnd) {} |
| | | public: |
| | | static TestingCompanyMaint* CreateInstance(void* implPtr, void* hWnd) |
| | | { |
| | | TestingCompanyMaint* pWin = new TestingCompanyMaint(implPtr, (HWND)hWnd); |
| | | return pWin; |
| | | } |
| | | int alert(xstring str) |
| | | { |
| | | //win::MessageBox(GetHWND(),str,L"提示22:",0); |
| | | TApp::alert(this, str); |
| | | return 0; |
| | | } |
| | | |
| | | int setCellReadOnly() |
| | | { |
| | | dw_base = new xdwtable; |
| | |
| | | return publiccode::GetGuid(); |
| | | } |
| | | int OnClear() { |
| | | //alert(m_EntityID); |
| | | if (m_EntityID == L"") { |
| | | m_userid = publiccode::GetUser().id; |
| | | |
| | | m_userid = publiccode::GetUser().personid; |
| | | m_username = publiccode::GetUser().name; |
| | | dw_base = new xdwtable; |
| | | dw_base.setNativePointer(GetControl(L"dw_base")); |
| | | /*dw_base = new xdwtable; |
| | | dw_base.setNativePointer(GetControl(L"dw_base"));*/ |
| | | dw_base = GetControl(L"dw_base"); |
| | | dw_base.SetItemString(1, L"PartyID", GetGuid()); |
| | | dw_base.SetItemString(1, L"PStatus", L"1"); |
| | | dw_base.SetItemDisplayString(1, L"PStatus", L"有效"); |
| | |
| | | dw_base.SetItemString(1, L"EnterName", m_userid); |
| | | dw_base.SetItemDisplayString(1, L"EnterName", m_username); |
| | | dw_base.SetItemString(1, L"CreateDate", publiccode::GetCurrentDate()); |
| | | |
| | | return 0; |
| | | } |
| | | else |
| | | { |
| | |
| | | if (aName == L"" ) |
| | | { |
| | | aTemp = dwcon.GetItemString(i, L"Mobile") + dwcon.GetItemString(i, L"TEL") + dwcon.GetItemString(i, L"Fax") + dwcon.GetItemString(i, L"Email") + dwcon.GetItemString(i, L"PCRemark"); |
| | | trace(aTemp); |
| | | if (aTemp != L"") |
| | | //alert(aTemp); |
| | | if (aTemp == L"") |
| | | { |
| | | alert(L"联系人名称必填!"); |
| | | return -1; |
| | |
| | | |
| | | args.AddArg(L"CSpec", cspec); |
| | | args.AddArg(L"SpecRule", SpecRule); |
| | | xml x = new xml; |
| | | xml x; |
| | | |
| | | getUrl(L"/sale/data/LogisticsCode/pref/forwarderno/check", args.GetString(), x); |
| | | if (x.selectSingleNode(L"root/spec")) |
| | |
| | | |
| | | int onload() |
| | | { |
| | | |
| | | SetArg(); |
| | | OnAttachEvent(); |
| | | //if(!m_configDoc) return -1; |
| | | |
| | | maint::onload(); |
| | | |
| | | OnClear(); |
| | | |
| | | return 1; |
| | | } |
| | | |
| | | int onloaded() |
| | | { |
| | | return maint::onloaded(); |
| | | } |
| | | |
| | | }; |