Browse Source

方案生产,考核指标样式

luzhiqiang_v1
luzhiqiang 2 years ago
parent
commit
836ce16db8
  1. 214
      .history/src/views/opk/asd/news/bb_20231023153725.vue
  2. 214
      .history/src/views/opk/asd/news/bb_20231023153727.vue
  3. 214
      .history/src/views/opk/asd/news/bb_20231023153729.vue
  4. 214
      .history/src/views/opk/asd/news/bb_20231023153737.vue
  5. 214
      .history/src/views/opk/asd/news/bb_20231023153745.vue
  6. 214
      .history/src/views/opk/asd/news/bb_20231023153753.vue
  7. 215
      .history/src/views/opk/asd/news/bb_20231023153803.vue
  8. 215
      .history/src/views/opk/asd/news/bb_20231023153809.vue
  9. 215
      .history/src/views/opk/asd/news/bb_20231023153812.vue
  10. 215
      .history/src/views/opk/asd/news/bb_20231023153816.vue
  11. 216
      .history/src/views/opk/asd/news/bb_20231023153825.vue
  12. 216
      .history/src/views/opk/asd/news/bb_20231023153833.vue
  13. 216
      .history/src/views/opk/asd/news/bb_20231023153835.vue
  14. 216
      .history/src/views/opk/asd/news/bb_20231023153842.vue
  15. 216
      .history/src/views/opk/asd/news/bb_20231023153844.vue
  16. 216
      .history/src/views/opk/asd/news/bb_20231023153846.vue
  17. 216
      .history/src/views/opk/asd/news/bb_20231023153847.vue
  18. 216
      .history/src/views/opk/asd/news/bb_20231023153850.vue
  19. 216
      .history/src/views/opk/asd/news/bb_20231023153943.vue
  20. 216
      .history/src/views/opk/asd/news/bb_20231023153947.vue
  21. 216
      .history/src/views/opk/asd/news/bb_20231023153950.vue
  22. 216
      .history/src/views/opk/asd/news/bb_20231023154006.vue
  23. 216
      .history/src/views/opk/asd/news/bb_20231023154013.vue
  24. 70
      .history/src/views/opk/asd/news/ycy_20231023082056.vue
  25. 149
      .history/src/views/opk/asd/news/yg_20231023081942.vue
  26. 147
      .history/src/views/opk/asd/news/yg_20231023081954.vue
  27. 148
      .history/src/views/opk/asd/news/yg_20231023082202.vue
  28. 148
      .history/src/views/opk/asd/news/yg_20231023082217.vue
  29. 148
      .history/src/views/opk/asd/news/yg_20231023082218.vue
  30. 150
      .history/src/views/opk/asd/news/yg_20231023082220.vue
  31. 237
      .history/src/views/opk/asd/news/yg_20231023082437.vue
  32. 237
      .history/src/views/opk/asd/news/yg_20231023082512.vue
  33. 238
      .history/src/views/opk/asd/news/yg_20231023082536.vue
  34. 235
      .history/src/views/opk/asd/news/yg_20231023082539.vue
  35. 233
      .history/src/views/opk/asd/news/yg_20231023082543.vue
  36. 233
      .history/src/views/opk/asd/news/yg_20231023082626.vue
  37. 233
      .history/src/views/opk/asd/news/yg_20231023082631.vue
  38. 233
      .history/src/views/opk/asd/news/yg_20231023082728.vue
  39. 233
      .history/src/views/opk/asd/news/yg_20231023082732.vue
  40. 233
      .history/src/views/opk/asd/news/yg_20231023082738.vue
  41. 233
      .history/src/views/opk/asd/news/yg_20231023082948.vue
  42. 233
      .history/src/views/opk/asd/news/yg_20231023083002.vue
  43. 233
      .history/src/views/opk/asd/news/yg_20231023083008.vue
  44. 233
      .history/src/views/opk/asd/news/yg_20231023083013.vue
  45. 232
      .history/src/views/opk/asd/news/yg_20231023083156.vue
  46. 233
      .history/src/views/opk/asd/news/yg_20231023083209.vue
  47. 232
      .history/src/views/opk/asd/news/yg_20231023083215.vue
  48. 232
      .history/src/views/opk/asd/news/yg_20231023083313.vue
  49. 232
      .history/src/views/opk/asd/news/yg_20231023083315.vue
  50. 232
      .history/src/views/opk/asd/news/yg_20231023083317.vue
  51. 232
      .history/src/views/opk/asd/news/yg_20231023083319.vue
  52. 232
      .history/src/views/opk/asd/news/yg_20231023083322.vue
  53. 232
      .history/src/views/opk/asd/news/yg_20231023083335.vue
  54. 196
      .history/src/views/opk/asd/news/yg_20231023083600.vue
  55. 196
      .history/src/views/opk/asd/news/yg_20231023083606.vue
  56. 196
      .history/src/views/opk/asd/news/yg_20231023083610.vue
  57. 196
      .history/src/views/opk/asd/news/yg_20231023083616.vue
  58. 195
      .history/src/views/opk/asd/news/yg_20231023083621.vue
  59. 195
      .history/src/views/opk/asd/news/yg_20231023083641.vue
  60. 195
      .history/src/views/opk/asd/news/yg_20231023083649.vue
  61. 195
      .history/src/views/opk/asd/news/yg_20231023083654.vue
  62. 148
      .history/src/views/opk/asd/news/yg_20231023083730.vue
  63. 165
      .history/src/views/opk/asd/news/yg_20231023083940.vue
  64. 165
      .history/src/views/opk/asd/news/yg_20231023083943.vue
  65. 165
      .history/src/views/opk/asd/news/yg_20231023083949.vue
  66. 165
      .history/src/views/opk/asd/news/yg_20231023083953.vue
  67. 165
      .history/src/views/opk/asd/news/yg_20231023084017.vue
  68. 165
      .history/src/views/opk/asd/news/yg_20231023084021.vue
  69. 165
      .history/src/views/opk/asd/news/yg_20231023084025.vue
  70. 165
      .history/src/views/opk/asd/news/yg_20231023084027.vue
  71. 165
      .history/src/views/opk/asd/news/yg_20231023084032.vue
  72. 175
      .history/src/views/opk/asd/news/yg_20231023084044.vue
  73. 175
      .history/src/views/opk/asd/news/yg_20231023084045.vue
  74. 175
      .history/src/views/opk/asd/news/yg_20231023084048.vue
  75. 175
      .history/src/views/opk/asd/news/yg_20231023084053.vue
  76. 174
      .history/src/views/opk/asd/news/yg_20231023084054.vue
  77. 174
      .history/src/views/opk/asd/news/yg_20231023084104.vue
  78. 175
      .history/src/views/opk/asd/news/yg_20231023084120.vue
  79. 174
      .history/src/views/opk/asd/news/yg_20231023084123.vue
  80. 175
      .history/src/views/opk/asd/news/yg_20231023084130.vue
  81. 175
      .history/src/views/opk/asd/news/yg_20231023084131.vue
  82. 175
      .history/src/views/opk/asd/news/yg_20231023084133.vue
  83. 175
      .history/src/views/opk/asd/news/yg_20231023084135.vue
  84. 175
      .history/src/views/opk/asd/news/yg_20231023084137.vue
  85. 175
      .history/src/views/opk/asd/news/yg_20231023084139.vue
  86. 175
      .history/src/views/opk/asd/news/yg_20231023084141.vue
  87. 175
      .history/src/views/opk/asd/news/yg_20231023084148.vue
  88. 175
      .history/src/views/opk/asd/news/yg_20231023084150.vue
  89. 175
      .history/src/views/opk/asd/news/yg_20231023084153.vue
  90. 175
      .history/src/views/opk/asd/news/yg_20231023084155.vue
  91. 175
      .history/src/views/opk/asd/news/yg_20231023084159.vue
  92. 175
      .history/src/views/opk/asd/news/yg_20231023084210.vue
  93. 175
      .history/src/views/opk/asd/news/yg_20231023084215.vue
  94. 196
      .history/src/views/opk/asd/news/yg_20231023084224.vue
  95. 233
      .history/src/views/opk/asd/news/yg_20231023084227.vue
  96. 233
      .history/src/views/opk/asd/news/yg_20231023084233.vue
  97. 233
      .history/src/views/opk/asd/news/yg_20231023084235.vue
  98. 233
      .history/src/views/opk/asd/news/yg_20231023084254.vue
  99. 233
      .history/src/views/opk/asd/news/yg_20231023084301.vue
  100. 233
      .history/src/views/opk/asd/news/yg_20231023084306.vue

