|
@@ -125,6 +125,7 @@ func (this *AskserieVideoController) PreserveAndPublish() {
|
|
|
// @Param EndDate query string false "结束时间,列如2021-03-06 "
|
|
|
// @Param PublishStatus query int true "发布状态: -1-默认全部; 0-未发布; 1-已关注"
|
|
|
// @Param ChartPermissionId query string false "行业Id"
|
|
|
+// @Param KeyWord query string false "搜索关键词"
|
|
|
// @Success Ret=200 {object} cygx.GetCygxTacticsTimeLineResp
|
|
|
// @router /askserie_video/list [get]
|
|
|
func (this *AskserieVideoController) List() {
|
|
@@ -147,6 +148,9 @@ func (this *AskserieVideoController) List() {
|
|
|
startDate := this.GetString("StartDate")
|
|
|
endDate := this.GetString("EndDate")
|
|
|
chartPermissionId, _ := this.GetInt("ChartPermissionId")
|
|
|
+ keyWord := this.GetString("KeyWord")
|
|
|
+ keyWord = strings.Trim(keyWord, " ")
|
|
|
+ keyWord = strings.Replace(keyWord, "'", "", -1)
|
|
|
var startSize int
|
|
|
if pageSize <= 0 {
|
|
|
pageSize = utils.PageSize20
|
|
@@ -158,7 +162,7 @@ func (this *AskserieVideoController) List() {
|
|
|
var condition string
|
|
|
var pars []interface{}
|
|
|
//发布状态查询
|
|
|
- if publishStatus == 0 || publishStatus == 1 {
|
|
|
+ if publishStatus == 0 || publishStatus == 1 || publishStatus == 3 {
|
|
|
condition += ` AND art.publish_status = ? `
|
|
|
pars = append(pars, publishStatus)
|
|
|
}
|
|
@@ -172,6 +176,9 @@ func (this *AskserieVideoController) List() {
|
|
|
condition += ` AND art.chart_permission_id = ?`
|
|
|
pars = append(pars, chartPermissionId)
|
|
|
}
|
|
|
+ if keyWord != "" {
|
|
|
+ condition += ` AND ( video_name LIKE '%` + keyWord + `%' ) `
|
|
|
+ }
|
|
|
total, err := cygx.GetCygxAskserieVideoCount(condition, pars)
|
|
|
if err != nil {
|
|
|
br.Msg = "获取失败"
|
|
@@ -453,7 +460,7 @@ func (this *AskserieVideoController) PublishReport() {
|
|
|
if detail.PublishStatus == 0 {
|
|
|
status = 1
|
|
|
} else {
|
|
|
- status = 0
|
|
|
+ status = 3
|
|
|
}
|
|
|
err = cygx.EditCygxAskserieVideoStatus(status, askserieVideoId)
|
|
|
if err != nil {
|