Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
JSH ERP
Commits
5e05f53a
Commit
5e05f53a
authored
Aug 30, 2017
by
季圣华
Browse files
更新后端代码
parent
b9bc613c
Changes
49
Expand all
Show whitespace changes
Inline
Side-by-side
src/main/java/com/jsh/service/basic/UnitIService.java
0 → 100644
View file @
5e05f53a
package
com.jsh.service.basic
;
import
com.jsh.base.BaseIService
;
import
com.jsh.model.po.Unit
;
public
interface
UnitIService
extends
BaseIService
<
Unit
>
{
}
src/main/java/com/jsh/service/basic/UnitService.java
0 → 100644
View file @
5e05f53a
package
com.jsh.service.basic
;
import
com.jsh.base.BaseService
;
import
com.jsh.dao.basic.UnitIDAO
;
import
com.jsh.model.po.Unit
;
public
class
UnitService
extends
BaseService
<
Unit
>
implements
UnitIService
{
@SuppressWarnings
(
"unused"
)
private
UnitIDAO
unitDao
;
public
void
setUnitDao
(
UnitIDAO
unitDao
)
{
this
.
unitDao
=
unitDao
;
}
@Override
protected
Class
<
Unit
>
getEntityClass
()
{
return
Unit
.
class
;
}
}
src/main/java/com/jsh/service/materials/DepotHeadIService.java
View file @
5e05f53a
...
...
@@ -15,7 +15,5 @@ public interface DepotHeadIService extends BaseIService<DepotHead>
void
findAllMoney
(
PageUtil
<
DepotHead
>
depotHead
,
Integer
supplierId
,
String
type
,
String
subType
,
String
mode
)
throws
JshException
;
public
void
findInDetail
(
PageUtil
pageUtil
,
String
beginTime
,
String
endTime
,
String
type
,
Long
pid
,
String
dids
)
throws
JshException
;
public
void
findInOutMaterialCount
(
PageUtil
pageUtil
,
String
beginTime
,
String
endTime
,
String
type
,
Long
pid
,
String
dids
)
throws
JshException
;
public
void
batchSetStatus
(
Boolean
status
,
String
depotHeadIDs
);
}
src/main/java/com/jsh/service/materials/DepotHeadService.java
View file @
5e05f53a
...
...
@@ -34,11 +34,7 @@ public class DepotHeadService extends BaseService<DepotHead> implements DepotHea
depotHeadDao
.
findAllMoney
(
pageUtil
,
supplierId
,
type
,
subType
,
mode
);
}
public
void
findInDetail
(
PageUtil
pageUtil
,
String
beginTime
,
String
endTime
,
String
type
,
Long
pid
,
String
dids
)
throws
JshException
{
depotHeadDao
.
findInDetail
(
pageUtil
,
beginTime
,
endTime
,
type
,
pid
,
dids
);
}
public
void
findInOutMaterialCount
(
PageUtil
pageUtil
,
String
beginTime
,
String
endTime
,
String
type
,
Long
pid
,
String
dids
)
throws
JshException
{
depotHeadDao
.
findInOutMaterialCount
(
pageUtil
,
beginTime
,
endTime
,
type
,
pid
,
dids
);
public
void
batchSetStatus
(
Boolean
status
,
String
depotHeadIDs
){
depotHeadDao
.
batchSetStatus
(
status
,
depotHeadIDs
);
}
}
src/main/java/com/jsh/service/materials/MaterialIService.java
View file @
5e05f53a
...
...
@@ -2,8 +2,19 @@ package com.jsh.service.materials;
import
com.jsh.base.BaseIService
;
import
com.jsh.model.po.Material
;
import
com.jsh.util.JshException
;
import
com.jsh.util.PageUtil
;
import
java.io.File
;
import
java.io.InputStream
;
public
interface
MaterialIService
extends
BaseIService
<
Material
>
{
public
void
batchSetEnable
(
Boolean
enable
,
String
supplierIDs
);
public
void
findUnitName
(
PageUtil
<
Material
>
material
,
Long
mId
)
throws
JshException
;
public
InputStream
exmportExcel
(
String
isAllPage
,
PageUtil
<
Material
>
pageUtil
)
throws
JshException
;
public
InputStream
importExcel
(
File
materialFile
)
throws
JshException
;
}
src/main/java/com/jsh/service/materials/MaterialService.java
View file @
5e05f53a
This diff is collapsed.
Click to expand it.
src/main/java/com/jsh/util/MaterialConstants.java
0 → 100644
View file @
5e05f53a
package
com.jsh.util
;
/**
* 定义商品信息常量
* @author jishenghua
*/
public
interface
MaterialConstants
{
/**
* 公共常量
* @author ji sheng hua
*/
public
class
Common
{
}
/**
* 常量--导入导出excel表格业务相关
* @author jishenghua
*/
public
class
BusinessForExcel
{
/**
* 名称
*/
public
static
final
int
EXCEL_NAME
=
0
;
/**
* 类型
*/
public
static
final
int
EXCEL_CATEGORY
=
1
;
/**
* 制造商
*/
public
static
final
int
EXCEL_MFRS
=
2
;
/**
* 型号
*/
public
static
final
int
EXCEL_MODEL
=
3
;
/**
* 规格
*/
public
static
final
int
EXCEL_STANDARD
=
4
;
/**
* 安全存量
*/
public
static
final
int
EXCEL_SAFETY_STOCK
=
5
;
/**
* 单位
*/
public
static
final
int
EXCEL_UNIT
=
6
;
/**
* 零售价
*/
public
static
final
int
EXCEL_RETAILPRICE
=
7
;
/**
* 最低售价
*/
public
static
final
int
EXCEL_LOWPRICE
=
8
;
/**
* 预设售价一
*/
public
static
final
int
EXCEL_PRESETPRICEONE
=
9
;
/**
* 预设售价二
*/
public
static
final
int
EXCEL_PRESETPRICETWO
=
10
;
/**
* 备注
*/
public
static
final
int
EXCEL_REMARK
=
11
;
/**
* 表头
*/
public
static
final
int
EXCEL_TABLE_HEAD
=
0
;
/**
* action返回excel结果
*/
public
static
final
String
EXCEL
=
"excel"
;
}
}
src/main/java/com/jsh/util/SupplierConstants.java
0 → 100644
View file @
5e05f53a
package
com.jsh.util
;
/**
* 定义供应商、客户管理常量
* @author jishenghua
*/
public
interface
SupplierConstants
{
/**
* 公共常量
* @author jishenghua
*/
public
class
Common
{
}
/**
* 常量--导入导出excel表格业务相关
* @author jishenghua
*/
public
class
BusinessForExcel
{
/**
* 名称
*/
public
static
final
int
EXCEL_SUPPLIER
=
0
;
/**
* 类型
*/
public
static
final
int
EXCEL_TYPE
=
1
;
/**
* 联系人
*/
public
static
final
int
EXCEL_CONTACTS
=
2
;
/**
* 电话
*/
public
static
final
int
EXCEL_PHONE_NUM
=
3
;
/**
* 电子邮箱
*/
public
static
final
int
EXCEL_EMAIL
=
4
;
/**
* 预收款
*/
public
static
final
int
EXCEL_ADVANCE_IN
=
5
;
/**
* 期初应收
*/
public
static
final
int
EXCEL_BEGIN_NEED_GET
=
6
;
/**
* 期初应付
*/
public
static
final
int
EXCEL_BEGIN_NEED_PAY
=
7
;
/**
* 备注
*/
public
static
final
int
EXCEL_DESCRIPTION
=
8
;
/**
* 传真
*/
public
static
final
int
EXCEL_FAX
=
9
;
/**
* 手机
*/
public
static
final
int
EXCEL_TELEPHONE
=
10
;
/**
* 地址
*/
public
static
final
int
EXCEL_ADDRESS
=
11
;
/**
* 纳税人识别号
*/
public
static
final
int
EXCEL_TAX_NUM
=
12
;
/**
* 开户行
*/
public
static
final
int
EXCEL_BANK_NAME
=
13
;
/**
* 账号
*/
public
static
final
int
EXCEL_ACCOUNT_NUMBER
=
14
;
/**
* 税率
*/
public
static
final
int
EXCEL_TAX_RATE
=
15
;
/**
* 表头
*/
public
static
final
int
EXCEL_TABLE_HEAD
=
0
;
/**
* action返回excel结果
*/
public
static
final
String
EXCEL
=
"excel"
;
}
}
src/main/java/com/jsh/util/Tools.java
View file @
5e05f53a
...
...
@@ -3,6 +3,7 @@ package com.jsh.util;
import
java.io.IOException
;
import
java.io.UnsupportedEncodingException
;
import
java.net.InetAddress
;
import
java.net.URLDecoder
;
import
java.net.URLEncoder
;
import
java.net.UnknownHostException
;
import
java.security.MessageDigest
;
...
...
@@ -48,7 +49,7 @@ public class Tools
}
/**
* 获取指定日期格式 yyyy-MM
* 获取指定日期格式 yyyy-MM
-dd
* @return
*/
public
static
String
getCurrentMonth
(
Date
date
)
...
...
@@ -230,6 +231,31 @@ public class Tools
}
return
valueAfterTransCode
;
}
/**
* 字符转码
* @param aValue
* @return
* @see 转码后的字符串
*/
public
static
String
decodeValue
(
String
aValue
)
{
if
(
aValue
.
trim
().
length
()
==
0
)
{
return
""
;
}
String
valueAfterTransCode
=
null
;
try
{
valueAfterTransCode
=
URLDecoder
.
decode
(
aValue
,
"UTF-8"
);
}
catch
(
UnsupportedEncodingException
e
)
{
e
.
getMessage
();
}
return
valueAfterTransCode
;
}
/**
* 去除str中的'
* @param str
...
...
Prev
1
2
3
Next
Write
Preview
Supports
Markdown
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