|
|
|
@ -272,7 +272,7 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<Button type="primary" @click="cloneTransfer">克隆调令</Button>
|
|
|
|
<Button type="primary" @click="cloneTransfer">克隆调令</Button>
|
|
|
|
<template #distribute>
|
|
|
|
<template #distribute>
|
|
|
|
<Button type="primary" @click="pickNoDistribute">勾选未下发</Button>
|
|
|
|
<Button type="primary" @click="pickNoDistribute">勾选当日未下发</Button>
|
|
|
|
<Button type="primary" @click="distributeTransfers">批量下发</Button>
|
|
|
|
<Button type="primary" @click="distributeTransfers">批量下发</Button>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</header-content>
|
|
|
|
</header-content>
|
|
|
|
@ -283,6 +283,9 @@
|
|
|
|
<!--$refs['drawer'].setId(row.id);
|
|
|
|
<!--$refs['drawer'].setId(row.id);
|
|
|
|
$refs['drawer'].show();-->
|
|
|
|
$refs['drawer'].show();-->
|
|
|
|
<xy-table
|
|
|
|
<xy-table
|
|
|
|
|
|
|
|
:btnCondition="btnCondition"
|
|
|
|
|
|
|
|
:span-method="objectSpanMethod"
|
|
|
|
|
|
|
|
:format-list-data="mergeData"
|
|
|
|
:is-page="false"
|
|
|
|
:is-page="false"
|
|
|
|
:btn-width="300"
|
|
|
|
:btn-width="300"
|
|
|
|
:auths="auths_auth_mixin"
|
|
|
|
:auths="auths_auth_mixin"
|
|
|
|
@ -323,7 +326,6 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<template #oa="{ row }">
|
|
|
|
<template #oa="{ row }">
|
|
|
|
<Button
|
|
|
|
<Button
|
|
|
|
v-if="row.shifouzouliucheng && (row.liuchengzhuangtai == 1 || !row.liuchengzhuangtai)"
|
|
|
|
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
type="primary"
|
|
|
|
type="primary"
|
|
|
|
@click="toOa(row)"
|
|
|
|
@click="toOa(row)"
|
|
|
|
@ -332,18 +334,20 @@
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<template #distribute="{ row }">
|
|
|
|
<template #distribute="{ row }">
|
|
|
|
<Button
|
|
|
|
<Button
|
|
|
|
v-if="row.status === 1"
|
|
|
|
v-if="row.status === 1 || row.status === 7"
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
type="primary"
|
|
|
|
type="primary"
|
|
|
|
@click="setTransferStatus(2,row)"
|
|
|
|
@click="setTransferStatus(2,row)"
|
|
|
|
>下发</Button
|
|
|
|
>下发</Button
|
|
|
|
>
|
|
|
|
>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<template #cancel="{ row }">
|
|
|
|
<Button
|
|
|
|
<Button
|
|
|
|
v-if="row.status === 2"
|
|
|
|
v-if="row.status === 2"
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
type="primary"
|
|
|
|
type="primary"
|
|
|
|
ghost
|
|
|
|
ghost
|
|
|
|
@click="setTransferStatus(1,row)"
|
|
|
|
@click="setTransferStatus(7,row)"
|
|
|
|
>取消</Button
|
|
|
|
>取消</Button
|
|
|
|
>
|
|
|
|
>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
@ -393,6 +397,7 @@ import drawer from "@/views/component/drawer.vue";
|
|
|
|
import imports from "@/views/component/imports.vue";
|
|
|
|
import imports from "@/views/component/imports.vue";
|
|
|
|
import callback from "@/views/order/component/callback.vue";
|
|
|
|
import callback from "@/views/order/component/callback.vue";
|
|
|
|
import {deepCopy} from "@/utils";
|
|
|
|
import {deepCopy} from "@/utils";
|
|
|
|
|
|
|
|
import {mergeTableRow} from "@/utils/mergeTableRow";
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
components: {
|
|
|
|
components: {
|
|
|
|
LxHeader,
|
|
|
|
LxHeader,
|
|
|
|
@ -455,6 +460,46 @@ export default {
|
|
|
|
};
|
|
|
|
};
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
|
|
|
|
btnCondition ({ row }, item, index) {
|
|
|
|
|
|
|
|
if (row.status === 7) {
|
|
|
|
|
|
|
|
if (item === 'oa') {
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if ([2,3,4,5,6].find(i => i === row.status)) {
|
|
|
|
|
|
|
|
if (item === 'delete' || item === 'oa') {
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if ([3,4,5,6].find(i => i === row.status)) {
|
|
|
|
|
|
|
|
if (item === 'edit') {
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (row.liuchengzhuangtai === 2 || row.liuchengzhuangtai === 3) {
|
|
|
|
|
|
|
|
if (item === 'delete' || item === 'edit') {
|
|
|
|
|
|
|
|
return false
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return true
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
objectSpanMethod({ row, column, rowIndex, columnIndex }) {
|
|
|
|
|
|
|
|
const span = column["property"] + "-span";
|
|
|
|
|
|
|
|
if (row[span]) {
|
|
|
|
|
|
|
|
return row[span];
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mergeData(list) {
|
|
|
|
|
|
|
|
return mergeTableRow({
|
|
|
|
|
|
|
|
data: list,
|
|
|
|
|
|
|
|
mergeColNames: ["equipment_id_equipments_id_relation.area","equipment_id_equipments_id_relation.name"], // 需要合并的列,默认合并列相同的数据
|
|
|
|
|
|
|
|
firstMergeColNames: ["equipment_id_equipments_id_relation.area","equipment_id_equipments_id_relation.name"], // 受影响的列,只合并以firstMerge为首的同类型数据
|
|
|
|
|
|
|
|
firstMerge: "equipment_id", // 以哪列为基础进行合并,一般为第一列
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
pickNoDistribute () {
|
|
|
|
pickNoDistribute () {
|
|
|
|
this.$refs['xyTable'].getListData()?.forEach(item => {
|
|
|
|
this.$refs['xyTable'].getListData()?.forEach(item => {
|
|
|
|
console.log(item)
|
|
|
|
console.log(item)
|
|
|
|
@ -506,7 +551,7 @@ export default {
|
|
|
|
'65aa1a442705f': row.content
|
|
|
|
'65aa1a442705f': row.content
|
|
|
|
}
|
|
|
|
}
|
|
|
|
let url =
|
|
|
|
let url =
|
|
|
|
`${process.env.VUE_APP_OA_URL}/admin/flow/create/34?diaoling_oatoken=${this.oaToken}&default_json=${JSON.stringify(jsonInfo)}`
|
|
|
|
`${process.env.VUE_APP_OA_URL}/admin/flow/create/34?diaoling_oatoken=${this.oaToken}&out_diaoling_id=${row.id}&default_json=${JSON.stringify(jsonInfo)}`
|
|
|
|
window.open(url, 'diaoling',
|
|
|
|
window.open(url, 'diaoling',
|
|
|
|
`top=${this.window.top},left=${this.window.left},width=${this.window.width},height=${this.window.height},location=0`
|
|
|
|
`top=${this.window.top},left=${this.window.left},width=${this.window.width},height=${this.window.height},location=0`
|
|
|
|
)
|
|
|
|
)
|
|
|
|
@ -801,6 +846,14 @@ export default {
|
|
|
|
)
|
|
|
|
)
|
|
|
|
);
|
|
|
|
);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
this.table.unshift({
|
|
|
|
|
|
|
|
width: 100,
|
|
|
|
|
|
|
|
label: "范围",
|
|
|
|
|
|
|
|
prop: "equipment_id_equipments_id_relation.area",
|
|
|
|
|
|
|
|
formatter:(data,row,val) => {
|
|
|
|
|
|
|
|
return this.areas.find(i => i.value === val)?.key
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
});
|
|
|
|
this.table.unshift({
|
|
|
|
this.table.unshift({
|
|
|
|
type: "index",
|
|
|
|
type: "index",
|
|
|
|
width: 60,
|
|
|
|
width: 60,
|
|
|
|
|