Skip to content

Commit

Permalink
✏️ Change label to name
Browse files Browse the repository at this point in the history
  • Loading branch information
Gellipapa committed Sep 21, 2024
1 parent 5b29feb commit 6ea41f8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions client/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ function ReturnVehicleProvider()

for k, v in ipairs(vehicles) do
local returnPrice = ESX.Math.Round(v.price * 0.75)
local vehicleLabel = getVehicleFromModel(v.vehicle).label
local vehicleLabel = getVehicleFromModel(v.vehicle).name

table.insert(elements, {
label = ('%s [<span style="color:orange;">%s</span>]'):format(vehicleLabel, TranslateCap('generic_shopitem', ESX.Math.GroupDigits(returnPrice))),
Expand Down Expand Up @@ -417,7 +417,7 @@ function OpenPopVehicleMenu()
local elements = {}

for k,v in ipairs(vehicles) do
local vehicleLabel = getVehicleFromModel(v.vehicle).label
local vehicleLabel = getVehicleFromModel(v.vehicle).name

table.insert(elements, {
label = ('%s [<span style="color:green;">%s</span>]'):format(vehicleLabel, TranslateCap('generic_shopitem', ESX.Math.GroupDigits(v.price))),
Expand Down Expand Up @@ -454,7 +454,7 @@ function OpenRentedVehiclesMenu()
local elements = {}

for k,v in ipairs(vehicles) do
local vehicleLabel = getVehicleFromModel(v.name).label
local vehicleLabel = getVehicleFromModel(v.name).name

table.insert(elements, {
label = ('%s: %s - <span style="color:orange;">%s</span>'):format(v.playerName, vehicleLabel, v.plate),
Expand Down
2 changes: 1 addition & 1 deletion server/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ AddEventHandler('esx_vehicleshop:returnProvider', function(vehicleModel)
end
TriggerEvent('esx_addonaccount:getSharedAccount', 'society_cardealer', function(account)
local price = ESX.Math.Round(result.price * 0.75)
local vehicleLabel = getVehicleFromModel(vehicleModel).label
local vehicleLabel = getVehicleFromModel(vehicleModel).name

account.addMoney(price)
xPlayer.showNotification(TranslateCap('vehicle_sold_for', vehicleLabel, ESX.Math.GroupDigits(price)))
Expand Down

0 comments on commit 6ea41f8

Please sign in to comment.