整合文件
This commit is contained in:
parent
1db678cb87
commit
06f7c7b005
@ -25,16 +25,13 @@
|
|||||||
</a-checkable-tag>
|
</a-checkable-tag>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<a-checkbox-group
|
<a-checkbox-group v-model:value="data.isFinish" :options="options" class="mr-3" />
|
||||||
v-model:value="projCheckbox"
|
|
||||||
:options="checkboxOptions" />
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex flex-wrap justify-start ">
|
<div class="flex flex-wrap justify-start ">
|
||||||
<ProjectCard
|
<ProjectCard
|
||||||
class=""
|
class=""
|
||||||
v-for="proj in projList" v-bind="proj" @click=" console.log('routePath',routePath)
|
v-for="proj in projList" v-bind="proj" @click="handleCardClick"></ProjectCard>
|
||||||
"></ProjectCard>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<a-float-button-group v-show="routePath === '/WorkLoad/I_Responsible'" trigger="hover" type="primary" :style="{ right: '94px' }">
|
<a-float-button-group v-show="routePath === '/WorkLoad/I_Responsible'" trigger="hover" type="primary" :style="{ right: '94px' }">
|
||||||
@ -71,7 +68,7 @@
|
|||||||
|
|
||||||
<!-- </div>-->
|
<!-- </div>-->
|
||||||
<!-- <!– <a-button @click="setupProj">999</a-button> –>-->
|
<!-- <!– <a-button @click="setupProj">999</a-button> –>-->
|
||||||
<a-modal v-model:open="addModalOpen" title="添加项目" @ok="handleOk">
|
<a-modal v-model:open="addModalOpen" title="添加项目" @ok="">
|
||||||
<a-form
|
<a-form
|
||||||
:label-col="labelCol"
|
:label-col="labelCol"
|
||||||
:wrapper-col="wrapperCol"
|
:wrapper-col="wrapperCol"
|
||||||
@ -128,7 +125,7 @@
|
|||||||
<!-- </a-tooltip>-->
|
<!-- </a-tooltip>-->
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import {onMounted, reactive, ref} from 'vue';
|
import {onMounted, reactive, ref, watch} from 'vue';
|
||||||
import {CommentOutlined, MinusOutlined, PlusOutlined} from '@ant-design/icons-vue';
|
import {CommentOutlined, MinusOutlined, PlusOutlined} from '@ant-design/icons-vue';
|
||||||
import {useRoute, useRouter} from "vue-router";
|
import {useRoute, useRouter} from "vue-router";
|
||||||
|
|
||||||
@ -144,8 +141,28 @@ const data = reactive({
|
|||||||
isFinish: [0, 1, 2, -1],
|
isFinish: [0, 1, 2, -1],
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const options = [
|
||||||
|
{
|
||||||
|
label: '未开始',
|
||||||
|
value: 0,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '进行中',
|
||||||
|
value: 2,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '已完成',
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '已暂停',
|
||||||
|
value: -1,
|
||||||
|
},
|
||||||
|
]
|
||||||
|
|
||||||
//我负责的路径:/WorkLoad/I_Responsible
|
//我负责的路径:/WorkLoad/I_Responsible
|
||||||
const routePath = route.path
|
const routePath = route.path
|
||||||
|
const selectedTags =ref([])
|
||||||
|
|
||||||
// 完整的标签列表
|
// 完整的标签列表
|
||||||
const tagsData = ref([]);
|
const tagsData = ref([]);
|
||||||
@ -199,18 +216,25 @@ const handleClickAll=(checked)=>{
|
|||||||
// 当选中其他的时候, 全部 不选中
|
// 当选中其他的时候, 全部 不选中
|
||||||
const handleChange = (tag, checked) => {
|
const handleChange = (tag, checked) => {
|
||||||
|
|
||||||
if(checked){
|
tag.checked = checked; // 更新checkbox的选中状态
|
||||||
tagAll.value=false
|
|
||||||
|
if (checked) {
|
||||||
|
tagAll.value = false;
|
||||||
|
|
||||||
|
selectedTags.value.push(tag.name); // 将选中的tag.name添加到数组中
|
||||||
|
} else {
|
||||||
|
const index = selectedTags.value.indexOf(tag.name);
|
||||||
|
if (index !== -1) {
|
||||||
|
selectedTags.value.splice(index, 1); // 从数组中移除取消选中的tag.name
|
||||||
}
|
}
|
||||||
else{
|
let flag = true;
|
||||||
let flag=true
|
selectTags.value.forEach((item, index) => {
|
||||||
selectTags.value.forEach((item,index)=>{
|
if (item) {
|
||||||
if(item){
|
flag = false;
|
||||||
flag=false
|
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
if(flag){
|
if (flag) {
|
||||||
tagAll.value=true
|
tagAll.value = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@ -250,7 +274,18 @@ const handleCardClick=(id)=>{
|
|||||||
console.log(id)
|
console.log(id)
|
||||||
router.push('/WorkLoad/I_Responsible/'+id)
|
router.push('/WorkLoad/I_Responsible/'+id)
|
||||||
}
|
}
|
||||||
|
watch(() => selectedTags.value.length, async (newValue, oldValue) =>{
|
||||||
|
data.tags = []
|
||||||
|
selectedTags.value.forEach((item,index)=>{
|
||||||
|
data.tags.push(item)
|
||||||
|
})
|
||||||
|
console.log(selectedTags)
|
||||||
|
flush()
|
||||||
|
})
|
||||||
|
watch(() =>data.isFinish, async (newValue, oldValue) =>{
|
||||||
|
// console.log("data.isFinish", data.isFinish)
|
||||||
|
flush()
|
||||||
|
})
|
||||||
|
|
||||||
const setupProj=()=>{
|
const setupProj=()=>{
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user