Commit ac21256c by 李伟康

Merge branch 'dev_lwk' into v3.24.0

2 parents 65ea12aa ace8a2a2
......@@ -137,6 +137,23 @@ img{
max-width: 80%;
}
}
.el-cascader-menu__list {
&::after{
position: absolute;
left: 0;
top: 0;
background-color: #fff;
width: 20px;
height: 20px;
content: '';
}
.el-cascader-node:not(.is-disabled):focus, .el-cascader-node:not(.is-disabled):hover {
position: relative;
z-index: 2;
}
}
.table_circular_flex{
display: flex;
align-items: center;
......
......@@ -39,9 +39,9 @@
slot="cover"
class="edit-tips"
>图片大小10M</div>
<template #endTimeType>
<template #endTimeLimit>
<div
v-if="configForm.endTimeType == 1"
v-if="configForm.endTimeLimit == 1"
class="item-box"
>
<el-date-picker
......@@ -64,7 +64,7 @@
:picker-options="afterRangePickerOptions"
value-format="yyyy-MM-dd HH:mm:ss"
class="end-time"
:disabled="(configForm.endTimeType == 1 && !configForm.endTime) || disabled "
:disabled="(configForm.endTimeLimit == 1 && !configForm.endTime) || disabled "
>
</el-date-picker>
</template>
......@@ -143,7 +143,7 @@ export default {
numLimit: 9,
numType: 1,
numWin: 0,
endTimeType: 0,
endTimeLimit: 0,
endTime: '',
lotteryTime: '',
groupLimitOpen: false,
......@@ -183,9 +183,12 @@ export default {
})
},
'configForm.groupLimitOpen' (n) {
if (n == 1 && !this.configForm.merchantId) {
this.configForm.groupLimitOpen = false
this.showError()
const { merchantId } = this.configForm
if (n == 1) {
if (!merchantId) {
this.configForm.groupLimitOpen = false
this.showError()
} else this.getMerchantWechatGroupList([merchantId])
}
},
'configForm.numWin' (n) {
......@@ -229,15 +232,11 @@ export default {
confName: data.merchantName
}]
let description = data.description,
endTimeType = 0,
numWin = data.numWin,
endTime = data.endTime,
groupLimitList = []
this.$refs.formRef.$refs.descriptionTextBox[0].setEdit(description)
if (endTime) {
if (endTime != data.lotteryTime) endTimeType = 1
endTime = dayjs(endTime).format('YYYY/MM/DD HH:mm:ss')
}
if (endTime) endTime = dayjs(endTime).format('YYYY/MM/DD HH:mm:ss')
if (data.numType == 1) numWin = 0
if (data.groupLimitOpen) {
data.groupLimits.map(e => {
......@@ -251,7 +250,7 @@ export default {
title: data.title,
cover: data.cover,
numLimit: data.numLimit,
endTimeType,
endTimeLimit: data.endTimeLimit,
lotteryTime: dayjs(data.lotteryTime).format('YYYY/MM/DD HH:mm:ss'),
groupLimitOpen: data.groupLimitOpen,
groupLimitList,
......@@ -281,8 +280,7 @@ export default {
const params = JSON.parse(JSON.stringify(this.configForm)),
{ relayLotteryId } = this
if (params.numType == 1) delete params.numWin
if (params.endTimeType == 0) {
delete params.endTimeType
if (params.endTimeLimit == 0) {
delete params.endTime
}
this.$loading()
......
......@@ -112,7 +112,7 @@ export const formData = that => {
{
label: '接龙结束时间',
type: 'radio',
name: 'endTimeType',
name: 'endTimeLimit',
optionList: [
{
text: '无限制',
......@@ -125,7 +125,7 @@ export const formData = that => {
],
optionId: 'id',
optionLabel: 'text',
suffixSlot: 'endTimeType',
suffixSlot: 'endTimeLimit',
isDisabled: false
},
{
......@@ -170,7 +170,7 @@ export const rule = that => {
cover: [{ required, message: '请上传卡片封面', trigger }],
numLimit: [{ required }],
numWin: [{ required }],
endTimeType: [{
endTimeLimit: [{
required,
validator: (rule, value, callback) => {
if (that.disabled) callback()
......@@ -195,7 +195,7 @@ export const rule = that => {
if (!value) throw '请选择接龙开奖时间'
else {
const valueTimestamp = dayjs(value).valueOf()
if (that.configForm.endTimeType != 1) {
if (that.configForm.endTimeLimit != 1) {
if (valueTimestamp < dayjs().valueOf()) throw '接龙开奖时间需大于当前时间'
} else {
if (valueTimestamp < dayjs(that.configForm.endTime).valueOf()) throw '接龙开奖时间需大于或等于接龙结束时间'
......
......@@ -211,7 +211,7 @@ export default {
prop: 'cardTitle',
minWidth: 100,
formatter: cell => {
return cell.numType == 1 ? `随机(${cell.numWin})` : cell.numWin
return cell.numType == 1 ? `随机(${cell.numWin || '--'})` : cell.numWin
}
},
{
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!