Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
李洋
/
消息系统
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
97abbc92
authored
Dec 22, 2025
by
gongyang
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
提交代码
parent
ed8d625f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
14 deletions
app/Logic/SystemNoticeLogic.php
app/Model/BusinessNoticeModel.php
app/Logic/SystemNoticeLogic.php
View file @
97abbc92
...
...
@@ -403,12 +403,11 @@ class SystemNoticeLogic
foreach
(
$returnData
[
'data'
]
as
&
$value
){
$value
[
'create_time_cn'
]
=
date
(
'Y-m-d H:i:s'
,
$value
[
'create_time'
]);
$value
[
'system_id_cn'
]
=
''
;
$value
[
'type_cn'
]
=
''
;
$value
[
'show_status_cn'
]
=
''
;
$value
[
'top_status_cn'
]
=
''
;
$value
[
'source_cn'
]
=
''
;
$value
[
'system_id_cn'
]
=
BusinessNoticeModel
::
$systemIdCn
[
$value
[
'system_id'
]]
??
''
;
$value
[
'type_cn'
]
=
BusinessNoticeModel
::
$typeCn
[
$value
[
'type'
]]
??
''
;;
$value
[
'show_status_cn'
]
=
BusinessNoticeModel
::
$showCn
[
$value
[
'show_status'
]]
??
''
;
$value
[
'top_status_cn'
]
=
BusinessNoticeModel
::
$topCn
[
$value
[
'top_status'
]]
??
''
;
$value
[
'source_cn'
]
=
BusinessNoticeModel
::
$sourceCn
[
$value
[
'source'
]]
??
''
;
}
return
$returnData
;
...
...
app/Model/BusinessNoticeModel.php
View file @
97abbc92
...
...
@@ -18,6 +18,15 @@ class BusinessNoticeModel extends Model
protected
$primaryKey
=
'business_notice_id'
;
public
$timestamps
=
false
;
static
public
$systemIdCn
=
[
1
=>
'采购系统'
,
2
=>
'WMS系统'
];
//类型1最新补货,2最新入库,3优势货源,4个人消息
static
public
$typeCn
=
[
1
=>
'最新补货'
,
2
=>
'最新入库'
,
3
=>
'优势货源'
,
4
=>
'个人消息'
];
static
public
$showCn
=
[
0
=>
'显示'
,
1
=>
'隐藏'
];
static
public
$topCn
=
[
0
=>
'置顶'
,
1
=>
'非置顶'
];
static
public
$sourceCn
=
[
0
=>
'系统生成'
,
1
=>
'手动新增'
];
public
function
getWhereObj
(
$data
)
{
...
...
@@ -25,12 +34,10 @@ class BusinessNoticeModel extends Model
foreach
(
$data
as
$key
=>
$val
){
if
(
$val
===
''
)
continue
;
switch
(
$key
){
case
'system_name'
:
case
'update_type'
:
case
'version_num'
:
case
'weonlt_id'
:
case
'product_user'
:
case
'type'
:
case
'title'
:
case
'show_status'
:
case
'top_status'
:
$obj
=
$obj
->
where
(
$key
,
$val
);
break
;
case
'smue_id_str'
:
$obj
=
$obj
->
whereIn
(
'smue_id'
,
explode
(
','
,
$val
));
break
;
...
...
@@ -38,9 +45,9 @@ class BusinessNoticeModel extends Model
case
'update_title'
:
case
'update_content'
:
$obj
=
$obj
->
where
(
$key
,
'like'
,
'%'
.
$val
.
'%'
);
break
;
case
'
begin_time
'
:
case
'
create_time_begin
'
:
$obj
=
$obj
->
where
(
'create_time'
,
'>'
,
strtotime
(
$val
));
break
;
case
'
end_time
'
:
case
'
create_time_end
'
:
$obj
=
$obj
->
where
(
'create_time'
,
'<='
,
strtotime
(
$val
));
break
;
}
}
...
...
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