|
|
@ -1,7 +1,7 @@
|
|
|
|
import { useState } from 'react'
|
|
|
|
import { useState } from 'react'
|
|
|
|
import { Table, Form, Modal, Button, Radio, Input, Flex, Card, Select, InputNumber, Checkbox, DatePicker, Space, App } from 'antd'
|
|
|
|
import { Table, Form, Modal, Button, Radio, Input, Flex, Card, Select, InputNumber, Checkbox, DatePicker, Space, App, Tooltip } from 'antd'
|
|
|
|
import { useTranslation } from 'react-i18next'
|
|
|
|
import { useTranslation } from 'react-i18next'
|
|
|
|
import { CloseOutlined, StarTwoTone, PlusOutlined, ExclamationCircleFilled } from '@ant-design/icons'
|
|
|
|
import { CloseOutlined, StarTwoTone, PlusOutlined, ExclamationCircleFilled, QuestionCircleOutlined, QuestionOutlined } from '@ant-design/icons'
|
|
|
|
import { useDatePresets } from '@/hooks/useDatePresets'
|
|
|
|
import { useDatePresets } from '@/hooks/useDatePresets'
|
|
|
|
import dayjs from 'dayjs'
|
|
|
|
import dayjs from 'dayjs'
|
|
|
|
import useProductsStore from '@/stores/Products/Index'
|
|
|
|
import useProductsStore from '@/stores/Products/Index'
|
|
|
@ -202,14 +202,14 @@ const ProductInfoQuotation = ({ editable, ...props }) => {
|
|
|
|
const quotationColumns = [
|
|
|
|
const quotationColumns = [
|
|
|
|
{ title: 'id', dataIndex: 'id', width: 40, className: 'italic text-gray-400' }, // test: 0
|
|
|
|
{ title: 'id', dataIndex: 'id', width: 40, className: 'italic text-gray-400' }, // test: 0
|
|
|
|
{ title: 'WPI_SN', dataIndex: 'WPI_SN', width: 40, className: 'italic text-gray-400' }, // test: 0
|
|
|
|
{ title: 'WPI_SN', dataIndex: 'WPI_SN', width: 40, className: 'italic text-gray-400' }, // test: 0
|
|
|
|
{ title: t('products:adultPrice'), dataIndex: 'adult_cost', width: '4rem' },
|
|
|
|
{ title: t('products:adultPrice'), dataIndex: 'adult_cost', width: '5rem' },
|
|
|
|
{ title: t('products:childrenPrice'), dataIndex: 'child_cost', width: '4rem' },
|
|
|
|
{ title: t('products:childrenPrice'), dataIndex: 'child_cost', width: '5rem' },
|
|
|
|
{ title: t('products:currency'), dataIndex: 'currency', width: '4rem' },
|
|
|
|
{ title: t('products:currency'), dataIndex: 'currency', width: '4rem' },
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: t('products:Types'),
|
|
|
|
title: t('products:PriceUnit.title'),
|
|
|
|
dataIndex: 'unit_id',
|
|
|
|
dataIndex: 'unit_id',
|
|
|
|
width: '4rem',
|
|
|
|
width: '4rem',
|
|
|
|
render: (text) => (text === '0' ? '每人' : text === '1' ? '每团' : text),
|
|
|
|
render: (text) => t(`products:PriceUnit.${text}`), // (text === '0' ? '每人' : text === '1' ? '每团' : text),
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: t('products:number'),
|
|
|
|
title: t('products:number'),
|
|
|
@ -219,9 +219,9 @@ const ProductInfoQuotation = ({ editable, ...props }) => {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: t('products:validityPeriod'),
|
|
|
|
title: (<>{t('products:validityPeriod')} <Tooltip placement='top' overlayInnerStyle={{width: '24rem'}} title={t('products:FormTooltip.UseDates')}><QuestionCircleOutlined className='text-gray-500' /></Tooltip> </>),
|
|
|
|
dataIndex: 'use_dates',
|
|
|
|
dataIndex: 'use_dates',
|
|
|
|
width: '6rem',
|
|
|
|
// width: '6rem',
|
|
|
|
render: (_, record) => `${record.use_dates_start}-${record.use_dates_end}`,
|
|
|
|
render: (_, record) => `${record.use_dates_start}-${record.use_dates_end}`,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
@ -229,7 +229,7 @@ const ProductInfoQuotation = ({ editable, ...props }) => {
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: t('products:operation'),
|
|
|
|
title: t('products:operation'),
|
|
|
|
dataIndex: 'operation',
|
|
|
|
dataIndex: 'operation',
|
|
|
|
width: '3%',
|
|
|
|
width: '10rem',
|
|
|
|
render: (_, quotation) => {
|
|
|
|
render: (_, quotation) => {
|
|
|
|
// const _rowEditable = [-1,3].includes(quotation.audit_state_id);
|
|
|
|
// const _rowEditable = [-1,3].includes(quotation.audit_state_id);
|
|
|
|
const _rowEditable = true; // test: 0
|
|
|
|
const _rowEditable = true; // test: 0
|
|
|
|