// 打印 $scope.showPrint = false; //打印内容的显示状态 $scope.printFn = function(){ $scope.showPrint = true; var obj = angular.element('#print'); var newWindow = window.open("订单打印","_blank"); var docStr = obj.html(); newWindow.document.write(docStr); newWindow.document.close(); newWindow.print(); newWindow.close(); $scope.showPrint = false; } <!-- 打印内容页面 --> <div id="print" ng-show="showPrint" style=" 100%;"> hello world! 这是打印页面内容 </div>