# 待新增個案 ## API * [待新增個案列表](#待新增個案列表) * [重新發送收案授權通知](#重新發送收案授權通知) * [發送授權同意通知](#發送授權同意通知) * [取得個人待新增個案通知列表](#取得個人待新增個案通知列表) * [將所有已收案的個案加入同意機構清單](#將所有已收案的個案加入同意機構清單) ## 待新增個案列表 ### Resquest URL ```url= POST /caseWaiting/list ``` ### Query Param | 欄位 | 型態 | 必填 | 說明 | |---|---|---|---| | startDate | timestamp | |收案日期開始時間 | | endDate | timestamp | |收案日期結束時間 | | keywords | string | |姓名或身份證字號查詢 | | current | number | |當前頁數| | pageSize | number | |每頁結果數量,-1 為顯示所有| | field | string | |排序欄位,這裡支援用 acceptDate , patName, disease, medicalStaff, latestNotify| | order | string | |排序方法,這裡支援用 asc 或 desc 排序| ### Request Body Example ```json= { "query": { "startDate":1614528000000, "endDate":1615528000000, "keywords":"王小明" }, "pagination": { "current": 1, "pageSize":10 }, "sorter": { "field": "acceptDate", "order": "asc" } } ``` ### Response Body Param | 欄位 | 型態 | 說明 | |---|---|---| |id | String | 待收案ID| |acceptDate | timestamp | 收案日期| |patIdNo |String |個案身份證| |patName | String | 個案姓名| |disease | String | 收案疾病與階段| |medicalStaff | String | 收案人員| |latestNotify | timestamp |最後發送通知時間| ### Response Body Example ```json { "httpCode": 200, "result": { "data": [ { "id":"88c2c686-4486-474", "acceptDate":1615028000000, "patIdNo": "C188256154", "patName": "李小飛", "disease": "ECKD Stage2", "medicalStaff": "林一飛/腎臟科", "latestNotify": 1615328000000 }, { "id":"1b06b8e2-88f4-4cef-99", "acceptDate":1615048000000, "patIdNo": "A138206154", "patName": "王大名", "disease": "DM", "medicalStaff": "陳小華/新陳代科", "latestNotify": 1616328000000 },... ], "pagination": { "current": 1, "pageSize": 10, "total": 75 }, "sorter": { "field": "acceptDate", "order": "asc" } } } ``` ## 重新發送收案授權通知 ### Resquest URL ```url= POST /caseWaiting/notify ``` ### Query Param | 欄位 | 型態 | 必填 | 說明 | |---|---|---|---| | caseWaitingId | string | * | 待新增個案 ID | ### Request Body Example ```json= { "query": { "caseWaitingId": "0a7e9660-f7c1-4194-be92-0d2c4d56e8cb" } } ``` ### Response Body Param | 欄位 | 型態 | 說明 | |---|---|---| |status | number |1為成功,0為失敗| ### Response Body Example ```json { "httpCode": 200, "result": { "data": { "status":1 } } } ``` ## 發送授權同意通知 ### Resquest URL ```url= POST /caseWaiting/agree ``` ### Query Param | 欄位 | 型態 | 必填 | 說明 | |---|---|---|---| | caseWaitingId | string | * | 待新增個案 ID | ### Request Body Example ```json= { "query": { "caseWaitingId": "0a7e9660-f7c1-4194-be92-0d2c4d56e8cb" } } ``` ### Response Body Param | 欄位 | 型態 | 說明 | |---|---|---| |status | number |1:個案授權成功,且待收案在加入個案時有一則以上成功。0:個案授權成功,但待收案在加入個案時全部失敗。| |tenantName | string |個案授權成功時,顯示第一間收案單位。| ### Response Body Example ```json { "httpCode": 200, "result": { "data": { "status":1, "tenantName": "365醫院" } } } ``` ## 取得個人待新增個案通知列表 ### Resquest URL ```url= POST /notificationRecord/list ``` ### Query Param | 欄位 | 型態 | 必填 | 說明 | |---|---|---|---| | type | Integer | * | 系統類別,固定為 5 | ### Request Body Example ```json= { "pagination": { "current": 2, "pageSize": 10 }, "type":5 } ``` ### Response Body Param | 欄位 | 型態 | 說明 | |---|---|---| |id | string |通知ID| |userId | string |使用者身份證| |title | string |發送通知標題| |description | string |發送通知內容| |notificationTime | timestamp |發送通知時間| |type | number |固定為 5 (代表系統類)| |caseWaitingId | string |待新增個案ID| |caseAgree | number | 1為同意,0為不同意| ### Response Body Example ```json { "httpCode": 200, "result": { "data": { "id": "0a7e9660-f7c1-4194-be92-0d2c4d56e8cb", "userId": "E124692461", "title": "收案授權通知", "description": "高醫想將您收入 DM 個案", "notificationTime":1614902400000, "type": 5, "caseWaitingId": "0a7e9660-f7c1-4194-be92-0d2c4d56e8cb" "caseAgree":1 } } } ``` ## 將所有已收案的個案加入同意機構清單 :::info 此 API 功能為 針對某特定機構下,取得已收案的個案後,全部一次加入使用者同意清單 ::: :::info 此 API 會以 ==之前已收案== 的個案 先加入使用者清單後,再檢查是否有已加入待收案清單, 若有的話則一併進行同意流程 針對尚未收過案的個案並無作用 ::: ### Resquest URL ```url= POST /caseWaiting/agreeAllVpnCase ``` ### Query Param | 欄位 | 型態 | 必填 | 說明 | |---|---|---|---| | tenantId | String | * | 想要同意的機構 ID | | householdMemberId | String | | 指定某 member ID | ### Request Body Example ```json= { { "query": { "householdMemberId":"4d474824-75c6-434b-a517-c0280fab96b2", "tenantId":"1af0a4c2-ef73-4385-aa8e-8e7ae8afe155" } } } ``` ### Response Body Param | 欄位 | 型態 | 說明 | |---|---|---| |id | string |同意清單 ID| |householdMemberId | string |同意者 ID| |tenantId | string |同意機構 ID| ### Response Body Example ```json { "httpCode": 200, "result": { "data": [ { "id": "b1c57233-9427-4fe0-b79a-06c92bae8533", "householdMemberId": "c179ce6f-07b6-438a-accb-9bcfd48533df", "tenantId": "1af0a4c2-ef73-4385-aa8e-8e7ae8afe155" } ] } } ```