Project

General

Profile

Actions

Feature proposal #5825

closed

Replace type, subtype, ittem, and parent with asset

Added by krileon over 8 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
High
Assignee:
Target version:
Start date:
01 March 2016
Due date:
% Done:

100%

Estimated time:

Description

Replace the relationship columns type, subtype, item, and parent with a single asset column. This can help eliminate issues of using 1 column, but not another. Migration will be needed and the assets need to be properly constructed as follows (general; it really depends on the usage exactly).

type.subtype.parent.item

Example usage.

Type: groupjive
SubType: group.wall
Item: 42
Parent: 15

Asset: groupjive.group.15.wall.42

Query to grab all activity of a specific group could be LIKE 'groupjive.group.15%'.

Type: gallery
SubType: photos
Item: 52

Asset: gallery.photos.52


Related issues 2 (0 open2 closed)

Related to CB Gallery - Feature proposal #5310: Extend the database structureClosedkrileon03 June 2015

Actions
Precedes CB Activity - Feature proposal #5987: Implement support for asset on menu and field usagesClosedkrileon02 March 201602 March 2016

Actions
Actions #1

Updated by krileon over 8 years ago

Actions #2

Updated by krileon over 8 years ago

Additionally a new trigger should be implemented on stream construct that lets additional steam objects to be built based off asset. So if the asset is profile.user_id it should add a user object to the stream params as asset_object, asset_user, target, or something of the sort that can be used to get further information about the asset. This could then be used in CB Auto Actions for example as [var1_asset_user_id] or [var1_asset_user_username].

Actions #3

Updated by krileon over 8 years ago

Actions #4

Updated by krileon about 8 years ago

Comments of an activity entry should also always be activity.ACTIVITY_ID. In the case of CB Gallery it needs to change the asset source for the comments before they're output so that the comments become linked to the gallery entry. This same usage should be applied to tags, etc..

Then when outputting comments of an activity entry it should grab all comments linked to activity.ACTIVITY_ID AND to the asset. This means "profile.42" comments would show basically on every status post for user 42. So usage should be done with care.

Actions #5

Updated by krileon almost 8 years ago

  • % Done changed from 0 to 50
Actions #6

Updated by krileon almost 8 years ago

  • % Done changed from 50 to 60

Implement support for array of assets. The API it self strictly uses "assets" instead of "asset" now and treats all of its handling as array. For the asset for storage you use ->asset() which returns the first asset of ->assets(). This means the first asset given in an array is determined for storage, etc.. Parameter usages can supply a comma separated list of assets.

Actions #7

Updated by krileon almost 8 years ago

CB GroupJive Migration CONCAT: CONCAT_WS( '.', 'groupjive.group', IF( `parent` != '', `parent`, `item` ), IF( `subtype` != '', IF( `subtype` != 'group', REPLACE( `subtype`, 'group.', '' ), NULL ), NULL ), IF( `parent` != '', `item`, NULL ) )

Actions #8

Updated by krileon almost 8 years ago

  • Status changed from Assigned to Resolved
  • % Done changed from 60 to 100
Actions #9

Updated by krileon over 7 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF