Giter Site home page Giter Site logo

[BUG]DEMO里面的组合式写法,表格全部是空,且目前我运用在项目里 也出现了表格渲染不出来的问题 about gantt HOT 8 CLOSED

RanRuan avatar RanRuan commented on May 24, 2024
[BUG]DEMO里面的组合式写法,表格全部是空,且目前我运用在项目里 也出现了表格渲染不出来的问题

from gantt.

Comments (8)

xpyjs avatar xpyjs commented on May 24, 2024

paste your code pls?

from gantt.

RanRuan avatar RanRuan commented on May 24, 2024

paste your code pls?

[
gantt-master.zip
](url)

from gantt.

RanRuan avatar RanRuan commented on May 24, 2024

paste your code pls?
gantt-master.zip

from gantt.

xpyjs avatar xpyjs commented on May 24, 2024

paste minimum reproduction code, not zip. I can see it in here

from gantt.

RanRuan avatar RanRuan commented on May 24, 2024
<template>
  <div class="gantt-wrap">
    <x-gantt
      data-id="index"
      :data="ganttData"
      header-height="48"
      :row-height="30"
    >
      <x-gantt-column label="事项" prop="name"></x-gantt-column>
    </x-gantt>
  </div>
</template>

<script lang="ts" setup>
import { reactive, ref, onMounted } from 'vue';
const ganttData = reactive([
{
    "index": 2,
    "name": "t1",
    "startDate": new Date('2022-01-24'),
    "endDate": new Date('2022-07-24'),
    "o": {
        "t1": "a",
        "t2": "b"
    },
    "children": [
        {
            "index": 51,
            "name": "sub-t51",
            "startDate": new Date('2022-01-27'),
            "endDate": new Date('2022-02-24'),
            "progress": 0.8,
            "o": {
                "t1": "a",
                "t2": "b"
            }
        },
        {
            "index": 52,
            "name": "sub-t52",
            "startDate":new Date('2022-03-27'),
            "endDate": new Date('2022-04-27'),
            "progress": 0.5,
            "o": {
                "t1": "a",
                "t2": "b"
            },
            "children": [
                {
                    "index": 53,
                    "name": "sub-sub-t53",
                    "startDate": new Date('2022-06-27'),
                    "endDate": new Date('2022-06-28'),
                    "progress": 0.3333333333,
                    "o": {
                        "t1": "a",
                        "t2": "b"
                    }
                }
            ]
        }
    ]
}

]);</script>

from gantt.

RanRuan avatar RanRuan commented on May 24, 2024

paste minimum reproduction code, not zip. I can see it in here

When the length of ganttData is equal to 1, it displays blank.
image

from gantt.

RanRuan avatar RanRuan commented on May 24, 2024

paste minimum reproduction code, not zip. I can see it in here

I found in the source code src\composables\useInView.ts,line 14 :

  // 预加载条数
  const preload = 5;

from gantt.

jeremyjone avatar jeremyjone commented on May 24, 2024

看到了代码,运行了一下,结果如下图:

image

并没有你说的问题。

1、检查你的代码
2、确保已经升级到最新版本

paste minimum reproduction code, not zip. I can see it in here

I found in the source code src\composables\useInView.ts,line 14 :

  // 预加载条数
  const preload = 5;

这个预加载是为了防止滚动时出现白屏,和你说的问题没有关系

from gantt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.