Commit 56d43d58 authored by alwayOnlie's avatar alwayOnlie

BUG修复

parent 81d43e9a
......@@ -16,8 +16,8 @@ const FormList = (props: any) => {
console.log(sourceType)
const refs = useRef({});
/* 显示模态框 */
const [isModalVisible, setIsModalVisible] = useState(false);
const [selectedRowKeys, setSelectedRowKeys] = useState<Array<string>>([])
const [isModalVisible, setIsModalVisible] = useState(false);// 显示模态框
const [selectedRowKeys, setSelectedRowKeys] = useState<Array<string>>([]) // 选中的
const [selectRow, setSelectRow] = useState<any[]>([]) // 模态框选择的行数据
const [dataList, setData] = useState<Array<any>>([]) // 列表数据
/* 选中 */
......@@ -39,7 +39,6 @@ const FormList = (props: any) => {
setData(dataArr)
setIsModalVisible(false);
};
/* 获取商品 */
const getGoodsList = (params) => {
return new Promise(resolve => {
......@@ -146,12 +145,15 @@ const FormList = (props: any) => {
price: _filter(sourceType, item, ['', 'taxUnitPrice', 'price', 'price']), //单价
bidCount: sourceType == '1' ? item.awardTaxProbability * item.purchaseCount / 100 : sourceType == '2' ? item.awardTenderRatio * item.inviteTenderMateriel.count / 100 : item.purchaseCount,
bidAmount: sourceType == '1' ? item.awardTaxProbability * item.purchaseCount / 100 * item.taxUnitPrice : sourceType == '2' ? item.awardTenderRatio * item.inviteTenderMateriel.count / 100 * item.price : item.price,
associatedType: _filter(sourceType, item, ['', 'productBrand', '', '']),
// productBrand
associatedType: _filter(sourceType, item, ['', '', '', '']),
associatedBrand: _filter(sourceType, item, ['', 'productAttributeJson', '', '']),
associatedDataId: sourceType == '1' ? item.productId : sourceType == '2' ? item.commodityId : '', // 关联商品id
associatedMaterielNo: sourceType == '1' ? item.number : sourceType == '2' ? item.commodityAttribute : '', // 关联物料编号
associatedMaterielName: sourceType == '1' ? item.productName : sourceType == '2' ? item.commodityName : '', // 关联商品名称
associatedGoods: sourceType == '1' ? item.productAttributeJson : sourceType == '2' ? item.commodityBrand : '',// 关联品牌
associatedDataId: _filter(sourceType, item, ['', 'number', 'commodityAttribute']), // 关联商品id
associatedMaterielNo: _filter(sourceType, item, ['', 'number', 'commodityAttribute']), // 关联物料编号
associatedMaterielName: _filter(sourceType, item, ['', 'productName', 'commodityName']), // 关联商品名称
associatedGoods: _filter(sourceType, item, ['', 'productAttributeJson', 'commodityBrand']), //关联品牌
// associatedMaterielName: sourceType == '1' ? item.productName : sourceType == '2' ? item.commodityName : '',
// associatedGoods: sourceType == '1' ? item.productAttributeJson : sourceType == '2' ? item.commodityBrand : '',// 关联品牌
rowId: index,
}
})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment