File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
backend/modules/circulation/controllers Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -74,16 +74,21 @@ public function actionCreate(){
7474 //echo $k;exit;
7575 // $r=in_array($date, $dates);
7676 //echo $r;exit;
77- if (in_array ($ date , $ dates )){
78- $ key = array_search ($ date , $ dates );
77+ $ dts = array_map (function ($ piece ){
78+ return (string ) $ piece ;
79+ }, $ dates );
80+ // print_r($dts);exit;
81+ if (in_array ($ date , $ dts )){
82+ $ key = array_search ($ date , $ dts );
7983 $ model ->price_per_piece =$ prices [$ key ];
8084 $ price =$ prices [$ key ];
8185 }
82- else
86+ else
8387 {
8488 $ price ='15 ' ;
8589 $ model ->price_per_piece ='15 ' ;
8690 }
91+ //echo $model->price_per_piece;exit;
8792 $ tot =$ val ['panchjanya ' ]+$ val ['organiser ' ];
8893 $ price =($ val ['panchjanya ' ]+$ val ['organiser ' ])*$ price ;
8994 $ model ->total_price =$ price ;
You can’t perform that action at this time.
0 commit comments