public class UserList { public string total { get; set; } public string count { get; set; } public userlistopenid data { get; set; } public string next_openid { get; set; } }
public class userlistopenid { public List<string> openid { get; set; } }
public class WxGroupsInfo { public string Group_ID { get; set; }//分组编号 public string Group_Name { get; set; }//分组名称 public string Group_Count { get; set; }//分组人数 }
WX.aspx内容:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WX.aspx.cs" Inherits="test.WX" %> <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <style type="text/css"> .inputstyle { height: 35px; line-height: 35px; text-indent: 5px; width: 350px; background-image: url('images/inputbg.gif'); background-repeat: repeat-x; border-top: solid 1px #a7b5bc; border-left: solid 1px #a7b5bc; border-right: solid 1px #ced9df; border-bottom: solid 1px #ced9df; margin: 15px auto 15px auto; } .g_title { width: 100%; border-bottom: 2px solid #ced9df; font-size: 20px; font-weight: bold; text-align: left; text-indent: 5px; height: 40px; line-height: 40px; } th { height: 35px; background-color: #31bb34; background-repeat: repeat-x; } tr { height: 30px; } #shownewgroup { width: 300px; height: 200px; background-color: white; z-index: 9999; border: 2px solid #DDD; top: 40%; left: 40%; background-color: #fff; position: fixed; margin: -100px auto auto -100px; display: none; } #shownewgroupzhezhaoceng { height: 200%; width: 200%; left: 0px; top: 0px; position: fixed; z-index: 9998; background: rgb(50, 50, 50); background: rgba(0, 0, 0, 0.5); display: none; } .closeLogin { height: 30px; border-bottom: 2px solid #31bb34; text-align: right; line-height: 30px; font-size: 14px; font-weight: bold; } a:hover { cursor: pointer; } .inputstyle22 { height: 35px; line-height: 35px; text-indent: 5px; width: 280px; background-image: url('images/inputbg.gif'); background-repeat: repeat-x; border-top: solid 1px #a7b5bc; border-left: solid 1px #a7b5bc; border-right: solid 1px #ced9df; border-bottom: solid 1px #ced9df; float: left; margin: auto 5px auto 5px; } </style> <style type="text/css"> .button { font: 15px Calibri, Arial, sans-serif; text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.4); text-decoration: none !important; white-space: nowrap; display: inline-block; vertical-align: baseline; position: relative; cursor: pointer; padding: 4px 20px; background-repeat: no-repeat; background-position: bottom left; background-image: url('button_bg.png'); background-position: bottom left, top right, 0 0, 0 0; background-clip: border-box; -moz-border-radius: 8px; -webkit-border-radius: 8px; border-radius: 8px; -moz-box-shadow: 0 0 1px #fff inset; -webkit-box-shadow: 0 0 1px #fff inset; box-shadow: 0 0 1px #fff inset; -webkit-transition: background-position 1s; -moz-transition: background-position 1s; transition: background-position 1s; } .blue.button { color: #0f4b6d !important; border: 1px solid #84acc3 !important; background-color: #48b5f2; background-image: url('button_bg.png'), url('button_bg.png'), -moz-radial-gradient(center bottom, circle, rgba(89, 208, 244, 1) 0, rgba(89, 208, 244, 0) 100px), -moz-linear-gradient(#4fbbf7, #3faeeb); background-image: url('button_bg.png'), url('button_bg.png'), -webkit-gradient(radial, 50% 100%, 0, 50% 100%, 100, from(rgba(89, 208, 244, 1)), to(rgba(89, 208, 244, 0))), -webkit-gradient(linear, 0% 0%, 0% 100%, from(#4fbbf7), to(#3faeeb)); } .blue.button:hover { background-color: #63c7fe; background-image: url('button_bg.png'), url('button_bg.png'), -moz-radial-gradient(center bottom, circle, rgba(109, 217, 250, 1) 0, rgba(109, 217, 250, 0) 100px), -moz-linear-gradient(#63c7fe, #58bef7); background-image: url('button_bg.png'), url('button_bg.png'), -webkit-gradient(radial, 50% 100%, 0, 50% 100%, 100, from(rgba(109, 217, 250, 1)), to(rgba(109, 217, 250, 0))), -webkit-gradient(linear, 0% 0%, 0% 100%, from(#63c7fe), to(#58bef7)); } </style> <script src="https://www.jb51.net/js/jquery-1.11.2.min.js"></script> <script type="text/javascript"> //修改分组名称调用的函数 function EditRoster(PayNo, name) { //alert(PayNo+":"+name); var url = 'Edit.aspx?id=' + PayNo + "&name=" + name; //转向网页的地址; var name = 'add'; //网页名称,可为空; var iWidth = 600; //弹出窗口的宽度; var iHeight = 300; //弹出窗口的高度; //获得窗口的垂直位置 var iTop = (window.screen.availHeight - 30 - iHeight) / 2; //获得窗口的水平位置 var iLeft = (window.screen.availWidth - 10 - iWidth) / 2; window.open(url, name, 'height=' + iHeight + ',innerHeight=' + iHeight + ',width=' + iWidth + ',innerWidth=' + iWidth + ',top=' + iTop + ',left=' + iLeft + ',status=no,toolbar=no,menubar=no,location=no,resizable=no,scrollbars=0,titlebar=no'); } $(document).ready(function() { $(".newGroups").click(function() { $("#shownewgroupzhezhaoceng").show(); $("#shownewgroup").show(); }), $('.closeloginpage').click(function() { $("#shownewgroupzhezhaoceng").hide(); $("#shownewgroup").hide(); }); }); </script> </head> <body> <form runat="server"> <div>分组管理</div> <div> <div> <span>新建分组</span> <a> 关闭 </a> </div> <div> 30字符以内 </div> <input type="text" maxlength="30" runat="server" value="分组名称" onfocus="if(value==defaultValue){value='';this.style.color='#000'}" onblur="if(!value){value=defaultValue;this.style.color='#999'}"/> <asp:LinkButton runat="server"> <div> 确定创建 </div> </asp:LinkButton> </div> <div></div> <table> <asp:Repeater runat="server" OnItemCommand="RepeaterGroupList_ItemCommand" OnItemDataBound="RepeaterGroupList_ItemDataBound"> <HeaderTemplate> <tr> <th>序号</th> <th>ID编号</th> <th>分组名称</th> <th>分组人数</th> <th>操作</th> </tr> </HeaderTemplate> <ItemTemplate> <tr> <td><asp:Label runat="server" Text=""></asp:Label></td> <td><%# Eval("Group_ID") %></td> <td><%# Eval("Group_Name") %></td> <td><%# Eval("Group_Count") %></td> <td> <aGroup_ID") %>', '<%# Eval("Group_Name") %>'); ">修改分组名称</a> <asp:LinkButton runat="server" CommandName="DeleteGroups" CommandArgument='<%# Eval("Group_ID") %>' CssClass="button blue">删除分组</asp:LinkButton> <asp:LinkButton runat="server" CommandName="SendByGroups" CommandArgument='<%# Eval("Group_ID") %>' CssClass="button blue">此分组消息群发</asp:LinkButton> <asp:LinkButton runat="server" CommandName="MoveUserToGroup" CommandArgument='<%# Eval("Group_ID") %>' CssClass="button blue">移动分组</asp:LinkButton> </td> </tr> </ItemTemplate> </asp:Repeater> </table> <a><div> ┼ 新建分组</div></a> </form> </body> </html>
WX.aspx.cs代码: