|
@@ -25,6 +25,33 @@
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
|
|
|
|
|
|
+ <el-row :gutter="10" class="mb8">
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
+ <el-button
|
|
|
|
+ type="primary"
|
|
|
|
+ plain
|
|
|
|
+ icon="el-icon-plus"
|
|
|
|
+ size="mini"
|
|
|
|
+ @click="handleAdj"
|
|
|
|
+ v-hasPermi="['ams:invLotLocId:adj']"
|
|
|
|
+ >库存调整
|
|
|
|
+ </el-button>
|
|
|
|
+ </el-col>
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
+ <el-button
|
|
|
|
+ type="success"
|
|
|
|
+ plain
|
|
|
|
+ icon="el-icon-edit"
|
|
|
|
+ size="mini"
|
|
|
|
+ @click="handleMove"
|
|
|
|
+ v-hasPermi="['ams:invLotLocId:move']"
|
|
|
|
+ >库存移动
|
|
|
|
+ </el-button>
|
|
|
|
+ </el-col>
|
|
|
|
+ <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
|
|
+ </el-row>
|
|
|
|
+
|
|
|
|
+
|
|
<!--<el-row :gutter="10" class="mb8">
|
|
<!--<el-row :gutter="10" class="mb8">
|
|
<el-col :span="1.5">
|
|
<el-col :span="1.5">
|
|
<el-button
|
|
<el-button
|
|
@@ -73,6 +100,7 @@
|
|
|
|
|
|
<el-table v-loading="loading" :data="invLotLocIdList" @selection-change="handleSelectionChange">
|
|
<el-table v-loading="loading" :data="invLotLocIdList" @selection-change="handleSelectionChange">
|
|
<!--<el-table-column label="lotnum" align="center" prop="lotnum" width="200"/>-->
|
|
<!--<el-table-column label="lotnum" align="center" prop="lotnum" width="200"/>-->
|
|
|
|
+ <el-table-column type="selection" />
|
|
<el-table-column label="物料" align="center" prop="sku" width="200"/>
|
|
<el-table-column label="物料" align="center" prop="sku" width="200"/>
|
|
<el-table-column label="物料名称" align="center" prop="skuName" width="200"/>
|
|
<el-table-column label="物料名称" align="center" prop="skuName" width="200"/>
|
|
<el-table-column label="库位" align="center" prop="locationNo" width="200"/>
|
|
<el-table-column label="库位" align="center" prop="locationNo" width="200"/>
|
|
@@ -158,25 +186,34 @@
|
|
<el-button @click="cancel">取 消</el-button>
|
|
<el-button @click="cancel">取 消</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
+
|
|
|
|
+ <!-- 库存调整dialog -->
|
|
|
|
+ <adj-dialog ref="adjDialog" @getList="getList()"></adj-dialog>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
-import { listInvLotLocId, getInvLotLocId, delInvLotLocId, addInvLotLocId, updateInvLotLocId } from "@/api/ams/invLotLocId";
|
|
|
|
|
|
+import { listInvLotLocId, getInvLotLocId, adjInvLotLocId, moveInvLotLocId, delInvLotLocId, addInvLotLocId, updateInvLotLocId } from "@/api/ams/invLotLocId";
|
|
import { lotattConfigList } from "@/api/ams/config";
|
|
import { lotattConfigList } from "@/api/ams/config";
|
|
|
|
+import adjDialog from "@/views/ams/inv/invLotLocId/adjDialog";
|
|
|
|
|
|
export default {
|
|
export default {
|
|
name: "InvLotLocId",
|
|
name: "InvLotLocId",
|
|
|
|
+ components: { adjDialog },
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
// 遮罩层
|
|
// 遮罩层
|
|
loading: true,
|
|
loading: true,
|
|
// 选中数组
|
|
// 选中数组
|
|
ids: [],
|
|
ids: [],
|
|
|
|
+ // 选中的数据
|
|
|
|
+ tableSelection: [],
|
|
|
|
+ // 是否勾选
|
|
|
|
+ isSelect: false,
|
|
// 非单个禁用
|
|
// 非单个禁用
|
|
- single: true,
|
|
|
|
|
|
+ single: false,
|
|
// 非多个禁用
|
|
// 非多个禁用
|
|
- multiple: true,
|
|
|
|
|
|
+ multiple: false,
|
|
// 显示搜索条件
|
|
// 显示搜索条件
|
|
showSearch: true,
|
|
showSearch: true,
|
|
// 总条数
|
|
// 总条数
|
|
@@ -271,8 +308,29 @@ export default {
|
|
// 多选框选中数据
|
|
// 多选框选中数据
|
|
handleSelectionChange(selection) {
|
|
handleSelectionChange(selection) {
|
|
this.ids = selection.map(item => item.lotnum)
|
|
this.ids = selection.map(item => item.lotnum)
|
|
- this.single = selection.length!==1
|
|
|
|
- this.multiple = !selection.length
|
|
|
|
|
|
+ this.tableSelection = selection;
|
|
|
|
+ this.isSelect = selection.length > 0;
|
|
|
|
+ this.single = selection.length == 1;
|
|
|
|
+ this.multiple = selection.length > 1;
|
|
|
|
+
|
|
|
|
+ },
|
|
|
|
+ /** 库存调整操作 */
|
|
|
|
+ handleAdj() {
|
|
|
|
+ if (!this.isSelect) {
|
|
|
|
+ this.$modal.alertWarning("请选择一条!");
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ if (!this.single) {
|
|
|
|
+ this.$modal.alertWarning("库存调整只能选择单条!");
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ this.$nextTick(() => {
|
|
|
|
+ this.$refs.adjDialog.show(this.tableSelection);
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ /** 库存移动操作 */
|
|
|
|
+ handleMove() {
|
|
|
|
+
|
|
},
|
|
},
|
|
/** 新增按钮操作 */
|
|
/** 新增按钮操作 */
|
|
handleAdd() {
|
|
handleAdd() {
|