Giter Club home page Giter Club logo

Comments (4)

21Bruce avatar 21Bruce commented on August 20, 2024

Implemented an interface to the api layer to include a preference for tables. Table preference is decided after each loop of time searches. So the structure is basically, given a priority list of times {T1 T2} and a priority list of table types {Ta1 Ta2}, the checking goes(rough pseudocode)

For slot in slots {
If slot.Time == T1 && slot.Type == Ta1 -> reserve
}

For slot in slots {
If slot.Time == T2 && slot.Type == Ta1 -> reserve
}

For slot in slots {
If slot.Time == T1 && slot.Type == Ta2 -> reserve
}

For slot in slots {
If slot.Time == T2 && slot.Type == Ta2 -> reserve
}

The changes involved modifying the resy api reserve operation, specifically the find step. We search the config of the slot for a field called type, which provides a string declaration of the type of table the slot corresponds to. See api/resy/doc.go for more info.

We still need to implement the command line flag for adding table types, but @justin-s-wong already has a commit in progress for this, should be available sometime tomorrow.

from resolved-bot.

21Bruce avatar 21Bruce commented on August 20, 2024

Ok, the command line parsing is done. I'd like some initial testing done for this. @ndbs879827 you can test these changes by cloning the branch 29-feature-an-option-to-specify-table-type and rebuilding with go build. Let us know if this is what you had in mind

from resolved-bot.

21Bruce avatar 21Bruce commented on August 20, 2024

As an extra note, since these changes pass my initial testing, if you don't have any other concerns, this branch will get merged into develop in a day or so

from resolved-bot.

21Bruce avatar 21Bruce commented on August 20, 2024

I've merged the changes into develop, but I'll keep the feature branch and this issue open for two days to anyone who would like to voice their opinion

from resolved-bot.

Related Issues (14)

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.