more corrections

This commit is contained in:
2018-10-25 22:40:14 -05:00
parent deaecb9d8b
commit d2357f1208
9 changed files with 13 additions and 34 deletions

View File

@@ -22,7 +22,7 @@ class MoonsController extends Controller
//Update the prices for the moon
$moonCalc->FetchNewPrices();
//get all of the moons from the database
$moons = DB::table('moons')->get();
$moons = DB::table('Moons')->get();
//declare the html variable and set it to null
$html = '';
foreach($moons as $moon) {

View File

@@ -7,11 +7,11 @@ use Illuminate\Database\Eloquent\Model;
class Moon extends Model
{
// Table Name
protected $table = 'moons';
protected $table = 'Moons';
//Primary Key
public $primaryKey = 'id';
// Timestamps
public $timestamps = 'true';
public $timestamps = 'false';
}

View File

@@ -13,5 +13,5 @@ class Price extends Model
public $primaryKey = 'id';
// Timestamps
public $timestamps = 'true';
public $timestamps = 'false';
}

View File

@@ -13,7 +13,7 @@ class CreateMoonsTable extends Migration
*/
public function up()
{
Schema::create('moons', function (Blueprint $table) {
Schema::create('Moons', function (Blueprint $table) {
$table->increments('id');
$table->string('Region');
$table->string('System');
@@ -30,7 +30,6 @@ class CreateMoonsTable extends Migration
$table->integer('FourthQuantity')->default('0');
$table->string('RentalCorp')->default('0');
$table->integer('RentalEnd')->default('0');
$table->timestamps();
});
}
@@ -41,6 +40,6 @@ class CreateMoonsTable extends Migration
*/
public function down()
{
Schema::dropIfExists('moons');
Schema::dropIfExists('Moons');
}
}

View File

@@ -19,7 +19,6 @@ class CreatePricesTable extends Migration
$table->integer('ItemId');
$table->decimal('Price', 20, 2);
$table->string('Time');
$table->timestamps();
});
}
@@ -30,6 +29,6 @@ class CreatePricesTable extends Migration
*/
public function down()
{
Schema::dropIfExists('prices');
Schema::dropIfExists('Prices');
}
}

View File

@@ -13,7 +13,7 @@ class CreateOrepricesTable extends Migration
*/
public function up()
{
Schema::create('oreprices', function (Blueprint $table) {
Schema::create('OrePrices', function (Blueprint $table) {
$table->increments('id');
$table->string('Name');
$table->integer('ItemId');
@@ -32,6 +32,6 @@ class CreateOrepricesTable extends Migration
*/
public function down()
{
Schema::dropIfExists('oreprices');
Schema::dropIfExists('OrePrices');
}
}

View File

@@ -13,7 +13,7 @@ class CreateConfigTable extends Migration
*/
public function up()
{
Schema::create('config', function (Blueprint $table) {
Schema::create('Config', function (Blueprint $table) {
$table->decimal('RentalTax', 5,2);
$table->decimal('AllyRentalTax', 5, 2);
$table->decimal('RefineRate', 5, 2);
@@ -28,6 +28,6 @@ class CreateConfigTable extends Migration
*/
public function down()
{
Schema::dropIfExists('config');
Schema::dropIfExists('Config');
}
}

View File

@@ -109,10 +109,6 @@ INSERT INTO `item_composition` (`Name`, `ItemId`, `m3Size`, `BatchSize`, `Tritan
('Loparite', 45512, '10.00', 100, 0, 0, 0, 0, 100, 200, 50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 20, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 22, 0),
('Ytterbite', 45513, '10.00', 100, 0, 0, 0, 0, 50, 100, 200, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 20, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22);
--
-- Indexes for dumped tables
--
--
-- Indexes for table `ItemComposition`
--

View File

@@ -26,7 +26,7 @@ SET time_zone = "+00:00";
-- Table structure for table `Moons`
--
CREATE TABLE IF NOT EXISTS `moons` (
CREATE TABLE IF NOT EXISTS `Moons` (
`id` int(10) NOT NULL,
`System` varchar(10) DEFAULT NULL,
`Planet` varchar(10) DEFAULT NULL,
@@ -48,7 +48,7 @@ CREATE TABLE IF NOT EXISTS `moons` (
-- Dumping data for table `Moons`
--
INSERT INTO `moons` (`id`, `System`, `Planet`, `Moon`, `StructureName`, `FirstOre`, `FirstQuantity`, `SecondOre`, `SecondQuantity`, `ThirdOre`, `ThirdQuantity`, `FourthOre`, `FourthQuantity`, `RentalCorp`, `RentalEnd`) VALUES
INSERT INTO `Moons` (`id`, `System`, `Planet`, `Moon`, `StructureName`, `FirstOre`, `FirstQuantity`, `SecondOre`, `SecondQuantity`, `ThirdOre`, `ThirdQuantity`, `FourthOre`, `FourthQuantity`, `RentalCorp`, `RentalEnd`) VALUES
(50, 'LN-56V', '3', '1', 'No Name', 'Cubic Bistot', 35, 'Stable Veldspar', 35, 'Sylvite', 10, 'Zircon', 20, 'HYPNO', 1533081600),
(52, 'LN-56V', '5', '7', '5-7', 'Loparite', 21, 'Monazite', 20, 'Pellucid Crokite', 31, 'Scintillating Hemorphite', 29, 'UOS', 1515715200),
(53, 'LN-56V', '5', '15', 'PUB', 'Carnotite', 25, 'Opulent Pyroxeres', 45, 'Zircon', 31, 'None', 0, 'HYPNO', 1536624000),
@@ -84,21 +84,6 @@ INSERT INTO `moons` (`id`, `System`, `Planet`, `Moon`, `StructureName`, `FirstOr
(83, 'B-A587', '6', '6', 'No Name', 'Chromite', 22, 'Opulent Pyroxeres', 17, 'Platinoid Omber', 17, 'Ytterbite', 44, NULL, NULL),
(84, 'LN-56V', '4', '8', 'No Name', 'Dazzling Spodumain', 10, 'Flawless Arkonor', 32, 'Glossy Scordite', 29, 'Zircon', 29, NULL, NULL);
--
-- Indexes for dumped tables
--
--
-- Indexes for table `Moons`
--
ALTER TABLE `moons`
ADD PRIMARY KEY (`id`),
ADD UNIQUE KEY `id` (`id`);
--
-- AUTO_INCREMENT for dumped tables
--
--
-- AUTO_INCREMENT for table `Moons`
--