原创 高德 自定義覆蓋物 信息窗體,站點名稱顯示;
效果圖,數據需自己模擬; val = { name: 'xxx城市', position: [123.34534566,41.423443] } let marker = new AMap.Marker({
原创 angular 上傳Excel
import { FileUploader } from 'ng2-file-upload'; this.uploader = new FileUploader({ url: this.importExcelUrl,
原创 關於new Date()獲取當前時間
在我們使用new Date() 想要獲取當前時間時,但是格式不是我們想要的,比如格式爲 年-月-日,可以使用如下方法: const date = new Date(); const current_date = date.getD
原创 Angular 模擬數據 及 表頭
首先創建一個json文件,格式如下: { "data": [ { "id": 1, "name": "Alice", "age" : "16",
原创 Angular 文件上傳
下面做的是Angular 實現文件上傳的一個小功能。 首先在你所需要用到的ts中導入: import { DomSanitizer } from '@angular/platform-browser'; 在constructor()中