/// <summary>
        /// 列表行绑定
        /// </summary>
        protected void gvCommentList_RowDataBound(object sender, GridViewRowEventArgs e)
        {
            if (e.Row.RowType == DataControlRowType.DataRow)
            {
                //还原出数据
                DNNGo_DNNGalleryProGame_Files Media = e.Row.DataItem as DNNGo_DNNGalleryProGame_Files;

                if (Media != null && Media.ID > 0)
                {
                    #region "编辑&删除按钮"
                    HyperLink  hlEdit          = e.Row.FindControl("hlEdit") as HyperLink;
                    HyperLink  hlMobileEdit    = e.Row.FindControl("hlMobileEdit") as HyperLink;
                    LinkButton btnRemove       = e.Row.FindControl("btnRemove") as LinkButton;
                    LinkButton btnMobileRemove = e.Row.FindControl("btnMobileRemove") as LinkButton;
                    //设置按钮的CommandArgument
                    btnRemove.CommandArgument = btnMobileRemove.CommandArgument = Media.ID.ToString();
                    //设置删除按钮的提示
                    //if (Media.Status == (Int32)EnumFileStatus.Recycle)
                    //{
                    btnRemove.Attributes.Add("onClick", "javascript:return confirm('" + Localization.GetString("DeleteItem") + "');");
                    btnMobileRemove.Attributes.Add("onClick", "javascript:return confirm('" + Localization.GetString("DeleteItem") + "');");
                    //}
                    //else
                    //{
                    //    btnRemove.Attributes.Add("onClick", "javascript:return confirm('" + ViewResourceText("DeleteRecycleItem", "Are you sure to move it to recycle bin?") + "');");
                    //    btnMobileRemove.Attributes.Add("onClick", "javascript:return confirm('" + ViewResourceText("DeleteRecycleItem", "Are you sure to move it to recycle bin?") + "');");
                    //}

                    hlEdit.NavigateUrl = hlMobileEdit.NavigateUrl = xUrl("ID", Media.ID.ToString(), "AddMedia");
                    #endregion

                    //发布者信息
                    e.Row.Cells[3].Text = "--";
                    if (Media.LastUser > 0)
                    {
                        UserInfo uInfo = UserController.GetUserById(PortalId, Media.LastUser);
                        if (uInfo != null && uInfo.UserID > 0)
                        {
                            e.Row.Cells[3].Text = String.Format("{0}<br />{1}", uInfo.Username, uInfo.DisplayName);
                        }
                    }


                    //发布时间
                    e.Row.Cells[4].Text = Media.LastTime.ToShortDateString();

                    //状态
                    e.Row.Cells[5].Text = EnumHelper.GetEnumTextVal(Media.Status, typeof(EnumFileStatus));

                    Label lblFileExtension = e.Row.FindControl("lblFileExtension") as Label;
                    lblFileExtension.Text = Media.FileExtension;

                    Image imgFileName = e.Row.FindControl("imgFileName") as Image;

                    HyperLink hlFileName = e.Row.FindControl("hlFileName") as HyperLink;
                    hlFileName.Text        = Media.FileName.Replace("." + Media.FileExtension, "");
                    imgFileName.ImageUrl   = GetPhotoExtension(Media.FileExtension, Media.FilePath);
                    hlFileName.NavigateUrl = GetPhotoPath(Media.FilePath);

                    Label lblSize = e.Row.FindControl("lblSize") as Label;
                    lblSize.Text = Common.ConvertFileSize(Media.FileSize);
                }
            }
        }
        /// <summary>
        /// 列表行绑定
        /// </summary>
        protected void gvArticleList_RowDataBound(object sender, GridViewRowEventArgs e)
        {
            if (e.Row.RowType == DataControlRowType.DataRow)
            {
                //还原出数据
                DNNGo_DNNGalleryProGame_Files Media = e.Row.DataItem as DNNGo_DNNGalleryProGame_Files;

                if (Media != null && Media.ID > 0)
                {
                    Label lblFileExtension = e.Row.FindControl("lblFileExtension") as Label;
                    lblFileExtension.Text = Media.FileExtension;

                    Image imgFileName = e.Row.FindControl("imgFileName") as Image;

                    HyperLink hlFileName = e.Row.FindControl("hlFileName") as HyperLink;
                    hlFileName.Text        = Media.FileName.Replace("." + Media.FileExtension, "");
                    imgFileName.ImageUrl   = GetPhotoExtension(Media.FileExtension, Media.FilePath);
                    hlFileName.NavigateUrl = GetPhotoPath(Media.FilePath);

                    HyperLink hlAdditional = e.Row.FindControl("hlAdditional") as HyperLink;

                    switch (File_Type.ToLower())
                    {
                    case "media": hlAdditional.Attributes.Add("onclick", String.Format("ReturnHtmlPicture('{0}','MediaID={1}');", GetPhotoExtension(Media.FileExtension, Media.FilePath), Media.ID));; break;

                    case "thumbnail": hlAdditional.Attributes.Add("onclick", String.Format("ReturnThumbnail('{0}','MediaID={1}');", GetPhotoExtension(Media.FileExtension, Media.FilePath), Media.ID)); break;

                    case "urllink": hlAdditional.Attributes.Add("onclick", String.Format("ReturnUrlLink('{0}','MediaID={1}');", GetPhotoExtension(Media.FileExtension, Media.FilePath), Media.ID)); break;

                    default: hlAdditional.Attributes.Add("onclick", String.Format("Return{2}('{0}','MediaID={1}');", GetPhotoExtension(Media.FileExtension, Media.FilePath), Media.ID, File_Type)); break;
                    }

                    //if (InsertType)
                    //{
                    //    //插入到文章内容
                    //    hlAdditional.Attributes.Add("onclick", String.Format("ReturnHtmlPicture('{0}',{1});", GetPhotoExtension(Media.FileExtension, Media.FilePath), Media.ID));
                    //}
                    //else
                    //{
                    //    hlAdditional.Attributes.Add("onclick", String.Format("ReturnPicture('{0}',{1});", GetPhotoExtension(Media.FileExtension, Media.FilePath), Media.ID));

                    //}

                    //发布者信息
                    e.Row.Cells[1].Text = "--";
                    if (Media.LastUser > 0)
                    {
                        UserInfo uInfo = UserController.GetUserById(PortalId, Media.LastUser);
                        if (uInfo != null && uInfo.UserID > 0)
                        {
                            e.Row.Cells[1].Text = String.Format("{0}<br />{1}", uInfo.Username, uInfo.DisplayName);
                        }
                    }


                    //发布时间
                    e.Row.Cells[2].Text = Media.LastTime.ToShortDateString();

                    //状态
                    e.Row.Cells[3].Text = EnumHelper.GetEnumTextVal(Media.Status, typeof(EnumFileStatus));
                }
            }
        }