mirror of
https://gitee.com/gz-yami/mall4j.git
synced 2026-03-22 09:17:16 +08:00
热搜管理
This commit is contained in:
@@ -84,15 +84,21 @@ export default {
|
||||
},
|
||||
components: {},
|
||||
methods: {
|
||||
init (data) {
|
||||
init (id) {
|
||||
this.dataForm.hotSearchId = id || 0
|
||||
this.visible = true
|
||||
if (data) {
|
||||
this.dataForm = Object.assign({}, data)
|
||||
} else {
|
||||
this.$nextTick(() => {
|
||||
this.$refs['dataForm'].resetFields()
|
||||
})
|
||||
}
|
||||
this.$nextTick(() => {
|
||||
this.$refs['dataForm'].resetFields()
|
||||
if (this.dataForm.hotSearchId) {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/admin/hotSearch/info/' + this.dataForm.hotSearchId),
|
||||
method: 'get',
|
||||
params: this.$http.adornParams()
|
||||
}).then(({data}) => {
|
||||
this.dataForm = data
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
// 表单提交
|
||||
dataFormSubmit () {
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
type="primary"
|
||||
size="small"
|
||||
icon="el-icon-edit"
|
||||
@click="addOrUpdateHandle(scope.row)">修改</el-button>
|
||||
@click="addOrUpdateHandle(scope.row.hotSearchId)">修改</el-button>
|
||||
<el-button v-if="isAuth('admin:hotSearch:delete')"
|
||||
type="danger"
|
||||
icon="el-icon-delete"
|
||||
|
||||
@@ -69,7 +69,6 @@ public class HotSearchController {
|
||||
* 获取信息
|
||||
*/
|
||||
@GetMapping("/info/{id}")
|
||||
@PreAuthorize("@pms.hasPermission('admin:hotSearch:info')")
|
||||
public ResponseEntity<HotSearch> info(@PathVariable("id") Long id){
|
||||
HotSearch hotSearch = hotSearchService.getById(id);
|
||||
return ResponseEntity.ok(hotSearch);
|
||||
|
||||
Reference in New Issue
Block a user