|
|
@@ -145,14 +145,15 @@ function($scope, $rootScope, $state, $stateParams, $filter, orgService, enumServ
|
|
145
|
145
|
// 获取组织信息
|
|
146
|
146
|
$scope.loadOrg = function() {
|
|
147
|
147
|
orgService.editOrg($stateParams.orgId).then(function(data) {
|
|
148
|
|
- $scope.orgInfo = data;
|
|
|
148
|
+ $scope.orgInfo = {};
|
|
149
|
149
|
$scope.initBasic(319);
|
|
150
|
|
- if (!$stateParams.orgId) {
|
|
|
150
|
+ if ($stateParams.orgId == "") {
|
|
151
|
151
|
$scope.orgInfo.parentId = $stateParams.parentId;
|
|
152
|
152
|
//$scope.orgInfo.registDate = new Date();
|
|
153
|
153
|
$scope.orgInfo.infoRegist = $rootScope.userInfo.realName;
|
|
154
|
154
|
$scope.orgInfo.depotProperty = "1";
|
|
155
|
155
|
} else {
|
|
|
156
|
+ $scope.orgInfo = data;
|
|
156
|
157
|
$scope.setArea($scope.orgInfo.areaCode);
|
|
157
|
158
|
$scope.orgInfo.registDate = $filter('date')($scope.orgInfo.registDate, "yyyy-MM-dd");
|
|
158
|
159
|
$scope.orgInfo.completeDate = $filter('date')($scope.orgInfo.completeDate, "yyyy-MM-dd");
|