2019年8月19日

摘要: Echarts关系图实战效果图 第一步: 下载echarts(4.1.0)和ngx-echarts(4.1.0)的依赖包,在angular.json中引入echarts.js,在公共模块中引入 第二步: html页面:<div style="height: 450px" echarts [optio 阅读全文

posted @ 2019-08-19 17:01 65207光 阅读(1394) 评论(0) 推荐(1)


2019年8月5日

摘要: echarts关系图: 一:引入 1.下载依赖包 echarts-4.1.0 ngx-echarts-3.0.0 2.引入echarts基础JS 在angular.json中 3.在模板文件中引入 4.在component.ts中创建关系图 靠后台返回的数据来绘制拓扑图,data和links都设置为 阅读全文

posted @ 2019-08-05 17:55 65207光 阅读(345) 评论(0) 推荐(0)


2019年7月29日

摘要: 一:js怎么判断字符串是否为全数字 1.正则判断 var str='1234' if(/^[0-9]+$/.test(str)){//这是用正则表达式检查 alert('全部是数字'); }else { alert('非纯数字'); } /^[0-9]+\.?[0-9]+?$/ //小数的正则表达式 阅读全文

posted @ 2019-07-29 10:46 65207光 阅读(213) 评论(0) 推荐(0)


2019年7月5日

摘要: 一:angular7中配置关系 1.路由: 主路由:app-routing.module.ts { path: 'classified-protection', loadChildren: './classified-protection/classified-protection.module#C 阅读全文

posted @ 2019-07-05 16:50 65207光 阅读(222) 评论(0) 推荐(0)


2019年7月4日

摘要: 一:Angular7中的表单验证 Angular7中有一个验证表单的服务,在需要验证的component中引入 import { FormBuilder , FormGroup , Validators } from '@angular/forms'; FormGroup : 1.FormContr 阅读全文

posted @ 2019-07-04 18:02 65207光 阅读(369) 评论(0) 推荐(0)

摘要: 一:项目需要加一个树形的下拉框 效果图: 于是开始动手写,按照ztree官方API一步步配置,最后发现没有复选框,经过百度发现是没有引入js 1.npm i ztree -S 2.在angular.json中加入"node_modules/ztree/js/jquery.ztree.all.js", 阅读全文

posted @ 2019-07-04 12:10 65207光 阅读(2231) 评论(0) 推荐(0)


博客园  ©  2004-2026
浙公网安备 33010602011771号 浙ICP备2021040463号-3