Commit b4cfbc24 by 冷斌

fix bug

parent bab9c9c5
......@@ -1652,7 +1652,7 @@ class ZyServiceModel
if (OPEN_SCHOOL) { // 多机构
// 机构单独分成比例配置
$school_proportion = M('school_divideinto')->where(['mhm_id' => $school_id, "{$type}_status" => 1])->field('course, live, album, course_line, classes')->find();
var_dump("log: {$school_proportion}");
if ($school_proportion) {
$old_proportion = $school_proportion;
} else {
......@@ -1691,8 +1691,9 @@ class ZyServiceModel
unset($school_id);
$utype = $type == 'course_line' ? 'CourseLine' : $type;
$old_proportion = model('Xdata')->get("admin_Config:divideInto" . ucwords($utype) . "Config");
var_dump("log: {$utype}");
$old_proportion = array_filter(explode(':', $old_proportion[$type]));
var_dump("log: {$old_proportion}");
if (empty($old_proportion)) {
return 1;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment