diff options
| author | Lester Caine <lester@lsces.co.uk> | 2026-06-02 17:15:16 +0100 |
|---|---|---|
| committer | Lester Caine <lester@lsces.co.uk> | 2026-06-02 17:15:16 +0100 |
| commit | 08f901e00b0627157318decfcde8f63491a26d33 (patch) | |
| tree | 2a9403396992ce2726d403afe69b152e14fef65c /includes | |
| parent | 7a2de113969c0e90626f569ea620c4c6927a0991 (diff) | |
| download | stock-08f901e00b0627157318decfcde8f63491a26d33.tar.gz stock-08f901e00b0627157318decfcde8f63491a26d33.tar.bz2 stock-08f901e00b0627157318decfcde8f63491a26d33.zip | |
Move all stock CONTENT_TYPE_GUID defines to StockBase
StockBase is always loaded first; defining all three constants there
avoids files depending on each other's load order.
Removed duplicate defines from StockComponent and StockMovement.
Reverted spurious use StockComponent from edit_assembly.php.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'includes')
| -rwxr-xr-x | includes/classes/StockBase.php | 4 | ||||
| -rwxr-xr-x | includes/classes/StockComponent.php | 2 | ||||
| -rw-r--r-- | includes/classes/StockMovement.php | 2 |
3 files changed, 3 insertions, 5 deletions
diff --git a/includes/classes/StockBase.php b/includes/classes/StockBase.php index f9d7c71..1d6c191 100755 --- a/includes/classes/StockBase.php +++ b/includes/classes/StockBase.php @@ -10,7 +10,9 @@ namespace Bitweaver\Stock; use Bitweaver\Liberty\LibertyContent; -defined( 'STOCKASSEMBLY_CONTENT_TYPE_GUID' ) || define( 'STOCKASSEMBLY_CONTENT_TYPE_GUID', 'stockassembly' ); +defined( 'STOCKASSEMBLY_CONTENT_TYPE_GUID' ) || define( 'STOCKASSEMBLY_CONTENT_TYPE_GUID', 'stockassembly' ); +defined( 'STOCKCOMPONENT_CONTENT_TYPE_GUID' ) || define( 'STOCKCOMPONENT_CONTENT_TYPE_GUID', 'stockcomponent' ); +defined( 'STOCKMOVEMENT_CONTENT_TYPE_GUID' ) || define( 'STOCKMOVEMENT_CONTENT_TYPE_GUID', 'stockmovement' ); /** * @package stock diff --git a/includes/classes/StockComponent.php b/includes/classes/StockComponent.php index 08ebf2b..c9c7adb 100755 --- a/includes/classes/StockComponent.php +++ b/includes/classes/StockComponent.php @@ -11,8 +11,6 @@ namespace Bitweaver\Stock; use Bitweaver\Liberty\LibertyContent; use Bitweaver\BitBase; -define('STOCKCOMPONENT_CONTENT_TYPE_GUID', 'stockcomponent'); - /** * @package stock */ diff --git a/includes/classes/StockMovement.php b/includes/classes/StockMovement.php index 8918e8c..933f11b 100644 --- a/includes/classes/StockMovement.php +++ b/includes/classes/StockMovement.php @@ -8,8 +8,6 @@ namespace Bitweaver\Stock; use Bitweaver\BitBase; use Bitweaver\Liberty\LibertyContent; -define( 'STOCKMOVEMENT_CONTENT_TYPE_GUID', 'stockmovement' ); - /** * @package stock */ |
