2018年11月14日 星期三

JSF 轉換器及驗證器介紹

介紹如何使用 JSF 的轉換器及驗證器, 顯示並驗證表單的資料. 此外, 也介紹如何停用(disable)及繞過(pass by)驗證器轉跳其他頁面

全文: https://hychen39.github.io/jsf_teaching/2018/11/15/JSF_Unit08.html

2018年10月31日 星期三

2018年10月23日 星期二

Show the message generated from the PL/SQL process

We need to show the messages from the PL/SQL process (back-end) to the user (front-end) very often.

One way is to use the global variable APEX_APPLICATION.G_PRINT_SUCCESS_MESSAGE. The Apex will shows the message in the upper right corner with the green box. The method is suitable for showing information that doesn’t need the user to interact with.

The second way is to use APEX_ERROR.ADD_ERROR procedure to add the message to the error stack. When loading the page, the Apex will show these messages. We can specify the locations of showing the messages either on the upper right corner or associate with pages items or event an error page. However, the APEX_ERROR.ADD_ERROR procedure will interrupt the request processing process such that the codes after the APEX_ERROR.ADD_ERROR will not be executed. The method is appropriate for the form validation.

This article presents another way to show the message from the PL/SQL process. We use the Application Item to store the message from the PL/SQL process. There is a Application Process executing on the page loading to show the message in the Application Item using the JS functions in the apex.message namespace.

See the full article: https://hychen39.github.io/oracle_apex/2018/10/17/apex_messages_app_item.html

2018年9月29日 星期六

使用 Maven 匯出 Apex Application file 到本地端電腦

Export Oracle Apex Application from remote to local computers using Maven

Abstract
Oracle Apex application needs to be exported as a sql file from the Workspace in order to deploy to another workspace. Other than exporting manually, this article introduces an automatic way to export the Apex file and copy it to the local computer by using Maven. The automation enables automated build and release process.

Full article:
https://hychen39.github.io/oracl_apex/2018/08/29/export_apex_app_maven.html


2018年9月21日 星期五

PDF Utilities

Here two utilities that let us merge pdf files and add page numbers to the merged file. And, the best part is that we don't need the Acrobat to do that.

PDFSAM: Merge multiple pdf files
A PDF Number: Add page numbers to your pdf file.


2018年6月21日 星期四

解決 Markdown Preview Enhanced 產生的 HTML 文件中 side toc 不見的方法


VSCode 的 Markdown Preview Enhanced plugin 可以將 Markdown 文件轉成 HTML 文件. 在生成的 HTML 文件中左邊會有目錄做為導覽.

但是如果 markdown-preview-enhanced.enableScriptExecution 的設定沒有設為 ture, 則
- 生成的 HTML 中沒有左邊導覽
- 在 VSCode preview 時, 無法看見 CSS 的效果


markdown-preview-enhanced.enableScriptExecution 設為 true 就可以解決此問題.

2018年1月19日 星期五

使用 awk 來抽離 csv 檔案中的部分欄位

misc_technique
使用 awk 來抽離 csv 檔案中的部分欄位
gawk -F, '{OFS=","} {print $1, $2}' 4c-students.csv  > 4c-stud-import.csv
會將 4c-students.csv 中的第一及第二 column 抽離出來, 並以逗號作為分隔字元. OFS (Output File Separator) 是內建的變數, 設定輸出時使用的分隔字元.
參考: