[Tutorial] - GCPhone - Adding calls and job messages

just perfect… i have to be honest i found and fix everything yesterday night… but.ypu.conrfirm that i made eveything right. Thx a lot.for your time.

anyone can help me fix this?

I got a bit odd problem.

The problem is if someone types to a company and they try to open it the phone locks up and stays like this. And only fix is to restart the phone script. anyone help?

1 Like

it says “duplicate column name phone_number”

Check here, @Gannon have release a update of gcphone : Releases · N3MTV/gcphone · GitHub

And look compatibility with mysql-async :smiley:

Because you’re already using esx_phone. Rename your phone_number collumn to phone_number_old or something

1 Like

When players join my server (friends that are helping me test), I get this error in console and no one receives a phone number.

[ERROR] [MySQL] [gcphone] An error happens on MySQL for query "[object Object]": WARN_DATA_TRUNCATED: Data truncated for column 'phone_number' at row 1
Error: (node:70176) UnhandledPromiseRejectionWarning: AssertionError [ERR_ASSERTION]: unexpected PromiseRejectEvent
    at process.<anonymous> (internal/process/promises.js:27:25)
    at <anonymous>
    at Query.db.query [as _callback] (mysql-async.js:4973:13)
    at Query.Sequence.end (mysql-async.js:280:24)
    at Query.ErrorPacket (mysql-async.js:2122:8)
    at Protocol._parsePacket (mysql-async.js:5941:23)
    at Parser.write (mysql-async.js:6198:12)
    at Protocol.write (mysql-async.js:5701:16)
    at Socket.<anonymous> (mysql-async.js:693:28)
    at emitOne (events.js:116:13)
Error: (node:70176) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
Error: (node:70176) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
Error: (node:70176) UnhandledPromiseRejectionWarning: Error: WARN_DATA_TRUNCATED: Data truncated for column 'phone_number' at row 1
    at Query.Sequence._packetToError (mysql-async.js:244:14)
    at Query.ErrorPacket (mysql-async.js:2109:18)
    at Protocol._parsePacket (mysql-async.js:5941:23)
    at Parser.write (mysql-async.js:6198:12)
    at Protocol.write (mysql-async.js:5701:16)
    at Socket.<anonymous> (mysql-async.js:693:28)
    at emitOne (events.js:116:13)
    at Socket.emit (events.js:211:7)
    at addChunk (_stream_readable.js:263:12)
    at readableAddChunk (_stream_readable.js:250:11)
    --------------------
    at Pool.query (mysql-async.js:4728:23)
    at Promise (mysql-async.js:4970:12)
    at new Promise (<anonymous>)
    at execute (mysql-async.js:4967:26)
    at Object.global.exports [as callback] (mysql-async.js:5009:5)
    at citizen:/scripting/v8/main.js:96:41
Error: (node:70176) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)

Hello,
We have a problem since we are 64 slots.
Indeed when we make a call we do not hear the other player and vice versa.
Do you have a solution because I have to look in the whole script but I can not find.
do you know how to make fire alarms happen with the GPS coordinates on the phone

Thank you

For me, it’s because gcphone use a GTA:Voice and not mumble voice or rtc voice.
With a rtc server, gcphone in 40/60 slots work fine.

@HalCroves

thank you I will disable the mumble voice in conponents.json because your phone is too good I do not want to put another .
sorry for my bad english i’m french

Check is row ‘phone_number’ is correct ( type VARCHAR and length >= numberFormat )

Yeah my man FourthBeam helped me, I’m stupid.

1 Like

Yo, getting this error on my phone

Something about message length? What is this.

g%3Bdgkjsl%3Bdgks%3Blgsdg

Is not real error, I jute warning to invit player to remove old message.

You can change limit in config.json ( warningMessageCount: 99999999 )

2 Likes

Hello,
Just a question but has anyone been able to or thought about adding mouse integration to this without using keyboard controls? Just like ESX Phone

Thanks

This right?

}, [n(“InfoBare”), t._v(" "), t.messages.length >= 220 ? n(“span”, {

I’d change that to 9999999.

  • I have ESX server
  • Hosted in zap host
  • I did set up sql in database coreclty
  • I don’t use another phone resource/plugin
  • I’ve put start gcphone before jobs
  • I’ve cleaned server’s cashe
  • I did follow the tutorial corecly
  • I can call my friend and sent messages to each other
  • I did this change in order to work the phone call
  • I turned useWebRTCVocal from true to false

And my problem is that Police, ambulance and generarly services doesn’t take any message if someoner die or call police, ambulance etc.

and my config.json is this

{
“reseau”: “COSMOTE 4G”,
“warningMessageCount”: 250,
“themeColor”: “#E900FF”,
“colors”: [
#EF5350”,
#EC407A”,
#AB47BC”,
#7E57C2”,
#5C6BC0”,
#42A5F5”,
#29B6F6”,
#26C6DA”,
#26A69A”,
#66BB6A”,
#9CCC65”,
#D4E157”,
#FFCA28”,
#FFA726”,
#FF7043”,
#8D6E63”,
#78909C
],

“useFormatNumberFrance”: false,

“useWebRTCVocal”: false,
“RTCConfig”: {
“iceServers”: [{
“urls”: [“turn:gannon.ovh”],
“username”: “jojo”,
“credential”: “pass”
}]
},

“background” : {
“Calvin & Hobbes”: “back001.jpg”,
“Destiny”: “back002.jpg”,
“Stormtrooper”: “back003.jpg”,
“Custom URL”: “URL”
},
“background_default”: {
“label”: “Calvin & Hobbes”,
“value”: “back001.jpg”
},

“coque”: {
“Sansumg S8”: “s8.png”,
“Iphone X”: “iphonex.png”,
“Brick Base”: “base.png”,
“Transparent”: “transparent.png”
},
“coque_default”: {
“label”: “Sansumg S8”,
“value”: “s8.png”
},

“serviceCall”: [
{
“display”: “Police”,
“icon”: “/html/static/img/icons_app/bank.png”,
“subMenu”: [
{
“title”: “Send a message”,
“eventName”: “esx_addons_gcphone:call”,
“type”: {
“number”: “police”
}
},
{
“title”: “Call”,
“eventName”: “gcphone:autoCallNumber”,
“type”: {
“number”: “911”
}
}
]
},
{
“display”: “Ambulance”,
“backgroundColor”: “red”,
“subMenu”: [
{
“title”: “Send a message”,
“eventName”: “esx_addons_gcphone:call”,
“type”: {
“number”: “ambulance”
}
}
]
}
],

“defaultContacts”: [
{ “number”: “ambulance” , “display”: “AMBULANCE”, “icon”: “/html/static/img/icons_app/bank.png” },
{ “number”: “police” , “display”: “Police”, “backgroundColor”: “blue”, “letter”: “J” }
],

“apps”: [
{
“name”: “Téléphone”,
“fr_FR__name”: “Téléphone”,
“en_US__name”: “Phone”,
“icons”: “/html/static/img/icons_app/call.png”,
“routeName”: “appels”,
“inHomePage”: true
},
{
“name”: “Messages”,
“icons”: “/html/static/img/icons_app/sms.png”,
“routeName”: “messages”,
“inHomePage”: true,
“puceRef”: “nbMessagesUnread”
},
{
“name”: “Contacts”,
“icons”: “/html/static/img/icons_app/contacts.png”,
“routeName”: “contacts”,
“inHomePage”: true
},
{
“name”: “Paramètres”,
“fr_FR__name”: “Paramètres”,
“en_US__name”: “System”,
“icons”: “/html/static/img/icons_app/settings.png”,
“routeName”: “parametre”,
“inHomePage”: true
},
{
“name”: “Bank”,
“fr_FR__name”: “Banque”,
“en_US__name”: “Bank”,
“icons”: “/html/static/img/icons_app/bank.png”,
“routeName”: “bank”,
“inHomePage”: false
},
{
“name”: “Bourse”,
“fr_FR__name”: “Bourse”,
“en_US__name”: “Stock Market”,
“icons”: “/html/static/img/icons_app/bourse.png”,
“routeName”: “bourse”,
“enabled”: true
},
{
“name”: “Photo”,
“fr_FR__name”: “Photo”,
“en_US__name”: “Camera”,
“icons”: “/html/static/img/icons_app/photo.png”,
“routeName”: “photo”
},
{
“name”: “Dark Chat”,
“icons”: “/html/static/img/icons_app/tchat.png”,
“routeName”: “tchat”
},
{
“name”: “9GAG”,
“icons”: “/html/static/img/icons_app/9gag.png”,
“routeName”: “9gag”
}
],
“language”: {
“fr_FR”: {
“NAME”: “Français”,

  "PHONE_WARNING_MESSAGE": "Saturation mémoires !",
  "PHONE_WARNING_MESSAGE_MESS": "messages",

  "CONFIRM": "Accepter",
  "CANCEL": "Annuler",

  "APP_CONFIG_TITLE": "Paramètres",
  "APP_CONFIG_MY_MUNBER": "Mon numéro",
  "APP_CONFIG_WALLPAPER": "Fond d'écran",
  "APP_CONFIG_CASE": "Coque téléhone",
  "APP_CONFIG_ZOOM": "Zoom",
  "APP_CONFIG_VOLUME": "Volume",
  "APP_CONFIG_LANGUAGE": "Langue",
  "APP_CONFIG_RESET": "Formater",
  "APP_CONFIG_RESET_CONFIRM": "TOUT SUPPRIMER",
  "APP_PHONE_CALL": "Appeler",
  "APP_PHONE_DELETE": "Effacer",
  "APP_PHONE_DELETE_ALL": "Effacer TOUT.",

  "APP_PHONE_TITLE": "Téléphone",
  "APP_PHONE_MENU_FAVORITES": "Favoris",
  "APP_PHONE_MENU_RECENTS": "Récents",
  "APP_PHONE_MENU_CONTACTS": "Contacts",
  "APP_PHONE_ENTER_NUMBER": "Entrer un numero",

  "APP_BANK_TITLE": "Banque",

  "APP_BOURSE_TITLE": "Bourse",

  "APP_CONTACT_TITLE": "Contact",
  "APP_CONTACT_NEW": "Nouveau Contact",
  "APP_CONTACT_EDIT": "Modifier le contact",
  "APP_CONTACT_SAVE": "Enregistrer",
  "APP_CONTACT_CANCEL": "Annuler",
  "APP_CONTACT_DELETE": "Supprimer",
  "APP_CONTACT_LABEL_NAME": "Prénom - Nom",
  "APP_CONTACT_LABEL_NUMBER": "Numéro",

  "APP_MESSAGE_TITLE": "Messages",
  "APP_MESSAGE_NEW_MESSAGE": "Nouveau Message",
  "APP_MESSAGE_ERASE_CONVERSATION": "Effacer la conversation",
  "APP_MESSAGE_ERASE_ALL_CONVERSATIONS": "Effacer toutes les conv.",
  "APP_MESSAGE_SEND_GPS": "Envoyer Coord GPS",
  "APP_MESSAGE_SET_GPS": "Position GPS",
  "APP_MESSAGE_ZOOM_IMG": "Zoom",
  "APP_MESSAGE_DELETE": "Effacer",
  "APP_MESSAGE_SMS": "SMS",
  "APP_MESSAGE_CONTACT_TITLE": "Contacts",
  "APP_MESSAGE_CONTRACT_ENTER_NUMBER": "Enter un numero",
  "APP_MESSAGE_PLACEHOLDER_ENTER_MESSAGE": "Envoyer un message",
  
  "APP_DARKTCHAT_TITLE": "Dark Tchat",
  "APP_DARKTCHAT_NEW_CHANNEL": "Ajouter un channel",
  "APP_DARKTCHAT_DELETE_CHANNEL": "Effacer le channel",
  "APP_DARKTCHAT_CANCEL": "Annuler",
  "APP_DARKTCHAT_PLACEHOLDER_ENTER_MESSAGE": "Entrer un message",

  "TIMEAGO": [
    "à l'instant",
    ["il y a %s seconde", "il y a %s secondes"],
    ["il y a %s minute",  "il y a %s minutes"],
    ["il y a %s heure",   "il y a %s heures"],
    ["il y a %s jour",    "il y a %s jours"],
    ["il y a %s semaine", "il y a %s semaines"],
    ["il y a %s mois",    "il y a %s mois"],
    ["il y a %s an",      "il y a %s ans"]
  ]

},
"en_US": {
  "NAME": "English",

  "PHONE_WARNING_MESSAGE": "...",
  "PHONE_WARNING_MESSAGE_MESS": "messages",

  "CONFIRM": "Confirm",
  "CANCEL": "Cancel",

  "APP_CONFIG_TITLE": "System",
  "APP_CONFIG_MY_MUNBER": "My number",
  "APP_CONFIG_WALLPAPER": "Wallpapers",
  "APP_CONFIG_CASE": "Phone Case",
  "APP_CONFIG_ZOOM": "Zoom",
  "APP_CONFIG_VOLUME": "Volume",
  "APP_CONFIG_LANGUAGE": "Language",
  "APP_CONFIG_RESET": "Reset Divice",
  "APP_CONFIG_RESET_CONFIRM": "ERASE ALL DATA",

  "APP_PHONE_TITLE": "Phone",
  "APP_PHONE_MENU_FAVORITES": "Favorites",
  "APP_PHONE_MENU_RECENTS": "Recents",
  "APP_PHONE_MENU_CONTACTS": "Contacts",
  "APP_PHONE_ENTER_NUMBER": "Enter a Number",
  "APP_PHONE_CALL": "Call",
  "APP_PHONE_DELETE": "Erase",
  "APP_PHONE_DELETE_ALL": "Erase ALL.",

  "APP_BANK_TITLE": "Bank",

  "APP_BOURSE_TITLE": "Stock Market",

  "APP_CONTACT_TITLE": "Contact",
  "APP_CONTACT_NEW": "New Contact",
  "APP_CONTACT_EDIT": "Modify Contact",
  "APP_CONTACT_SAVE": "Save",
  "APP_CONTACT_CANCEL": "Cancel",
  "APP_CONTACT_DELETE": "Remove",
  "APP_CONTACT_LABEL_NAME": "Contact Name",
  "APP_CONTACT_LABEL_NUMBER": "Number",

  "APP_MESSAGE_TITLE": "Messages",
  "APP_MESSAGE_NEW_MESSAGE": "New Message",
  "APP_MESSAGE_ERASE_CONVERSATION": "ERASE the conversation",
  "APP_MESSAGE_ERASE_ALL_CONVERSATIONS": "ERASE all conversations",
  "APP_MESSAGE_SEND_GPS": "Send GPS Coordinates",
  "APP_MESSAGE_SET_GPS": "SET GPS",
  "APP_MESSAGE_ZOOM_IMG": "Zoom",
  "APP_MESSAGE_DELETE": "Erase",
  "APP_MESSAGE_SMS": "SMS",
  "APP_MESSAGE_CONTACT_TITLE": "Contacts",
  "APP_MESSAGE_CONTRACT_ENTER_NUMBER": "Enter a Number",
  "APP_MESSAGE_PLACEHOLDER_ENTER_MESSAGE": "Enter a message",
  
  "APP_DARKTCHAT_TITLE": "Dark Tchat",
  "APP_DARKTCHAT_NEW_CHANNEL": "Add channel",
  "APP_DARKTCHAT_DELETE_CHANNEL": "Delete channel",
  "APP_DARKTCHAT_CANCEL": "Cancel",
  "APP_DARKTCHAT_PLACEHOLDER_ENTER_MESSAGE": "Enter a message",
  
  "TIMEAGO": [
    "just now",
    ["%s second ago", "%s seconds ago"],
    ["%s minute ago", "%s minutes ago"],
    ["%s hour ago", "%s hours ago"],
    ["%s day ago", "%s days ago"],
    ["%s week ago", "%s weeks ago"],
    ["%s month ago", "%s months ago"],
    ["%s year ago", "%s years ago"]
  ]
},
"ja_JP": {
  "NAME": "日本"
}

}
}

  • also take a look in config

These resources will start by default.

start mapmanager
start chat
start spawnmanager
start sessionmanager
start fivem
start hardcap
start rconlog
start playernames
#inserted trough ZAP ressourcesystem
exec resources/vMenu/config/permissions.cfg
start vMenu
start mysql-async
start essentialmode
start esplugin_mysql
start es_admin2

##myinstallings##
start RealisticVehicleFailure
start speedometer
start frfuel
start JFSeatShuffle
start SeatbeltIndicator
start carhud
start RealisticVehicleFailure
start Calm-AI

#phone##
start vdk_call
start esx_addons_gcphone
start gcphone
start es_extended

From ESX Pack

start async
start cron
start instance
start es_camera
start skinchanger
start esx_ladderhud
start esx_extraitems
start esx_status
start esx_accessories
start esx_addonaccount
start esx_addoninventory
start esx_ambulancejob
start esx_animations
start esx_bankerjob
start esx_barbershop
start esx_basicneeds
start esx_billing
start esx_boat
start esx_boilerplate
start esx_clotheshop
start esx_cruisecontrol
start esx_datastore
start esx_dmvschool
start esx_drugs
start esx_holdup
start esx_identity
start esx_joblisting
start esx_jobs
start esx_license
start esx_lscustom
start esx_mecanojob
start esx_menu_default
start esx_menu_dialog
start esx_menu_list
start esx_migrate
start esx_optionalneeds
start esx_policejob
start esx_property
start esx_realestateagentjob
start esx_rpchat
start esx_service
start esx_shops
start esx_sit
start esx_skin
start esx_society
start esx_taxijob
start esx_vehicleshop
start esx_voice
start esx_weaponshop
start streetLabel
start esx_vehiclelock
start new_banking
start nocarjack
start esx_barbershop
start esx_drp_garage
start esx_carwash
start scoreboard
start esx_gym

End of ESX Pack

HalCroves If you have time please give it a look

it’s esx_addons_gcphone needs to be started before the job

It is before the jobs :confused:

1 Like

my phone works except for a few things:

player to player GPS coordinate system doesnt work but it does work for emergency services

cant use up arrow in a vehicle, usually bugs out, no errors.

1 Like