|
|
@@ -4,6 +4,7 @@ namespace ghs\controllers;
|
|
|
|
|
|
use bizGhs\expend\classes\ExpendClass;
|
|
|
use bizGhs\shop\classes\MainClass;
|
|
|
+use bizGhs\shop\classes\ShopAdminClass;
|
|
|
use bizGhs\shop\classes\ShopMoneyClass;
|
|
|
use common\components\dict;
|
|
|
use common\components\noticeUtil;
|
|
|
@@ -13,7 +14,32 @@ use Yii;
|
|
|
class ExpendController extends BaseController
|
|
|
{
|
|
|
|
|
|
- //类型
|
|
|
+ //待报销人员列表和金额 ssh 20240308
|
|
|
+ public function actionUnBxList()
|
|
|
+ {
|
|
|
+ ini_set('memory_limit', '2045M');
|
|
|
+ set_time_limit(0);
|
|
|
+ $list = ExpendClass::getAllByCondition(['mainId' => $this->mainId, 'bx' => 0], null, '*', null);
|
|
|
+ $arr = [];
|
|
|
+ if (!empty($list)) {
|
|
|
+ foreach ($list as $expend) {
|
|
|
+ $staffId = $expend['staffId'] ?? 0;
|
|
|
+ $amount = $expend['amount'] ?? 0;
|
|
|
+ $staffName = $expend['staffName'] ?? '';
|
|
|
+ if (isset($arr[$staffId])) {
|
|
|
+ $arr[$staffId]['amount'] = bcadd($arr[$staffId]['amount'], $amount);
|
|
|
+ $arr[$staffId]['num'] = bcadd($arr[$staffId]['num'], 1);
|
|
|
+ } else {
|
|
|
+ $arr[$staffId]['amount'] = $amount;
|
|
|
+ $arr[$staffId]['staffName'] = $staffName;
|
|
|
+ $arr[$staffId]['num'] = 1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ util::success(['list' => $arr]);
|
|
|
+ }
|
|
|
+
|
|
|
+ //类型列表 ssh 20240308
|
|
|
public function actionGetTypeList()
|
|
|
{
|
|
|
$list = dict::getDict('expendTypeMap');
|