B4J Tutorial [BANanoVuetifyAD3] Create Professional Looking Vuetify WebSites & WebApps with BANano

westereng

Member
Licensed User

I have attached the pre-run logs
 

Attachments

  • prerunlogs.zip
    3.8 KB · Views: 125

RWK

Member
Licensed User
If I experience the errors ....BANano dosn't support..... it's the sign to me to compile the BVAD3 library by myself.....after that these errors are gone an the webproject works for me.
 

westereng

Member
Licensed User
Thanks for the error logs, they are perfect and report nothing out of the ordinary. Perhaps running the BANanoVuetifyAD3 library to compile it will solve the issues just like @RWK is saying.

Just did that now, and it did not make a difference, this is frustrating

Got rid of the Banano dosn't support errors though.

I will try to step through to se where it may have a problem.
 

westereng

Member
Licensed User
Im sorry about that, if you dont mind we can try and run anydesk so that I can try and help. Is that ok?

No need to, I forgot to do a hard refresh of the browser after recompiling the BANanoVuetifyAD3 library, and now it seems to work.

Lession learnd for me, always recompile a library first if I have problems

Thanks for the assistance @Mashiane

 

LJG

Member
According to my error notes, the last time I received this type of message (java.io.FileNotFoundException: ... manifest.txt) I had to recompile the BANanoSkeleton library (ran it in release mode to re-create the library) ... and it resolved the missing manifest error. I know that your case is not a BANanoSkeleton library issue but it is a possible clue that one of your libraries that you are using is corrupt and needs to be re-compiled. Since "bananofaker" is in the error path, that is the library that I would remove, recompile, and re-try again.
 

Mashiane

Expert
Licensed User
Longtime User
Tip: Creating Forms at Runtime

Sometimes it might happen that you will have to create forms at runtime due to the structure of your app.

We have wrapped vjsf, a json schema based library for Vuetify, https://github.com/koumoul-dev/vuetify-jsonschema-form

With a few lines of code..

B4X:
Sub oncreated
    dynaForm.Clear
    dynaForm.AddTextField("firstname", "First Name", "", 10)
    dynaForm.AddClass("firstname", "mx-4")
    dynaForm.AddStyle("firstname", "background-color", "pink")
    dynaForm.SetHint("firstname", "This is a hint")
    dynaForm.SetCols("firstname", "6")
    dynaForm.SetReadOnly("firstname", True)
    '
    dynaForm.AddFile("imgx", "Browse a file", "", False)
    '
    dynaForm.AddCheckBox("agree", "I agree", True,  "purple")
    dynaForm.AddDate("dateofbirth", "Date of Birth", "", "")
    dynaForm.AddSlider("age", "Age", 48, 0, 100, True, "24")
    dynaForm.AddSwitch("active", "Active", True, "deep-orange", True)
    dynaForm.AddTextArea("notes", "Notes", "", 0)
    dynaForm.SetMinLength("notes", 10)
    dynaForm.SetMaxLength("notes", 255)
   
    dynaForm.AddTelephone("telephone", "Telephone", "")
    dynaForm.AddTextFieldMulti("email", "To", Array("anele@x.com", "xolani@b.com"))
    dynaForm.AddNumber("boxes", "Number Entry", 43, -1, -1)
    dynaForm.AddNumberMulti("stocks", "Multi Numbers", Array(10, 11))
    dynaForm.AddTime("mytime", "Enter Time", "", "")
    dynaForm.AddDateTime("mydatetime", "Date Time", "", "")
    dynaForm.AddColorPicker("mycolor", "Select a color", "")
    '
    'dynaForm.AddComboBox("acx1", "ComboBox", "2", "accounts", "id", "text", False)
    dynaForm.AddComboBox("acx1", "ComboBox", "2")
    dynaForm.AddItem("acx1", "1", "A")
    dynaForm.AddItem("acx1", "2", "B")
    dynaForm.AddItem("acx1", "3", "C")
   
    'dynaForm.SetChips("acx1", True, True)
    '
    dynaForm.AddSwitchMulti("covid", "Covid Test", "blue", True, Array("1"))
    dynaForm.AddItemMulti("covid", "1", "A")
    dynaForm.AddItemMulti("covid", "2", "B")
    dynaForm.AddItemMulti("covid", "3", "C")
    '
    dynaForm.AddCheckBoxMulti("covid1", "Checking Items", "green", Array("2"))
    dynaForm.AddItemMulti("covid1", "1", "AA")
    dynaForm.AddItemMulti("covid1", "2", "BB")
    dynaForm.AddItemMulti("covid1", "3", "CC")
   
    'dynaForm.AddAutoComplete("acx", "Auto Complete", "1", "accounts", "id", "text", False)
    dynaForm.AddAutoComplete("acx", "Auto Complete", "3")
    dynaForm.AddItem("acx", "1", "A")
    dynaForm.AddItem("acx", "2", "B")
    dynaForm.AddItem("acx", "3", "C")
    '
    dynaForm.AddRadio("gender", "Gender", "m")
    dynaForm.AddItem("gender", "m", "Male")
    dynaForm.AddItem("gender", "f", "Female")
   
    dynaForm.Refresh(about)
