diff --git a/Host/Views.Mobile/User/AssignAddress.cshtml b/Host/Views.Mobile/User/AssignAddress.cshtml index 4e8ab48..e1df1a5 100644 --- a/Host/Views.Mobile/User/AssignAddress.cshtml +++ b/Host/Views.Mobile/User/AssignAddress.cshtml @@ -81,8 +81,8 @@ account = getQueryVariable('account'), pass = getQueryVariable('password'); - if(product_id != 13&&product_id != 19&&product_id != 17) { - alert('目前仅支持极客、火狐产品!'); + if(product_id != 13&&product_id != 19&&product_id != 17&&product_id != 1) { + alert('目前仅支持极客、火狐、西瓜、强子产品!'); window.location.href = "/User/MyAccounts"; } @@ -166,6 +166,21 @@ } }); } + if(product_id == 1){ + $("#huohu").show(); + $("#jike").hide(); + $.ajax({ + type: 'GET', + url: 'http://php-api.juip.com/product/AccountAddress/qiangzi_address?user='+account+'&password='+pass, + dataType: "json", + contentType: "application/json", + success: function (res) { + $("#huohu").html('
服务器地址是混拨服务器,不选择任何地区,则为全国随机
'); + $("#huohu").append(res); + + } + }); + } }, checkLine(n) { var that = this; @@ -261,6 +276,38 @@ } }); } + if(this.productId == 1){ + let address_checked = []; + $("input[name='poolids[]']:checked").each(function(i){ + address_checked.push($(this).val()); + }); + + let data = { + list:address_checked, + account:this.assign_account, + password:this.assign_pass, + } + $.ajax({ + type: 'POST', + url: 'http://php-api.juip.com/product/AccountAddress/qiangzi', + dataType: "json", + data:JSON.stringify(data), + contentType: "application/json", + success: function (res) { + if(res.code == 1){ + alert('选择成功'); + } else { + alert('选择失败'); + } + //if (res.Code == 10000) { + // that.onLineData = res.Data; + // for (var i = 0; i < that.onLineData.length; i++) { + // that.onLineData[i].ProductId = productId; + // } + //} + } + }); + } if(product_id == 19){ let address_checked = []; $("input[name='citys[]']:checked").each(function(i){ diff --git a/Host/Views.Mobile/User/MyAccounts.cshtml b/Host/Views.Mobile/User/MyAccounts.cshtml index 5f4d0ee..b0ed7ad 100644 --- a/Host/Views.Mobile/User/MyAccounts.cshtml +++ b/Host/Views.Mobile/User/MyAccounts.cshtml @@ -119,7 +119,7 @@ - + diff --git a/Host/Views/User/MyAccounts.cshtml b/Host/Views/User/MyAccounts.cshtml index 6ebfb6c..968749f 100644 --- a/Host/Views/User/MyAccounts.cshtml +++ b/Host/Views/User/MyAccounts.cshtml @@ -387,7 +387,7 @@服务器地址是混拨服务器,不选择任何地区,则为全国随机
'); + $("#huohu").append(res); + + } + }); + } if(productId == 19){ $("#huohu").show(); $("#jike").hide(); @@ -794,6 +809,38 @@ } }); } + if(this.productId == 1){ + let address_checked = []; + $("input[name='poolids[]']:checked").each(function(i){ + address_checked.push($(this).val()); + }); + + let data = { + list:address_checked, + account:this.assign_account, + password:this.assign_pass, + } + $.ajax({ + type: 'POST', + url: 'http://php-api.juip.com/product/AccountAddress/qiangzi', + dataType: "json", + data:JSON.stringify(data), + contentType: "application/json", + success: function (res) { + if(res.code == 1){ + alert('选择成功'); + } else { + alert('选择失败'); + } + //if (res.Code == 10000) { + // that.onLineData = res.Data; + // for (var i = 0; i < that.onLineData.length; i++) { + // that.onLineData[i].ProductId = productId; + // } + //} + } + }); + } if(this.productId == 17){ if(this.assign_list.length>20||this.assign_list.length==0){ alert('最多选择20个,至少选择一个!');