Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
A
Aidea
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
sa_aidea
Aidea
Commits
74142c64
Commit
74142c64
authored
Nov 29, 2020
by
谢希宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Aidea product update by Strive Date 2020-11-28
parent
58f22923
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
127 additions
and
147 deletions
+127
-147
InvoiceServiceImpl.java
...a/com/cftech/invoice/service/impl/InvoiceServiceImpl.java
+3
-2
MobileInvoiceController.java
.../java/com/cftech/invoice/web/MobileInvoiceController.java
+1
-2
orderSendOut.html
...web/src/main/webapp/WEB-INF/views/order/orderSendOut.html
+75
-136
OrderMapper.xml
...module/src/main/java/com/cftech/order/dao/OrderMapper.xml
+3
-1
OrderFollowupRemindJob.java
...ain/java/com/cftech/order/job/OrderFollowupRemindJob.java
+18
-1
OrderMobile.java
...ule/src/main/java/com/cftech/order/model/OrderMobile.java
+5
-0
OrderServiceImpl.java
.../java/com/cftech/order/service/impl/OrderServiceImpl.java
+2
-2
MobileOrderController.java
...main/java/com/cftech/order/web/MobileOrderController.java
+1
-1
productform.html
...eb/src/main/webapp/WEB-INF/views/product/productform.html
+8
-0
ProductMapper.xml
...le/src/main/java/com/cftech/product/dao/ProductMapper.xml
+3
-0
ProductController.java
...c/main/java/com/cftech/product/web/ProductController.java
+3
-1
pom.xml
aidea-modules/waybill-module/pom.xml
+5
-0
ExpressOrderInfoUtils.java
.../java/com/cftech/waybill/utils/ExpressOrderInfoUtils.java
+0
-1
No files found.
aidea-modules/invoice-module/src/main/java/com/cftech/invoice/service/impl/InvoiceServiceImpl.java
View file @
74142c64
...
...
@@ -46,11 +46,12 @@ public class InvoiceServiceImpl extends GenericServiceImpl<Invoice> implements I
public
JSONObject
selectInvoiceDetail
(
InvoiceDetail
invoiceDetail
)
{
JSONObject
jsonObject
=
new
JSONObject
();
MpAccountsEntity
mpAccountsEntity
=
null
;
if
(
StringUtils
.
isNotBlank
(
invoiceDetail
.
getAppId
())){
if
(
StringUtils
.
isNotBlank
(
invoiceDetail
.
getAppId
()))
{
mpAccountsEntity
=
mpAccountsService
.
getMpAccountsAppid
(
invoiceDetail
.
getAppId
());
}
else
{
}
else
{
jsonObject
.
put
(
"errorNo"
,
"2"
);
jsonObject
.
put
(
"errorMsg"
,
"appId不能为空"
);
return
jsonObject
;
}
try
{
...
...
aidea-modules/invoice-module/src/main/java/com/cftech/invoice/web/MobileInvoiceController.java
View file @
74142c64
...
...
@@ -6,7 +6,6 @@ import com.cftech.invoice.service.InvoiceService;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.http.MediaType
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
import
org.springframework.web.bind.annotation.RestController
;
...
...
@@ -25,7 +24,7 @@ public class MobileInvoiceController {
* @return
*/
@RequestMapping
(
value
=
"/invoiceDetail"
,
method
=
{
RequestMethod
.
POST
},
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
public
JSONObject
invoiceDetail
(
@RequestBody
InvoiceDetail
invoiceDetail
){
public
JSONObject
invoiceDetail
(
InvoiceDetail
invoiceDetail
){
return
invoiceService
.
selectInvoiceDetail
(
invoiceDetail
);
}
...
...
aidea-modules/order-module-web/src/main/webapp/WEB-INF/views/order/orderSendOut.html
View file @
74142c64
...
...
@@ -56,6 +56,31 @@
<div
class=
"wrapper"
>
<div
class=
"content-wrapper"
style=
"margin-left:0;"
>
<div
class=
"modal fade"
id=
"exampleModal"
tabindex=
"-1"
role=
"dialog"
aria-labelledby=
"exampleModalLabel"
aria-hidden=
"true"
>
<div
class=
"modal-dialog"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<h4
class=
"modal-title"
>
提示
</h4>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
aria-label=
"Close"
>
<span
aria-hidden=
"true"
>
×
</span>
</button>
</div>
<div
class=
"modal-body"
>
<div
class=
"form-group"
>
<label
for=
"message-text"
class=
"col-form-label"
id=
"labels"
>
商品不在订单中
</label>
</div>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-secondary"
data-dismiss=
"modal"
>
确定
</button>
</div>
</div>
</div>
</div>
<section
class=
"content-header"
>
<h1>
需求清单出库管理
...
...
@@ -270,76 +295,67 @@
}
//扫码全局变量
var
s
canCodeStr
=
""
;
var
s
umScanCode
=
""
;
var
scanSubCode
=
""
;
var
avgTime
=
30
;
var
lastTime
=
0
;
var
lastTime
=
0
;
//最后一次扫码时间
//触发顺序keydown keypress keyup
$
(
document
).
on
(
'keydown'
,
function
(
event
)
{
function
scanCode
(
event
)
{
let
subCode
=
String
.
fromCharCode
(
event
.
keyCode
);
let
currTime
=
new
Date
().
getTime
();
let
spaceTime
=
currTime
-
lastTime
;
console
.
log
(
event
.
keyCode
+
"=="
);
let
currTime
=
new
Date
().
getTime
();
//当前时间
let
spaceTime
=
currTime
-
lastTime
;
//间隔时间
//扫码间隔大于30,未认为输入
if
(
lastTime
!=
0
&&
spaceTime
>
avgTime
)
{
if
(
lastTime
!=
0
&&
spaceTime
>
avgTime
)
{
return
;
}
if
(
event
.
keyCode
!=
13
)
{
scanSubCode
+=
subCode
;
}
lastTime
=
currTime
;
if
(
event
.
keyCode
==
13
)
{
lastTime
=
0
;
let
nextEleV
=
0
;
let
scanNumEle
=
null
;
//获取所有商品编码
let
flag
=
false
;
$
(
"#group"
).
find
(
'input[name="productCode"]'
).
each
(
function
()
{
let
index
=
0
;
$
(
"#group"
).
find
(
'input[name="productCode"]'
).
each
(
function
(
i
)
{
if
(
$
(
this
).
val
()
==
scanSubCode
)
{
nextEleV
=
$
(
this
).
next
().
val
();
scanNumEle
=
$
(
this
).
next
().
next
();
index
=
i
;
flag
=
true
;
}
});
if
(
!
flag
)
{
Cfapp
.
alert
({
message
:
"商品未在订单中!"
,
btntext
:
"确定"
,
success
:
function
()
{}
});
scanSubCode
=
""
;
return
;
}
scanCodeStr
+=
scanSubCode
+
"|"
;
let
count
=
0
;
if
(
scanCodeStr
!=
""
&&
scanCodeStr
!=
null
)
{
let
arr
=
scanCodeStr
.
split
(
"|"
);
console
.
log
(
arr
.
length
);
for
(
let
i
=
0
;
i
<
arr
.
length
;
i
++
)
{
if
(
arr
[
i
]
==
scanSubCode
)
count
++
;
}
if
(
nextEleV
<
count
)
{
Cfapp
.
alert
({
message
:
"商品超过订单数量!"
,
btntext
:
"确定"
,
success
:
function
()
{}
});
scanSubCode
=
""
;
return
;
if
(
!
flag
)
{
$
(
"#labels"
).
text
(
"商品不在订单中"
);
$
(
'#exampleModal'
).
modal
(
'show'
);
}
else
{
let
orderNum
=
$
(
"#group"
).
find
(
'input[name="orderNum"]:eq('
+
index
+
')'
).
val
();
let
sendNum
=
$
(
"#group"
).
find
(
'input[name="sendNum"]:eq('
+
index
+
')'
).
val
();
if
(
parseInt
(
sendNum
)
>=
parseInt
(
orderNum
))
{
$
(
"#labels"
).
text
(
"超过订单商品数量"
);
$
(
'#exampleModal'
).
modal
(
'show'
);
}
else
{
$
(
"#group"
).
find
(
'input[name="sendNum"]:eq('
+
index
+
')'
).
val
(
parseInt
(
sendNum
)
+
1
);
sumScanCode
+=
scanSubCode
+
"|"
;
$
(
'textarea[name="scanGoodsCode"]'
).
text
(
sumScanCode
);
}
}
scanNumEle
.
val
(
count
);
$
(
'textarea[name="scanGoodsCode"]'
).
text
(
scanCodeStr
);
scanSubCode
=
""
;
return
;
}
}
scanSubCode
+=
subCode
;
lastTime
=
currTime
;
//触发顺序keydown keypress keyup
$
(
document
).
on
(
'keydown'
,
function
(
event
){
console
.
log
(
"触发1"
);
scanCode
(
event
);
});
// $(document).on('keypress', function(event){
...
...
@@ -354,20 +370,6 @@
// }
// });
function
checkProductCode
(
code
)
{
let
flag
=
true
;
$
(
"#group"
).
find
(
'input[name="productCode"]'
).
each
(
function
(
e
)
{
if
(
e
.
val
()
==
code
)
{
let
count
=
e
.
next
().
val
();
let
length
=
$
(
'textarea[name="scanGoodsCode"]'
).
text
().
split
(
code
).
length
-
1
;
if
(
count
>=
length
)
return
true
;
}
});
if
(
!
flag
)
{
return
flag
;
}
}
function
list
()
{
var
url
=
"#springUrl('/a/order/fromProduct')"
...
...
@@ -387,21 +389,11 @@
selectProductList
=
JSON
.
parse
(
selectProductList
);
for
(
var
i
=
0
;
i
<
selectProductList
.
length
;
i
++
)
{
var
obj
=
selectProductList
[
i
];
// if($(this).val() == obj.provinceId){
// $(this).attr('selected', 'selected');
// }
console
.
log
(
obj
);
clickAdd
(
obj
.
id
,
obj
.
productId
,
obj
.
productName
,
obj
.
drugsNum
,
obj
.
price
,
obj
.
amount
,
obj
.
productNumber
);
}
}
// $('#selectProduct option').each(function () {
// for(var index= 0;i
<
selectProductList
.
length
;
i
++
){
// var obj = selectProductList[i];
// if($(this).val() == obj.provinceId){
// $(this).attr('selected', 'selected');
// }
// }
//
// })
}
});
}
...
...
@@ -428,20 +420,6 @@
Cfapp
.
init
();
list
();
// var selectdrugsNum = $("#selectdrugsNum");
// for (var i = 1; i
<=
30
;
i
++
){
// selectdrugsNum.append("
<
option
value
=
'"+[i]+"'
>
"+[i]+"
<
/option>"
)
// }
// var drugsNum = "$!{data.drugsNum}";
// $('#selectdrugsNum option').each(function () {
// if($(this).val() == drugsNum){
// $(this).attr('selected', 'selected');
// }
// })
});
...
...
@@ -498,10 +476,6 @@
}
function
toTal
()
{
// $('#group').on('click', '.scanGoods', function() {
// $(this).prev().val("11111111111");
// });
var
count
=
0
$
(
'.group [name="htmlAmount"]'
).
each
(
function
(
index
,
item
){
count
+=
+
item
.
value
...
...
@@ -513,47 +487,18 @@
* 保存事件
*/
function
save
()
{
var
arr
=
[]
var
obj
=
{}
$
(
'.translate'
).
each
((
index
,
item
)
=>
{
var
txt
=
$
(
item
).
find
(
'[name="releas"]'
).
val
()
if
(
obj
[
txt
])
{
arr
.
push
(
index
)
return
}
else
{
obj
[
txt
]
=
true
let
flag
=
false
;
$
(
"#group"
).
find
(
'.list-group-item'
).
each
(
function
(
i
)
{
if
(
$
(
this
).
find
(
'input[name="orderNum"]'
).
val
()
!=
$
(
this
).
find
(
'input[name="sendNum"]'
).
val
())
{
flag
=
true
;
}
})
if
(
arr
.
length
>
0
)
{
Cfapp
.
alert
({
message
:
"无法增加重复商品!"
,
btntext
:
"确定"
,
success
:
function
()
{
}
});
});
if
(
flag
)
{
$
(
"#labels"
).
text
(
"订单商品数量和出库数量不一致"
);
$
(
'#exampleModal'
).
modal
(
'show'
);
return
;
}
var
id
=
$
(
"#id"
).
val
();
var
orderAmount
=
$
(
"#orderAmount"
).
val
();
var
datas
=
[];
$
(
'.translate'
).
each
(
function
(
index
,
item
){
const
idDetail
=
$
(
item
).
find
(
'[name="idDetail"]'
).
val
()
const
productId
=
$
(
item
).
find
(
'[name="releas"]'
).
val
()
const
drugsNum
=
$
(
item
).
find
(
'[name="listHtml"]'
).
val
()
const
price
=
$
(
item
).
find
(
'[name="htmlPrice"]'
).
val
()
const
amount
=
$
(
item
).
find
(
'[name="htmlAmount"]'
).
val
()
datas
.
push
({
id
:
id
,
idDetail
:
idDetail
,
productId
:
productId
,
drugsNum
:
drugsNum
,
price
:
price
,
amount
:
amount
,
orderAmount
:
orderAmount
})
});
var
url
=
"#springUrl('/a/waybill/orderSendOutForWaybill')"
;
...
...
@@ -575,14 +520,8 @@
}
});
}
else
{
Cfapp
.
alert
({
message
:
"出库失败"
,
btntext
:
"确定"
,
success
:
function
()
{
let
idTmp
=
$
(
'input[name="id"]'
).
val
();
location
.
href
=
"#springUrl('/a/order/sendOut?id="
+
idTmp
+
"')"
;
}
});
$
(
"#labels"
).
text
(
"出库失败"
);
$
(
'#exampleModal'
).
modal
(
'show'
);
}
}
...
...
aidea-modules/order-module/src/main/java/com/cftech/order/dao/OrderMapper.xml
View file @
74142c64
...
...
@@ -566,12 +566,14 @@
t.order_cancel AS orderCancel,
t.status,
DATE_FORMAT(t.create_time,'%Y-%m-%d %h:%i:%s') AS createTime,
DATE_FORMAT(t.order_time,'%Y-%m-%d %h:%i:%s') AS orderTime,
s.address_name AS addressName,
a.areaname AS province,
b.areaname AS city,
c.areaname AS area,
s.phone,
s.address
s.address,
t.confirm
FROM
t_order t
LEFT JOIN t_order_details d ON t.id =d.order_id
...
...
aidea-modules/order-module/src/main/java/com/cftech/order/job/OrderFollowupRemindJob.java
View file @
74142c64
package
com
.
cftech
.
order
.
job
;
import
com.cftech.accounts.model.MpAccountsEntity
;
import
com.cftech.accounts.model.SysJob
;
import
com.cftech.accounts.service.JobService
;
import
com.cftech.accounts.service.MpAccountsService
;
import
com.cftech.base.org.api.QyMsgUtil
;
import
com.cftech.base.org.model.Qyuser
;
import
com.cftech.base.org.service.QyuserService
;
import
com.cftech.core.sql.Conds
;
import
com.cftech.core.util.Constants
;
import
com.cftech.core.util.SpringContextHolder
;
...
...
@@ -18,6 +23,7 @@ import org.quartz.JobExecutionException;
import
java.math.BigDecimal
;
import
java.text.ParseException
;
import
java.text.SimpleDateFormat
;
import
java.util.ArrayList
;
import
java.util.Calendar
;
import
java.util.Date
;
import
java.util.List
;
...
...
@@ -37,6 +43,11 @@ public class OrderFollowupRemindJob implements Job {
}
SimpleDateFormat
sdf
=
new
SimpleDateFormat
(
"yyyy-MM-dd"
);
Long
accounts
=
Long
.
parseLong
(
SystemConfig
.
p
.
getProperty
(
"QY_SEND_APPID"
));
MpAccountsService
mpAccountsService
=
SpringContextHolder
.
getBean
(
MpAccountsService
.
class
);
MpAccountsEntity
accountsEntity
=
mpAccountsService
.
getDetail
(
accounts
);
Long
agenId
=
Long
.
parseLong
(
accountsEntity
.
getAgentId
());
String
msg
=
SystemConfig
.
p
.
getProperty
(
"QY_SEND_SERVICE_FOLLOWUP_MSG"
);
Conds
orderConds
=
new
Conds
();
orderConds
.
equal
(
"o.del_flag"
,
Constants
.
DEL_FLAG_0
);
...
...
@@ -80,7 +91,13 @@ public class OrderFollowupRemindJob implements Job {
Date
nowDate
=
sdf
.
parse
(
sdf
.
format
(
new
Date
()));
if
(
date
.
compareTo
(
nowDate
)
==
0
)
{
QyuserService
qyuserService
=
SpringContextHolder
.
getBean
(
QyuserService
.
class
);
Qyuser
serverUser
=
qyuserService
.
fetchById
(
order
.
getServiceId
());
List
<
Qyuser
>
serviceUsers
=
new
ArrayList
();
serviceUsers
.
add
(
serverUser
);
QyMsgUtil
qyMsgUtil
=
SpringContextHolder
.
getBean
(
QyMsgUtil
.
class
);
msg
+=
msg
+
order
.
getNumber
();
qyMsgUtil
.
sendText
(
accounts
,
false
,
serviceUsers
,
null
,
null
,
agenId
,
msg
,
false
);
}
}
catch
(
ParseException
e
)
{
e
.
printStackTrace
();
...
...
aidea-modules/order-module/src/main/java/com/cftech/order/model/OrderMobile.java
View file @
74142c64
...
...
@@ -46,6 +46,11 @@ public class OrderMobile {
private
String
city
;
/*区县*/
private
String
area
;
private
String
orderTime
;
private
String
confirm
;
private
List
<
ProductMobile
>
ProductMobile
;
}
aidea-modules/order-module/src/main/java/com/cftech/order/service/impl/OrderServiceImpl.java
View file @
74142c64
...
...
@@ -307,9 +307,9 @@ public class OrderServiceImpl extends GenericServiceImpl<Order> implements Order
try
{
Conds
conds
=
new
Conds
();
conds
.
in
(
"o.id"
,
invoiceDto
.
getId
().
split
(
","
));
conds
.
equal
(
"o.id"
,
invoiceDto
.
getId
(
));
conds
.
equal
(
"o.del_flag"
,
Constants
.
DEL_FLAG_0
);
List
<
Order
>
list
=
orderMapper
.
fetchSearchBy
(
conds
,
null
,
0
,
0
,
null
);
List
<
Order
>
list
=
this
.
fetchSearchBy
(
conds
,
null
,
0
,
0
,
null
);
if
(
list
.
size
()
>
0
){
for
(
Order
order
:
list
){
SimpleDateFormat
format
=
new
SimpleDateFormat
(
"yyyy-MM-dd HH:mm:ss"
);
...
...
aidea-modules/order-module/src/main/java/com/cftech/order/web/MobileOrderController.java
View file @
74142c64
...
...
@@ -66,7 +66,7 @@ public class MobileOrderController {
* @return
*/
@RequestMapping
(
value
=
"/invoice"
,
method
=
{
RequestMethod
.
POST
},
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
public
JSONObject
invoice
(
@RequestBody
InvoiceDto
invoiceDto
){
public
JSONObject
invoice
(
InvoiceDto
invoiceDto
){
return
orderService
.
invoice
(
invoiceDto
);
}
}
aidea-modules/product-module-web/src/main/webapp/WEB-INF/views/product/productform.html
View file @
74142c64
...
...
@@ -104,6 +104,14 @@
>
</div>
<div
class=
"form-group form-md-line-input col-md-12"
>
<label>
产品编码
</label>
<input
type=
"text"
required
class=
"form-control pull-right"
value=
"$!{data.productNumber}"
maxlength=
"500"
required
name=
"productNumber"
placeholder=
"剂型"
>
</div>
<div
class=
"form-group form-md-line-input col-md-12"
>
<label>
通用名
</label>
<input
type=
"text"
required
class=
"form-control pull-right"
...
...
aidea-modules/product-module/src/main/java/com/cftech/product/dao/ProductMapper.xml
View file @
74142c64
...
...
@@ -287,6 +287,9 @@
<if
test=
"format != null"
>
format = #{format, jdbcType=VARCHAR},
</if>
<if
test=
"productNumber != null"
>
product_number = #{productNumber, jdbcType=VARCHAR},
</if>
<if
test=
"approveNumber != null"
>
approve_number = #{approveNumber, jdbcType=VARCHAR},
</if>
...
...
aidea-modules/product-module/src/main/java/com/cftech/product/web/ProductController.java
View file @
74142c64
...
...
@@ -107,7 +107,9 @@ public class ProductController {
}
else
{
product
.
setAccountsId
(
accountsId
);
product
.
setDelFlag
(
false
);
product
.
setProductNumber
(
codingruleUtils
.
getNumber
(
accountsId
,
Product
.
class
.
getName
()));
if
(
StringUtils
.
isBlank
(
product
.
getProductNumber
()))
{
product
.
setProductNumber
(
codingruleUtils
.
getNumber
(
accountsId
,
Product
.
class
.
getName
()));
}
product
.
setAccountsId
(
UserUtils
.
getmpaccounts
(
request
));
product
.
setCreateBy
(
UserUtils
.
getUser
().
getId
());
product
.
setUpdateBy
(
UserUtils
.
getUser
().
getId
());
...
...
aidea-modules/waybill-module/pom.xml
View file @
74142c64
...
...
@@ -32,5 +32,10 @@
<artifactId>
shipping-address-module
</artifactId>
<version>
1.0-SNAPSHOT
</version>
</dependency>
<dependency>
<groupId>
com.cftech
</groupId>
<artifactId>
logistics-module
</artifactId>
<version>
1.0-SNAPSHOT
</version>
</dependency>
</dependencies>
</project>
aidea-modules/waybill-module/src/main/java/com/cftech/waybill/utils/ExpressOrderInfoUtils.java
View file @
74142c64
...
...
@@ -256,7 +256,6 @@ public class ExpressOrderInfoUtils {
retObj
.
put
(
"trackingType"
,
1
);
//1:根据顺丰运单号查询
JSONArray
waybills
=
new
JSONArray
();
//waybills.add("SF7444420632664");
retObj
.
put
(
"trackingNumber"
,
waybills
);
//顺丰运单号
retObj
.
put
(
"methodType"
,
1
);
//标准路由查询
}
catch
(
Exception
e
)
{
...
...
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