Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
traffic-front
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangxiaoming
traffic-front
Commits
2b6738a8
Commit
2b6738a8
authored
May 08, 2019
by
weizhikai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
机构地区三级联动区县可选可不选,所以增加当前地区属于市还是区县的判断及后台查询
parent
e8f51d96
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
32 additions
and
8 deletions
+32
-8
OrganizationDto.java
...o/src/main/java/pwc/taxtech/atms/dpo/OrganizationDto.java
+11
-0
OrganizationExtendsMapper.xml
...wc/taxtech/atms/dao/extends/OrganizationExtendsMapper.xml
+2
-0
edit-organization-modal.ctrl.js
...s/edit-organization-modal/edit-organization-modal.ctrl.js
+18
-7
edit-organization-modal.html
...rols/edit-organization-modal/edit-organization-modal.html
+1
-1
No files found.
atms-dao/src/main/java/pwc/taxtech/atms/dpo/OrganizationDto.java
View file @
2b6738a8
...
...
@@ -126,6 +126,17 @@ public class OrganizationDto {
public
List
<
OrganizationDto
>
sameVehicleroutinglocationList
;
public
List
<
TaxControlDiskDto
>
taxControlDiskList
;
@JsonProperty
(
"levelType"
)
private
Integer
levelType
;
public
Integer
getLevelType
()
{
return
levelType
;
}
public
void
setLevelType
(
Integer
levelType
)
{
this
.
levelType
=
levelType
;
}
public
String
getId
()
{
return
this
.
id
;
}
...
...
atms-dao/src/main/resources/pwc/taxtech/atms/dao/extends/OrganizationExtendsMapper.xml
View file @
2b6738a8
...
...
@@ -558,6 +558,7 @@
<result
column=
"PARENT_REGION_ID"
jdbcType=
"VARCHAR"
property=
"parentRegionId"
/>
<result
column=
"AREA_NAME"
jdbcType=
"VARCHAR"
property=
"areaName"
/>
<result
column=
"BUSINESS_UNIT_NAME"
jdbcType=
"VARCHAR"
property=
"businessUnitName"
/>
<result
column=
"level_type"
jdbcType=
"INTEGER"
property=
"levelType"
/>
</resultMap>
<select
id=
"getSingleOrgByOrgIdToOrgDto"
parameterType=
"map"
resultMap=
"OrgDtoForGetSingleOrgByOrgID"
>
...
...
@@ -565,6 +566,7 @@
M.*,
N.name AS INDUSTRY_NAME,
CONCAT(PREGION.name,T.name) AS REGION_NAME,
T.level_type AS level_type,
S.name AS STRUCTURE_NAME,
T.parent_id AS PARENT_REGION_ID,
AR.name AS AREA_NAME,
...
...
atms-web/src/main/webapp/app/common/controls/edit-organization-modal/edit-organization-modal.ctrl.js
View file @
2b6738a8
...
...
@@ -303,8 +303,8 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
}
// 区域是必填项
if
(
$scope
.
selectProvince
&&
$scope
.
selectRegionID
)
{
editModel
.
regionID
=
$scope
.
selectRegionID
;
if
(
$scope
.
selectProvince
&&
(
$scope
.
selectCity
||
$scope
.
selectRegionID
)
)
{
editModel
.
regionID
=
$scope
.
selectRegionID
||
$scope
.
selectCity
.
regionID
;
}
var
pId
=
editModel
.
parentID
;
...
...
@@ -675,7 +675,11 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
$scope
.
ProvinceList
=
data
;
//根据当前机构的父级(即市的层级)获取对应的省的regionID
//目前情况为省市区三级联动,参数为$scope.editOrgModel.parentRegionID,若为省市两级联动,参数改为$scope.editOrgModel.regionID即可
areaRegionService
.
getProvincesByCityID
(
$scope
.
editOrgModel
.
parentRegionID
).
success
(
function
(
resp
)
{
var
cityIDTemp
=
$scope
.
editOrgModel
.
regionID
;
if
(
$scope
.
editOrgModel
.
levelType
==
3
){
cityIDTemp
=
$scope
.
editOrgModel
.
parentRegionID
;
}
areaRegionService
.
getProvincesByCityID
(
cityIDTemp
).
success
(
function
(
resp
)
{
if
(
resp
){
$scope
.
selectProvince
=
_
.
find
(
$scope
.
ProvinceList
,
function
(
num
)
{
return
num
.
regionID
===
resp
.
regionID
;
...
...
@@ -702,7 +706,11 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
if
(
data
&&
data
.
length
>
0
)
{
$scope
.
CityList
=
data
;
$scope
.
selectCity
=
_
.
find
(
$scope
.
CityList
,
function
(
num
)
{
return
num
.
regionID
===
$scope
.
editOrgModel
.
parentRegionID
;
if
(
$scope
.
editOrgModel
.
levelType
==
3
){
return
num
.
regionID
===
$scope
.
editOrgModel
.
parentRegionID
;
}
else
if
(
$scope
.
editOrgModel
.
levelType
==
2
){
return
num
.
regionID
===
$scope
.
editOrgModel
.
regionID
;
}
});
if
(
$scope
.
selectCity
)
{
...
...
@@ -732,16 +740,19 @@ controller('editOrganizationModalController', ['$scope', '$log', '$translate', '
if
(
target
)
{
$scope
.
selectRegionID
=
$scope
.
editOrgModel
.
regionID
;
}
else
{
$scope
.
selectRegionID
=
data
[
0
].
regionID
;
}
else
{
$scope
.
selectRegionID
=
""
;
}
}
else
{
data
=
null
;
$scope
.
DistrictList
=
data
;
$scope
.
selectRegionID
=
null
;
$scope
.
selectRegionID
=
""
;
}
});
}
else
{
$scope
.
DistrictList
=
null
;
$scope
.
selectRegionID
=
""
;
}
};
...
...
atms-web/src/main/webapp/app/common/controls/edit-organization-modal/edit-organization-modal.html
View file @
2b6738a8
...
...
@@ -463,7 +463,7 @@
</div>
<div
class=
"col-sm-3"
style=
"width: 31%"
ng-class=
"{'has-error':orgControlForm.selectDistrict.$invalid && (orgControlForm.selectDistrict.$dirty || orgControlForm.$submitted)}"
>
<select
class=
"form-control
localRequired
"
name=
"selectDistrict"
style=
"width: 90px;"
<select
class=
"form-control"
name=
"selectDistrict"
style=
"width: 90px;"
id=
"selectDistrict"
ng-model=
"selectRegionID"
>
<option
value=
""
>
{{pleaseSelect}}
</option>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment