These are chat archives for reactioncommerce/reaction

18th
Oct 2015
Aaron Judd
@aaronjudd
Oct 18 2015 00:02
Can you create an issue please?thanks!
Bryan Wu
@cooloney
Oct 18 2015 00:10
sure, I did
danielortiz
@danielortiz
Oct 18 2015 00:13
can I use "attachSchema"method to add something like
new SimpleSchema({
   "correiosInfo": {
     type: [ReactionCore.Schemas.correiosPackInfo]
   }
 })
if I want to add a new set of informations on the products, only visible to whom has the right to edit products?
danielortiz
@danielortiz
Oct 18 2015 04:13
anyone? =/
Aaron Judd
@aaronjudd
Oct 18 2015 14:24

@danielortiz you should be able to do something like:

ReactionCore.Schemas.Products = new SimpleSchema([
  ReactionCore.Schemas.Products, {
    "correiosInfo": {
       type: [ReactionCore.Schemas.correiosPackInfo]
     }

to add a new set of properties to the Products schema

Take a look at the Paypal package, it’s a decent example
danielortiz
@danielortiz
Oct 18 2015 23:18
cool, I tried to do something similar to this
in the end I found out that products already have a "parcel" property, with width, height, weight and length within it..it will probably enough..but anyway it's good to know how to solve that problem =)