Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Z
zhichan
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
蒋勇
zhichan
Commits
f6bbca5f
Commit
f6bbca5f
authored
Jun 22, 2020
by
sxy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 生成材料下载地址
parent
533da2e8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
17 additions
and
5 deletions
+17
-5
icp-deliver/app/base/controller/impl/delivery/materialCtl.js
+0
-0
icp-deliver/app/base/db/dao.base.js
+2
-2
icp-deliver/app/base/db/impl/delivery/materialDao.js
+2
-1
icp-deliver/app/base/db/models/delivery/meterials_info.js
+8
-0
icp-deliver/app/base/service/sve.base.js
+5
-2
No files found.
icp-deliver/app/base/controller/impl/delivery/materialCtl.js
0 → 100644
View file @
f6bbca5f
This diff is collapsed.
Click to expand it.
icp-deliver/app/base/db/dao.base.js
View file @
f6bbca5f
...
...
@@ -266,8 +266,8 @@ class Dao {
async
findById
(
oid
)
{
return
this
.
model
.
findById
(
oid
);
}
async
findAll
(
obj
)
{
return
this
.
model
.
findAll
({
"where"
:
obj
,
row
:
true
});
async
findAll
(
obj
,
include
=
[]
)
{
return
this
.
model
.
findAll
({
"where"
:
obj
,
include
,
row
:
true
});
}
}
module
.
exports
=
Dao
;
icp-deliver/app/base/db/impl/delivery/materialDao.js
View file @
f6bbca5f
...
...
@@ -17,7 +17,8 @@ class MaterialDao extends Dao {
implementationPlanInfo
:
pobj
.
cache_info
.
implementationPlanInfo
,
safetyInfo
:
pobj
.
cache_info
.
safetyInfo
,
otherMaterialsInfo
:
pobj
.
cache_info
.
otherMaterialsInfo
,
deliver_id
:
pobj
.
deliver_id
deliver_id
:
pobj
.
deliver_id
,
ifDownload
:
false
}
dataInfo
.
proposerInfo
.
businessInformation
.
ifListed
=
dataInfo
.
proposerInfo
.
businessInformation
.
ifListed
===
"true"
if
(
materialData
)
{
...
...
icp-deliver/app/base/db/models/delivery/meterials_info.js
View file @
f6bbca5f
...
...
@@ -25,6 +25,14 @@ module.exports = (db, DataTypes) => {
otherMaterialsInfo
:
{
allowNull
:
false
,
type
:
DataTypes
.
JSON
},
ifDownload
:
{
//是否生成下载文件
type
:
DataTypes
.
BOOLEAN
,
defaultValue
:
false
},
downloadUrl
:
{
allowNull
:
true
,
type
:
DataTypes
.
STRING
}
},
{
paranoid
:
false
,
//假的删除
...
...
icp-deliver/app/base/service/sve.base.js
View file @
f6bbca5f
...
...
@@ -75,11 +75,14 @@ class ServiceBase {
async
findById
(
oid
)
{
return
this
.
dao
.
findById
(
oid
);
}
async
findAll
(
obj
,
include
=
[])
{
return
this
.
dao
.
findAll
(
obj
,
include
);
}
/*
返回20位业务订单号
prefix:业务前缀
*/
async
getBusUid
(
prefix
)
{
async
getBusUid
(
prefix
)
{
prefix
=
(
prefix
||
""
);
if
(
prefix
)
{
prefix
=
prefix
.
toUpperCase
();
...
...
@@ -97,7 +100,7 @@ class ServiceBase {
len:返回长度
radix:参与计算的长度,最大为62
*/
async
getUidInfo
(
len
,
radix
)
{
async
getUidInfo
(
len
,
radix
)
{
var
chars
=
'0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'
.
split
(
''
);
//长度62,到yz长度为长36
var
uuid
=
[],
i
;
radix
=
radix
||
chars
.
length
;
...
...
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