| | |
| | | return OracleHelper.ExecuteSql("UPDATE GW_SP SET ALARM_MOBILE=:ALARM_MOBILE,BALANCE_THRESHOLD=:BALANCE_THRESHOLD WHERE CLIENT_ID=:CLIENT_ID", OracleHelper.Connection, new OracleParameter(":ALARM_MOBILE", (object)client.AlarmMobile), new OracleParameter(":BALANCE_THRESHOLD", (object)client.BalanceThreshold), new OracleParameter(":CLIENT_ID", (object)client.ClientID)) > 0; |
| | | } |
| | | |
| | | //更新充值金额AMOUNT |
| | | public bool UpdateClientAmount(GwClient client) |
| | | { |
| | | return OracleHelper.ExecuteSql("UPDATE GW_CLIENT SET BALANCE=:BALANCE, TOP_UP_AMOUNT_TOTAL=:TOP_UP_AMOUNT_TOTAL WHERE CLIENT_ID=:CLIENT_ID", OracleHelper.Connection, new OracleParameter(":BALANCE", (object)client.Balance), new OracleParameter(":TOP_UP_AMOUNT_TOTAL", (object)client.Top_up_Amount_Total), new OracleParameter(":CLIENT_ID", (object)client.ClientID)) > 0; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 更新账号的信息 |
| | | /// </summary> |
| | |
| | | o.Agent = oracleReaderWrapper.GetString("AGENT", ""); |
| | | o.AlarmMobile = oracleReaderWrapper.GetString("ALARM_MOBILE", ""); |
| | | o.BalanceThreshold = oracleReaderWrapper.GetInt("BALANCE_THRESHOLD", 0); |
| | | o.Balance = oracleReaderWrapper.GetInt("BALANCE", 0); |
| | | o.PermissionData = oracleReaderWrapper.GetString("PERMISSION_DATA", ""); |
| | | o.Id = oracleReaderWrapper.GetInt("ID", 0); |
| | | o.Certification_Status = oracleReaderWrapper.GetInt("CERTIFICATION_STATUS", 0); |
| | |
| | | { |
| | | StringBuilder stringBuilder = new StringBuilder(); |
| | | stringBuilder.Append("INSERT INTO GW_ORDER ( "); |
| | | stringBuilder.Append(" ORDER_ID, SP_ID, CLIENT_ID, PRODUCT_ID, COMBO_ID, BASIC_NUM, GIVING_NUM, PRICE, ORDER_NUM_TOTAL, ORDER_AMOUNT_TOTAL, BEFORE_BALANCE_NUM "); |
| | | stringBuilder.Append(" ORDER_ID, SP_ID, CLIENT_ID, PRODUCT_ID, COMBO_ID, BASIC_NUM, GIVING_NUM, PRICE, ORDER_NUM_TOTAL, ORDER_AMOUNT_TOTAL, PAY_AMOUNT, BEFORE_BALANCE_NUM "); |
| | | stringBuilder.Append(" , CREATOR, CREATE_TIME, STATUS, REMARK "); |
| | | //stringBuilder.Append(" , AUDITOR, AUDIT_TIME "); |
| | | stringBuilder.Append(" ) "); |
| | | stringBuilder.Append(" VALUES (:ORDER_ID, :SP_ID, :CLIENT_ID, :PRODUCT_ID, :COMBO_ID, :BASIC_NUM, :GIVING_NUM, :PRICE, :ORDER_NUM_TOTAL, :ORDER_AMOUNT_TOTAL, :BEFORE_BALANCE_NUM "); |
| | | stringBuilder.Append(" VALUES (:ORDER_ID, :SP_ID, :CLIENT_ID, :PRODUCT_ID, :COMBO_ID, :BASIC_NUM, :GIVING_NUM, :PRICE, :ORDER_NUM_TOTAL, :ORDER_AMOUNT_TOTAL, :PAY_AMOUNT, :BEFORE_BALANCE_NUM "); |
| | | stringBuilder.Append(" , :CREATOR, :CREATE_TIME, :STATUS, :REMARK "); |
| | | //stringBuilder.Append(" , :AUDITOR, :AUDIT_TIME "); |
| | | stringBuilder.Append(" ) "); |
| | |
| | | new OracleParameter(":PRICE", (object)o.Price), |
| | | new OracleParameter(":ORDER_NUM_TOTAL", (object)o.OrderNumTotal), |
| | | new OracleParameter(":ORDER_AMOUNT_TOTAL", (object)o.OrderAmountTotal), |
| | | new OracleParameter(":PAY_AMOUNT", (object)o.PayAmount), |
| | | new OracleParameter(":BEFORE_BALANCE_NUM", (object)o.BeforeBalanceNum), |
| | | new OracleParameter(":CREATOR", (object)o.Creator), |
| | | new OracleParameter(":CREATE_TIME", (object)o.CreateTime), |
| | |
| | | } |
| | | |
| | | //更新订单修改前余额 |
| | | public bool UpdateBalanceAndStatus(int basicNum, int givingNum, int orderNumTotal, int orderAmountTotal, int beforeGivingNum , int orderStatus, string orderId ) |
| | | public bool UpdateBalanceAndStatus(int basicNum, int givingNum, int orderNumTotal, int orderAmountTotal, int payAmount , int beforeGivingNum, int orderStatus, string orderId ) |
| | | { |
| | | if (string.IsNullOrEmpty(orderId)) |
| | | return false; |
| | | //status:4-取消 |
| | | return OracleHelper.ExecuteSql("update GW_ORDER SET BASIC_NUM=:BASIC_NUM, GIVING_NUM=:GIVING_NUM, ORDER_NUM_TOTAL=:ORDER_NUM_TOTAL, ORDER_AMOUNT_TOTAL=:ORDER_AMOUNT_TOTAL, BEFORE_BALANCE_NUM=:BEFORE_BALANCE_NUM, STATUS = :STATUS where ORDER_ID=:ORDER_ID", OracleHelper.Connection |
| | | return OracleHelper.ExecuteSql("update GW_ORDER SET BASIC_NUM=:BASIC_NUM, GIVING_NUM=:GIVING_NUM, ORDER_NUM_TOTAL=:ORDER_NUM_TOTAL, ORDER_AMOUNT_TOTAL=:ORDER_AMOUNT_TOTAL, PAY_AMOUNT=:PAY_AMOUNT, BEFORE_BALANCE_NUM=:BEFORE_BALANCE_NUM, STATUS = :STATUS where ORDER_ID=:ORDER_ID", OracleHelper.Connection |
| | | , new OracleParameter(":BASIC_NUM", (object)basicNum) |
| | | , new OracleParameter(":GIVING_NUM", (object)givingNum) |
| | | , new OracleParameter(":ORDER_NUM_TOTAL", (object)orderNumTotal) |
| | | , new OracleParameter(":ORDER_AMOUNT_TOTAL", (object)orderAmountTotal) |
| | | , new OracleParameter(":PAY_AMOUNT", (object)payAmount) |
| | | , new OracleParameter(":BEFORE_BALANCE_NUM", (object)beforeGivingNum) |
| | | , new OracleParameter(":STATUS", (object)orderStatus) |
| | | , new OracleParameter(":ORDER_ID", (object)orderId) |
| | |
| | | new OracleParameter(":PRICE", (object)o.Price), |
| | | new OracleParameter(":ORDER_NUM_TOTAL", (object)o.OrderNumTotal), |
| | | new OracleParameter(":ORDER_AMOUNT_TOTAL", (object)o.OrderAmountTotal), |
| | | new OracleParameter(":PAY_AMOUNT", (object)o.PayAmount), |
| | | new OracleParameter(":BEFORE_BALANCE_NUM", (object)o.BeforeBalanceNum), |
| | | new OracleParameter(":CREATOR", (object)o.Creator), |
| | | new OracleParameter(":CREATE_TIME", (object)o.CreateTime), |
| | |
| | | stringBuilder.Append(" , PRODUCT_ID =:PRODUCT_ID "); |
| | | stringBuilder.Append(" , COMBO_ID =:COMBO_ID "); |
| | | stringBuilder.Append(" , BASIC_NUM=:BASIC_NUM, GIVING_NUM=:GIVING_NUM, PRICE=:PRICE, ORDER_NUM_TOTAL=:ORDER_NUM_TOTAL, ORDER_AMOUNT_TOTAL=:ORDER_AMOUNT_TOTAL "); |
| | | stringBuilder.Append(" , BEFORE_BALANCE_NUM =:BEFORE_BALANCE_NUM, CREATOR=:CREATOR, CREATE_TIME=:CREATE_TIME "); |
| | | stringBuilder.Append(" , PAY_AMOUNT =:PAY_AMOUNT, BEFORE_BALANCE_NUM =:BEFORE_BALANCE_NUM, CREATOR=:CREATOR, CREATE_TIME=:CREATE_TIME "); |
| | | stringBuilder.Append(" , STATUS=:STATUS, REMARK=:REMARK "); |
| | | stringBuilder.Append(" WHERE ORDER_ID=:ORDER_ID "); |
| | | |
| | |
| | | o.Price = oracleReaderWrapper.GetInt("PRICE", 0); |
| | | o.OrderNumTotal = oracleReaderWrapper.GetInt("ORDER_NUM_TOTAL", 0); |
| | | o.OrderAmountTotal = oracleReaderWrapper.GetInt("ORDER_AMOUNT_TOTAL", 0); |
| | | o.PayAmount = oracleReaderWrapper.GetInt("PAY_AMOUNT", 0); |
| | | o.BeforeBalanceNum = oracleReaderWrapper.GetInt("BEFORE_BALANCE_NUM", 0); |
| | | o.Creator = oracleReaderWrapper.GetString("CREATOR", ""); |
| | | o.CreateTime = oracleReaderWrapper.GetDateTime("CREATE_TIME"); |
| | |
| | | D:\Company\SMGW_NewWeb\web\Dao\obj\Debug\Dao.pdb |
| | | C:\AYZH\work\Git_Rep\SMGW_NewWeb\web\Lib\Dao.dll |
| | | C:\AYZH\work\Git_Rep\SMGW_NewWeb\web\Lib\Dao.pdb |
| | | C:\AYZH\work\Git_Rep\SMGW_NewWeb\web\Dao\obj\Debug\Dao.csproj.AssemblyReference.cache |
| | | C:\AYZH\work\Git_Rep\SMGW_NewWeb\web\Dao\obj\Debug\Dao.csproj.CoreCompileInputs.cache |
| | | C:\AYZH\work\Git_Rep\SMGW_NewWeb\web\Dao\obj\Debug\Dao.csproj.CopyComplete |
| | | C:\AYZH\work\Git_Rep\SMGW_NewWeb\web\Dao\obj\Debug\Dao.dll |
| | |
| | | |
| | | public int OrderAmountTotal { get; set; } |
| | | |
| | | public int PayAmount { get; set; } |
| | | |
| | | public int BeforeBalanceNum { get; set; } |
| | | |
| | | public string Creator { get; set; } |
| | |
| | | { |
| | | private GwOrderDao _Dao = new GwOrderDao(); |
| | | private GwSpDao _GwSpDao = new GwSpDao(); |
| | | private GwClientDao _GwClientDao = new GwClientDao(); |
| | | private GwOpGroupDao _GwOpGroupDao = new GwOpGroupDao(); |
| | | private GwProductDao _GwProductDao = new GwProductDao(); |
| | | private SysXhDao _SysXhDao = new SysXhDao(); |
| | |
| | | string orderId = context.GetString("orderId"); |
| | | int basicNum = context.GetInt("basicNum"); |
| | | int givingNum = context.GetInt("givingNum"); |
| | | string clientId = ""; |
| | | int payAmount = 0; |
| | | int tmpPayAmount = Math.Max((int) (context.GetDecimal("payAmount", new Decimal(4, 0, 0, false, (byte) 2)) * new Decimal(1000)), 1); |
| | | payAmount = tmpPayAmount; |
| | | //double price = context.GetDecimal(price); |
| | | int num = Math.Max((int) (context.GetDecimal("price", new Decimal(4, 0, 0, false, (byte) 2)) * new Decimal(1000)), 1); |
| | | string remark = context.GetString("remark"); |
| | |
| | | if (gwOrder.Status !=0 && gwOrder.Status !=1) |
| | | throw new ArgumentException("该订单已处理,操作失败!"); |
| | | |
| | | |
| | | clientId = gwOrder.ClientId; |
| | | |
| | | //获取订单审核流程 |
| | | string flowGroup = null; //流程组合 |
| | |
| | | } |
| | | else if(status==1) |
| | | { |
| | | int beforeBasicNum = 0; |
| | | int beforeGivingNum = 0; |
| | | int balance = 0; |
| | | if(string.IsNullOrEmpty(nextFlowCode)) |
| | | int beforeBasicNum = 0; |
| | | int beforeGivingNum = 0; |
| | | int balance = 0; |
| | | int topUpAmountTotal = 0; |
| | | if (string.IsNullOrEmpty(nextFlowCode)) |
| | | { |
| | | orderStatus = 2; |
| | | |
| | |
| | | |
| | | beforeBasicNum = gwSp.BasicNum; |
| | | beforeGivingNum = gwSp.GivingNum; |
| | | balance = Convert.ToInt32(gwSp.Balance); |
| | | //balance = Convert.ToInt32(gwSp.Balance); |
| | | |
| | | //为1-预付费 |
| | | if (gwSp.ChargeType.Equals("1") && gwSp.Balance < num * basicNum ) |
| | | //获取客户信息 |
| | | GwClient gwClient = _GwClientDao.Get(gwSp.ClientID); |
| | | balance = int.Parse(gwClient.Balance.ToString() ); |
| | | topUpAmountTotal = int.Parse(gwClient.Top_up_Amount_Total.ToString() ); |
| | | |
| | | //为1-预付费 |
| | | if (gwSp.ChargeType==1 && (balance + payAmount) < num * basicNum) |
| | | { |
| | | throw new ArgumentException("账号余额不足,请联系管理员!"); |
| | | throw new ArgumentException("客户余额及充值金额不足购买,请调整后提交!"); |
| | | } |
| | | |
| | | //gwSp.Balance = balance - num * basicNum; |
| | |
| | | , beforeGivingNum + givingNum |
| | | , spId |
| | | ); |
| | | |
| | | |
| | | //有充值金额时,更新客户累计充值金额(厘) |
| | | if (payAmount > 0) { |
| | | //GwClient gwClient = new GwClient(); |
| | | gwClient = new GwClient(); |
| | | gwClient.Top_up_Amount_Total = topUpAmountTotal + payAmount; //累计金额:单位(厘) |
| | | gwClient.Balance = ((balance + payAmount) - num * basicNum) ; //账户余额:单位(厘) |
| | | gwClient.ClientID = clientId; |
| | | |
| | | _GwClientDao.UpdateClientAmount(gwClient); |
| | | } |
| | | } |
| | | else |
| | | { |
| | |
| | | //newGwOrder.OrderAmountTotal = basicNum * num ; |
| | | //newGwOrder.BeforeBalanceNum = beforeGivingNum + beforeGivingNum; |
| | | //newGwOrder.Status = orderStatus; |
| | | //更新订单 |
| | | _Dao.UpdateBalanceAndStatus(basicNum, givingNum, basicNum + givingNum, basicNum * num, beforeGivingNum + beforeGivingNum,orderStatus, orderId ); |
| | | //更新订单 |
| | | _Dao.UpdateBalanceAndStatus(basicNum, givingNum, basicNum + givingNum, basicNum * num, payAmount, beforeGivingNum + beforeGivingNum, orderStatus, orderId ); |
| | | |
| | | //Dao.Update(newGwOrder); |
| | | |
| | |
| | | |
| | | int orderNumTotal = context.GetInt("orderNumTotal", 0); |
| | | int orderAmountTotal = context.GetInt("orderAmountTotal", 0); |
| | | int payAmount = 0; |
| | | int beforeBalanceNum = context.GetInt("beforeBalanceNum", 0); |
| | | //客服人员提交订单时的状态为1-审核中。 |
| | | int status = 1; //0-待审核(已提交);1-审核中;2-审核通过;3-审核不通过;4-取消;申请订单在未审核情况下可以取消。 |
| | |
| | | DateTime createTime = DateTime.Now; |
| | | string creator = context.OperatorID; |
| | | |
| | | int tmpPayAmount = Math.Max((int) (context.GetDecimal("payAmount", new Decimal(4, 0, 0, false, (byte) 2)) * new Decimal(1000)), 1); |
| | | payAmount = tmpPayAmount; |
| | | int num = Math.Max((int) (context.GetDecimal("price", new Decimal(4, 0, 0, false, (byte) 2)) * new Decimal(1000)), 1); |
| | | price = num; |
| | | |
| | |
| | | throw new ArgumentException("账号不能为空!"); |
| | | } |
| | | |
| | | if (basicNum<=0 && givingNum <= 0) |
| | | if (basicNum<=0 && givingNum <= 0 && payAmount <=0) |
| | | { |
| | | throw new ArgumentException("基本条数或赠送条数必须大于零!"); |
| | | throw new ArgumentException("充值金额或基本条数或赠送条数必须大于零!"); |
| | | } |
| | | |
| | | //获取账号信息 |
| | | GwSp gwSp = _GwSpDao.Get(spId); |
| | | int balance = 0; |
| | | if (gwSp == null) |
| | | { |
| | | throw new ArgumentException("账号不存在!"); |
| | | } |
| | | else if (gwSp.Status==0) |
| | | { |
| | | throw new ArgumentException("账号已禁用!"); |
| | | } |
| | | |
| | | |
| | | //获取客户信息 |
| | | GwClient gwClient = _GwClientDao.Get(gwSp.ClientID); |
| | | balance = int.Parse(gwClient.Balance.ToString() ); |
| | | |
| | | //为1-预付费 |
| | | if (gwSp.ChargeType==1 && (balance + payAmount) < num * basicNum) |
| | | { |
| | | throw new ArgumentException("客户余额及充值金额不足购买,请调整后提交!"); |
| | | } |
| | | |
| | | //获取订单审核流程 |
| | |
| | | throw new ArgumentException("用户没有充值权限,请联系管理员!"); |
| | | } |
| | | |
| | | |
| | | //获取订单信息 |
| | | GwSp gwSp = _GwSpDao.Get(spId); |
| | | if (gwSp == null) |
| | | { |
| | | throw new ArgumentException("账号不存在!"); |
| | | } |
| | | else if (gwSp.Status==0) |
| | | { |
| | | throw new ArgumentException("账号已禁用!"); |
| | | } |
| | | |
| | | productId = gwSp.ProductId; |
| | | price = gwSp.Price; |
| | | |
| | |
| | | Price = price, //单价换算 |
| | | OrderNumTotal = orderNumTotal, |
| | | OrderAmountTotal = orderAmountTotal, |
| | | PayAmount = payAmount, |
| | | BeforeBalanceNum = beforeBalanceNum, |
| | | Status = status, |
| | | Remark = remark, |
| | |
| | | |
| | | }); |
| | | |
| | | |
| | | string auditId = _SysXhDao.getXh("GW_ORDER_AUDIT"); //获取生成订单审核ID |
| | | this._GwOrderAuditDao.Add(new GwOrderAudit() |
| | | //流程组合为空时 |
| | | if (!string.IsNullOrEmpty(flowGroup)) |
| | | { |
| | | AuditId = auditId, |
| | | OrderId = orderId, |
| | | AuditSort = sort, |
| | | AuditStatus = status, |
| | | Auditor = creator, |
| | | //AuditReason = null, |
| | | AuditTime = createTime |
| | | string auditId = _SysXhDao.getXh("GW_ORDER_AUDIT"); //获取生成订单审核ID |
| | | this._GwOrderAuditDao.Add(new GwOrderAudit() |
| | | { |
| | | AuditId = auditId, |
| | | OrderId = orderId, |
| | | AuditSort = sort, |
| | | AuditStatus = status, |
| | | Auditor = creator, |
| | | //AuditReason = null, |
| | | AuditTime = createTime |
| | | |
| | | }); |
| | | }); |
| | | } |
| | | |
| | | |
| | | return new JsonPageResult(true, "生成订单信息成功!"); |
| | |
| | | |
| | | int orderNumTotal = context.GetInt("orderNumTotal", 0); |
| | | int orderAmountTotal = context.GetInt("orderAmountTotal", 0); |
| | | int payAmount = 0; |
| | | int beforeBalanceNum = context.GetInt("beforeBalanceNum", 0); |
| | | int status = 0; |
| | | string remark = context.GetString("remark"); |
| | | DateTime createTime = DateTime.Now; |
| | | string creator = context.OperatorID; |
| | | |
| | | int tmpPayAmount = Math.Max((int) (context.GetDecimal("payAmount", new Decimal(4, 0, 0, false, (byte) 2)) * new Decimal(1000)), 1); |
| | | payAmount = tmpPayAmount; |
| | | |
| | | int num = Math.Max((int) (context.GetDecimal("price", new Decimal(4, 0, 0, false, (byte) 2)) * new Decimal(1000)), 1); |
| | | price = num; |
| | |
| | | Price = price, //单价换算 |
| | | OrderNumTotal = orderNumTotal, |
| | | OrderAmountTotal = orderAmountTotal, |
| | | PayAmount = payAmount, |
| | | BeforeBalanceNum = beforeBalanceNum, |
| | | Status = status, |
| | | Remark = remark, |
| | |
| | | $("#orderDialog #price").val(r.Message.Price / 1000, 0.00).attr("readonly", "readonly"); |
| | | $("#orderDialog #orderNumTotal").val(r.Message.OrderNumTotal, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #orderAmountTotal").val(r.Message.OrderAmountTotal / 1000, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #payAmount").val(r.Message.PayAmount / 1000, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #beforeBalanceNum").val(r.Message.BeforeBalanceNum, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #creator").val(r.Message.Creator).attr("readonly", "readonly"); |
| | | $("#orderDialog #createTime").val(r.Message.CreateTime).attr("readonly", "readonly"); |
| | |
| | | $("#orderDialog #clientId").val(r.Message.ClientId).attr("disabled", "disabled"); |
| | | $("#orderDialog #productId").val(r.Message.ProductId).attr("disabled", "disabled"); |
| | | //$("#orderDialog #comboId").val(r.Message.ComboId); |
| | | $("#orderDialog #basicNum").val(r.Message.BasicNum, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #givingNum").val(r.Message.GivingNum, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #basicNum").val(r.Message.BasicNum, 0).attr("readonly", false); |
| | | $("#orderDialog #givingNum").val(r.Message.GivingNum, 0).attr("readonly", false); |
| | | $("#orderDialog #price").val(r.Message.Price / 1000, 0.00).attr("readonly", "readonly"); |
| | | $("#orderDialog #orderNumTotal").val(r.Message.OrderNumTotal, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #orderAmountTotal").val(r.Message.OrderAmountTotal / 1000, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #payAmount").val(r.Message.PayAmount / 1000, 0).attr("readonly", false); |
| | | $("#orderDialog #beforeBalanceNum").val(r.Message.BeforeBalanceNum, 0).attr("readonly", "readonly"); |
| | | $("#orderDialog #creator").val(r.Message.Creator).attr("readonly", "readonly"); |
| | | $("#orderDialog #createTime").val(r.Message.CreateTime).attr("readonly", "readonly"); |
| | |
| | | var orderId = $("#orderId").val(); |
| | | var basicNum = $("#basicNum").val(); |
| | | var givingNum = $("#givingNum").val(); |
| | | var payAmount = $("#payAmount").val(); |
| | | var price = $("#price").val(); |
| | | var auditReason = $("#auditReason").val(); |
| | | mytek.confirm("是否确定审核通过该信息?", "数据更新后将无法恢复,请谨慎操作!", function (b) { |
| | | if (b) { |
| | | $.post("gwOrder.ashx", { "action": "audit", status: 1, spId: spId, orderId: orderId, basicNum: basicNum, givingNum: givingNum, price: price, auditReason: auditReason }, function (result) { |
| | | $.post("gwOrder.ashx", { "action": "audit", status: 1, spId: spId, orderId: orderId, basicNum: basicNum, givingNum: givingNum, payAmount: payAmount, price: price, auditReason: auditReason }, function (result) { |
| | | mytek.alert(result.Message, result.OK, function () { |
| | | loadPageList(); |
| | | }); |
| | |
| | | var orderId = $("#orderId").val(); |
| | | var basicNum = $("#basicNum").val(); |
| | | var givingNum = $("#givingNum").val(); |
| | | var payAmount = $("#payAmount").val(); |
| | | var price = $("#price").val(); |
| | | var auditReason = $("#auditReason").val(); |
| | | mytek.confirm("是否确定审核不通过该信息?", "数据更新后将无法恢复,请谨慎操作!", function (b) { |
| | | if (b) { |
| | | $.post("gwOrder.ashx", { "action": "audit", status: 0, spId: spId, orderId: orderId, basicNum: basicNum, givingNum: givingNum, price: price, auditReason: auditReason }, function (result) { |
| | | $.post("gwOrder.ashx", { "action": "audit", status: 0, spId: spId, orderId: orderId, basicNum: basicNum, givingNum: givingNum, payAmount: payAmount, price: price, auditReason: auditReason }, function (result) { |
| | | mytek.alert(result.Message, result.OK, function () { |
| | | loadPageList(); |
| | | }); |
| | |
| | | 订单基本条数</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="basicNum" id="basicNum" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="basicNum" id="basicNum" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">条 </span> |
| | | </div> |
| | |
| | | 订单赠送条数</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="givingNum" id="givingNum" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="givingNum" id="givingNum" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">条 </span> |
| | | </div> |
| | |
| | | 单价</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="price" id="price" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="price" id="price" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">元/条 </span> |
| | | </div> |
| | |
| | | 订单总条数</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="orderNumTotal" id="orderNumTotal" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="orderNumTotal" id="orderNumTotal" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">条 </span> |
| | | </div> |
| | |
| | | 订单总金额</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="orderAmountTotal" id="orderAmountTotal" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="orderAmountTotal" id="orderAmountTotal" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">元 </span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="form-group"> |
| | | <label class="col-sm-2 control-label"> |
| | | 充值金额</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="payAmount" id="payAmount" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">元 </span> |
| | | </div> |
| | |
| | | 充值前账号余额</label> |
| | | <div class="col-sm-4"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="beforeBalanceNum" id="beforeBalanceNum" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="beforeBalanceNum" id="beforeBalanceNum" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">条 </span> |
| | | </div> |
| | |
| | | </div> |
| | | <div class="form-group classes-span classes-span-1"> |
| | | <label class="col-sm-2 control-label"> |
| | | 用户余额</label> |
| | | 客户余额</label> |
| | | <div class="col-sm-6"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" value="<%=(double)Balance/1000 %>" |
| | |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="form-group classes-span classes-span-1"> |
| | | <label class="col-sm-2 control-label"> |
| | | 充值金额</label> |
| | | <div class="col-sm-6"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="payAmount" id="payAmount" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">元 </span> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="form-group"> |
| | | <label class="col-sm-2 control-label"> |
| | | 订单基本条数</label> |
| | | <div class="col-sm-6"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="basicNum" id="basicNum" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="basicNum" id="basicNum" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">条 </span> |
| | | </div> |
| | |
| | | 订单赠送条数</label> |
| | | <div class="col-sm-6"> |
| | | <div class="input-group"> |
| | | <input type="text" class="form-control" name="givingNum" id="givingNum" value="" maxlength="5" |
| | | <input type="text" class="form-control" name="givingNum" id="givingNum" value="" maxlength="10" |
| | | onkeyup="value=value.replace(/[^\d\.]/g,'')" onpaste="value=value.replace(/[^\d\.]/g,'')" |
| | | oncontextmenu="return false" /><span class="input-group-addon">条 </span> |
| | | </div> |
| | |
| | | |
| | | var spId = $("#spId").val(); |
| | | var clientId = $("#clientId").val(); |
| | | var productId = $("#productId").val(); |
| | | var productId = $("#productId").val(); |
| | | var price = $("#price").val(); |
| | | var payAmount = $("#payAmount").val(); |
| | | var basicNum = $("#basicNum").val(); |
| | | var givingNum = $("#givingNum").val(); |
| | | var remark = $("#remark").val(); |
| | |
| | | |
| | | if (b) { |
| | | |
| | | $.post("gwOrder.ashx", { action: "add", spId: spId, clientId: clientId, productId: productId, basicNum: basicNum, givingNum: givingNum, remark: remark }, function (r) { |
| | | $.post("gwOrder.ashx", { action: "add", spId: spId, clientId: clientId, productId: productId, price: price, payAmount:payAmount, basicNum: basicNum, givingNum: givingNum, remark: remark }, function (r) { |
| | | |
| | | mytek.alert(r.Message, r.OK, function () { |
| | | //loadPageList(); |
| | | if (r.OK) { |
| | | window.location = "GwSp.aspx"; |
| | | } else { |
| | | mytek.alert(r.Message, false); |
| | | } |
| | | }); |
| | | |
| | | }); |
| | |
| | | throw new ArgumentException("账号状态已停用!"); |
| | | |
| | | } |
| | | else |
| | | |
| | | |
| | | GwClient gwClient = new GwClient(); |
| | | using (GwClientDao gwClientDao = new GwClientDao()) |
| | | { |
| | | this.GwOrder = new GwOrder(); |
| | | gwClient = gwClientDao.Get(gwSp.ClientID); |
| | | } |
| | | |
| | | |
| | | this.GwOrder = new GwOrder(); |
| | | this.GwOrder.SpId = gwSp.SpID; |
| | | this.GwOrder.ClientId = gwSp.ClientID; |
| | | this.GwOrder.ProductId = gwSp.ProductId; |
| | |
| | | this.GwOrder.BasicNum = gwSp.BasicNum; //基本条数 |
| | | this.GwOrder.GivingNum = gwSp.GivingNum; |
| | | |
| | | this.Balance = gwSp.Balance; //余额 |
| | | } |
| | | //this.Balance = gwSp.Balance; //余额 |
| | | this.Balance = long.Parse(gwClient.Balance.ToString() ); //余额 |
| | | } |
| | | else |
| | | { |