Skip to content

Commit

Permalink
🔨fix:tick-pagi updatedAt, disabled처리,date 형식화하기
Browse files Browse the repository at this point in the history
  • Loading branch information
AlmondBreez3 committed Aug 6, 2022
1 parent d630236 commit 863c3c1
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 4 deletions.
27 changes: 23 additions & 4 deletions src/components/Tables/TicketsPage/TicketsPage.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useState, useEffect } from 'react';

import moment from 'moment';
import { useSelector, useDispatch } from 'react-redux';
import { Table, Segmented, Select } from 'antd';
import {
Expand Down Expand Up @@ -139,8 +139,23 @@ function TicketsPage() {
render={user => user.name}
key="id"
/>

<Column title="공연 날짜" dataIndex="date" key="id" />
<Column title="예매일자" dataIndex="createdAt" key="id" />
<Column
title="예매일자"
dataIndex="createdAt"
render={element => {
return moment(element).utc(false).format('MM월DD일 HH:mm');
}}
/>
<Column
title="업데이트일자"
dataIndex="updatedAt"
key="id"
render={element => {
return moment(element).utc(false).format('MM월DD일 HH:mm');
}}
/>
<Column
title="Action"
dataIndex=""
Expand All @@ -153,8 +168,12 @@ function TicketsPage() {
>
<Option value="입금확인">입금확인</Option>
<Option value="입장완료">입장완료</Option>
<Option value="기한만료">기한만료</Option>
<Option value="확인대기">확인대기</Option>
<Option value="기한만료" disabled={true}>
기한만료
</Option>
<Option value="확인대기" disabled={true}>
확인대기
</Option>
</Select>
</div>
);
Expand Down
1 change: 1 addition & 0 deletions src/state/actions-creators/ticketPagination.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export const changeState =
try {
console.log('ticketId:', id);
console.log('status:', e);

const response = await axios.patch(
`https://api.gosrock.band/v1/tickets/status`,
{ ticketId: id, status: e }
Expand Down

0 comments on commit 863c3c1

Please sign in to comment.