Code Duplication    Length = 11-11 lines in 2 locations

src/Eccube/Form/Type/Shopping/ShippingType.php 1 location

@@ 150-160 (lines=11) @@
147
                $deliveryDates = array();
148
149
                // 配送日数が設定されている
150
                if ($deliveryDateFlag) {
151
                    $period = new \DatePeriod (
152
                        new \DateTime($minDate.' day'),
153
                        new \DateInterval('P1D'),
154
                        new \DateTime($minDate + $this->appConfig['deliv_date_end_max'].' day')
155
                    );
156
157
                    foreach ($period as $day) {
158
                        $deliveryDates[$day->format('Y/m/d')] = $day->format('Y/m/d');
159
                    }
160
                }
161
162
                $form = $event->getForm();
163
                $form

src/Eccube/Service/ShoppingService.php 1 location

@@ 954-964 (lines=11) @@
951
        $deliveryDates = array();
952
953
        // 配送日数が設定されている
954
        if ($deliveryDateFlag) {
955
            $period = new \DatePeriod (
956
                new \DateTime($minDate.' day'),
957
                new \DateInterval('P1D'),
958
                new \DateTime($minDate + $this->appConfig['deliv_date_end_max'].' day')
959
            );
960
961
            foreach ($period as $day) {
962
                $deliveryDates[$day->format('Y/m/d')] = $day->format('Y/m/d');
963
            }
964
        }
965
966
        return $deliveryDates;
967
    }