當前位置: 首頁>>代碼示例>>TypeScript>>正文


TypeScript state.provider.ApplicationStateProvider.addChildState方法代碼示例

本文整理匯總了TypeScript中core/application/application.state.provider.ApplicationStateProvider.addChildState方法的典型用法代碼示例。如果您正苦於以下問題:TypeScript state.provider.ApplicationStateProvider.addChildState方法的具體用法?TypeScript state.provider.ApplicationStateProvider.addChildState怎麽用?TypeScript state.provider.ApplicationStateProvider.addChildState使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在core/application/application.state.provider.ApplicationStateProvider的用法示例。


在下文中一共展示了state.provider.ApplicationStateProvider.addChildState方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。

示例1: require

]).config((applicationStateProvider: ApplicationStateProvider) => {

  const taskDetails: INestedState = {
    name: 'taskDetails',
    url: '/:taskId',
    views: {},
    data: {
      pageTitleDetails: {
        title: 'Task Details',
        nameParam: 'taskId'
      }
    }
  };

  const tasks: INestedState = {
    name: 'tasks',
    url: '/tasks',
    views: {
      'insight': {
        templateUrl: require('../task/tasks.html'),
        controller: 'TasksCtrl',
        controllerAs: 'tasks'
      },
    },
    data: {
      pageTitleSection: {
        title: 'Tasks'
      }
    },
    children: [taskDetails],
  };

  applicationStateProvider.addChildState(tasks);
});
開發者ID:brujoand,項目名稱:deck,代碼行數:34,代碼來源:task.states.ts

示例2: require

]).config((applicationStateProvider: ApplicationStateProvider) => {

  const detailTabsPanel: INestedState = {
    name: 'detailTab',
    url: '/:tab',
    views: {
      'detailTab': {
        templateUrl: require('./detail/detailTab/detailTabView.html'),
        controller: 'CiDetailTabCtrl',
        controllerAs: 'ctrl',
      }
    }
  };

  const detailPanel: INestedState = {
    name: 'detail',
    url: '/detail/:buildId',
    views: {
      'detail': {
        templateUrl: require('./detail/detailView.html'),
        controller: 'CiDetailCtrl',
        controllerAs: 'ctrl'
      }
    },
    children: [
      detailTabsPanel
    ]
  };

  const appCI: INestedState = {
    name: 'ci',
    url: '/ci',
    views: {
      'insight': {
        templateUrl: require('./ci.html'),
        controller: 'NetflixCiCtrl',
        controllerAs: 'ctrl'
      }
    },
    data: {
      pageTitleSection: {
        title: 'CI'
      }
    },
    children: [
      detailPanel
    ]
  };

  applicationStateProvider.addChildState(appCI);
});
開發者ID:brujoand,項目名稱:deck,代碼行數:51,代碼來源:ci.states.ts

示例3: require

]).config((applicationStateProvider: ApplicationStateProvider, stateConfigProvider: StateConfigProvider) => {

  const appState: INestedState = {
    name: 'analytics',
    url: '/analytics',
    reloadOnSearch: false,
    views: {
      'insight': {
        templateUrl: require('./application/appTableau.html'),
        controller: 'AppTableauCtrl as ctrl',
      }
    },
    data: {
      pageTitleSection: {
        title: 'Analytics'
      }
    },
  };

  const summaryState: INestedState = {
    name: 'analytics',
    url: '/analytics',
    reloadOnSearch: false,
    views: {
      'main@': {
        templateUrl: require('./summary/summaryTableau.html'),
        controller: 'SummaryTableauCtrl as ctrl',
      }
    },
    data: {
      pageTitleSection: {
        title: 'Analytics'
      }
    },
  };

  applicationStateProvider.addChildState(appState);
  stateConfigProvider.addToRootState(summaryState);
});
開發者ID:jtk54,項目名稱:deck,代碼行數:39,代碼來源:tableau.states.ts

示例4: module

