dengrui/unpackage/dist/dev/.sourcemap/mp-weixin/pages/views/newAddress/newAddress.js.map

1 line
12 KiB
Plaintext

{"version":3,"sources":["uni-app:///main.js",null,"webpack:///D:/chen/登锐小程序(uniapp)/dengrui/pages/views/newAddress/newAddress.vue?57f7","webpack:///D:/chen/登锐小程序(uniapp)/dengrui/pages/views/newAddress/newAddress.vue?01c0","webpack:///D:/chen/登锐小程序(uniapp)/dengrui/pages/views/newAddress/newAddress.vue?0953","uni-app:///pages/views/newAddress/newAddress.vue"],"names":["createPage","Page"],"mappings":";;;;;;;;;;kDAAA;AACA;AACA,kH;AACAA,UAAU,CAACC,mBAAD,CAAV,C;;;;;;;;;;;;;ACHA;AAAA;AAAA;AAAA;AAAA;AAAmI;AACnI;AAC8D;AACL;;;AAGzD;AACyK;AACzK,gBAAgB,6KAAU;AAC1B,EAAE,gFAAM;AACR,EAAE,iGAAM;AACR,EAAE,0GAAe;AACjB;AACA;AACA;AACA;AACA;AACA,EAAE,qGAAU;AACZ;AACA;;AAEA;AACe,gF;;;;;;;;;;;;ACtBf;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;;;;;;;;;;;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;ACRA;AAAA;AAAA;AAAA;AAAqoB,CAAgB,onBAAG,EAAC,C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC0CzpB;AACA;AACA,sBADA,EADA;;AAIA,MAJA,kBAIA;AACA;AACA,cADA;AAEA,eAFA;AAGA,cAHA;AAIA,iBAJA;AAKA;AACA,kHADA;AAEA,kHAFA;AAGA,iHAHA,CALA;;AAUA,wBAVA;AAWA,kBAXA;;AAaA,GAlBA;AAmBA,QAnBA,kBAmBA,OAnBA,EAmBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAFA;AAGA;AACA;AACA,GA7BA;AA8BA;AACA,eADA,yBACA;AACA;AACA;AACA,OAFA,MAEA;AACA;AACA,OAFA,MAEA;AACA;AACA,OAFA,MAEA;AACA;AACA,OAFA,MAEA;AACA;AACA,OAFA,MAEA;AACA;AACA,sBADA;AAEA,6BAFA;AAGA,4BAHA;AAIA,gCAJA;AAKA,6BALA;AAMA,iCANA;AAOA;AACA;AACA;AACA,aAFA,MAEA;AACA;AACA;AACA,WAbA;;AAeA,OAhBA,MAgBA;AACA;AACA,eADA;AAEA,sBAFA;AAGA,2BAHA;;AAKA;AACA;AACA,sBADA;AAEA,kCAFA;AAGA,0BAHA;AAIA,gCAJA;AAKA,2BALA;AAMA,iCANA;AAOA;AACA;AACA;AACA;AACA,WAXA;;AAaA;AACA,KAjDA;AAkDA,UAlDA,oBAkDA;AACA;AACA;AACA;AACA,OAFA,EAEA,IAFA;AAGA,KAvDA;AAwDA;AACA;AACA;AACA,KA3DA,EA9BA,E","file":"pages/views/newAddress/newAddress.js","sourcesContent":["import 'uni-pages';\nimport Vue from 'vue'\nimport Page from './pages/views/newAddress/newAddress.vue'\ncreatePage(Page)","import { render, staticRenderFns, recyclableRender, components } from \"./newAddress.vue?vue&type=template&id=4440cb25&scoped=true&\"\nvar renderjs\nimport script from \"./newAddress.vue?vue&type=script&lang=js&\"\nexport * from \"./newAddress.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"4440cb25\",\n null,\n false,\n components,\n renderjs\n)\n\ncomponent.options.__file = \"pages/views/newAddress/newAddress.vue\"\nexport default component.exports","export * from \"-!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader/index.js??ref--16-0!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/template.js!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-uni-app-loader/page-meta.js!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/index.js??vue-loader-options!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./newAddress.vue?vue&type=template&id=4440cb25&scoped=true&\"","var components\nvar render = function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n}\nvar recyclableRender = false\nvar staticRenderFns = []\nrender._withStripped = true\n\nexport { render, staticRenderFns, recyclableRender, components }","import mod from \"-!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/babel-loader/lib/index.js!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader/index.js??ref--12-1!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/index.js??vue-loader-options!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./newAddress.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/babel-loader/lib/index.js!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/webpack-preprocess-loader/index.js??ref--12-1!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/script.js!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/vue-cli-plugin-uni/packages/vue-loader/lib/index.js??vue-loader-options!../../../../../../HBuilderX/plugins/uniapp-cli/node_modules/@dcloudio/webpack-uni-mp-loader/lib/style.js!./newAddress.vue?vue&type=script&lang=js&\"","<template>\n <view class=\"\">\n <!-- 使用标题栏 -->\r\n <status-nav :statusBackw=\"true\" :statusTitle=\"true\" :whereCome=\"0\" :title-val=\"'地址管理'\" :tabcolor=\"'#ffffff'\"></status-nav>\r\n <!-- 地址信息 -->\r\n <view class=\"ptwo-box bacb ptwo-box10 padding-zy20 posir padding-sx30\">\r\n <view class=\"disba fon24 color33 borbot padding-sx20\">\r\n <view style=\"width: 16%;\" class=\"flexs margin-y10\">收货人</view>\r\n <input class=\"width100 fon24\" style=\"\" type=\"text\" v-model=\"name\" placeholder=\"请填写收货人姓名\" placeholder-style=\"font-size:24rpx;\"/>\r\n </view>\r\n <view class=\"disac fon24 color33 borbot padding-sx20\">\r\n <view class=\"flexs\" style=\"width: 16%;\">手机号码</view>\r\n <view class=\"disac width100\">\r\n <view class=\"flexs\">+86</view>\r\n <input class=\"width100 margin-z10 fon24\" type=\"number\" maxlength=\"11\" v-model=\"phone\" placeholder=\"请填写收货人的手机号码\" placeholder-style=\"font-size:24rpx;\"/>\r\n </view>\r\n </view>\r\n <view class=\"disba fon24 color33 borbot padding-sx20\">\r\n <view style=\"width: 16%;\" class=\"flexs margin-y10\">所在地区</view>\r\n <input class=\"width100 fon24\" style=\"\" type=\"text\" v-model=\"city\" placeholder=\"省市区县、乡镇等\" placeholder-style=\"font-size:24rpx;\"/>\r\n </view>\r\n <view class=\"dis fon24 color33 borbot padding-sx20\">\r\n <view style=\"width: 16%;\" class=\"flexs margin-y10\">详细地址</view>\r\n <textarea class=\"width100 fon24\" v-model=\"address\" style=\"height: 200rpx;\" placeholder=\"街道、楼牌号等\" placeholder-style=\"font-size:24rpx;\"/>\r\n </view>\r\n <view class=\"borbot\"></view>\r\n </view>\r\n <view class=\"bacb margin-s20 padding-zy20 padding-sx30\">\r\n <view class=\"disba\">\r\n <view class=\"fon28\">设置为默认地址</view>\r\n <liSwitch :checked=\"switch_state\" @change=\"switchChange1\"></liSwitch>\r\n </view>\r\n <view class=\"fon24 color9\">提醒:每次下单会默认推荐使用该地址</view>\r\n </view>\r\n <view class=\"disbc\" style=\"position: fixed;bottom: 40px;left: 60px;right: 60px;\">\r\n <view @tap=\"saveAddress\" class=\"colorb fon30\" style=\"background-color: #1c4594;width: 100%;height: 82rpx;line-height: 82rpx;border-radius: 42.5rpx;text-align: center;\">保存</view>\r\n </view>\r\n </view>\n</template>\n\n<script>\r\n import liSwitch from '@/components/li-switch.vue';\r\n export default {\r\n components:{\r\n liSwitch\r\n },\n data() {\n return {\r\n name:'',\r\n phone:'',\r\n city:'',\r\n address:'',\r\n dataArr:[\r\n {isMo:false,cate:'公司',name:'陈之汉',phone:'138****1234',addInfo:'凤凰南大街75号',pcq:'四川省 成都市 温江区 涌泉社区'},\r\n {isMo:false,cate:'学校',name:'陈之汉',phone:'138****1234',addInfo:'凤凰南大街75号',pcq:'四川省 成都市 温江区 涌泉社区'},\r\n {isMo:true,cate:'住宅',name:'陈之汉',phone:'138****1234',addInfo:'凤凰南大街75号',pcq:'四川省 成都市 温江区 涌泉社区'},\r\n ],\r\n switch_state: true,\r\n updateId:''\r\n }\n },\r\n onLoad(options) {\r\n let newId = options.id\r\n if(newId!=undefined) this.updateId = newId\r\n console.log(this.updateId);\r\n // let obj = this.dataArr.filter(item=>item.isMo==true)//返回找到的对象\r\n let index = this.dataArr.findIndex((v) => {\r\n return v.isMo == true;\r\n });\r\n let newArr = this.dataArr.splice(index,1)\r\n this.dataArr.unshift(newArr[0])\r\n },\n methods: {\n saveAddress(){\r\n if(!this.name){\r\n this.$toolAll.tools.showToast('请输入收货人');\r\n } else if(!this.phone){\r\n this.$toolAll.tools.showToast('请输入手机号');\r\n } else if(this.$toolAll.tools.isPhone(this.phone)){\r\n this.$toolAll.tools.showToast('请输入正确的手机号');\r\n } else if(!this.city){\r\n this.$toolAll.tools.showToast('请输入所在地区');\r\n } else if(!this.address){\r\n this.$toolAll.tools.showToast('请输入详细地址');\r\n } else if(!this.switch_state){\r\n uni.showModal({\r\n title:'提示:',\r\n content:'是否设为默认地址',\r\n cancelText:'取消默认',\r\n cancelColor:'#999999',\r\n confirmText:'设为默认',\r\n confirmColor:'#164396',\r\n success: (res) => {\r\n if(res.confirm){\r\n this.switch_state = true\r\n } else {\r\n this.saveEv()\r\n }\r\n }\r\n })\r\n } else {\r\n let data = {\r\n id:1,\r\n name:'1234',\r\n hideLoading:true\r\n }\r\n this.$requst.get('login', data)\r\n uni.showModal({\r\n title:'提示:',\r\n content:'确定要保存当前地址信息吗?',\r\n cancelText:'取消',\r\n cancelColor:'#999999',\r\n confirmText:'确定',\r\n confirmColor:'#164396',\r\n success: (res) => {\r\n if(res.confirm){\r\n this.saveEv()\r\n }\r\n }\r\n })\r\n }\r\n },\r\n saveEv(){\r\n this.$toolAll.tools.showToast('保存地址成功');\r\n setTimeout(function(){\r\n uni.navigateBack({delta:1})\r\n },2000)\r\n },\r\n switchChange1: function(e){\r\n \tconsole.log(e);\r\n \tthis.switch_state = !e.checked;\r\n }\n }\n }\n</script>\n\n<style scoped>\r\n \n</style>\n"],"sourceRoot":""}