随笔分类 -  前端-工作篇-react工作

前端-react工作
摘要:1接口调用 /*调用接口*/ created() { /*动态渲染content_type接口*/ getAction("/dict/list",{ dict_code:"content_type" }).then(res=>{ this.content_type=res.data }) /*动态渲 阅读全文
posted @ 2022-10-07 18:44 前端导师歌谣 阅读(9) 评论(0) 推荐(0) 编辑
摘要:import React, { Component } from 'react'; class List extends Component { constructor(props) { super(props); } render() { return <div>1111</div>; } } e 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(52) 评论(0) 推荐(0) 编辑
摘要:<div style={{ textAlign: 'center' }}> <Button type="primary" style={{ marginRight: '10px' }}> 保存 </Button> <Button>取消</Button> <Button type="primary" 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(20) 评论(0) 推荐(0) 编辑
摘要:boothActivityCode: this.props.location.query.code || '', 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(29) 评论(0) 推荐(0) 编辑
摘要:this.setState({ pageIndex: 1, pageSize: 10, }); 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(20) 评论(0) 推荐(0) 编辑
摘要:Uncaught Error: Reducer "index" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(32) 评论(0) 推荐(0) 编辑
摘要:<Col span={8} key={index}> <Form.Item label={item.label} {...formItemLayout}> {getFieldDecorator(`${item.paramsName}`, {})( item.isRangePicker ? ( <Ra 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(61) 评论(0) 推荐(0) 编辑
摘要:<p> {moment(boothDetails.startTime).format('YYYY-MM-DD')}到 {moment(boothDetails.endTime).format('YYYY-MM-DD')} </p> 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(100) 评论(0) 推荐(0) 编辑
摘要:Warning: Each record in table should have a unique `key` prop,or set `rowKey` to an unique primary key. rowKey="code" pageIndex={pageIndex} pageSize={ 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(223) 评论(0) 推荐(0) 编辑
摘要:ilter() 方法创建一个新的数组,新数组中的元素是通过检查指定数组中符合条件的所有元素。 注意: filter() 不会对空数组进行检测。 注意: filter() 不会改变原始数组。 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(32) 评论(0) 推荐(0) 编辑
摘要:{ title: '状态', dataIndex: 'status', render: (text, row) => { let arr = ['', '未开始', '进行中', '已结束', '已作废']; return <span>{arr[text]}</span>; }, }, 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(44) 评论(0) 推荐(0) 编辑
摘要:react生命周期1.1.constructor() constructor()中完成了React数据的初始化,它接受两个参数 :props和context,当想在函数内部使用这两个参数时 ,需使用super()传入这两个参数。 注意:只要使用了constructor()就必须写super() ,否 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(19) 评论(0) 推荐(0) 编辑
摘要:{ title: '状态', dataIndex: 'status', render: (text, row) => { let arr = ['', '未开始', '进行中', '已结束', '已作废']; return <span>{arr[text]}</span>; }, }, 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(34) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(26) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(13) 评论(0) 推荐(0) 编辑
摘要:componentWillReceiveProps componentWillReceiveProps# void componentWillReceiveProps( object nextProps ) 当props发生变化时执行,初始化render时不执行,在这个回调函数里面, 你可以根据属性 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(43) 评论(0) 推荐(0) 编辑
摘要:{getFieldDecorator('activityTimeStamp', { rules: [{ required: true, message: '请选择活动时间' }], initialValue: [ moment(updateDataSource.startTime), moment( 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(164) 评论(0) 推荐(0) 编辑
摘要:this.props.form.validateFieldsAndScroll((err, values) => {} values可以对应表单的值 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(157) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(6) 评论(0) 推荐(0) 编辑
摘要:react项目中接口未能执行从dva.js上面找问题 阅读全文
posted @ 2022-07-23 22:31 前端导师歌谣 阅读(39) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示