|
13 | 13 | $sql = mysqli_query( |
14 | 14 | $mysqli, |
15 | 15 | "SELECT SQL_CALC_FOUND_ROWS * FROM software |
16 | | - LEFT JOIN logins ON login_software_id = software_id |
17 | 16 | WHERE software_client_id = $client_id |
18 | 17 | AND software_template = 0 |
19 | 18 | AND software_$archive_query |
|
81 | 80 | <th><a class="text-secondary" href="?<?php echo $url_query_strings_sort; ?>&sort=software_type&order=<?php echo $disp; ?>">Type</a></th> |
82 | 81 | <th><a class="text-secondary" href="?<?php echo $url_query_strings_sort; ?>&sort=software_license_type&order=<?php echo $disp; ?>">License Type</a></th> |
83 | 82 | <th><a class="text-secondary" href="?<?php echo $url_query_strings_sort; ?>&sort=software_seats&order=<?php echo $disp; ?>">Seats</a></th> |
84 | | - <th></th> |
85 | 83 | <th class="text-center">Action</th> |
86 | 84 | </tr> |
87 | 85 | </thead> |
|
91 | 89 | while ($row = mysqli_fetch_array($sql)) { |
92 | 90 | $software_id = intval($row['software_id']); |
93 | 91 | $software_name = nullable_htmlentities($row['software_name']); |
| 92 | + $software_description = nullable_htmlentities($row['software_description']); |
94 | 93 | $software_version = nullable_htmlentities($row['software_version']); |
95 | 94 | $software_type = nullable_htmlentities($row['software_type']); |
96 | 95 | $software_license_type = nullable_htmlentities($row['software_license_type']); |
|
101 | 100 | $software_notes = nullable_htmlentities($row['software_notes']); |
102 | 101 | $software_created_at = nullable_htmlentities($row['software_created_at']); |
103 | 102 |
|
104 | | - // Get Login |
105 | | - $login_id = intval($row['login_id']); |
106 | | - $login_username = nullable_htmlentities(decryptLoginEntry($row['login_username'])); |
107 | | - $login_password = nullable_htmlentities(decryptLoginEntry($row['login_password'])); |
108 | | - |
109 | 103 | $seat_count = 0; |
110 | 104 |
|
111 | 105 | // Asset Licenses |
|
130 | 124 |
|
131 | 125 | ?> |
132 | 126 | <tr> |
133 | | - <td><a class="text-dark" href="#" data-toggle="modal" data-target="#editSoftwareModal<?php echo $software_id; ?>"><?php echo "$software_name<br><span class='text-secondary'>$software_version</span>"; ?></a></td> |
134 | | - <td><?php echo $software_type; ?></td> |
135 | | - <td><?php echo $software_license_type; ?></td> |
136 | | - <td><?php echo "$seat_count / $software_seats"; ?></td> |
137 | 127 | <td> |
138 | | - <?php |
139 | | - if ($login_id > 0) { ?> |
140 | | - <button type="button" class="btn btn-dark btn-sm" data-toggle="modal" data-target="#viewPasswordModal<?php echo $login_id; ?>"><i class="fas fa-key"></i></button> |
141 | | - |
142 | | - <div class="modal" id="viewPasswordModal<?php echo $login_id; ?>" tabindex="-1"> |
143 | | - <div class="modal-dialog"> |
144 | | - <div class="modal-content bg-dark"> |
145 | | - <div class="modal-header"> |
146 | | - <h5 class="modal-title"><i class="fa fa-fw fa-key"></i> <?php echo $software_name; ?></h5> |
147 | | - <button type="button" class="close text-white" data-dismiss="modal"> |
148 | | - <span>×</span> |
149 | | - </button> |
150 | | - </div> |
151 | | - <div class="modal-body bg-white"> |
152 | | - <div class="form-group"> |
153 | | - <div class="input-group"> |
154 | | - <div class="input-group-prepend"> |
155 | | - <span class="input-group-text"><i class="fa fa-user"></i></span> |
156 | | - </div> |
157 | | - <input type="text" class="form-control" value="<?php echo $login_username; ?>" readonly> |
158 | | - </div> |
159 | | - </div> |
160 | | - <div class="form-group"> |
161 | | - <div class="input-group"> |
162 | | - <div class="input-group-prepend"> |
163 | | - <span class="input-group-text"><i class="fa fa-lock"></i></span> |
164 | | - </div> |
165 | | - <input type="text" class="form-control" value="<?php echo $login_password; ?>" readonly> |
166 | | - </div> |
167 | | - </div> |
168 | | - </div> |
169 | | - </div> |
| 128 | + <a class="text-dark" href="#" data-toggle="modal" data-target="#editSoftwareModal<?php echo $software_id; ?>"> |
| 129 | + <div class="media"> |
| 130 | + <i class="fa fa-fw fa-2x fa-cube mr-3"></i> |
| 131 | + <div class="media-body"> |
| 132 | + <p> |
| 133 | + <?php echo "$software_name <span>$software_version</span>"; ?> |
| 134 | + <br> |
| 135 | + <small class="text-secondary"><?php echo $software_description; ?></small> |
| 136 | + </p> |
170 | 137 | </div> |
171 | 138 | </div> |
172 | | - |
173 | | - <?php |
174 | | - } |
175 | | - |
176 | | - ?> |
| 139 | + </a> |
177 | 140 | </td> |
| 141 | + <td><?php echo $software_type; ?></td> |
| 142 | + <td><?php echo $software_license_type; ?></td> |
| 143 | + <td><?php echo "$seat_count / $software_seats"; ?></td> |
178 | 144 | <td> |
179 | 145 | <div class="dropdown dropleft text-center"> |
180 | 146 | <button class="btn btn-secondary btn-sm" data-toggle="dropdown"> |
|
216 | 182 | </div> |
217 | 183 |
|
218 | 184 | <?php |
| 185 | + |
219 | 186 | require_once "client_software_add_modal.php"; |
220 | 187 |
|
221 | 188 | require_once "client_software_add_from_template_modal.php"; |
222 | 189 |
|
223 | 190 | require_once "client_software_export_modal.php"; |
224 | 191 |
|
225 | 192 | require_once "footer.php"; |
226 | | - |
0 commit comments