问题描述
想象一下我有一个这样的模型
public class CustomerTableViewModel
{
public int Id { get; set; }
public string CustomerName { get; set; }
public string CreatedDate { get; set; }
public string CreatedBy { get; set; }
public string RegistryCount { get; set; }
public string CurrentProfit { get; set; }
}
我使用 DatatableJs 服务器端。而它的前端是这样的:
DataTableTRInitializeServerSide(
$("#CustomersTable"),.....,[
{ "data": "Id","name": "#Number" },{ "data": "CustomerName","name": "Customer Name" },{ "data": "CreatedDate","name": "Created Date" },{ "data": "CreatedBy","name": "Created By" },{ "data": "RegistryCount","name": "Registries" },{ "data": "CurrentProfit","name": "Profits" }
],...
我想在这个表中插入一个隐藏属性。
public class CustomerTableViewModel
{
public int Id { get; set; }
public string CustomerName { get; set; }
public string CreatedDate { get; set; }
public string CreatedBy { get; set; }
public string RegistryCount { get; set; }
public string CurrentProfit { get; set; }
public string HIDDENPROP {get; set;} // here is my prop
}
我该怎么做?
我不想在桌子上展示这个 HIDDENPROP。具体的操作我会用到。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)