1 |
- define(["config","base"],function(e,t){var n=function(){if(typeof n.instance=="object")return n.instance;n.instance=this,this.isLoading=!1};n.prototype=new t;var r={success:!1,message:"网页加载失败,请您返回首页重新访问 <( ̄︶ ̄)>"};return n.prototype.getUserInfo=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=api/user/info",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getO2oUserInfo=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=o2o/user/info",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getProductList=function(t){var n=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=o2o/product/list",data:t,dataType:"JSON",success:function(e){n.isLoading=!1},error:function(e){n.isLoading=!1}})},n.prototype.getBalanceLog=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=o2o/user/getUserBalanceLog",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getUserTotalOrder=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/GetUserTotalOrder",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getAgreement=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=api/common/staticSource&key=agreement",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getHelp=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=api/common/staticSource&key=help_center",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getAbout=function(t,n){var i=this;this.isLoading=!0,$.signAjax({url:e.apiPath+"/index.php?r=api/common/staticSource&key=about_us",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getCouponList=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/usableCoupon",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.exchangeCoupon=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/user/exchangeCoupon",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.checkAddress=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/checkAddress",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.addOrder=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/add",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.cancelOrder=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/del",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.appendOrder=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/append",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getOrderDetail=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/detail",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getPayCharge=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/pay",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getAppendPayCharge=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/appendPay",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getMyOrderList=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/list",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.postReview=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/product/comment",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getReviewList=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/product/commentList",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getAddressList=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=api/shop/addressList",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.addAddress=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=api/shop/addAddress",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.deleteAddress=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=api/shop/delAddress",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.editAddress=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=api/shop/editAddress",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.gettoken=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=api/upload/gettoken",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.refundOrder=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/retrieve",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.finishOrder=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/confirmComplete",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getTradeStr=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/chubao/chubaoPay",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.selectTech=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/selectTech",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.techComment=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/order/techComment",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.addRechargeorder=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/recharge/addRechargeorder",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.payRecharge=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/recharge/payRecharge",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},n.prototype.getRechargeList=function(t,n){var i=this;$.signAjax({url:e.apiPath+"/index.php?r=o2o/recharge/rechargeList",data:t,dataType:"JSON",success:function(e){i.isLoading=!1,n&&n(e)},error:function(e){i.isLoading=!1,n&&n(r)}})},new n});
|