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
52009e37
Commit
52009e37
authored
Jun 29, 2020
by
孙亚楠
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d
parent
339ee15f
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
260 additions
and
33 deletions
+260
-33
esign-sve-order/app/base/api/impl/op/action.js
+12
-27
esign-sve-order/app/base/db/impl/eorder/eorderDao.js
+9
-0
esign-sve-order/app/base/db/impl/eorder/eorderauthlogDao.js
+9
-0
esign-sve-order/app/base/db/impl/eorder/eorderproductDao.js
+9
-0
esign-sve-order/app/base/db/impl/eorder/eordersignlogDao.js
+9
-0
esign-sve-order/app/base/db/models/eorder/eorder.js
+39
-0
esign-sve-order/app/base/db/models/eorder/eorderauthlog.js
+30
-0
esign-sve-order/app/base/db/models/eorder/eorderproduct.js
+22
-0
esign-sve-order/app/base/db/models/eorder/eordersignlog.js
+30
-0
esign-sve-order/app/base/service/impl/eorder/eorderSve.js
+49
-0
esign-sve-order/app/base/service/impl/eorder/eorderauthlogSve.js
+13
-0
esign-sve-order/app/base/service/impl/eorder/eorderproductSve.js
+13
-0
esign-sve-order/app/base/service/impl/eorder/eordersignlogSve.js
+13
-0
esign-sve-order/app/config/localsettings.js
+3
-6
No files found.
esign-sve-order/app/base/api/impl/op/action.js
View file @
52009e37
...
...
@@ -4,7 +4,10 @@ var settings = require("../../../../config/settings");
class
ActionAPI
extends
APIBase
{
constructor
()
{
super
();
this
.
accountSve
=
system
.
getObject
(
"service.account.accountSve"
);
this
.
eorderSve
=
system
.
getObject
(
"service.eorder.eorderSve"
);
this
.
eorderproductSve
=
system
.
getObject
(
"service.eorder.eorderproductSve"
);
this
.
eorderauthlogSve
=
system
.
getObject
(
"service.eorder.eorderauthlogSve"
);
this
.
eordersignlogSve
=
system
.
getObject
(
"service.eorder.eordersignlogSve"
);
}
/**
* 接口跳转
...
...
@@ -32,35 +35,17 @@ class ActionAPI extends APIBase {
async
handleRequest
(
action_process
,
action_type
,
action_body
)
{
var
opResult
=
null
;
switch
(
action_type
)
{
// 测试
case
"test"
:
opResult
=
await
this
.
accountSve
.
test
(
action_body
);
case
"saveEorder"
:
// 保存订单
opResult
=
await
this
.
eorderSve
.
saveEorder
(
action_body
);
break
;
// 创建账户
case
"accountCreate"
:
opResult
=
await
this
.
accountSve
.
createAccount
(
action_body
);
case
"auditEorder"
:
// 审核订单
opResult
=
await
this
.
eorderSve
.
auditEorder
(
action_body
);
break
;
// 账户余额查询
case
"accountInfo"
:
opResult
=
await
this
.
accountSve
.
accountInfo
(
action_body
);
case
"getEorderById"
:
// 查看订单
opResult
=
await
this
.
eorderSve
.
getEorderById
(
action_body
);
break
;
// 账户充值
case
"accountRecharge"
:
opResult
=
await
this
.
accountSve
.
accountRecharge
(
action_body
);
break
;
// 账户充值
case
"accountRefund"
:
opResult
=
await
this
.
accountSve
.
accountRefund
(
action_body
);
break
;
case
"accountTrade"
:
opResult
=
await
this
.
accountSve
.
accountTrade
(
action_body
);
break
;
case
"accountTradePage"
:
opResult
=
await
this
.
accountSve
.
accountTradePage
(
action_body
);
break
;
// 账户交易
case
"test4"
:
opResult
=
await
this
.
accountSve
.
test
(
action_body
);
case
"pageEorder"
:
// 查看订单
opResult
=
await
this
.
eorderSve
.
pageEorder
(
action_body
);
break
;
default
:
opResult
=
system
.
getResult
(
null
,
"action_type参数错误"
);
...
...
esign-sve-order/app/base/db/impl/eorder/eorderDao.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
Dao
=
require
(
"../../dao.base"
);
class
EorderDao
extends
Dao
{
constructor
(){
super
(
Dao
.
getModelName
(
EorderDao
));
}
}
module
.
exports
=
EorderDao
;
esign-sve-order/app/base/db/impl/eorder/eorderauthlogDao.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
Dao
=
require
(
"../../dao.base"
);
class
EorderauthlogDao
extends
Dao
{
constructor
(){
super
(
Dao
.
getModelName
(
EorderauthlogDao
));
}
}
module
.
exports
=
EorderauthlogDao
;
esign-sve-order/app/base/db/impl/eorder/eorderproductDao.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
Dao
=
require
(
"../../dao.base"
);
class
EorderproductDao
extends
Dao
{
constructor
(){
super
(
Dao
.
getModelName
(
EorderproductDao
.
js
));
}
}
module
.
exports
=
EorderproductDao
;
esign-sve-order/app/base/db/impl/eorder/eordersignlogDao.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
Dao
=
require
(
"../../dao.base"
);
class
EordersignlogDao
extends
Dao
{
constructor
(){
super
(
Dao
.
getModelName
(
EordersignlogDao
));
}
}
module
.
exports
=
EordersignlogDao
;
esign-sve-order/app/base/db/models/eorder/eorder.js
0 → 100644
View file @
52009e37
'use strict'
/**
* 订单表
*/
module
.
exports
=
function
(
db
,
DataTypes
)
{
return
db
.
define
(
'eorder'
,
{
merchant_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'merchant_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'商户id'
},
merchant_name
:
{
type
:
DataTypes
.
STRING
,
field
:
'merchant_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'商户名称'
},
sign_name
:
{
type
:
DataTypes
.
STRING
,
field
:
'sign_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'签署名称'
},
sign_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'sign_id'
,
allowNull
:
false
,
defaultValue
:
''
,
comment
:
'签署ID'
},
product_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'product_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品id'
},
product_type
:
{
type
:
DataTypes
.
STRING
,
field
:
'product_type'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品类型'
},
product_unit_price
:{
type
:
DataTypes
.
STRING
,
field
:
'product_unit_price'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品单价'
},
product_desc
:{
type
:
DataTypes
.
STRING
,
field
:
'product_desc'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品描述'
},
price
:
{
type
:
DataTypes
.
BIGINT
,
field
:
'price'
,
allowNull
:
true
,
defaultValue
:
0
,
comment
:
'订单价格'
},
product_specifications
:
{
type
:
DataTypes
.
INTEGER
,
field
:
'price'
,
allowNull
:
true
,
defaultValue
:
0
,
comment
:
'产品规格数量'
},
contract_url
:
{
type
:
DataTypes
.
STRING
,
field
:
'contract_url'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'合同Url'
},
live_start
:
{
type
:
DataTypes
.
DATE
,
field
:
'live_start'
,
allowNull
:
true
,
defaultValue
:
null
,
comment
:
'生效时间'
},
live_end
:
{
type
:
DataTypes
.
DATE
,
field
:
'live_end'
,
allowNull
:
true
,
defaultValue
:
null
,
comment
:
'结束时间'
},
audit_status
:
{
type
:
DataTypes
.
STRING
,
field
:
'audit_status'
,
allowNull
:
true
,
defaultValue
:
'10'
,
comment
:
'审核状态10 待审核 20 审核成功 30 审核失败'
},
audit_remark
:
{
type
:
DataTypes
.
STRING
,
field
:
'audit_remark'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'审核备注'
},
audit_user_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'audit_user_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'审核人'
},
live_status
:
{
type
:
DataTypes
.
STRING
,
field
:
'live_status'
,
allowNull
:
true
,
defaultValue
:
'10'
,
comment
:
'生效状态10 待生效 20 已生效 30 已终止'
},
pay_status
:
{
type
:
DataTypes
.
STRING
,
field
:
'pay_status'
,
allowNull
:
true
,
defaultValue
:
'10'
,
comment
:
'支付状态10 待支付 20 已支付 30 支付失败'
},
engine_account_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'engine_account_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'计费引擎账户id'
},
created_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'created_at'
,
allowNull
:
false
},
updated_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'updated_at'
,
allowNull
:
false
},
deleted_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'deleted_at'
,
allowNull
:
true
},
version
:
{
type
:
DataTypes
.
BIGINT
,
field
:
'version'
,
defalut
:
0
,
allowNull
:
true
}
},
{
paranoid
:
true
,
//假的删除
underscored
:
true
,
version
:
true
,
freezeTableName
:
true
,
tableName
:
'e_order'
,
});
}
esign-sve-order/app/base/db/models/eorder/eorderauthlog.js
0 → 100644
View file @
52009e37
'use strict'
/**
* 身份认证日志表
*/
module
.
exports
=
function
(
db
,
DataTypes
)
{
return
db
.
define
(
'eorderauthlog'
,
{
order_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'order_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'订单号'
},
product_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'product_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品id'
},
spended_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'spended_at'
,
allowNull
:
true
,
defaultValue
:
null
,
comment
:
'生效时间'
},
platform_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'platform_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'平台ID'
},
platform_name
:
{
type
:
DataTypes
.
STRING
,
field
:
'platform_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'平台名称'
},
spended_num
:
{
type
:
DataTypes
.
INTEGER
,
field
:
'spended_num'
,
allowNull
:
false
,
defaultValue
:
0
,
comment
:
'消费数量'
},
user_name
:
{
type
:
DataTypes
.
STRING
,
field
:
'user_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'使用方'
},
actual_spend_name
:{
type
:
DataTypes
.
STRING
,
field
:
'actual_spend_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'实际使用方'
},
engine_trade_id
:{
type
:
DataTypes
.
STRING
,
field
:
'engine_trade_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'引擎交易id'
},
pass
:
{
type
:
DataTypes
.
INTEGER
,
field
:
'pass'
,
allowNull
:
true
,
defaultValue
:
0
,
comment
:
'是否通过'
},
created_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'created_at'
,
allowNull
:
false
},
updated_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'updated_at'
,
allowNull
:
false
},
deleted_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'deleted_at'
,
allowNull
:
true
},
version
:
{
type
:
DataTypes
.
BIGINT
,
field
:
'version'
,
defalut
:
0
,
allowNull
:
true
}
},
{
paranoid
:
true
,
//假的删除
underscored
:
true
,
version
:
true
,
freezeTableName
:
true
,
tableName
:
'e_order_auth_log'
,
});
}
esign-sve-order/app/base/db/models/eorder/eorderproduct.js
0 → 100644
View file @
52009e37
'use strict'
/**
* 电子签订单关联产品表
*/
module
.
exports
=
function
(
db
,
DataTypes
)
{
return
db
.
define
(
'eorderproduct'
,
{
order_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'order_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'订单号'
},
product_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'product_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品id'
},
created_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'created_at'
,
allowNull
:
false
},
updated_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'updated_at'
,
allowNull
:
false
},
deleted_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'deleted_at'
,
allowNull
:
true
},
version
:
{
type
:
DataTypes
.
BIGINT
,
field
:
'version'
,
defalut
:
0
,
allowNull
:
true
}
},
{
paranoid
:
true
,
//假的删除
underscored
:
true
,
version
:
true
,
freezeTableName
:
true
,
tableName
:
'e_order_product'
,
});
}
esign-sve-order/app/base/db/models/eorder/eordersignlog.js
0 → 100644
View file @
52009e37
'use strict'
/**
* 电子签合同日志表
*/
module
.
exports
=
function
(
db
,
DataTypes
)
{
return
db
.
define
(
'eordersignlog'
,
{
order_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'order_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'订单号'
},
product_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'product_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'产品id'
},
spended_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'spended_at'
,
allowNull
:
true
,
defaultValue
:
null
,
comment
:
'生效时间'
},
platform_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'platform_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'平台ID'
},
platform_name
:
{
type
:
DataTypes
.
STRING
,
field
:
'platform_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'平台名称'
},
spended_num
:
{
type
:
DataTypes
.
INTEGER
,
field
:
'spended_num'
,
allowNull
:
false
,
defaultValue
:
0
,
comment
:
'消费数量'
},
actual_spend_name
:{
type
:
DataTypes
.
STRING
,
field
:
'actual_spend_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'实际使用方'
},
engine_trade_id
:
{
type
:
DataTypes
.
STRING
,
field
:
'engine_trade_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'引擎交易id'
},
engine_contract_id
:{
type
:
DataTypes
.
STRING
,
field
:
'engine_contract_id'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'引擎合同id(签署ID)'
},
engine_contract_name
:{
type
:
DataTypes
.
STRING
,
field
:
'engine_contract_name'
,
allowNull
:
true
,
defaultValue
:
''
,
comment
:
'引擎合同名称(签署任务名称)'
},
created_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'created_at'
,
allowNull
:
false
},
updated_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'updated_at'
,
allowNull
:
false
},
deleted_at
:
{
type
:
DataTypes
.
DATE
,
field
:
'deleted_at'
,
allowNull
:
true
},
version
:
{
type
:
DataTypes
.
BIGINT
,
field
:
'version'
,
defalut
:
0
,
allowNull
:
true
}
},
{
paranoid
:
true
,
//假的删除
underscored
:
true
,
version
:
true
,
freezeTableName
:
true
,
tableName
:
'e_order_sign_log'
,
});
}
esign-sve-order/app/base/service/impl/eorder/eorderSve.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
ServiceBase
=
require
(
"../../sve.base"
)
class
EorderSve
extends
ServiceBase
{
constructor
()
{
super
(
"eorder"
,
ServiceBase
.
getDaoName
(
EorderSve
));
this
.
eorderprodcutDao
=
system
.
getObject
(
"db.eorder.eorderprodcutDao"
);
}
/**
* fn:保存订单
* @param params
* @returns {Promise<void>}
*/
async
saveEorder
(
params
){
}
/**
* fn:审核订单
* @param params
* @returns {Promise<void>}
*/
async
auditEorder
(
params
){
}
/**
* fn:根据ID查询订单信息
* @param params
* @returns {Promise<void>}
*/
async
getEorderById
(
params
){
}
/**
* fn:订单查询(分页)
* @param params
* @returns {Promise<void>}
*/
async
pageEorder
(
params
){
}
}
module
.
exports
=
EorderSve
;
\ No newline at end of file
esign-sve-order/app/base/service/impl/eorder/eorderauthlogSve.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
ServiceBase
=
require
(
"../../sve.base"
)
class
EorderauthlogSve
extends
ServiceBase
{
constructor
()
{
super
(
"eorderauthlogSve"
,
ServiceBase
.
getDaoName
(
EorderauthlogSve
));
// this.accounttradeDao = system.getObject("db.account.accounttradeDao");
}
}
module
.
exports
=
EorderauthlogSve
;
\ No newline at end of file
esign-sve-order/app/base/service/impl/eorder/eorderproductSve.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
ServiceBase
=
require
(
"../../sve.base"
)
class
EorderproductSve
extends
ServiceBase
{
constructor
()
{
super
(
"eorderproduct"
,
ServiceBase
.
getDaoName
(
EorderproductSve
));
// this.accounttradeDao = system.getObject("db.account.accounttradeDao");
}
}
module
.
exports
=
EorderproductSve
;
\ No newline at end of file
esign-sve-order/app/base/service/impl/eorder/eordersignlogSve.js
0 → 100644
View file @
52009e37
const
system
=
require
(
"../../../system"
);
const
ServiceBase
=
require
(
"../../sve.base"
)
class
EordersignlogSve
extends
ServiceBase
{
constructor
()
{
super
(
"eordersignlog"
,
ServiceBase
.
getDaoName
(
EordersignlogSve
));
// this.accounttradeDao = system.getObject("db.account.accounttradeDao");
}
}
module
.
exports
=
EordersignlogSve
;
\ No newline at end of file
esign-sve-order/app/config/localsettings.js
View file @
52009e37
...
...
@@ -6,15 +6,13 @@ var settings={
db
:
10
,
},
database
:{
dbname
:
"e
ngine-product
"
,
dbname
:
"e
sign-sve-order
"
,
user
:
"write"
,
password
:
"write"
,
config
:
{
// host: '192.168.18.237',
// port: 3306,
host
:
'43.247.184.35'
,
port
:
8899
,
timezone
:
'+08:00'
,
dialect
:
'mysql'
,
operatorsAliases
:
false
,
pool
:
{
...
...
@@ -26,8 +24,7 @@ var settings={
debug
:
false
,
dialectOptions
:{
requestTimeout
:
999999
,
// instanceName:'DEV'
}
//设置MSSQL超时时间
}
}
},
reqEsDevUrl
:
"http://192.168.4.249:9200/"
,
...
...
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