EasyUI Forum
May 06, 2024, 06:13:50 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
  Home Help Search Login Register  
  Show Posts
Pages: [1]
1  General Category / EasyUI for Vue / Re: Expander layout on: September 08, 2019, 02:36:40 AM
https://www.jeasyui.com/demo-vue/components/layout/expander.vue
haha thanks

i was check this morning and i see this

thanks all
2  General Category / EasyUI for Vue / Expander layout on: August 23, 2019, 01:41:23 AM
How to set layout expander, like react demo
3  General Category / EasyUI for Vue / Event in switchbutton on: August 14, 2019, 09:49:39 PM
what the event of swithbutton?
i want to change switchbutton using other switchbutton
4  General Category / EasyUI for jQuery / CREATE MUTLRIGROUP ON DATAGRID [I HOPE CAN HELP] on: June 21, 2019, 08:09:13 AM
I try to create multiple group in some datagrid

git@github.com:lutungp/datagrid-groupview.git
5  General Category / EasyUI for React / How to using method in event or from initial component on: May 05, 2019, 11:46:07 PM
i;m confused to use method get panel to check already tabpanel inside Tabs, by some function
6  General Category / EasyUI for React / Re: dynamically add tab panel using reactJs on: April 07, 2019, 04:49:32 PM
wuww ok thank you sir, i have problem with setstate. but i can fix it.
thanks you veey much
7  General Category / EasyUI for React / Re: dynamically add tab panel using reactJs on: April 06, 2019, 01:30:31 AM
thanks for your answer, and I was follow your code  Smiley
Code:
import React, { Component } from 'react';
import { Tabs, TabPanel } from 'rc-easyui';
import { render } from 'react-dom';

var data = [];
class TabContent extends Component {

  constructor(props){
    super(props);
    this.state = {
        data: [
          {
            title: 'Tab1',
            content: 'Content1'
          },{
            title: 'Tab2',
            content: 'Content2'
          },{
            title: 'Tab3',
            content: 'Content3'
          }
        ]
    };
  }


  handleAddTab(elem) {
      /* action ketika action menu true */
      this.state = {
          data: [
            {
              title: 'Tab1',
              content: 'Content1'
            },{
              title: 'Tab2',
              content: 'Content2'
            },{
              title: 'Tab3',
              content: 'Content3'
            },{
              title: 'Tab4',
              content: 'Content4'
            }
          ]
      };
  }

  render() {
    return (
        <Tabs id="tabpanel" scrollable style={{ width: '100%', height: '100%' }} justified>
        {
          this.state.data.map((tab,index) => (
            <TabPanel key={index} {...tab}>...</TabPanel>
          ))
        }
        </Tabs>
    );
  }
}

module.exports = TabContent;

Sorry this is my code. I'am new in react
handleAddTab is function will called from my sidebar file, I try to change data array with new data but its not got effect on my tabpanel

And, Please give me scrypt for render from other file imported on this tabpanel, Thank you very much
8  General Category / EasyUI for React / [SOLVED] dynamically add tab panel using reactJs on: April 04, 2019, 04:11:30 AM
i build application using reactJs and EasyUi using meteorJs framework.
i create dynamic sidebar menu with tree. but i'am very confused how to add new tab using on click event i build.
Pages: [1]
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!