first commit

This commit is contained in:
PC-202306242200\Administrator
2026-03-28 23:10:55 +08:00
commit 1c24452b6c
1735 changed files with 150474 additions and 0 deletions

View File

@@ -0,0 +1 @@
"use strict";const e=require("../../common/vendor.js"),a=require("../../api/index.js");if(!Array){(e.resolveComponent("wd-navbar")+e.resolveComponent("wd-input")+e.resolveComponent("wd-switch"))()}Math||((()=>"../../uni_modules/wot-design-uni/components/wd-navbar/wd-navbar.js")+(()=>"../../uni_modules/wot-design-uni/components/wd-input/wd-input.js")+(()=>"../../uni_modules/wot-design-uni/components/wd-switch/wd-switch.js"))();const r=e.defineComponent({__name:"add",setup(r){e.onLoad((e=>{e.id&&a.api.addressInfo({id:e.id}).then((e=>{const a=e||{};a.isDefault=!!a.isDefault;const r=Object.keys(o.value),n={};r.forEach((e=>{a.hasOwnProperty(e)&&(n[e]=a[e])})),Object.assign(o.value,n)}))}));const o=e.ref({receiverName:"",receiverPhone:"",receiverArea:"",receiverAddress:"",isDefault:!0,status:0,id:""}),n=()=>{let r=JSON.parse(JSON.stringify(o.value));r.isDefault=r.isDefault?1:0,r.id?a.api.addressUp(r).then((a=>{e.index.navigateBack()})):a.api.addressAdd(r).then((a=>{e.index.navigateBack()}))},t=()=>{e.index.navigateBack()};return(a,r)=>({a:e.o(t),b:e.p({title:"新增地址",safeAreaInsetTop:!0,"left-arrow":!0}),c:e.o((e=>o.value.receiverName=e)),d:e.p({type:"text","no-border":!0,placeholder:"请输入收货人姓名",modelValue:o.value.receiverName}),e:e.o((e=>o.value.receiverPhone=e)),f:e.p({type:"number","no-border":!0,placeholder:"请输入手机号",modelValue:o.value.receiverPhone}),g:e.o((e=>o.value.receiverArea=e)),h:e.p({type:"text","no-border":!0,placeholder:"请输入省市区",modelValue:o.value.receiverArea}),i:e.o((e=>o.value.receiverAddress=e)),j:e.p({type:"text","no-border":!0,placeholder:"请输入详细地址",modelValue:o.value.receiverAddress}),k:e.o((e=>o.value.isDefault=e)),l:e.p({size:"20px",modelValue:o.value.isDefault}),m:e.o(n)})}}),o=e._export_sfc(r,[["__scopeId","data-v-1285ff06"]]);wx.createPage(o);

View File

@@ -0,0 +1,9 @@
{
"navigationBarTitleText": "",
"navigationStyle": "custom",
"usingComponents": {
"wd-navbar": "../../uni_modules/wot-design-uni/components/wd-navbar/wd-navbar",
"wd-input": "../../uni_modules/wot-design-uni/components/wd-input/wd-input",
"wd-switch": "../../uni_modules/wot-design-uni/components/wd-switch/wd-switch"
}
}

View File

@@ -0,0 +1 @@
<view class="address-add data-v-1285ff06"><wd-navbar wx:if="{{b}}" class="data-v-1285ff06" bindclickLeft="{{a}}" u-i="1285ff06-0" bind:__l="__l" u-p="{{b}}"></wd-navbar><view class="from-address data-v-1285ff06"><view class="title data-v-1285ff06">收货人</view><view class="content data-v-1285ff06"><wd-input wx:if="{{d}}" class="data-v-1285ff06" u-i="1285ff06-1" bind:__l="__l" bindupdateModelValue="{{c}}" u-p="{{d}}"/></view></view><view class="from-address data-v-1285ff06"><view class="title data-v-1285ff06">手机号</view><view class="content data-v-1285ff06"><wd-input wx:if="{{f}}" class="data-v-1285ff06" u-i="1285ff06-2" bind:__l="__l" bindupdateModelValue="{{e}}" u-p="{{f}}"/></view></view><view class="from-address data-v-1285ff06"><view class="title data-v-1285ff06">所在地区</view><view class="content data-v-1285ff06"><wd-input wx:if="{{h}}" class="data-v-1285ff06" u-i="1285ff06-3" bind:__l="__l" bindupdateModelValue="{{g}}" u-p="{{h}}"/></view></view><view class="from-address data-v-1285ff06"><view class="title data-v-1285ff06">详细地址</view><view class="content data-v-1285ff06"><wd-input wx:if="{{j}}" class="data-v-1285ff06" u-i="1285ff06-4" bind:__l="__l" bindupdateModelValue="{{i}}" u-p="{{j}}"/></view></view><view class="from-address data-v-1285ff06" style="margin-top:30rpx;justify-content:space-between"><view class="title data-v-1285ff06" style="width:300rpx">设置为默认地址</view><view class="data-v-1285ff06"><wd-switch wx:if="{{l}}" class="data-v-1285ff06" u-i="1285ff06-5" bind:__l="__l" bindupdateModelValue="{{k}}" u-p="{{l}}"/></view></view><view class="bottom-btn data-v-1285ff06"><view class="button-a data-v-1285ff06" bindtap="{{m}}">保存</view></view></view>

View File

