|
@@ -499,6 +499,7 @@ func MoveEdbChart(source, subSource, oldUserId, newUserId int, isSelectAll bool,
|
|
|
|
|
|
dataPermissionMoveRecordList := make([]*data_manage_permission.DataPermissionMoveRecord, 0)
|
|
|
uniqueCode := uuid.NewUUID().Hex32()
|
|
|
+ title := `资产转移`
|
|
|
content := `资产转入`
|
|
|
|
|
|
switch source {
|
|
@@ -701,7 +702,7 @@ func MoveEdbChart(source, subSource, oldUserId, newUserId int, isSelectAll bool,
|
|
|
DataPermissionMessageId: 0,
|
|
|
SendUserId: int32(opUserId),
|
|
|
ReceiveUserId: int32(adminInfo.AdminId),
|
|
|
- Content: content,
|
|
|
+ Content: title,
|
|
|
Remark: content,
|
|
|
OpType: 1,
|
|
|
Source: int32(source),
|
|
@@ -732,7 +733,7 @@ func MoveEdbChart(source, subSource, oldUserId, newUserId int, isSelectAll bool,
|
|
|
return
|
|
|
}
|
|
|
|
|
|
-
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
@@ -751,6 +752,7 @@ func MoveAllEdbChartOld(sourceList, oldUserIdList []int, userId, opUserId int) (
|
|
|
|
|
|
dataPermissionMoveRecordList := make([]*data_manage_permission.DataPermissionMoveRecord, 0)
|
|
|
uniqueCode := uuid.NewUUID().Hex32()
|
|
|
+ title := `资产转移`
|
|
|
content := `资产转入`
|
|
|
sourceStrList := make([]string, 0)
|
|
|
|
|
@@ -954,7 +956,7 @@ func MoveAllEdbChartOld(sourceList, oldUserIdList []int, userId, opUserId int) (
|
|
|
DataPermissionMessageId: 0,
|
|
|
SendUserId: int32(opUserId),
|
|
|
ReceiveUserId: int32(adminInfo.AdminId),
|
|
|
- Content: content,
|
|
|
+ Content: title,
|
|
|
Remark: content,
|
|
|
OpType: 2,
|
|
|
OpUniqueCode: uniqueCode,
|
|
@@ -1002,6 +1004,7 @@ func MoveAllEdbChart(sourceList, oldUserIdList []int, userId, opUserId int) (err
|
|
|
|
|
|
dataPermissionMoveRecordList := make([]*data_manage_permission.DataPermissionMoveRecord, 0)
|
|
|
uniqueCode := uuid.NewUUID().Hex32()
|
|
|
+ title := `资产转移`
|
|
|
content := `资产转入`
|
|
|
sourceStrList := make([]string, 0)
|
|
|
|
|
@@ -1203,7 +1206,7 @@ func MoveAllEdbChart(sourceList, oldUserIdList []int, userId, opUserId int) (err
|
|
|
DataPermissionMessageId: 0,
|
|
|
SendUserId: int32(opUserId),
|
|
|
ReceiveUserId: int32(adminInfo.AdminId),
|
|
|
- Content: content,
|
|
|
+ Content: title,
|
|
|
Remark: content,
|
|
|
OpType: 2,
|
|
|
OpUniqueCode: uniqueCode,
|
|
@@ -1233,8 +1236,9 @@ func MoveAllEdbChart(sourceList, oldUserIdList []int, userId, opUserId int) (err
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
-func GetMoveEdbChartCount(userId int) (sourceMap map[int]int, err error) {
|
|
|
+
|
|
|
+
|
|
|
+func GetMoveEdbChartCount(userId, countType int) (sourceMap map[int]int, err error) {
|
|
|
sourceMap = make(map[int]int)
|
|
|
{
|
|
|
|
|
@@ -1271,23 +1275,6 @@ func GetMoveEdbChartCount(userId int) (sourceMap map[int]int, err error) {
|
|
|
sourceMap[2] = total
|
|
|
}
|
|
|
|
|
|
- {
|
|
|
-
|
|
|
- var condition string
|
|
|
- var pars []interface{}
|
|
|
- if userId > 0 {
|
|
|
- condition += ` AND sys_user_id = ? `
|
|
|
- pars = append(pars, userId)
|
|
|
- }
|
|
|
-
|
|
|
- total, tmpErr := data_manage.GetMysteelChemicalIndexCount(condition, pars)
|
|
|
- if tmpErr != nil {
|
|
|
- err = tmpErr
|
|
|
- return
|
|
|
- }
|
|
|
- sourceMap[2] = total
|
|
|
- }
|
|
|
-
|
|
|
{
|
|
|
|
|
|
var condition string
|
|
@@ -1352,11 +1339,20 @@ func GetMoveEdbChartCount(userId int) (sourceMap map[int]int, err error) {
|
|
|
var condition string
|
|
|
var pars []interface{}
|
|
|
|
|
|
+ condition += ` AND is_delete = 0 `
|
|
|
+
|
|
|
if userId > 0 {
|
|
|
condition += ` AND sys_user_id = ? `
|
|
|
pars = append(pars, userId)
|
|
|
}
|
|
|
|
|
|
+ switch countType {
|
|
|
+ case 2:
|
|
|
+ condition += ` AND source in (2,3) `
|
|
|
+ default:
|
|
|
+ condition += ` AND source in (2,3,4) `
|
|
|
+ }
|
|
|
+
|
|
|
total, tmpErr := excel.GetExcelInfoCountByCondition(condition, pars)
|
|
|
if tmpErr != nil {
|
|
|
err = tmpErr
|