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,131 @@
"use strict";
const common_vendor = require("../../common/vendor.js");
const common_assets = require("../../common/assets.js");
const api_index = require("../../api/index.js");
const utils_fun = require("../../utils/fun.js");
const store_index = require("../../store/index.js");
if (!Array) {
const _easycom_wd_datetime_picker2 = common_vendor.resolveComponent("wd-datetime-picker");
const _easycom_uni_dateformat2 = common_vendor.resolveComponent("uni-dateformat");
const _easycom_z_paging2 = common_vendor.resolveComponent("z-paging");
(_easycom_wd_datetime_picker2 + _easycom_uni_dateformat2 + _easycom_z_paging2)();
}
const _easycom_wd_datetime_picker = () => "../../uni_modules/wot-design-uni/components/wd-datetime-picker/wd-datetime-picker.js";
const _easycom_uni_dateformat = () => "../../uni_modules/uni-dateformat/components/uni-dateformat/uni-dateformat.js";
const _easycom_z_paging = () => "../../uni_modules/z-paging/components/z-paging/z-paging.js";
if (!Math) {
(_easycom_wd_datetime_picker + _easycom_uni_dateformat + _easycom_z_paging)();
}
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
__name: "team",
setup(__props) {
const paging = common_vendor.ref(null);
const dataList = common_vendor.ref([]);
const count = common_vendor.ref({});
const showLoading = common_vendor.ref(true);
const timeTrue = common_vendor.ref(false);
const store = store_index.Store();
const userInfo = common_vendor.computed(
() => store.userInfo || {
inviteCode: "",
nickname: "",
mobile: "",
avatar: "",
paywallet: {
balance: 0
}
}
);
common_vendor.onShow(() => {
});
common_vendor.onLoad(() => {
timeTrue.value = isTimestampInCurrentMonth((/* @__PURE__ */ new Date()).getTime());
timeCount();
});
function timeCount() {
if (userInfo.value.userRights && userInfo.value.userRights.rightsLevel == 3) {
api_index.api.getTeamMonthlyPerformanceAward({ month: utils_fun.timeFormat(value.value, "yyyy-MM-ddThh:mm:ss") }).then((res) => {
count.value = res;
});
}
}
const value = common_vendor.ref((/* @__PURE__ */ new Date()).getTime());
common_vendor.ref({});
const queryList = (pageNo, pageSize) => {
api_index.api.usersGetInfoTeam({ pageNo, pageSize }).then((res) => {
paging.value.complete(res.list);
timeCount();
}).catch((res) => {
paging.value.complete(false);
});
};
const confirm = (e) => {
timeTrue.value = isTimestampInCurrentMonth(e.value);
paging.value.reload();
};
function isTimestampInCurrentMonth(timestamp) {
const ts = timestamp < 1e12 ? timestamp * 1e3 : timestamp;
const date = new Date(ts);
const now = /* @__PURE__ */ new Date();
const currentYear = now.getFullYear();
const currentMonth = now.getMonth();
const targetYear = date.getFullYear();
const targetMonth = date.getMonth();
return currentYear === targetYear && currentMonth === targetMonth;
}
return (_ctx, _cache) => {
return common_vendor.e({
a: userInfo.value.userRights && userInfo.value.userRights.rightsLevel == 3
}, userInfo.value.userRights && userInfo.value.userRights.rightsLevel == 3 ? {
b: common_assets._imports_0$5,
c: common_assets._imports_1$3,
d: common_vendor.o(confirm),
e: common_vendor.o(($event) => showLoading.value = true),
f: common_vendor.o(($event) => showLoading.value = false),
g: common_vendor.o(($event) => value.value = $event),
h: common_vendor.p({
type: "year-month",
modelValue: value.value
}),
i: common_vendor.t(count.value.investmentAmount),
j: common_vendor.t(timeTrue.value ? "可" : "已"),
k: common_vendor.t(count.value.expectedReturn),
l: common_vendor.t(count.value.totalExpectedReturn)
} : {}, {
m: userInfo.value.puser
}, userInfo.value.puser ? {
n: common_vendor.t(userInfo.value.puser ? `${userInfo.value.puser.nickname} ${userInfo.value.puser.mobile}` : "无")
} : {}, {
o: common_vendor.f(dataList.value, (item, index, i0) => {
return common_vendor.e({
a: item.avatar,
b: common_vendor.t(item.nickname || "微信用户"),
c: common_vendor.t(item.mobile),
d: "dc51e287-2-" + i0 + ",dc51e287-0",
e: common_vendor.p({
format: "yyyy-MM-dd hh:mm:ss",
date: item.createTime
}),
f: item.userRights
}, item.userRights ? {
g: common_vendor.t(item.userRights.rights.rightsName)
} : {}, {
h: index
});
}),
p: common_vendor.sr(paging, "dc51e287-0", {
"k": "paging"
}),
q: common_vendor.o(queryList),
r: common_vendor.o(($event) => dataList.value = $event),
s: common_vendor.p({
["refresher-enabled"]: showLoading.value,
modelValue: dataList.value
})
});
};
}
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-dc51e287"]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/team/team.js.map

View File

@@ -0,0 +1,8 @@
{
"navigationBarTitleText": "我的团队",
"usingComponents": {
"wd-datetime-picker": "../../uni_modules/wot-design-uni/components/wd-datetime-picker/wd-datetime-picker",
"uni-dateformat": "../../uni_modules/uni-dateformat/components/uni-dateformat/uni-dateformat",
"z-paging": "../../uni_modules/z-paging/components/z-paging/z-paging"
}
}

View File

@@ -0,0 +1 @@
<view class="data-v-dc51e287"><z-paging wx:if="{{s}}" class="r data-v-dc51e287" u-s="{{['d']}}" u-r="paging" bindquery="{{q}}" u-i="dc51e287-0" bind:__l="__l" bindupdateModelValue="{{r}}" u-p="{{s}}"><view class="p30 data-v-dc51e287"><view wx:if="{{a}}" class="data-v-dc51e287" style="position:relative;width:690rpx;height:228rpx;padding:30rpx 25rpx;box-shadow:0rpx 2rpx 8rpx 2rpx rgba(0,88,219,0.06);border-radius:16rpx;overflow:hidden"><image class="data-v-dc51e287" style="width:690rpx;height:228rpx;position:absolute;top:0;left:0;z-index:-1" src="{{b}}"></image><view class="data-v-dc51e287" style="display:flex;align-items:center;justify-content:space-between;margin-bottom:30rpx"><view class="data-v-dc51e287" style="font-size:32rpx;font-weight:bold"> 团队业绩奖励 <text class="data-v-dc51e287" style="font-weight:500;font-size:28rpx;color:#999">(元)</text></view><wd-datetime-picker wx:if="{{h}}" class="data-v-dc51e287" u-s="{{['d']}}" bindconfirm="{{d}}" bindclose="{{e}}" bindopen="{{f}}" u-i="dc51e287-1,dc51e287-0" bind:__l="__l" bindupdateModelValue="{{g}}" u-p="{{h}}"><view class="data-v-dc51e287" style="font-size:28rpx;font-weight:bold;color:#5d7a4e;display:flex;align-items:center"> 11月 <image class="data-v-dc51e287" src="{{c}}" style="width:34rpx;height:34rpx"></image></view></wd-datetime-picker></view><view class="data-v-dc51e287" style="display:flex;align-items:center;justify-content:space-between;font-size:26rpx;margin-bottom:30rpx"><view class="data-v-dc51e287">本月团队业绩:{{i}}</view><view class="data-v-dc51e287">{{j}}获得业绩奖励:{{k}}</view></view><view class="data-v-dc51e287" style="font-size:26rpx"> 累计获得奖励: <text class="data-v-dc51e287" style="color:#fe3535">{{l}}</text></view></view><view wx:if="{{m}}" class="data-v-dc51e287" style="font-size:30rpx;background-color:#fff;border-radius:8rpx;padding:25rpx;margin-bottom:25rpx"> 推荐人:{{n}}</view><view class="data-v-dc51e287" style="font-weight:bold;font-size:32rpx;margin:30rpx 0">团队成员列表</view><view wx:for="{{o}}" wx:for-item="item" wx:key="h" class="user-card data-v-dc51e287"><view class="avatar-container data-v-dc51e287"><image class="avatar data-v-dc51e287" src="{{item.a}}" mode="aspectFit"></image><view class="avatar-container_name data-v-dc51e287">{{item.b}}</view></view><view class="data-v-dc51e287" style="display:flex;align-items:center;justify-content:space-between;margin-top:20rpx"><view class="phone-time-row data-v-dc51e287"><view class="phone data-v-dc51e287">{{item.c}}</view><view class="time data-v-dc51e287"><uni-dateformat wx:if="{{item.e}}" class="data-v-dc51e287" u-i="{{item.d}}" bind:__l="__l" u-p="{{item.e}}"></uni-dateformat></view></view><view class="action-section data-v-dc51e287"><view wx:if="{{item.f}}" class="action-btn join data-v-dc51e287">{{item.g}}</view><view wx:else class="action-btn join data-v-dc51e287">无</view><view class="level-text data-v-dc51e287">当前等级</view></view></view></view></view></z-paging></view>

View File

@@ -0,0 +1,68 @@
/* 水平间距 */
/* 水平间距 */
.user-card.data-v-dc51e287 {
border-radius: 16rpx;
width: 690rpx;
height: 244rpx;
background: #ffffff;
padding: 30rpx;
margin-bottom: 30rpx;
box-shadow: 0rpx 2rpx 8rpx 2rpx rgba(0, 88, 219, 0.06);
}
.avatar-container.data-v-dc51e287 {
display: flex;
align-items: center;
}
.avatar-container_name.data-v-dc51e287 {
font-weight: bold;
font-size: 28rpx;
color: #232323;
}
.avatar-container .avatar.data-v-dc51e287 {
width: 72rpx;
height: 72rpx;
border-radius: 50%;
margin-right: 20rpx;
background-color: #999;
}
.info-section.data-v-dc51e287 {
flex: 1;
}
.username.data-v-dc51e287 {
font-size: 36rpx;
color: #333333;
font-weight: 500;
margin-bottom: 20rpx;
display: block;
}
.phone-time-row.data-v-dc51e287 {
margin-top: 10rpx;
}
.phone.data-v-dc51e287 {
font-weight: 400;
font-size: 28rpx;
color: #232323;
}
.time.data-v-dc51e287 {
margin-top: 20rpx;
font-weight: 400;
font-size: 24rpx;
color: #999;
}
.action-section.data-v-dc51e287 {
display: flex;
flex-direction: column;
align-items: center;
}
.action-btn.data-v-dc51e287 {
font-weight: bold;
font-size: 28rpx;
color: #5d7a4e;
margin-bottom: 4rpx;
}
.level-text.data-v-dc51e287 {
margin-top: 20rpx;
font-weight: 400;
font-size: 24rpx;
color: #999;
}