Bug687修正(日付指定に値非対応時エラー表示ないBug)
This commit is contained in:
@@ -56,7 +56,10 @@ export class DateSpecifiedAction implements IAction {
|
||||
let verNameGetValue = getContextVarByPath(context.variables,this.props.verNameGet);
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//取得変数の値Dateオブジェクトに変換:
|
||||
let dateObj = new Date(verNameGetValue);
|
||||
let dateObj = new Date(verNameGetValue);
|
||||
if(verNameGetValue === undefined || verNameGetValue === null || verNameGetValue === '' || isNaN(dateObj.getDate())){
|
||||
throw new Error("Invalid time value");
|
||||
}
|
||||
// 年の設定(newYearが設定されていない場合は、元の値を使用)
|
||||
dateObj.setFullYear(this.props.newYear >=1900 && this.props.newYear <=9999 ? this.props.newYear : dateObj.getFullYear());
|
||||
// 月の設定(newMonthが設定されていない場合は、元の値を使用)// 月は0始まりなので、12月は11。
|
||||
|
||||
Reference in New Issue
Block a user