private void AddAngularControllerCallback(object sender, EventArgs e) { string resultTitle = ""; string resultMessage = ""; OLEMSGICON icon = OLEMSGICON.OLEMSGICON_CRITICAL; var layout = "NgController.xml"; var path = Path.Combine(Strings.AngularDirectory, layout); if (!File.Exists(path)) { resultTitle = "Error"; resultMessage = "Layout file not found on disk: " + path; } else { try { var angSer = new AngularService(); var result = angSer.CreateController(path); if (!string.IsNullOrEmpty(result?.Trim())) { resultTitle = "Success"; resultMessage = $"Controller '{result}' created."; icon = OLEMSGICON.OLEMSGICON_INFO; } } catch (Exception ex) { resultTitle = "Exception"; resultMessage = ex.Message; } } VsShellUtilities.ShowMessageBox( this.ServiceProvider, resultMessage, resultTitle, icon, OLEMSGBUTTON.OLEMSGBUTTON_OK, OLEMSGDEFBUTTON.OLEMSGDEFBUTTON_FIRST); }
public AngularTagHelper(AngularService angularService, AngularServiceOptions options, IUrlHelperFactory urlHelperFactory) { this.angularService = angularService; this.options = options; this.urlHelperFactory = urlHelperFactory; }
public ScriptAngularTagHelper(AngularService angularService) { this.angularService = angularService; }