|
@@ -31,49 +31,63 @@
|
|
|
|
|
|
|
|
<template v-slot:isTemp="{ row }">
|
|
<template v-slot:isTemp="{ row }">
|
|
|
<el-tag size="mini" v-if="row.isTemp == 1">主数据</el-tag>
|
|
<el-tag size="mini" v-if="row.isTemp == 1">主数据</el-tag>
|
|
|
-
|
|
|
|
|
</template>
|
|
</template>
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
|
|
|
|
|
<!-- 表头工具栏 -->
|
|
<!-- 表头工具栏 -->
|
|
|
<template v-slot:action="{ row }">
|
|
<template v-slot:action="{ row }">
|
|
|
<el-link type="primary" @click="handelDetail(row)">详情</el-link>
|
|
<el-link type="primary" @click="handelDetail(row)">详情</el-link>
|
|
|
- <!-- <el-switch
|
|
|
|
|
- :active-value="'1'"
|
|
|
|
|
- :inactive-value="'0'"
|
|
|
|
|
- @change="openBom(row, $event)"
|
|
|
|
|
- v-model="row.status"
|
|
|
|
|
- >
|
|
|
|
|
- </el-switch> -->
|
|
|
|
|
|
|
+
|
|
|
<el-link
|
|
<el-link
|
|
|
- v-if="row.status == 0"
|
|
|
|
|
|
|
+ v-if="row.approvalStatusOpt == 0 || row.approvalStatusOpt == 3"
|
|
|
type="primary"
|
|
type="primary"
|
|
|
@click="handSubmit(row)"
|
|
@click="handSubmit(row)"
|
|
|
>发布</el-link
|
|
>发布</el-link
|
|
|
>
|
|
>
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- <el-link type="danger" :underline="false" v-if="activeName == 1 && row.status == 0" @click="handDel(row)">
|
|
|
|
|
- 删除
|
|
|
|
|
- </el-link>
|
|
|
|
|
-
|
|
|
|
|
|
|
+ <el-link
|
|
|
|
|
+ type="danger"
|
|
|
|
|
+ :underline="false"
|
|
|
|
|
+ v-if="activeName == 1 && row.status == 0"
|
|
|
|
|
+ @click="handDel(row)"
|
|
|
|
|
+ >
|
|
|
|
|
+ 删除
|
|
|
|
|
+ </el-link>
|
|
|
</template>
|
|
</template>
|
|
|
</ele-pro-table>
|
|
</ele-pro-table>
|
|
|
</el-tabs>
|
|
</el-tabs>
|
|
|
</el-card>
|
|
</el-card>
|
|
|
|
|
|
|
|
|
|
+ <el-dialog
|
|
|
|
|
+ title="发布"
|
|
|
|
|
+ :visible.sync="isSubmit"
|
|
|
|
|
+ v-if="isSubmit"
|
|
|
|
|
+ width="30%"
|
|
|
|
|
+ center
|
|
|
|
|
+ >
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <el-radio v-model="radioSubmit" :label="1">药品</el-radio>
|
|
|
|
|
+ <el-radio v-model="radioSubmit" :label="2">器械</el-radio>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
|
|
+ <el-button @click="isSubmit = false">取 消</el-button>
|
|
|
|
|
+ <el-button type="primary" @click="handJsSubmit()">确 定</el-button>
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </el-dialog>
|
|
|
|
|
|
|
|
<LCdetail ref="detailRef"></LCdetail>
|
|
<LCdetail ref="detailRef"></LCdetail>
|
|
|
-
|
|
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
import BOMSearch from './components/BOM-search.vue';
|
|
import BOMSearch from './components/BOM-search.vue';
|
|
|
- import { getBomPageList, startAndStop, bomSubmit, deleteBomTreeList } from '@/api/material/BOM';
|
|
|
|
|
- import LCdetail from './components/LCdetail.vue'
|
|
|
|
|
|
|
+ import {
|
|
|
|
|
+ getBomPageList,
|
|
|
|
|
+ startAndStop,
|
|
|
|
|
+ bomSubmit,
|
|
|
|
|
+ jsBomSubmit,
|
|
|
|
|
+ deleteBomTreeList
|
|
|
|
|
+ } from '@/api/material/BOM';
|
|
|
|
|
+ import LCdetail from './components/LCdetail.vue';
|
|
|
export default {
|
|
export default {
|
|
|
name: 'SystemDictionary',
|
|
name: 'SystemDictionary',
|
|
|
components: { BOMSearch, LCdetail },
|
|
components: { BOMSearch, LCdetail },
|
|
@@ -130,8 +144,7 @@
|
|
|
width: 100,
|
|
width: 100,
|
|
|
prop: 'isTemp',
|
|
prop: 'isTemp',
|
|
|
slot: 'isTemp',
|
|
slot: 'isTemp',
|
|
|
- label: '主数据',
|
|
|
|
|
-
|
|
|
|
|
|
|
+ label: '主数据'
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
{
|
|
{
|
|
@@ -166,9 +179,20 @@
|
|
|
loadingInstance: null,
|
|
loadingInstance: null,
|
|
|
where: {},
|
|
where: {},
|
|
|
|
|
|
|
|
- activeName: '1'
|
|
|
|
|
|
|
+ activeName: '1',
|
|
|
|
|
+
|
|
|
|
|
+ isSubmit: false,
|
|
|
|
|
+ JsRId: null,
|
|
|
|
|
+ radioSubmit: 1
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
|
|
+
|
|
|
|
|
+ computed: {
|
|
|
|
|
+ clientEnvironmentId() {
|
|
|
|
|
+ return this.$store.state.user.info.clientEnvironmentId;
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
mounted() {
|
|
mounted() {
|
|
|
this.initData();
|
|
this.initData();
|
|
|
},
|
|
},
|
|
@@ -217,15 +241,37 @@
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
handSubmit(row) {
|
|
handSubmit(row) {
|
|
|
|
|
+ if (this.clientEnvironmentId == 3) {
|
|
|
|
|
+ this.JsRId = row.id;
|
|
|
|
|
+ this.isSubmit = true;
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.$alert('确定要发布吗?', '提示', {
|
|
|
|
|
+ confirmButtonText: '确定',
|
|
|
|
|
+ cancelButtonText: '取消',
|
|
|
|
|
+ type: 'warning'
|
|
|
|
|
+ })
|
|
|
|
|
+ .then(() => {
|
|
|
|
|
+ bomSubmit({ businessId: row.id }).then((res) => {
|
|
|
|
|
+ this.$message.success('发布成功');
|
|
|
|
|
+ this.reload();
|
|
|
|
|
+ });
|
|
|
|
|
+ })
|
|
|
|
|
+ .catch(() => {});
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
|
|
+ handJsSubmit() {
|
|
|
|
|
+ let URL = this.radioSubmit == 1 ? jsBomSubmit : bomSubmit;
|
|
|
this.$alert('确定要发布吗?', '提示', {
|
|
this.$alert('确定要发布吗?', '提示', {
|
|
|
confirmButtonText: '确定',
|
|
confirmButtonText: '确定',
|
|
|
cancelButtonText: '取消',
|
|
cancelButtonText: '取消',
|
|
|
type: 'warning'
|
|
type: 'warning'
|
|
|
})
|
|
})
|
|
|
.then(() => {
|
|
.then(() => {
|
|
|
- bomSubmit({ businessId: row.id }).then((res) => {
|
|
|
|
|
|
|
+ URL({ businessId: this.JsRId }).then((res) => {
|
|
|
this.$message.success('发布成功');
|
|
this.$message.success('发布成功');
|
|
|
this.reload();
|
|
this.reload();
|
|
|
|
|
+ this.isSubmit = false;
|
|
|
});
|
|
});
|
|
|
})
|
|
})
|
|
|
.catch(() => {});
|
|
.catch(() => {});
|
|
@@ -260,9 +306,6 @@
|
|
|
this.$refs.table.reload({ where });
|
|
this.$refs.table.reload({ where });
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
handleClick(tab) {
|
|
handleClick(tab) {
|
|
|
this.activeName = tab.name;
|
|
this.activeName = tab.name;
|
|
|
this.reload();
|
|
this.reload();
|
|
@@ -275,10 +318,9 @@
|
|
|
type: 'warning'
|
|
type: 'warning'
|
|
|
})
|
|
})
|
|
|
.then(() => {
|
|
.then(() => {
|
|
|
- deleteBomTreeList([row.id])
|
|
|
|
|
- .then(() => {
|
|
|
|
|
- this.reload();
|
|
|
|
|
- })
|
|
|
|
|
|
|
+ deleteBomTreeList([row.id]).then(() => {
|
|
|
|
|
+ this.reload();
|
|
|
|
|
+ });
|
|
|
})
|
|
})
|
|
|
.catch(() => {
|
|
.catch(() => {
|
|
|
this.$message({
|
|
this.$message({
|
|
@@ -288,15 +330,13 @@
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
-
|
|
|
|
|
- handleDetails(row) {
|
|
|
|
|
- if (!row.processInstanceId) {
|
|
|
|
|
- this.$message.info('未提交没有审核流程')
|
|
|
|
|
- } else {
|
|
|
|
|
- this.$refs.detailRef.open(row.processInstanceId);
|
|
|
|
|
|
|
+ handleDetails(row) {
|
|
|
|
|
+ if (!row.processInstanceId) {
|
|
|
|
|
+ this.$message.info('未提交没有审核流程');
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.$refs.detailRef.open(row.processInstanceId);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- }
|
|
|
|
|
}
|
|
}
|
|
|
};
|
|
};
|
|
|
</script>
|
|
</script>
|