|
@@ -1,16 +1,13 @@
|
|
|
<template>
|
|
|
- <div>
|
|
|
+ <div >
|
|
|
+
|
|
|
<transition appear enter-active-class="animated fadeIn">
|
|
|
<q-table class="my-sticky-header-column-table shadow-24" :data="table_list" row-key="id" :separator="separator"
|
|
|
:loading="loading" :columns="columns" hide-bottom :pagination.sync="pagination" no-data-label="No data"
|
|
|
no-results-label="No data you want" :table-style="{ height: height }" flat bordered>
|
|
|
<template v-slot:top>
|
|
|
<q-btn-group push>
|
|
|
-<!--
|
|
|
- <q-btn :label="$t('new')" icon="add" @click="newForm = true; newFormData.creater = login_name">
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
- content-style="font-size: 12px">{{ $t('newtip') }}</q-tooltip>
|
|
|
- </q-btn> -->
|
|
|
+
|
|
|
<q-btn :label="$t('refresh')" icon="refresh" @click="reFresh()">
|
|
|
<q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
content-style="font-size: 12px">{{ $t('refreshtip') }}</q-tooltip>
|
|
@@ -21,7 +18,25 @@
|
|
|
<q-space />
|
|
|
|
|
|
<div class="flex items-center">
|
|
|
-
|
|
|
+ <div class="q-mr-md">{{ $t("download_center.createTime") }}</div>
|
|
|
+ <q-input readonly outlined dense v-model="createDate2" :placeholder="interval">
|
|
|
+ <template v-slot:append>
|
|
|
+ <q-icon name="event" class="cursor-pointer">
|
|
|
+ <q-popup-proxy ref="qDateProxy" transition-show="scale" transition-hide="scale">
|
|
|
+ <q-date v-model="createDate1" range>
|
|
|
+ <div class="row items-center justify-end q-gutter-sm">
|
|
|
+ <q-btn :label="$t('index.cancel')" color="primary" flat v-close-popup />
|
|
|
+ <q-btn :label="$t('index.clear')" color="primary" @click="createDate2 = ''; createDate1 = '';"
|
|
|
+ v-close-popup />
|
|
|
+
|
|
|
+ </div>
|
|
|
+ </q-date>
|
|
|
+ </q-popup-proxy>
|
|
|
+ </q-icon>
|
|
|
+ </template>
|
|
|
+ </q-input>
|
|
|
+ <q-btn-group push class="q-ml-md">
|
|
|
+ </q-btn-group>
|
|
|
<q-input outlined rounded dense debounce="300" color="primary" v-model="filter" :placeholder="$t('search')"
|
|
|
@input="getSearchList()" @keyup.enter="getSearchList()">
|
|
|
<template v-slot:append>
|
|
@@ -32,139 +47,71 @@
|
|
|
</template>
|
|
|
<template v-slot:body="props">
|
|
|
<q-tr :props="props">
|
|
|
-
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="asn_code" :props="props">{{ props.row.asn_code }}</q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="asn_code" :props="props">{{ props.row.asn_code }}</q-td>
|
|
|
- </template>
|
|
|
-
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="goods_code" :props="props">
|
|
|
- <q-input dense outlined square v-model="editFormData.goods_code" :label="'存货编码'"
|
|
|
- :rules="[val => (val && val.length > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="goods_code" :props="props">{{ props.row.goods_code }}</q-td>
|
|
|
- </template>
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="goods_desc" :props="props">
|
|
|
- <q-input dense outlined square v-model="editFormData.goods_desc" :label="'存货名称'"
|
|
|
- :rules="[val => (val && val.length > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="goods_desc" :props="props">{{ props.row.goods_desc }}</q-td>
|
|
|
- </template>
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="goods_qty" :props="props">
|
|
|
- <q-input dense outlined square v-model.number="editFormData.goods_qty" :label="'入库数量'" type="number"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="goods_qty" :props="props">{{ props.row.goods_qty }}</q-td>
|
|
|
+ <template >
|
|
|
+ <q-td key="document_date" :props="props">{{ props.row.batch_detail.bound_list.bound_date }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="document_number" :props="props">{{ props.row.batch_detail.bound_list.bound_code }}</q-td>
|
|
|
</template>
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="goods_weight" :props="props">
|
|
|
- <q-input dense outlined square v-model.number="editFormData.goods_weight" :label="'入库重量'" type="number"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="goods_weight" :props="props">{{ props.row.goods_weight }}</q-td>
|
|
|
- </template>
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="warehouse_name" :props="props">
|
|
|
- <q-input dense outlined square v-model.number="editFormData.warehouse_name" :label="'仓库'"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="warehouse_name" :props="props">{{ props.row.warehouse_name }}</q-td>
|
|
|
- </template>
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="shelf_name" :props="props">
|
|
|
- <q-input dense outlined square v-model.number="editFormData.shelf_name" :label="'货架'"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="shelf_name" :props="props">{{ props.row.shelf_name }}</q-td>
|
|
|
- </template>
|
|
|
-
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="container_code" :props="props">
|
|
|
- <q-input dense outlined square v-model.number="editFormData.container_code" :label="'托盘编码'"
|
|
|
- :rules="[val => (val && val.length > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="container_code" :props="props">{{ props.row.container_code }}</q-td>
|
|
|
+ <template >
|
|
|
+ <q-td key="document_type" :props="props">{{ props.row.batch_detail.bound_list.bound_code_type }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="business_type" :props="props">{{ props.row.batch_detail.bound_list.bound_bs_type }}</q-td>
|
|
|
</template>
|
|
|
+ <template >
|
|
|
+ <q-td key="iout_type" :props="props">{{ props.row.batch_detail.bound_list.bound_type }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="department" :props="props">{{ props.row.batch_detail.bound_list.bound_department }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="warehouse_code" :props="props">{{ props.row.batch_detail.bound_batch.warehouse_code }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="warehouse_name" :props="props">{{ props.row.batch_detail.bound_batch.warehouse_name }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_code" :props="props">{{ props.row.batch_detail.bound_batch.goods_code }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_desc" :props="props">{{ props.row.batch_detail.bound_batch.goods_desc }}</q-td>
|
|
|
+ </template>
|
|
|
+
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_std" :props="props">{{ props.row.batch_detail.bound_batch.goods_std }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_batch" :props="props">{{ props.row.container_detail.batch.bound_number }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="in_batch" :props="props">{{ props.row.container_detail.batch.goods_code}}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="out_batch" :props="props">{{ props.row.batch_detail.bound_batch.out_batch }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_unit" :props="props">{{ props.row.batch_detail.bound_batch.goods_unit }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_in" :props="props">{{ props.row.container_detail.goods_qty }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="container_number" :props="props">{{ props.row.container_detail.container.container_code }}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="goods_notes" :props="props">{{ props.row.task_wcs.message}}</q-td>
|
|
|
+ </template>
|
|
|
+ <template >
|
|
|
+ <q-td key="creator" :props="props">{{ props.row.container_detail.creater}}</q-td>
|
|
|
+ </template>
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="creater" :props="props">
|
|
|
- <q-input dense outlined square v-model.number="editFormData.creater" :label="'经办人'"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="creater" :props="props">{{ props.row.creater }}</q-td>
|
|
|
- </template>
|
|
|
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="asn_status" :props="props">
|
|
|
- <q-td key="asn_status" :props="props">{{ props.row.asn_status }}</q-td>
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid">
|
|
|
- <q-td key="asn_status" :props="props">{{ props.row.asn_status }}</q-td>
|
|
|
- </template>
|
|
|
|
|
|
|
|
|
- <template v-if="!editMode">
|
|
|
- <q-td key="action" :props="props" style="width: 100px">
|
|
|
- <q-btn round flat push color="purple" icon="edit" @click="editData(props.row)">
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
- content-style="font-size: 12px">{{ $t('edit') }}</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- <q-btn round flat push color="dark" icon="trolley" @click="change_status(props.row)">
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
- content-style="font-size: 12px">一键分拣</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- <q-btn round flat push color="dark" icon="delete" @click="deleteData(props.row.id)">
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
- content-style="font-size: 12px">{{ $t('delete') }}</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="editMode">
|
|
|
- <template v-if="props.row.id === editid">
|
|
|
- <q-td key="action" :props="props" style="width: 100px">
|
|
|
- <q-btn round flat push color="secondary" icon="check" @click="editDataSubmit()">
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
- content-style="font-size: 12px">{{ $t('confirmedit') }}</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- <q-btn round flat push color="red" icon="close" @click="editDataCancel()">
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4" :offset="[10, 10]"
|
|
|
- content-style="font-size: 12px">{{ $t('canceledit') }}</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- </q-td>
|
|
|
- </template>
|
|
|
- <template v-else-if="props.row.id !== editid"></template>
|
|
|
- </template>
|
|
|
</q-tr>
|
|
|
</template>
|
|
|
</q-table>
|
|
@@ -183,57 +130,6 @@
|
|
|
<q-btn flat push color="dark" :label="$t('no_data')"></q-btn>
|
|
|
</div>
|
|
|
</template>
|
|
|
- <q-dialog v-model="newForm">
|
|
|
- <q-card class="shadow-24">
|
|
|
- <q-bar class="bg-light-blue-10 text-white rounded-borders" style="height: 50px">
|
|
|
- <div>{{ $t('newtip') }}</div>
|
|
|
- <q-space />
|
|
|
- <q-btn dense flat icon="close" v-close-popup>
|
|
|
- <q-tooltip content-class="bg-amber text-black shadow-4">{{ $t('index.close') }}</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- </q-bar>
|
|
|
- <q-card-section style="max-height: 325px; width: 400px" class="scroll">
|
|
|
- <q-input dense outlined square v-model="newFormData.code" :label="'到货编码'" autofocus
|
|
|
- :rules="[val => (val && val.length > 0) || error1]" />
|
|
|
-
|
|
|
- <q-input dense outlined square v-model="newFormData.goods_code" :label="'存货编码'"
|
|
|
- :rules="[val => (val && val.length > 0) || error8]" />
|
|
|
- <q-input dense outlined square v-model="newFormData.goods_desc" :label="'存货名称'"
|
|
|
- :rules="[val => (val && val.length > 0) || error8]" />
|
|
|
- <q-input dense outlined square v-model.number="newFormData.goods_qty" :label="'入库数量'" type="number"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
- <q-input dense outlined square v-model.number="newFormData.goods_weight" :label="'入库重量'" type="number"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
-
|
|
|
- <q-input dense outlined square v-model.number="newFormData.creater" :label="'经办人'"
|
|
|
- :rules="[val => (val && val > 0) || error8]" />
|
|
|
-
|
|
|
- </q-card-section>
|
|
|
-
|
|
|
- <div style="float: right; padding: 15px 15px 15px 0">
|
|
|
- <q-btn color="white" text-color="black" style="margin-right: 25px" @click="newDataCancel()">{{ $t('cancel')
|
|
|
- }}</q-btn>
|
|
|
- <q-btn color="primary" @click="newDataSubmit()">{{ $t('submit') }}</q-btn>
|
|
|
- </div>
|
|
|
- </q-card>
|
|
|
- </q-dialog>
|
|
|
- <q-dialog v-model="deleteForm">
|
|
|
- <q-card class="shadow-24">
|
|
|
- <q-bar class="bg-light-blue-10 text-white rounded-borders" style="height: 50px">
|
|
|
- <div>{{ $t('delete') }}</div>
|
|
|
- <q-space />
|
|
|
- <q-btn dense flat icon="close" v-close-popup>
|
|
|
- <q-tooltip>{{ $t('index.close') }}</q-tooltip>
|
|
|
- </q-btn>
|
|
|
- </q-bar>
|
|
|
- <q-card-section style="max-height: 325px; width: 400px" class="scroll">{{ $t('deletetip') }}</q-card-section>
|
|
|
- <div style="float: right; padding: 15px 15px 15px 0">
|
|
|
- <q-btn color="white" text-color="black" style="margin-right: 25px" @click="deleteDataCancel()">{{ $t('cancel')
|
|
|
- }}</q-btn>
|
|
|
- <q-btn color="primary" @click="deleteDataSubmit()">{{ $t('submit') }}</q-btn>
|
|
|
- </div>
|
|
|
- </q-card>
|
|
|
- </q-dialog>
|
|
|
|
|
|
</div>
|
|
|
</template>
|
|
@@ -245,7 +141,7 @@ import { date, exportFile, LocalStorage } from 'quasar'
|
|
|
|
|
|
|
|
|
export default {
|
|
|
- name: 'Pagesorted',
|
|
|
+ name: 'PageTask',
|
|
|
data() {
|
|
|
return {
|
|
|
createDate1: '',
|
|
@@ -259,58 +155,45 @@ export default {
|
|
|
login_name: '',
|
|
|
authin: '0',
|
|
|
searchUrl: '',
|
|
|
- pathname: 'asn/detail/',
|
|
|
- pathfilename: 'asn/file/',
|
|
|
+ pathname: 'container/task/',
|
|
|
|
|
|
pathname_previous: '',
|
|
|
pathname_next: '',
|
|
|
separator: 'cell',
|
|
|
loading: false,
|
|
|
height: '',
|
|
|
+ viewForm: false,
|
|
|
|
|
|
- printObj: {
|
|
|
- id: 'printMe',
|
|
|
- popTitle: this.$t('inbound.asn')
|
|
|
- },
|
|
|
table_list: [],
|
|
|
-
|
|
|
columns: [
|
|
|
- { name: 'asn_code', label: '入库单号', field: 'asn_code', align: 'center' },
|
|
|
- { name: 'goods_code', label: '存货编码', field: 'goods_code', align: 'center' },
|
|
|
- { name: 'goods_desc', label: '存货', field: 'goods_desc', align: 'center' },
|
|
|
- { name: 'goods_qty', label: '数量', field: 'goods_qty', align: 'center' },
|
|
|
- { name: 'goods_weight', label: '重量', field: 'goods_weight', align: 'center' },
|
|
|
- { name: 'warehouse_name', label: '仓库', field: 'warehouse_name', align: 'center' },
|
|
|
- { name: 'shelf_name', label: '货架', field: 'shelf_name', align: 'center' },
|
|
|
- { name: 'container_code', label: '托盘编码', field: 'container_code', align: 'center' },
|
|
|
-
|
|
|
- { name: 'creater', label: '经办人', field: 'creater', align: 'center' },
|
|
|
- { name: 'asn_status', label: '状态', field: 'asn_status', align: 'center' },
|
|
|
- { name: 'action', label: '操作', align: 'center' }
|
|
|
- ],
|
|
|
+ { name: 'document_date', required: true, label: '入库时间', align: 'center', field: 'document_date' },
|
|
|
+ { name: 'document_number', label: '单据编号', field: 'document_number', align: 'center' },
|
|
|
+ { name: 'department', label: '部门', field: 'department', align: 'center' },
|
|
|
+
|
|
|
+ { name: 'goods_code', label: '存货编码', field: 'goods_code', align: 'center' },
|
|
|
+ { name: 'goods_desc', label: '存货', field: 'goods_desc', align: 'center' },
|
|
|
+ { name: 'goods_std', label: '规格型号', field: 'goods_std', align: 'center' },
|
|
|
+ { name: 'goods_batch', label: '入库批号', field: 'goods_batch', align: 'center' },
|
|
|
+
|
|
|
+
|
|
|
+ { name: 'goods_in', label: '入库数目', field: 'goods_in', align: 'center' },
|
|
|
+ { name: 'container_number', label: '托盘编码', field: 'container_number', align: 'center' },
|
|
|
+
|
|
|
+ // { name: 'goods_notes', label: '备注', field: 'goods_notes', align: 'center' },
|
|
|
+ { name: 'creator', label: '创建人', field: 'creator', align: 'center' },
|
|
|
+
|
|
|
+ ],
|
|
|
filter: '',
|
|
|
pagination: {
|
|
|
page: 1,
|
|
|
rowsPerPage: 11
|
|
|
},
|
|
|
- newForm: false,
|
|
|
- newFormData: {
|
|
|
-
|
|
|
- },
|
|
|
- editid: 0,
|
|
|
- editFormData: {
|
|
|
-
|
|
|
- },
|
|
|
- editMode: false,
|
|
|
- deleteForm: false,
|
|
|
- deleteid: 0,
|
|
|
- bar_code: '',
|
|
|
- error1: this.$t('goods.view_goodslist.error1'),
|
|
|
-
|
|
|
+ current: 1,
|
|
|
max: 0,
|
|
|
total: 0,
|
|
|
paginationIpt: 1,
|
|
|
current: 1,
|
|
|
+
|
|
|
}
|
|
|
|
|
|
},
|
|
@@ -345,7 +228,6 @@ export default {
|
|
|
getauth(`${_this.pathname}?${queryParams}`)
|
|
|
.then(res => {
|
|
|
_this.table_list = res.results
|
|
|
-
|
|
|
_this.total = res.count
|
|
|
_this.max = Math.ceil(res.count / _this.pagination.rowsPerPage) || 0
|
|
|
_this.pathname_previous = res.previous
|
|
@@ -380,56 +262,10 @@ export default {
|
|
|
this.current = page
|
|
|
this.paginationIpt = page
|
|
|
this.getList({
|
|
|
- goods_desc__icontains: this.filter,
|
|
|
- document_date__range: this.date_range
|
|
|
+ container_detail__goods_desc__icontains: this.filter,
|
|
|
+ create_time__range: this.date_range
|
|
|
})
|
|
|
},
|
|
|
- downloadlistData() {
|
|
|
- this.getfileList()
|
|
|
-
|
|
|
- },
|
|
|
- getfileList() {
|
|
|
- var _this = this
|
|
|
- _this.loading = true
|
|
|
- const params = {
|
|
|
- goods_desc__icontains: _this.filter,
|
|
|
- document_date__range: _this.date_range
|
|
|
- }
|
|
|
- const queryParams = new URLSearchParams({
|
|
|
- ...params
|
|
|
- })
|
|
|
- console.log(queryParams)
|
|
|
- // 过滤空值参数
|
|
|
- Array.from(queryParams.entries()).forEach(([key, value]) => {
|
|
|
- if (value === '' || value === null || value === undefined) {
|
|
|
- queryParams.delete(key)
|
|
|
- }
|
|
|
- })
|
|
|
- console.log(`${_this.pathfilename}?${queryParams}`)
|
|
|
- getauth(`${_this.pathfilename}?${queryParams}`)
|
|
|
- .then(res => {
|
|
|
- var timeStamp = Date.now()
|
|
|
- var formattedString = date.formatDate(timeStamp, 'YYYYMMDDHHmmss')
|
|
|
- const status = exportFile(_this.pathfilename + 'list' + formattedString + '.csv', '\uFEFF' + res, 'text/csv')
|
|
|
- if (status !== true) {
|
|
|
- _this.$q.notify({
|
|
|
- message: 'Browser denied file download...',
|
|
|
- color: 'negative',
|
|
|
- icon: 'warning'
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
- .catch(err => {
|
|
|
- _this.$q.notify({
|
|
|
- message: err.detail,
|
|
|
- icon: 'close',
|
|
|
- color: 'negative'
|
|
|
- })
|
|
|
- })
|
|
|
- .finally(() => {
|
|
|
- _this.loading = false
|
|
|
- })
|
|
|
- },
|
|
|
|
|
|
getListPrevious() {
|
|
|
var _this = this
|
|
@@ -474,163 +310,6 @@ export default {
|
|
|
_this.getSearchList()
|
|
|
},
|
|
|
|
|
|
- newDataSubmit() {
|
|
|
- var _this = this
|
|
|
- _this.newFormData.asn_type = 'INT';
|
|
|
- _this.newFormData.asn_status = '待分拣'
|
|
|
-
|
|
|
- postauth(_this.pathname, _this.newFormData)
|
|
|
- .then(res => {
|
|
|
- _this.getSearchList()
|
|
|
- _this.newDataCancel()
|
|
|
- if (res.status_code != 500) {
|
|
|
- _this.$q.notify({
|
|
|
- message: '成功新增数据',
|
|
|
- icon: 'check',
|
|
|
- color: 'green'
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
- .catch(err => {
|
|
|
- _this.$q.notify({
|
|
|
- message: err.detail,
|
|
|
- icon: 'close',
|
|
|
- color: 'negative'
|
|
|
- })
|
|
|
- })
|
|
|
- },
|
|
|
- newDataCancel() {
|
|
|
- var _this = this
|
|
|
- _this.newForm = false
|
|
|
- _this.newFormData = {
|
|
|
- code: '',
|
|
|
- goods_code: '',
|
|
|
- goods_desc: '',
|
|
|
- goods_qty: '',
|
|
|
- goods_weight: '',
|
|
|
- creater: ''
|
|
|
- }
|
|
|
- },
|
|
|
- editData(e) {
|
|
|
- var _this = this
|
|
|
- _this.editMode = true
|
|
|
- _this.editid = e.id
|
|
|
- _this.editFormData = {
|
|
|
- code: e.code,
|
|
|
- asn_code: e.asn_code,
|
|
|
- asn_status: e.asn_status,
|
|
|
- goods_code: e.goods_code,
|
|
|
- goods_desc: e.goods_desc,
|
|
|
- goods_qty: e.goods_qty,
|
|
|
- goods_weight: e.goods_weight,
|
|
|
- creater: _this.login_name,
|
|
|
- }
|
|
|
-
|
|
|
- },
|
|
|
- change_status(e) {
|
|
|
- var _this = this
|
|
|
-
|
|
|
- var status_FormData = {
|
|
|
- code: e.code,
|
|
|
- asn_code: e.asn_code,
|
|
|
- asn_status: e.asn_status,
|
|
|
- goods_code: e.goods_code,
|
|
|
- goods_desc: e.goods_desc,
|
|
|
- goods_qty: e.goods_qty,
|
|
|
- goods_weight: e.goods_weight,
|
|
|
- creater: _this.login_name,
|
|
|
- }
|
|
|
- status_FormData.asn_type = 'INT';
|
|
|
- status_FormData.asn_status = '入库中'
|
|
|
- putauth(_this.pathname + e.id + '/', status_FormData)
|
|
|
- .then(res => {
|
|
|
- _this.editDataCancel()
|
|
|
- _this.getSearchList()
|
|
|
- if (res.status_code != 500) {
|
|
|
- _this.$q.notify({
|
|
|
- message: '开始入库',
|
|
|
- icon: 'check',
|
|
|
- color: 'green'
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
- .catch(err => {
|
|
|
- _this.$q.notify({
|
|
|
- message: err.detail,
|
|
|
- icon: 'close',
|
|
|
- color: 'negative'
|
|
|
- })
|
|
|
- })
|
|
|
- },
|
|
|
- editDataSubmit() {
|
|
|
- var _this = this
|
|
|
- _this.editFormData.asn_type = 'INT'
|
|
|
-
|
|
|
- putauth(_this.pathname + _this.editid + '/', _this.editFormData)
|
|
|
- .then(res => {
|
|
|
- _this.editDataCancel()
|
|
|
- _this.getSearchList()
|
|
|
- if (res.status_code != 500) {
|
|
|
- _this.$q.notify({
|
|
|
- message: '成功编辑数据',
|
|
|
- icon: 'check',
|
|
|
- color: 'green'
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
- .catch(err => {
|
|
|
- _this.$q.notify({
|
|
|
- message: err.detail,
|
|
|
- icon: 'close',
|
|
|
- color: 'negative'
|
|
|
- })
|
|
|
- })
|
|
|
- },
|
|
|
- editDataCancel() {
|
|
|
- var _this = this
|
|
|
- _this.editMode = false
|
|
|
- _this.editid = 0
|
|
|
- _this.editFormData = {
|
|
|
- code: '',
|
|
|
- asn_code: '',
|
|
|
- asn_status: '',
|
|
|
- goods_code: '',
|
|
|
- goods_desc: '',
|
|
|
- goods_qty: '',
|
|
|
- goods_weight: '',
|
|
|
- creater: ''
|
|
|
- }
|
|
|
- },
|
|
|
- deleteData(e) {
|
|
|
- var _this = this
|
|
|
- _this.deleteForm = true
|
|
|
- _this.deleteid = e
|
|
|
- },
|
|
|
- deleteDataSubmit() {
|
|
|
- var _this = this
|
|
|
- deleteauth(_this.pathname + _this.deleteid + '/')
|
|
|
- .then(res => {
|
|
|
- _this.deleteDataCancel()
|
|
|
- _this.getSearchList()
|
|
|
- _this.$q.notify({
|
|
|
- message: '成功删除数据',
|
|
|
- icon: 'check',
|
|
|
- color: 'green'
|
|
|
- })
|
|
|
- })
|
|
|
- .catch(err => {
|
|
|
- _this.$q.notify({
|
|
|
- message: err.detail,
|
|
|
- icon: 'close',
|
|
|
- color: 'negative'
|
|
|
- })
|
|
|
- })
|
|
|
- },
|
|
|
- deleteDataCancel() {
|
|
|
- var _this = this
|
|
|
- _this.deleteForm = false
|
|
|
- _this.deleteid = 0
|
|
|
- },
|
|
|
|
|
|
updateProxy() {
|
|
|
var _this = this
|
|
@@ -670,11 +349,10 @@ export default {
|
|
|
} else {
|
|
|
_this.height = _this.$q.screen.height - 290 + '' + 'px'
|
|
|
}
|
|
|
- _this.newFormData.creater = _this.login_name
|
|
|
},
|
|
|
updated() { },
|
|
|
destroyed() { },
|
|
|
-
|
|
|
+ // 在 watch 或方法中添加调试代码
|
|
|
watch: {
|
|
|
createDate1(val) {
|
|
|
if (val) {
|