ref: Remove board types, refactoring

This commit is contained in:
Maksim Eltyshev
2022-12-26 21:10:50 +01:00
parent d39da61295
commit 5cd025ffb7
182 changed files with 1573 additions and 1239 deletions
+4 -3
View File
@@ -12,7 +12,6 @@ export function* createCard(listId, data) {
const nextData = {
...data,
listId,
position: yield select(selectors.selectNextCardPosition, listId),
};
@@ -22,13 +21,14 @@ export function* createCard(listId, data) {
actions.createCard({
...nextData,
boardId,
listId,
id: localId,
}),
);
let card;
try {
({ item: card } = yield call(request, api.createCard, boardId, nextData));
({ item: card } = yield call(request, api.createCard, listId, nextData));
} catch (error) {
yield put(actions.createCard.failure(localId, error));
return;
@@ -61,8 +61,9 @@ export function* updateCurrentCard(data) {
yield call(updateCard, cardId, data);
}
// TODO: handle card transfer
export function* handleCardUpdate(card) {
yield put(actions.handleCardUpdate(card)); // TODO: handle card transfer
yield put(actions.handleCardUpdate(card));
}
export function* moveCard(id, listId, index) {