$chConfigObj = new ChannelConfiguration(); $chConfigObj->setFolderSeq($selSeq); $chConfigObj->setChannelStatusFlag(1); } if (!$chConfigObj) { continue; } $chNo = $_POST["chno" . $count]; $chName = $_POST["chName" . $count]; $chUnit = $_POST["chUnit" . $count]; $chSubStation = $_POST["substation" . $count]; $prescribedLimit = $_POST["prescribedlimit" . $count]; $chConfigObj->setChannelName($chName); $chConfigObj->setChannelNumber($chNo); $chConfigObj->setChannelUnit($chUnit); $chConfigObj->setChannelStation($chSubStation); if (empty($prescribedLimit)) { $prescribedLimit = 0; } $chConfigObj->setPrescribedLimit($prescribedLimit); if (!empty($chseq)) { $channlConfigs[intval($chseq)] = $chConfigObj; } else { array_push($channlConfigs, $chConfigObj); } if (!empty($chNo)) { if (!in_array($chNo, $chNoArr)) { array_push($chNoArr, $chNo); } else { array_push($dupNoChArr, $chNo); }
public function populateObject($rsItem) { $seq_ = $rsItem["configseq"]; $folderSeq_ = $rsItem["folderseq"]; $channelNumber_ = $rsItem["channelnumber"]; $channelName_ = $rsItem["channelname"]; $channelStatusFlag_ = $rsItem["channelstatusflag"]; $channelUnit_ = $rsItem["channelunit"]; $channelStation_ = $rsItem["channelstation"]; $prescribedLimit_ = $rsItem["prescribedlimit"]; $cc = new ChannelConfiguration(); $cc->setSeq($seq_); $cc->setFolderSeq($folderSeq_); $cc->setChannelNumber($channelNumber_); $cc->setChannelName($channelName_); $cc->setChannelStatusFlag($channelStatusFlag_); $cc->setChannelUnit($channelUnit_); $cc->setChannelStation($channelStation_); $cc->setPrescribedLimit($prescribedLimit_); return $cc; }