1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
| /**
| * Created by wisestone on 2018-11-05.
| */
| 'use strict';
|
| define(['app'],
| function (app) {
| app.directive('myIssueWidget', ['$log', '$rootScope',
| function ($log, $rootScope) {
| return {
| restrict : 'E',
| scope : {
| myIssueWidget : '=',
| },
| replace : true,
| templateUrl : '../custom_components/widget/my-issue-widget/my-issue-widget.html',
| controller : function ($scope, $element, $attrs) {
|
| // 변수 모음
| $scope.vm = {
| myIssueWidget : {}
| };
|
| // 함수 모음
| $scope.fn = {};
|
| // 나의 이슈 현황 정보가 변경될때 감지한다.
| $scope.$watch("myIssueWidget", function (newValue) {
| if ($rootScope.isDefined(newValue)) {
| // 나의 이슈 현황 정보를 저장한다.
| $scope.vm.myIssueWidget = newValue;
| }
| });
| },
| link : function (scope, element, attrs) {
|
| }
| };
| }])
| });
|
|