bug
This commit is contained in:
@@ -68,12 +68,10 @@
|
|||||||
getList() {
|
getList() {
|
||||||
if (this.pageNum > this.pages) return
|
if (this.pageNum > this.pages) return
|
||||||
this.$instance.post(`/app/appgeneralelectioninfo/list-xcx?partyId=${this.partyId}¤t=${this.pageNum}&size=${this.pageSize}`, null, {}).then(res => {
|
this.$instance.post(`/app/appgeneralelectioninfo/list-xcx?partyId=${this.partyId}¤t=${this.pageNum}&size=${this.pageSize}`, null, {}).then(res => {
|
||||||
console.log(res)
|
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
const list = this.pageNum > 1 ? [...this.list, ...res.data.records] : res.data.records
|
const list = this.pageNum > 1 ? [...this.list, ...res.data.records] : res.data.records
|
||||||
this.pages = Math.ceil(res.data.total / 10)
|
this.pages = Math.ceil(res.data.total / 10)
|
||||||
this.list = list
|
this.list = list
|
||||||
console.log(this.list)
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -42,8 +42,9 @@
|
|||||||
<view class="mask" v-if="showMask">
|
<view class="mask" v-if="showMask">
|
||||||
<view class="mask-content">
|
<view class="mask-content">
|
||||||
<view class="mask-title">投票说明</view>
|
<view class="mask-title">投票说明</view>
|
||||||
<view class="mask-text">1、本次选举采用无记名投票方式,差额选举的办法,选举第十一届村民委员会主任1名。选举工作由选举委员会主持,未尽事宜由选举委员会研究决定;</view>
|
<!-- <view class="mask-text">1、本次选举采用无记名投票方式,差额选举的办法</view>
|
||||||
<view class="mask-text">2、差额选举的办法,选举第十一届村民委员会主任1名。选举工作由选举委员会主持,未尽事宜由选举委员会研究决定。</view>
|
<view class="mask-text">2、选举工作由选举委员会主持,未尽事宜由选举委员会研究决定。</view> -->
|
||||||
|
<view class="mask-text">{{ votingInstructions }}</view>
|
||||||
<view class="mask-btn" @click="closeMask()">关闭</view>
|
<view class="mask-btn" @click="closeMask()">关闭</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -62,7 +63,8 @@ export default {
|
|||||||
showMask: false,
|
showMask: false,
|
||||||
title: '',
|
title: '',
|
||||||
chooseNumber: '',
|
chooseNumber: '',
|
||||||
partyId: ''
|
partyId: '',
|
||||||
|
votingInstructions: '',
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
@@ -86,14 +88,14 @@ export default {
|
|||||||
uni.showToast({title: `投票人数大于应选人数,请重试`, icon: 'none'})
|
uni.showToast({title: `投票人数大于应选人数,请重试`, icon: 'none'})
|
||||||
flags = false
|
flags = false
|
||||||
}
|
}
|
||||||
// if (checkNum < this.chooseNumber) {
|
if (checkNum < this.chooseNumber) {
|
||||||
// uni.showToast({title: `请给候选人投票`, icon: 'none'})
|
|
||||||
// flags = false
|
|
||||||
// }
|
|
||||||
if (checkNum < this.userList.length) {
|
|
||||||
uni.showToast({title: `请给候选人投票`, icon: 'none'})
|
uni.showToast({title: `请给候选人投票`, icon: 'none'})
|
||||||
flags = false
|
flags = false
|
||||||
}
|
}
|
||||||
|
// if (checkNum < this.userList.length) {
|
||||||
|
// uni.showToast({title: `请给候选人投票`, icon: 'none'})
|
||||||
|
// flags = false
|
||||||
|
// }
|
||||||
|
|
||||||
if (!flags) return
|
if (!flags) return
|
||||||
this.$instance.post('/app/appgeneralelectioninfo/vote', checkList).then(res => {
|
this.$instance.post('/app/appgeneralelectioninfo/vote', checkList).then(res => {
|
||||||
@@ -123,6 +125,7 @@ export default {
|
|||||||
getDetailInfo() {
|
getDetailInfo() {
|
||||||
this.$instance.post(`/app/appgeneralelectioninfo/queryDetailById?id=${this.detailId}`, null).then(res => {
|
this.$instance.post(`/app/appgeneralelectioninfo/queryDetailById?id=${this.detailId}`, null).then(res => {
|
||||||
if (res.data) {
|
if (res.data) {
|
||||||
|
this.votingInstructions = res.data.votingInstructions
|
||||||
this.chooseNumber = res.data.chooseNumber
|
this.chooseNumber = res.data.chooseNumber
|
||||||
this.title = res.data.title
|
this.title = res.data.title
|
||||||
res.data.candidateUsers.map((item) => {
|
res.data.candidateUsers.map((item) => {
|
||||||
@@ -131,7 +134,7 @@ export default {
|
|||||||
"candidateUserName": item.name,
|
"candidateUserName": item.name,
|
||||||
"electionId": this.detailId,
|
"electionId": this.detailId,
|
||||||
"voteStatus": '',
|
"voteStatus": '',
|
||||||
"voterUserId": this.partyId
|
"voterUserId": this.partyId,
|
||||||
}
|
}
|
||||||
this.userList.push(info)
|
this.userList.push(info)
|
||||||
})
|
})
|
||||||
@@ -294,6 +297,7 @@ export default {
|
|||||||
margin: 200px auto 0;
|
margin: 200px auto 0;
|
||||||
padding: 48px 48px 0;
|
padding: 48px 48px 0;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
overflow-y: scroll;
|
||||||
|
|
||||||
.mask-title {
|
.mask-title {
|
||||||
font-size: 32px;
|
font-size: 32px;
|
||||||
@@ -321,7 +325,7 @@ export default {
|
|||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: #1365DD;
|
color: #1365DD;
|
||||||
line-height: 40px;
|
line-height: 40px;
|
||||||
margin: 60px 0 0 332px;
|
margin: 60px 0 20px 332px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user