Commit 64078e62 authored by wanglianghe's avatar wanglianghe

仓位修改为储位

parent af850750
import request from '@/utils/request' import request from '@/utils/request'
// 创建 // 创建
export function createWarehouseAreaPosition(data) { export function createWarehouseAreaPosition(data) {
return request({ return request({
url: '/ecw/warehouse-area-position/create', url: '/ecw/warehouse-area-position/create',
...@@ -9,7 +9,7 @@ export function createWarehouseAreaPosition(data) { ...@@ -9,7 +9,7 @@ export function createWarehouseAreaPosition(data) {
}) })
} }
// 更新 // 更新
export function updateWarehouseAreaPosition(data) { export function updateWarehouseAreaPosition(data) {
return request({ return request({
url: '/ecw/warehouse-area-position/update', url: '/ecw/warehouse-area-position/update',
...@@ -18,7 +18,7 @@ export function updateWarehouseAreaPosition(data) { ...@@ -18,7 +18,7 @@ export function updateWarehouseAreaPosition(data) {
}) })
} }
// 删除 // 删除
export function deleteWarehouseAreaPosition(id) { export function deleteWarehouseAreaPosition(id) {
return request({ return request({
url: '/ecw/warehouse-area-position/delete?id=' + id, url: '/ecw/warehouse-area-position/delete?id=' + id,
...@@ -26,7 +26,7 @@ export function deleteWarehouseAreaPosition(id) { ...@@ -26,7 +26,7 @@ export function deleteWarehouseAreaPosition(id) {
}) })
} }
// 获得 // 获得
export function getWarehouseAreaPosition(id) { export function getWarehouseAreaPosition(id) {
return request({ return request({
url: '/ecw/warehouse-area-position/get?id=' + id, url: '/ecw/warehouse-area-position/get?id=' + id,
...@@ -34,7 +34,7 @@ export function getWarehouseAreaPosition(id) { ...@@ -34,7 +34,7 @@ export function getWarehouseAreaPosition(id) {
}) })
} }
// 获得位分页 // 获得位分页
export function getWarehouseAreaPositionPage(query) { export function getWarehouseAreaPositionPage(query) {
return request({ return request({
url: '/ecw/warehouse-area-position/page', url: '/ecw/warehouse-area-position/page',
...@@ -43,7 +43,7 @@ export function getWarehouseAreaPositionPage(query) { ...@@ -43,7 +43,7 @@ export function getWarehouseAreaPositionPage(query) {
}) })
} }
// 导出位 Excel // 导出位 Excel
export function exportWarehouseAreaPositionExcel(query) { export function exportWarehouseAreaPositionExcel(query) {
return request({ return request({
url: '/ecw/warehouse-area-position/export-excel', url: '/ecw/warehouse-area-position/export-excel',
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<el-button size="mini" type="text" @click="handleCreate(scope.row)" v-if="scope.row.pid==0" <el-button size="mini" type="text" @click="handleCreate(scope.row)" v-if="scope.row.pid==0"
v-hasPermi="['ecw:warehouse-area:create']">添加库区</el-button> v-hasPermi="['ecw:warehouse-area:create']">添加库区</el-button>
<el-button size="mini" type="text" @click="positionManager(scope.row)" v-if="scope.row.pid>0" <el-button size="mini" type="text" @click="positionManager(scope.row)" v-if="scope.row.pid>0"
v-hasPermi="['ecw:warehouse-area:create']">查看</el-button> v-hasPermi="['ecw:warehouse-area:create']">查看</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
......
...@@ -4,8 +4,8 @@ ...@@ -4,8 +4,8 @@
<!-- 搜索工作栏 --> <!-- 搜索工作栏 -->
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="位代码" prop="code"> <el-form-item label="位代码" prop="code">
<el-input v-model="queryParams.code" placeholder="请输入位代码" clearable @keyup.enter.native="handleQuery"/> <el-input v-model="queryParams.code" placeholder="请输入位代码" clearable @keyup.enter.native="handleQuery"/>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <el-col :span="1.5">
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['ecw:warehouse-area-position:create']">新增</el-button> v-hasPermi="['ecw:warehouse-area-position:create']">新增</el-button>
</el-col> </el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<!-- 列表 --> <!-- 列表 -->
<el-table v-loading="loading" :data="list" row-key="id" default-expand-all :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> <el-table v-loading="loading" :data="list" row-key="id" default-expand-all :tree-props="{children: 'children', hasChildren: 'hasChildren'}">
<el-table-column label="位代码" align="center" prop="code" /> <el-table-column label="位代码" align="center" prop="code" />
<el-table-column label="仓库" align="center" prop="warehouseId"> <el-table-column label="仓库" align="center" prop="warehouseId">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ warehouseName(scope.row.warehouseId) }}</span> <span>{{ warehouseName(scope.row.warehouseId) }}</span>
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['ecw:warehouse-area-position:delete']">删除</el-button> v-hasPermi="['ecw:warehouse-area-position:delete']">删除</el-button>
<el-button size="mini" type="text" @click="handleCreate(scope.row)" v-if="scope.row.pid==0" <el-button size="mini" type="text" @click="handleCreate(scope.row)" v-if="scope.row.pid==0"
v-hasPermi="['ecw:warehouse-area:create']">添加</el-button> v-hasPermi="['ecw:warehouse-area:create']">添加</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
...@@ -68,8 +68,8 @@ ...@@ -68,8 +68,8 @@
<span>{{parentDo.code}}</span> <span>{{parentDo.code}}</span>
</el-form-item> </el-form-item>
<el-form-item label="位代码" prop="code"> <el-form-item label="位代码" prop="code">
<el-input v-model="form.code" placeholder="请输入仓位代码" /> <el-input v-model="form.code" placeholder="请输位代码" />
</el-form-item> </el-form-item>
<el-form-item label="仓库" prop="warehouseId"> <el-form-item label="仓库" prop="warehouseId">
...@@ -143,7 +143,7 @@ export default { ...@@ -143,7 +143,7 @@ export default {
showSearch: true, showSearch: true,
// 总条数 // 总条数
total: 0, total: 0,
//位列表 //位列表
list: [], list: [],
// 弹出层标题 // 弹出层标题
title: "", title: "",
...@@ -168,7 +168,7 @@ export default { ...@@ -168,7 +168,7 @@ export default {
form: {}, form: {},
// 表单校验 // 表单校验
rules: { rules: {
code: [{ required: true, message: "位代码不能为空", trigger: "blur" }], code: [{ required: true, message: "位代码不能为空", trigger: "blur" }],
warehouseId: [{ required: true, message: "仓库不能为空", trigger: "blur" }], warehouseId: [{ required: true, message: "仓库不能为空", trigger: "blur" }],
domainId: [{ required: true, message: "库域不能为空", trigger: "blur" }], domainId: [{ required: true, message: "库域不能为空", trigger: "blur" }],
areaId: [{ required: true, message: "库区不能为空", trigger: "blur" }], areaId: [{ required: true, message: "库区不能为空", trigger: "blur" }],
...@@ -331,7 +331,7 @@ computed: { ...@@ -331,7 +331,7 @@ computed: {
this.parentDo = null; this.parentDo = null;
this.form.status = 0; this.form.status = 0;
this.form.isShelf = 1; this.form.isShelf = 1;
this.title = "添加"; this.title = "添加";
}, },
/** 修改按钮操作 */ /** 修改按钮操作 */
handleUpdate(row) { handleUpdate(row) {
...@@ -344,7 +344,7 @@ computed: { ...@@ -344,7 +344,7 @@ computed: {
} }
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改"; this.title = "修改";
}); });
}, },
/** 提交按钮 */ /** 提交按钮 */
...@@ -373,7 +373,7 @@ computed: { ...@@ -373,7 +373,7 @@ computed: {
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const id = row.id; const id = row.id;
this.$modal.confirm('是否确认删除位编号为"' + id + '"的数据项?').then(function() { this.$modal.confirm('是否确认删除位编号为"' + id + '"的数据项?').then(function() {
return deleteWarehouseAreaPosition(id); return deleteWarehouseAreaPosition(id);
}).then(() => { }).then(() => {
this.getList(); this.getList();
...@@ -388,7 +388,7 @@ computed: { ...@@ -388,7 +388,7 @@ computed: {
params.pageSize = undefined; params.pageSize = undefined;
this.addBeginAndEndTime(params, this.dateRangeCreateTime, 'createTime'); this.addBeginAndEndTime(params, this.dateRangeCreateTime, 'createTime');
// 执行导出 // 执行导出
this.$modal.confirm('是否确认导出所有位数据项?').then(() => { this.$modal.confirm('是否确认导出所有位数据项?').then(() => {
this.exportLoading = true; this.exportLoading = true;
return exportWarehouseAreaPositionExcel(params); return exportWarehouseAreaPositionExcel(params);
}).then(response => { }).then(response => {
...@@ -397,7 +397,7 @@ computed: { ...@@ -397,7 +397,7 @@ computed: {
}).catch(() => {}); }).catch(() => {});
}, },
/** 新增位 */ /** 新增位 */
handleCreate(row) { handleCreate(row) {
this.reset(); this.reset();
this.parentDo = row; this.parentDo = row;
...@@ -410,7 +410,7 @@ computed: { ...@@ -410,7 +410,7 @@ computed: {
this.form.areaName = row.areaName; this.form.areaName = row.areaName;
this.form.pid = row.id; this.form.pid = row.id;
this.open = true; this.open = true;
this.title = "添加"; this.title = "添加";
}, },
} }
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment