From 3a3137b405af9728f9a7e4d7ee725498d0e8ecb7 Mon Sep 17 00:00:00 2001
From: xj qian <qianxj15@sina.com>
Date: 星期四, 18 七月 2024 09:25:10 +0800
Subject: [PATCH] system module

---
 jrj/project/business/BasicCode/FCL.cpp |   24 +++++++++---------------
 1 files changed, 9 insertions(+), 15 deletions(-)

diff --git a/jrj/project/business/BasicCode/FCL.cpp b/jrj/project/business/BasicCode/FCL.cpp
index c612560..afa9bc1 100644
--- a/jrj/project/business/BasicCode/FCL.cpp
+++ b/jrj/project/business/BasicCode/FCL.cpp
@@ -8,7 +8,7 @@
 #include "viewobject/view.base.hpp"
 
 using xml = KXMLDOMDocument;
-class __declspec(dllexport) FCL : public xframe
+class __declspec(dllexport) FCL : public listwin
 {
 public:
 	xcombobox ddlb_1;
@@ -23,7 +23,7 @@
 	xstring m_config;
 	xstring m_spec;
 public:
-	FCL(void* implPtr, HWND hWnd) :xframe(implPtr, hWnd) {}
+	FCL(void* implPtr, HWND hWnd) :listwin(implPtr, hWnd) {}
 public:
 	static FCL* CreateInstance(void* implPtr, void* hWnd)
 	{
@@ -85,11 +85,11 @@
 	}
 	int SetCellEdit(int row, xstring name, xstring value, xstring display)
 	{
-		dw_base.SetItemString(row, name, value);
+		dw_base.SetItemString(row, name.c_str(), value);
 		dw_base.Redraw();
 		if (display != L"")
 		{
-			dw_base.SetItemDisplayString(row, name, display);
+			dw_base.SetItemDisplayString(row, name.c_str(), display);
 		}
 		dw_base.AcceptText();
 		dw_base.ResetUpdateStatus();
@@ -101,10 +101,10 @@
 		dw_base.AcceptText();
 		SetPriceBaseEmpty();
 		KXMLDOMElement e = dw_list.GetRowElement(row);
-		var list = e.selectNodes(L"*");
+		auto list = e.selectNodes(L"*");
 		if (list)
 		{
-			int s = list.length;
+			int s = list.length();
 			int i;
 			for (i = 0; i < s; i++)
 			{
@@ -243,17 +243,9 @@
 
 		dw_list.DwUpdateAllToEx(x);
 		trace(x.xml());
+		return 1;
 	}
-	int OnDeleteRow()
-	{
-		int row = dw_list.GetRow();
-		if (row<1 || row>dw_list.GetRowCount())
-		{
-			return -1;
-		}
-		dw_list.DeleteRow(row);
 
-	}
 	int OnAddrow()
 	{
 		int row = dw_list.InsertRow(0);
@@ -270,6 +262,7 @@
 		SetPriceBaseEmpty();
 		return 1;
 	}
+
 	int OnDeleteRow()
 	{
 		int row = dw_list.GetRow();
@@ -280,6 +273,7 @@
 		}
 		return 1;
 	}
+
 	int OnCmdDispatch(xstring comdid)
 	{
 		if (comdid.find(L"add", 0) >= 0)

--
Gitblit v1.9.3