321321
This commit is contained in:
parent
bf1481d2fb
commit
5dbd8c7e68
|
|
@ -184,6 +184,11 @@ public class GoodsCreateRequest
|
||||||
/// 下架金额
|
/// 下架金额
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public decimal XiajiaJine { get; set; }
|
public decimal XiajiaJine { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 解锁金额(用户需消费满此金额才能看到此盒子,0表示无需解锁)
|
||||||
|
/// </summary>
|
||||||
|
public decimal UnlockAmount { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
@ -288,6 +293,11 @@ public class GoodsListResponse
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public int ChoujiangXianzhi { get; set; }
|
public int ChoujiangXianzhi { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 解锁金额
|
||||||
|
/// </summary>
|
||||||
|
public decimal UnlockAmount { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 创建时间
|
/// 创建时间
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
||||||
|
|
@ -129,6 +129,7 @@ public class GoodsService : IGoodsService
|
||||||
XiajiaLirun = (int)request.XiajiaLirun,
|
XiajiaLirun = (int)request.XiajiaLirun,
|
||||||
XiajiaAutoCoushu = (int)request.XiajiaAutoCoushu,
|
XiajiaAutoCoushu = (int)request.XiajiaAutoCoushu,
|
||||||
XiajiaJine = (int)request.XiajiaJine,
|
XiajiaJine = (int)request.XiajiaJine,
|
||||||
|
UnlockAmount = request.UnlockAmount,
|
||||||
Status = 0, // 默认下架
|
Status = 0, // 默认下架
|
||||||
PrizeNum = 0,
|
PrizeNum = 0,
|
||||||
IsFlw = (byte)(request.Type == 15 ? 1 : 0),
|
IsFlw = (byte)(request.Type == 15 ? 1 : 0),
|
||||||
|
|
@ -207,6 +208,7 @@ public class GoodsService : IGoodsService
|
||||||
goods.XiajiaLirun = (int)request.XiajiaLirun;
|
goods.XiajiaLirun = (int)request.XiajiaLirun;
|
||||||
goods.XiajiaAutoCoushu = (int)request.XiajiaAutoCoushu;
|
goods.XiajiaAutoCoushu = (int)request.XiajiaAutoCoushu;
|
||||||
goods.XiajiaJine = (int)request.XiajiaJine;
|
goods.XiajiaJine = (int)request.XiajiaJine;
|
||||||
|
goods.UnlockAmount = request.UnlockAmount;
|
||||||
goods.IsFlw = (byte)(request.Type == 15 ? 1 : 0);
|
goods.IsFlw = (byte)(request.Type == 15 ? 1 : 0);
|
||||||
goods.UpdatedAt = DateTime.Now;
|
goods.UpdatedAt = DateTime.Now;
|
||||||
|
|
||||||
|
|
@ -677,6 +679,7 @@ public class GoodsService : IGoodsService
|
||||||
FlwEndTime = goods.FlwEndTime,
|
FlwEndTime = goods.FlwEndTime,
|
||||||
OpenTime = goods.OpenTime,
|
OpenTime = goods.OpenTime,
|
||||||
ChoujiangXianzhi = goods.ChoujiangXianzhi,
|
ChoujiangXianzhi = goods.ChoujiangXianzhi,
|
||||||
|
UnlockAmount = goods.UnlockAmount,
|
||||||
CreatedAt = goods.CreatedAt,
|
CreatedAt = goods.CreatedAt,
|
||||||
UpdatedAt = goods.UpdatedAt
|
UpdatedAt = goods.UpdatedAt
|
||||||
};
|
};
|
||||||
|
|
@ -712,6 +715,7 @@ public class GoodsService : IGoodsService
|
||||||
FlwEndTime = goods.FlwEndTime,
|
FlwEndTime = goods.FlwEndTime,
|
||||||
OpenTime = goods.OpenTime,
|
OpenTime = goods.OpenTime,
|
||||||
ChoujiangXianzhi = goods.ChoujiangXianzhi,
|
ChoujiangXianzhi = goods.ChoujiangXianzhi,
|
||||||
|
UnlockAmount = goods.UnlockAmount,
|
||||||
GoodsDescribe = goods.GoodsDescribe,
|
GoodsDescribe = goods.GoodsDescribe,
|
||||||
NewIs = goods.NewIs,
|
NewIs = goods.NewIs,
|
||||||
IsShouZhe = goods.IsShouZhe,
|
IsShouZhe = goods.IsShouZhe,
|
||||||
|
|
|
||||||
|
|
@ -1099,8 +1099,7 @@ public class UserBusinessService : IUserBusinessService
|
||||||
|
|
||||||
if (request.UserId.HasValue)
|
if (request.UserId.HasValue)
|
||||||
{
|
{
|
||||||
query = query.Where(u => u.Id == request.UserId.Value);
|
query = query.Where(u => u.Id == request.UserId.Value || u.Uid == request.UserId.ToString());
|
||||||
query = query.Where(u => u.Uid == request.UserId.ToString());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!string.IsNullOrWhiteSpace(request.Mobile))
|
if (!string.IsNullOrWhiteSpace(request.Mobile))
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,7 @@ export interface GoodsListItem {
|
||||||
flwEndTime: string | null
|
flwEndTime: string | null
|
||||||
openTime: string | null
|
openTime: string | null
|
||||||
choujiangXianzhi: number
|
choujiangXianzhi: number
|
||||||
|
unlockAmount: number
|
||||||
createdAt: string
|
createdAt: string
|
||||||
updatedAt: string
|
updatedAt: string
|
||||||
}
|
}
|
||||||
|
|
@ -81,6 +82,7 @@ export interface GoodsDetail extends GoodsListItem {
|
||||||
flwEndTime: string | null
|
flwEndTime: string | null
|
||||||
openTime: string | null
|
openTime: string | null
|
||||||
choujiangXianzhi: number
|
choujiangXianzhi: number
|
||||||
|
unlockAmount: number
|
||||||
goodsDescribe: string | null
|
goodsDescribe: string | null
|
||||||
newIs: number
|
newIs: number
|
||||||
isShouZhe: number
|
isShouZhe: number
|
||||||
|
|
@ -124,6 +126,7 @@ export interface GoodsCreateRequest {
|
||||||
xiajiaLirun?: number
|
xiajiaLirun?: number
|
||||||
xiajiaAutoCoushu?: number
|
xiajiaAutoCoushu?: number
|
||||||
xiajiaJine?: number
|
xiajiaJine?: number
|
||||||
|
unlockAmount?: number
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 更新盒子请求 */
|
/** 更新盒子请求 */
|
||||||
|
|
|
||||||
|
|
@ -497,6 +497,7 @@ const loadGoodsDetail = async () => {
|
||||||
formData.imgUrlDetail = detail.imgUrlDetail
|
formData.imgUrlDetail = detail.imgUrlDetail
|
||||||
formData.categoryId = detail.categoryId
|
formData.categoryId = detail.categoryId
|
||||||
formData.couponPro = detail.couponPro
|
formData.couponPro = detail.couponPro
|
||||||
|
formData.unlockAmount = (detail as any).unlockAmount || 0
|
||||||
|
|
||||||
// 福利屋时间
|
// 福利屋时间
|
||||||
formData.flwStartTime = detail.flwStartTime ? formatDateTime(detail.flwStartTime) : ''
|
formData.flwStartTime = detail.flwStartTime ? formatDateTime(detail.flwStartTime) : ''
|
||||||
|
|
@ -598,6 +599,7 @@ const handleSubmit = async () => {
|
||||||
xiajiaLirun: formData.xiajiaLirun,
|
xiajiaLirun: formData.xiajiaLirun,
|
||||||
xiajiaAutoCoushu: formData.xiajiaAutoCoushu,
|
xiajiaAutoCoushu: formData.xiajiaAutoCoushu,
|
||||||
xiajiaJine: formData.xiajiaJine,
|
xiajiaJine: formData.xiajiaJine,
|
||||||
|
unlockAmount: formData.unlockAmount,
|
||||||
}
|
}
|
||||||
|
|
||||||
await updateGoods(props.goodsId, requestData)
|
await updateGoods(props.goodsId, requestData)
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,14 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
|
<!-- 解锁金额 -->
|
||||||
|
<el-table-column label="解锁金额" width="100" align="center">
|
||||||
|
<template #default="{ row }">
|
||||||
|
<span v-if="row.unlockAmount > 0" class="unlock-value">¥{{ row.unlockAmount }}</span>
|
||||||
|
<span v-else class="text-muted">-</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
<!-- 福利屋时间信息 -->
|
<!-- 福利屋时间信息 -->
|
||||||
<el-table-column label="时间配置" width="180" v-if="hasFuLiWuType">
|
<el-table-column label="时间配置" width="180" v-if="hasFuLiWuType">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
|
|
@ -268,6 +276,11 @@ const formatTime = (time: string | null) => {
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.unlock-value {
|
||||||
|
color: #409eff;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
.image-error {
|
.image-error {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user