79bea6acb0ac13cf3eb3a8908460226ea3f7f53b.js 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. System.register(["cc"], function (_export, _context) {
  2. "use strict";
  3. var _cclegacy, _crd;
  4. return {
  5. setters: [function (_cc) {
  6. _cclegacy = _cc.cclegacy;
  7. }],
  8. execute: function () {
  9. _crd = true;
  10. _cclegacy._RF.push({}, "80ebbBz8etB5qijWdYrU2HH", "DateExt", undefined);
  11. /** 格式化时间字符串 */
  12. Date.prototype.format = function (format) {
  13. var year = this.getFullYear();
  14. var month = this.getMonth() + 1;
  15. var day = this.getDate();
  16. var hours = this.getHours();
  17. var minutes = this.getMinutes();
  18. var seconds = this.getSeconds();
  19. return format.replace('yy', year.toString()).replace('mm', (month < 10 ? '0' : '') + month).replace('dd', (day < 10 ? '0' : '') + day).replace('hh', (hours < 10 ? '0' : '') + hours).replace('mm', (minutes < 10 ? '0' : '') + minutes).replace('ss', (seconds < 10 ? '0' : '') + seconds);
  20. };
  21. _cclegacy._RF.pop();
  22. _crd = false;
  23. }
  24. };
  25. });
  26. //# sourceMappingURL=79bea6acb0ac13cf3eb3a8908460226ea3f7f53b.js.map