Merge branch 'master' of http://121.40.234.130:8899/root/hl_one
This commit is contained in:
@@ -27,7 +27,7 @@ export function edit(data) {
|
||||
export function getSect(data) {
|
||||
return request({
|
||||
url: 'api/sectattr/getSect',
|
||||
method: 'get',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
102
mes/qd/src/views/wms/scheduler_manage/scheduler/index.vue
Normal file
102
mes/qd/src/views/wms/scheduler_manage/scheduler/index.vue
Normal file
@@ -0,0 +1,102 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<!--表单组件-->
|
||||
<el-dialog append-to-body :close-on-click-modal="false" :before-close="crud.cancelCU" :visible="crud.status.cu > 0"
|
||||
:title="crud.status.title" width="500px">
|
||||
<el-form ref="form" :model="form" :rules="rules" size="mini" label-width="80px">
|
||||
<el-form-item label="物料系列" prop="code">
|
||||
<el-input v-model="form.material_spec" style="width: 370px;"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="工序调度编号">
|
||||
<el-input v-model="form.process_id" style="width: 370px;"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="text" @click="crud.cancelCU">取消</el-button>
|
||||
<el-button :loading="crud.status.cu === 2" type="primary" @click="crud.submitCU">确认</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<!-- 字典列表 -->
|
||||
<el-card class="box-card">
|
||||
<!--工具栏-->
|
||||
<div class="head-container">
|
||||
<div v-if="crud.props.searchToggle">
|
||||
<!-- 搜索 -->
|
||||
<el-input v-model="query.blurry" clearable size="mini" placeholder="输入名称或者描述搜索" style="width: 200px;"
|
||||
class="filter-item" @keyup.enter.native="crud.toQuery"/>
|
||||
<rrOperation/>
|
||||
</div>
|
||||
<crudOperation :permission="permission"/>
|
||||
</div>
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="table"
|
||||
v-loading="crud.loading"
|
||||
:data="crud.data"
|
||||
highlight-current-row
|
||||
style="width: 100%;"
|
||||
@selection-change="crud.selectionChangeHandler"
|
||||
@current-change="handleCurrentChange">
|
||||
<el-table-column type="selection" width="55"/>
|
||||
<el-table-column show-overflow-tooltip prop="material_spec" label="物料系列"/>
|
||||
<el-table-column show-overflow-tooltip prop="process_id" label="工序调度编号"/>
|
||||
<el-table-column show-overflow-tooltip prop="process_name" label="工序调度名称"/>
|
||||
<el-table-column v-permission="['admin','dict:edit','dict:del']" label="操作" width="130px" align="center"
|
||||
fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<udOperation
|
||||
:data="scope.row"
|
||||
:permission="permission"
|
||||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<!--分页组件-->
|
||||
<pagination/>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import crudRoute from '@/views/wms/scheduler_manage/scheduler/schedulerRoute.js'
|
||||
import CRUD, {presenter, header, form} from '@crud/crud'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import udOperation from '@crud/UD.operation'
|
||||
|
||||
const defaultForm = {material_spec: null, process_id: null, process_name: null}
|
||||
|
||||
export default {
|
||||
name: 'SchedulerRoute',
|
||||
components: {crudOperation, pagination, rrOperation, udOperation},
|
||||
cruds() {
|
||||
return [
|
||||
CRUD({title: '物料对应工序调度', url: '/api/shceduler/route', idField: 'material_spec', crudMethod: {...crudRoute}})
|
||||
]
|
||||
},
|
||||
mixins: [presenter(), header(), form(defaultForm)],
|
||||
data() {
|
||||
return {
|
||||
queryTypeOptions: [
|
||||
{key: 'name', display_name: '字典名称'},
|
||||
{key: 'description', display_name: '描述'}
|
||||
],
|
||||
rules: {
|
||||
material_spec: [
|
||||
{required: true, message: '请输入编码', trigger: 'blur'}
|
||||
]
|
||||
},
|
||||
permission: {
|
||||
add: ['admin', 'dict:add'],
|
||||
edit: ['admin', 'dict:edit'],
|
||||
del: ['admin', 'dict:del']
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
</style>
|
||||
@@ -0,0 +1,34 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
export function getRoutes() {
|
||||
return request({
|
||||
url: '/api/shceduler/route',
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
export function add(data) {
|
||||
return request({
|
||||
url: '/api/shceduler/routeCreate',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function del(ids) {
|
||||
return request({
|
||||
url: '/api/shceduler/routeDelete',
|
||||
method: 'post',
|
||||
data: ids
|
||||
})
|
||||
}
|
||||
|
||||
export function edit(data) {
|
||||
return request({
|
||||
url: '/api/shceduler/routeUpdate',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export default { getRoutes, add, edit, del }
|
||||
@@ -62,28 +62,6 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="车间" prop="workshop_id">
|
||||
<label slot="label">车间</label>
|
||||
<el-select
|
||||
v-model="form.workshop_id"
|
||||
clearable
|
||||
size="mini"
|
||||
placeholder="全部"
|
||||
class="filter-item"
|
||||
@change="crud.toQuery"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.product_area"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="仓位" prop="struct_id">
|
||||
<label slot="label">仓位:</label>
|
||||
<el-input v-model="form.struct_id" size="mini" disabled style="width: 210px" />
|
||||
</el-form-item>
|
||||
<el-form-item label="单据状态" prop="bill_status">
|
||||
<el-select
|
||||
v-model="form.bill_status"
|
||||
@@ -226,7 +204,7 @@ import CRUD, { crud, form } from '@crud/crud'
|
||||
import crudProductIn from '@/views/wms/storage_manage/product/productIn/productin'
|
||||
import MaterDtl from '@/views/wms/pub/MaterDialog'
|
||||
import AddDtl from '@/views/wms/storage_manage/product/productIn/AddDtl'
|
||||
import crudStorattr from "@/api/wms/basedata/st/storattr"
|
||||
import crudStorattr, {getStor} from '@/views/wms/storage_manage/basedata/basedata'
|
||||
|
||||
const defaultForm = {
|
||||
bill_code: '',
|
||||
@@ -288,7 +266,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
open() {
|
||||
crudStorattr.queryStor().then(res => {
|
||||
crudStorattr.getStor({ 'stor_type': '4' }).then(res => {
|
||||
this.storlist = res.content
|
||||
})
|
||||
},
|
||||
|
||||
@@ -487,25 +487,6 @@ export default {
|
||||
row.qty = row.storage_qty
|
||||
this.bucketuniqueObj = row
|
||||
},
|
||||
divPoint() {
|
||||
if (!this.form.point_code) {
|
||||
this.crud.notify('请选择入库点', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
if (this.form.tableMater.length === 0) {
|
||||
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
crudProductIn.divPoint(this.form).then(res => {
|
||||
crudProductIn.getIODtl({ 'iostorinv_id': this.form.dtl_row.iostorinv_id, 'open_flag': '1' }).then(res => {
|
||||
this.openParam = res
|
||||
})
|
||||
crudProductIn.getDisDtl(this.form.dtl_row).then(res => {
|
||||
this.form.tableMater = res
|
||||
this.crud.notify('设置起点成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
})
|
||||
},
|
||||
divStruct() {
|
||||
if (this.dis_row === null) {
|
||||
this.crud.notify('请先选择一条分配明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
@@ -519,17 +500,16 @@ export default {
|
||||
if (this.form.checked) {
|
||||
this.divBtn = true
|
||||
|
||||
debugger
|
||||
this.dis_row.stor_id = this.stor_id
|
||||
this.dis_row.sect_id = this.sect_id
|
||||
crudProductIn.divStruct(this.dis_row).then(res => {
|
||||
/* crudProductIn.getIODtl({ 'iostorinv_id': this.form.dtl_row.iostorinv_id, 'open_flag': '1' }).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('分配成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
crudProductIn.getDisDtl(this.form.dtl_row).then(res => {
|
||||
this.form.tableMater = res
|
||||
this.divBtn = false
|
||||
this.crud.notify('分配货位成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})*/
|
||||
}).finally(() => {
|
||||
this.divBtn = false
|
||||
})
|
||||
@@ -539,23 +519,36 @@ export default {
|
||||
}
|
||||
},
|
||||
unDivStruct() {
|
||||
if (this.form.tableMater.length <= 0) {
|
||||
this.crud.notify('不存在载具明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
if (this.dis_row === null) {
|
||||
this.crud.notify('请先选择一条分配明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
const flag = this.form.tableMater.some(mater => !mater.struct_code)
|
||||
if (flag) {
|
||||
this.crud.notify('明细存在未分配货位!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
// 如果勾选了,直接跳后台
|
||||
crudProductIn.unDivStruct(this.form).then(res => {
|
||||
crudProductIn.getIODtl({ 'iostorinv_id': this.form.dtl_row.iostorinv_id, 'open_flag': '1' }).then(res => {
|
||||
|
||||
crudProductIn.unDivStruct(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('取消成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
crudProductIn.getDisDtl(this.form.dtl_row).then(res => {
|
||||
this.form.tableMater = res
|
||||
this.crud.notify('取消分配成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
},
|
||||
divPoint() {
|
||||
if (!this.form.point_code) {
|
||||
this.crud.notify('请选择入库点', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
if (this.dis_row === null) {
|
||||
this.crud.notify('请先选择一条明细!', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
this.dis_row.point_code = this.form.point_code
|
||||
crudProductIn.setPoint(this.dis_row).then(res => {
|
||||
crudProductIn.getIosInvDtl({ 'iostorinv_id': this.dis_row.iostorinv_id }).then(res => {
|
||||
this.openParam = res
|
||||
this.form.tableMater = []
|
||||
this.dis_row = null
|
||||
this.crud.notify('操作成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
@@ -235,7 +235,7 @@ import DateRangePicker from '@/components/DateRangePicker/index'
|
||||
import AddDialog from '@/views/wms/storage_manage/product/productIn/AddDialog'
|
||||
import DivDialog from '@/views/wms/storage_manage/product/productIn/DivDialog'
|
||||
import ViewDialog from '@/views/wms/storage_manage/product/productIn/ViewDialog'
|
||||
import crudStorattr from '@/api/wms/basedata/st/storattr'
|
||||
import crudStorattr, {getStor} from '@/views/wms/storage_manage/basedata/basedata'
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
@@ -281,7 +281,7 @@ export default {
|
||||
}
|
||||
},
|
||||
created() {
|
||||
crudStorattr.queryStor().then(res => {
|
||||
crudStorattr.getStor({ 'stor_type': '4' }).then(res => {
|
||||
this.storlist = res.content
|
||||
})
|
||||
},
|
||||
@@ -341,7 +341,7 @@ export default {
|
||||
this.crud.notify('请选择一条单据', CRUD.NOTIFICATION_TYPE.INFO)
|
||||
return
|
||||
}
|
||||
crudProductIn.confirm(this.currentRow).then(res => {
|
||||
crudProductIn.confirm({ 'iostorinv_id': this.currentRow.iostorinv_id }).then(res => {
|
||||
this.crud.notify('单据确认成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.crud.toQuery()
|
||||
})
|
||||
|
||||
@@ -66,7 +66,31 @@ export function getSect(data) {
|
||||
|
||||
export function divStruct(data) {
|
||||
return request({
|
||||
url: '/api/stIvtSectattr/divStruct',
|
||||
url: '/api/productIn/divStruct',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function unDivStruct(data) {
|
||||
return request({
|
||||
url: '/api/productIn/unDivStruct',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function setPoint(data) {
|
||||
return request({
|
||||
url: '/api/productIn/setPoint',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function confirm(data) {
|
||||
return request({
|
||||
url: '/api/productIn/confirm',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
@@ -81,5 +105,8 @@ export default {
|
||||
vehicleCheck,
|
||||
confirmvehicle,
|
||||
getSect,
|
||||
divStruct
|
||||
divStruct,
|
||||
unDivStruct,
|
||||
setPoint,
|
||||
confirm
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user