|
@@ -5,6 +5,7 @@
|
|
|
:pagination="sourceList.pagination"
|
|
|
:config="config"
|
|
|
:loading="loading"
|
|
|
+ :searchConfig="searchConfig"
|
|
|
highlight-current-row
|
|
|
:action-list="[
|
|
|
{
|
|
@@ -20,7 +21,7 @@
|
|
|
|
|
|
<script setup>
|
|
|
import byTable from "/src/components/byTable/index";
|
|
|
-import { ElMessage, ElMessageBox } from "element-plus";
|
|
|
+import { flowStatus } from "/src/utils/flowStatus";
|
|
|
|
|
|
const { proxy } = getCurrentInstance();
|
|
|
const sourceList = ref({
|
|
@@ -32,6 +33,16 @@ const sourceList = ref({
|
|
|
},
|
|
|
});
|
|
|
const loading = ref(false);
|
|
|
+const searchConfig = computed(() => {
|
|
|
+ return [
|
|
|
+ {
|
|
|
+ type: "select",
|
|
|
+ prop: "flowStatus",
|
|
|
+ label: "流程状态",
|
|
|
+ data: flowStatus(),
|
|
|
+ },
|
|
|
+ ];
|
|
|
+});
|
|
|
const config = computed(() => {
|
|
|
return [
|
|
|
{
|
|
@@ -71,6 +82,16 @@ const config = computed(() => {
|
|
|
},
|
|
|
{
|
|
|
attrs: {
|
|
|
+ label: "流程状态",
|
|
|
+ prop: "flowStatus",
|
|
|
+ width: 120,
|
|
|
+ },
|
|
|
+ render(val) {
|
|
|
+ return proxy.dictKeyValue(val, flowStatus());
|
|
|
+ },
|
|
|
+ },
|
|
|
+ {
|
|
|
+ attrs: {
|
|
|
label: "操作",
|
|
|
width: 260,
|
|
|
align: "center",
|
|
@@ -78,17 +99,19 @@ const config = computed(() => {
|
|
|
},
|
|
|
renderHTML(row) {
|
|
|
return [
|
|
|
- {
|
|
|
- attrs: {
|
|
|
- label: "变更退货单",
|
|
|
- type: "danger",
|
|
|
- text: true,
|
|
|
- },
|
|
|
- el: "button",
|
|
|
- click() {
|
|
|
- console.log(row);
|
|
|
- },
|
|
|
- },
|
|
|
+ row.flowStatus == 0
|
|
|
+ ? {
|
|
|
+ attrs: {
|
|
|
+ label: "变更退货单",
|
|
|
+ type: "danger",
|
|
|
+ text: true,
|
|
|
+ },
|
|
|
+ el: "button",
|
|
|
+ click() {
|
|
|
+ clickChange(row);
|
|
|
+ },
|
|
|
+ }
|
|
|
+ : {},
|
|
|
{
|
|
|
attrs: {
|
|
|
label: "打印退货单",
|
|
@@ -161,6 +184,19 @@ const clickDetails = (item) => {
|
|
|
},
|
|
|
});
|
|
|
};
|
|
|
+const clickChange = (item) => {
|
|
|
+ proxy.$router.replace({
|
|
|
+ path: "/platform_manage/process/processApproval",
|
|
|
+ query: {
|
|
|
+ flowKey: "purchase_return",
|
|
|
+ flowName: "采购退货流程",
|
|
|
+ processType: "30",
|
|
|
+ businessId: item.id,
|
|
|
+ flowId: item.flowId,
|
|
|
+ random: proxy.random(),
|
|
|
+ },
|
|
|
+ });
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped></style>
|