Changeset 3000815
- Timestamp:
- 11/23/2023 05:15:00 PM (2 years ago)
- Location:
- apimo/trunk
- Files:
-
- 3 added
- 17 edited
-
admin/add_property.php (modified) (2 diffs)
-
admin/settings.php (modified) (2 diffs)
-
apimo.php (modified) (1 diff)
-
assets/css/app.css (modified) (1 diff)
-
assets/download_icon.png (added)
-
assets/user_image.png (added)
-
assets/verify.png (added)
-
languages/apimo-de_DE.mo (modified) (previous)
-
languages/apimo-de_DE.po (modified) (1 diff)
-
languages/apimo-en_GB.po (modified) (1 diff)
-
languages/apimo-es_ES.mo (modified) (previous)
-
languages/apimo-es_ES.po (modified) (1 diff)
-
languages/apimo-fr_FR.mo (modified) (previous)
-
languages/apimo-fr_FR.po (modified) (1 diff)
-
languages/apimo-it_IT.mo (modified) (previous)
-
languages/apimo-it_IT.po (modified) (1 diff)
-
languages/apimo-ru_RU.mo (modified) (previous)
-
languages/apimo-ru_RU.po (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
templates/single_property_style_1.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
apimo/trunk/admin/add_property.php
r2986633 r3000815 369 369 370 370 371 update_post_meta($id, 'apimo_property_location', array( 372 'country' => $property->country, 373 'region' => $property->region, 374 'city' => $property->city, 375 'district' => $property->district, 376 'longitude' => $property->longitude, 377 'latitude' => $property->latitude, 378 )); 379 380 381 371 382 if($property->country){ 372 383 $country = wp_set_object_terms($id, $property->country, 'country', true); … … 868 879 869 880 update_post_meta($id, 'apimo_regulations', $property->regulations); 881 882 update_post_meta($id, 'apimo_documents', $property->documents); 883 884 885 870 886 871 887 -
apimo/trunk/admin/settings.php
r2993232 r3000815 55 55 'gallery_display_slider' => filter_var($_POST['archive']['gallery_display_slider'], FILTER_VALIDATE_INT), 56 56 // 'hideicon' => sanitize_text_field($_POST['archive']['hideicon']) 57 'hideicon' => (isset($_POST['archive']['hideicon'])) ? sanitize_text_field($_POST['archive']['hideicon']) : "showicon" 57 'hideicon' => (isset($_POST['archive']['hideicon'])) ? sanitize_text_field($_POST['archive']['hideicon']) : "showicon", 58 'userinfo' => (isset($_POST['archive']['userinfo'])) ? sanitize_text_field($_POST['archive']['userinfo']) : "show" 59 58 60 59 61 ); 60 62 63 61 64 62 65 … … 2496 2499 2497 2500 </div> 2501 <div class="apimo-col-6"> 2502 2503 <div class="apimo-block-label"> 2504 2505 <h5><?php _e('Hide User info', 'apimo'); ?></h5> 2506 2507 </div> 2508 2509 2510 <div class="apimo-step-description checkbox-inline"> 2511 2512 <label class="apimo-field"> 2513 2514 <div class="box-apimo-checkbox"> 2515 2516 <input type="checkbox" name="archive[userinfo]" value="hide" id="userinfo" <?php if ($archive['userinfo'] == 'hide') {echo 'checked';} ?> /> 2517 <span class="check"></span> <label for="userinfo" class="apimo-title"> 2518 <?php _e('Yes, I want to hide the userinfo', 'apimo'); ?></label> 2519 </div> 2520 2521 </label> 2522 </div> 2523 2524 </div> 2498 2525 2499 2526 </div> -
apimo/trunk/apimo.php
r2993232 r3000815 7 7 * Description: Manage Real Estat Bussiness 8 8 9 * Version: 2.5. 19 * Version: 2.5.2 10 10 11 11 * Author: CodeByte Srl -
apimo/trunk/assets/css/app.css
r2872252 r3000815 5871 5871 } 5872 5872 5873 5874 .apimo_profile_picture { 5875 width: 600px; 5876 display: flex; 5877 align-items: center; 5878 justify-content: space-between; 5879 border: 1px solid #ddd; 5880 padding: 20px; 5881 box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); 5882 background-color: #fff; 5883 border-radius: 10px; 5884 } 5885 5886 .apimo_profile_picture .profile_img img { 5887 width: 120px; 5888 height: 120px; 5889 border-radius: 50%; 5890 object-fit: cover; 5891 border: 3px solid #fff; 5892 box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); 5893 } 5894 5895 .apimo_profile_picture .profile_info { 5896 flex: 2; 5897 margin: 0 20px; 5898 } 5899 5900 .apimo_profile_picture .username { 5901 font-size: 24px; 5902 font-weight: bold; 5903 margin-bottom: 15px; 5904 color: #333; 5905 padding: 10px; 5906 5907 } 5908 5909 .apimo_profile_picture .username img { 5910 width: 30px; 5911 height: 30px; 5912 } 5913 5914 .apimo_profile_picture .info span { 5915 display: block; 5916 margin-bottom: 8px; 5917 font-size: 14px; 5918 color: #555; 5919 border: 1px solid #ddd; 5920 padding: 10px; 5921 border-radius: 5px; 5922 background-color: #fff; 5923 } 5924 5925 .apimo_profile_picture .verify_user { 5926 display: flex; 5927 flex-direction: column; 5928 align-items: center; 5929 } 5930 5931 .apimo_profile_picture .language { 5932 margin-bottom: 15px; 5933 font-size: 16px; 5934 color: #007bff; 5935 } 5936 5937 .apimo_profile_picture .verification img { 5938 width: 30px; 5939 height: 30px; 5940 } 5941 5942 .apimo_profile_picture .contact-button{ 5943 margin: 20px 0; 5944 } 5945 5946 5947 5948 -
apimo/trunk/languages/apimo-de_DE.po
r2986633 r3000815 3810 3810 msgid "Yearly" 3811 3811 msgstr "" 3812 3813 3814 msgid "Location Map" 3815 msgstr "Landkarte" 3816 3817 msgid "No documents found for this property" 3818 msgstr "Keine Dokumente für diese Immobilie gefunden" 3819 3820 3821 msgid "File title" 3822 msgstr "Größe der Datei" 3823 3824 3825 msgid "File size" 3826 msgstr "Dateigröße " 3827 3828 3829 msgid "Action" 3830 msgstr "Aktion" 3831 3832 3833 msgid "Documents" 3834 msgstr "Dokumente" 3835 3836 msgid "User Detail" 3837 msgstr "Benutzerdetails" -
apimo/trunk/languages/apimo-en_GB.po
r2986633 r3000815 3739 3739 msgid "Yearly" 3740 3740 msgstr "" 3741 3742 msgid "Location Map" 3743 msgstr "" 3744 3745 3746 msgid "No documents found for this property" 3747 msgstr "" 3748 3749 3750 msgid "File title" 3751 msgstr "" 3752 3753 msgid "Action" 3754 msgstr "" 3755 3756 msgid "File size" 3757 msgstr "" 3758 3759 msgid "Documents" 3760 msgstr "" 3761 3762 msgid "User Detail" 3763 msgstr "" -
apimo/trunk/languages/apimo-es_ES.po
r2986633 r3000815 3812 3812 msgid "Yearly" 3813 3813 msgstr "" 3814 3815 msgid "Location Map" 3816 msgstr "Mapa de localización" 3817 3818 3819 msgid "No documents found for this property" 3820 msgstr "No se han encontrado documentos para esta propiedad" 3821 3822 3823 msgid "File title" 3824 msgstr "Título del fichero" 3825 3826 msgid "Action" 3827 msgstr "Acción" 3828 3829 msgid "File size" 3830 msgstr "tamaño del archivo" 3831 3832 3833 msgid "Documents" 3834 msgstr "Documentos" 3835 3836 msgid "User Detail" 3837 msgstr "Detalles del Usuario" -
apimo/trunk/languages/apimo-fr_FR.po
r2986633 r3000815 3812 3812 msgid "Yearly" 3813 3813 msgstr "Annuel" 3814 3815 msgid "Location Map" 3816 msgstr "Carte de localisation" 3817 3818 3819 msgid "No documents found for this property" 3820 msgstr "Aucun document trouvé pour cette propriété" 3821 3822 msgid "File title" 3823 msgstr "Titre du fichier" 3824 3825 msgid "Action" 3826 msgstr "Action" 3827 3828 msgid "File size" 3829 msgstr "Taille du fichier" 3830 3831 msgid "Documents" 3832 msgstr "Documents" 3833 3834 3835 msgid "User Detail" 3836 msgstr "Détail de l'utilisateur" -
apimo/trunk/languages/apimo-it_IT.po
r2986633 r3000815 3810 3810 msgid "Yearly" 3811 3811 msgstr "Annuale" 3812 3813 3814 3815 msgid "Location Map" 3816 msgstr "Mappa di localizzazione" 3817 3818 msgid "No documents found for this property" 3819 msgstr "Nessun documento trovato per questa proprietà" 3820 3821 msgid "File title" 3822 msgstr "Titolo del file" 3823 3824 msgid "Action" 3825 msgstr "Azione" 3826 3827 msgid "File size" 3828 msgstr "Dimensione del file" 3829 3830 msgid "Documents" 3831 msgstr "Documenti" 3832 3833 msgid "User Detail" 3834 msgstr "Dettagli utente" -
apimo/trunk/languages/apimo-ru_RU.po
r2986633 r3000815 3887 3887 msgid "Yearly" 3888 3888 msgstr "" 3889 3890 msgid "Location Map" 3891 msgstr "Карта местности" 3892 3893 msgid "No documents found for this property" 3894 msgstr "Документы для этого объекта не найдены" 3895 3896 msgid "File title" 3897 msgstr "Название файла" 3898 3899 msgid "Action" 3900 msgstr "Действие" 3901 3902 msgid "File size" 3903 msgstr "Размер файла" 3904 3905 msgid "Documents" 3906 msgstr "Документы" 3907 3908 msgid "User Detail" 3909 msgstr "Детали пользователя" -
apimo/trunk/readme.txt
r2993232 r3000815 3 3 Tags: real estate, property management, listings, clients, leads, showings, open houses, reports 4 4 Tested up to: 6.3.1 5 Stable tag: 2.5. 15 Stable tag: 2.5.2 6 6 License: GPLv2 7 7 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 94 94 == Changelog == 95 95 96 = 2.5.2 = 97 * New: Location details - Explore the location details of each property. 98 * New: Interactive map - Immerse yourself in an interactive map for property visualization. 99 * New: User details - View the user agent on each property. 100 * New: Energy consumption graph: Energy consumption graph. 101 * Enhanced: General improvements for a richer, more informative property management experience. 102 96 103 = 1.0 = 97 104 * Initial release -
apimo/trunk/templates/single_property_style_1.php
r2986633 r3000815 342 342 <div class="apimo-other-info-properties"> 343 343 <div class="Pro-info"> 344 344 345 <?php 345 346 $currentLanguage = get_bloginfo('language'); … … 557 558 558 559 </div> 560 561 562 <div class="Pro-info Pro-general-information"> 563 <h5 class="Pro-info-title"><?php _e('Location Details', 'apimo'); ?></h5> 564 <div class="details-table"> 565 <?php 566 $locationData = $metas['apimo_property_location']; 567 568 // Check if $locationData is an array 569 if (is_array($locationData)) { 570 // Loop through each serialized element 571 foreach ($locationData as $serializedLocation) { 572 // Unserialize the data 573 $location = unserialize($serializedLocation); 574 ?> 575 <?php if($location['country']): ?> 576 <dl class="row"> 577 <dt class="term"><?php esc_html_e('Country', 'apimo'); ?>:</dt> 578 <dd class="description"><?php echo esc_html($location['country']); ?></dd> 579 </dl> 580 <?php endif; ?> 581 582 <?php if($location['region']->name): ?> 583 <dl class="row"> 584 <dt class="term"><?php esc_html_e('Region', 'apimo'); ?>:</dt> 585 <dd class="description"><?php echo esc_html($location['region']->name); ?></dd> 586 </dl> 587 <?php endif; ?> 588 589 <?php if($location['city']->name): ?> 590 <dl class="row"> 591 <dt class="term"><?php esc_html_e('City', 'apimo'); ?>:</dt> 592 <dd class="description"><?php echo esc_html($location['city']->name); ?></dd> 593 </dl> 594 <?php endif; ?> 595 596 <?php if($location['district']->name): ?> 597 <dl class="row"> 598 <dt class="term"><?php esc_html_e('District', 'apimo'); ?>:</dt> 599 <dd class="description"><?php echo esc_html($location['district']->name); ?></dd> 600 </dl> 601 <?php endif; ?> 602 603 604 605 606 <?php 607 global $iframeSrc; 608 if ($location['latitude'] && $location['longitude']) { 609 610 $span = 0.09; 611 612 $iframeSrc = "https://maps.google.com/maps?width=100%25&height=600&hl=en&t=&z=16&ie=UTF8&&spn={$span},{$span}&&ll={$location['latitude']},{$location['longitude']}&&output=embed"; 613 614 } 615 616 ?> 617 618 619 <?php 620 } 621 } 622 ?> 623 624 625 626 627 </div> 628 629 <?php 630 if($iframeSrc){ 631 ?> 632 <div class="map"> 633 <h5 class="Pro-info-title"><?php _e('Location Map', 'apimo'); ?></h5> 634 <iframe src="<?php echo $iframeSrc ?>" width="100%" height="400" frameborder="0"></iframe> 635 </div> 636 <?php 637 } 638 ?> 639 </div> 640 559 641 <?php 560 // foreach (maybe_unserialize($metas['apimo_regulations'][0]) as $regulations) { 561 // if ($regulations->type == 13) { 562 // $regulation_type = $regulations->value; 563 // } 564 // } 565 566 $unserialized_data = maybe_unserialize($metas['apimo_regulations'][0]); 567 // print_r($unserialized_data);die(); 568 global $regulation_type; 569 if (is_array($unserialized_data)) { 570 foreach ($unserialized_data as $regulations) { 571 // global $regulation_type; 572 // echo $regulations->value . "<br>"; 573 if ($regulations->type == 13) { 574 $regulation_type = $regulations->value; 575 } 576 577 // $regulation_type = $regulations->value; 578 } 579 } 642 // foreach (maybe_unserialize($metas['apimo_regulations'][0]) as $regulations) { 643 // if ($regulations->type == 13) { 644 // $regulation_type = $regulations->value; 645 // } 646 // } 647 global $unserialized_data; 648 $unserialized_data = maybe_unserialize($metas['apimo_regulations'][0]); 649 650 // print_r($unserialized_data);die(); 651 global $regulation_type; 652 if (is_array($unserialized_data)) { 653 foreach ($unserialized_data as $regulations) { 654 // global $regulation_type; 655 // echo $regulations->value . "<br>"; 656 if ($regulations->type == 13) { 657 $regulation_type = $regulations->value; 658 } 659 660 // $regulation_type = $regulations->value; 661 } 662 } 580 663 581 664 582 665 ?> 666 583 667 <div class="Pro-info"> 584 668 <h5 class="Pro-info-title"><?php _e('Energy performance', 'apimo'); ?></h5> … … 586 670 <div class="energy-class"> 587 671 <div class="apimo-row"> 588 <div class="apimo-col-12 apimo-col-lg-4"> 589 <div class="energy-class__chart"> 590 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='A4'){ echo 'is-active'; } ?>"> 591 A4 592 </span> <span class="energy-class__bar energy-class__bar--nA4"></span> 672 <?php 673 if($unserialized_data[0]->graph && $unserialized_data[0]->type == '1'){ 674 ?> 675 <div class="apimo-col-12 apimo-col-lg-4"> 676 <div class="regulation"> 677 <img src="<?php echo $unserialized_data[0]->graph ?>" alt="graph"> 678 679 </div> 593 680 </div> 594 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='A3'){ echo 'is-active'; } ?>"> 595 A3 596 </span> <span class="energy-class__bar energy-class__bar--nA3"></span> 597 </div> 598 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='A2'){ echo 'is-active'; } ?>"> 599 A2 600 </span> <span class="energy-class__bar energy-class__bar--nA2"></span> 601 </div> 602 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='A1'){ echo 'is-active'; } ?>"> 603 A1 604 </span> <span class="energy-class__bar energy-class__bar--nA1"></span> 605 </div> 606 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='B'){ echo 'is-active'; } ?>"> 607 B 608 </span> <span class="energy-class__bar energy-class__bar--nB"></span> 609 </div> 610 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='C'){ echo 'is-active'; } ?>"> 611 C 612 </span> <span class="energy-class__bar energy-class__bar--nC"></span> 613 </div> 614 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='D'){ echo 'is-active'; } ?>"> 615 D 616 </span> <span class="energy-class__bar energy-class__bar--nD"></span> 617 </div> 618 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='E'){ echo 'is-active'; } ?>"> 619 E 620 </span> <span class="energy-class__bar energy-class__bar--nE"></span> 621 </div> 622 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='F'){ echo 'is-active'; } ?>"> 623 F 624 </span> <span class="energy-class__bar energy-class__bar--nF"></span> 625 </div> 626 <div class="energy-class__division"><span class="energy-class__letter <?php if($regulation_type=='G'){ echo 'is-active'; } ?>"> 627 G 628 </span> <span class="energy-class__bar energy-class__bar--nG"></span> 629 </div> 630 </div> 631 </div> 681 <?php 682 } 683 ?> 684 632 685 <div class="apimo-col-12 apimo-col-lg-4"> 633 686 <div class="energy-box-color"> … … 816 869 </div> 817 870 </div> 871 818 872 </div> 819 873 </div> 820 874 </div> 821 875 </div> 822 823 <?php $data_of_area_service = (wp_get_object_terms(get_the_ID(), array('apimo_service', 'apimo_areas'))); 876 <!--Documents --> 877 <?php 878 if (isset($metas['apimo_documents']) && is_array($metas['apimo_documents']) && !empty($metas['apimo_documents'])): 879 foreach ($metas['apimo_documents'] as $serializedDoc): 880 $doc = unserialize($serializedDoc); 881 882 if (isset($doc[0])): 883 ?> 884 <div class="Pro-info"> 885 <h5 class="Pro-info-title"><?php _e('Documents', 'apimo'); ?></h5> 886 887 <?php 888 $docs = $metas['apimo_documents']; 889 890 if (is_array($docs) && !empty($docs)): 891 ?> 892 <table> 893 <thead> 894 <tr> 895 <th><?= __('File title', 'apimo'); ?></th> 896 <th><?= __('File size', 'apimo'); ?></th> 897 <th><?= __('Download', 'apimo'); ?></th> 898 </tr> 899 </thead> 900 <tbody> 901 <?php 902 903 foreach ($docs as $serializedDoc): 904 $doc = unserialize($serializedDoc); 905 906 if (is_array($doc) && !empty($doc)): 907 foreach ($doc as $singleDoc): 908 if (!empty($singleDoc->name) && !empty($singleDoc->filesize) && !empty($singleDoc->download_url)): 909 ?> 910 <tr> 911 912 <td><?= pathinfo($singleDoc->name, PATHINFO_FILENAME); ?></td> 913 914 <td><?= $singleDoc->filesize . ' Kb'; ?></td> 915 <td style="text-align: center;"><a href="<?= $singleDoc->download_url; ?>" target="_blank"><img width="50" src="<?= plugin_dir_url(dirname(__FILE__)) . 'assets/download_icon.png'; ?>" alt="<?= __('Download', 'apimo'); ?>"></a></td> 916 </tr> 917 <?php 918 endif; 919 endforeach; 920 endif; 921 endforeach; 922 923 924 ?> 925 </tbody> 926 </table> 927 <?php 928 endif; 929 ?> 930 </div> 931 <?php 932 endif; 933 endforeach; 934 endif; 935 ?> 936 937 938 939 <?php 940 $data_of_area_service = (wp_get_object_terms(get_the_ID(), array('apimo_service', 'apimo_areas'))); 824 941 $final_array = array_map(function ($term) { 825 942 return $term->term_id; … … 864 981 </ul> 865 982 </div> 983 <!--user details --> 984 <?php 985 if($apimo_archive_settings['userinfo'] == 'show'){ 986 ?> 987 <div class="Pro-info Pro-general-information"> 988 <h5 class="Pro-info-title"><?php _e('User Detail', 'apimo'); ?></h5> 989 990 991 992 <?php 993 $property_user_data = $metas['apimo_user_data']; 994 995 foreach ($property_user_data as $serialized_user) { 996 // Unserialize the data 997 $user = unserialize($serialized_user); 998 999 // Output HTML with dynamically populated user data 1000 ?> 1001 <div class="apimo_profile_picture"> 1002 <div class="profile_img"> 1003 <img src="<?php echo isset($user->picture) ? $user->picture : plugin_dir_url(dirname(__FILE__)) . 'assets/user_image.png' ?>" alt="Profile Picture"> 1004 </div> 1005 <div class="profile_info"> 1006 <div class="username"> 1007 <?php echo isset($user->firstname) && isset($user->lastname) ? $user->firstname . ' ' . $user->lastname : 'N/A'; ?> 1008 <?php if (isset($user->active) && $user->active) : ?> 1009 <img src="<?php echo plugin_dir_url(dirname(__FILE__)) . 'assets/verify.png' ?>" alt="Verified Icon"> 1010 <?php endif; ?> 1011 </div> 1012 1013 <div class="info"> 1014 1015 <a href="tel:<?php echo isset($user->phone) ? $user->phone : ''; ?>"> 1016 <span><?php _e('Phone', 'apimo') ?> : <?php echo isset($user->phone) ? $user->phone : 'N/A'; ?></span> 1017 </a> 1018 1019 <a href="tel:<?php echo isset($user->mobile) ? $user->mobile : ''; ?>"> 1020 <span><?php _e('Mobile', 'apimo') ?> : <?php echo isset($user->mobile) ? $user->mobile : 'N/A'; ?></span> 1021 </a> 1022 1023 <span><?php _e('Email','apimo') ?> : <?php echo isset($user->email) ? $user->email : 'N/A'; ?></span> 1024 1025 1026 <?php if(isset($user->fax)): ?> 1027 <span><?php _e('Fax','apimo') ?> <?php echo $user->fax ?></span> 1028 <?php endif; ?> 1029 </div> 1030 <div class="contact-button"> 1031 <?php 1032 $emailSubject = __('Interested in Property Inquiry', 'apimo'); 1033 $emailBody = __('Hello, I\'m interested in this property:', 'apimo') . ' ' . get_permalink($property_id); 1034 $encodedEmailBody = rawurlencode($emailBody); 1035 $encodedEmail = base64_encode(isset($user->email) ? $user->email : 'N/A'); 1036 ?> 1037 <script type="text/javascript"> 1038 document.write('<a href="mailto:' + atob("<?php echo $encodedEmail; ?>") + '?subject=<?php echo rawurlencode($emailSubject); ?>&body=<?php echo $encodedEmailBody; ?>" class="button" target="_blank"><?php _e('Contact', 'apimo'); ?></a>'); 1039 </script> 1040 <noscript> 1041 <span>Email address is protected by JavaScript.</span> 1042 </noscript> 1043 </div> 1044 </div> 1045 </div> 1046 <?php 1047 } 1048 ?> 1049 1050 1051 1052 </div> 1053 <?php 1054 } 1055 ?> 866 1056 867 1057 </div>
Note: See TracChangeset
for help on using the changeset viewer.