Skip to content

CLCdesq API - #2754

Closed
objecttothis wants to merge 56 commits into
masterfrom
CLCdesq_API
Closed

objecttothis wants to merge 56 commits into
masterfrom
CLCdesq_API

Conversation

@objecttothis

@objecttothis objecttothis commented Mar 9, 2020 •

Copy link
Copy Markdown
Member

This will need to be completely reworked and implemented after CI4 Event triggers have been implemented.

@objecttothis objecttothis self-assigned this Mar 9, 2020
Comment thread application/libraries/Events.php Outdated
*/
public static function has_listeners($event)
{
if (isset(self::$_listeners[$event]) AND count(self::$_listeners[$event]) > 0)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can just return this statement, no if needed

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've corrected this in this branch and in the event_generator branch.

@objecttothis
objecttothis marked this pull request as ready for review April 21, 2020 19:13
@objecttothis objecttothis added this to the 3.4.0 milestone May 22, 2020
@objecttothis objecttothis linked an issue Jun 15, 2020 that may be closed by this pull request
7 tasks done
@objecttothis
objecttothis force-pushed the CLCdesq_API branch 2 times, most recently from 2de895d to 5933bb5 Compare July 2, 2020 12:58
@odiea

odiea commented Jul 2, 2020

Copy link
Copy Markdown
Collaborator

What is CLCdesq api anyway?

@objecttothis

Copy link
Copy Markdown
Member Author

What is CLCdesq api anyway?

It's a third-party integration. It has the event_generator for third-party integrations as a dependency. In short, it sends JSON RESTful API calls to a proprietary web platform so that we can sync inventory with the website. Several people have been asking for integrations similar to it for publicly available CMSs. Those, like this will need to integration through whatever the final product of our event_generator ends up being.

@odiea

odiea commented Jul 2, 2020

Copy link
Copy Markdown
Collaborator

Thanks. I tried googling it and did not see much about it.

- Corrected bug in Items->data_error_check preventing dates from being
checked properly.
- Fixed attribute save to properly account for decimal and date updates.
- Changed some columns from tinyint to tinyint(1)
- Removed from querybuilder calls to optimize speed.
- Cleaned up code
- Optimized out 1 query call per attribute per row in import file.
- Fixed a bug causing attribute conversion to fail.
- Code cleanup and optimization in the convert_definition_data method.
- Reverted method chaining in query builder methods for readability.
- Resorted Attribute model to original method order for clarity in code
review.
- Added NEW_ITEM constant
- Renamed variables for clarity
- Tab indentation of equals signs for easy of reading
- Removed unnecessary comments
- Removed unecessary variable.
- Renamed CSV headings to for consistency with other headings
- Remove method chaining for clarity.
- Replaced array() and new Array() with [] for speed (+20%) and to match
current standard.
- Removed trailing whitespace and whitespace on empty lines
- Resorted order to take advantage of query indexes in the database.
- Fixed a problem causing quantities to not be properly stored.
- Added a check to fail a line if an item_id is provided that does not
exist.
- Corrected Saving of inventory quantities to allow 0 quantity to be
entered.
- In the event that an item was being updated and the new
attribute_value didn't exist, the old attribute_link was not being
deleted which caused two attribute_link rows to exist with the same
item_id and definition_id.
- There was a bug in the code that caused attribute_link rows to be
duplicated with the same information on item_import with an update.
This migration removes the duplicate rows.
Added event_update trigger in Receivings
@jekkos

jekkos commented Dec 2, 2020

Copy link
Copy Markdown
Member

@objecttothis It seems this branch has some changes that are already in the import branch? Do you want me to have a look and sync it with latest master? Maybe it's better to wait until we merge your import changes.

@objecttothis

Copy link
Copy Markdown
Member Author

@objecttothis It seems this branch has some changes that are already in the import branch? Do you want me to have a look and sync it with latest master? Maybe it's better to wait until we merge your import changes.

Correct. The order that we need to review and merge the branches is:

  • Import/Optimizations.
  • 3rd Party Integrations.
  • CLCDESQ API.

This branch will change depending on how we implement the 3rd party integrations event generator, so no need to review it until that's sorted out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants