main #139

Merged
charles merged 2 commits from main into prod 2026-07-15 17:04:36 +08:00
2 changed files with 14 additions and 18 deletions

View File

@ -338,7 +338,10 @@ export default Vue.extend({
supplySquare: isEn ? 'Supply Square' : '供需广场', supplySquare: isEn ? 'Supply Square' : '供需广场',
// about: isEn ? 'About Us' : '' // about: isEn ? 'About Us' : ''
} }
return this.productMenuItems.map(item => ({ ...item, label: labels[item.action] || item.action })) const hiddenNcmatchActions = ['computeMarket', 'trainPlatform', 'agentStore']
return this.productMenuItems
.filter(item => !this.isNcmatchDomain || !hiddenNcmatchActions.includes(item.action))
.map(item => ({ ...item, label: labels[item.action] || item.action }))
}, },
aiPanelStyle() { aiPanelStyle() {
if (this.aiPanelPosition.left === null || this.aiPanelPosition.top === null) return {} if (this.aiPanelPosition.left === null || this.aiPanelPosition.top === null) return {}

View File

@ -152,11 +152,11 @@
</div> </div>
<div class="card-foot"> <div class="card-foot">
<span class="price">{{ getPriceText(item) }}</span> <span class="price">{{ getPriceText(item) }}</span>
<button type="button" @click="openDetail(item)"> <!-- <button type="button" @click="openDetail(item)">
查看详情 查看详情
<i v-if="loadingStates[item.id]" class="el-icon-loading"></i> <i v-if="loadingStates[item.id]" class="el-icon-loading"></i>
<span v-else></span> <span v-else></span>
</button> </button> -->
</div> </div>
</article> </article>
</div> </div>
@ -381,6 +381,7 @@ export default {
filteredPlazaDemandList() { filteredPlazaDemandList() {
const keyword = this.keyword.toLowerCase() const keyword = this.keyword.toLowerCase()
return this.plazaDemandData.filter(item => { return this.plazaDemandData.filter(item => {
if (item.isPublishedDemand) return false
const matchTab = this.currentPlazaTab === '全部' || item.type === this.currentPlazaTab const matchTab = this.currentPlazaTab === '全部' || item.type === this.currentPlazaTab
const matchSearch = !keyword || [ const matchSearch = !keyword || [
item.title, item.title,
@ -524,24 +525,16 @@ export default {
formData.append('contact_person', this.demandForm.contact) formData.append('contact_person', this.demandForm.contact)
formData.append('phone_number', this.demandForm.phone) formData.append('phone_number', this.demandForm.phone)
formData.append('application_scenario', this.demandForm.scenario) formData.append('application_scenario', this.demandForm.scenario)
const submittedDemand = {
title: this.demandForm.title,
company: this.demandForm.company,
type: this.demandForm.type,
scenario: this.demandForm.scenario,
tags: [this.demandForm.type].filter(Boolean),
desc: this.demandForm.desc
}
reqPublishProductAdd(formData).then(res => { reqPublishProductAdd(formData).then(res => {
if (res.status) { if (res.status) {
this.plazaDemandData.unshift(submittedDemand) this.plazaDemandData = this.plazaDemandData.filter(item => {
this.currentPlazaTab = '全部' return item.title !== this.demandForm.title || item.desc !== this.demandForm.desc
})
this.publishDemandVisible = false this.publishDemandVisible = false
this.resetDemandForm() this.resetDemandForm()
this.$message.success(res.msg || '需求发布成功!') this.$message.success('需求发布成功!')
} else { } else {
this.$message.error(res.msg || '需求发布失败') this.$message.error('需求发布失败')
} }
}).catch(() => { }).catch(() => {
this.$message.error('需求发布失败,请稍后重试') this.$message.error('需求发布失败,请稍后重试')