<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="index.aspx.cs" Inherits="JuSNS.Web.system.movie.index" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<title id="ptitle" runat="server">电影管理</title>
<link href="../images/css/style.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="../../js/ajax.js"></script>
<script language="javascript" type="text/javascript" src="../../js/public.js"></script>

</head>
<body>
<table width="99%" border="0" align="center" cellpadding="5" cellspacing="1">
  <tr>
    <td width="120" align="center" valign="top">
        <div class="menu">
            <ul>
        	<%=this.GetSystemMenu(sort)%>
        	</ul>
      </div>
    </td>
    <td valign="top">
   <div class="navip">
    <span class="Blue"><a href="index.aspx">电影管理</a> <a href="add.aspx">添加电影</a> <a href="class.aspx">分类管理</a> <a href="javascript:void(0);" onclick="javascript:alert('还没开放');">电影采集</a></span> 
   </div> 
   <div id="DivErr" runat="server"></div>
   <form id="form1" runat="server">
   <div id="mainbody">
            <div class="sortlist">
                <ul id="SortList" runat="server"></ul>
            </div>
            
           <asp:Repeater runat="server" ID="Rpt_MovieList">
                <HeaderTemplate>
                    <table width="100%" border="0" cellpadding="3" cellspacing="1" class="maintable">
                        <tr class="maintablehead">
                            <td style="width: 23%;">
                                电影名称</td>
                            <td align="center" style="width: 8%;">
                                分类</td>
                            <td align="center" style="width: 31%;">
                                演员</td>
                            <td align="center" style="width: 8%;">
                                年份</td>
                            <td align="center" style="width: 5%;">
                                得分</td>
                            <td align="center" style="width: 25%;">
                                操作</td>
                        </tr>
                </HeaderTemplate>
                <ItemTemplate>
                    <tr class="maintablelist">
                        <td>
                            <a href="javascript:edit(<%# DataBinder.Eval(Container.DataItem, "MovieID")%>);" title="编辑"><%# DataBinder.Eval(Container.DataItem, "Title")%></a>
                        </td>
                        <td align="center">
                            <a href="index.aspx?c=<%# DataBinder.Eval(Container.DataItem, "SortID")%>"><%# DataBinder.Eval(Container.DataItem, "CName")%></a>
                        </td>
                        <td>
                            <%# DataBinder.Eval(Container.DataItem, "Billing")%>
                        </td>
                        <td align="center">
                            <%# DataBinder.Eval(Container.DataItem, "YearOnShow")%>
                        </td>
                        <td align="center">
                            <%# DataBinder.Eval(Container.DataItem, "Score")%>
                        </td>
                        <td align="center">
                            <a href="javascript:edit(<%# DataBinder.Eval(Container.DataItem, "MovieID")%>);">编辑</a>
                            | <a href="javascript:del(<%# DataBinder.Eval(Container.DataItem, "MovieID")%>);">删除</a>
                            | <a href="javascript:look(<%# DataBinder.Eval(Container.DataItem, "MovieID")%>);">查看已上传的电影海报</a>
                        </td>
                    </tr>
                </ItemTemplate>
                <FooterTemplate>
                    </table>
                </FooterTemplate>
            </asp:Repeater>
            <div class="pagination" runat="server" id="DivPage"  align="center"></div>
            <table width="100%" border="0" cellpadding="3" cellspacing="1">
                <tr class="maintablepage">
                    <td>
                        <div align="center">
                            搜索电影 <asp:TextBox ID="Key" runat="server" Width="200"></asp:TextBox><asp:Button ID="Button1"
                                runat="server" Text=" 搜索 " OnClick="Button1_Click" /></div>
                        
                    </td>
                </tr>
            </table>
        </div>
    </form>
    </td>
  </tr>
</table>
</body>
</html>
<script language="javascript" type="text/javascript">
function edit(id)
{
    self.location="edit.aspx?id="+id;
}
function del(id)
{
    if(confirm('你确认删除此电影吗?'))
        self.location="?action=del&id="+id;
}
function look(id)
{
    self.location="pic.aspx?movieid="+id;
}
</script>