Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Function] 取得行事曆資料 (in Dashboard ToDoList) #2471

Closed
Tracked by #2449
godmmt opened this issue Sep 18, 2024 · 7 comments · Fixed by #3326
Closed
Tracked by #2449

[Function] 取得行事曆資料 (in Dashboard ToDoList) #2471

godmmt opened this issue Sep 18, 2024 · 7 comments · Fixed by #3326
Assignees
Labels
5 hard level 5 enhancement New feature or request

Comments

@godmmt
Copy link
Member

godmmt commented Sep 18, 2024

心智圖

API: listUserTodo

@godmmt godmmt self-assigned this Sep 18, 2024
@godmmt godmmt added enhancement New feature or request 3 hard level 3 labels Sep 18, 2024
@godmmt godmmt added this to the v0.9.0 Beta Release milestone Sep 20, 2024
@godmmt godmmt changed the title [Function] 建立行事曆 [Function] 取得行事曆資料 Sep 20, 2024
@godmmt godmmt changed the title [Function] 取得行事曆資料 [Function] 取得行事曆資料 (in Dashboard ToDoList) Nov 19, 2024
@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

取得 todoList 後拿最新一筆

@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

如果沒有建立過公司就顯示 Not Link

@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

todoList 為 [] 就顯示 沒有資料

@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

討論

建立 todo 的 modal 要新增欄位「時間」

讓使用者可以輸入「時間」
目前只有「日期」所以在顯示的時候無法顯示時間

設計稿:

截圖 2024-11-22 18 10 32 截圖 2024-11-22 18 10 41

UI 元件需要修改

src/components/beta/todo_list_page/create_todo_modal.tsx

API 需要修改

interface 格式要再增加時間
目前:

export interface ITodo {
  id: number;
  name: string;
  deadline: number;
  note: string;
  status: boolean;
  createdAt: number;
  updatedAt: number;
}

export interface ITodoCompany extends ITodo {
  id: number;
  company: ICompany;
  createdAt: number;
  updatedAt: number;
}

@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

目前暫時解法先放入 note 取代時間的位置

截圖 2024-11-22 18 11 16

@godmmt godmmt added 5 hard level 5 and removed 3 hard level 3 labels Nov 22, 2024
@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

重構 toda todo list 邏輯

只篩選出今天且尚未過期的待辦事項
並排序
離當前時間越靠近越前面

提供 scroll bar 可以滑待辦事項 (x 軸)

使用計時器 limer 去每秒觀察待辦事項是否已經過期並更新

@godmmt
Copy link
Member Author

godmmt commented Nov 22, 2024

took 5 hours

done

@godmmt godmmt linked a pull request Nov 22, 2024 that will close this issue
10 tasks
@godmmt godmmt closed this as completed Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
5 hard level 5 enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant