use hook
MaelVB edited this page Jul 30, 2021
·
2 revisions
If you have created your hook and you want to use it, or you just want to reuse a hook, please follow this tutorial.
The ng-repeat
directive is used in the HTML, so you just need to add a value to the variable which is used in the loop.
ProductControllers.controller("nsProductGeneral", [
"$scope", "$filter", "ClientFields", "TheSecondInjection", "SetAttributesV2", "AttributesV2", "$modal", "ProductsV2",
function ($scope, $filter, ClientFields, TheSecondInjection, SetAttributesV2, AttributesV2, $modal, ProductsV2) {
//maybe some code of the controller here
$scope.test = [ ClientFields, TheSecondInjection]; //we add a value to the scope
//maybe other some code of the controller here
}]);
Legend :
- You just made a array with two values : the old
ClientsFields
and the newTheSecondInjection
- Note two injections :
ClientsFields
andTheSecondInjection
, the injection is done twice- Note that you need to confirm the edit of
service
of the page just like above
-
Installation
-
Get started
-
Core reference
-
Themes
-
Images
-
Plugin Creation
-
Hook
- Hook
- Admin Hook
- Admin Columns Hook
- Front Hook
- Event and Hooks
-
Updating
-
Testing