diff --git a/demo/demolist/Demo26.js b/demo/demolist/Demo26.js deleted file mode 100644 index 6694406..0000000 --- a/demo/demolist/Demo26.js +++ /dev/null @@ -1,257 +0,0 @@ -/** -* -* @title 简单表格、文字过长,两种tip -* 【Tooltip】 -* @description -*/ - -import React, { Component } from "react"; -import Button from "bee-button"; -import Tooltip from "bee-tooltip"; -import Table from "../../src"; - -const columns = [ - { - title: "序号", - dataIndex: "index", - width: 50, - key: "index", - render(text,record,index){ - return( - {index + 1} - ) - } - }, - { - title: "订单编号", - dataIndex: "ebeln", - key: "ebeln", - width: 100, - className:'text-center',//列内容居中 - onCellClick: (record) => this.cellClick(record, false), - render(text,record,index){ - return( - {text} - ) - } - }, - { - title: "供应商编码", - width: 80, - dataIndex: "lifnr", - key: "lifnr", - className:'text-center', - }, - { - title: "供应商名称", - //width: 250, - dataIndex: "lifnrName", - className: "text-ellipsis",//溢出省略号,写了溢出省略号必须加上下面的render - key: "lifnrName", - render(text,record,index){ - return( - {text}//title是鼠标放上去显示所有的内容 - ) - } - }, - { - title: "订单类型", - width: 150, - dataIndex: "bsart", - key: "bsart", - render(text,record,index) { - return text=='NB'?'标准采购订单':(text=='YB'?'直发工地采购订单':(text=='Z100'?'跨公司重机采购6.0':(text=='ZCB'?'非生产材料领料单':(text=='ZDB'?'D02领料单':(text=='ZEB'?'配送转储采购订单':(text=='ZFB'?'维修采购订单':(text=='ZLB'?'网购订单':(text=='ZMB'?'委托加工采购订单':(text=='ZRB'?'退货采购订单':(text=='ZWB'?'工序外协采购订单':(text=='ZTB'?'紧急订单':(text=='ZWB'?'工序外协采购订单':(text=='UB'?'转储采购订单':''))))))))))))) - } - }, - { - title: "采购组织", - width: 80, - dataIndex: "ekorg", - key: "ekorg", - className:'text-center', - }, - { - title: "采购组", - width: 60, - dataIndex: "ekgrp", - key: "ekgrp", - className:'text-center', - }, - { - title: "凭证日期", - dataIndex: "bedat", - width: 80, - key: "bedat", - className:'text-center', - render(text,record,index) { - return moment(text).format('YYYY-MM-DD') - } - }, - { - title: "一级审批", - dataIndex: "frgc1", - width: 80, - key: "frgc1", - className:'text-center' - }, - { - title: "二级审批", - dataIndex: "frgc2", - width: 80, - key: "frgc2", - className:'text-center' - }, - { - title: "审批状态", - dataIndex: "frgrl", - width: 80, - key: "frgrl", - className:'text-center', - render(text,record,index) { - return text?(text=='X'?'未审批':''):'已审批' - } - }, - { - title: "确认状态", - dataIndex: "confirmResult", - width: 80, - key: "confirmResult", - className:'text-center', - render(text,record,index) { - return text?(text=='1'?'已确认':'拒绝'):'未确认' - } - }, - { - title: "确认人", - dataIndex: "confirmUsername", - width: 150, - key: "confirmUsername", - className: "text-ellipsis",//溢出省略号,写了溢出省略号必须加上下面的render - render(text,record,index){ - return( - {text}//title是鼠标放上去显示所有的内容 - ) - } - }, - { - title: "确认时间", - dataIndex: "confirmDate", - width: 80, - key: "confirmDate", - className:'text-center', - render(text,record,index) { - return text?moment(text).format('YYYY-MM-DD hh:mm:ss'):'' - } - }, - { - title: "关闭状态", - dataIndex: "elikz", - width: 80, - key: "elikz", - className:'text-center', - render(text,record,index) { - return text?(text=='X'?'已关闭':''):'未关闭' - } - }, - { - title: "沟通", - dataIndex: "gt", - width: 80, - key: "gt", - className:'text-center', - render:(text,record,index)=>{ - return ( - { - this.getContent({"orderType":"purchase","ebeln":record.ebeln}) - } - } - modalContent={ - ( -
- - - - - {record.ebeln} - - - - - - {record.lifnr} - - - - - - {record.lifnrName} - - - -
- {this.state.feedbacks.map((item,index)=>{ - return ( -

- 【{item.feedbackUsername}】 - {item.feedbackContent} - {moment(item.feedbackDate).format('YYYY-MM-DD HH:MM:SS')} -

- ) - })} -
- - - 反馈内容必填 - - -
- ) - - }> - -
- ) - } - } -]; - -const data = [ - { a: "令狐冲", b: "男", c: 41, d: "操作", key: "1" }, - { a: "杨过叔叔的女儿黄蓉", b: "男", c: 67, d: "操作", key: "2" }, - { a: "郭靖", b: "男", c: 25, d: "操作", key: "3" } -]; - -class Demo1 extends Component { - - constructor(props){ - super(props); - this.state = { - data: [], - selectedRowIndex: 0 - } - } - - render() { - return ( - { - this.setState({ - selectedRowIndex: index - }); - }} - /> - ); - } -} - -export default Demo1;