| | |
| | | import com.mzl.flower.dto.request.menber.UserGrowthRecordDTO; |
| | | import com.mzl.flower.dto.response.customer.CustomerDTO; |
| | | import com.mzl.flower.dto.response.partner.PartnerDTO; |
| | | import com.mzl.flower.dto.response.supplier.SupplierDTO; |
| | | import com.mzl.flower.entity.customer.Customer; |
| | | import com.mzl.flower.entity.partner.Partner; |
| | | import com.mzl.flower.enums.TrueOrFalseEnum; |
| | |
| | | import org.springframework.util.ObjectUtils; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.List; |
| | | |
| | | @Service |
| | |
| | | return null; |
| | | } |
| | | |
| | | public CustomerDTO findCustomerByPhone(String phone) { |
| | | CustomerDTO customerByPhone = customerMapper.findCustomerByPhone(phone); |
| | | if (customerByPhone != null && customerByPhone.getMemberOvertime() != null) { |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd"); |
| | | customerByPhone.setMemberOverDate(customerByPhone.getMemberOvertime().format(formatter)); |
| | | } |
| | | customerByPhone.setContactTel(phone); |
| | | return customerByPhone; |
| | | } |
| | | } |