214
.history/src/views/opk/asd/news/bb_20231023153725.vue

@ -0,0 +1,214 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="deaprtname" label="部门">
</el-table
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

214
.history/src/views/opk/asd/news/bb_20231023153727.vue

@ -0,0 +1,214 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="deaprtname" label="部门">
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

214
.history/src/views/opk/asd/news/bb_20231023153729.vue

@ -0,0 +1,214 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="deaprtname" label="部门">
{{}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

214
.history/src/views/opk/asd/news/bb_20231023153737.vue

@ -0,0 +1,214 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="deaprtname," label="部门">
{{}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

214
.history/src/views/opk/asd/news/bb_20231023153745.vue

@ -0,0 +1,214 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
{{}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

214
.history/src/views/opk/asd/news/bb_20231023153753.vue

@ -0,0 +1,214 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
{{groupname}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

215
.history/src/views/opk/asd/news/bb_20231023153803.vue

@ -0,0 +1,215 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
{{groupname}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

215
.history/src/views/opk/asd/news/bb_20231023153809.vue

@ -0,0 +1,215 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default =
{{groupname}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

215
.history/src/views/opk/asd/news/bb_20231023153812.vue

@ -0,0 +1,215 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default=scope>
{{groupname}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

215
.history/src/views/opk/asd/news/bb_20231023153816.vue

@ -0,0 +1,215 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{groupname}}
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153825.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{groupname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153833.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.groupname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153835.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153842.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153844.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153846.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row,}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153847.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153850.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.deaprtname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153943.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.deaprtname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年" la/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153947.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.deaprtname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年" label-width=""/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023153950.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.deaprtname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年" label-width="30"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023154006.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.deaprtname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年" width="30"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

216
.history/src/views/opk/asd/news/bb_20231023154013.vue

@ -0,0 +1,216 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-09-19 09:13:14
@ 备注:
-->
<script lang='ts' setup>
import {ref,reactive,onMounted} from 'vue'
import { organdpost,posttarget,set_posttarget } from '@/api/opk/api'
import { addPostCont,tarlist,deltarget } from '@/api/opk/api'
import { editPostCont } from '@/api/opk/pulic/api'
import { departmentprogramme,edit_depart,edit_depart_progra } from '@/api/opk/news/api'
import { ge_copy } from '@/api/opk/zxy/news/api'
import { formItemValidateStates, TableV2SortOrder } from 'element-plus';
import { getDictFormData } from '@/api/dict'
import Dialog from './dialog.vue'
import Dialoglog from './dialoglog.vue'
import Yg from './yg.vue'
// eslint-disable-next-line vue/require-prop-types
const { addShow, title } = defineProps(['addShow', 'title'])
const data = reactive({
formInline:{
region:'',
},
title:"",
addPostBox: false,
edPostBox:false,
ygPostBox:false,
})
const orgTreeProps ={
label: 'name',
children:'child'
}
const orgTreeProp ={
label: 'title',
children:'childen'
}
const formdat = {
someProp:"",
}
const total =ref(0)
const rowInfo = ref<any>({})
const postIds = ref<number[]>([])
const tableData = ref<any>([]);
const tables = ref<any>([]);
//
function jjjs(){
addPostCont("/hrapi/org/govthree","post")
.then(data => {
tableData.value = data.data[3].child[14].child;
})
.catch(error => {
console.error('Error fetching data:', error);
});
}
jjjs()
function editPost(){
editPostCont({})
.then(data => {
tables.value = data.data.list;
})
}
editPost()
const table = ref<any>([])
const formdate = reactive({
page:0,
pagesize:20,
name:"",
dimension:"",
attribute:"",
orgidlist:"",
type:"",
value1:"2023",
})
//
const tableq = ref([])
const postt = ()=>{
const ass = new Date(formdate.value1);
const qwe = ass.getFullYear();
const zjr = qwe.toString();
departmentprogramme({orgid:formdate.orgidlist,year:zjr,version:formdate.name})
.then(data => {
tableq.value = data.data;
total.value = data.data.count;
})
}
//
const addtableData = ()=>{
data.addPostBox = true;
}
//
const addRow = (val:any)=> {
tableData.value.push(val);
}
//
const editRow = (val:any)=> {
let index =tableData.value.findIndex(
(item:any) => item.id === val.id
);
tableData.value.splice(index, 1, val);
}
//
const closeDetail = ()=>{
data.addPostBox = false;
}
function editPostState(classId:string,state:number){
console.log("改变状态--------->",classId,state)
let statusVal = 1
if( state == 1) statusVal = 2;
edit_depart({id:classId,state:statusVal,istrue:2})
postt()
}
//
const handleDel = (val:any) => {
const dictTypeIds = [val.outID || postIds.value].join(",");
let dictTypeIdAry = dictTypeIds.split(",")
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const add = val.key.toString()
handleSure(val)
console.log(val.id)
edit_depart({id:add,state:3,istrue:2}).then(()=>
ElMessage.success("删除成功"))
})
postt()
};
const handleSure = (val:any)=> {
const index = tableData.value.findIndex((item:any) => item.id === val.id);
if(index!=-1){
tableData.value.splice(index, 1);
}
}
const resetChecked=()=> {
formdate.orgidlist = ""
postt()
}
const handle=(data:any)=>{
formdate.orgidlist = data.id.toString()
postt()
}
const handleErd=(val:any)=>{
data.edPostBox=true;
rowInfo.value=val;
}
const handleio=(val:any)=>{
data.ygPostBox=true;
rowInfo.value = val;
}
onMounted(()=>{
jjjs()
postt()
})
</script>
<template>
<div class="m-4">
<el-container style="width: 100%">
<div>
<el-button type="primary" style="width: 100%" @click="resetChecked">全选</el-button>
<el-tree ref="orgTreeRef" v-model="formdate.orgidlist" node-key="id" class="orgTree" :data="tableData" :props="orgTreeProps" :default-expand-all="false" @node-click="handle"/>
</div>
<el-col :span="22">
<el-container class="m-4">
<el-form-item label="方案版本号:">
<el-input v-model="formdate.name" placeholder="请输入方案版本号" clearable style="width:200px"/>
</el-form-item>
<el-form-item label="年度:" label-width="90">
<el-date-picker v-model="formdate.value1" type="year"/>
</el-form-item>
<el-form-item label-width="40">
<el-button type="primary" @click="postt"><el-icon><Search /></el-icon></el-button>
<el-button class="new_btn" type="warning" @click="addtableData"><el-icon><Plus /></el-icon></el-button>
</el-form-item>
</el-container>
<el-table class="m-4" :data="tableq" border style="width: 100%">
<el-table-column prop="groupname,deaprtname," label="部门">
<template #default="scope">
{{scope.row.groupname}}{{scope.row.deaprtname}}
</template>
</el-table-column>
<el-table-column prop="year" label="年" width="70"/>
<el-table-column prop="key" label="版本号"/>
<el-table-column prop="time" label="时间" />
<el-table-column prop="states" label="状态" width="70">
<template #default="scope">
<el-switch v-model="scope.row.status" class="ml-2" inline-prompt style="--el-switch-on-color: #ff4949; --el-switch-off-color: #13ce66" @change="editPostState(scope.row.key,scope.row.state)"/>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="228">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
<el-button type="primary" link @click="handleErd(row)"><el-icon><DocumentChecked /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
</el-col>
</el-container>
<pagination v-if="total > 0" v-model:page="formdate.page" v-model:pagesize="formdate.pagesize" :total="total" @click="postt"/>
<Dialog v-if="data.addPostBox" v-model="data.addPostBox" :title="title" :array-num="tableData.length" @add-row="addRow" @edit-row="editRow"></Dialog>
<Dialoglog v-if="data.edPostBox" v-model="data.edPostBox" :title="title" :row-info="rowInfo"></Dialoglog>
<Yg v-if="data.ygPostBox" v-model="data.ygPostBox" :title="title" :row-info="rowInfo"></Yg>
</div>
</template>
<style lang='scss' scoped>
.horizontal-controls {
display: flex;
float: left;
}
/* 可以根据需要调整样式 */
</style>

70
.history/src/views/opk/asd/news/ycy_20231023082056.vue

@ -0,0 +1,70 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="考核细则" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" style="width:100%">
<el-table-column prop="tablename" label="考核项目" />
<el-table-column prop="targetname" label="考核内容"/>
<el-table-column prop="criterion" label="考核标准"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="content" label="备注说明"/>
</el-table>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue"
import { get_runman,look_scheme } from '@/api/opk/zxy/news/api'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ycyPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const emit = defineEmits(["update:ycyPostBox","editRow","addRow"])
const formData = reactive({})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.targetid
look_scheme({id:yui,level:1,orgid:props.rowInfo.orgid,posid:"",type:3})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ycyPostBox", false);
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

149
.history/src/views/opk/asd/news/yg_20231023081942.vue

@ -0,0 +1,149 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

147
.history/src/views/opk/asd/news/yg_20231023081954.vue

@ -0,0 +1,147 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

148
.history/src/views/opk/asd/news/yg_20231023082202.vue

@ -0,0 +1,148 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

148
.history/src/views/opk/asd/news/yg_20231023082217.vue

@ -0,0 +1,148 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function objectSpanMethod
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

148
.history/src/views/opk/asd/news/yg_20231023082218.vue

@ -0,0 +1,148 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function objectSpanMethod()
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

150
.history/src/views/opk/asd/news/yg_20231023082220.vue

@ -0,0 +1,150 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function objectSpanMethod(){
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

237
.history/src/views/opk/asd/news/yg_20231023082437.vue

@ -0,0 +1,237 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: PriceTableItem;
column: TableColumnCtx<PriceTableItem>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(() => {
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
});
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

237
.history/src/views/opk/asd/news/yg_20231023082512.vue

@ -0,0 +1,237 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: PriceTableItem;
column: TableColumnCtx<PriceTableItem>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 0
};
}
};
onMounted(() => {
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
});
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

238
.history/src/views/opk/asd/news/yg_20231023082536.vue

@ -0,0 +1,238 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: PriceTableItem;
column: TableColumnCtx<PriceTableItem>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 0
};
}
};
onMounted(() => {
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
});
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

