private void BuildForm() { if (key.Count > 1) { item = controller.FetchByManyID(key); } else { item = Data.TIPEAKTOR.FetchByID(Request["editid1"]); } Control control_key_KODETIPE = new Control("KODETIPE", item.KODETIPE, false, smarty, this.Request, builder, MODE.MODE_VIEW); smarty.Add("show_key1", Control.HTMLEncodeSpecialChars(control_key_KODETIPE.GetData())); if (item != null) { string value = ""; string keylink = string.Empty; keylink += "&key1=" + Control.HTMLEncodeSpecialChars(this.Server.UrlEncode(item.KODETIPE.ToString())); // KODETIPE - Control control_KODETIPE = new Control("KODETIPE", item.KODETIPE, false, smarty, this.Request, builder, MODE.MODE_VIEW); value = control_KODETIPE.GetData(); value = control_KODETIPE.ProcessLargeText(value, "field=KODETIPE" + keylink, "", MODE.MODE_VIEW); smarty.Add("KODETIPE_value", value); smarty.Add("KODETIPE_fieldblock", true); // DESKRIPSI - Control control_DESKRIPSI = new Control("DESKRIPSI", item.DESKRIPSI, false, smarty, this.Request, builder, MODE.MODE_VIEW); value = control_DESKRIPSI.GetData(); value = control_DESKRIPSI.ProcessLargeText(value, "field=DESKRIPSI" + keylink, "", MODE.MODE_VIEW); smarty.Add("DESKRIPSI_value", value); smarty.Add("DESKRIPSI_fieldblock", true); } }
private bool Init() { inlineedit = ((string)Request["editType"] == "inline"); record_id = (string)Request["recordID"]; if (inlineedit) { templatefile = "TIPEAKTOR_inline_edit.aspx"; } else { templatefile = "TIPEAKTOR_edit.aspx"; } keys["KODETIPE"] = Request["editid1"]; if (keys.Count > 1) { item = controller.FetchByManyID(keys); } else { item = Data.TIPEAKTOR.FetchByID(Request["editid1"]); } if (item != null) { bool editable = true; if (!editable) { output.Append("<p>" + "You don't have permissions to access this table" + " <a href=\"TIPEAKTOR_list.aspx?a=return\">back</a>"); return(false); } } else { this.Server.Transfer("~/TIPEAKTOR_list.aspx?a=return"); } return(true); }