Skip to content

Commit

Permalink
Update rt-html-abs.js
Browse files Browse the repository at this point in the history
  • Loading branch information
ledangtrung committed Dec 9, 2024
1 parent 285afdc commit b3a9c49
Showing 1 changed file with 22 additions and 11 deletions.
33 changes: 22 additions & 11 deletions js/rt-html-abs.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,8 @@ function updateCopyButton(button, originalText) {

function callPhone(element) {
const actionData = {
actionID: "9001",
actionID: 9001,
orderNumber: 1,
phone: element.getAttribute('data-phone'),
type: 'act_call'
};
Expand All @@ -135,7 +136,8 @@ function callPhone(element) {

function sendSMS(element) {
const actionData = {
actionID: "9002",
actionID: 9002,
orderNumber: 1,
phone: element.getAttribute('data-phone'),
defaultMsg: element.getAttribute('data-default-msg'),
type: 'act_sms'
Expand All @@ -146,7 +148,8 @@ function sendSMS(element) {

function openLocation(element) {
const actionData = {
actionID: "9003",
actionID: 9003,
orderNumber: 1,
name: element.getAttribute('data-name'),
lat: parseFloat(element.getAttribute('data-lat')),
lon: parseFloat(element.getAttribute('data-lon')),
Expand All @@ -159,7 +162,8 @@ function openLocation(element) {

function shareContent(element) {
const actionData = {
actionID: "9004",
actionID: 9004,
orderNumber: 1,
copy: element.getAttribute('data-copy') === 'true',
body: element.getAttribute('data-body'),
subject: element.getAttribute('data-subject'),
Expand All @@ -171,7 +175,8 @@ function shareContent(element) {

function callCloudPhone(element) {
const actionData = {
actionID: "9005",
actionID: 900",
orderNumber: 1,
phone: element.getAttribute('data-phone'),
isVideoCall: element.getAttribute('data-video-call') === 'true',
isCallOut: element.getAttribute('data-call-out') === 'true',
Expand All @@ -183,7 +188,8 @@ function callCloudPhone(element) {

function openForm(element) {
const actionData = {
actionID: "9006",
actionID: 9006,
orderNumber: 1,
familyID: element.getAttribute('data-family-id'),
dismissParent: element.getAttribute('data-dismiss-parent') === 'true',
dependencies: JSON.parse(element.getAttribute('data-dependencies')),
Expand All @@ -198,7 +204,8 @@ function openForm(element) {

function openReport(element) {
const actionData = {
actionID: "9007",
actionID: 9007,
orderNumber: 1,
reportID: element.getAttribute('data-report-id'),
type: 'act_report'
};
Expand All @@ -208,7 +215,8 @@ function openReport(element) {

function openDMView(element) {
const actionData = {
actionID: "9008",
actionID: 9008,
orderNumber: 1,
subModule: element.getAttribute('data-sub-module'),
component: element.getAttribute('data-component'),
object: element.getAttribute('data-object'),
Expand All @@ -227,7 +235,8 @@ function openDMView(element) {

function getInstance(element) {
const actionData = {
actionID: "9009",
actionID: 9009,
orderNumber: 1,
familyName: element.getAttribute('data-family-name'),
display: element.getAttribute('data-display'),
uuid: element.getAttribute('data-uuid'),
Expand All @@ -243,7 +252,8 @@ function getInstance(element) {

function openModule(element) {
const actionData = {
actionID: "9010",
actionID: 9010,
orderNumber: 1,
destinationCode: element.getAttribute('data-destination-code'),
destinationType: element.getAttribute('data-destination-type'),
args: JSON.parse(element.getAttribute('data-args') || '{}'),
Expand All @@ -256,7 +266,8 @@ function openModule(element) {

function openChat(element) {
const actionData = {
actionID: "9011",
actionID: 9011,
orderNumber: 1,
room_target: element.getAttribute('data-room-target'),
room_title: element.getAttribute('data-room-title'),
type: 'act_open_chat'
Expand Down

0 comments on commit b3a9c49

Please sign in to comment.