235
.history/src/views/opk/asd/news/yg_20231023082539.vue

@ -0,0 +1,235 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: PriceTableItem;
column: TableColumnCtx<PriceTableItem>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 0
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082543.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: PriceTableItem;
column: TableColumnCtx<PriceTableItem>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 0
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082626.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<PriceTableItem>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 0
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082631.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 0
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082728.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082732.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 2
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082738.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023082948.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 0) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023083002.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023083008.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1,2) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023083013.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083156.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023083209.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083215.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083313.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083315.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度 "/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083317.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度" />
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083319.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度" :span-method="objectSpanMethod"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083322.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度" :span-method="objectSpanMethod"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

232
.history/src/views/opk/asd/news/yg_20231023083335.vue

@ -0,0 +1,232 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

196
.history/src/views/opk/asd/news/yg_20231023083600.vue

@ -0,0 +1,196 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
, courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tableData2.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
, objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

196
.history/src/views/opk/asd/news/yg_20231023083606.vue

@ -0,0 +1,196 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
, courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tableData2.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

196
.history/src/views/opk/asd/news/yg_20231023083610.vue

@ -0,0 +1,196 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
, courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tableData2.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

196
.history/src/views/opk/asd/news/yg_20231023083616.vue

@ -0,0 +1,196 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
function courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tableData2.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

