diff --git a/ecs/jskult-webapp/src/static/css/bioStyle.css b/ecs/jskult-webapp/src/static/css/bioStyle.css index 55fea870..1314057c 100644 --- a/ecs/jskult-webapp/src/static/css/bioStyle.css +++ b/ecs/jskult-webapp/src/static/css/bioStyle.css @@ -317,25 +317,3 @@ table.tablesorter thead tr .headerSortDown { table.tablesorter thead tr .headerSortDown, table.tablesorter thead tr .headerSortUp { background-color: #8dbdd8; } - -#loading { - z-index: 10000; - position: fixed; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-color: #FFF; - overflow-x: hidden; - overflow-y: auto; - outline: 0; - text-align: center; - display: none; - opacity: 0.7; -} - -#loading_content { - position: absolute; - top: 50%; - left: 50%; -} \ No newline at end of file diff --git a/ecs/jskult-webapp/src/static/css/loading.css b/ecs/jskult-webapp/src/static/css/loading.css new file mode 100644 index 00000000..8f081d29 --- /dev/null +++ b/ecs/jskult-webapp/src/static/css/loading.css @@ -0,0 +1,21 @@ +._loading { + z-index: 10000; + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + background-color: #FFF; + overflow-x: hidden; + overflow-y: auto; + outline: 0; + text-align: center; + display: none; + opacity: 0.7; +} + +._loading_content { + position: absolute; + top: 50%; + left: 50%; +} diff --git a/ecs/jskult-webapp/src/static/function/businessLogicScript.js b/ecs/jskult-webapp/src/static/function/businessLogicScript.js index 56d971e4..a77bb2e9 100644 --- a/ecs/jskult-webapp/src/static/function/businessLogicScript.js +++ b/ecs/jskult-webapp/src/static/function/businessLogicScript.js @@ -1,8 +1,75 @@ +// ローディング + +/** + * ローディングクラス + * @param {string} loading_elem_id ローディングのHTML要素 + */ +class Loading { + constructor(loadingElemId = '_loading') { + this.loadingElemId = loadingElemId; + // ロード中かどうか + this.isLoading = false; + } + + /** + * ローディングを開始する。
+ * 開始済みの場合と、ローディングの要素が見つからない場合は何もしない。 + */ + start() { + if (this.isLoading) + return; + + const loadingElem = document.getElementById(this.loadingElemId); + + if (loadingElem) { + this.isLoading = true; + loadingElem.style.display = 'block'; + } + } + + /** + * ローディングを停止する。
+ * 開始されていない場合と、ローディングの要素が見つからない場合は何もしない。 + */ + stop() { + if (!this.isLoading) + return; + + const loadingElem = document.getElementById(this.loadingElemId); + + if (loadingElem) { + this.isLoading = false; + loadingElem.style.display = 'none'; + } + } +} + + +/** + * ローダーを表示する + * @param {string} loadingElemId ローディング要素のID + */ +function showLoading(loadingElemId = '_loading') { + const loading = new Loading(loadingElemId); + loading.start(); +} + +// 汎用画面遷移 + +function transitionTo(link){ + // ローディング表示 + showLoading(); + location.href = link; + return false; +} + // 検索フォーム // 戻るボタンの関数 // 機能概要:メニュー画面に遷移する function backToMenu(){ + // ローディング表示 + showLoading(); location.href = "/menu/"; } @@ -224,8 +291,10 @@ function checkNumberOnlyForm($this) // メニューへボタンの関数 // 機能概要:マスターメンテメニュー画面に遷移する -function backToMainteMenu(){ +function backToMainteMenu(loadingElemId = '_loading'){ sessionStorage.clear(); + // ローディング表示 + showLoading(loadingElemId); location.href = "/masterMainte/masterMainteMenu"; } diff --git a/ecs/jskult-webapp/src/templates/_header.html b/ecs/jskult-webapp/src/templates/_header.html index 01a1521a..c2476734 100644 --- a/ecs/jskult-webapp/src/templates/_header.html +++ b/ecs/jskult-webapp/src/templates/_header.html @@ -8,6 +8,7 @@ + diff --git a/ecs/jskult-webapp/src/templates/_loading.html b/ecs/jskult-webapp/src/templates/_loading.html new file mode 100644 index 00000000..437c7e50 --- /dev/null +++ b/ecs/jskult-webapp/src/templates/_loading.html @@ -0,0 +1,5 @@ +
+
+ {{progress_message}} +
+
diff --git a/ecs/jskult-webapp/src/templates/bioSearchList.html b/ecs/jskult-webapp/src/templates/bioSearchList.html index 08302af9..e0950c20 100644 --- a/ecs/jskult-webapp/src/templates/bioSearchList.html +++ b/ecs/jskult-webapp/src/templates/bioSearchList.html @@ -198,10 +198,12 @@ - + {% for doctor_wrkplace_data in ultmarc.doctor_wrkplace_data %} {% if doctor_wrkplace_data.dcf_dsf_inst_cd %} - + {{doctor_wrkplace_data.dcf_dsf_inst_cd or ''}} {{doctor_wrkplace_data.inst_name_kanji or ''}} {{doctor_wrkplace_data.blng_sec_name or ''}} @@ -211,7 +212,7 @@ {% for doctor_wrkplace_his_data in ultmarc.doctor_wrkplace_his_data %} {% if doctor_wrkplace_his_data.dcf_dsf_inst_cd %} - + {{doctor_wrkplace_his_data.dcf_dsf_inst_cd or ''}} {{doctor_wrkplace_his_data.inst_name_kanji or ''}} {{doctor_wrkplace_his_data.blng_sec_name or ''}} @@ -225,6 +226,9 @@ - + + {% with progress_message = ''%} + {% include '_loading.html' %} + {% endwith %} \ No newline at end of file diff --git a/ecs/jskult-webapp/src/templates/docSearch.html b/ecs/jskult-webapp/src/templates/docSearch.html index dfedc2eb..e8d89083 100644 --- a/ecs/jskult-webapp/src/templates/docSearch.html +++ b/ecs/jskult-webapp/src/templates/docSearch.html @@ -35,7 +35,7 @@ -

-

{% if not mainte_csv_up.is_error_message_list_empty() %}
{% for error_message in mainte_csv_up.error_message_list %} @@ -203,5 +200,14 @@
{% endif %}

+ + + {% with progress_message = '処理中...しばらくお待ち下さい。'%} + {% include '_loading.html' %} + {% endwith %} + + {% with progress_message = '', id = '_loading_for_back' %} + {% include '_loading.html' %} + {% endwith %} diff --git a/ecs/jskult-webapp/src/templates/instInfo.html b/ecs/jskult-webapp/src/templates/instInfo.html index 00f8e9ab..6c1fa1ff 100644 --- a/ecs/jskult-webapp/src/templates/instInfo.html +++ b/ecs/jskult-webapp/src/templates/instInfo.html @@ -41,13 +41,13 @@ - + - +
@@ -86,6 +86,8 @@ }else{ $('#instSearch').attr('method', 'POST'); } + // ローディングを表示 + showLoading(); return true; } @@ -283,5 +285,9 @@
+ + {% with progress_message = ''%} + {% include '_loading.html' %} + {% endwith %} \ No newline at end of file diff --git a/ecs/jskult-webapp/src/templates/instSearch.html b/ecs/jskult-webapp/src/templates/instSearch.html index 32ca580c..ea1d55de 100644 --- a/ecs/jskult-webapp/src/templates/instSearch.html +++ b/ecs/jskult-webapp/src/templates/instSearch.html @@ -37,7 +37,7 @@ - + @@ -211,6 +211,8 @@ // ページ送りしたときにヘッダがずれるのを修正 FixedMidashi.remove(); FixedMidashi.create(); + // ページ送りしたときに施設情報ボタンを非活性化 + resultBtDisabled(); } }) }); @@ -232,7 +234,7 @@ let td = display_keys.map((key) =>{ let inner_content = data[key]; if(key=='dcf_dsf_inst_cd') - inner_content = `${data['dcf_dsf_inst_cd'] || ''}`; + inner_content = `${data['dcf_dsf_inst_cd'] || ''}`; if(key=='abolish_ymd' && data[key] != null) inner_content = '削除'; return `` @@ -281,9 +283,14 @@ vals.push( $(this).val() ); // 配列に値を追加 }); $("#inst_id").val(vals.join(',')); + // ローダー表示 + showLoading(); } - + +{% with progress_message = ''%} +{% include '_loading.html' %} +{% endwith %} \ No newline at end of file diff --git a/ecs/jskult-webapp/src/templates/maintlogin.html b/ecs/jskult-webapp/src/templates/maintlogin.html index 06f28098..6a3a7d71 100644 --- a/ecs/jskult-webapp/src/templates/maintlogin.html +++ b/ecs/jskult-webapp/src/templates/maintlogin.html @@ -13,7 +13,7 @@ Mainte Login

