Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
Y
YX_IDENT_beijing_auxiliary_YD
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhangyusheng
YX_IDENT_beijing_auxiliary_YD
Commits
21ff10e8
Commit
21ff10e8
authored
Jan 13, 2020
by
liboyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
机器受理包导入以及解析,打印封签派出所名称后面加机器号
parent
b6995b55
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
330 additions
and
2 deletions
+330
-2
app.js
src/main/resources/static/js/app.js
+4
-0
service.js
src/main/resources/static/js/service.js
+72
-0
machinePackageImport.html
...atic/views/machinePackageImport/machinePackageImport.html
+125
-0
machinePackageImport.js
...static/views/machinePackageImport/machinePackageImport.js
+125
-0
tagPrint.js
src/main/resources/static/views/tagPrint/tagPrint.js
+4
-2
No files found.
src/main/resources/static/js/app.js
View file @
21ff10e8
...
...
@@ -46,6 +46,7 @@ angular.module('AvatarCheck', [
'AvatarCheck.greenPackageInfo'
,
"AvatarCheck.confirmNotDeliveredInfo"
,
'AvatarCheck.getPoliceList'
,
"AvatarCheck.machinePackageImport"
,
'AvatarCheck.blank'
]).
config
([
'$locationProvider'
,
'$routeProvider'
,
'localStorageServiceProvider'
,
'$qProvider'
,
function
(
$locationProvider
,
$routeProvider
,
localStorageServiceProvider
,
$qProvider
)
{
$locationProvider
.
hashPrefix
(
'!'
);
...
...
@@ -232,6 +233,9 @@ angular.module('AvatarCheck', [
if
(
$location
.
path
()
==
"/getPoliceList"
){
$rootScope
.
tab
=
'/getPoliceList'
;
}
if
(
$location
.
path
()
==
"/machinePackageImport"
){
$rootScope
.
tab
=
'/machinePackageImport'
;
}
...
...
src/main/resources/static/js/service.js
View file @
21ff10e8
...
...
@@ -387,6 +387,78 @@ angular.module('AvatarCheck.http', ['ngDialog', 'LocalStorageModule'])
success
(
response
.
data
)
})
},
ReadMachineInfoData
:
function
(
fd
,
importName
,
success
){
$http
({
method
:
'POST'
,
url
:
"../ReadExcel/ReadMachineAcceptList?name="
+
importName
,
data
:
fd
,
headers
:
{
'Content-Type'
:
undefined
},
transformRequest
:
angular
.
identity
}).
then
(
function
successCallback
(
response
)
{
success
(
response
.
data
)
})
},
selectMachinePackageCount
:
function
(
fileName
,
state
,
date
,
success
){
if
(
angular
.
isUndefined
(
fileName
)){
fileName
=
''
;
}
if
(
angular
.
isUndefined
(
state
)
||
state
==
''
){
state
=-
1
;
}
if
(
date
==
'{{choseDate}}'
){
date
=
$filter
(
"date"
)(
new
Date
(),
"yyyy-MM-dd"
);
}
console
.
log
(
fileName
,
state
,
date
)
$http
({
method
:
'GET'
,
url
:
"../ReadExcel/queryMachineAcceptListCount"
+
urlTimeStamp
(),
params
:{
fileName
:
fileName
,
analysisState
:
state
,
uploadDate
:
date
}
}).
then
(
function
successCallback
(
response
)
{
success
(
response
.
data
)
})
},
deleteMachineAcceptListByFileId
:
function
(
fileId
,
success
){
console
.
log
(
fileId
);
$http
({
method
:
'GET'
,
url
:
"../ReadExcel/deleteMachineAcceptListByFileId "
+
urlTimeStamp
(),
params
:{
fileId
:
fileId
}
}).
then
(
function
successCallback
(
response
)
{
console
.
log
(
response
.
data
)
success
(
response
.
data
)
})
},
selectMachinePackage
:
function
(
fileName
,
state
,
currentPage
,
itemsPerPage
,
date
,
success
){
if
(
angular
.
isUndefined
(
fileName
)){
fileName
=
''
;
}
if
(
angular
.
isUndefined
(
state
)
||
state
==
''
){
state
=-
1
;
}
if
(
date
==
'{{choseDate}}'
){
date
=
$filter
(
"date"
)(
new
Date
(),
"yyyy-MM-dd"
);
}
console
.
log
(
fileName
,
state
,
currentPage
,
itemsPerPage
,
date
)
$http
({
method
:
'GET'
,
url
:
"../ReadExcel/queryMachineAcceptList"
+
urlTimeStamp
(),
params
:{
fileName
:
fileName
,
analysisState
:
state
,
currPage
:
currentPage
,
pageSize
:
itemsPerPage
,
uploadDate
:
date
}
}).
then
(
function
successCallback
(
response
)
{
success
(
response
.
data
)
})
},
selectAnalyseLogCount
:
function
(
oldPackageName
,
date
,
success
)
{
if
(
angular
.
isUndefined
(
oldPackageName
)){
oldPackageName
=
''
;
...
...
src/main/resources/static/views/machinePackageImport/machinePackageImport.html
0 → 100644
View file @
21ff10e8
<style>
.table
th
,
.table
td
{
text-align
:
center
;
vertical-align
:
middle
!important
;
}
.ul
li
{
cursor
:
pointer
;
}
.page-list
.pagination
{
float
:
left
;}
.page-list
.pagination
span
{
cursor
:
pointer
;}
.page-list
.pagination
.separate
span
{
cursor
:
default
;
border-top
:
none
;
border-bottom
:
none
;}
.page-list
.pagination
.separate
span
:hover
{
background
:
none
;}
.page-list
.page-total
{
float
:
left
;
margin
:
25px
20px
;}
.page-list
.page-total
input
,
.page-list
.page-total
select
{
height
:
26px
;
border
:
1px
solid
#ddd
;}
.page-list
.page-total
input
{
width
:
40px
;
padding-left
:
3px
;}
.page-list
.page-total
select
{
width
:
50px
;}
.page-list
:after
{
display
:
block
;
clear
:
both
;
content
:
""
}
.page-list
{
zoom
:
1
}
</style>
<div
class=
"content row"
>
<div
class=
"col-md-12"
style=
"margin-top:20px;"
>
<div
class=
"box"
>
<strong
class=
"box-header with-border"
>
导入机器受理包文件
</strong>
<div
class=
"box box-primary"
>
<table
class=
"table table-bordered"
>
<tr>
<td
width=
"15%"
>
选择文件:
</td>
<td
width=
"40%"
>
<input
type=
"file"
id=
"id_file_photo_for_check"
class=
"file"
data-show-preview=
"false"
data-allowed-file-extensions=
'["XLS","xls","XLSX","xlsx"]'
multiple
/>
</td>
<td>
<div
style=
"float: left"
>
<button
class=
"btn btn-primary"
ng-click=
"ReadMachineInfo()"
>
导入
</button>
</div>
</td>
</tr>
</table>
</div>
</div>
<div
class=
"box "
>
<strong
class=
"box-header with-border"
>
机器受理包文件管理
</strong>
<div
class=
"box box-primary"
style=
"margin-bottom: 0;"
>
<table
class=
"table table-bordered"
style=
"margin-bottom: 0;"
>
<tr>
<td>
上传时间:
</td>
<td>
<div
class=
"input-group date"
>
<div
class=
"input-group-addon"
>
<i
class=
"fa fa-calendar"
></i>
</div>
<input
type=
"text"
class=
"form-control pull-right"
id=
"datepicker"
value=
"{{choseDate}}"
readonly
/>
<span
class=
"input-group-addon"
><span
class=
"glyphicon glyphicon-remove"
></span></span>
</div>
</td>
<td>
文件名称:
</td>
<td>
<input
type=
"text"
class=
"form-control"
ng-model=
"fileName"
placeholder=
"文件名称"
>
</td>
<td>
状态:
</td>
<td>
<select
class=
"form-control select2"
id=
"state"
ng-model=
"state"
>
<option
value=
""
>
--请选择解析状态--
</option>
<option
value=
"1"
>
已解析
</option>
<option
value=
"0"
>
未解析
</option>
</select>
</td>
<td>
<button
class=
"btn btn-primary"
ng-click=
"getMachinePackage()"
>
查询
</button>
</td>
</tr>
</table>
</div>
<div
class=
"box-info"
style=
"padding-top: 0;"
>
<table
class=
"table table-bordered table-hover postTable"
ng-if=
"machinePackageData.length>0"
>
<thead>
<tr>
<th>
NO.
</th>
<th>
订单起始日期
</th>
<th>
订单截至日期
</th>
<th>
文件名
</th>
<th>
上传时间
</th>
<th>
解析状态
</th>
<th>
操作
</th>
</tr>
</thead>
<tbody>
<tr
ng-repeat=
"item in machinePackageData"
>
<td>
{{$index+1}}
</td>
<td>
{{item.formStartTime | myDateFilter}}
</td>
<td>
{{item.formDeadline| myDateFilter}}
</td>
<td>
{{item.fileName}}
</td>
<td>
{{item.uploadDate | myDateFilter}}
</td>
<td
ng-if=
"item.state==0"
>
未解析
</td>
<td
ng-if=
"item.state==1"
>
已解析
</td>
<td>
<button
class=
"btn btn-danger"
ng-disabled=
"item.state==1"
ng-click=
"deleteMachineData(item.fileId,item.uploadDate)"
>
删除
</button>
</td>
</tr>
</tbody>
</table>
<div
style=
"padding-left: 27%;"
ng-if=
"machinePackageData.length>0"
>
<tm-pagination
conf=
"paginationConf"
class=
"ul"
></tm-pagination>
</div>
<div
class=
"box-body"
ng-if=
"machinePackageData.length==0"
><h4>
暂无记录
</h4></div>
</div>
</div>
</div>
</div>
\ No newline at end of file
src/main/resources/static/views/machinePackageImport/machinePackageImport.js
0 → 100644
View file @
21ff10e8
'use strict'
;
angular
.
module
(
"AvatarCheck.machinePackageImport"
,[
'ngRoute'
,
'AvatarCheck.http'
])
.
config
([
'$routeProvider'
,
function
(
$routeProvider
){
$routeProvider
.
when
(
'/machinePackageImport'
,
{
templateUrl
:
'views/machinePackageImport/machinePackageImport.html'
+
urlTimeStamp
(),
controller
:
'machinePackageImportContr'
,
cache
:
false
});
}])
.
controller
(
'machinePackageImportContr'
,
function
(
$scope
,
$rootScope
,
$timeout
,
HttpService
,
$filter
,
$interval
,
MessageService
,
ngDialog
)
{
$
(
"#id_file_photo_for_check"
).
fileinput
({
language
:
'zh'
,
showUpload
:
false
,
showCaption
:
true
,
maxFileCount
:
1024
,
showPreview
:
true
,
maxFileSize
:
1024
*
30
});
$scope
.
ReadMachineInfo
=
function
()
{
var
importName
=
$rootScope
.
loginData
.
name
;
var
fd
=
new
FormData
();
var
files
=
document
.
querySelector
(
'input#id_file_photo_for_check'
).
files
;
if
(
files
.
length
==
0
){
MessageService
.
showAlert
(
"请选择上传的文件..."
)
}
else
{
for
(
var
i
in
files
){
fd
.
append
(
'file'
,
files
[
i
]);
}
ngDialog
.
openConfirm
({
template
:
'dialogs/alert.html'
+
urlTimeStamp
(),
width
:
600
,
cache
:
false
,
closeByDocument
:
false
,
controller
:
[
'$scope'
,
function
(
$scope
)
{
$scope
.
wrongMsg
=-
1
;
$scope
.
msgText
=
"上传中,请稍等..."
;
console
.
log
(
fd
,
importName
);
HttpService
.
ReadMachineInfoData
(
fd
,
importName
,
function
(
data
)
{
console
.
log
(
data
);
if
(
data
){
$scope
.
closeThisDialog
();
getData
();
}
else
{
$scope
.
wrongMsg
=
'上传失败'
;
}
})
}]
});
}
};
//Date picker
$
(
'#datepicker'
).
datetimepicker
({
minView
:
"month"
,
//选择日期后,不会再跳转去选择时分秒
language
:
'zh-CN'
,
format
:
'yyyy-mm-dd'
,
todayBtn
:
1
,
autoclose
:
1
});
$scope
.
choseDate
=
$filter
(
"date"
)(
new
Date
(),
"yyyy-MM-dd"
);
$scope
.
paginationConf
=
{
currentPage
:
1
,
itemsPerPage
:
10
,
perPageOptions
:
[
5
,
10
,
15
,
20
,
25
]
};
$scope
.
getMachinePackage
=
function
()
{
if
(
$scope
.
paginationConf
.
currentPage
!=
1
){
$scope
.
paginationConf
.
currentPage
=
1
;
$scope
.
paginationConf
.
itemsPerPage
=
10
;
}
else
{
$scope
.
getMachinePackagePage
();
}
};
$scope
.
getMachinePackagePage
=
function
()
{
console
.
log
(
$scope
.
fileName
,
$scope
.
state
,
$
(
"#datepicker"
).
val
());
HttpService
.
selectMachinePackageCount
(
$scope
.
fileName
,
$scope
.
state
,
$
(
"#datepicker"
).
val
(),
function
(
data
)
{
$scope
.
paginationConf
.
totalItems
=
data
.
respData
.
string
;
console
.
log
(
$scope
.
paginationConf
.
totalItems
)
});
HttpService
.
selectMachinePackage
(
$scope
.
fileName
,
$scope
.
state
,
$scope
.
paginationConf
.
currentPage
,
$scope
.
paginationConf
.
itemsPerPage
,
$
(
"#datepicker"
).
val
(),
function
(
data
){
$scope
.
machinePackageData
=
data
.
respData
;
console
.
log
(
$scope
.
machinePackageData
)
})
};
var
reGetMachineData
=
$scope
.
getMachinePackage
;
// 通过$watch currentPage和itemperPage 当他们一变化的时候,重新获取数据条目
$scope
.
$watch
(
'paginationConf.currentPage +paginationConf.itemsPerPage'
,
$scope
.
getMachinePackagePage
);
$scope
.
deleteMachineData
=
function
(
fileId
,
importDate
)
{
ngDialog
.
open
({
template
:
'dialogs/confirmDeleteGreenFile.html'
+
urlTimeStamp
(),
width
:
600
,
cache
:
false
,
closeByDocument
:
false
,
controller
:
[
'$scope'
,
function
(
$scope
)
{
$scope
.
wrongMsg
=-
1
;
$scope
.
total
=
1
;
$scope
.
importDate
=
$filter
(
'myDateFilter'
)(
importDate
,
'yyyy-MM-dd'
);;
$scope
.
confirmDelete
=
function
()
{
HttpService
.
deleteMachineAcceptListByFileId
(
fileId
,
function
(
data
)
{
if
(
data
.
msg
){
$scope
.
closeThisDialog
();
reGetMachineData
();
}
else
{
$scope
.
wrongMsg
=
"删除失败"
;
}
})
};
}]
});
}
});
\ No newline at end of file
src/main/resources/static/views/tagPrint/tagPrint.js
View file @
21ff10e8
...
...
@@ -42,7 +42,8 @@ angular.module('AvatarCheck.tagPrint', ['ngRoute', 'AvatarCheck.http', 'tm.pagin
policeCardsList
:[],
isShow
:
false
,
policeData
:
''
,
QR_CODE
:
''
QR_CODE
:
''
,
machineNum
:
''
}
var
getDetailListById
=
function
(
id
)
{
...
...
@@ -83,6 +84,7 @@ angular.module('AvatarCheck.tagPrint', ['ngRoute', 'AvatarCheck.http', 'tm.pagin
$scope
.
json
.
policeCode
=
item
.
POLICE_CODE
;
$scope
.
json
.
count
=
item
.
FINISH_COUNT
;
$scope
.
json
.
QR_CODE
=
item
.
QR_CODE
;
$scope
.
json
.
machineNum
=
item
.
MACHINE_NUM
;
$scope
.
json
.
isShow
=
item
.
show
;
getDetailListById
(
item
.
ID
);
};
...
...
@@ -297,7 +299,7 @@ angular.module('AvatarCheck.tagPrint', ['ngRoute', 'AvatarCheck.http', 'tm.pagin
LODOP.SET_PRINT_STYLEA(0, "
Bold
", 1);
LODOP.SET_PRINT_STYLEA(0, "
Alignment
", 2);
LODOP.SET_PRINT_STYLEA(0, "
FontSize
", 15);
LODOP.ADD_PRINT_TEXT(137, 0, "
100
%
", 20, $scope.json.policeName.toString());
LODOP.ADD_PRINT_TEXT(137, 0, "
100
%
", 20, $scope.json.policeName.toString()
+($scope.json.machineNum==null?"":"
(
"+$scope.json.machineNum+"
)
")
);
LODOP.SET_PRINT_STYLEA(0, "
Bold
", 1);
LODOP.SET_PRINT_STYLEA(0, "
Alignment
", 2);
LODOP.SET_PRINT_STYLEA(0, "
VOrient
", 0);
...
...
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