技术方案库修改
This commit is contained in:
parent
991428f85a
commit
22acd6baa3
|
|
@ -64,7 +64,7 @@ export default {
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
if (this.value) {
|
if (this.value) {
|
||||||
this.activeCategory = this.value
|
this.activeCategory = this.value;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
|
@ -94,6 +94,7 @@ export default {
|
||||||
handleCategoryClick(id) {
|
handleCategoryClick(id) {
|
||||||
this.activeCategory = id
|
this.activeCategory = id
|
||||||
this.$emit('change', id)
|
this.$emit('change', id)
|
||||||
|
this.handleQuery();
|
||||||
},
|
},
|
||||||
handleCategoryCommand(command) {
|
handleCategoryCommand(command) {
|
||||||
if (command.type === 'edit') {
|
if (command.type === 'edit') {
|
||||||
|
|
|
||||||
|
|
@ -2,12 +2,12 @@
|
||||||
<!-- 技术方案列表 -->
|
<!-- 技术方案列表 -->
|
||||||
<div class="right-table-card">
|
<div class="right-table-card">
|
||||||
<TableModel :formLabel="formLabel" :showOperation="true" :showRightTools="false" ref="technicalTableRef"
|
<TableModel :formLabel="formLabel" :showOperation="true" :showRightTools="false" ref="technicalTableRef"
|
||||||
:columnsList="columnsList" :request-api="listAPI" :sendParams="{ enterpriseId }">
|
:columnsList="columnsList" :request-api="listAPI" :sendParams="{'technicalSolutionTypeId':value }">
|
||||||
<template slot="tableTitle">
|
<template slot="tableTitle">
|
||||||
<h3>数据列表</h3>
|
<h3>数据列表</h3>
|
||||||
</template>
|
</template>
|
||||||
<template slot="tableActions">
|
<template slot="tableActions">
|
||||||
<el-button @click="handleAdd" v-hasPermi="['enterpriseLibrary:technical:add']" class="add-btn"><i
|
<el-button @click="handleAdd" :disabled="disabled" v-hasPermi="['enterpriseLibrary:technical:add']" class="add-btn"><i
|
||||||
class="el-icon-plus"></i> 新增</el-button>
|
class="el-icon-plus"></i> 新增</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template slot="technicalSolutionState">
|
<template slot="technicalSolutionState">
|
||||||
|
|
@ -48,10 +48,10 @@ export default {
|
||||||
type: String,
|
type: String,
|
||||||
default: '0'
|
default: '0'
|
||||||
},
|
},
|
||||||
technicalSolutionTypeId: {
|
value: {
|
||||||
type: Number,
|
type: [String, Number],
|
||||||
default: null
|
default: null
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
@ -60,7 +60,19 @@ export default {
|
||||||
listAPI,
|
listAPI,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
watch: {
|
||||||
|
value(newVal){
|
||||||
|
if(newVal){
|
||||||
|
this.handleQuery();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
immediate: true
|
||||||
|
},
|
||||||
|
computed:{
|
||||||
|
disabled(){
|
||||||
|
return !this.value;
|
||||||
|
}
|
||||||
|
},
|
||||||
created() {
|
created() {
|
||||||
// 将字典数据填充到表单配置的下拉选项中
|
// 将字典数据填充到表单配置的下拉选项中
|
||||||
if (Array.isArray(this.formLabel)) {
|
if (Array.isArray(this.formLabel)) {
|
||||||
|
|
@ -80,8 +92,9 @@ export default {
|
||||||
name: 'TechnicalAdd',
|
name: 'TechnicalAdd',
|
||||||
query: {
|
query: {
|
||||||
enterpriseId: encryptWithSM4(this.enterpriseId || '0'),
|
enterpriseId: encryptWithSM4(this.enterpriseId || '0'),
|
||||||
technicalSolutionTypeId: encryptWithSM4(this.technicalSolutionTypeId + '' || '0'),
|
technicalSolutionTypeId: encryptWithSM4(this.value + '' || '0'),
|
||||||
type: encryptWithSM4('add'),
|
technicalSolutionId: encryptWithSM4('0'),
|
||||||
|
type: encryptWithSM4('add')
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
@ -92,7 +105,7 @@ export default {
|
||||||
name: 'TechnicalEdit',
|
name: 'TechnicalEdit',
|
||||||
query: {
|
query: {
|
||||||
enterpriseId: encryptWithSM4(this.enterpriseId || '0'),
|
enterpriseId: encryptWithSM4(this.enterpriseId || '0'),
|
||||||
technicalSolutionTypeId: encryptWithSM4(this.technicalSolutionTypeId + '' || '0'),
|
technicalSolutionTypeId: encryptWithSM4(this.value || '0'),
|
||||||
type: encryptWithSM4('edit'),
|
type: encryptWithSM4('edit'),
|
||||||
technicalSolutionId: encryptWithSM4(row.technicalSolutionId + '' || '0'),
|
technicalSolutionId: encryptWithSM4(row.technicalSolutionId + '' || '0'),
|
||||||
}
|
}
|
||||||
|
|
@ -100,11 +113,13 @@ export default {
|
||||||
},
|
},
|
||||||
/** 查看操作 */
|
/** 查看操作 */
|
||||||
handleDetail(row) {
|
handleDetail(row) {
|
||||||
|
console.log(row);
|
||||||
|
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: 'TechnicalDetail',
|
name: 'TechnicalDetail',
|
||||||
query: {
|
query: {
|
||||||
enterpriseId: encryptWithSM4(this.enterpriseId || '0'),
|
enterpriseId: encryptWithSM4(this.enterpriseId || '0'),
|
||||||
technicalSolutionTypeId: encryptWithSM4(this.technicalSolutionTypeId + '' || '0'),
|
technicalSolutionTypeId: encryptWithSM4(row.technicalSolutionTypeId + '' || '0'),
|
||||||
type: encryptWithSM4('detail'),
|
type: encryptWithSM4('detail'),
|
||||||
technicalSolutionId: encryptWithSM4(row.technicalSolutionId + '' || '0'),
|
technicalSolutionId: encryptWithSM4(row.technicalSolutionId + '' || '0'),
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,6 @@
|
||||||
<!-- 企业主体库表单 -->
|
<!-- 企业主体库表单 -->
|
||||||
<template>
|
<template>
|
||||||
<div class="app-container" :class="{ 'no-pointer-events': showUploadAnimation || showSaveAnimation }">
|
<div class="app-container">
|
||||||
<!-- 全局上传动画 -->
|
|
||||||
<GlobalUploadAnimation v-if="showUploadAnimation" :text="animationText" subtext="正在处理文件,请稍候..." />
|
|
||||||
<!-- 保存动画 -->
|
|
||||||
<GlobalUploadAnimation v-if="showSaveAnimation" text="数据上传中" subtext="请稍后,正在保存数据..." />
|
|
||||||
|
|
||||||
<div class="content-header">
|
<div class="content-header">
|
||||||
<el-button class="reset-btn" @click="handleClose()">返回</el-button>
|
<el-button class="reset-btn" @click="handleClose()">返回</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,7 @@ export default {
|
||||||
async getDetail() {
|
async getDetail() {
|
||||||
if (this.type === 'edit') {
|
if (this.type === 'edit') {
|
||||||
const res = await getDetailDataAPI({ technicalSolutionTypeId: this.technicalSolutionTypeId,
|
const res = await getDetailDataAPI({ technicalSolutionTypeId: this.technicalSolutionTypeId,
|
||||||
technicalSolutionId: this.technicalSolutionId })
|
technicalSolutionId: this.technicalSolutionId,type:'edit' })
|
||||||
console.log('res:', res);
|
console.log('res:', res);
|
||||||
this.detailData = res.data;
|
this.detailData = res.data;
|
||||||
}
|
}
|
||||||
|
|
@ -216,6 +216,93 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 全局上传动画样式
|
||||||
|
.global-upload-animation {
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
z-index: 9999;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
|
||||||
|
// 动画区域本身可以有点击事件(如果需要)
|
||||||
|
pointer-events: auto;
|
||||||
|
|
||||||
|
.animation-mask {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
background: rgba(255, 255, 255, 0.6); // 添加半透明背景
|
||||||
|
backdrop-filter: blur(4px);
|
||||||
|
|
||||||
|
// 遮罩层阻止点击
|
||||||
|
pointer-events: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.animation-content {
|
||||||
|
position: relative;
|
||||||
|
z-index: 10000;
|
||||||
|
text-align: center;
|
||||||
|
background: linear-gradient(135deg, #ffffff 0%, #f8faff 100%);
|
||||||
|
padding: 40px 50px;
|
||||||
|
border-radius: 20px;
|
||||||
|
box-shadow:
|
||||||
|
0 10px 40px rgba(31, 114, 234, 0.15),
|
||||||
|
0 0 0 1px rgba(31, 114, 234, 0.1);
|
||||||
|
min-width: 280px;
|
||||||
|
animation: slideInUp 0.3s ease-out;
|
||||||
|
|
||||||
|
// 动画内容可以有点击事件
|
||||||
|
pointer-events: auto;
|
||||||
|
|
||||||
|
.spinner {
|
||||||
|
width: 60px;
|
||||||
|
height: 60px;
|
||||||
|
border: 4px solid #f3f7ff;
|
||||||
|
border-top: 4px solid #1F72EA;
|
||||||
|
border-radius: 50%;
|
||||||
|
animation: spin 1.2s linear infinite;
|
||||||
|
margin: 0 auto 20px;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
&::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
top: -4px;
|
||||||
|
left: -4px;
|
||||||
|
right: -4px;
|
||||||
|
bottom: -4px;
|
||||||
|
border: 4px solid transparent;
|
||||||
|
border-top: 4px solid #4A8BFF;
|
||||||
|
border-radius: 50%;
|
||||||
|
animation: spin 0.8s linear infinite reverse;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.animation-text {
|
||||||
|
font-size: 20px;
|
||||||
|
font-weight: 600;
|
||||||
|
color: #1F72EA;
|
||||||
|
margin-bottom: 8px;
|
||||||
|
background: linear-gradient(135deg, #1F72EA 0%, #4A8BFF 100%);
|
||||||
|
-webkit-background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
|
background-clip: text;
|
||||||
|
}
|
||||||
|
|
||||||
|
.animation-subtext {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #666;
|
||||||
|
opacity: 0.8;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.content-body {
|
.content-body {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@
|
||||||
@category-command="handleCategoryCommand" :enterpriseId="enterpriseId" />
|
@category-command="handleCategoryCommand" :enterpriseId="enterpriseId" />
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="20" class="right-col">
|
<el-col :span="20" class="right-col">
|
||||||
<RightTable :technicalSolutionTypeId="activeCategory" @add-scheme="handleAddScheme" @view="handleView"
|
<RightTable :value="activeCategory" @add-scheme="handleAddScheme" @view="handleView"
|
||||||
@edit="handleEdit" @delete="handleDelete" :enterpriseId="enterpriseId" />
|
@edit="handleEdit" @delete="handleDelete" :enterpriseId="enterpriseId" />
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue