From 82b745015edf51c5765f6939f7c166b74ec00a26 Mon Sep 17 00:00:00 2001
From: liukangdong <898885815@qq.com>
Date: 星期四, 09 一月 2025 17:53:10 +0800
Subject: [PATCH] ll
---
admin/src/views/stock/check.vue | 135 ++++++
admin/src/views/stock/in.vue | 138 ++++++
admin/src/views/stock/components/CateEdit.vue | 74 +++
admin/src/views/stock/out.vue | 138 ++++++
admin/src/views/stock/assetList.vue | 140 ++++++
admin/package-lock.json | 160 +++---
admin/src/views/stock/assetCate.vue | 109 ++++
admin/src/views/stock/record.vue | 150 ++++++
admin/src/views/stock/asset.vue | 133 ++++++
admin/src/views/stock/query.vue | 132 ++++++
10 files changed, 1,230 insertions(+), 79 deletions(-)
diff --git a/admin/package-lock.json b/admin/package-lock.json
index 4adea74..6d328d1 100644
--- a/admin/package-lock.json
+++ b/admin/package-lock.json
@@ -2915,63 +2915,6 @@
"integrity": "sha1-/q7SVZc9LndVW4PbwIhRpsY1IPo=",
"dev": true
},
- "ansi-styles": {
- "version": "4.3.0",
- "resolved": "https://registry.npmmirror.com/ansi-styles/-/ansi-styles-4.3.0.tgz",
- "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
- "dev": true,
- "optional": true,
- "requires": {
- "color-convert": "^2.0.1"
- }
- },
- "chalk": {
- "version": "4.1.2",
- "resolved": "https://registry.npmmirror.com/chalk/-/chalk-4.1.2.tgz",
- "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
- "dev": true,
- "optional": true,
- "requires": {
- "ansi-styles": "^4.1.0",
- "supports-color": "^7.1.0"
- }
- },
- "color-convert": {
- "version": "2.0.1",
- "resolved": "https://registry.npmmirror.com/color-convert/-/color-convert-2.0.1.tgz",
- "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
- "dev": true,
- "optional": true,
- "requires": {
- "color-name": "~1.1.4"
- }
- },
- "color-name": {
- "version": "1.1.4",
- "resolved": "https://registry.npmmirror.com/color-name/-/color-name-1.1.4.tgz",
- "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
- "dev": true,
- "optional": true
- },
- "has-flag": {
- "version": "4.0.0",
- "resolved": "https://registry.npmmirror.com/has-flag/-/has-flag-4.0.0.tgz",
- "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
- "dev": true,
- "optional": true
- },
- "loader-utils": {
- "version": "2.0.4",
- "resolved": "https://registry.npmmirror.com/loader-utils/-/loader-utils-2.0.4.tgz",
- "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==",
- "dev": true,
- "optional": true,
- "requires": {
- "big.js": "^5.2.2",
- "emojis-list": "^3.0.0",
- "json5": "^2.1.2"
- }
- },
"ssri": {
"version": "8.0.1",
"resolved": "https://registry.npm.taobao.org/ssri/download/ssri-8.0.1.tgz?cache=0&sync_timestamp=1617826515595&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fssri%2Fdownload%2Fssri-8.0.1.tgz",
@@ -2979,28 +2922,6 @@
"dev": true,
"requires": {
"minipass": "^3.1.1"
- }
- },
- "supports-color": {
- "version": "7.2.0",
- "resolved": "https://registry.npmmirror.com/supports-color/-/supports-color-7.2.0.tgz",
- "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
- "dev": true,
- "optional": true,
- "requires": {
- "has-flag": "^4.0.0"
- }
- },
- "vue-loader-v16": {
- "version": "npm:vue-loader@16.8.3",
- "resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-16.8.3.tgz",
- "integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==",
- "dev": true,
- "optional": true,
- "requires": {
- "chalk": "^4.1.0",
- "hash-sum": "^2.0.0",
- "loader-utils": "^2.0.0"
}
}
}
@@ -15821,6 +15742,87 @@
}
}
},
+ "vue-loader-v16": {
+ "version": "npm:vue-loader@16.8.3",
+ "resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-16.8.3.tgz",
+ "integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==",
+ "dev": true,
+ "optional": true,
+ "requires": {
+ "chalk": "^4.1.0",
+ "hash-sum": "^2.0.0",
+ "loader-utils": "^2.0.0"
+ },
+ "dependencies": {
+ "ansi-styles": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
+ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "dev": true,
+ "optional": true,
+ "requires": {
+ "color-convert": "^2.0.1"
+ }
+ },
+ "chalk": {
+ "version": "4.1.2",
+ "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
+ "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
+ "dev": true,
+ "optional": true,
+ "requires": {
+ "ansi-styles": "^4.1.0",
+ "supports-color": "^7.1.0"
+ }
+ },
+ "color-convert": {
+ "version": "2.0.1",
+ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
+ "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "dev": true,
+ "optional": true,
+ "requires": {
+ "color-name": "~1.1.4"
+ }
+ },
+ "color-name": {
+ "version": "1.1.4",
+ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
+ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
+ "dev": true,
+ "optional": true
+ },
+ "has-flag": {
+ "version": "4.0.0",
+ "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
+ "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
+ "dev": true,
+ "optional": true
+ },
+ "loader-utils": {
+ "version": "2.0.4",
+ "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.4.tgz",
+ "integrity": "sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw==",
+ "dev": true,
+ "optional": true,
+ "requires": {
+ "big.js": "^5.2.2",
+ "emojis-list": "^3.0.0",
+ "json5": "^2.1.2"
+ }
+ },
+ "supports-color": {
+ "version": "7.2.0",
+ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
+ "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
+ "dev": true,
+ "optional": true,
+ "requires": {
+ "has-flag": "^4.0.0"
+ }
+ }
+ }
+ },
"vue-property-decorator": {
"version": "8.5.1",
"resolved": "https://registry.npmjs.org/vue-property-decorator/-/vue-property-decorator-8.5.1.tgz",
diff --git a/admin/src/views/stock/asset.vue b/admin/src/views/stock/asset.vue
new file mode 100644
index 0000000..61d0ab4
--- /dev/null
+++ b/admin/src/views/stock/asset.vue
@@ -0,0 +1,133 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">鏂板</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="浠撳簱鍚嶇О" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="璐熻矗浜�" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="浠撳簱浣嶇疆" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鎺掑簭鐮�" min-width="110" show-overflow-tooltip />
+ <el-table-column prop="param1" label="澶囨敞" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鐘舵��" min-width="90" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔" min-width="100" show-overflow-tooltip>
+ <template v-slot="{row}">
+ <span class="primaryColor pointer">鏌ョ湅璇︽儏</span>
+ <span class="red pointer">鍒犻櫎</span>
+ </template>
+ </el-table-column>
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '浠撳簱鍚嶇О',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '浠撳簱鐘舵��',
+ options: []
+ }
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style>
+
+</style>
diff --git a/admin/src/views/stock/assetCate.vue b/admin/src/views/stock/assetCate.vue
new file mode 100644
index 0000000..965a882
--- /dev/null
+++ b/admin/src/views/stock/assetCate.vue
@@ -0,0 +1,109 @@
+<template>
+ <TableLayout>
+ <template v-slot:table-wrap>
+ <ul class="toolbar" v-permissions="['business:category:create', 'business:category:delete']">
+ <li><el-button type="primary" @click="handleEdit()" icon="el-icon-plus"
+ v-permissions="['business:category:create']">鏂板缓</el-button></li>
+ <li v-permissions="['business:category:exportExcel']"><el-button type="primary"
+ @click="exportExcel">瀵煎嚭</el-button></li>
+ </ul>
+ <el-table row-key="id" :tree-props="{ children: 'childCategoryList' }" v-loading="isWorking.search"
+ :data="dataList" stripe @selection-change="handleSelectionChange">
+ <el-table-column prop="name" label="璁惧鍒嗙被" min-width="100px"></el-table-column>
+ <!-- <el-table-column prop="parentName" label="鎵�灞炲垎绫�" min-width="100px"></el-table-column> -->
+ <el-table-column prop="sortnum" label="鎺掑簭鐮�" min-width="100px"></el-table-column>
+ <el-table-column v-if="containPermissions(['business:category:update', 'business:category:delete'])" label="鎿嶄綔"
+ min-width="120" fixed="right">
+ <template slot-scope="{row}">
+ <el-button type="text" @click="handleEdit(row)" icon="el-icon-edit"
+ v-permissions="['business:category:update']">缂栬緫</el-button>
+ <el-button type="text" @click="deleteById(row)" icon="el-icon-delete"
+ v-permissions="['business:category:delete']">鍒犻櫎</el-button>
+ </template>
+ </el-table-column>
+ </el-table>
+ <pagination @size-change="handleSizeChange" @current-change="getList" :pagination="tableData.pagination">
+ </pagination>
+ </template>
+ <!-- 鏂板缓/淇敼 -->
+ <CateEdit v-if="isShowEdit" @close="isShowEdit = false" ref="CateEditRef" @success="getList" />
+ </TableLayout>
+</template>
+
+<script>
+import BaseTable from '@/components/base/BaseTable'
+import TableLayout from '@/layouts/TableLayout'
+import Pagination from '@/components/common/Pagination'
+import CateEdit from './components/CateEdit.vue'
+import { fetchList, deleteById } from '@/api/business/category.js'
+export default {
+ name: 'Category',
+ extends: BaseTable,
+ components: { TableLayout, Pagination, CateEdit },
+ data() {
+ return {
+ // 鎼滅储
+ filters: {
+ parentId: ''
+ },
+ isShowEdit: false,
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0,
+ },
+ dataList: []
+ }
+ },
+ created() {
+ this.config({
+ module: '杞﹁締淇℃伅琛�',
+ api: '/business/category',
+ 'field.id': 'id',
+ 'field.main': 'id'
+ })
+ this.getList()
+ },
+ methods: {
+ handleEdit(row) {
+ this.isShowEdit = true
+ let str = row && row.id ? '缂栬緫璁惧鍒嗙被' : '鏂板缓璁惧鍒嗙被'
+ this.$nextTick(() => {
+ this.$refs.CateEditRef.open(str)
+ this.$refs.CateEditRef.getList()
+ if (row && row.id) {
+ this.$refs.CateEditRef.getDetail(row.id)
+ }
+ })
+ },
+ deleteById(row) {
+ this.$confirm(`鎮ㄧ‘璁よ鍒犻櫎璇ュ垎绫诲悧`, '娓╅Θ鎻愮ず', {
+ confirmButtonText: '纭畾',
+ cancelButtonText: '鍙栨秷',
+ type: 'warning'
+ }).then(() => {
+ deleteById(row.id).then(res => {
+ this.getList()
+ })
+ })
+
+ },
+ getList() {
+ const { pagination, filters } = this
+ this.loading = true
+ fetchList({
+ model: { ...filters, type: 5 },
+ capacity: pagination.pageSize,
+ page: pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.dataList = res.records || []
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ }
+}
+</script>
diff --git a/admin/src/views/stock/assetList.vue b/admin/src/views/stock/assetList.vue
new file mode 100644
index 0000000..c5851ae
--- /dev/null
+++ b/admin/src/views/stock/assetList.vue
@@ -0,0 +1,140 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">鏂板</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="璧勪骇缂栫爜" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="璧勪骇鍚嶇О" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="鏉$爜" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鍝佺墝" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="param1" label="瑙勬牸鍨嬪彿" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鍗曚綅" min-width="70" show-overflow-tooltip />
+ <el-table-column prop="param2" label="瀹夊叏搴撳瓨(涓嬮檺)" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="param2" label="瀹夊叏搴撳瓨(涓婇檺)" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鐘舵��" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔" min-width="100" show-overflow-tooltip>
+ <template v-slot="{ row }">
+ <span class="primaryColor pointer">缂栬緫</span>
+ <span class="red pointer">鍒犻櫎</span>
+ </template>
+ </el-table-column>
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '璧勪骇淇℃伅',
+ placeholder: '璇疯緭鍏ヨ祫浜у悕绉�/缂栫爜'
+ },
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '瑙勬牸鍨嬪彿',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鎵�灞為」鐩�',
+ options: []
+ }
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style></style>
diff --git a/admin/src/views/stock/check.vue b/admin/src/views/stock/check.vue
new file mode 100644
index 0000000..86c05ec
--- /dev/null
+++ b/admin/src/views/stock/check.vue
@@ -0,0 +1,135 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">娣诲姞</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="鐩樼偣鍗曞悕绉�" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="鐩樼偣浠撳簱" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="鐩樼偣鍛�" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鐩樼偣鏃ユ湡" min-width="110" show-overflow-tooltip />
+ <el-table-column prop="param1" label="鍒涘缓浜�" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鍒涘缓鏃堕棿" min-width="140" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鐩樼偣鐘舵��" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔" min-width="140" show-overflow-tooltip>
+ <template v-slot="{row}">
+ <span class="primaryColor pointer">鏌ョ湅璇︽儏</span>
+ <span class="primaryColor pointer">鍙栨秷</span>
+ <span class="primaryColor pointer">鍒犻櫎</span>
+ </template>
+ </el-table-column>
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鐩樼偣鍗�',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鐩樼偣鐘舵��',
+ options: []
+ },
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style>
+
+</style>
diff --git a/admin/src/views/stock/components/CateEdit.vue b/admin/src/views/stock/components/CateEdit.vue
new file mode 100644
index 0000000..a066862
--- /dev/null
+++ b/admin/src/views/stock/components/CateEdit.vue
@@ -0,0 +1,74 @@
+<template>
+ <GlobalWindow :title="title" :visible.sync="visible" :confirm-working="isWorking" width="600px" @close="close" @confirm="confirm">
+ <el-form :model="form" ref="form" :rules="rules">
+ <el-form-item label="鍒嗙被鍚嶇О" prop="name">
+ <el-input v-model="form.name" placeholder="璇疯緭鍏ュ垎绫诲悕绉�" v-trim />
+ </el-form-item>
+ <el-form-item label="鎵�灞炲垎绫�" prop="parentId">
+ <el-select :disabled="form.id" v-model="form.parentId" placeholder="涓嶅~涓哄垯涓�绾у垎绫�">
+ <el-option v-for="op in dataList" :key="op.id" :label="op.name" :value="op.id"></el-option>
+ </el-select>
+ </el-form-item>
+ <el-form-item label="鎺掑簭鐮�(鍗囧簭)" prop="sortnum">
+ <el-input v-model="form.sortnum" oninput="value=value.replace(/^(0+)|[^\d]+/g, '').slice(0, 6)" v-trim />
+ </el-form-item>
+ </el-form>
+ </GlobalWindow>
+</template>
+
+<script>
+import BaseOpera from '@/components/base/BaseOpera'
+import GlobalWindow from '@/components/common/GlobalWindow'
+import { create, fetchCateList, getInfoById } from '@/api/business/category.js'
+export default {
+ name: 'OperaCategoryWindow',
+ extends: BaseOpera,
+ components: { GlobalWindow },
+ data() {
+ return {
+ // 琛ㄥ崟鏁版嵁
+ form: {
+ parentId: null,
+ name: '',
+ remark: '',
+ status: '',
+ sortnum: '',
+ type: 5
+ },
+ // 楠岃瘉瑙勫垯
+ rules: {
+ name: [
+ { required: true, message: '璇疯緭鍏ヤ簩绾у垎绫诲悕绉�', trigger: 'blur' }
+ ],
+ status: [
+ { required: true, message: '璇烽�夋嫨鏄惁鍚敤', trigger: 'change' }
+ ]
+ },
+ dataList: []
+ }
+ },
+ created() {
+ this.config({
+ api: '/business/category',
+ 'field.id': 'id'
+ })
+ },
+ methods: {
+ getList() {
+ fetchCateList({ type: 5 }).then(res => {
+ this.dataList = res || []
+
+ })
+ },
+ close() {
+ this.visible = false
+ this.$emit('close')
+ },
+ getDetail(id) {
+ getInfoById(id).then(res => {
+ this.form = res
+ })
+ },
+ }
+}
+</script>
diff --git a/admin/src/views/stock/in.vue b/admin/src/views/stock/in.vue
index e69de29..e71d95d 100644
--- a/admin/src/views/stock/in.vue
+++ b/admin/src/views/stock/in.vue
@@ -0,0 +1,138 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">瀵煎嚭</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="鍑哄簱鍗曞彿" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="鍑哄簱浠撳簱" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="鍑哄簱绫诲瀷" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鍑哄簱鏃ユ湡" min-width="110" show-overflow-tooltip />
+ <el-table-column prop="param1" label="鍑哄簱鏁伴噺" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鎿嶄綔浜�" min-width="90" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔鏃堕棿" min-width="140" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔" min-width="80" show-overflow-tooltip>
+ <template v-slot="{row}">
+ <span class="primaryColor pointer">鏌ョ湅璇︽儏</span>
+ </template>
+ </el-table-column>
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鍑哄簱鍗曞彿',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鎵�鍦ㄤ粨搴�',
+ options: []
+ },
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鍑哄簱绫诲瀷',
+ },
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style>
+
+</style>
diff --git a/admin/src/views/stock/out.vue b/admin/src/views/stock/out.vue
index e69de29..e71d95d 100644
--- a/admin/src/views/stock/out.vue
+++ b/admin/src/views/stock/out.vue
@@ -0,0 +1,138 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">瀵煎嚭</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="鍑哄簱鍗曞彿" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="鍑哄簱浠撳簱" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="鍑哄簱绫诲瀷" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鍑哄簱鏃ユ湡" min-width="110" show-overflow-tooltip />
+ <el-table-column prop="param1" label="鍑哄簱鏁伴噺" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鎿嶄綔浜�" min-width="90" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔鏃堕棿" min-width="140" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鎿嶄綔" min-width="80" show-overflow-tooltip>
+ <template v-slot="{row}">
+ <span class="primaryColor pointer">鏌ョ湅璇︽儏</span>
+ </template>
+ </el-table-column>
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鍑哄簱鍗曞彿',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鎵�鍦ㄤ粨搴�',
+ options: []
+ },
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鍑哄簱绫诲瀷',
+ },
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style>
+
+</style>
diff --git a/admin/src/views/stock/query.vue b/admin/src/views/stock/query.vue
index e69de29..7c318d2 100644
--- a/admin/src/views/stock/query.vue
+++ b/admin/src/views/stock/query.vue
@@ -0,0 +1,132 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">瀵煎嚭</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="璧勪骇缂栫爜" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="璧勪骇鍚嶇О" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="鏉$爜" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鍝佺墝" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="param1" label="瑙勬牸鍨嬪彿" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="param2" label="鎵�鍦ㄤ粨搴�" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="搴撳瓨" min-width="80" show-overflow-tooltip />
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鎵�鍦ㄤ粨搴�',
+ options: []
+ },
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '璧勪骇淇℃伅',
+ placeholder: '璇疯緭鍏ヨ祫浜у悕绉�/缂栫爜'
+ },
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鍨嬪彿',
+ },
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style></style>
diff --git a/admin/src/views/stock/record.vue b/admin/src/views/stock/record.vue
index e69de29..7f1764b 100644
--- a/admin/src/views/stock/record.vue
+++ b/admin/src/views/stock/record.vue
@@ -0,0 +1,150 @@
+<template>
+ <div class="main_app">
+ <QueryForm v-model="filters" :query-form-config="queryFormConfig" @handleQuery="getList(1)" @clear="clear" />
+ <div class="mt20">
+ <el-button type="primary" @click="handleEx()" v-permissions="['business:ywpatrolline:create']">瀵煎嚭</el-button>
+ </div>
+ <el-table v-loading="loading" :data="list" stripe>
+ <el-table-column prop="platformName" label="鍗曟嵁鏃ユ湡" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="platformName" label="璧勪骇缂栫爜" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="platformGroupName" label="璧勪骇鍚嶇О" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeFront" label="璧勪骇鍒嗙被" min-width="100" show-overflow-tooltip />
+ <el-table-column prop="carCodeBack" label="鏁伴噺" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="param1" label="绫诲瀷" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="浠撳簱" min-width="90" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鍗曟嵁缂栧彿" min-width="120" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鍒涘缓浜�" min-width="80" show-overflow-tooltip />
+ <el-table-column prop="workTime" label="鍒涘缓鏃堕棿" min-width="140" show-overflow-tooltip />
+ </el-table>
+ <div class="mt20">
+ <Pagination @size-change="handleSizeChange" @current-change="getList" :pagination="pagination" />
+ </div>
+ </div>
+</template>
+
+<script>
+import Pagination from '@/components/common/Pagination'
+import QueryForm from '@/components/common/QueryForm'
+import dayjs from 'dayjs'
+import duration from 'dayjs/plugin/duration'
+dayjs.extend(duration)
+import { platformLogPage, getPlatformGroupList } from '@/api'
+export default {
+ components: {
+ Pagination,
+ QueryForm
+ },
+ data() {
+ return {
+ loading: false,
+ pagination: {
+ pageSize: 10,
+ page: 1,
+ total: 0
+ },
+ filters: {},
+ list: [],
+ total: 0,
+ queryFormConfig: {
+ formItems: [
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '璧勪骇缂栫爜',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鎵�鍦ㄤ粨搴�',
+ options: []
+ },
+ {
+ filed: 'carCodeFront',
+ type: 'input',
+ label: '鍗曟嵁缂栧彿',
+ },
+ {
+ filed: 'platformGroupId',
+ type: 'select',
+ label: '鍗曟嵁绫诲瀷',
+ options: []
+ },
+ {
+ filed: 'selDate',
+ type: 'daterange',
+ label: '鍗曟嵁鏃ユ湡',
+ },
+ {
+ filed: 'selTime',
+ type: 'daterange',
+ label: '鍒涘缓鏃堕棿',
+ },
+ ],
+ online: true
+ }
+ }
+ },
+ created() {
+ // this.getList()
+ // this.getGroupList()
+ },
+ methods: {
+ handleSub() {
+ this.$refs.ruleForm.validate((valid) => {
+ if (valid) {
+ alert('submit!')
+ }
+ })
+ },
+ handleEx() { },
+ getGroupList() {
+ getPlatformGroupList({ queryData: 0, queryType: 0 }).then(res => {
+ this.queryFormConfig.formItems[1].options = res.map(i => {
+ return {
+ value: i.id,
+ label: i.name
+ }
+ })
+ // this.queryFormConfig.formItems[1].options.unshift({ value: '', label: '鍏ㄩ儴鏈堝彴缁�' })
+ })
+ },
+ getList(page) {
+ const { pagination, filters } = this
+ this.loading = true
+ platformLogPage({
+ model: {
+ ...filters,
+ queryStatus: '6,7,8',
+ beginWorkDateStart: filters.selDate && filters.selDate.length > 0 ? filters.selDate[0] : null,
+ beginWorkDateEnd: filters.selDate && filters.selDate.length > 0 ? filters.selDate[1] : null,
+ },
+ sorts: [{ direction: 'DESC', property: 'param1' }],
+ capacity: pagination.pageSize,
+ page: page || pagination.page,
+ }).then(res => {
+ this.loading = false
+ this.list = res.records || []
+ this.list.forEach(item => {
+ item.inTypeTemp = item.inType == 0 ? '鏁存墭鐩�' : '浠剁儫'
+ item.taskOrigin = 'WMS鑾峰彇'
+ item.workTime = dayjs.duration(item.param3, 'seconds').format('H鏃秏鍒唖绉�')
+ })
+ this.pagination.total = res.total || 0
+ }, () => {
+ this.loading = false
+ })
+ },
+ clear() {
+ this.filters = {}
+ this.pagination.pageSize = 10
+ this.pagination.page = 1
+ this.getList()
+ },
+ handleSizeChange(capacity) {
+ this.pagination.pageSize = capacity
+ }
+ }
+}
+</script>
+
+<style></style>
--
Gitblit v1.9.3