| | |
| | | label="操作" |
| | | align="center" |
| | | fixed="right" |
| | | width="300" |
| | | class-name="small-padding fixed-width" |
| | | > |
| | | <template slot-scope="scope"> |
| | |
| | | v-if="scope.row.recordstatus == -1 || scope.row.recordstatus == 1" |
| | | size="mini" |
| | | type="text" |
| | | icon="el-icon-delete" |
| | | @click="handleDelete(scope.row)" |
| | | >删除</el-button |
| | | ><span class="button-delete" |
| | | ><i class="el-icon-delete"></i>删除</span |
| | | ></el-button |
| | | > |
| | | <!-- v-hasPermi="['project:funddetail:remove']" --> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column fixed="right" align="center" width="120" label="功能"> |
| | | <template slot-scope="scope"> |
| | | <el-button size="mini" v-if="scope.row.uploadStates == 1" |
| | | >线下已报销</el-button |
| | | > |
| | | <el-button |
| | | size="mini" |
| | | type="success" |
| | | v-else-if="scope.row.uploadStates == 0" |
| | | @click="Dooffline('1', scope.row)" |
| | | >线下报销</el-button |
| | | > |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | import { getUser, getUserProfile } from "@/api/system/user"; |
| | | import { treeselect } from "@/api/system/dept"; |
| | | import { getSubsidy } from "@/api/project/travelcity"; |
| | | import { addorupdateFund } from "@/api/project/fund"; |
| | | import { listReportname, listUser } from "@/api/project/organization"; |
| | | import { getToken } from "@/utils/auth"; |
| | | export default { |
| | |
| | | |
| | | handleExceed() { |
| | | this.$message.error(`上传文件数量不能超过 ${5} 个!`); |
| | | }, |
| | | Dooffline(a, value) { |
| | | value.uploadStates = 1; |
| | | value.notes = "线下已报销"; |
| | | addorupdateFund(value).then(res => { |
| | | if (res.code == 200) { |
| | | this.$modal.msgSuccess("记录成功"); |
| | | } else { |
| | | this.$modal.msgError(res.msg); |
| | | } |
| | | }); |
| | | }, |
| | | |
| | | //文件上传成功回调 |
| | |
| | | console.log(url); |
| | | const link = document.createElement("a"); |
| | | link.href = url; |
| | | const name=fileUrl["downloadName"] |
| | | const name = fileUrl["downloadName"]; |
| | | link.setAttribute("download", name); // 替换file.pdf为实际的文件名 |
| | | document.body.appendChild(link); |
| | | link.click(); |
| | |
| | | //明显提示审批退回记录 |
| | | rowClassName({ row, column, rowIndex, columnIndex }) { |
| | | //此判断为最后三行 |
| | | if (row.backflowlevel == 199) { |
| | | return "addClassva"; |
| | | if (row.recordstatus == -1 && row.backflowlevel != null) { |
| | | return "error-row"; |
| | | } |
| | | return ""; |
| | | } |
| | | } |
| | | }; |
| | | </script> |
| | | <!-- <style scoped> --> |
| | | <!-- 不可加scoped,会独立样式element访问不到 --> |
| | | <style> |
| | | <style lang="scss" scoped> |
| | | .addClassva { |
| | | /* background: #10aec2; */ |
| | | background: #e8f4ff !important; |
| | | /* color:whitesmoke; */ |
| | | } |
| | | .button-delete { |
| | | color: rgb(236, 69, 69); |
| | | } |
| | | ::v-deep.el-table .error-row { |
| | | background: #fcebeb; |
| | | } |
| | | </style> |