上传控件的一处bug修复
前端模型一处调整
This commit is contained in:
@@ -24,26 +24,27 @@ class Content extends Fornt {
|
|||||||
$id = db('Category')->where(array('name' => $name))->getField('id');
|
$id = db('Category')->where(array('name' => $name))->getField('id');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$id) {
|
if ($id) {
|
||||||
return $this->error("无此频道!");
|
$cate = $this->getCategory($id);
|
||||||
|
|
||||||
|
//获得当前栏目的所有子栏目
|
||||||
|
$ids = get_category_child($id);
|
||||||
|
}else{
|
||||||
|
$cate = array();
|
||||||
|
$ids = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
$cate = $this->getCategory($id);
|
|
||||||
|
|
||||||
//获得当前栏目的所有子栏目
|
|
||||||
$ids = get_category_child($id);
|
|
||||||
|
|
||||||
$data = array(
|
$data = array(
|
||||||
'category' => $cate,
|
'category' => $cate,
|
||||||
'child_cate' => $ids,
|
'child_cate' => $ids,
|
||||||
);
|
);
|
||||||
if ($cate['template_index']) {
|
if (isset($cate['template_index']) && $cate['template_index']) {
|
||||||
$teamplate = 'content/' . $this->modelInfo['name'] . '/' . $cate['template_index'];
|
$teamplate = 'content/' . $this->modelInfo['name'] . '/' . $cate['template_index'];
|
||||||
} else {
|
} else {
|
||||||
$teamplate = 'content/' . $this->modelInfo['name'] . '/index';
|
$teamplate = 'content/' . $this->modelInfo['name'] . '/index';
|
||||||
}
|
}
|
||||||
$this->assign($data);
|
$this->assign($data);
|
||||||
$this->setSeo($cate['name']);
|
$this->setSeo($this->modelInfo['title']);
|
||||||
return $this->fetch($teamplate);
|
return $this->fetch($teamplate);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -305,11 +305,11 @@
|
|||||||
} else {
|
} else {
|
||||||
self.resetHiddenVal(furl);
|
self.resetHiddenVal(furl);
|
||||||
}
|
}
|
||||||
$('#' + qfid).remove();
|
$('#'+self.options.listName+' #'+qfid).remove();
|
||||||
|
|
||||||
if (qfid.substring(0, 7) == 'WU_FILE') {
|
// if (qfid.substring(0, 7) == 'WU_FILE') {
|
||||||
self.BDUploader.removeFile(qfid, true);
|
// self.BDUploader.removeFile(qfid, true);
|
||||||
}
|
// }
|
||||||
self.allowNum++;
|
self.allowNum++;
|
||||||
} else {
|
} else {
|
||||||
$.messager.show(json.msg, {
|
$.messager.show(json.msg, {
|
||||||
|
|||||||
Reference in New Issue
Block a user