カルテ3号紙(入院)印刷API
メニュー
更新履歴
2019-10-28 帳票のPDF作成機能を追加。
概要
- リクエスト項目に該当するカルテ3号紙(入院)の印刷および、レスポンスとして帳票データの返却を行います。
- 標準帳票の「ORCHCN33」に準じたレイアウトで印刷を行います。
- 帳票の編集にあたって、システム管理マスタ「1910 プログラムオプション情報」の「ORCHCN33」の設定を参照します。
テスト方法
- 参考提供されているsample_karte_no3_h_v2.rb内の変数HOST等を接続環境に合わせます。
- sample_karte_no3_h_v2.rb内の患者番号等を接続先の日レセの環境に合わせます。
- ruby sample_karte_no3_h_v2.rb により接続します。
リクエスト(POSTリクエスト)サンプル
POST : /api01rv2/karteno3hv2
Content-Type: application/xml
application/xml の場合の文字コードは UTF-8 とします。
<data>
<karte_no3_hv2req type ="record">
<Request_Number type ="string">01</Request_Number>
<Order_Class type ="string">1</Order_Class>
<Patient_ID type ="string">1</Patient_ID>
<Perform_Month type ="string">2018-07</Perform_Month>
<Department_Code type ="string"></Department_Code>
<Insurance_Combination_Number type ="string"></Insurance_Combination_Number>
<Start_Day type ="string"></Start_Day>
<Last_Page_Number type ="string"></Last_Page_Number>
<Last_Row_Number type ="string"></Last_Row_Number>
</karte_no3_hv2req>
</data>
レスポンスサンプル
JSON形式で返却を行います。
{
"Information_Date": "2018-08-01",
"Information_Time": "15:11:00",
"Api_Result": "0000",
"Api_Result_Message": "処理終了",
"Form_ID": "karte_no3_n",
"Form_Name": "カルテ3号紙(入院)",
"Print_Date": "2018-08-01",
"Print_Time": "15:10:59",
"Patient": {
"ID": "00001",
"Name": "日医 太郎",
"KanaName": "ニチイ タロウ",
"BirthDate": "1958-01-10",
"Sex": "1"
},
"Forms": [
{
"data": {
"Form_ID": "karte_no3_n",
"Printer": "PDF",
"Printer_Overlay": "PDF",
"Order_Class": "1",
"Last_Page_Number": " 1",
"Last_Row_Number": " 0",
"Perform_Month": "2018-07",
"Insurance_Name": "本人 協会",
"Patient": {
"ID": "00001",
"Name": "日医 太郎",
"KanaName": "ニチイ タロウ",
"BirthDate": "1958-01-10",
"Sex": "1"
},
"Account_List": [
{
"Perform_Date": "2018-07-01",
"Consultation": " 316",
"Medication": " 27",
"Injection": " 18",
"Treatment_Operation": " 875",
"Examination": " 146",
"Diagnostic_Imaging": " 153",
"Other": " 22",
"Hospital_Charge": " 2001",
"Total_Point": " 3558",
"Meal_Living": " 1970",
"Own_Expence": " 1000"
},
{
"Perform_Date": "2018-07-02",
"Medication": " 7",
"Hospital_Charge": " 1816",
"Total_Point": " 1823",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-03",
"Medication": " 7",
"Hospital_Charge": " 1816",
"Total_Point": " 1823",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-04",
"Medication": " 7",
"Hospital_Charge": " 1816",
"Total_Point": " 1823",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-05",
"Medication": " 7",
"Hospital_Charge": " 1816",
"Total_Point": " 1823",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-06",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-07",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-08",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-09",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-10",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-11",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-12",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-13",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-14",
"Hospital_Charge": " 1816",
"Total_Point": " 1816",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-15",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-16",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-17",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-18",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-19",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-20",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-21",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-22",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-23",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-24",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-25",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-26",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-27",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-28",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-29",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-30",
"Hospital_Charge": " 1318",
"Total_Point": " 1318",
"Meal_Living": " 1970"
},
{
"Perform_Date": "2018-07-31",
"Hospital_Charge": " 1126",
"Total_Point": " 1126",
"Meal_Living": " 1970"
},
{
"Total_Point": " 49408",
"Meal_Living": " 61070",
"Own_Expence": " 1000",
"Memo": "合計"
},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},{},
{},{},{},{},{},{},{},{}
]
}
}
]
}
リクエスト一覧
レスポンス一覧
Rubyによるリクエストサンプルソース
Rubyのバージョンが1.9.2以前の環境の場合、HTTPのバージョン指定を1.1に変更する必要があります。 Rubyのバージョンを確認後、以下のように該当箇所を変更して下さい。
- Ruby1.9.2以降の場合
Net::HTTP.version_1_2
- Ruby1.9.2以前の場合
Net::HTTP.version_1_1
Rubyのバージョンが1.9.1以降の環境(日レセ4.8以降の環境)ではソースファイル内の文字コードの指定が必要になります。
サンプルソース内に以下の一行が記述されていることを確認して下さい。
# -*- coding: utf-8 -*-