Explorar o código

Merge branch 'feature-201846-hejq' into release-hejq-201846

wangcz %!s(int64=7) %!d(string=hai) anos
pai
achega
8e8367f4f8

+ 7 - 2
src/main/webapp/resources/js/index/app.js

@@ -12435,6 +12435,13 @@ define(['toaster', 'charts', 'ngTable', 'common/services', 'common/directives',
 
         };
 
+        $scope.closeNewUser = function () {
+            $scope.newUser.userTel = '';
+            $scope.newUser.userEmail = '';
+            $scope.newUser.userName = '';
+            $scope.adding = true;
+        }
+
 
         /**
          * 添加未注册用户
@@ -12455,8 +12462,6 @@ define(['toaster', 'charts', 'ngTable', 'common/services', 'common/directives',
                 $scope.newUserForm.newUserEmail.$setValidity('available', false);
                 $scope.userTelSuccess = false;
                 $scope.userTelError = false;
-                $scope.userEmailSuccess = false;
-                $scope.userEmailError = false;
             }, function (response) {
             	$scope.submit = false;
             	$scope.loading = false;

+ 4 - 5
src/main/webapp/resources/tpl/index/approvalFlow/user.html

@@ -350,12 +350,11 @@
 					添加用户
 				</a>
 				<ul ng-show="adding != true" class="list-unstyle list-inline operator-menu2">
-					<li><a ng-click="adding = true">添加未注册用户</a></li>
+					<li><a ng-click="closeNewUser()">添加未注册用户</a></li>
 					<li><a ng-click="addExistUser()">添加已注册用户</a></li>
 				</ul>
 			</div>
 			<!-- 添加用户 end -->
-
 		</div>
 	</div>
 	<div class="pane-body" id="order-detail-list">
@@ -382,7 +381,7 @@
 					</tr>
 				</thead>
 				<tbody>
-					<tr ng-show="adding">
+					<tr ng-if="adding">
 						<td class="text-center">
 							<div style="line-height: 30px;">系统生成</div>
 						</td>
@@ -402,7 +401,7 @@
 							ng-class="{'has-error': userTelError, 'has-success': userTelSuccess}">
 							<input ng-model="newUser.userTel"
 							ng-blur="telValid(newUser.userTel)" required name="newUserTel"
-							class="form-control input-sm" ng-pattern="/^1[3|4|5|7|8]\d{9}$/" type="text" placeholder="手机号">
+							class="form-control input-sm" ng-pattern="/^1\d{10}$/" type="text" placeholder="手机号">
 						</td>
 						<td class="text-center"
 							ng-class="{'has-error': userEmailError, 'has-success': userEmailSuccess}">
@@ -420,7 +419,7 @@
 						<!--<td class="text-center" ng-bind="::u.userSex == 'F' ? '女' : '男'"></td>-->
 						<!--<td class="text-center" ng-bind="::u.userIdcode"></td>-->
 						<td class="text-center" ng-bind="::u.userTel"></td>
-						<td class="text-center" ng-bind="::u.userEmail"></td>
+						<td class="text-center" ng-bind="::u.userEmail || '-'"></td>
 						<td class="user-role">
 							<div class="role-item" ng-repeat="role in u.roles"
 								 title="{{role.desc}}">