public bool updateIformationByPoint(bean.deviceInformation di) { int ret = 0; String sql = "update lb_device_information set pointX='" + di.pointX + "',pointY='" + di.pointY + "' where measureCode='" + di.measureCode + "' and meterNo='" + di.meterNo + "'"; ret = DbHelperMySQL.ExecuteSql(sql); return(ret == 0 ? false : true); }
public bool updateAllIformationDao(bean.deviceInformation di) { int ret = 0; String sql = "update lb_device_information set t_high='" + di.t_high + "',t_low='" + di.t_low + "',h_high='" + di.h_high + "',h_low='" + di.h_low + "',State=1 where 1=1"; ret = DbHelperMySQL.ExecuteSql(sql); return(ret == 0 ? false : true); }
public bool queryDeviceBycode(bean.deviceInformation di) { int ret = 0; String sql = "SELECT count(1) FROM lb_device_information where measureCode='" + di.measureCode + "' and meterNo='" + di.meterNo + "'"; ret = DbHelperMySQL.ExecuteSql(sql); return(ret == -1 ? true : false); }
public bool deletetDeviceInformation(bean.deviceInformation di) { int ret = 0; String sql = "delete from lb_device_information where measureCode='" + di.measureCode + "' and meterNo='" + di.meterNo + "'"; ret = DbHelperMySQL.ExecuteSql(sql); return(ret == 0 ? false : true); }
public bool updateIformationDao(bean.deviceInformation di) { int ret = 0; String sql = ""; sql = "update lb_device_information set terminalname='" + di.terminalname + "',house_code='" + di.housecode + "',t_high='" + di.t_high + "',t_low='" + di.t_low + "',h_high='" + di.h_high + "',h_low='" + di.h_low + "',powerflag='" + di.powerflag + "',State=1 where measureCode='" + di.measureCode + "' and meterNo='" + di.meterNo + "'"; ret = DbHelperMySQL.ExecuteSql(sql); return(ret == 0 ? false : true); }
public bool insertDeviceInformation(bean.deviceInformation di) { string id = Result.GetNewId(); int flag = 0; string time = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); int ret = 0; String sql = "insert into lb_device_information (id,measureCode,meterNo,terminalname,house_code,housetype,t_high,t_low,h_high,h_low,powerflag,createtime) values ('" + id + "','" + di.measureCode + "', '" + di.meterNo + "', '" + di.terminalname + "', '" + di.housecode + "','" + 0 + "', '" + di.t_high + "', '" + di.t_low + "', '" + di.h_high + "', '" + di.h_low + "', '" + flag + "', '" + time + "')"; ret = DbHelperMySQL.ExecuteSql(sql); return(ret == 0 ? false : true); }
public bool updateAllIformation(bean.deviceInformation di) { return(deviceinfo.updateAllIformationDao(di)); }
public bool updateIformationByPoint(bean.deviceInformation di) { return(deviceinfo.updateIformationByPoint(di)); }
public bool deletetDeviceInformation(bean.deviceInformation di) { return(deviceinfo.deletetDeviceInformation(di)); }
public bool queryDeviceBycode(bean.deviceInformation di) { return(deviceinfo.queryDeviceBycode(di)); }
public bool insertDeviceInformation(bean.deviceInformation di) { return(deviceinfo.insertDeviceInformation(di)); }