195
.history/src/views/opk/asd/news/yg_20231023083621.vue

@ -0,0 +1,195 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
function courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tableData2.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

195
.history/src/views/opk/asd/news/yg_20231023083641.vue

@ -0,0 +1,195 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
function courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tablea.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

195
.history/src/views/opk/asd/news/yg_20231023083649.vue

@ -0,0 +1,195 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
function courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tablea.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tablea[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

195
.history/src/views/opk/asd/news/yg_20231023083654.vue

@ -0,0 +1,195 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
function courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tablea.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tablea[i].course === _this.tablea[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

148
.history/src/views/opk/asd/news/yg_20231023083730.vue

@ -0,0 +1,148 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023083940.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
getSpanArr(data) { 
for (var i = 0; i < data.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (data[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
},
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023083943.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
getSpanArr(data) {
for (var i = 0; i < data.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (data[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
},
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023083949.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(data) {
for (var i = 0; i < data.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (data[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
},
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023083953.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(data) {
for (var i = 0; i < data.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (data[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023084017.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < data.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (data[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023084021.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (data[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023084025.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tal[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023084027.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === data[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

165
.history/src/views/opk/asd/news/yg_20231023084032.vue

@ -0,0 +1,165 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084044.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
cellMerge({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
},
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084045.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
cellMerge({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
},
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084048.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function cellMerge({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
},
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084053.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function cellMerge({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

174
.history/src/views/opk/asd/news/yg_20231023084054.vue

@ -0,0 +1,174 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function cellMerge({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

174
.history/src/views/opk/asd/news/yg_20231023084104.vue

@ -0,0 +1,174 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084120.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

174
.history/src/views/opk/asd/news/yg_20231023084123.vue

@ -0,0 +1,174 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084130.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084131.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084133.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084135.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084137.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084139.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084141.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084148.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084150.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084153.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084155.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084159.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084210.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 1) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

175
.history/src/views/opk/asd/news/yg_20231023084215.vue

@ -0,0 +1,175 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
function getSpanArr(tablea) {
for (var i = 0; i < tablea.length; i++) {
if (i === 0) {
this.spanArr.push(1);
this.pos = 0
} else {
//
if (tablea[i].name === tablea[i - 1].name) {
this.spanArr[this.pos] += 1;
this.spanArr.push(0);
} else {
this.spanArr.push(1);
this.pos = i;
}
}
}
}
function objectSpanMethod({ row, column, rowIndex, columnIndex }) {
getSpanArr()
if (columnIndex === 0) {
const _row = this.spanArr[rowIndex];
const _col = _row > 0 ? 1 : 0;
return {
rowspan: _row,
colspan: _col
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
})
</script>

196
.history/src/views/opk/asd/news/yg_20231023084224.vue

@ -0,0 +1,196 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
//
, courseinit() {
//
var _this = this;
this.courseArr = []
this.coursePos = 0
for (var i = 0; i < _this.tableData2.length; i++) {
//
if (i === 0) {
//
_this.courseArr.push(1)
_this.coursePos = 0
} else {
//courseprop
if (_this.tableData2[i].course === _this.tableData2[i - 1].course) {
// +1
_this.courseArr[_this.coursePos] += 1
_this.courseArr.push(0)
} else {
// index
_this.courseArr.push(1)
_this.coursePos = i
}
}
}
}
//
function objectSpanMethod({rowIndex, columnIndex}) {
//
if (columnIndex === 0) {
//courseArr
const row1 = this.courseArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
} else if (columnIndex === 1) {
//nameArr
const row1 = this.nameArr[rowIndex]
const col1 = row1 > 0 ? 1 : 0
return {
rowspan: row1,
colspan: col1
}
}
}
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023084227.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 1) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023084233.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === ) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023084235.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 0) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023084254.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 0) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023084301.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 0) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionstandard');//
})
</script>

233
.history/src/views/opk/asd/news/yg_20231023084306.vue

@ -0,0 +1,233 @@
<!--
@ 作者: 鲁智强
@ 时间: 2023-08-15 11:34:38
@ 备注:
-->
<template>
<el-dialog :model-value="true" title="查看方案详情" @close="handleClose">
<el-table :data="tablea" border label-width="120px" class="demo-ruleForm" :span-method="objectSpanMethod" style="width:100%">
<el-table-column prop="dimensionname" label="考核维度"/>
<el-table-column prop="dimensionstandard" label="维度权重"/>
<el-table-column label="考核指标">
<template #default="scope">
<a v-if="scope.row.attribute == 1" style="color:#409eff" @click="cancelDialog(scope.row)">{{scope.row.targetname}}</a >
<a v-if="scope.row.attribute == 2">{{scope.row.targetname}}</a>
</template>
</el-table-column>
<el-table-column prop="Targetstandard" label="权重指标"/>
<el-table-column prop="content" label="说明"/>
<el-table-column prop="unit" label="单位"/>
<el-table-column prop="state" label="指标状态">
<template #default="scope">
<span v-if="scope.row.state== 1" class="el-tag"></span>
<span v-if="scope.row.state== 2" class="el-tag el-tag--warning">季度</span>
<span v-if="scope.row.state== 3" class="el-tag el-tag--warning el-tag--light"></span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="周期">
<template #default="scope">
<span v-if="scope.row.cycle== 4" class="el-tag">使用</span>
<span v-if="scope.row.cycle== 5" class="el-tag">禁用</span>
<span v-if="scope.row.cycle== 6" class="el-tag">观察</span>
</template>
</el-table-column>
<el-table-column prop="cycle" label="频次"/>
<el-table-column fixed="right" label="执行人" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleio(row)"><el-icon><View /></el-icon></el-button>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="200">
<template #default="{ row }">
<el-button type="primary" link @click="handleErd(row)"><el-icon><EditPen /></el-icon></el-button>
<el-button type="primary" link @click="handleDel(row)"><el-icon><Delete /></el-icon></el-button>
</template>
</el-table-column>
</el-table>
<Xd v-if="data.xdPostBox" v-model="data.xdPostBox" :row-info="rowInfo"></Xd>
<Hyr v-if="data.hyrPostBox" v-model="data.hyrPostBox" :row-info="rowInfo"></Hyr>
<Ycy v-if="data.ycyPostBox" v-model="data.ycyPostBox" :row-info="rowInfo"></Ycy>
</el-dialog>
</template>
<script lang="ts" setup>
import { reactive } from "vue";
import {tarlist,addPostCont,addtarget,getgroupuser,addposttargetcont,search_orgpost,organdpost} from '@/api/opk/api'
import {editPostCont} from '@/api/opk/pulic/api'
import { ge_add } from '@/api/opk/news/api'
import {look_scheme} from '@/api/opk/opk/api'
import { create_scheme,ge_copy,del_scheme } from '@/api/opk/zxy/news/api'
import Xd from './xd.vue'
import Hyr from './hyr.vue'
import Ycy from './ycy.vue'
const isshow = ref(false)
const props= defineProps( {
title: {
type: String,
default: "",
},
ygPostBox: {
type: Boolean,
default: false,
},
rowInfo: {
type: Object,
default() {
return {};
},
},
arrayNum: {
type: Number,
default: 0,
},
});
const orgTreeProps ={
label: 'name',
}
const orgTreeProp = {
label:'title',
children:'children'
}
const data = reactive({
xdPostBox:false,
hyrPostBox:false,
ycyPostBox:false,
})
// eslint-disable-next-line vue/no-dupe-keys
const rowInfo = ref<any>({})
const emit = defineEmits(["update:ygPostBox","editRow","addRow"])
const formData = reactive({
deaprtname:"",
year:"",
asd:[] as string[],
})
const tablea = ref<any>([])
function ge_adds(){
const yui = props.rowInfo.key
look_scheme({id:yui})
.then((data) => {
tablea.value = data.data;
}).finally(()=>{
isshow.value = false
})
}
ge_adds()
//
const handleClose = ()=> {
emit("update:ygPostBox", false);
}
const handleio = (val:any)=>{
data.xdPostBox = true,
rowInfo.value = val
}
const handleErd = (val:any)=>{
data.hyrPostBox = true,
rowInfo.value = val
}
const handleDel = (val:any) => {
ElMessageBox.confirm("你确定删除这条信息吗?", "提示", {
confirmButtonText: "确认",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
const delid = new String(val.id)
del_scheme({orgid:val.orgid,planversionkey:val.plantversion,targetid:val.targetid})
ge_adds()
})
}
const cancelDialog = (val:any)=>{
data.ycyPostBox=true,
rowInfo.value =val
}
//
interface ObjInterface {
[key: string]: any; //
}
function tableRowMerge(
data: ObjInterface[],
rowName: string,
otherRowName?: string
) {
const idArray = [] as number[];
let idPos = 0;
for (let i = 0; i < data.length; i++) {
// i == 0 ,
if (i == 0) {
// idArray.push(1)
idArray.push(1);
// idPos = 0
idPos = 0;
}
//
else {
if (otherRowName) {
//
if (
data[i][rowName] == data[i - 1][rowName] &&
data[i][otherRowName] == data[i - 1][otherRowName]
) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
} else {
//
if (data[i][rowName] == data[i - 1][rowName]) {
// idArray
idArray[idPos] += 1;
// idArray push0
idArray.push(0);
}
//
else {
// idArray.push(1)
idArray.push(1);
//
idPos = i;
}
}
}
}
return idArray;
}
let rowMergeArr = [] as number[];
/**
* @description 合并行
*/
interface SpanMethodProps {
row: User;
column: TableColumnCtx<User>;
rowIndex: number;
columnIndex: number;
}
const objectSpanMethod = ({
row,
column,
rowIndex,
columnIndex
}: SpanMethodProps) => {
// level
if (columnIndex === 0) {
// rowMergeArr[rowIndex]
const rowSpan = rowMergeArr[rowIndex];
//
return {
rowspan: rowSpan,
colspan: 1
};
}
};
onMounted(()=>{
Object.assign(formData,props.rowInfo);
rowMergeArr = tableRowMerge(tablea, 'dimensionname');//
})
</script>

Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save