| @@ -83,10 +83,10 @@ | ||
| 83 | 83 | $count_no_reply++; |
| 84 | 84 | } |
| 85 | 85 | |
| 86 | 86 | // Count solved. |
| 87 | - // Before using $GLOBALS['bbp_solved_topic'], check if it is set | |
| 88 | - if (isset($GLOBALS['bbp_solved_topic']) && $GLOBALS['bbp_solved_topic']->is_solved($topic_id)) { | |
| 87 | + // Before using $GLOBALS['forumax_solve_topic'], check if it is set | |
| 88 | + if (isset($GLOBALS['forumax_solve_topic']) && $GLOBALS['forumax_solve_topic']->is_solved($topic_id)) { | |
| 89 | 89 | $count_solved++; |
| 90 | 90 | } else { |
| 91 | 91 | $count_unsolved++; |
| 92 | 92 | } |
| @@ -128,9 +128,9 @@ | ||
| 128 | 128 | endif; |
| 129 | 129 | ?> |
| 130 | 130 | |
| 131 | 131 | <a class="easydocs-btn easydocs-btn-outline-blue easydocs-btn-sm easydocs-btn-round button button-info section-doc" id="bbpc-topic" target="_blank" name="submit" href="javascript:void(0)" bbp_forum_id="<?php echo esc_attr( $item ); ?>"> |
| 132 | - <?php esc_html_e( 'Add Topic', 'bbp-core' ); ?> | |
| 132 | + <?php esc_html_e( 'Add Topic', 'forumax' ); ?> | |
| 133 | 133 | </a> |
| 134 | 134 | </div> |
| 135 | 135 | <?php |
| 136 | 136 | endforeach; |
| @@ -143,14 +143,20 @@ | ||
| 143 | 143 | <?php |
| 144 | 144 | else : |
| 145 | 145 | ?> |
| 146 | 146 | <div class="eazydocs-no-content"> |
| 147 | - <img src="<?php echo esc_url( BBPC_IMG . 'icon/folder-open.png' ); ?>" alt="<?php esc_attr_e( 'Folder Open', 'bbp-core' ); ?>"> | |
| 148 | - <p class="big-p"> <?php esc_html_e( 'No forum has been found . Perhaps', 'bbp-core' ); ?> </p> | |
| 149 | - <p> <br> | |
| 147 | + <img src="<?php echo esc_url( FORUMAX_IMG . 'icon/folder-open.png' ); ?>" alt="<?php esc_attr_e( 'Folder Open', 'forumax' ); ?>"> | |
| 148 | + <p class="big-p"> <?php esc_html_e( 'No forums found. Get started by creating a new forum or importing demo data.', 'forumax' ); ?> </p> | |
| 149 | + <p class="forumax-empty-actions"> | |
| 150 | 150 | <a href="javascript:void(0)" type="button" id="bbpc-forum" class="button button-primary ezd-btn btn-lg"> |
| 151 | - <?php esc_html_e( 'Create Forum', 'bbp-core' ); ?> | |
| 151 | + <span class="dashicons dashicons-plus-alt2"></span> | |
| 152 | + <?php esc_html_e( 'Create Forum', 'forumax' ); ?> | |
| 152 | 153 | </a> |
| 154 | + <span class="forumax-actions-separator"><?php esc_html_e( 'or', 'forumax' ); ?></span> | |
| 155 | + <a href="javascript:void(0)" type="button" id="forumax-import-demo" class="button ezd-btn btn-lg forumax-import-demo-btn"> | |
| 156 | + <span class="dashicons dashicons-database-import"></span> | |
| 157 | + <?php esc_html_e( 'Import Demo Data', 'forumax' ); ?> | |
| 158 | + </a> | |
| 153 | 159 | </p> |
| 154 | 160 | </div> |
| 155 | 161 | <?php |
| 156 | 162 | endif; |
| @@ -169,12 +175,24 @@ | ||
| 169 | 175 | animation: { |
| 170 | 176 | enable: false, |
| 171 | 177 | }, |
| 172 | 178 | load: { |
| 173 | - filter: '<?php echo esc_js( bbpc_get_opt( 'default_filter', '.open-topics' ) ); ?>' | |
| 179 | + filter: '<?php echo esc_js( forumax_get_opt( 'default_filter', '.open-topics' ) ); ?>' | |
| 174 | 180 | }, |
| 175 | 181 | pagination: { |
| 176 | 182 | limit: 10, |
| 183 | + }, | |
| 184 | + callbacks: { | |
| 185 | + onMixEnd: function(state) { | |
| 186 | + var pagination = state.container.querySelector('.bbpc-admin-pagination'); | |
| 187 | + if ( pagination ) { | |
| 188 | + if ( state.totalShow === 0 ) { | |
| 189 | + pagination.style.display = 'none'; | |
| 190 | + } else { | |
| 191 | + pagination.style.display = 'block'; | |
| 192 | + } | |
| 193 | + } | |
| 194 | + } | |
| 177 | 195 | } |
| 178 | 196 | }; |
| 179 | 197 | for (let i = 0; i < docContainer.length; i++) { |
| 180 | 198 | var mixer1 = mixitup(docContainer[i], config); |