@@ -0,0 +1 @@
.address-add.data-v-1285ff06{width:100%;padding:0rpx 0 180rpx}.address-add .from-address.data-v-1285ff06{background-color:#fff;height:110rpx;padding:0rpx 20rpx;display:flex;align-items:center}.address-add .from-address .title.data-v-1285ff06{width:150rpx;font-size:28rpx;font-weight:700;color:#333}.address-add .from-address .content.data-v-1285ff06{flex:1;height:100rpx;display:flex;align-items:center;border-bottom:1rpx solid #f6f6f6}.address-add .bottom-btn.data-v-1285ff06{width:100%;height:150rpx;padding:30rpx;background-color:#fff;position:fixed;bottom:0;left:0;border-radius:20rpx 20rpx 0 0;box-shadow:0 6rpx 16rpx 2rpx rgba(170,170,170,.35);display:flex;align-items:center;justify-content:center}.address-add .bottom-btn .button-a.data-v-1285ff06{width:690rpx;height:90rpx;background:#799675;border-radius:15rpx;text-align:center;font-size:30rpx;color:#fff;line-height:90rpx}

View File

@@ -0,0 +1 @@
"use strict";const e=require("../../common/vendor.js"),a=require("../../api/index.js");if(!Array){(e.resolveComponent("wd-navbar")+e.resolveComponent("z-paging"))()}Math||((()=>"../../uni_modules/wot-design-uni/components/wd-navbar/wd-navbar.js")+(()=>"../../uni_modules/z-paging/components/z-paging/z-paging.js"))();const n=e.defineComponent({__name:"list",setup(n){const o=e.ref(null),r=e.ref(null),i=e.ref([]);e.onLoad((e=>{r.value=e.type})),e.onShow((()=>{o.value.reload()}));const s=(e,n)=>{a.api.addressPage({pageNo:e,pageSize:n}).then((e=>{o.value.complete(e.list)})).catch((e=>{o.value.complete(!1)}))},t=()=>{e.index.navigateBack()},d=a=>{e.index.navigateTo({url:a})};return(n,c)=>({a:e.o(t),b:e.p({title:"地址管理",safeAreaInsetTop:!0,"left-arrow":!0}),c:e.f(i.value,((n,i,s)=>({a:e.t(n.receiverName),b:e.t(n.receiverPhone),c:e.t(n.receiverArea),d:e.t(n.receiverAddress),e:e.o((r=>{return i=n,void e.index.showModal({title:"提示",content:"是否确认删除?",success:e=>{e.confirm&&a.api.addressDel({id:i.id}).then((e=>{o.value.reload()}))}});var i}),i),f:e.o((e=>d(`./add?id=${n.id}`)),i),g:e.o((a=>(a=>{let n=`收货人:${a.receiverName}\n手机号码:${a.receiverPhone}\n所在地区:${a.receiverArea}\n详细地址:${a.receiverAddress}`;e.index.setClipboardData({data:n,success:function(){console.log("success")}})})(n)),i),h:e.o((a=>{return o=n,void(1==r.value&&(e.index.$emit("address",o),e.index.navigateBack()));var o}),i),i:i}))),d:e.sr(o,"a56d4a9a-1",{k:"paging"}),e:e.o(s),f:e.o((e=>i.value=e)),g:e.p({"use-page-scroll":!0,modelValue:i.value}),h:e.o((e=>d("./add")))})}}),o=e._export_sfc(n,[["__scopeId","data-v-a56d4a9a"]]);wx.createPage(o);

View File

@@ -0,0 +1,8 @@
{
"navigationBarTitleText": "",
"navigationStyle": "custom",
"usingComponents": {
"wd-navbar": "../../uni_modules/wot-design-uni/components/wd-navbar/wd-navbar",
"z-paging": "../../uni_modules/z-paging/components/z-paging/z-paging"
}
}

View File

@@ -0,0 +1 @@
<view class="address data-v-a56d4a9a"><wd-navbar wx:if="{{b}}" class="data-v-a56d4a9a" bindclickLeft="{{a}}" u-i="a56d4a9a-0" bind:__l="__l" u-p="{{b}}"></wd-navbar><z-paging wx:if="{{g}}" class="r data-v-a56d4a9a" u-s="{{['d']}}" u-r="paging" bindquery="{{e}}" u-i="a56d4a9a-1" bind:__l="__l" bindupdateModelValue="{{f}}" u-p="{{g}}"><view class="data-v-a56d4a9a" style="padding:30rpx"><view wx:for="{{c}}" wx:for-item="item" wx:key="i" class="address-a data-v-a56d4a9a" bindtap="{{item.h}}"><view class="top data-v-a56d4a9a"><view class="top-a data-v-a56d4a9a"><view class="data-v-a56d4a9a">{{item.a}}</view><view class="data-v-a56d4a9a">{{item.b}}</view></view><view class="top-b data-v-a56d4a9a">{{item.c}} {{item.d}}</view></view><view class="bottom data-v-a56d4a9a"><view class="bottom-r data-v-a56d4a9a"><view class="data-v-a56d4a9a" catchtap="{{item.e}}">删除</view><view class="data-v-a56d4a9a" style="margin-left:50rpx" catchtap="{{item.f}}">编辑</view><view class="data-v-a56d4a9a" catchtap="{{item.g}}" style="margin:0 50rpx">复制</view></view></view></view></view></z-paging><view class="bottom-btn data-v-a56d4a9a"><view class="button-a data-v-a56d4a9a" bindtap="{{h}}">新增收货地址</view></view></view>

View File

@@ -0,0 +1 @@
.address .address-a.data-v-a56d4a9a{width:100%;background:#fff;box-shadow:0 2rpx 21rpx rgba(184,184,184,.35);border-radius:17rpx;margin-bottom:30rpx}.address .address-a .top.data-v-a56d4a9a{padding:40rpx;border-bottom:1rpx solid #f3f3f3}.address .address-a .top .top-a.data-v-a56d4a9a{display:flex;align-items:center;justify-content:space-between;font-size:30rpx;font-weight:700;color:#222;margin-bottom:45rpx}.address .address-a .top .top-b.data-v-a56d4a9a{font-size:30rpx;font-weight:700;color:#999}.address .address-a .bottom.data-v-a56d4a9a{padding:35rpx;display:flex;align-items:center;justify-content:space-between}.address .address-a .bottom .bottom-che.data-v-a56d4a9a{display:flex;align-items:center;font-size:24rpx;font-weight:700;color:#222}.address .address-a .bottom .bottom-che image.data-v-a56d4a9a{width:32rpx;height:32rpx;margin-right:10rpx}.address .address-a .bottom .bottom-r.data-v-a56d4a9a{font-size:26rpx;font-weight:700;color:#999;display:flex;align-items:center}.address .bottom-btn.data-v-a56d4a9a{width:100%;height:150rpx;padding:30rpx;background-color:#fff;position:fixed;bottom:0;left:0;border-radius:20rpx 20rpx 0 0;box-shadow:0 6rpx 16rpx 2rpx rgba(170,170,170,.35);display:flex;align-items:center;justify-content:center}.address .bottom-btn .button-a.data-v-a56d4a9a{width:690rpx;height:90rpx;background:#799675;border-radius:15rpx;text-align:center;font-size:30rpx;color:#fff;line-height:90rpx}