|
@@ -15,7 +15,7 @@
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="24" :style="allDetail">
|
|
<el-col :span="24" :style="allDetail">
|
|
<el-col :span="24" class="title">项目基本信息
|
|
<el-col :span="24" class="title">项目基本信息
|
|
- <i class="el-icon-edit editDetail" v-if="user.parentId == 1 || user.isManager == 1" @click="edit"></i>
|
|
|
|
|
|
+ <i class="el-icon-edit editDetail" v-if="user.parentId == 1 || user.id == proDetail.managerId" @click="edit"></i>
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="24" class="main">
|
|
<el-col :span="24" class="main">
|
|
<el-col :span="6" class="detail">
|
|
<el-col :span="6" class="detail">
|
|
@@ -65,7 +65,7 @@
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="24" class="title">项目文档
|
|
<el-col :span="24" class="title">项目文档
|
|
- <el-upload class="upload-demo" action="customize" :http-request="uploadFile" :show-file-list="false" multiple :limit="5" style="float:right;">
|
|
|
|
|
|
+ <el-upload v-if="update == 1" class="upload-demo" action="customize" :http-request="uploadFile" :show-file-list="false" multiple :limit="5" style="float:right;">
|
|
<el-button size="small" type="primary">点击上传</el-button>
|
|
<el-button size="small" type="primary">点击上传</el-button>
|
|
</el-upload>
|
|
</el-upload>
|
|
</el-col>
|
|
</el-col>
|
|
@@ -77,28 +77,26 @@
|
|
<el-table-column prop="uploader" label="上传者" width="120" align="center" sortable></el-table-column>
|
|
<el-table-column prop="uploader" label="上传者" width="120" align="center" sortable></el-table-column>
|
|
<el-table-column prop="indate" label="上传时间" width="200" align="center" sortable></el-table-column>
|
|
<el-table-column prop="indate" label="上传时间" width="200" align="center" sortable></el-table-column>
|
|
<el-table-column label="操作" width="220" align="center" sortable>
|
|
<el-table-column label="操作" width="220" align="center" sortable>
|
|
- <template slot-scope="scope">
|
|
|
|
|
|
+ <template slot-scope="scope" v-if="download == 1">
|
|
<el-button size="small" @click="dowloadFile(scope.row.id)">
|
|
<el-button size="small" @click="dowloadFile(scope.row.id)">
|
|
- <a :href="scope.row.url" :download="scope.row.fileName">下载</a></el-button>
|
|
|
|
|
|
+ <a :href="scope.row.url" :download="scope.row.fileName">下载</a>
|
|
|
|
+ </el-button>
|
|
<el-button size="small" type="danger" @click="fileDel(scope.row.id)" v-if="scope.row.uploaderId == user.id">删除</el-button>
|
|
<el-button size="small" type="danger" @click="fileDel(scope.row.id)" v-if="scope.row.uploaderId == user.id">删除</el-button>
|
|
</template>
|
|
</template>
|
|
|
|
+ <template slot-scope="scope" v-if="download == 0">
|
|
|
|
+ -
|
|
|
|
+ </template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
<el-col :span="24" class="title">操作记录</el-col>
|
|
<el-col :span="24" class="title">操作记录</el-col>
|
|
- <el-table :data="operations" highlight-current-row v-loading="listLoading" height="400" style="width: 100%;">
|
|
|
|
|
|
+ <el-table :data="opers" highlight-current-row v-loading="oplistLoading" height="400" style="width: 100%;">
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
- <el-table-column prop="name" label="姓名" width="400" sortable></el-table-column>
|
|
|
|
- <el-table-column prop="document" label="文档名称" sortable></el-table-column>
|
|
|
|
- <el-table-column label="操作" width="400" sortable>
|
|
|
|
- <template slot-scope="scope">
|
|
|
|
- <span v-if="scope.row.operations == 0">浏览</span>
|
|
|
|
- <span v-else-if="scope.row.operations == 1">下载</span>
|
|
|
|
- <span v-else>删除</span>
|
|
|
|
- </template>
|
|
|
|
- </el-table-column>
|
|
|
|
- <el-table-column prop="time" label="时间" width="400" sortable></el-table-column>
|
|
|
|
|
|
+ <el-table-column prop="content" label="操作" width="120" sortable></el-table-column>
|
|
|
|
+ <el-table-column prop="fileName" label="操作文档名称" sortable></el-table-column>
|
|
|
|
+ <el-table-column prop="operator" label="操作人" width="120" sortable></el-table-column>
|
|
|
|
+ <el-table-column prop="indate" label="操作时间" width="200" sortable></el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
@@ -185,6 +183,7 @@
|
|
//临时数据
|
|
//临时数据
|
|
proDetail: {},
|
|
proDetail: {},
|
|
files: [],
|
|
files: [],
|
|
|
|
+ opers: [],
|
|
|
|
|
|
allDetail: {
|
|
allDetail: {
|
|
overflow: 'auto',
|
|
overflow: 'auto',
|
|
@@ -193,8 +192,14 @@
|
|
},
|
|
},
|
|
|
|
|
|
listLoading: false,
|
|
listLoading: false,
|
|
|
|
+ oplistLoading: false,
|
|
activePage: 0,
|
|
activePage: 0,
|
|
|
|
|
|
|
|
+ update: 0,
|
|
|
|
+ download: 0,
|
|
|
|
+ view: 0,
|
|
|
|
+ approve: 0,
|
|
|
|
+
|
|
company:[],
|
|
company:[],
|
|
assets: [],
|
|
assets: [],
|
|
produce: [],
|
|
produce: [],
|
|
@@ -248,6 +253,11 @@
|
|
id: this.detailId
|
|
id: this.detailId
|
|
}, res => {
|
|
}, res => {
|
|
if (res.code == "ok") {
|
|
if (res.code == "ok") {
|
|
|
|
+ this.update = res.data.update;
|
|
|
|
+ this.download = res.data.download;
|
|
|
|
+ this.view = res.data.view;
|
|
|
|
+ this.approve = res.data.approve;
|
|
|
|
+
|
|
var list = res.data.vo;
|
|
var list = res.data.vo;
|
|
var approves = res.data.vo.approves;
|
|
var approves = res.data.vo.approves;
|
|
|
|
|
|
@@ -298,9 +308,32 @@
|
|
});
|
|
});
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+ getOperList() {
|
|
|
|
+ this.oplistLoading = true;
|
|
|
|
+ // 获取文档列表
|
|
|
|
+ this.http.post(this.port.project.operList, {
|
|
|
|
+ projectId: this.detailId
|
|
|
|
+ }, res => {
|
|
|
|
+ this.oplistLoading = false;
|
|
|
|
+ if (res.code == "ok") {
|
|
|
|
+ this.opers = res.data;
|
|
|
|
+ } else {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: res.msg,
|
|
|
|
+ type: 'error'
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ }, error => {
|
|
|
|
+ this.oplistLoading = false;
|
|
|
|
+ this.$message({
|
|
|
|
+ message: error,
|
|
|
|
+ type: 'error'
|
|
|
|
+ });
|
|
|
|
+ })
|
|
|
|
+ },
|
|
//获取信息
|
|
//获取信息
|
|
getMsg() {
|
|
getMsg() {
|
|
- // 获取公司
|
|
|
|
|
|
+ // 获取人员
|
|
var compIds = this.user.companyId;
|
|
var compIds = this.user.companyId;
|
|
for(var i in this.proDetail.customCompanies){
|
|
for(var i in this.proDetail.customCompanies){
|
|
compIds += "," + this.proDetail.customCompanies[i].companyId;
|
|
compIds += "," + this.proDetail.customCompanies[i].companyId;
|
|
@@ -334,8 +367,8 @@
|
|
});
|
|
});
|
|
})
|
|
})
|
|
|
|
|
|
- // 获取人员
|
|
|
|
- this.http.post(this.port.base.companys, {
|
|
|
|
|
|
+ // 获取公司
|
|
|
|
+ this.http.post(this.port.base.addCompanyListToProject, {
|
|
parentId: this.user.parentId,
|
|
parentId: this.user.parentId,
|
|
id: this.user.id
|
|
id: this.user.id
|
|
}, res => {
|
|
}, res => {
|
|
@@ -628,6 +661,7 @@
|
|
mounted() {
|
|
mounted() {
|
|
this.getDetail();
|
|
this.getDetail();
|
|
this.getFileList();
|
|
this.getFileList();
|
|
|
|
+ this.getOperList();
|
|
}
|
|
}
|
|
};
|
|
};
|
|
</script>
|
|
</script>
|