Commit 1076e372 authored by frank.xa.zhang's avatar frank.xa.zhang

fixed entity page-- frank

parent 8c1d5183
......@@ -178,7 +178,7 @@
$scope.isCanOrganizationIsActiveBtn = true;
});
}
generalSelectCompanyText();
// generalSelectCompanyText();
};
// 进入高级配置编辑状态
......@@ -335,60 +335,9 @@
}
});
// var loadUserRoleList = function (orgID) {
// roleService.getUserRoleList(orgID, '', '').success(function (data) {
// // 构造用户信息
// var roleStaticsList = [];
//
// var userRoleShowList = [];
// if (data && data.length > 0) {
// data.forEach(function (row) {
//
// var uniqRoleList = _.uniq(row.roleInfoList, function (item) {
// return item.name
// });
// row.roleNameList = _.map(uniqRoleList, function (x) {
// return x.name;
// }).join(constant.comma);
//
// //var roleNames = _.pluck(row.roleInfoList, 'name');
// //row.roleNameList = roleNames.join(',');
//
// if (!row.isAccessible) {
// row.roleNameList = $translate.instant('UnAccessable');
// }
//
// row.hasEditPermission = $scope.hasEditPermission;
//
// userRoleShowList.push({id: row.id, userName: row.userName, roleNameList: row.roleNameList});
// row.roleInfoList.forEach(function (role) {
// var one = _.find(roleStaticsList, function (data) {
// return data.id === role.id;
// });
//
// if (one) {
// one.count++;
// } else {
// role.count = 1;
// roleStaticsList.push(role);
// }
// });
// });
// }
//
// $scope.roleStaticsList = roleStaticsList;
//
// $scope.userRoleList = JSON.stringify(userRoleShowList);
// $scope.userRoleGridOptions.data = data;
// //用户数统计
// $scope.userCount = data.length || 0;
// });
// };
// 选中机构
$scope.selectOrganization = function (branch) {
var org = branch.data;
$scope.output = "You selected: " + org.id;
......@@ -404,7 +353,6 @@
$scope.selectNodeCount++;
$scope.selectCompany = data;
$scope.selectCompany.isActiveStr = $translate.instant(isActiveMap[$scope.selectCompany.isActive]);
//$log.debug("org.regionID: " + org.regionID);
$scope.selectCompany.suborgList = suborgList;
$scope.backups = {};
$scope.backups.enterpriseAccountSetOrgList = angular.copy($scope.selectCompany.enterpriseAccountSetOrgList);
......@@ -438,42 +386,9 @@
$scope.selectCompany.orgAttributeRowList = orgAttributeRowList;
$scope.isInternational = $scope.selectCompany.oversea;
// $scope.editOrgExtraModel.unifiedSocialCreditCode = $scope.selectCompany.taxPayerNumber;
// $scope.selectCompanyExtra.unifiedSocialCreditCode = $scope.selectCompany.taxPayerNumber;
//加载用户权限list
// loadUserRoleList(org.id);
// generalSelectCompanyText();
cancelWebChange();
// $scope.updateOrgExtraCancel()
cancelWebChange();
});
// orgService.getSingleOrgExtra(org.id).success(function (data) {
// if (data) {
// $scope.selectCompanyExtra = data;
// $scope.editOrgExtraModel = angular.copy(data);
// // generalSelectCompanyExtraText();
// }
// });
// getEquityListByOrgId(org.id);
// todo 其他信息的grid可以移到label ng-click事件里做,lazyinit
// getTaxRuleList(org.id);
// getInvoiceInfoList(org.id);
// getReturnRateInfoList(org.id);
// getAccountingRateInfoList(org.id);
// getApprovedLevyList(org.id);
// getTaxOfficerList(org.id);
// getEmployeeList(org.id);
// getTaxpayerQualificationList(org.id);
// equityService.getChangeLogByOrgName(org.name).success(function (data) {
// if (data) {
// $scope.EquityChangeList = data;
// }
// });
};
$scope.resources = {
......
......@@ -26,7 +26,7 @@
<span class="glyphicon glyphicon-search input-group-addon"></span>
</div>
<div class="flex-0-0-auto" style="margin:5px;">
<button type="button" class="btn btn-in-panel-big" ng-click="showAll()" ng-if="hasAddPermission">{{'DisplayAll'|translate}}
<button type="button" class="btn btn-in-panel-big" ng-click="showAll()">{{'DisplayAll'|translate}}
</button>
</div>
<div class="orgpage-tree-container flex-1-1-auto">
......@@ -50,11 +50,10 @@
{{'EntityList'||translate}}</p>
</div>
<div class="right-option">
<button type="button" class="btn btn-in-grid" style="width: 117px;" ng-click="updateOrg()"
ng-if="hasEditPermission" id="orgListRefreshBtn">
<button type="button" class="btn btn-in-grid" style="width: 117px;" ng-click="updateOrg()" id="orgListRefreshBtn">
<i class="dx-icon-refresh"></i>{{'Refresh' | translate}}
</button>
<button type="button" id="organizationExportBtn" ng-if="hasEditPermission"
<button type="button" id="organizationExportBtn"
class="btn btn-in-grid" ng-click="updateIsActive()"><i
class="dx-icon-export"></i>{{'Export'||translate}}
</button>
......@@ -63,7 +62,7 @@
</div>
<div class="user-grid" style="margin-top: 10px;">
<div class="createEntityBtn">
<button type="button" class="btn btn-up-grid" ng-click="addOrg()" ng-if="hasAddPermission"><i
<button type="button" class="btn btn-up-grid" ng-click="addOrg()"><i
class="material-icons button-icons"> add_circle_outline</i> 新增机构
</button>
</div>
......@@ -85,7 +84,7 @@
</div>
<div class="right-option">
<!--<button type="button" class="btn btn-in-grid" style="width: 117px;" ng-click="updateOrg()" ng-if="hasEditPermission"><i class="material-icons middle">create</i>{{'Change' | translate}}</button>-->
<button type="button" id="organizationIsActiveBtn" ng-if="hasEditPermission" class="btn"
<button type="button" id="organizationIsActiveBtn" class="btn"
ng-class="{true:'btn-secondary', false:'btn-in-grid'}[!selectCompany.isActive]"
ng-click="updateIsActive()" ng-disabled="!isCanOrganizationIsActiveBtn"><i
ng-show="selectCompany.isActive"
......@@ -116,7 +115,7 @@
<div class="basic-org-info-wrapper">
<div class="right-option">
<button type="button" class="btn btn-in-grid" style="width: 117px;"
ng-click="updateOrg()" ng-if="hasEditPermission"><i
ng-click="updateOrg()"><i
class="material-icons middle">create</i>{{'Change' | translate}}
</button>
</div>
......@@ -316,7 +315,7 @@
</div>
<div class="right-option">
<button type="button" class="btn btn-in-grid" style="width: 117px;"
ng-click="addEquity()" ng-if="hasEditPermission"><i
ng-click="addEquity()"><i
class="material-icons middle">create</i>{{'Create' | translate}}
</button>
</div>
......@@ -338,7 +337,7 @@
</div>
<div class="right-option">
<button type="button" class="btn btn-in-grid" style="width: 117px;"
ng-click="addDirector()" ng-if="hasEditPermission"><i
ng-click="addDirector()"><i
class="material-icons middle">create</i>{{'Create' | translate}}
</button>
</div>
......
......@@ -423,10 +423,6 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
}
};
var checkSelfDimensionSetList = function () {
};
// 获取设置的DimensionValue
var getSelfDimensionSetValueList = function () {
$scope.selfDimensionError = false;
......@@ -612,27 +608,6 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
$scope.selectRegionID = defaultData;
};
// 获取账套
var loadEnterpriseAccountSetList = function () {
// enterpriseAccountService.getEnterpriseAccountSetList().success(function (data) {
// // 只获取启用状态的账套
// //data = _.filter(data, function (num) { return num.isActive });
// $scope.enterpriseAccountSetList = data;
// if (data && data.length > 0) {
// $scope.hasEnterpriseAccountSet = true;
//
// } else {
// $scope.hasEnterpriseAccountSet = false;
// }
// });
};
// 获取行业信息
var loadProjectIndustryList = function () {
orgService.getProjectIndustrys().success(function (data) {
$scope.projectIndustryList = data;
});
};
// 获取机构层级
var loadOrganizationStructureService = function () {
......@@ -1005,55 +980,6 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
return ret;
};
// 初始化选择服务选项
var initIsCheckedServiceList = function () {
$scope.isCheckedServiceList = [];
projectService.getServiceList().success(function (serviceListData) {
$scope.serviceList = serviceListData;
serviceListData.forEach(function (rowData) {
var row = {
id: rowData.id,
name: rowData.name,
templateGroupList: rowData.templateGroupList,
selectedTemplate: null,
isChecked: false,
};
$scope.isCheckedServiceList.push(row);
});
});
};
// 设置是否选择服务模板
var setIsCheckedServiceList = function (orgData) {
$scope.isCheckedServiceList = [];
projectService.getServiceList().success(function (serviceListData) {
$scope.serviceList = serviceListData;
serviceListData.forEach(function (rowData) {
var temp = _.find(orgData.organizationServiceTemplateGroupList, function (num) {
return num.serviceTypeID == rowData.id
});
var ischecked = true;
var selectTemplateID = -1;
if (temp == undefined) {
ischecked = false;
} else {
selectTemplateID = temp.templateGroupID;
}
var row = {
id: rowData.id,
name: rowData.name,
templateGroupList: rowData.templateGroupList,
selectedTemplate: _.find(rowData.templateGroupList, function (num) {
return num.id == selectTemplateID
}),
isChecked: ischecked,
};
$scope.isCheckedServiceList.push(row);
});
});
};
// 说明
$scope.resources = {
OrganizationName: $translate.instant('OrganizationName'),
......@@ -1098,20 +1024,6 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
DateMonthFormatError: $translate.instant('DateMonthFormatError')
};
// 客户代码跟着上级机构是一样的
//$scope.$watch('editOrgModel.parentName', function (newValue, oldValue) {
// if (newValue !== oldValue && newValue && newValue.length > 0 && $scope.editOrgModel.componentSelectedOrg && $scope.isAdd) {
// if ($scope.editOrgModel.componentSelectedOrg.clientCode) {
// $scope.editOrgModel.clientCode = $scope.editOrgModel.componentSelectedOrg.clientCode;
// }
// }
// if ($scope.editOrgModel.componentSelectedOrg && !$scope.isAdd) {
// // 修改机构的上级公司,不能为自己及下级节点
// }
//});
// 行业发生改变时,只有在已经做过科目对应的机构,且行业是非房地产和房地产 切换时,才需要给出需要重新做科目对应的提示
$scope.ProjectIndustryChanged = function () {
......@@ -1242,13 +1154,6 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
}
};
// 获取所有维度值和维度值配置信息
// var getAllDimensionList = function () {
// dimensionService.getAllDimensionList().success(function (data) {
// $scope.dimensionList = data;
// });
// };
// 获取添加自定义纬度列表
var getAddOrgSetDimension = function () {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment