SuLei.Web/admin/channel/attribute_field_edit.aspx.cs
(开头部分) 10KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Data;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using SuLei.Common;
using SuLei.UI;
namespace SuLei.Web.admin.channel
{
public partial class attribute_field_edit : ManagePage
{
private string action = SLEnums.ActionEnum.Add.ToString();//操作类型
private int id = 0;
protected void Page_Load(object sender, EventArgs e)
{
string _action = SLRequest.GetQueryString("action");
if (!string.IsNullOrEmpty(_action) && _action == SLEnums.ActionEnum.Edit.ToString())
{
this.action = SLEnums.ActionEnum.Edit.ToString();//修改类型
this.id = SLRequest.GetQueryInt("id");
if (this.id == 0)
{
JscriptMsg("传输参数不正确!", "back");
return;
}
if (!new BLL.sl_article_attribute_field().Exists(this.id))
{
JscriptMsg("记录不存在或已被删除!", "back");
return;
}
}
if (!Page.IsPostBack)
{
ChkAdminLevel(" sys_channel_field", SLEnums.ActionEnum.View.ToString());//检查权限
dlIsPassWord.Visible = dlIsHtml.Visible = dlEditorType.Visible = dlDataType.Visible
= dlDataLength.Visible = dlDataPlace.Visible = dlItemOption.Visible = false;//隐藏相应控件
if (action == SLEnums.ActionEnum.Edit.ToString())//修改
{
ShowInfo(this.id);
}
}
}
#region 赋值操作=================================
private void ShowInfo(int _id)
{
BLL.sl_article_attribute_field bll = new BLL.sl_article_attribute_field();
Model.sl_article_attribute_field model = bll.GetModel(_id);
txtName.Enabled = false;
txtName.Attributes.Remove("ajaxurl");
txtName.Attributes.Remove("datatype");
ddlControlType.SelectedValue = model.control_type;
showControlHtml(model.control_type);//显示对应的HTML
txtSortId.Text = model.sort_id.ToString();
txtName.Text = model.name;
后面还有 226 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
