|
@@ -149,7 +149,7 @@ import Drawer from '@/common/components/drawer/index.vue';
|
|
|
import { PlusOutlined, MinusOutlined } from '@ant-design/icons-vue';
|
|
import { PlusOutlined, MinusOutlined } from '@ant-design/icons-vue';
|
|
|
import { hdWROrder } from '@/services/proto/warehousetrade';
|
|
import { hdWROrder } from '@/services/proto/warehousetrade';
|
|
|
import { requestResultLoadingAndInfo } from '@/common/methods/request/resultInfo';
|
|
import { requestResultLoadingAndInfo } from '@/common/methods/request/resultInfo';
|
|
|
-import { WRGoodsInfo } from '@/services/proto/warehousetrade/interface';
|
|
|
|
|
|
|
+import {DGFactoryItems, WRGoodsInfo} from '@/services/proto/warehousetrade/interface';
|
|
|
import { getAccountTypeList, getUserId } from '@/services/bus/account';
|
|
import { getAccountTypeList, getUserId } from '@/services/bus/account';
|
|
|
import { v4 as uuidv4 } from 'uuid';
|
|
import { v4 as uuidv4 } from 'uuid';
|
|
|
import moment, { Moment } from 'moment';
|
|
import moment, { Moment } from 'moment';
|
|
@@ -157,7 +157,7 @@ import { getMarketRunByTradeMode } from '@/services/bus/market';
|
|
|
import { WrOrderQuote } from '@/services/go/wrtrade/interface';
|
|
import { WrOrderQuote } from '@/services/go/wrtrade/interface';
|
|
|
import { handleForm, handleNumAndPrice } from './setup';
|
|
import { handleForm, handleNumAndPrice } from './setup';
|
|
|
import { validateAction } from '@/common/setup/form';
|
|
import { validateAction } from '@/common/setup/form';
|
|
|
-import { FormParam } from './interface';
|
|
|
|
|
|
|
+import {FormParam, TempWrOrderQuoteDetail} from './interface';
|
|
|
import { EnumRouterName } from '@/common/constants/enumRouterName';
|
|
import { EnumRouterName } from '@/common/constants/enumRouterName';
|
|
|
import { handleIs } from '../buy-sell-market/setup';
|
|
import { handleIs } from '../buy-sell-market/setup';
|
|
|
import { BuyOrSell } from '@/common/constants/enumCommon';
|
|
import { BuyOrSell } from '@/common/constants/enumCommon';
|
|
@@ -169,7 +169,7 @@ export default defineComponent({
|
|
|
components: { Des, Drawer, PlusOutlined, MinusOutlined },
|
|
components: { Des, Drawer, PlusOutlined, MinusOutlined },
|
|
|
props: {
|
|
props: {
|
|
|
selectedRow: {
|
|
selectedRow: {
|
|
|
- type: Object as PropType<WrOrderQuote>,
|
|
|
|
|
|
|
+ type: Object as PropType<TempWrOrderQuoteDetail>,
|
|
|
default: {},
|
|
default: {},
|
|
|
},
|
|
},
|
|
|
enumName: {
|
|
enumName: {
|
|
@@ -200,6 +200,10 @@ export default defineComponent({
|
|
|
const marketInfo = getMarketRunByTradeMode(17);
|
|
const marketInfo = getMarketRunByTradeMode(17);
|
|
|
if (marketInfo) {
|
|
if (marketInfo) {
|
|
|
validateAction<FormParam>(formRef, formState).then((res) => {
|
|
validateAction<FormParam>(formRef, formState).then((res) => {
|
|
|
|
|
+
|
|
|
|
|
+ // 现在增加一种挂牌求购的情况
|
|
|
|
|
+ // 这种求购模式会生成一种仓单贸易商品
|
|
|
|
|
+
|
|
|
const wrGoodsInfo: WRGoodsInfo = {
|
|
const wrGoodsInfo: WRGoodsInfo = {
|
|
|
GoodsID: props.selectedRow.goodsid, // uint32 配置商品ID
|
|
GoodsID: props.selectedRow.goodsid, // uint32 配置商品ID
|
|
|
GoodsCode: props.selectedRow.goodscode, // string 配置商品代码
|
|
GoodsCode: props.selectedRow.goodscode, // string 配置商品代码
|
|
@@ -248,7 +252,16 @@ export default defineComponent({
|
|
|
WRStandardID: props.selectedRow.wrstandardid,
|
|
WRStandardID: props.selectedRow.wrstandardid,
|
|
|
HasWr: isWR(), // 无仓单挂牌 是否有无仓单
|
|
HasWr: isWR(), // 无仓单挂牌 是否有无仓单
|
|
|
DeliveryMonth: isWR() ? '' : moment(res.DeliveryMonth).format('YYYY-MM'),
|
|
DeliveryMonth: isWR() ? '' : moment(res.DeliveryMonth).format('YYYY-MM'),
|
|
|
|
|
+ FactoryItems: props.selectedRow.wrResult.flatMap((it) => {
|
|
|
|
|
+ return {
|
|
|
|
|
+ DGFactoryItemTypeID: it.dgfactoryitemtypeid, // uint64 要素项类型ID
|
|
|
|
|
+ DGFactoryItemID: it.dgfactoryitemid, // uint64 预约要素项类型值
|
|
|
|
|
+ ItemTypeMode: 1, // uint32 要素项类型模式
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ ) // DGFactoryItems 要素类型明细集合(没有仓单要素ID填写)
|
|
|
};
|
|
};
|
|
|
|
|
+ debugger
|
|
|
requestResultLoadingAndInfo(hdWROrder, param, loading, ['求购成功', '求购失败:']).then(() => {
|
|
requestResultLoadingAndInfo(hdWROrder, param, loading, ['求购成功', '求购失败:']).then(() => {
|
|
|
cancel(true);
|
|
cancel(true);
|
|
|
});
|
|
});
|