|
|
|
@ -6,7 +6,7 @@ |
|
|
|
" |
|
|
|
@contextmenu.prevent="onContextmenu" |
|
|
|
> |
|
|
|
<div id="info"> |
|
|
|
<div> |
|
|
|
<el-table @body-scrolling="load" |
|
|
|
:data="patientRegister.prList" |
|
|
|
border :height="window.pageHeight < 600 ? 226 : Math.floor(((window.pageHeight - 261) * 2) / 3)" |
|
|
|
@ -15,7 +15,7 @@ |
|
|
|
size="small" row-key="id" |
|
|
|
@selection-change="handleSelectionChange" |
|
|
|
@cell-contextmenu="onCellRightClick" |
|
|
|
ref="info" |
|
|
|
ref="info" id="info" |
|
|
|
:row-class-name="handleRowClassName" |
|
|
|
> |
|
|
|
<!-- 取消勾选,改为选中 |
|
|
|
@ -130,20 +130,20 @@ |
|
|
|
</div> |
|
|
|
<div style="margin-left: 10px;"> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'人员登记')" class="listBtn"> |
|
|
|
<el-button type="success" class="btnClass" @click="btnAdd">人员登记</el-button |
|
|
|
<el-button type="success" class="commonbutton" @click="btnAdd">人员登记</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'批量正式登记')" class="listBtn"> |
|
|
|
<el-button type="success" class="btnClass" @click="btnAddBatch">批量正式登记</el-button |
|
|
|
<el-button type="success" class="commonbutton" @click="btnAddBatch">批量正式登记</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'编辑')" class="listBtn"> |
|
|
|
<el-button type="primary" class="btnClass" @click="btnEdit" |
|
|
|
<el-button type="primary" class="commonbutton" @click="btnEdit" |
|
|
|
>编辑</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'删除')" class="listBtn"> |
|
|
|
<el-button type="danger" class="btnClass" @click="btnDel" |
|
|
|
<el-button type="danger" class="commonbutton" @click="btnDel" |
|
|
|
>删除</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
@ -162,19 +162,19 @@ |
|
|
|
</div> |
|
|
|
--> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'批量调整分组')" class="listBtn"> |
|
|
|
<el-button type="" class="btnClass" @click="btnGroupBatch" |
|
|
|
<el-button type="" class="commonbutton" @click="btnGroupBatch" |
|
|
|
>批量调整分组</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'批量调整项目')" class="listBtn"> |
|
|
|
<el-button type="" class="btnClass" @click="btnAsbBatch" |
|
|
|
<el-button type="" class="commonbutton" @click="btnAsbBatch" |
|
|
|
>批量调整项目</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'指引单打印')" class="listBtn"> |
|
|
|
<el-button |
|
|
|
type="" |
|
|
|
class="btnClass" |
|
|
|
class="commonbutton" |
|
|
|
@click="guidePrint('0001', false)" |
|
|
|
>指引单打印</el-button |
|
|
|
> |
|
|
|
@ -182,7 +182,7 @@ |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'指引单预览')" class="listBtn"> |
|
|
|
<el-button |
|
|
|
type="" |
|
|
|
class="btnClass" |
|
|
|
class="commonbutton" |
|
|
|
@click="guidePrint('0001', true)" |
|
|
|
>指引单预览</el-button |
|
|
|
> |
|
|
|
@ -190,7 +190,7 @@ |
|
|
|
<div v-show="checkPagePriv(pagePriv.privs,'人员信息导出')" class="listBtn"> |
|
|
|
<el-button |
|
|
|
type="" |
|
|
|
class="btnClass" |
|
|
|
class="commonbutton" |
|
|
|
@click="btnExport('info')" |
|
|
|
>人员信息导出</el-button |
|
|
|
> |
|
|
|
@ -1305,28 +1305,29 @@ export default { |
|
|
|
// 获取HTML元素(表格) |
|
|
|
// let table = document.getElementById(elId); //.cloneNode(true) |
|
|
|
this.$nextTick(() => { |
|
|
|
let refsTable = this.$refs[elId] //.cloneNode(true) true |
|
|
|
let table = document.getElementById(elId) |
|
|
|
console.log('table',table) |
|
|
|
// let table = this.$refs[elId] //.cloneNode(true) true |
|
|
|
console.log('table,refsTable',table,refsTable) |
|
|
|
|
|
|
|
let tableData = table.innerHTML |
|
|
|
let fileName = moment(new Date()).format('yyyyMMDDHHmmss') |
|
|
|
let blob = new Blob([tableData],{type:"text/plain;charset=utf-8"}); |
|
|
|
|
|
|
|
FileSaver.saveAs(blob, fileName + '.xls'); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 导出图片 |
|
|
|
// 使用html2canvas将HTML元素转换为画布 |
|
|
|
// let cloneTable = table.cloneNode(true) //[elId] |
|
|
|
|
|
|
|
html2canvas(table).then(canvas => { |
|
|
|
|
|
|
|
// 创建一个a元素用于下载 |
|
|
|
const link = document.createElement('a'); |
|
|
|
link.href = canvas.toDataURL('image/png'); |
|
|
|
link.download = fileName + '.png'; |
|
|
|
link.href = canvas.toDataURL('image/jpeg'); |
|
|
|
link.download = fileName + '.jpg'; |
|
|
|
document.body.appendChild(link); |
|
|
|
link.click(); |
|
|
|
document.body.removeChild(link); |
|
|
|
//document.body.removeChild(link); |
|
|
|
|
|
|
|
// // 创建一个PDF对象 |
|
|
|
// var pdf = new jsPDF(); |
|
|
|
@ -1365,12 +1366,12 @@ export default { |
|
|
|
}, |
|
|
|
|
|
|
|
//新增后,触发赋值 |
|
|
|
"patientRegister.patientRegisterRd.id"(newVal, oldVal) { |
|
|
|
if (newVal != oldVal) { |
|
|
|
//console.log('patientRegister.patientRegisterRd.customerOrgId',this.patientRegister.patientRegisterRd.customerOrgId) |
|
|
|
objCopy(this.patientRegister.patientRegisterRd, this.form); |
|
|
|
} |
|
|
|
}, |
|
|
|
// "patientRegister.patientRegisterRd.id"(newVal, oldVal) { |
|
|
|
// if (newVal != oldVal) { |
|
|
|
// //console.log('patientRegister.patientRegisterRd.customerOrgId',this.patientRegister.patientRegisterRd.customerOrgId) |
|
|
|
// objCopy(this.patientRegister.patientRegisterRd, this.form); |
|
|
|
// } |
|
|
|
// }, |
|
|
|
}, |
|
|
|
}; |
|
|
|
</script> |
|
|
|
|