How can I use Vue data-bindinding in a Moqui form? - moqui

I want to add a calculated field to a form that depends on the value entered by the user on some other field and I'd like its value to update before the form is submitted, as if it were using data-binding of some kind.
Is this possible to implement for the vuet output mode?

While part of the initial Vue JS functionality in Moqui Framework 2.1.0 it is only recently well supported and tested so you will need the latest code from the moqui/moqui-framework and moqui/moqui-runtime repositories. This will all be in the upcoming 2.1.1 release series.
Because this is new and many are likely to have questions about it I added an example and some brief documentation that covers the main differences from normal XML Screens. That is now available on moqui.org here:
https://www.moqui.org/m/docs/framework/User+Interface/Client+Rendered+Vue+Screen
To run this locally you will also need the latest code from the moqui/example repository.

Related

Shopware 6 add entity extension fields to admin search

I wonder how to make some fields of an entity extension searchable in the administration through the "/api/search/my-entity" api-endpoint. By default they are not considered during search as it looks like.
I found the answer by debugging the search-endpoint:
The association-Field of the EntityExtension needs to have a SearchRanking-flag:
...->addFlags(new SearchRanking(SearchRanking::ASSOCIATION_SEARCH_RANKING))
Then you can add SearchRanking-flags in the EntityExtensionDefinition as you like, e.g.:
(new StringField('test', 'test'))->addFlags(new SearchRanking(SearchRanking::HIGH_SEARCH_RANKING)),
After that the fields are searchable via the search-endpoint :)
As far as the API is concerned, search functionality should automatically be generated following your custom entity definitions.
When it comes to facilitate Admin search for your entity, you need to add some code to the administration component as described in the docs: https://developer.shopware.com/docs/guides/plugins/plugins/administration/search-custom-data (even though it looks not fully up-to-date w.r.t to the current Shopware versions).

B2B/Powertools Spartacus 3.3 - Missing "Reorder", "Cancel" and "Return" options in MyAccount

Successfully build Commerce 2011_7 with Spartacus 3.3 last week (using the standard instructions for B2B Commerce) and all appears to function on initial tests.
This week, I've gone to test the Standard Order Flows with mark.rivers#pronto-hw.com and noticed that the "Self Service" buttons that typically appear against a placed order in My Account are missing, and these are definitely there in the JSP Storefront and earlier versions of Spartacus.
I'm able to follow the instructions but not a developer so asking if anyone knows whats causing them to 'not appear' and could help me get them back please - have supplied a screenshot with the Console open as well.
The two lines in the console that concerned me were:
spartacus-storefront.js:18398 No component implementation found for the CMS component type 'AccountOrderDetailsOverviewComponent'.
Make sure you implement a component and register it in the mapper.
spartacus-storefront.js:18398 No component implementation found for the CMS component type 'AccountOrderDetailsReorderComponent'.
Make sure you implement a component and register it in the mapper.
enter image description here
order self service was added in 1.4 but you need release 2005.
see https://sap.github.io/spartacus-docs/cancellations-and-returns/
it's possible that with installation of 3.3, the cancel/returns code wasn't installed? we transitioned to many smaller libraries for 3.3. but also you need cms content in the backend (which looks like you have).

Create issue : Test link integration with jira

I've integrated Testlink with Jira using below xml
<issuetracker>
<username>xyz</username>
<password>#123</password>
<uribase>abc.net/projects/KEY/</uribase>
<uriapi>abc.net/rest/api/latest/</uriapi>
<uriview>abc.net/browse/</uriview>
<projectkey>KEY</projectkey>
<issuetype>1</issuetype>
</issuetracker>
I am able to link existing jira issue in to test link.
But create issue window contains Version field which would not alow me to enter any value or not giving any suggestion as displayed in below image.
I've tried to create version in jira but it doesn't work.
So,
What value i should enter/configure for version field ?
What is use of <issuetype>1</issuetype> ? can we provide any other value?
How to link new field on create Issue window?
4.Version is mismatched with jira field Versions.
I'm not sure which version of JIRA REST API you are using but the tutorial for the v2 says:
Just like everyone else in the real world, we're faced with time and resource constraints. Supporting two serialisation formats requires more time than just a single one. Hence, for our initial release of the JIRA REST API, we decided to provide "more stuff in JSON" rather than "less stuff in JSON and XML".
So I'm not sure about the XML support. I have no experience with Testlink, but I guess it's using some kind of serialiser at the back end.
If you check the Create issue endpoint, there is no version field. I guess it will be the versions field instead. In JIRA projects can have multiple versions. You can get a list of versions from the Get project eversions endpoint.
Issue type is an ID of issue type you want to use for your issue. You can get a list of project specific issue types from the Get issue all types
endpoint.
I'm not sure about this
Check the first point
This version field is empty because you have not specified any version for your project in JIRA. In my case it was Fix version in JIRA. Currently the rest API is getting an empty list of versions. You can try
curl -X GET http://example.com/rest/api/2/project/KEY/versions
-H 'authorization: Basic dtgzkisVlbyhsuYWhtYijdsdidjjsidDkw'
This will give you an empty list.
Once you set FixVersion in for your project in JIRA, this API will return the list of available versions for your project and the Version field will be populated with those versions.
PS: use your own authorization headers. You can use [Postman][1] for this purpose.

How to add custom field type on KeystoneJS 0.4?

I'm currently building an app for TV/Radio program guide and schedule using keystonejs. I need time input field (hour and minute) for it to work. By default keystonejs doesn't give me an option of time field. Only Date and Datetime are available, none of which are suitable for my use case. Keystonejs documentation doesn't really do the job for >0.4. Although, I can spare its sparse documentation since it's still in beta phase
How to create a new Field type which is usable in production app on keystonejs 0.4.3-beta without directly modifying keystonejs node_modules package?
The one that I found on keystonejs wiki (credit card field type), is to create custom field for development only. And it doesn't even translate to admin UI.
Is it possible to add plugin (such as npm clock-input) to use it as field input on keystonejs admin UI?
I'm still thinking of the best way to integrate schedule system in keystonejs admin UI. For now, I'm thinking of creating a List which contains program name, description, days of the week, and time. In this case, some TV program are supposed to be able to have multiple days, and on specific days of the week it has different time (for example: program A being aired from Monday-Thursday on 4PM, and Friday on 7PM).
I think the way I'm currently planning to implement on is a bit messy. Any suggestion of the good way to do this?
note:
I figure #1 out, although I'm still learning on how it actually works.
I ended up using keystone-custom-fieldtypes npm packages to export my custom input field to keystonejs module without manually touching the file (I use igorrafael fork which works for keystonejs >0.4. Since the original package only works for keystonejs 0.3). You can find it here : https://github.com/igorrafael/keystone-custom-fieldtypes.
I managed to duplicate one of the default field type. So currently I have my custom field type boilerplate. Still need to modify a lot of things though.

ActiveCollab Project management section - adding extra custom fields while add/edit

I'm trying to develop a custom module inside ActiveCollab(4.0.11) for adding some extra fields while adding/editing projects. ActiveCollab itself has ability to add only 3 custom fields, but I need to add more fields(text,dropdown etc). I have gone through the documentation of creating modules and started working on it, but did not get much details. I have used "on_project_created" event to trigger my custom module to capture the Project form data(added the required custom fields in to ActiveCollab database tables tables and it started showing on project add/edit form automatically). Now I'm stuck with not knowing how to pass the posted values from Handler function to Controller.
Any help would be greatly appreciated.
activeCollab supports only three custom fields and there is no officially supported way to programatically add more fields. Exploiting internal API-s may work, but it is not recommended. These API-s may change or even disappear at any point, without prior notice.