Comments (4)
感谢🙏
点击当前格子, 会触发scheduleClick
事件,该事件接受一个包含日期信息的参数。说明文档里面有写。
<Gantt @scheduleClick=""/>
from vue3-gantt.
比如在6.30-7.5的日程里,点击7.2 或7.3的时候拿到的日期,一直是第一个格子的日期,
{type: 'works', date: '2023-06-30', width: 550, left: 0, id: '1674344695524532226', …}
from vue3-gantt.
当前甘特图会将日程信息 的格子合成一个,所以获取日程内具体点击的信息会有一些难度。
我这边刚刚更新了vue3-gantt
版本 #21
你先更新一下依赖到最新版本1.1.8-3
😊。
然后最新的 scheduleClick 点击事件 参数中包含了原始的event 信息(这也是1.1.8-3
更新的 内容),你可以通过 offsetX
属性获取点击的横向坐标。
days
是一个数组,包含了当前块的所有日期,结合这两个属性,可以快速计算出当前点击坐标所代表的具体日期。
如果还有疑问,欢迎继续提问,非常感谢你的支持❤️
from vue3-gantt.
好的,非常感谢.
from vue3-gantt.
Related Issues (15)
- two bugs HOT 5
- 报错,无法显示 HOT 4
- 根据readme文件上的配置,数据渲染不出来? HOT 2
- 支持子项目显示吗? HOT 1
- 支持TS吗 HOT 1
- 请问可以支持树型结构么 HOT 1
- 支持树形结构的数据吗? HOT 1
- 可以支持横坐标拖拽和纵坐标拖拽吗
- 日期可以支持第一行为年-月-日,第二行为时,并支持拖拽
- October saws only 30th days HOT 1
- install HOT 1
- 请问可以在指定日期添加竖线标记吗 HOT 2
- 是否可以支持直接CDN在浏览器中使用呢 HOT 2
- 当schedule为单个日期且在表格最后一列时显示不正常 HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vue3-gantt.