发票后台搜索以及编辑时候的字段不一致

This commit is contained in:
evoxwht 2023-03-24 15:16:59 +08:00
parent 99501a40e7
commit dccfdfbe5e
3 changed files with 17 additions and 7 deletions

View File

@ -45,6 +45,8 @@ class StoreOrderInvoice extends AuthController
{
$where = $this->request->getMore([
['data', '', '', 'time'],
['real_name', ''],
['field_key', ''],
[['type', 'd'], 0],
]);
$data = $this->services->chart($where);

View File

@ -36,21 +36,28 @@ class StoreOrderInvoiceServices extends BaseServices
public function chart(array $where)
{
$where['is_pay'] = 1;
//全部
$data['all'] = (string)$this->dao->count(['is_pay' => 1, 'time' => $where['time']]);
$data['all'] = (string)$this->dao->count($where);
//待开
$data['noOpened'] = (string)$this->dao->count(['is_pay' => 1, 'time' => $where['time'], 'type' => 1]);
$where['type'] = 1;
$data['noOpened'] = (string)$this->dao->count($where);
//已开
$data['opened'] = (string)$this->dao->count(['is_pay' => 1, 'time' => $where['time'], 'type' => 2]);
$where['type'] = 2;
$data['opened'] = (string)$this->dao->count($where);
//退款
$data['refund'] = (string)$this->dao->count(['is_pay' => 1, 'time' => $where['time'], 'type' => 3]);
$where['type'] = 3;
$data['refund'] = (string)$this->dao->count($where);
return $data;
}
/**
* 后台获取开票列表
* @param $where
* @param array $where
* @return array
* @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\DbException
* @throws \think\db\exception\ModelNotFoundException
*/
public function getList(array $where)
{

View File

@ -151,7 +151,7 @@
<div class="list">
<div class="title row">联系信息</div>
<Row class="row">
<Col span="12">真实姓名: {{ invoiceDetails.real_name }}</Col>
<Col span="12">真实姓名: {{ invoiceDetails.name }}</Col>
<Col span="12">联系电话: {{ invoiceDetails.user_phone }}</Col>
</Row>
<Row class="row">
@ -178,7 +178,7 @@
<div class="list">
<div class="title row">联系信息</div>
<Row class="row">
<Col span="12">真实姓名: {{ invoiceDetails.real_name }}</Col>
<Col span="12">真实姓名: {{ invoiceDetails.name }}</Col>
<Col span="12">联系电话: {{ invoiceDetails.user_phone }}</Col>
</Row>
<Row class="row">
@ -555,6 +555,7 @@ export default {
this.timeVal = e;
this.orderData.data = this.timeVal[0] ? this.timeVal.join('-') : '';
this.getList();
this.getTabs();
},
//订单状态搜索()
selectChange() {