修改
This commit is contained in:
93
mes/qd/src/views/wms/pcs/saleorder/Dialog.vue
Normal file
93
mes/qd/src/views/wms/pcs/saleorder/Dialog.vue
Normal file
@@ -0,0 +1,93 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
title="销售订单导入"
|
||||
append-to-body
|
||||
:visible.sync="dialogVisible"
|
||||
destroy-on-close
|
||||
:show-close="true"
|
||||
width="500px"
|
||||
v-loading.fullscreen.lock="fullscreenLoading"
|
||||
@close="close"
|
||||
>
|
||||
<div class="head-container">
|
||||
<div>
|
||||
<!-- 搜索 -->
|
||||
<el-form ref="form" :model="form1" :rules="rules" size="mini" label-width="110px">
|
||||
<el-form-item label="日期区间:" prop="createTime">
|
||||
<el-date-picker
|
||||
v-model="form.createTime"
|
||||
type="daterange"
|
||||
value-format="yyyy-MM-dd"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="销售订单号:" prop="bill_code">
|
||||
<el-input v-model="form.bill_code" style="width: 350px;"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-button class="filter-item" size="mini" type="success" icon="el-icon-search" @click="queryStruct">确认
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
import CRUD, {header, presenter} from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import pagination from '@crud/Pagination'
|
||||
import DateRangePicker from '@/components/DateRangePicker/index'
|
||||
import crudSap from '@/api/wms/ext/sap'
|
||||
|
||||
export default {
|
||||
name: 'importOrder',
|
||||
components: {rrOperation, pagination, DateRangePicker},
|
||||
cruds() {
|
||||
},
|
||||
mixins: [presenter(), header()],
|
||||
props: {
|
||||
dialogShow: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
fullscreenLoading: false,
|
||||
dialogVisible: false,
|
||||
form: {}
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
dialogShow: {
|
||||
handler(newValue, oldValue) {
|
||||
this.dialogVisible = newValue
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
close() {
|
||||
this.form = {}
|
||||
this.$emit('update:dialogShow', false)
|
||||
this.$emit('tableChanged', this.rows)
|
||||
},
|
||||
queryStruct() {
|
||||
debugger
|
||||
this.fullscreenLoading = true
|
||||
if (this.form.createTime) {
|
||||
this.form.date_begin = this.form.createTime[0]
|
||||
this.form.date_end = this.form.createTime[1]
|
||||
}
|
||||
crudSap.getSaleOrder(this.form).then(res => {
|
||||
this.crud.notify(res.message, CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
this.fullscreenLoading = false
|
||||
}).catch(() => {
|
||||
this.fullscreenLoading = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -62,14 +62,41 @@
|
||||
placeholder="请选择"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否正常">
|
||||
<el-select
|
||||
v-model="query.is_success"
|
||||
style="width: 200px"
|
||||
clearable
|
||||
filterable
|
||||
placeholder="请选择"
|
||||
@change="crud.toQuery"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.IS_OR_NOT"
|
||||
:key="item.id"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<rrOperation :crud="crud" />
|
||||
</el-form>
|
||||
</div>
|
||||
<!--如果想在工具栏加入更多按钮,可以使用插槽方式, slot = 'left' or 'right'-->
|
||||
<crudOperation :permission="permission" />
|
||||
<crudOperation :permission="permission">
|
||||
<el-button
|
||||
slot="right"
|
||||
class="filter-item"
|
||||
type="success"
|
||||
icon="el-icon-position"
|
||||
size="mini"
|
||||
@click="importin"
|
||||
>
|
||||
同步
|
||||
</el-button>
|
||||
</crudOperation>
|
||||
<!--表单组件-->
|
||||
<el-dialog :close-on-click-modal="false" :before-close="crud.cancelCU" :visible.sync="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 ref="form" :model="form" size="mini" label-width="80px">
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="text" @click="crud.cancelCU">取消</el-button>
|
||||
@@ -99,6 +126,7 @@
|
||||
<el-table-column prop="cust_name" label="客户名称" min-width="100" show-overflow-tooltip/>
|
||||
<el-table-column prop="unit_name" label="计量单位" show-overflow-tooltip min-width="150" />
|
||||
<el-table-column prop="plandeliver_date" label="计划交期" min-width="100" show-overflow-tooltip/>
|
||||
<el-table-column prop="remark" label="备注" show-overflow-tooltip min-width="200"/>
|
||||
<el-table-column prop="create_name" label="创建人" />
|
||||
<el-table-column prop="create_time" label="创建时间" min-width="120" show-overflow-tooltip/>
|
||||
<el-table-column prop="update_time" label="修改时间" min-width="120" show-overflow-tooltip/>
|
||||
@@ -114,6 +142,7 @@
|
||||
<!--分页组件-->
|
||||
<pagination />
|
||||
</div>
|
||||
<Dialog :dialog-show.sync="dialogShow" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -122,7 +151,7 @@ import crudSaleOrder from '@/api/wms/pcs/saleOrder'
|
||||
import CRUD, { presenter, header, form, crud } from '@crud/crud'
|
||||
import rrOperation from '@crud/RR.operation'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import udOperation from '@crud/UD.operation'
|
||||
import Dialog from '@/views/wms/pcs/saleorder/Dialog'
|
||||
import pagination from '@crud/Pagination'
|
||||
import Treeselect, {LOAD_CHILDREN_OPTIONS} from '@riophae/vue-treeselect'
|
||||
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
|
||||
@@ -131,8 +160,8 @@ import crudClassstandard from '@/api/wms/basedata/master/classstandard'
|
||||
const defaultForm = { sale_id: null, sale_code: null, seq_no: null, sale_type: null, material_id: null, status: null, sale_qty: null, produce_seq: null, cust_id: null, qty_unit_id: null, plandeliver_date: null, create_id: null, create_name: null, create_time: null, update_optid: null, update_optname: null, update_time: null, cust_code: null, cust_name: null }
|
||||
export default {
|
||||
name: 'SaleOrder',
|
||||
dicts: ['PCS_SALE_STATUS', 'PCS_SAL_TYPE'],
|
||||
components: { pagination, crudOperation, rrOperation, udOperation, Treeselect },
|
||||
dicts: ['PCS_SALE_STATUS', 'PCS_SAL_TYPE', 'IS_OR_NOT'],
|
||||
components: { pagination, crudOperation, rrOperation, Treeselect, Dialog },
|
||||
mixins: [presenter(), header(), form(defaultForm), crud()],
|
||||
cruds() {
|
||||
return CRUD({ title: '销售订单', url: 'api/saleOrder', idField: 'sale_id', sort: 'sale_id,desc',
|
||||
@@ -148,10 +177,9 @@ export default {
|
||||
data() {
|
||||
return {
|
||||
classes3: [],
|
||||
dialogShow: false,
|
||||
permission: {
|
||||
},
|
||||
rules: {
|
||||
},
|
||||
queryTypeOptions: [
|
||||
{ key: 'sale_code', display_name: '销售单号' }
|
||||
]
|
||||
@@ -174,6 +202,9 @@ export default {
|
||||
})
|
||||
})
|
||||
},
|
||||
importin() {
|
||||
this.dialogShow = true
|
||||
},
|
||||
buildTree(classes) {
|
||||
classes.forEach(data => {
|
||||
if (data.children) {
|
||||
|
||||
Reference in New Issue
Block a user