feat: 耗材补充修改
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
@reset-click="handleResetClick"
|
||||
/>
|
||||
<!-- 统计 -->
|
||||
<data-tongji :data="gongjiData"></data-tongji>
|
||||
<data-tongji :data="gongjiData" />
|
||||
<!-- 列表 -->
|
||||
<page-content
|
||||
ref="contentRef"
|
||||
@@ -35,24 +35,24 @@
|
||||
<div class="goods-list">
|
||||
<el-button
|
||||
v-for="item in scope.row.productList"
|
||||
@click="toGoods(item.id)"
|
||||
:key="item.productId"
|
||||
type="text"
|
||||
@click="toGoods(item.id)"
|
||||
>
|
||||
{{ item.name }}
|
||||
</el-button>
|
||||
<span v-if="scope.row.productList.length > 1">,</span>
|
||||
</div>
|
||||
<el-dropdown trigger="click" v-if="scope.row.productList.length > 1" @command="toGoods">
|
||||
<el-dropdown v-if="scope.row.productList.length > 1" trigger="click" @command="toGoods">
|
||||
<span class="el-dropdown-link" style="color: blue">
|
||||
<el-icon><CaretBottom /></el-icon>
|
||||
</span>
|
||||
<template #dropdown>
|
||||
<el-dropdown-menu>
|
||||
<el-dropdown-item
|
||||
class="clearfix"
|
||||
v-for="item in scope.row.productList"
|
||||
:key="item.id"
|
||||
class="clearfix"
|
||||
:command="item.id"
|
||||
>
|
||||
{{ item.name }}
|
||||
@@ -80,18 +80,31 @@
|
||||
/>
|
||||
</template>
|
||||
<template #operate="scope">
|
||||
<div>
|
||||
<el-button @click="refAddHaocaiOpen(scope.row)" type="primary" link>编辑</el-button>
|
||||
<el-button @click="refAddHaocaiTakinShow(scope.row)" link type="primary">
|
||||
<div
|
||||
style="
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
"
|
||||
>
|
||||
<el-button type="primary" link @click="refAddHaocaiOpen(scope.row)">编辑</el-button>
|
||||
<el-button link type="primary" @click="refAddHaocaiTakinShow(scope.row, 'consumables')">
|
||||
耗材盘点
|
||||
</el-button>
|
||||
<el-button link type="primary" @click="refAddHaocaiTakinShow(scope.row, 'manual-in')">
|
||||
入库记录
|
||||
</el-button>
|
||||
<!-- <el-button link type="primary" @click="refAddHaocaiTakinShow(scope.row, 'delete')">
|
||||
删除
|
||||
</el-button> -->
|
||||
</div>
|
||||
</template>
|
||||
</page-content>
|
||||
<!-- 耗材添加编辑 -->
|
||||
<add-haocai ref="refAddHaocai" @refresh="refresh"></add-haocai>
|
||||
<add-haocai ref="refAddHaocai" @refresh="refresh" />
|
||||
<!-- 耗材盘点 -->
|
||||
<addConsTakin ref="refAddHaocaiTakin" @success="refresh"></addConsTakin>
|
||||
<addConsTakin ref="refAddHaocaiTakin" @success="refresh" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -152,7 +165,20 @@ watch(
|
||||
|
||||
//耗材盘点
|
||||
const refAddHaocaiTakin = ref();
|
||||
function refAddHaocaiTakinShow(item: any) {
|
||||
function refAddHaocaiTakinShow(item: any, type: string) {
|
||||
console.log(item);
|
||||
if (type === "manual-in") {
|
||||
router.push({ path: "/inventory/libraryrecords", query: { type: type, conId: item.id } });
|
||||
return;
|
||||
}
|
||||
if (type === "delete") {
|
||||
refAddHaocaiTakin.value.show(item, type);
|
||||
return;
|
||||
}
|
||||
if (type === "consumables") {
|
||||
refAddHaocaiTakin.value.show(item, type);
|
||||
return;
|
||||
}
|
||||
refAddHaocaiTakin.value.show(item);
|
||||
}
|
||||
|
||||
@@ -195,6 +221,10 @@ function handleToolbarClick(name: string) {
|
||||
router.push({ path: "/inventory/operation_in", query: { type: "out" } });
|
||||
return;
|
||||
}
|
||||
if (name == "damage-out" || name == "manual-out" || name == "manual-in") {
|
||||
router.push({ path: "/inventory/libraryrecords", query: { type: name } });
|
||||
return;
|
||||
}
|
||||
}
|
||||
// 其他操作列
|
||||
async function handleOperatClick(data: IOperatData) {
|
||||
|
||||
Reference in New Issue
Block a user