zion / fishbowl

A ruby gem to interface with the Fishbowl Inventory API.
MIT License
6 stars 9 forks source link

fix nokogiri version. #4

Open farooqch11 opened 4 years ago

farooqch11 commented 4 years ago

Bundler could not find compatible versions for gem "nokogiri": In snapshot (Gemfile.lock): nokogiri (= 1.10.9)

In Gemfile: fishbowl was resolved to 0.0.3, which depends on nokogiri (~> 1.5.5)

zion commented 4 years ago

hey, I had this problem too a while ago. Havent taken the time to address the issue in the gem. I'll try to do that really soon.

As a work around, Im just using the gem from github.

gem 'fishbowl', :git => 'https://github.com/zion/fishbowl.git'

This isnt ideal, I know. But it worked for me. I'll try to get the gem updated on rubygems soon!

zion commented 4 years ago

@farooqch11 Ok, I decided to just do this now.

Pushed the gem as v1.0

Try gem 'fishbowl', '~> 1.0'

I was able to bundle install but havent tested my app yet. But its the same codebase as I was using before. Let me know if you have issues.

farooqch11 commented 4 years ago

Thanks for such a quick response.

is there any documentation for all methods we have in the gem, i need to fetch products, orders, and other details also.

zion commented 4 years ago

There isn’t. I inherited this gem a while ago when the original author no longer used it or supported it.

Fishbowl has some documentation for the different requests but it’s not great to be honest.

farooqch11 commented 4 years ago

Oh, i think i will put some efforst to put docs ?

On Sun, 5 Apr 2020, 5:42 pm Simeon, notifications@github.com wrote:

There isn’t. I inherited this gem a while ago when the original author no longer used it or supported it.

Fishbowl has some documentation for the different requests but it’s not great to be honest.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/zion/fishbowl/issues/4#issuecomment-609410531, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFWI22LQQS24FRVENH2ADLRLB4EFANCNFSM4L4L3MEQ .

zion commented 4 years ago

Sounds awesome!

I currently only use a couple of the request methods. Save and retrieve SO. so it’s very possible some of them don’t work correctly

farooqch11 commented 4 years ago

Possible then i will check if something doest work and will update in separate branch

On Sun, 5 Apr 2020, 5:48 pm Simeon, notifications@github.com wrote:

Sounds awesome!

I currently only use a couple of the request methods. Save and retrieve SO. so it’s very possible some of them don’t work correctly

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/zion/fishbowl/issues/4#issuecomment-609411156, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFWI23EFYEKO6TGWF37GKTRLB4YDANCNFSM4L4L3MEQ .

farooqch11 commented 4 years ago

@zion can you guide little bit to me , how can i add new request methods in this gem and make it work for my project only? easy way to add new requests in my project by using this gem functions.

zion commented 4 years ago

You can add more request classes if you'd like and make a PR... or you could fork this and add them in your fork.

What kind of new requests?

farooqch11 commented 4 years ago

I have custom made queries in fishbowl, named queries, i wanna fetch those. Like all products, updated products, images for single product.

On Sat, 11 Apr 2020, 12:33 am Simeon, notifications@github.com wrote:

You can add more request classes if you'd like and make a PR... or you could fork this and add them in your fork.

What kind of new requests?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/zion/fishbowl/issues/4#issuecomment-612184571, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFWI23HYHZB5WD5Q3VYDPTRL5YAPANCNFSM4L4L3MEQ .

zion commented 4 years ago

Could we use this?

https://www.fishbowlinventory.com/wiki/Fishbowl_API#Execute_Query

farooqch11 commented 4 years ago

Yes, this is needed! Do we have any this request type in the gem already?

On Sat, 11 Apr 2020, 12:38 am Simeon, notifications@github.com wrote:

Could we use this?

https://www.fishbowlinventory.com/wiki/Fishbowl_API#Execute_Query

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/zion/fishbowl/issues/4#issuecomment-612186097, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIFWI24NUZX4IN5FTXDJTZLRL5YR3ANCNFSM4L4L3MEQ .

zion commented 4 years ago

There is not.

All the request objects now use a base class that uses an xml structure. We would have to create a new base class or build some other mechanism for json type requests. Which isnt a big deal, but does not exist yet.

Heres what we can do, if you are willing, you can add a new request object for execute query. You can use this as an example: https://github.com/zion/fishbowl/blob/master/lib/fishbowl/requests/get_product.rb

Instead of: Fishbowl::Objects::BaseObject.new.send_request(builder, "ProductGetRs")

We can build a new object class for json requests, and do something like:

Fishbowl::Objects::JsonObject.new.send_request(builder, 'ExecuteQueryRq')

All of this is purely speculative, however I think it should work