diff --git a/app/adminapi/logic/bid/BidDocumentExaminationLogic.php b/app/adminapi/logic/bid/BidDocumentExaminationLogic.php index 1f5b4471f..d81ae9547 100644 --- a/app/adminapi/logic/bid/BidDocumentExaminationLogic.php +++ b/app/adminapi/logic/bid/BidDocumentExaminationLogic.php @@ -22,8 +22,6 @@ use app\common\model\bid\BidDocumentExamination; use app\common\model\bid\BidDocumentExaminationDetail; use app\common\logic\BaseLogic; use app\common\model\custom\Custom; -use app\common\model\dept\Dept; -use app\common\model\dept\Orgs; use app\common\model\project\Project; use think\facade\Db; @@ -51,8 +49,6 @@ class BidDocumentExaminationLogic extends BaseLogic try { $bidDocumentExamination = BidDocumentExamination::create([ 'code' => data_unique_code('标书审查'), - 'org_id' => $params['org_id'], - 'dept_id' => $params['dept_id'], 'project_id' => $buy_bidding_document['project_id'], 'buy_bidding_document_id' => $params['buy_bidding_document_id'], 'technical_protocol_deviation' => $params['technical_protocol_deviation'] ?? '', @@ -102,17 +98,13 @@ class BidDocumentExaminationLogic extends BaseLogic */ public static function detail($params): array { - $field = 'id,code,org_id,dept_id,project_id,buy_bidding_document_id,technical_protocol_deviation,protocol_deviation_handling_plan,technical_review_annex,tax_rate,pay_type,pay_rate,business_contract_deviation,business_contract_deviation_handling_plan,business_contract_deviation_annex'; + $field = 'id,code,project_id,buy_bidding_document_id,technical_protocol_deviation,protocol_deviation_handling_plan,technical_review_annex,tax_rate,pay_type,pay_rate,business_contract_deviation,business_contract_deviation_handling_plan,business_contract_deviation_annex'; $data = BidDocumentExamination::field($field)->findOrEmpty($params['id']); - $org = Orgs::field('name')->where('id',$data['org_id'])->findOrEmpty(); - $dept = Dept::field('name')->where('id',$data['dept_id'])->findOrEmpty(); $project = Project::field('custom_id,name')->where('id',$data['project_id'])->findOrEmpty(); $custom = Custom::field('name')->where('id',$project['custom_id'])->findOrEmpty(); $bid_buy_doc = BidBuyBiddingDocument::field('bid_decision_id,bid_document_no,buyer,invite_tenders_company_name,bid_company_name,amount,buy_date,bid_address')->where('id',$data['buy_bidding_document_id'])->findOrEmpty(); $buyer = Admin::field('name')->where('id',$bid_buy_doc['buyer'])->findOrEmpty(); $bid_decision = BidBiddingDecision::field('bidding_project_fund_source,bidding_time,bid_type,is_margin,margin_amount,bid_opening_date,margin_amount_return_date,bid_project_overview,project_desc,annex')->where('id',$bid_buy_doc['bid_decision_id'])->findOrEmpty(); - $data['org_name'] = $org['name']; - $data['dept_name'] = $dept['name']; $data['project_name'] = $project['name']; $data['custom_name'] = $custom['name']; $data['bid_document_no'] = $bid_buy_doc['bid_document_no']; diff --git a/app/adminapi/validate/bid/BidDocumentExaminationValidate.php b/app/adminapi/validate/bid/BidDocumentExaminationValidate.php index 3172a8bbf..76ad3d98a 100644 --- a/app/adminapi/validate/bid/BidDocumentExaminationValidate.php +++ b/app/adminapi/validate/bid/BidDocumentExaminationValidate.php @@ -16,8 +16,6 @@ namespace app\adminapi\validate\bid; use app\common\model\bid\BidBuyBiddingDocument; -use app\common\model\dept\Dept; -use app\common\model\dept\Orgs; use app\common\model\dict\DictData; use app\common\model\material\Material; use app\common\validate\BaseValidate; @@ -37,8 +35,6 @@ class BidDocumentExaminationValidate extends BaseValidate */ protected $rule = [ 'id' => 'require', - 'org_id' => 'require|checkOrg', - 'dept_id' => 'require|checkDept', 'buy_bidding_document_id' => 'require|checkBuyBiddingDocument', 'technical_review_annex' => 'checkAnnex', 'business_contract_deviation_annex' => 'checkAnnex', @@ -49,8 +45,6 @@ class BidDocumentExaminationValidate extends BaseValidate protected $message = [ 'id.require' => '缺少必要参数', - 'org_id.require' => '请选择组织', - 'dept_id.require' => '请选择部门', 'buy_bidding_document_id.require' => '请选择标书编号', 'quotation_detail' => 'checkQuotationDetail', ]; @@ -101,27 +95,6 @@ class BidDocumentExaminationValidate extends BaseValidate return $this->only(['id']); } - public function checkOrg($value): bool|string - { - $org = Orgs::where('id',$value)->findOrEmpty(); - if($org->isEmpty()){ - return '组织不存在'; - } - return true; - } - - public function checkDept($value,$rule,$data): bool|string - { - $dept = Dept::where('id',$value)->findOrEmpty(); - if($dept->isEmpty()){ - return '部门不存在'; - } - if($dept['org_id'] != $data['org_id']){ - return '部门无效'; - } - return true; - } - public function checkBuyBiddingDocument($value): bool|string { $data = BidBuyBiddingDocument::where('id',$value)->findOrEmpty();