I want to customize moodle course/edit_form.php file and add some more fields and remove some existing fields. Is this possible to do without changing core files?
I followed this article but didn't find anything helpful https://docs.moodle.org/dev/Form_API
You can create a plugin that has a form which saves extra information about the courses and then you can show those fields by overriding the course renderer in the theme.
Related
I am using Moodle 3.8, I added a custom field called razon_social, I just want to show it in the profile edit page, in the optional section.
Custom field added in mdl_user
Section where I want to show my custom field
Does anyone know in which file in .php, do I have to call my custom field?
Thank you very much for your time
I want to do this, I have Moodle 3.8
enter image description here
Adding a custom field to the mdl_user table (or any other core table) is a really bad idea. There are all sorts of ways it can conflict with the core code (particularly for tables which Moodle uses with "persistent" classes, but still a problem in other situations).
Thankfully, Moodle already has a build in custom user field system (using the tables mdl_user_info_field and mdl_user_info_data) and fields defined this way automatically appear on the user profile page (unless you mark them as hidden).
It should be fairly easy to write a script that will transfer the data from the mdl_user field you created, into a custom user field. After that, you can drop the extra field you added.
is there a way to have prefilled attributes notes in enterprise architect?
It should be something like this scenario:
1) I create new attribute
2) Enterprise architect prefill note of attribute with predefined text
Something like template for attributes.
Thank you for any advice
I know this won't help directly this question.
Anyways you can achieve it through an external addin.
All you need to do is handle the EA_OnPreNewAttribute and EA_OnPostNewAttribute broadcast events .
This isn't quite what you're after but it is possible to create an Attribute stereotype in a Profile and add to this a Tag with an initial value set to what ever you want. When you create an attribute with this stereotype, this means your predefined text would appear in a tag-value for the attribute rather than the note. Not ideal, but might work for you.
You could also have a go at writing some JavaScript to do this as well (under Scripting in EA). You'd have to use the JS to navigate the repository structure, find the attributes in question, and update their note. I don't believe you can attach a script to a UI event, so I think you'd be stuck running this post-hoc rather than having the note auto-populate on attribute creation.
Hi, Currently am working on hybris 6.5. I want to remove Header which have orbeon form logo. I have published forms on storefront.
You can change the logo by setting the oxf.fr.default-logo.uri.*.* property. This in done in your properties-local.xml, and if you haven't gotten a chance to modify that file yet, you might find going through the doc on properties useful.
I have a requirement to store a list of designers with logos and some bio information in my Umbraco CMS. I created a document type called 'Designer' with all those properties. I'd like to now create a dropdown list with those designer names so I can associate it with other document types. How do I create this dropdown? I'm using the v7 of umbraco.
Checkout nuPickers for Umbraco v7. Should have everything you need.
http://our.umbraco.org/projects/backoffice-extensions/nupickers
http://github.com/uComponents/nuPickers/wiki
http://www.nuget.org/packages/nuPickers
Look here for help with creating custom labels using macros
http://github.com/uComponents/nuPickers/wiki/Custom-Labels
As I understand, your intention is to let editors pick designers from the designers dropdown when editing content items in the backoffice.
If so, you may want to either use an existing data type called 'Dropdown' or create a custom data type.
If you only want the names in the dropdown, the default 'Dropdown' data type may suffice. Take a look at the article explaining how to customize the 'Dropdown' data type
Otherwise (say, if you want to show the avatar of the designer in your designer picker), you may want to implement your custom property editor (designers picker) and a custom data type related to it. Then you will be able to associate your data type with any document type you want.
A couple of useful links in this case:
how to create a custom property editor in umbraco 7
the demo which includes building a custom picker property editor to assign custom data to a document
Umbraco v7 XPathDropdownList implementation
I'm trying to add an attribute to the form tag of a cq5 form. I noticed that the output is generated using
FormsHelper.startForm(slingRequest, new JspSlingHttpServletResponseWrapper(pageContext));
I was curious how I can either:
alter the request so that the formHelper prints the form w/ the attributes I need
Hook into the actual print out to include the attributes I need.
Any help or direction would be good.
note:
I've already checkout out the javadoc for formshelper, done some searching via goolgle, and dev.day.com including the dev.day.com doc on developing forms.
thank you
API doesn't allow you to add any attributes to this tag. You can only specify desired CSS classes adding css property to the form component. Of course, you can also create component sling filter and response wrapper to rewrite created form, but it seems to be an overkill. I think better solution is using JS to add attributes client-side.