Exemple #1
0
        public string FlatHmtl(string TotalFlat)
        {
            string FltHtml   = "";
            int    flatcount = Convert.ToInt32(TotalFlat);

            for (int i = 1; i <= flatcount; i++)
            {
                string     html  = fservice.FlatCreateBody();
                PLCService ps    = new PLCService();
                var        model = ps.GetAllPLC();
                html += "<div id='panel" + i.ToString() + "'>";
                foreach (var pm in model)
                {
                    string id = pm.PLCID.ToString() + " " + i.ToString();
                    html += @"<label class='checkbox'><input type='checkbox' value='" + pm.PLCID + "' name='" + pm.PLCName + "' id='" + id + "'><i></i> " + pm.PLCName + "</label>";
                }
                html    += "</div></div>";
                FltHtml += html.Replace("<% FlatNo %>", "FlatNo" + i).Replace("<% PreIncrement %>", "PreIncrement" + i);
            }
            return(FltHtml);
        }