Skip to content

F51-152 Remove buyerid and catalogid constants#124

Merged
crhistianramirez merged 4 commits intoordercloud-api:developmentfrom
robertsoniv:development
Jun 6, 2017
Merged

F51-152 Remove buyerid and catalogid constants#124
crhistianramirez merged 4 commits intoordercloud-api:developmentfrom
robertsoniv:development

Conversation

@robertsoniv
Copy link
Copy Markdown
Contributor

This also includes a lot of various changes based on an update that was made to the version of angular-bootstrap. Many of the changes account for the lack of buyerid and catalogid constants.

  • Update ocLineItems.AddItem() to use $broadcast - base.js was not getting updated with $emit
  • Use ocLineItems.AddItem() in the product card directive
  • Update angular-bootstrap to the latest version, remove oc-carousel in favor of uib-carousel (custom directive was over-engineered)
  • Remove productSearch component in favor of re-routing the search directive to the product browse component.
  • Add an indicator when searching to the product browse template, there is also a blue icon for clearing the search (useful on mobile)
  • Move the product search modal into the ocProducts service in common/services/oc-products

- This was stopping the order from being updated correctly in base.js
- Use ocLineItems.AddItem() in the product card directive
- Update angular-bootstrap to the latest version, remove oc-carousel
  in favor of uib-carousel (custom directive was over-engineered)
- Remove productSearch component in favor of re-routing the search
  directive to the product browse component.
- Add an indicator when searching to the product browse template, there
  is also a blue icon for clearing the search (useful on mobile)
- Move the product search modal into the ocProducts service in common/
@robertsoniv
Copy link
Copy Markdown
Contributor Author

This PR seems a little large because I added the package-lock.json file

@robertsoniv
Copy link
Copy Markdown
Contributor Author

This will require a bower install to get the updated versions of the SDK and ui-bootstrap

});
it('should resolve ProductList', function () {
xit('should resolve ProductList', function () {
injector.invoke(productsState.resolve.ProductList);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

is this on purpose? xit will skip a test

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, I haven't figured out how to stop the global parameters from changing during the unit tests. Some people are altering these for specific tests and those changes come down in subsequent tests. We may need to come up with a way to copy those parameters instead of changing what's stored in global.spec

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

yeah, i noticed the same. Lets just add a function (can store it in global.spec.js) that does something similar to angular.copy so that global constants aren't mutated.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

that can be a separate task though

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@crhistianramirez crhistianramirez merged commit b3eda97 into ordercloud-api:development Jun 6, 2017
crhistianramirez pushed a commit to crhistianramirez/angular-buyer that referenced this pull request Jun 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants