Git Product home page Git Product logo

Comments (26)

chriskpalmer avatar chriskpalmer commented on August 18, 2024 2

Dashboard Unknown Error bug |||FIXED||| --- this error:
Uncaught exception: --> Smarty Compiler: Syntax error in template "file:/opt/lampp/htdocs/librebooking/tpl/Dashboard/resource_availability.tpl" on line 59 "<a href="{if isset($path) $Path}{Pages::RESERVATION}?{QueryStringKeys::RESOURCE_ID}={$i->ResourceId()}"" too many shorthand attributes
Fixed by changing the first part {if isset($path) $Path} to {$Path}:
<a href="{$Path}{Pages::RESERVATION}?{QueryStringKeys::RESOURCE_ID}={$i->ResourceId()}

from app.

effgarces avatar effgarces commented on August 18, 2024 1

I took sometime off to recover and slowly getting back to work, but as you already seen, one of the most recent pull request was exactly about PHP8 compatibility, and it will also be one of my main objectives in the coming weeks/months.

from app.

christiaangoossens avatar christiaangoossens commented on August 18, 2024

Same issue as americandigitalservices#2

from app.

effgarces avatar effgarces commented on August 18, 2024

Thanks for the heads-up, I'm not able to solve this right now due to a heavy workload, but I will definitely address it as soon as my schedule eases up (in one or two months).

from app.

guilegatan avatar guilegatan commented on August 18, 2024

Bump. Sorry, but any progress in regard of PHP 8.0 support?
Thank you.

from app.

effgarces avatar effgarces commented on August 18, 2024

Yes, I already did some work on that direction, there were a couple of commits sometime ago that tried to address some of the issues, but as my current production server are still on 7.x land I haven't advanced much more. Also due to health related issues I had to slow down alot, so most of the progress here will only occur when my day job slows down.

from app.

guilegatan avatar guilegatan commented on August 18, 2024

Thank you. I already tried to incorporate the various commits but there is definitely something still missing.
I totally understand you. This is your part-time project anyway.
I will be patient, and all the best with your health issues!

from app.

guilegatan avatar guilegatan commented on August 18, 2024

Sorry to bring it up again.
Any progress on PHP 8 support? Anything I/we can contribute to the solution?

EDIT: just found this #132
I will test asap

from app.

guilegatan avatar guilegatan commented on August 18, 2024

Thank you very much!

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

Hello @effgarces, I am interested in PHP 8 support as IT people will not let me have PHP 7 after November. I am trying to get librebooking installed on a UBuntu linux box with a fresh install of xampp. So far I have got it working except for this error from librebooking-app.log:

2022-10-06T07:50:50+02:00 [589902] ERROR default - [User= ()] Error executing MySQL query Table 'librebooking.announcement_groups' doesn't exist [File=/opt/lampp/htdocs/librebooking/lib/Database/MySQL/MySqlConnection.php,Line=112]
2022-10-06T07:50:50+02:00 [589902] ERROR default - [User= ()] Uncaught exception: Exception: There was an error executing your query\nTable 'librebooking.announcement_groups' doesn't exist in /opt/lampp/htdocs/librebooking/lib/Database/MySQL/MySqlConnection.php:114
Stack trace:
#0 /opt/lampp/htdocs/librebooking/lib/Database/MySQL/MySqlConnection.php(76): MySqlConnection->_handleError(false)
#1 /opt/lampp/htdocs/librebooking/lib/Database/Database.php(27): MySqlConnection->Query(Object(GetDashboardAnnouncementsCommand))
#2 /opt/lampp/htdocs/librebooking/Domain/Access/AnnouncementRepository.php(11): Database->Query(Object(GetDashboardAnnouncementsCommand))
#3 /opt/lampp/htdocs/librebooking/Presenters/LoginPresenter.php(123): AnnouncementRepository->GetFuture(5)
#4 /opt/lampp/htdocs/librebooking/Pages/LoginPage.php(124): LoginPresenter->PageLoad()
#5 /opt/lampp/htdocs/librebooking/Web/index.php(22): LoginPage->PageLoad()
#6 {main} [File=/opt/lampp/htdocs/librebooking/lib/Common/Logging/ExceptionHandler.php,Line=19]

I searched for "announcement_groups" and found it in upgrades/2.6/schema.sql and nowhere else. The table is not in the schema I successfully manually installed from the develop database_schema/create-schema.sql. I would appreciate help figuring out why it is being asked for and producing this error. Thank you for your efforts to keep this alive and working with PHP 8.

from app.

effgarces avatar effgarces commented on August 18, 2024

I took a quick look at our installs and all of them contain the "announcement_groups" table, but they were all installed initially using the web wizard, and while I'm not able, at the moment, to take in depth look at this I can tell you that this table is required and it should be in your database, but as you say it's not on the create-schema.sql, so I'm putting this tentatively as a bug. As soon as I get back to the office, next week, I will dive on this. In the mean time, just grab the sql from upgrades/2.6/schema.sql, just the part that creates this table and apply it to your install, it should fix this error.

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

Hi @effgarces thanks for having a quick look at this. When you get a chance can you look at one of your installs and tell me how many tables you have? From the develop create_schema.sql I ran there are 25 tables.

I am asking because I see other tables in 2.6 that are not in the 25 tables I see in phpmyadmin and the create_schema.sql. (peak_times, custom_attribute_entities, resource_type_assignment, reservation_color_rules, reservation_guests, announcement_resources, reservation_waitlist_requests)

I hesitate to add announcement_groups then to go right to another error and so on if there are many missing.

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

As I suspected the next error was missing announcement_resources

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

Okay wow, I managed to run the Web/install successfully and it seems to be working. There are 57 tables. I'll report back later how it goes with php 8 setting it up and using it.

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

I'm in just getting started. So far this is the only error that makes the Dashboard return Unknown Error:
2022-10-06T23:50:43+02:00 [589668] ERROR default - [User=Chris Palmer ([email protected])] Uncaught exception: --> Smarty Compiler: Syntax error in template "file:/opt/lampp/htdocs/librebooking/tpl/Dashboard/resource_availability.tpl" on line 59 "<a href="{if isset($path) $Path}{Pages::RESERVATION}?{QueryStringKeys::RESOURCE_ID}={$i->ResourceId()}"" too many shorthand attributes <-- [File=/opt/lampp/htdocs/librebooking/lib/Common/Logging/ExceptionHandler.php,Line=19]

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

So far, the smarty syntax error above persists ||FIXED||and only one other:
After a reservation is made when the "Close" button is clicked on the reservation confirmation the app goes to the url http://schedule.php/ which has nothing. Also the "Cancel" button on a new reservation does the same thing. |||FIXED||| Needed to add https:// to script url

Everything else (Making Resources, Schedules, etc) has worked as expected.

from app.

effgarces avatar effgarces commented on August 18, 2024

Thank you documenting your findings, it's always helpfull to have this kind of info out on the web. The basic functionality should be working with PHP 8, at the moment I'm going around fixing warnings (you never know what the next PHP version will cause) and also trying to figure out why the reports are not working properly on my test install.

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

Hi @effgarces, yes there are lots of warnings but it seems to work well. I wish I could figure that smarty syntax thing out but it is just past my comfort zone, tcl is not so readable code!

One thing I would love to get working but that has not yet is the email function. I have tried many combinations of settings and been on forums and found this: https://forums.bookedscheduler.com/viewtopic.php?f=3&t=1529&p=2047&hilit=sendmail#p2047
"I will note that Booked uses the package "PhpMailer", which has been upgraded from the version in Booked (5.0) to a more recent version (6.5.1). The new version is not compatible with with the 5.0 version. I don't know what the effort would be to update Booked to the newer version, but I suspect that although it would be "non trivial", it wouldn't be difficult."

I wonder if that is why I have been having trouble. I will continue to work on this but if you could test it on your environment and let me know if it works it would be helpful.

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

@effgarces Does your dashboard work?

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

~$ echo "Subject" | sendmail [email protected] on my linux xampp box works but I can't get the librebooking email to work with either "mail" or "sendmail" and the correct path to usr/sbin/sendmail

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

The sendmail problem was |||FIXED||| by my IT support. It had to do with fixing this:
usr/sbin/sendmail: /opt/lampp/lib/libstdc++.so.6: version `CXXABI_1.3.8' not found (required by /lib/x86_64-linux-gnu/libicuuc.so.70)
So probably not a librebooking problem :)

from app.

effgarces avatar effgarces commented on August 18, 2024

Hi @effgarces, yes there are lots of warnings but it seems to work well. I wish I could figure that smarty syntax thing out but it is just past my comfort zone, tcl is not so readable code!

One thing I would love to get working but that has not yet is the email function. I have tried many combinations of settings and been on forums and found this: https://forums.bookedscheduler.com/viewtopic.php?f=3&t=1529&p=2047&hilit=sendmail#p2047 "I will note that Booked uses the package "PhpMailer", which has been upgraded from the version in Booked (5.0) to a more recent version (6.5.1). The new version is not compatible with with the 5.0 version. I don't know what the effort would be to update Booked to the newer version, but I suspect that although it would be "non trivial", it wouldn't be difficult."

I wonder if that is why I have been having trouble. I will continue to work on this but if you could test it on your environment and let me know if it works it would be helpful.

This is one off the big issues with Librebooking, besides phpmailer, there are a bunch of libraries that are stuck in old versions, all of those need to be updated and that means one needs to familiar with how they were integrated and as of consequence more time is required and I'm in short supply of it.

@effgarces Does your dashboard work?

Yes, seems to working ok.

from app.

chriskpalmer avatar chriskpalmer commented on August 18, 2024

Thanks @effgarces for all your work dealing with all the depreciated and warning bugs.
Small bug just observed:
When as admin (did not see this as regular user) making a new reservation there is a link "View Availability" that goes to a blank page.
Also, thanks for working on "Reports" they are not working on my install either. No rush but it will be nice when they are there again.

from app.

guilegatan avatar guilegatan commented on August 18, 2024

Is the current development version already working with PHP8? Does it need a database upgrade?

I still get an "unknown error" on my PHP8 testserver with imported database from my production environment.
apache2 log says: PHP Warning: Attempt to read property "value" on null in /var/www/html/app_develop/tpl_c/02c57c49d3225e4b7754ac327c8994c6afa5f642_0.file.globalheader.tpl.php on line 32, referer: https://my.testserver.url/app_develop/Web/?

PHP 8,1,9
MySQL 8.0.31

from app.

effgarces avatar effgarces commented on August 18, 2024

The current version is working with PHP8, no database upgrade required ( do bear in mind that recently added functionality does require an upgrade to the DB, but this is not related to PHP8 support). The only part of librebooking that needs a bit of help in terms of PHP8 support is the reports functionality, that is not working properly.

from app.

guilegatan avatar guilegatan commented on August 18, 2024

Thank you for the update. In this case I will dig deeper into my problem. If the current development version is PHP 8 capable, I should somehow get it running on my testserver with PHP 8.1

from app.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.