eventEdit: {
autoClose:false,
startDateConfig:{style:"flex: 1 0 70%;",label:vm.$data.startDateName},
startTimeConfig:{style:"flex: 1 0 30%;"},
endDateConfig:{style:"flex: 1 0 70%;",label:vm.$data.endDateName},
endTimeConfig:{style:"flex: 1 0 30%;"},
extraWidgets: createExtraWidgets(),
showResourceField:false//Resource
},
function createExtraWidgets() {
var widgetsIndex = 7;
var extraWidgets =[
{
type: '[b]checkbox[/b]',
text: '日単位',
name: 'unitDay',
Support Forum
https://www.bryntum.com/docs/scheduler/#Common/widget/Checkbox
Hello Tomy,
We don't have a special guide of how to subclass our components and implement custom logic, but all our sources are the guide in this case. You can look at Checkbox class for example. It extends Field class which extends Widget. Radio field behavior is quite similar to checkbox, so you can copy the Checkbox class as a base and start changing it to make it a radio field. I've created a small proof of concept which shows how it can be implemented and a small demo which shows the usecase (see the attachment). Feel free to copy it to your project and start changing it to get what you need. Also I've created a feature request to have Radio field in our sources one day. Here is the ticket: https://app.assembla.com/spaces/bryntum/tickets/8744-create-radio-field-component/details
Best,
Pavel
We don't have a special guide of how to subclass our components and implement custom logic, but all our sources are the guide in this case. You can look at Checkbox class for example. It extends Field class which extends Widget. Radio field behavior is quite similar to checkbox, so you can copy the Checkbox class as a base and start changing it to make it a radio field. I've created a small proof of concept which shows how it can be implemented and a small demo which shows the usecase (see the attachment). Feel free to copy it to your project and start changing it to get what you need. Also I've created a feature request to have Radio field in our sources one day. Here is the ticket: https://app.assembla.com/spaces/bryntum/tickets/8744-create-radio-field-component/details
Best,
Pavel
- Attachments
-
- demo.zip
- (1.72 KiB) Downloaded 134 times
-
- Radio.js.zip
- (5.08 KiB) Downloaded 143 times
Pavlo Miklashevych
Sr. Frontend Developer