开发者

Doctrine 1.2: Can a model have two instances of the sluggabl behavior?

I dont see any direct mention on using multiple slugs (or any behavior for that matter) for single model. Is there a way to use the sluggable behavior to generate two separate slugs for a model?

For example i need to generate two slugs for every record a product_id consisting of a slugified company name and sku and a distributor_id consisting of a different slugified company name.

Obviously i could write t开发者_高级运维his myself fairly easily, im just wondering if this can be done quickly with Sluggable.


Yes, you can have multiple slugs... read my answer for similar question: Can a table have multiple slugs in Doctrine?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