- +
@@ -21,5 +21,9 @@
+ + {% with progress_message = ''%} + {% include '_loading.html' %} + {% endwith %} \ No newline at end of file diff --git a/ecs/jskult-webapp/src/templates/masterMainteMenu.html b/ecs/jskult-webapp/src/templates/masterMainteMenu.html index 0abc4ec3..fe0f7a93 100644 --- a/ecs/jskult-webapp/src/templates/masterMainteMenu.html +++ b/ecs/jskult-webapp/src/templates/masterMainteMenu.html @@ -10,16 +10,17 @@

MeDaCA
マスターメンテメニュー



- 施設担当者データCSVアップロード

- + 施設担当者データCSVアップロード

- 施設担当者データCSVダウンロード

- + 施設担当者データCSVダウンロード

- テーブル上書きコピー

- + テーブル上書きコピー

-

メニューへ +

メニューへ + + {% with progress_message = ''%} + {% include '_loading.html' %} + {% endwith %} diff --git a/ecs/jskult-webapp/src/templates/menu.html b/ecs/jskult-webapp/src/templates/menu.html index 59eb8a74..8b920198 100644 --- a/ecs/jskult-webapp/src/templates/menu.html +++ b/ecs/jskult-webapp/src/templates/menu.html @@ -11,14 +11,14 @@

MeDaCA
機能メニュー



{% if menu.is_available_ult_doctor_menu() %} - Ultmarc照会(医師)

+ Ultmarc照会(医師)

{% endif %} {% if menu.is_available_ult_inst_menu() %} - Ultmarc照会(施設)

+ Ultmarc照会(施設)

{% endif %} {% if menu.is_available_bio_menu() %} {% if not menu.is_batch_processing() %} - 生物由来データ参照

+ 生物由来データ参照

{% else %}
生物由来データ参照は
日次バッチ処理中のため利用出来ません
{% endif %} @@ -29,10 +29,14 @@ {% elif menu.is_backup_processing() %}
バックアップ取得を開始しました。
日次バッチ更新が終了するまでマスターメンテメニューは利用できません
{% else %} - マスターメンテメニュー

+ マスターメンテメニュー

{% endif %} {% endif %} -

Logout +

Logout + + {% with progress_message = ''%} + {% include '_loading.html' %} + {% endwith %} diff --git a/ecs/jskult-webapp/src/templates/tableOverride.html b/ecs/jskult-webapp/src/templates/tableOverride.html index 40c69255..b5fe6a58 100644 --- a/ecs/jskult-webapp/src/templates/tableOverride.html +++ b/ecs/jskult-webapp/src/templates/tableOverride.html @@ -11,7 +11,7 @@ function Form_Submit_Disp_Dialog(){ var msg = "ダミー従業員担当施設マスタのデータがすべて上書きされます。よろしいですか?" if (confirmDialog(msg)) { - document.getElementById("loading").style.display = "block"; + showLoading(); document.getElementById("overRided").style.display = "none"; } else { return false; @@ -25,7 +25,7 @@
${inner_content || ''}
- +

テーブル上書きコピー

@@ -53,9 +53,13 @@
ダミー従業員担当施設マスタのデータを本番従業員担当施設マスタのデータで上書きしました

{% endif %} - - + + {% with progress_message = 'データ上書き中...しばらくお待ち下さい。'%} + {% include '_loading.html' %} + {% endwith %} + + {% with progress_message = '', id = '_loading_for_back' %} + {% include '_loading.html' %} + {% endwith %}