更新报销模块
This commit is contained in:
parent
9d6d42f5c9
commit
261908caff
@ -15,10 +15,10 @@
|
|||||||
namespace app\adminapi\lists\expense;
|
namespace app\adminapi\lists\expense;
|
||||||
|
|
||||||
|
|
||||||
use app\adminapi\lists\BaseAdminDataLists;
|
use app\adminapi\lists\BaseAdminDataLists;
|
||||||
use app\common\model\expense\ExpenseReimbursement;
|
use app\common\model\expense\ExpenseReimbursement;
|
||||||
use app\common\lists\ListsSearchInterface;
|
use app\common\lists\ListsSearchInterface;
|
||||||
|
use think\facade\Db;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ExpenseReimbursement列表
|
* ExpenseReimbursement列表
|
||||||
@ -38,7 +38,7 @@ class ExpenseReimbursementLists extends BaseAdminDataLists implements ListsSearc
|
|||||||
public function setSearch(): array
|
public function setSearch(): array
|
||||||
{
|
{
|
||||||
return [
|
return [
|
||||||
'=' => ['reimburser', 'reimbursement_date', 'customer_id', 'payee_name', 'payee_account'],
|
'=' => ['reimburser', 'reimbursement_date', 'customer_id', 'payee_name', 'payee_account'],
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -60,6 +60,23 @@ class ExpenseReimbursementLists extends BaseAdminDataLists implements ListsSearc
|
|||||||
->order(['id' => 'desc'])
|
->order(['id' => 'desc'])
|
||||||
->select()
|
->select()
|
||||||
->toArray();
|
->toArray();
|
||||||
|
|
||||||
|
return Db::name('ExpenseReimbursement')->alias('er')
|
||||||
|
->where($this->searchWhere)
|
||||||
|
->leftJoin('orgs o','o.id = er.org_id')
|
||||||
|
->leftJoin('dept d','d.id = er.dept_id')
|
||||||
|
->leftJoin('custom ct','ct.id = er.customer_id')
|
||||||
|
->field('er.*, d.name as dept_name, o.name as org_name, ct.name as customer_name')
|
||||||
|
->limit($this->limitOffset, $this->limitLength)
|
||||||
|
->order(['er.id' => 'desc'])
|
||||||
|
->select()->each(function($item, $key){
|
||||||
|
//关联数据后续添加
|
||||||
|
$item['approve_no'] = '付款单号';
|
||||||
|
$item['approve_step'] = '流程步骤';
|
||||||
|
$item['approve_settle_status'] = 1;
|
||||||
|
return $item;
|
||||||
|
})
|
||||||
|
->toArray();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user