Updated 066 The new fields Area to make things easier (markdown)
parent
03a2fedbd3
commit
10a0512a2e
@ -26,30 +26,32 @@ What had been done? We removed this XML definition and we have replaced it with
|
||||
|
||||
[00:05:00](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m00s)
|
||||
|
||||
What we did and I can show you a little peek of that. It will be in version 2.7.6. If you have watched this video after those releases you possibly already have it. You click on New, this is New implementation for the Custom Fields and also for Custom user. You click on it, it will take the PHP and adds it to it's own little text area. Now you can easily follow and adapt the getOptions method PHP values. That's [00:05:40](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m40s) quite more convenient I suppose then using one line at a time. If we look at the user, you have two fields then, one for he getExclude method and one for the getGroup method. They are also immediately available to you.
|
||||
Just a little peek of what has been done. It will be in version 2.7.6. If you have watched this video after those releases you possibly already have it. Click on New, this is New implementation for the Custom Fields and also for Custom user. You click on it, it will take the PHP and adds it to its own little text area. Now you can easily follow and adapt the 'getOptions' method PHP values. That is [00:05:40](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h05m40s) quite more convenient I suppose than using one line at a time. If we look at the user, you have two fields then, one for he 'getExclude' method and one for the 'getGroup' method. They are also immediately available to you.
|
||||
|
||||
### Advantage - Extra Properties Options - Listclass Option
|
||||
|
||||
[00:06:05](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m05s)
|
||||
|
||||
The other advantage with this implementation is, we have this new Extra properties option which has been available in JCB for some time. Many of you may not know that it exists. There is what we call listclass. If you want to add a class like a CSS class value to the field when it appears in the list area. [00:06:29](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m29s) Let me show you this area(see video), this is the list area. Well any of the views where you see a list of items and you want this specific value to have a specific CSS class value. Because maybe you want to style it somewhat different. Then you have this option to use. All you need to do is [00:06:53](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m53s) click listclass and you add there my-class-dean. Whatever you want to call it. It will add that the class to the [00:07:15](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m15s) field in the list area which is quite stunning.
|
||||
The other advantage with this implementation is, we have this new Extra properties option which has been available in JCB for some time. Many of you may not know that it exists. There is what we call 'listclass'. If you want to add a class like a CSS class value to the field when it appears in the list area. [00:06:29](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m29s) Let me show you this area(see video), this is the list area. Well any of the views where you see a list of items and you want this specific value to have a specific CSS class value because maybe you want to style it somewhat different. Then you have this option to use. All you need to do is [00:06:53](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h06m53s) click 'listclass' and you add there 'my-class-dean'. Whatever you want to call it. It will add that the class to the [00:07:15](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m15s) field in the list area which is quite stunning.
|
||||
|
||||
### Escape Option
|
||||
|
||||
[00:07:19](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h07m19s)
|
||||
|
||||
There is also the Escape Option. If you escape a value, all the values are escaped by default. If you want a value not to be escaped because you are going to have values in it, which if it's escaped, it gets stripped like a span tag and stuff like that. You could say false and then the specific fields. Now when I say escaped, I mean in the list area, again this area. When there is a list value. Then this is a being escaped at the moment. If you don't want that done, then you add this false escaped.
|
||||
There is also the 'Escape' Option. If you escape a value, all the values are escaped by default. If you want a value not to be escaped because you are going to have values in it, which if it's escaped, it gets stripped like a span tag and stuff like that. You could say: 'false' and then the specific fields. Now when I say escaped, I mean in the list area, again this area. When there is a list value. Then this is a being escaped at the moment. If you do not want that done, then you can add this false escaped.
|
||||
|
||||
### Display Option
|
||||
|
||||
[00:08:06](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m06s)
|
||||
|
||||
The other option which is also available. It is the Display option. We'll still add some more documentation to this. But it's about when the field gets displayed in a config, it's when a component have a let me see this options area. You can add Fields to that option area. When a field is added to the option area, it has implementation structures. You can let it show in the menu, you can let it show in various [00:08:43](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m43s) places. I'll make a tutorial about this specifically. But just to show you quickly that that is also are available.
|
||||
The other option which is also available. It is the 'Display option'. We will still add some more documentation to this, but it is about when the field gets displayed in a config, it is when a component have this options area. You can add Fields to that option area. When a field is added to the option area, it has implementation structures. You can let it show in the menu, you can let it show in various places.[00:08:43](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m43s) I will make a tutorial about this specifically. But just to show you quickly that that is also are available.
|
||||
|
||||
### Validate Option
|
||||
|
||||
[00:08:53](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h08m53s)
|
||||
|
||||
Last but not least, Validate. Not all fields have the property to validate the value. There are Validation Rules. You can add a validation to this field, if that property is not available in the field type, which you have selected. If it is, we would suggest that you add it to the properties at the top. It says that, if you have a validation set as a field property, this extra property will not be needed because you can just use that one. [00:09:33](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m33s)
|
||||
Last but not least,there is 'Validate'. Not all fields have the property to validate the value. There are Validation Rules. You can add a validation to this field, if that property is not available in the field type, which you have selected. If it is, we would suggest that you add it to the properties at the top. It says that, if you have a validation set as a field property, this extra property will not be needed because you can just use that one. [00:09:33](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h09m33s)
|
||||
|
||||
That was a quick demonstration of the new field area. We trust that it will be as easy and as comfortable as we hoped it would be. Trust that this change would not frustrate you, but be great. Because of the reason, for example one of the unforeseen [00:10:00](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m00s) outcomes, as if you have a field like this which already has all its values. You are thinking on changing it and you say, let me just check how will the text look. You can change it and it really adds all your text value with its defaults. If you say no I want to go back, you can click back, and lo and behold your old values [00:10:25](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m25s) are again been added to the page. The values that were there originally. That is even true if you were to remove a specific property. Then you want to add it back, it adds the original value back, was what we intended because by accident [00:10:48](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m48s) you might remove it and want to just put it back. It should be as easy as that. You could still go to Type Info to see what could be the default values and adapt them. It's not like you don't have access to the default values, it's just that we want to [00:11:10](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h11m10s) recover your current saved value for you. Whenever you add another field which isn't already here, this drop down list only shows the fields that are not already on the page. You won't end up adding fields properties the second time. It has become much more easier to build fields and its properties [00:11:39](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h11m39s) as before. You really had to navigate through some of the complexities of dealing with an XML set of values. Which maybe some of you don't even know exactly what's going on. Those of you that do, I mean it's not like you're losing any advantage with the new implementation, [00:12:02](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h12m02s) you are still targeting that value with any value you want. It's still as easy as clicking a plus and selecting a value and adding it. I do hope that all of you will be as excited about this change as we are . We are now at the point where making JCB easy-to-use is also a priority.
|
||||
That was a quick demonstration of the new field area. We trust that it will be as easy and as comfortable as we hoped it would be. Trust that this change would not frustrate you, but be great. Because one of the unforeseen [00:10:00](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m00s) outcomes for example may be, if you have a field like this which already has all its values and you are thinking on changing it and say, let me just check how will the text look. You can change it and it really adds all your text value with its defaults. If you say no, I want to go back, you can click back, and your values which were there originally has [00:10:25](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m25s) again been added to the page. That is even true if you were to remove a specific property. <<<<<<<<<<<<<<<<<<<
|
||||
|
||||
Then you want to add it back, it adds the original value back, was what we intended because by accident [00:10:48](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h10m48s) you might remove it and want to just put it back. It should be as easy as that. You could still go to Type Info to see what could be the default values and adapt them. It's not like you don't have access to the default values, it's just that we want to [00:11:10](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h11m10s) recover your current saved value for you. Whenever you add another field which isn't already here, this drop down list only shows the fields that are not already on the page. You won't end up adding fields properties the second time. It has become much more easier to build fields and its properties [00:11:39](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h11m39s) as before. You really had to navigate through some of the complexities of dealing with an XML set of values. Which maybe some of you don't even know exactly what's going on. Those of you that do, I mean it's not like you're losing any advantage with the new implementation, [00:12:02](https://www.youtube.com/watch?v=26x_Sc8jbp8&list=PLQRGFI8XZ_wtGvPQZWBfDzzlERLQgpMRE&t=00h12m02s) you are still targeting that value with any value you want. It's still as easy as clicking a plus and selecting a value and adding it. I do hope that all of you will be as excited about this change as we are . We are now at the point where making JCB easy-to-use is also a priority.
|
Loading…
Reference in New Issue
Block a user