<div class="modal center">
<div cg-busy="{promise:myPromise,message:'正在加载...'}"></div>
	<div class="modal-dialog">
		<div class="modal-content">
			<div class="modal-header">
				<button type="button" class="close" aria-label="Close" ng-click="$hide()">
					<span aria-hidden="true">×</span>
				</button>
				<h4 class="modal-title">提交审核结果</h4>
			</div>
			<div class="modal-body">
				<form class="form-horizontal" name="markForm">
				    <div class="form-group">
					    <label class="col-sm-3 control-label">审核意见</label>
					    <div class="col-sm-9">
					    	<label><input type="radio" ng-model="workflow.auditResult" value="2" ng-required="true"> 通过</label>
					    	<label><input type="radio" ng-model="workflow.auditResult" value="4" ng-required="true"> 驳回</label>
					    </div>
				     </div>
				    <div class="form-group" ng-show="task.status != 'TO_ARCHIVE' || workflow.auditResult == 4">
					    <label class="col-sm-3 control-label">下一个处理人</label>
					    <div class="col-sm-9">
					      <select class="form-control" ng-model="workflow.nextDealer" ng-if="workflow.auditResult == 2">
				      		<option ng-repeat="dealer in task.nextDealers" value="{{dealer.id}}" 
				      			ng-selected="{{dealer.id==task.defaultNextDealer}}" >
				      			{{dealer.name}}
			      			</option>
		      			  </select>
		      			
					      <select class="form-control" ng-model="workflow.nextDealer" ng-if="workflow.auditResult == 4">
				      		<option ng-repeat="dealer in task.preDealers" value="{{dealer.id}}" 
				      			ng-selected="{{dealer.id==task.defaultNextDealer}}">
				      			{{dealer.name}}
			      			</option>
		      			  </select>
					    </div>
				     </div>
					 <div class="form-group">
					    <label for="remark" class="col-sm-3 control-label">备注</label>
					    <div class="col-sm-9">
					    	<textarea id="remark" class="form-control" ng-model="workflow.remark" rows="3">
					    	</textarea>
					    </div>
					  </div>
				</form>
			</div>
			<div class="modal-footer">
				<button type="submit" ng-disabled="markForm.$invalid" ng-click="workflowAudit()" class="btn btn-info" >提交</button>
				<button type="submit" ng-click="$hide()" class="btn btn-default" >取消</button>
			</div>
		</div>
	</div>
</div>