dev_review
yujialong 1 year ago
parent 392d258acc
commit 85ab452faf
  1. 2
      src/components/upload/index.vue
  2. 2
      src/components/upload/upload.js
  3. 2
      src/setting.js
  4. 2
      src/views/match/add/index.vue
  5. 7
      src/views/match/add/step1.vue
  6. 8
      src/views/match/add/step2.vue
  7. 2
      src/views/match/add/step3.vue
  8. 12
      src/views/match/manage/matchRank.vue

@ -102,7 +102,7 @@ export default {
this.uploading = true
this.showFiles = false
// oss
const { name } = await this.client.multipartUpload(file.name, file, {
const { name } = await this.client.multipartUpload(Date.now() + '.' + Util.getFileExt(file.name), file, {
progress: this.handleProgress
});

@ -17,7 +17,7 @@ export default {
return new Promise(async (resolve, reject) => {
try {
// 上传到阿里云oss
const res = await client.multipartUpload(file.name, file);
const res = await client.multipartUpload(Date.now() + '.' + Util.getFileExt(file.name), file);
resolve({
format: Util.getFileExt(file.name),
name: file.name,

@ -13,7 +13,7 @@ if (isDev) {
sandPath = `http://${location.hostname}:9520`
host = 'http://121.37.12.51/'
// host = 'https://huorantech.cn/'
// host = 'http://192.168.31.217:9000/'// 榕
host = 'http://192.168.31.217:9000/'// 榕
// host = 'http://192.168.31.51:9000/'// 赓
} else if (isPro) {
jumpPath = 'https://www.huorantech.cn/judgmentPoint/'

@ -90,7 +90,7 @@
@click="save(1)">发布</el-button>
<el-button v-else
type="primary"
@click="save(id ? 1 : 0, 2)">保存并下一步</el-button>
@click="save(0, 2)">保存并下一步</el-button>
</template>
<el-button type="danger"
@click="preview"

@ -653,7 +653,7 @@ export default {
if (!form.name) return util.warningMsg("请填写竞赛名称");
//
if (next === 2) {
if (form.competitionScope == 2 && !form.competitionRangeList.length) return util.warningMsg('请选择区域、院校')
if (form.competitionScope == 2 && (!form.competitionRangeList || !form.competitionRangeList.length)) return util.warningMsg('请选择区域、院校')
if (!form.sponsor) return util.warningMsg("请填写主办方");
if (!form.signUpStartTime) return util.warningMsg("请选择报名时间");
let now = new Date().getTime();
@ -677,9 +677,12 @@ export default {
}
if (isNeedCode && (!invitationCode || invitationCode.length !== 4)) return util.warningMsg('请填写四位数邀请码')
if (!form.description) return util.warningMsg("请填写竞赛详情");
} else {
if (form.competitionScope == 2 && (!form.competitionRangeList || !form.competitionRangeList.length)) form.competitionScope = 1
}
this.$parent.showLoad()
form.publishStatus = status
delete form.publishStatus
if (status === 1) form.publishStatus = 1
form.ztOpen = status ? 0 : 1 //
form.releaseType = releaseType
form.id = this.$route.query.id

@ -153,7 +153,7 @@
style="width: 120px"></el-input>
小时公布阶段比赛成绩
</div>
<div v-if="item.resultAnnouncementTime != 0"
<div v-if="item.resultAnnouncementTime !== '' && item.resultAnnouncementTime !== null && item.resultAnnouncementTime !== undefined"
class="line">
是否公布成绩详情
<el-radio v-model="item.resultsDetails"
@ -362,10 +362,10 @@ export default {
const stages = this.form.competitionStageList
const { ruleId } = this.form
if (stages.length < val) {
const list = []
for (let i = 1; i <= val - stages.length; i++) {
const len = stages.length
for (let i = 1; i <= val - len; i++) {
const form = JSON.parse(JSON.stringify(this.ruleForm))
form.number = stages.length + i
form.number = len + i
if (ruleId) form.ruleId = ruleId
this.form.competitionStageList.push(form)
}

@ -154,7 +154,7 @@ export default {
updateTime: 0,
step1: this.$parent.$refs.step1.form,
cache: this.$store.state.competitionCache,
nums: ['一', '二', '三'],
nums: ['一', '二', '三', '四', '五', '六', '七', '八', '九', '十'],
methods: [
{
id: 0,

@ -148,8 +148,10 @@
:rowspan="item.rowspan">
<p class="score">{{ item.teamScore }}</p>
<p>{{ item.teamCalculationMethodName }}</p>
<template v-if="isPointWeight">
<p>权重</p>
<p>{{ item.pointWeight }}%</p>
</template>
</td>
</template>
<template v-if="item.accountId">
@ -324,7 +326,8 @@ export default {
},
uploaded: 0,
multipleSelection: [],
loading: false
loading: false,
isPointWeight: false
};
},
mounted () {
@ -443,11 +446,12 @@ export default {
data.stageIds = ids.splice(0, this.index + 1)
//
// if (this.published) {
this.$post(this.api.totalRankingScoreDetails, data).then(({ data }) => {
if (data.length) {
this.$post(this.api.totalRankingScoreDetails, data).then(res => {
this.isPointWeight = res.isPointWeight
if (res.data.length) {
const result = []
//
data.map(e => {
res.data.map(e => {
const team = e.stageTeamInformation
if (team.length) {
const teamCItem = this.teamCalculationMethods.find(n => n.id == e.teamCalculationMethod)

Loading…
Cancel
Save