Начало переверстки Project

This commit is contained in:
Vitaly committed 2023-09-06 08:59:08 +03:00
1 parent 4716effcf7
commit d8974877d2
2 files changed
+42 -27

No files matched your search

+25 -12
View File
@@ -250,13 +250,16 @@
</template>
<template #4>
<v-container>
<v-container style="height:100%">
<v-row style="height:100%">
<v-col>
<v-col class="flex-col justify-space-between">
<v-treeview
:active.sync="selection"
:active.sync="selection[0]"
:items="newproject.tasks"
:selection-type="'independent'"
hoverable
@@ -265,16 +268,20 @@
item-children="task_work"
open-all
></v-treeview>
<v-btn
@click="addtask"
>Добавить задачу</v-btn>
</v-col>
<v-divider vertical></v-divider>
<v-col
class="pa-6"
class="flex-col justify-space-between"
cols="6"
>
<template v-if="!selection.length">
Ничего не выбрано
</template>
<template v-else>
<div>
<div
v-for="node in selection"
:key="node.id"
@@ -416,16 +423,21 @@
></v-textarea>
</template>
</row-pirow>
</div>
<v-btn
v-if="'task_work' in selection[0]"
@click="addwork"
>Добавить работу</v-btn>
</div>
</template>
</v-col>
</v-row>
</v-container>
<b-btn>Добавить задачу</b-btn>
@@ -1068,14 +1080,15 @@ formatDate (date) {
this.newproject.info[rem.field].splice(rem.key, 1)
},
newTask() {
this.newproject.tasks.push({id: this.indx, longname: "", name:"Новая задача", description: "", datestart: "", dateend: "", responsible: "", task_work:[]})
this.indx--
addtask() {
this.newproject.tasks.push({id: -1*(this.newproject.tasks.length), longname: "", name:"Новая задача", description: "", datestart: "", dateend: "", responsible: "", task_work:[]})
this.selection[0]=this.newproject.tasks[this.newproject.tasks.length-1]
},
adddwork() {
this.selected.task_work.push({id: this.indexwork, longname: "", name:"Новая работа", description: "", datestart: "", dateend: "", responsible: ""})
this.indexwork--
addwork() {
console.log(this.selection);
this.selection[0].task_work.push({id: -1*(this.selection[0].task_work.length), longname: "", name:"Новая работа", description: "", datestart: "", dateend: "", responsible: ""})
this.selection[0]= this.selection[0].task_work[this.selection[0].task_work.length-1]
},
deltasksworks() {
+17 -15
View File
@@ -92,6 +92,19 @@
@createtabchat="createtabchat"
@changestatus="changestatus"
/>
<div>
<v-dialog
v-model="show_change_dialog"
width="75vw"
>
<project-stepper
@closes="closes"
@newproject='newproject'
@showuserinfo='showuserinfo'
/>
</v-dialog>
</div>
</template>
<template #projdocs>
@@ -130,24 +143,12 @@
<template #graphic>
<div>
<v-dialog
v-model="show_change_dialog"
width="75vw"
>
<project-stepper
@closes="closes"
@newproject='newproject'
@showuserinfo='showuserinfo'
/>
</v-dialog>
</div>
<work-pie-chart
:title="'Статусы задач в проекте'"
:data="task_statuses_calc"
/>
</template>
</work-task-ass-project>
@@ -211,7 +212,7 @@ export default {
},
data: () => ({
show_change_dialog:true,
show_change_dialog:false,
statid: [1, 3, 4, 5, 6],
message: {mes:"", show: false},
comment:"",
@@ -490,10 +491,11 @@ takeprev(payload){
data.project_files.forEach((el,index)=> data.project_files[index].visible =el.visible.split("") )
this.project=data;
console.log(this.project, 'this.project');
console.log(this.project, 'this.project _2load');
this.setProject(this.project)
this.tasksaccepted=this.getProject.tasks.filter(el=>el.status.id==5).length*100/this.getProject.tasks.length
this.setLoad(false)
// if (this.gantview) this.$refs.gantproject.rebuild()
if("datachat" in data){