|
@@ -1,8 +1,8 @@
|
|
|
import Mock from 'mockjs'
|
|
|
// import TagApplyState from '@@/entries/TagApplyState'
|
|
|
-import TagType from '@@/entries/TagType'
|
|
|
-import TagPurchaseState from '@@/entries/TagPurchaseState'
|
|
|
-import Provider from '@@/entries/Provider'
|
|
|
+// import TagType from '@@/entries/TagType'
|
|
|
+// import TagPurchaseState from '@@/entries/TagPurchaseState'
|
|
|
+// import Provider from '@@/entries/Provider'
|
|
|
import Constant from '@/utils/Constant'
|
|
|
|
|
|
const API_BASE_PATH = Constant.REQUEST_PREFIX
|
|
@@ -38,95 +38,95 @@ const API_BASE_PATH = Constant.REQUEST_PREFIX
|
|
|
// }
|
|
|
// })
|
|
|
|
|
|
-Mock.mock(`${API_BASE_PATH}/provider/list`, 'post', {
|
|
|
- type: 'success',
|
|
|
- data: [
|
|
|
- new Provider(1, '人民电器集团有限公司'),
|
|
|
- new Provider(2, '上海东生供用电器材厂'),
|
|
|
- new Provider(3, '上海辉电电力设备工程有限公司')
|
|
|
- ]
|
|
|
-})
|
|
|
+// Mock.mock(`${API_BASE_PATH}/provider/list`, 'post', {
|
|
|
+// type: 'success',
|
|
|
+// data: [
|
|
|
+// new Provider(1, '人民电器集团有限公司'),
|
|
|
+// new Provider(2, '上海东生供用电器材厂'),
|
|
|
+// new Provider(3, '上海辉电电力设备工程有限公司')
|
|
|
+// ]
|
|
|
+// })
|
|
|
|
|
|
-Mock.mock(`${API_BASE_PATH}/tag/type/list`, 'post', {
|
|
|
- type: 'success',
|
|
|
- data: [
|
|
|
- new TagType(1, '高性能不干胶标签'),
|
|
|
- new TagType(2, '柔性抗金属标签'),
|
|
|
- new TagType(3, '扎带标签')
|
|
|
- ]
|
|
|
-})
|
|
|
+// Mock.mock(`${API_BASE_PATH}/tag/type/list`, 'post', {
|
|
|
+// type: 'success',
|
|
|
+// data: [
|
|
|
+// new TagType(1, '高性能不干胶标签'),
|
|
|
+// new TagType(2, '柔性抗金属标签'),
|
|
|
+// new TagType(3, '扎带标签')
|
|
|
+// ]
|
|
|
+// })
|
|
|
|
|
|
-Mock.mock(`${API_BASE_PATH}/tag/purchase/state/list`, 'post', {
|
|
|
- type: 'success',
|
|
|
- data: [
|
|
|
- new TagPurchaseState(1, '新建'),
|
|
|
- new TagPurchaseState(2, '完成')
|
|
|
- ]
|
|
|
-})
|
|
|
+// Mock.mock(`${API_BASE_PATH}/tag/purchase/state/list`, 'post', {
|
|
|
+// type: 'success',
|
|
|
+// data: [
|
|
|
+// new TagPurchaseState(1, '新建'),
|
|
|
+// new TagPurchaseState(2, '完成')
|
|
|
+// ]
|
|
|
+// })
|
|
|
|
|
|
-Mock.mock(/\/tag\/purchase\/page/, 'post', {
|
|
|
- type: 'success',
|
|
|
- data: {
|
|
|
- 'count|10-40': 1,
|
|
|
- 'list|1-20': [{
|
|
|
- 'id|1-20': 1,
|
|
|
- 'providerId|1-3': 1,
|
|
|
- dataTime: '2024/01/01 00:00:00',
|
|
|
- orderNo: '123456',
|
|
|
- 'tagTypeId|1': [1, 2, 3],
|
|
|
- number: 123,
|
|
|
- 'amount|1-100.1-2': 30,
|
|
|
- buyerName: '采购者',
|
|
|
- receiveDate: '2024/01/02 00:00:00',
|
|
|
- 'tagPurchaseStateId|1-2': 1
|
|
|
- }]
|
|
|
- }
|
|
|
-})
|
|
|
+// Mock.mock(/\/tag\/purchase\/page/, 'post', {
|
|
|
+// type: 'success',
|
|
|
+// data: {
|
|
|
+// 'count|10-40': 1,
|
|
|
+// 'list|1-20': [{
|
|
|
+// 'id|1-20': 1,
|
|
|
+// 'providerId|1-3': 1,
|
|
|
+// dataTime: '2024/01/01 00:00:00',
|
|
|
+// orderNo: '123456',
|
|
|
+// 'tagTypeId|1': [1, 2, 3],
|
|
|
+// number: 123,
|
|
|
+// 'amount|1-100.1-2': 30,
|
|
|
+// buyerName: '采购者',
|
|
|
+// receiveDate: '2024/01/02 00:00:00',
|
|
|
+// 'tagPurchaseStateId|1-2': 1
|
|
|
+// }]
|
|
|
+// }
|
|
|
+// })
|
|
|
|
|
|
-Mock.mock(/\/tag\/purchase\/.+/, 'get', {
|
|
|
- type: 'success',
|
|
|
- data: {
|
|
|
- 'id|1-20': 1,
|
|
|
- 'providerId|1-3': 1,
|
|
|
- dataTime: '2024/01/01 00:00:00',
|
|
|
- orderNo: '123456',
|
|
|
- 'tagTypeId|1': [1, 2, 3],
|
|
|
- number: 123,
|
|
|
- price: 10,
|
|
|
- 'amount|1-100.1-2': 30,
|
|
|
- buyerName: '采购者',
|
|
|
- receiveDate: '2024/01/02 00:00:00',
|
|
|
- 'tagPurchaseStateId|1-2': 1
|
|
|
- }
|
|
|
-})
|
|
|
+// Mock.mock(/\/tag\/purchase\/.+/, 'get', {
|
|
|
+// type: 'success',
|
|
|
+// data: {
|
|
|
+// 'id|1-20': 1,
|
|
|
+// 'providerId|1-3': 1,
|
|
|
+// dataTime: '2024/01/01 00:00:00',
|
|
|
+// orderNo: '123456',
|
|
|
+// 'tagTypeId|1': [1, 2, 3],
|
|
|
+// number: 123,
|
|
|
+// price: 10,
|
|
|
+// 'amount|1-100.1-2': 30,
|
|
|
+// buyerName: '采购者',
|
|
|
+// receiveDate: '2024/01/02 00:00:00',
|
|
|
+// 'tagPurchaseStateId|1-2': 1
|
|
|
+// }
|
|
|
+// })
|
|
|
|
|
|
-Mock.mock(/\/tag\/purchase\/in-storage/, 'put', {
|
|
|
- type: 'success',
|
|
|
- data: true
|
|
|
-})
|
|
|
+// Mock.mock(/\/tag\/purchase\/in-storage/, 'put', {
|
|
|
+// type: 'success',
|
|
|
+// data: true
|
|
|
+// })
|
|
|
|
|
|
-Mock.mock(/\/tag\/code\/page/, 'post', {
|
|
|
- type: 'success',
|
|
|
- data: {
|
|
|
- 'count|10-40': 1,
|
|
|
- 'list|1-20': [{
|
|
|
- 'id|1-20': 1,
|
|
|
- dataTime: '2024/01/01 00:00:00',
|
|
|
- orderNo: '123456',
|
|
|
- expectedReceiptDate: '2024/01/02 00:00:00',
|
|
|
- serialNumberRange: ['0000001', '000800'],
|
|
|
- 'providerName|1': ['人民电器集团有限公司', '上海东生供用电器材厂', '上海辉电电力设备工程有限公司'],
|
|
|
- 'tagTypeName|1': ['高性能不干胶标签', '柔性抗金属标签', '扎带标签'],
|
|
|
- number: 123,
|
|
|
- 'amount|1-100.1-2': 30,
|
|
|
- 'tagApplyStateName|1': ['待支付', '待发货', '已发货'],
|
|
|
- operatorName: '操作员',
|
|
|
- applicantName: '申领人',
|
|
|
- 'unitPrice|1-100.1-2': 10,
|
|
|
- createTime: '2024/01/01 00:00:00'
|
|
|
- }]
|
|
|
- }
|
|
|
-})
|
|
|
+// Mock.mock(/\/tag\/code\/page/, 'post', {
|
|
|
+// type: 'success',
|
|
|
+// data: {
|
|
|
+// 'count|10-40': 1,
|
|
|
+// 'list|1-20': [{
|
|
|
+// 'id|1-20': 1,
|
|
|
+// dataTime: '2024/01/01 00:00:00',
|
|
|
+// orderNo: '123456',
|
|
|
+// expectedReceiptDate: '2024/01/02 00:00:00',
|
|
|
+// serialNumberRange: ['0000001', '000800'],
|
|
|
+// 'providerName|1': ['人民电器集团有限公司', '上海东生供用电器材厂', '上海辉电电力设备工程有限公司'],
|
|
|
+// 'tagTypeName|1': ['高性能不干胶标签', '柔性抗金属标签', '扎带标签'],
|
|
|
+// number: 123,
|
|
|
+// 'amount|1-100.1-2': 30,
|
|
|
+// 'tagApplyStateName|1': ['待支付', '待发货', '已发货'],
|
|
|
+// operatorName: '操作员',
|
|
|
+// applicantName: '申领人',
|
|
|
+// 'unitPrice|1-100.1-2': 10,
|
|
|
+// createTime: '2024/01/01 00:00:00'
|
|
|
+// }]
|
|
|
+// }
|
|
|
+// })
|
|
|
|
|
|
Mock.mock(`${API_BASE_PATH}/data/statistics/tag/type/count`, 'get', {
|
|
|
type: 'success',
|