| 1234567891011121314151617 |
- <?php
- $assetSql = "SELECT *,
- asset.CreatedAt AS AssetCreatedAt,
- asset.UpdatedAt AS AssetUpdatedAt,
- assetcategory.CreatedAt AS AssetCategoryCreatedAt,
- assetcategory.UpdatedAt AS AssetCategoryUpdatedAt
- FROM asset asset
- JOIN assetcategory assetcategory ON assetcategory.AssetCategoryID =asset.AssetCategoryID
- WHERE asset.IsActive='1' $assetSqlfilter";
- $assetRes = mysqli_query($conn, $assetSql);
- if ($assetRes->num_rows > 0) {
- $id = 0;
- foreach ($assetRes as $assetrow) {
- $id++;
- $assets = array_merge($assets, array(array($id, $assetrow['AssetID'], $assetrow['AssetName'], $assetrow['IsInServiceCenter'], $assetrow['AssetCategoryTitle'], $assetrow['AssetCreatedAt'], $assetrow['AssetUpdatedAt'])));
- }
- }
|