add:新增手持功能
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
window.g = {
|
||||
dev: {
|
||||
VUE_APP_BASE_API: 'http://127.0.0.1:8010'
|
||||
VUE_APP_BASE_API: 'http://192.168.217.2:8011'
|
||||
},
|
||||
prod: {
|
||||
VUE_APP_BASE_API: 'http://127.0.0.1:8010'
|
||||
VUE_APP_BASE_API: 'http://192.168.217.2:8011'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
BIN
nladmin-ui/src/assets/images/ftdl.png
Normal file
BIN
nladmin-ui/src/assets/images/ftdl.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 39 KiB |
BIN
nladmin-ui/src/assets/images/miri.png
Normal file
BIN
nladmin-ui/src/assets/images/miri.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 975 KiB |
@@ -2,7 +2,7 @@ export default {
|
||||
'lang': 'zh',
|
||||
// 平台
|
||||
'platform': {
|
||||
'title': '诺力开发平台',
|
||||
'title': 'WMS系统',
|
||||
'tip1': '用户名不能为空',
|
||||
'tip2': '密码不能为空',
|
||||
'tip3': '验证码不能为空'
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import Logo from '@/assets/images/logo.png'
|
||||
import Logo from '@/assets/images/miri.png'
|
||||
import variables from '@/assets/styles/variables.scss'
|
||||
export default {
|
||||
name: 'SidebarLogo',
|
||||
@@ -26,7 +26,7 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
title: '诺力开发平台',
|
||||
title: 'WMS系统',
|
||||
logo: Logo,
|
||||
title_param: 'platform'
|
||||
}
|
||||
@@ -65,8 +65,8 @@ export default {
|
||||
width: 100%;
|
||||
|
||||
& .sidebar-logo {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
width: 55px;
|
||||
height: 15px;
|
||||
vertical-align: middle;
|
||||
margin-right: 6px;
|
||||
}
|
||||
|
||||
@@ -28,10 +28,10 @@ const user = {
|
||||
actions: {
|
||||
// 登录
|
||||
Login({ commit }, userInfo) {
|
||||
// const rememberMe = userInfo.rememberMe
|
||||
const rememberMe = userInfo.rememberMe
|
||||
return new Promise((resolve, reject) => {
|
||||
login(userInfo.username, userInfo.password, userInfo.code, userInfo.uuid).then(res => {
|
||||
// setToken(res.token, rememberMe)
|
||||
setToken(res.token, rememberMe)
|
||||
commit('SET_TOKEN', res.token)
|
||||
setUserInfo(res.user, commit)
|
||||
// 第一次加载菜单时用到, 具体见 src 目录下的 permission.js
|
||||
|
||||
@@ -10,6 +10,15 @@
|
||||
label-width="90px"
|
||||
label-suffix=":"
|
||||
>
|
||||
<el-form-item label="物料类型">
|
||||
<el-input
|
||||
v-model="query.material_type"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="物料类型"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="模糊搜索">
|
||||
<el-input
|
||||
v-model="query.blurry"
|
||||
@@ -103,6 +112,11 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="物料类型" prop="material_type">
|
||||
<el-input v-model="form.material_type" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
@@ -120,6 +134,7 @@
|
||||
style="width: 100%;"
|
||||
@selection-change="crud.selectionChangeHandler"
|
||||
>
|
||||
<el-table-column prop="material_type" label="物料类型" width="160" />
|
||||
<el-table-column prop="material_code" label="物料编码" width="160" />
|
||||
<el-table-column prop="material_name" label="物料名称" width="180" show-overflow-tooltip />
|
||||
<el-table-column prop="material_spec" show-overflow-tooltip show-tooltip-when-overflow :min-width="flexWidth('material_spec',crud.data,'物料规格')" label="物料规格" />
|
||||
@@ -176,6 +191,7 @@ const defaultForm = {
|
||||
material_id: null,
|
||||
ass_unit_id: null,
|
||||
material_code: null,
|
||||
material_type: null,
|
||||
material_name: null,
|
||||
material_spec: null,
|
||||
material_model: null,
|
||||
|
||||
@@ -83,6 +83,8 @@
|
||||
<el-table-column prop="remark" label="备注" :min-width="flexWidth('remark',crud.data,'备注')" />
|
||||
<el-table-column prop="create_name" label="组盘人" :min-width="flexWidth('create_name',crud.data,'组盘人')" />
|
||||
<el-table-column prop="create_time" label="组盘时间" :min-width="flexWidth('create_time',crud.data,'组盘时间')" />
|
||||
<el-table-column prop="update_name" label="修改人" :min-width="flexWidth('update_name',crud.data,'修改人')" />
|
||||
<el-table-column prop="update_time" label="修改时间" :min-width="flexWidth('update_time',crud.data,'修改时间')" />
|
||||
<el-table-column
|
||||
v-permission="['admin','Supplierbase:edit','Supplierbase:del']"
|
||||
label="操作"
|
||||
|
||||
@@ -46,12 +46,12 @@
|
||||
class="filter-item"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="批次号">
|
||||
<el-form-item label="托盘号">
|
||||
<el-input
|
||||
v-model="query.pcsn"
|
||||
v-model="query.storagevehicle_code"
|
||||
clearable
|
||||
size="small"
|
||||
placeholder="批次号"
|
||||
placeholder="托盘号"
|
||||
style="width: 200px;"
|
||||
class="filter-item"
|
||||
/>
|
||||
|
||||
252
nladmin-ui/src/views/wms/sch/materialRecord/index.vue
Normal file
252
nladmin-ui/src/views/wms/sch/materialRecord/index.vue
Normal file
@@ -0,0 +1,252 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<!--工具栏-->
|
||||
<div class="head-container">
|
||||
<div v-if="crud.props.searchToggle">
|
||||
<el-form
|
||||
:inline="true"
|
||||
class="demo-form-inline"
|
||||
label-position="right"
|
||||
label-width="90px"
|
||||
label-suffix=":"
|
||||
>
|
||||
<el-form-item label="模糊搜索">
|
||||
<el-input
|
||||
v-model="query.blurry"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="区域编码"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<rrOperation />
|
||||
</el-form>
|
||||
</div>
|
||||
<!--如果想在工具栏加入更多按钮,可以使用插槽方式, slot = 'left' or 'right'-->
|
||||
<crudOperation :permission="permission" />
|
||||
<!--表单组件-->
|
||||
<el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="crud.status.cu > 0" :title="crud.status.title" width="800px">
|
||||
<el-form ref="form" :model="form" style="border: 1px solid #cfe0df;margin-top: 10px;padding-top: 10px;" :inline="true" :rules="rules" size="mini" label-width="115px" label-suffix=":">
|
||||
<el-form-item label="区域编码" prop="region_code">
|
||||
<el-select v-model="form.region_code" placeholder="请选择" style="width: 200px;">
|
||||
<el-option
|
||||
v-for="item in regionList"
|
||||
:key="item.region_code"
|
||||
:label="item.region_name"
|
||||
:value="item.region_code"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="物料编码" prop="material_code">
|
||||
<el-input v-model="form.material_code" disabled class="input-with-select">
|
||||
<el-button slot="append" icon="el-icon-search" @click="getMaterial()" />
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="物料名称" prop="material_name">
|
||||
<el-input v-model="form.material_name" disabled style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="物料数量" prop="qty">
|
||||
<el-input v-model="form.qty" style="width: 200px;" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<label slot="label">备 注:</label>
|
||||
<el-input v-model.trim="form.remark" style="width: 480px;" rows="2" type="textarea" :disabled="crud.status.view > 0" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="text" @click="crud.cancelCU">取消</el-button>
|
||||
<el-button :loading="crud.cu === 2" type="primary" @click="crud.submitCU">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="table"
|
||||
v-loading="crud.loading"
|
||||
:data="crud.data"
|
||||
size="mini"
|
||||
style="width: 100%;"
|
||||
@selection-change="crud.selectionChangeHandler"
|
||||
>
|
||||
<el-table-column prop="region_code" label="区域编码" :min-width="flexWidth('region_code',crud.data,'区域编码')" />
|
||||
<el-table-column prop="region_name" label="区域名称" :min-width="flexWidth('region_name',crud.data,'区域名称')" />
|
||||
<el-table-column prop="material_code" label="物料编码" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
|
||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
||||
<el-table-column prop="qty" label="物料数量" show-overflow-tooltip :min-width="flexWidth('qty',crud.data,'物料数量')" />
|
||||
<el-table-column prop="measure_unit_id" label="计量单位" show-overflow-tooltip :min-width="flexWidth('measure_unit_id',crud.data,'计量单位')" />
|
||||
<el-table-column prop="remark" label="备注" :min-width="flexWidth('remark',crud.data,'备注')" />
|
||||
<el-table-column prop="create_name" label="创建人" :min-width="flexWidth('create_name',crud.data,'创建人')" />
|
||||
<el-table-column prop="create_time" label="创建时间" :min-width="flexWidth('create_time',crud.data,'创建时间')" />
|
||||
<el-table-column prop="update_name" label="修改人" :min-width="flexWidth('update_name',crud.data,'修改人')" />
|
||||
<el-table-column prop="update_time" label="修改时间" :min-width="flexWidth('update_time',crud.data,'修改时间')" />
|
||||
<el-table-column v-permission="[]" label="操作" width="120px" align="center" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<udOperation
|
||||
:data="scope.row"
|
||||
:permission="permission"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<pagination />
|
||||
</div>
|
||||
<ViewDialog :dialog-show.sync="viewShow" :rowmst="mstrow" @AddChanged="querytable" />
|
||||
<MaterialDialog :dialog-show.sync="materialDialog" @materialChoose="tableChanged" />
|
||||
<!-- <WorkOrderDialog :dialog-show.sync="workOrderDialog" @tableChanged="tableChanged" />-->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import crudMaterialRecord from './materialRecord'
|
||||
import CRUD, { crud, form, header, presenter } from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import udOperation from '@crud/UD.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
import crudSchBaseRegion from '@/views/wms/sch/region/schBaseRegion'
|
||||
import MaterialDialog from '@/views/wms/basedata/material/MaterialDialog'
|
||||
|
||||
const defaultForm = {
|
||||
region_code: null,
|
||||
region_name: null,
|
||||
material_code: null,
|
||||
material_name: null,
|
||||
qty: null,
|
||||
measure_unit_id: null,
|
||||
remark: null,
|
||||
is_delete: false
|
||||
}
|
||||
export default {
|
||||
name: 'MaterialRecord',
|
||||
dicts: ['group_status', 'group_status', 'vehicle_type'],
|
||||
tableEnums: ['md_pb_measureunit#unit_name#measure_unit_id'],
|
||||
components: { pagination, crudOperation, rrOperation, udOperation, MaterialDialog },
|
||||
mixins: [presenter(), header(), form(defaultForm), crud()],
|
||||
cruds() {
|
||||
return CRUD({
|
||||
title: '用料清单管理',
|
||||
url: 'api/materialRecord',
|
||||
idField: 'record_id',
|
||||
sort: 'region_code,desc',
|
||||
optShow: {
|
||||
add: true,
|
||||
edit: true,
|
||||
del: true,
|
||||
download: false,
|
||||
reset: true
|
||||
},
|
||||
crudMethod: { ...crudMaterialRecord }
|
||||
})
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
permission: {
|
||||
},
|
||||
rules: {
|
||||
material_code: [
|
||||
{ required: true, message: '物料号不能为空', trigger: 'blur' }
|
||||
],
|
||||
material_name: [
|
||||
{ required: true, message: '物料名称不能为空', trigger: 'blur' }
|
||||
]
|
||||
},
|
||||
workShopList: [],
|
||||
pointList: [],
|
||||
regionList: [],
|
||||
viewShow: false,
|
||||
mstrow: {},
|
||||
choose: '物料',
|
||||
materialDialog: false,
|
||||
workOrderDialog: false
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getRegionList()
|
||||
},
|
||||
methods: {
|
||||
// 钩子:在获取表格数据之前执行,false 则代表不获取数据
|
||||
[CRUD.HOOK.beforeRefresh]() {
|
||||
return true
|
||||
},
|
||||
handleSelectionChange(val, row) {
|
||||
if (val.length > 1) {
|
||||
this.$refs.table.clearSelection()
|
||||
this.$refs.table.toggleRowSelection(val.pop())
|
||||
this.buttonChange(row)
|
||||
} else if (val.length === 1) {
|
||||
this.buttonChange(row)
|
||||
} else {
|
||||
this.handleCurrentChange(null)
|
||||
}
|
||||
},
|
||||
onSelectAll() {
|
||||
this.$refs.table.clearSelection()
|
||||
this.handleCurrentChange(null)
|
||||
},
|
||||
buttonChange(currentRow) {
|
||||
if (currentRow !== null) {
|
||||
this.currentRow = currentRow
|
||||
if (currentRow.bill_status === '10' || currentRow.bill_status === '20' || currentRow.bill_status === '30' || currentRow.bill_status === '40') {
|
||||
this.dis_flag = false
|
||||
} else {
|
||||
this.dis_flag = true
|
||||
}
|
||||
if (currentRow.bill_status === '30' || currentRow.bill_status === '40') {
|
||||
this.task_flag = false
|
||||
} else {
|
||||
this.task_flag = true
|
||||
}
|
||||
}
|
||||
},
|
||||
handleCurrentChange(currentRow) {
|
||||
if (currentRow === null) {
|
||||
this.dis_flag = true
|
||||
this.task_flag = true
|
||||
this.currentRow = {}
|
||||
}
|
||||
},
|
||||
getRegionList() {
|
||||
crudSchBaseRegion.getRegions().then(res => {
|
||||
this.regionList = res
|
||||
})
|
||||
},
|
||||
toView(index, row) {
|
||||
this.mstrow = row
|
||||
this.viewShow = true
|
||||
},
|
||||
querytable() {
|
||||
this.onSelectAll()
|
||||
this.crud.toQuery()
|
||||
},
|
||||
getMaterial() {
|
||||
if (this.choose === '物料') {
|
||||
this.materialDialog = true
|
||||
} else {
|
||||
this.workOrderDialog = true
|
||||
}
|
||||
},
|
||||
tableChanged(row) {
|
||||
debugger
|
||||
this.form.material_name = row.material_name
|
||||
this.form.material_code = row.material_code
|
||||
},
|
||||
clearMaterial() {
|
||||
this.form.material_name = null
|
||||
this.form.material_id = null
|
||||
this.form.material_spec = null
|
||||
this.form.material_code = null
|
||||
},
|
||||
setPointName(data) {
|
||||
var point = this.pointList.find(item => item.point_code === data)
|
||||
this.form.point_name = point.point_name
|
||||
},
|
||||
hand(value) {
|
||||
this.crud.toQuery()
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
</style>
|
||||
@@ -0,0 +1,27 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function add(data) {
|
||||
return request({
|
||||
url: 'api/materialRecord',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function del(ids) {
|
||||
return request({
|
||||
url: 'api/materialRecord/',
|
||||
method: 'delete',
|
||||
data: ids
|
||||
})
|
||||
}
|
||||
|
||||
export function edit(data) {
|
||||
return request({
|
||||
url: 'api/materialRecord',
|
||||
method: 'put',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del }
|
||||
@@ -34,6 +34,15 @@
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="托盘号">
|
||||
<el-input
|
||||
v-model="query.storagevehicle_code"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="托盘号"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="区域类型">
|
||||
<el-select
|
||||
v-model="query.region_code"
|
||||
@@ -331,15 +340,15 @@
|
||||
:data="scope.row"
|
||||
:permission="permission"
|
||||
/>
|
||||
<el-button
|
||||
v-if="showButton(scope.row.point_status)"
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-view"
|
||||
@click="toView(scope.row)"
|
||||
>
|
||||
查看详情
|
||||
</el-button>
|
||||
<!-- <el-button-->
|
||||
<!-- v-if="showButton(scope.row.point_status)"-->
|
||||
<!-- size="mini"-->
|
||||
<!-- type="text"-->
|
||||
<!-- icon="el-icon-view"-->
|
||||
<!-- @click="toView(scope.row)"-->
|
||||
<!-- >-->
|
||||
<!-- 查看详情-->
|
||||
<!-- </el-button>-->
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -472,7 +481,6 @@ export default {
|
||||
// },
|
||||
getRegionList() {
|
||||
crudSchBaseRegion.getRegionList().then(res => {
|
||||
debugger
|
||||
this.regionList = res
|
||||
})
|
||||
},
|
||||
|
||||
@@ -31,6 +31,14 @@ export function getRegionList(data) {
|
||||
})
|
||||
}
|
||||
|
||||
export function getRegions(data) {
|
||||
return request({
|
||||
url: 'api/schBaseRegion/getRegions',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function getPointStatusSelectById(id) {
|
||||
return request({
|
||||
url: 'api/schBaseRegion/getPointStatusSelectById',
|
||||
@@ -47,4 +55,4 @@ export function getPointTypeSelectById(id) {
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, getRegionList, getPointStatusSelectById, getPointTypeSelectById }
|
||||
export default { add, edit, del, getRegionList, getPointStatusSelectById, getPointTypeSelectById, getRegions }
|
||||
|
||||
Reference in New Issue
Block a user