mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-12 04:16:47 +08:00
投票字段校验
This commit is contained in:
@@ -55,7 +55,7 @@
|
|||||||
<div v-if="ballotId > 0">
|
<div v-if="ballotId > 0">
|
||||||
<a-tag closable color="processing" @close="handlelog">
|
<a-tag closable color="processing" @close="handlelog">
|
||||||
<span style="font-size: 14px; line-height: 33px">
|
<span style="font-size: 14px; line-height: 33px">
|
||||||
删除投票
|
{{ ballot_name }}
|
||||||
</span>
|
</span>
|
||||||
</a-tag>
|
</a-tag>
|
||||||
</div>
|
</div>
|
||||||
@@ -64,6 +64,7 @@
|
|||||||
v-model:createVoteVisible="createVoteVisible"
|
v-model:createVoteVisible="createVoteVisible"
|
||||||
v-model:ballotId="ballotId"
|
v-model:ballotId="ballotId"
|
||||||
v-model:editChild="editChild"
|
v-model:editChild="editChild"
|
||||||
|
v-model:ballot_name="ballot_name"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<button
|
<button
|
||||||
@@ -75,7 +76,7 @@
|
|||||||
</button>
|
</button>
|
||||||
<div :style="{ display: creVote ? 'block' : 'none' }">
|
<div :style="{ display: creVote ? 'block' : 'none' }">
|
||||||
<div class="fileTigan">
|
<div class="fileTigan">
|
||||||
<span style="color: #388be1">{{ ballotName }}</span>
|
<span style="color: #388be1">{{ ballot_name }}</span>
|
||||||
<div class="delBox" @click="dleVoteStem()"></div>
|
<div class="delBox" @click="dleVoteStem()"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -93,6 +94,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
<div class="signbox">
|
<div class="signbox">
|
||||||
|
<div class="sign">
|
||||||
|
<img
|
||||||
|
src="@/assets/images/coursewareManage/asterisk.png"
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<span style="margin-right: 3px">起止时间:</span>
|
<span style="margin-right: 3px">起止时间:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
@@ -105,6 +112,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
<div class="signbox">
|
<div class="signbox">
|
||||||
|
<div class="sign">
|
||||||
|
<img
|
||||||
|
src="@/assets/images/coursewareManage/asterisk.png"
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<span style="margin-right: 3px">基础投票数:</span>
|
<span style="margin-right: 3px">基础投票数:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
@@ -142,6 +155,7 @@
|
|||||||
v-model:value="textV1"
|
v-model:value="textV1"
|
||||||
placeholder="请输入投票说明"
|
placeholder="请输入投票说明"
|
||||||
allow-clear
|
allow-clear
|
||||||
|
:rows="6"
|
||||||
maxlength="150"
|
maxlength="150"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
@@ -231,7 +245,7 @@ export default {
|
|||||||
voteStemId: null,
|
voteStemId: null,
|
||||||
EditVoteId: "",
|
EditVoteId: "",
|
||||||
voteStemName: "",
|
voteStemName: "",
|
||||||
ballotName: "",
|
ballot_name: "",
|
||||||
editStem: false, //编辑状态
|
editStem: false, //编辑状态
|
||||||
ballotId: 0, //题干id
|
ballotId: 0, //题干id
|
||||||
optionId: "", //删除,修改选项id
|
optionId: "", //删除,修改选项id
|
||||||
@@ -240,6 +254,7 @@ export default {
|
|||||||
fileList: [],
|
fileList: [],
|
||||||
voteCount: null,
|
voteCount: null,
|
||||||
projectTemplateId: null,
|
projectTemplateId: null,
|
||||||
|
|
||||||
});
|
});
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
(state.inputV1 = ""),
|
(state.inputV1 = ""),
|
||||||
@@ -289,6 +304,7 @@ export default {
|
|||||||
console.log("file========", file);
|
console.log("file========", file);
|
||||||
console.log("file========", file.response);
|
console.log("file========", file.response);
|
||||||
state.voteCount = file.response.data;
|
state.voteCount = file.response.data;
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
//fileList.value = resFileList;
|
//fileList.value = resFileList;
|
||||||
@@ -386,8 +402,12 @@ export default {
|
|||||||
return message.info("请创建题干信息");
|
return message.info("请创建题干信息");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (state.basevote == "") {
|
if (!state.time) {
|
||||||
state.basevote = 1;
|
message.destroy();
|
||||||
|
return message.warning("请输入直播时间");
|
||||||
|
}
|
||||||
|
if (!state.basevote) {
|
||||||
|
return message.info("请上传投票基数");
|
||||||
}
|
}
|
||||||
if (state.time != undefined) {
|
if (state.time != undefined) {
|
||||||
state.startTime = dayjs(state.time[0]).format("YYYY-MM-DD");
|
state.startTime = dayjs(state.time[0]).format("YYYY-MM-DD");
|
||||||
@@ -672,6 +692,27 @@ export default {
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: flex-start;
|
align-items: flex-start;
|
||||||
margin-bottom: 32px;
|
margin-bottom: 32px;
|
||||||
|
.textarea {
|
||||||
|
width: 423px;
|
||||||
|
|
||||||
|
.ant-input {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-input-textarea-show-count {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-input-textarea-show-count::after {
|
||||||
|
position: absolute;
|
||||||
|
right: 10px;
|
||||||
|
bottom: 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ant-input {
|
||||||
|
border-radius: 8px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.signbox {
|
.signbox {
|
||||||
width: 120px;
|
width: 120px;
|
||||||
|
|||||||
@@ -118,6 +118,10 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
ballot_name: {
|
||||||
|
type: String,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
editChild: {
|
editChild: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
@@ -150,6 +154,7 @@ export default {
|
|||||||
handleAllCancel();
|
handleAllCancel();
|
||||||
ctx.emit("update:createVoteVisible", false);
|
ctx.emit("update:createVoteVisible", false);
|
||||||
ctx.emit("update:ballotId", state.ballotId);
|
ctx.emit("update:ballotId", state.ballotId);
|
||||||
|
ctx.emit("update:ballot_name", state.ballotName);
|
||||||
};
|
};
|
||||||
// 详情
|
// 详情
|
||||||
const getInfoDate = async () => {
|
const getInfoDate = async () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user