Song.Site/Manage/Student/Student_Money.aspx.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using WeiSha.Common;
using Song.ServiceInterfaces;
using Song.Entities;
namespace Song.Site.Manage.Student
{
public partial class Student_Money : Extend.CustomPage
{
private int id = WeiSha.Common.Request.QueryString["id"].Int32 ?? 0;
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
fill();
}
//密码输入框的显示与否
//this.trPw1.Visible = this.trPw2.Visible = id == 0;
}
private void fill()
{
Song.Entities.Student ea;
if (id == 0) return;
ea = Business.Do<IStudent>().StudentSingle(id);
//员工名称
this.lbName.Text = ea.St_Name;
//账户余额
lbMoney.Text = ea.St_Money.ToString();
}
/// <summary>
/// 充值或扣费
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void btnAddMoney_Click(object sender, EventArgs e)
{
if (!Extend.LoginState.Admin.IsAdmin) throw new Exception("非管理员无权此操作权限!");
Song.Entities.Student st = Business.Do<IStudent>().StudentSingle(id);
if (st == null) throw new Exception("当前信息不存在!");
//操作类型
int type = 2;
int.TryParse(rblOpera.SelectedItem.Value, out type);
//操作金额
int money = 0;
int.TryParse(tbMoney.Text, out money);
//操作对象
Song.Entities.MoneyAccount ma = new MoneyAccount();
ma.Ma_Monery = money;
后面还有 33 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
