上传控件的一处bug修复

前端模型一处调整
This commit is contained in:
2017-08-09 01:15:03 +08:00
parent 2cd00111f4
commit 9a5d67d937
2 changed files with 14 additions and 13 deletions

View File

@@ -24,26 +24,27 @@ class Content extends Fornt {
$id = db('Category')->where(array('name' => $name))->getField('id');
}
if (!$id) {
return $this->error("无此频道!");
if ($id) {
$cate = $this->getCategory($id);
//获得当前栏目的所有子栏目
$ids = get_category_child($id);
}else{
$cate = array();
$ids = '';
}
$cate = $this->getCategory($id);
//获得当前栏目的所有子栏目
$ids = get_category_child($id);
$data = array(
'category' => $cate,
'child_cate' => $ids,
);
if ($cate['template_index']) {
if (isset($cate['template_index']) && $cate['template_index']) {
$teamplate = 'content/' . $this->modelInfo['name'] . '/' . $cate['template_index'];
} else {
$teamplate = 'content/' . $this->modelInfo['name'] . '/index';
}
$this->assign($data);
$this->setSeo($cate['name']);
$this->setSeo($this->modelInfo['title']);
return $this->fetch($teamplate);
}

View File

@@ -305,11 +305,11 @@
} else {
self.resetHiddenVal(furl);
}
$('#' + qfid).remove();
$('#'+self.options.listName+' #'+qfid).remove();
if (qfid.substring(0, 7) == 'WU_FILE') {
self.BDUploader.removeFile(qfid, true);
}
// if (qfid.substring(0, 7) == 'WU_FILE') {
// self.BDUploader.removeFile(qfid, true);
// }
self.allowNum++;
} else {
$.messager.show(json.msg, {