module(TASK_STATES, [APPLICATION_STATE_PROVIDER]).config((applicationStateProvider: ApplicationStateProvider) => {
  const taskDetails: INestedState = {
    name: 'taskDetails',
    url: '/:taskId',
    views: {},
    data: {
      pageTitleDetails: {
        title: 'Task Details',
        nameParam: 'taskId',
      },
    },
  };

  const tasks: INestedState = {
    name: 'tasks',
    url: '/tasks?q',
    views: {
      insight: {
        templateUrl: require('../task/tasks.html'),
        controller: 'TasksCtrl',
        controllerAs: 'tasks',
      },
    },
    params: {
      q: { dynamic: true, value: null },
    },
    data: {
      pageTitleSection: {
        title: 'Tasks',
      },
    },
    children: [taskDetails],
  };

  applicationStateProvider.addChildState(tasks);
});
開發者ID:mizzy,項目名稱:deck,代碼行數:36,代碼來源:task.states.ts

示例5: require


//.........這裏部分代碼省略.........
    children: [
      applicationFastPropertyDetails
    ]
  };

  const propInsights: INestedState = {
    name: 'propInsights',
    abstract: true,
    views: {
      'insight': {
        templateUrl: require('./mainApplicationProperties.html'),
      }
    },
    data: {
      pageTitleSection: {
        title: 'Fast Properties'
      }
    },
    children: [
      applicationFastProperty
    ]
  };

  const globalFastPropertyDetails: INestedState = {
    name: 'globalFastPropertyDetails',
    url: '/:propertyId',
    reloadOnSearch: true,
    views: {
      'detail@../data': {
        templateUrl: require('./view/fastPropertyDetails.html'),
        controller: 'FastPropertiesDetailsController',
        controllerAs: 'details'
      }
    },
    resolve: {
      fastProperty: ['$stateParams', ($stateParams: IPropertyDetailsStateParams) => {
        return {
          propertyId: $stateParams.propertyId,
        };
      }]
    },
    data: {
      pageTitleDetails: {
        title: 'Fast Property Details',
        propertyId: 'propertyId',
        accountParam: 'accountId',
        regionParam: 'region'
      },
      history: {
        type: 'properties',
      },
    }
  };


  const globalFastProperties: INestedState = {
    name: 'properties',
    url: '/properties',
    reloadOnSearch: false,
    views: {
      'master': {
        templateUrl: require('./view/properties.html'),
        controller: 'FastPropertiesController',
        controllerAs: 'fp'
      }
    },
    children: [
      globalFastPropertyDetails
    ]
  };

  const data: INestedState = {
    name: 'data',
    url: '/data',
    reloadOnSearch: false,
    views: {
      'main@': {
        templateUrl: require('./dataNav/main.html'),
      }
    },
    data: {
      pageTitleMain: {
        label: 'Properties'
      }
    },
    resolve: {
      app: (): any => {
        return null;
      }
    },
    children: [
      globalFastProperties,
      globalFastPropertyRollouts,
    ]
  };

  applicationStateProvider.addChildState(globalFastPropertyRollouts);
  applicationStateProvider.addChildState(propInsights);
  stateConfigProvider.addToRootState(data);
});
開發者ID:brujoand,項目名稱:deck,代碼行數:101,代碼來源:fastProperties.states.ts