End Sub

You are able to have a form with content.



There are some settings that you need to define in the Abstract Designer for this to work. We have only done the most simplified cases for the form, for complex forms, one will have to use the designer, thus its limited to basic controls. Also there are controls in this library that are custom built like the DateTimePicker, the tagged input controls



Ta!
 
Last edited:

Mashiane

Expert
Licensed User
Longtime User
Thanks, just to add, BANanoFaker is part of the BVAD3 child extensions to create fake data for testing purposes.
 

Mashiane

Expert
Licensed User
Longtime User
Tip: Getting Results of Filtered Data-Table Records

The data-table has a search property. To activate it, one should, when creating columns, specify the column as "filterable". This ensures that on the search, all columns marked as filterable can be searchable.



This when typing sbp on the search, the data-table will only list those records that have the word sbp by searching all the columns marked as filterable.

To trap the results that get listed after a search results, one needs to

Method 1 - Current Page Filter

1. Trap the Current Items event by generating members for it.



2. The event returns the array of objects that are returned by the filter - for the current page. If for example your items per page is 50 and the filter returned 15 results, the returned items by CurrentItems will return 15 items. You can save these items for later retrieval as per indicated in this example.

B4X:
Private Sub dynaTable_CurrentItems(items As List)
    'save the current items for later retrieval
    dynaTable.CurrentItems = items
End Sub

3. Getting the filtered results..

B4X:
Private Sub dynaTable_PDF_Click (e As BANanoEvent)
    'get the filtered items
    get filtered items for the active page
    Dim res As List = dynaTable.CurrentItems
    Log(res)
End Sub

Method 2 - Complete Filter For All Records

The second method involves not using current_items event trapping. It enables one to get all the filtered records across the table and not just the current page. Using the same pdf sub above. We could...

B4X:
Private Sub dynaTable_PDF_Click (e As BANanoEvent)
    'get the filtered items
    mydata.refs = vuetify.getrefs
    Dim res As List = dynaTable.FilteredItems
    Log(res)
End Sub

It's important to refresh the refs with .refs = vuetify.GetRefs

Ta!
 

Mashiane

Expert
Licensed User
Longtime User
Version 5.66 is now available. It features a fully jRDC2 MySQL example.

Download B4J External Libraries
Download New Awesome BANanoVuetifyAD3 BANanoServer Kitchen Sink



PS: The database name for this exercise is test and the table name is animals.

Please note there are only 2 felds in the animals table.

You need to create a test database in MySQL and import this script to create the table.


 
Last edited:
Cookies are required to use this site. You must accept them to continue using the site. Learn more…