|
@@ -174,6 +174,20 @@ class Set
|
|
|
|
|
|
</tr>';
|
|
|
}
|
|
|
+ $id = $info[$type . '_id'];
|
|
|
+ if ($type == 'shop') {
|
|
|
+ $where['type'] = 1;
|
|
|
+ $where['type_id'] = $id;
|
|
|
+ } elseif ($type == 'factory') {
|
|
|
+ $where['source_type'] = 3;
|
|
|
+ $where['source_id'] = $id;
|
|
|
+ } else {
|
|
|
+ $where['type'] = 2;
|
|
|
+ $where['type_id'] = $id;
|
|
|
+
|
|
|
+
|
|
|
+ }
|
|
|
+ $where['status'] = 2;
|
|
|
|
|
|
$button = array();
|
|
|
|
|
@@ -188,7 +202,12 @@ class Set
|
|
|
|
|
|
$start = date('Y-m-d H:i:s', $info['start']);
|
|
|
$end = date('Y-m-d H:i:s', $info['end']);
|
|
|
- $out = Dever::url('database.list_excel?project=cash&table=order&search_option_status=2&search_option_state=1&search_option_start_cdate=' . $start . '&search_option_end_cdate=' . $end, 'manage');
|
|
|
+ $ow = array();
|
|
|
+ foreach ($where as $k => $v) {
|
|
|
+ $ow['search_option_' . $k] = $v;
|
|
|
+ }
|
|
|
+ $ow = http_build_query($ow);
|
|
|
+ $out = Dever::url('database.list_excel?project=cash&table=order&search_option_status=2&search_option_state=1&search_option_start_cdate=' . $start . '&search_option_end_cdate=' . $end . '&' . $ow, 'manage');
|
|
|
|
|
|
$button[] = '<a class="layui-btn layui-btn-primary" href="'.$out.'">导出对账单</a>';
|
|
|
} elseif ($show == 2) {
|
|
@@ -214,20 +233,7 @@ class Set
|
|
|
|
|
|
$html .= '</tbody></table></div></div>';
|
|
|
|
|
|
- $id = $info[$type . '_id'];
|
|
|
- if ($type == 'shop') {
|
|
|
- $where['type'] = 1;
|
|
|
- $where['type_id'] = $id;
|
|
|
- } elseif ($type == 'factory') {
|
|
|
- $where['source_type'] = 3;
|
|
|
- $where['source_id'] = $id;
|
|
|
- } else {
|
|
|
- $where['type'] = 2;
|
|
|
- $where['type_id'] = $id;
|
|
|
-
|
|
|
-
|
|
|
- }
|
|
|
- $where['status'] = 2;
|
|
|
+
|
|
|
$where['start'] = $info['start'];
|
|
|
$where['end'] = $info['end'];
|
|
|
$data = Dever::db('cash/order')->getAll($where);
|