• MVC---- DataSet 页面遍历


    后台代码:

      public override ActionResult Index()
      {
             DataSet ab = custapp.GetCustomerFollows();
             ViewData["activityDs"] = ab;
             return View();
      }

    前台代码:

    @using System.Data
    
       $(function () {
            jQuery.ajax({
                url: "/Business/CustomerFollow/GetList",
                data: null,
                dataType: "json",
                async: false,
                btn: null
            });
      }
    
     @{ foreach (DataRow activities in ((DataSet)ViewData["activityDs"]).Tables[0].Rows)
         {
            <table class="ui-jqgrid-btable ui-common-table table table-bordered" style=" background:#ffffff!important; margin-bottom:30px;">
                <tbody>
                    <tr class="jqgfirstrow">
                        <td style="height:50px;line-height:50px;">@activities["F_Id"]</td>
                        <td style="height:50px;line-height:50px;">@activities["F_FullName"]</td>
                        <td style="height:50px;line-height:50px;">@activities["F_Msisdn"]</td>
                        <td style="height:50px;line-height:50px;">@activities["F_CreatorTime"]</td>
                        <td style="height:50px;line-height:50px;">@activities["F_CreatorUserName"]</td>
                    </tr>
                    <tr>
                        <td colspan="5">
                            <textarea id="@activities["F_Id"]" class="ckeditor" id="postContent" ></textarea>
                        </td>
                    </tr>
                </tbody>
            </table>
         }}
  • 相关阅读:
    numpy常用函数
    python 语法学习
    python学习:字典
    python 字符串使用
    k-近邻算法
    Numpy函数库
    机器学习初体验
    Xcode8 + iOS10Beta 权限问题崩溃的解决方法
    苹果设备全攻略
    使用 Xcode 代码块
  • 原文地址:https://www.cnblogs.com/youmingkuang/p/7234531.html
Copyright © 2020-2023  润新知