|
|
@@ -1,182 +1,25 @@
|
|
|
<template>
|
|
|
- <a-form :loading="loading"
|
|
|
- class="inlineForm">
|
|
|
- <fieldset class="formFieldSet">
|
|
|
- <legend>基本信息</legend>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="合同编号">
|
|
|
- <span class="white">{{ formatValue(selectedRow.contractno) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="合同类型">
|
|
|
- <span class="white">{{ getContractTypeName(selectedRow.contracttype) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="业务类型">
|
|
|
- <span class="white">{{ getBizTypeName(selectedRow.biztype) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="采购方">
|
|
|
- <span class="white">{{ formatValue(selectedRow.buyusername) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="销售方">
|
|
|
- <span class="white">{{ formatValue(selectedRow.sellusername) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="合同附件">
|
|
|
- <span class="white"
|
|
|
- @click="previewImg(selectedRow.attachment)">{{ formatValue(getImgName(selectedRow.attachment)) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="状态">
|
|
|
- <span class="yellow">{{ formatValue(getContractStatusName(selectedRow.contracctstatus)) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- </fieldset>
|
|
|
- <fieldset class="formFieldSet">
|
|
|
- <legend>现货信息</legend>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="现货品种">
|
|
|
- <span class="white">{{ formatValue(selectedRow.deliverygoodsname) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="品类">
|
|
|
- <span class="white">{{ formatValue(selectedRow.wrstandardname) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="品牌">
|
|
|
- <span class="white">{{ formatValue(selectedRow.brandname) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="标仓系数">
|
|
|
- <span class="white">{{ formatValue(selectedRow.convertfactor) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="商品规格">
|
|
|
- <span class="white">{{ formatValue(selectedRow.spotgoodsdesc) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- </fieldset>
|
|
|
- <fieldset class="formFieldSet">
|
|
|
- <legend>价格信息</legend>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="定价类型">
|
|
|
- <span class="white">{{ getPriceTypeName(formatValue(selectedRow.pricetype)) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="数量">
|
|
|
- <span class="white">{{ formatValue(selectedRow.qty) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="点价合约">
|
|
|
- <span class="white">{{ formatValue(selectedRow.goodscode) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="升贴水">
|
|
|
- <span class="white">{{ formatValue(selectedRow.pricemove) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="点价期">
|
|
|
- <span class="white">{{ formatValue(formatTime(selectedRow.startdate, "d") + '--' + formatTime(selectedRow.enddate, "d")) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="交收期">
|
|
|
- <span class="white">{{ formatValue(formatTime(selectedRow.deliverystartdate, "d") + '--' + formatTime(selectedRow.deliveryenddate, "d"))}}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- </fieldset>
|
|
|
+ <Detail :selectedRow="selectedRow">
|
|
|
<fieldset class="formFieldSet">
|
|
|
<legend>其它信息</legend>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="保证金">
|
|
|
- <span class="white">{{ formatValue(selectedRow.contractmargin) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="业务员">
|
|
|
- <span class="white">{{ formatValue(findManagerName(selectedRow.saleuserid, businessManager) ) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="跟单员">
|
|
|
- <span class="white">{{ formatValue(findManagerName(selectedRow.meruserid, businessManager) ) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="交易用户">
|
|
|
- <span class="white">{{ formatValue(selectedRow.tradeusername) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
- <a-row :gutter="24">
|
|
|
- <a-col :span="12">
|
|
|
- <a-form-item label="备注">
|
|
|
- <span class="white">{{ formatValue(selectedRow.remark) }}</span>
|
|
|
- </a-form-item>
|
|
|
- </a-col>
|
|
|
- </a-row>
|
|
|
+ <Des :list="desList" />
|
|
|
</fieldset>
|
|
|
- <a-modal :visible="previewVisible"
|
|
|
- :footer="null"
|
|
|
- @cancel="cancelImg">
|
|
|
- <img alt="预览附件"
|
|
|
- style="width: 100%"
|
|
|
- :src="previewImage" />
|
|
|
- </a-modal>
|
|
|
- </a-form>
|
|
|
+ </Detail>
|
|
|
</template>
|
|
|
|
|
|
<script lang="ts">
|
|
|
import { defineComponent, PropType, ref } from 'vue';
|
|
|
import { Ermcp3ContractRsp } from '@/services/go/ermcp/spot-contract/interface';
|
|
|
-import { formatTime, formatValue } from '@/common/methods';
|
|
|
-import { getBizTypeName, getContractStatusName, getContractTypeName, getPriceTypeName } from '@/common/constants/enumsName';
|
|
|
-import { handlerManagerList } from '@/common/setup/user';
|
|
|
+import { formatValue } from '@/common/methods';
|
|
|
import { ErmcpLoginUserEx } from '@/services/go/ermcp/account/interface';
|
|
|
-import { handlePreviewImg } from '@/common/setup/upload';
|
|
|
+import Detail from '../common-detail/index.vue';
|
|
|
+import { Des, handleDesList } from '@/common/components/commonDes';
|
|
|
+import { watchEffect } from '@vue/runtime-dom';
|
|
|
+import { handlerManagerList } from '@/common/setup/user';
|
|
|
|
|
|
export default defineComponent({
|
|
|
name: 'spot-contract-info-detail',
|
|
|
- components: {},
|
|
|
+ components: { Detail, Des },
|
|
|
props: {
|
|
|
selectedRow: {
|
|
|
type: Object as PropType<Ermcp3ContractRsp>,
|
|
|
@@ -189,24 +32,25 @@ export default defineComponent({
|
|
|
},
|
|
|
setup(props, context) {
|
|
|
const loading = ref<boolean>(false);
|
|
|
+ // 预览附件
|
|
|
+ const { desList, getDesList } = handleDesList();
|
|
|
// 获取 业务账户
|
|
|
const { findManagerName } = handlerManagerList(loading, 1);
|
|
|
- // 预览附件
|
|
|
- const { previewVisible, previewImage, cancelImg, previewImg, getImgName } = handlePreviewImg();
|
|
|
+ watchEffect(() => {
|
|
|
+ if (props.selectedRow.contracctstatus) {
|
|
|
+ const data = props.selectedRow;
|
|
|
+ const list = [
|
|
|
+ { label: '保证金', value: formatValue(data.contractmargin) },
|
|
|
+ { label: '业务员', value: formatValue(findManagerName(data.saleuserid, props.businessManager)) },
|
|
|
+ { label: '跟单员', value: formatValue(findManagerName(data.meruserid, props.businessManager)) },
|
|
|
+ { label: '交易用户', value: formatValue(data.tradeusername) },
|
|
|
+ { label: '备注', value: formatValue(data.remark) },
|
|
|
+ ];
|
|
|
+ getDesList(list);
|
|
|
+ }
|
|
|
+ });
|
|
|
return {
|
|
|
- loading,
|
|
|
- formatValue,
|
|
|
- getPriceTypeName,
|
|
|
- getContractStatusName,
|
|
|
- formatTime,
|
|
|
- getContractTypeName,
|
|
|
- getBizTypeName,
|
|
|
- findManagerName,
|
|
|
- previewVisible,
|
|
|
- previewImage,
|
|
|
- cancelImg,
|
|
|
- previewImg,
|
|
|
- getImgName,
|
|
|
+ desList,
|
|
|
};
|
|
|
},
|
|
|
});
|