示例6: require

  (applicationStateProvider: ApplicationStateProvider, stateConfigProvider: StateConfigProvider) => {
    const pipelineConfig: INestedState = {
      name: 'pipelineConfig',
      url: '/configure/:pipelineId?executionId&new',
      views: {
        pipelines: {
          templateUrl: require('../pipeline/config/pipelineConfig.html'),
          controller: 'PipelineConfigCtrl',
          controllerAs: 'vm',
        },
      },
      data: {
        pageTitleSection: {
          title: 'pipeline config',
        },
      },
    };

    // a specific stage can be deep linked by providing either refId or stageId,
    // which will be resolved to stage or step by the executionDetails controller to stage/step parameters,
    // replacing the URL
    const executionDetails: INestedState = {
      name: 'execution',
      url: '/:executionId?refId&stage&subStage&step&details&stageId',
      params: {
        stage: {
          value: '0',
        },
        step: {
          value: '0',
        },
      },
      data: {
        pageTitleDetails: {
          title: 'Execution Details',
          nameParam: 'executionId',
        },
      },
    };

    const singleExecutionDetails: INestedState = {
      name: 'executionDetails',
      url: '/details',
      views: {
        pipelines: { component: SingleExecutionDetails, $type: 'react' },
      },
      params: {
        executionParams: null,
      },
      abstract: true,
      children: [executionDetails],
    };

    const executions: INestedState = {
      name: 'executions',
      url: `?startManualExecution&${stateConfigProvider.paramsToQuery(filterModelConfig)}`,
      views: {
        pipelines: { component: Executions, $type: 'react' },
      },
      params: stateConfigProvider.buildDynamicParams(filterModelConfig),
      children: [executionDetails],
      data: {
        pageTitleSection: {
          title: 'Pipeline Executions',
        },
      },
    };

    const pipelines: INestedState = {
      name: 'pipelines',
      url: '/executions',
      abstract: true,
      views: {
        insight: {
          template: '<div ui-view="pipelines" sticky-headers class="flex-fill"></div>',
        },
      },
      children: [executions, pipelineConfig, singleExecutionDetails],
    };

    applicationStateProvider.addChildState(pipelines);
  },
開發者ID:spinnaker,項目名稱:deck,代碼行數:82,代碼來源:pipeline.states.ts

示例7: require

]).config((applicationStateProvider: ApplicationStateProvider) => {

  const pipelineConfig: INestedState = {
    name: 'pipelineConfig',
    url: '/configure/:pipelineId',
    views: {
      'pipelines': {
        templateUrl: require('../pipeline/config/pipelineConfig.html'),
        controller: 'PipelineConfigCtrl',
        controllerAs: 'vm',
      },
    },
    data: {
      pageTitleSection: {
        title: 'pipeline config'
      }
    }
  };

  // a specific stage can be deep linked by providing either refId or stageId,
  // which will be resolved to stage or step by the executionDetails controller to stage/step parameters,
  // replacing the URL
  const executionDetails: INestedState = {
    name: 'execution',
    url: '/:executionId?refId&stage&step&details&stageId',
    params: {
      stage: {
        value: '0',
      },
      step: {
        value: '0',
      }
    },
    data: {
      pageTitleDetails: {
        title: 'Execution Details',
        nameParam: 'executionId'
      }
    }
  };

  const singleExecutionDetails: INestedState = {
    name: 'executionDetails',
    url: '/details',
    views: {
      'pipelines': {
        templateUrl: require('./details/singleExecutionDetails.html'),
        controller: 'SingleExecutionDetailsCtrl',
        controllerAs: 'vm',
      },
    },
    abstract: true,
    children: [executionDetails],
  };

  const executions: INestedState = {
    name: 'executions',
    url: '',
    views: {
      'pipelines': {
        template: '<executions application="application"></executions>',
      },
    },
    children: [executionDetails],
    data: {
      pageTitleSection: {
        title: 'Pipeline Executions'
      }
    }
  };

  const pipelines: INestedState = {
    name: 'pipelines',
    url: '/executions',
    abstract: true,
    views: {
      'insight': {
        template: '<div ui-view="pipelines" sticky-headers class="flex-fill"></div>'
      }
    },
    children: [executions, pipelineConfig, singleExecutionDetails]
  };

  applicationStateProvider.addChildState(pipelines);
});
開發者ID:brujoand,項目名稱:deck,代碼行數:85,代碼來源:delivery.states.ts


注:本文中的core/application/application.state.provider.ApplicationStateProvider.addChildState方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。