rev: 代码错乱修改
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
|
||||
})
|
||||
}
|
||||
|
||||
@@ -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