Commit 5a874c68 authored by Ana's avatar Ana

pruebas sms

parent 086859c1
{ {
"_readme": [ "_readme": [
"This file locks the dependencies of your project to a known state", "This file locks the dependencies of your project to a known state",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"hash": "b26c9fba642159f0b485ea86df8eee11", "content-hash": "abfd299c609fbc49d92de0871d755065",
"content-hash": "c25647f7ebf2b32f7b9a383d7d4dc0a0",
"packages": [ "packages": [
{
"name": "bulkgate/message",
"version": "2.0.2",
"source": {
"type": "git",
"url": "https://github.com/BulkGate/message.git",
"reference": "f1b69295450ee9c6516ec874424139253743c032"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/BulkGate/message/zipball/f1b69295450ee9c6516ec874424139253743c032",
"reference": "f1b69295450ee9c6516ec874424139253743c032",
"shasum": ""
},
"require": {
"bulkgate/utils": "^2.0",
"php": ">=7.1.0"
},
"require-dev": {
"nette/tester": "~2.0",
"tracy/tracy": "~2.4"
},
"type": "library",
"autoload": {
"classmap": [
"src/"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-3-Clause"
],
"authors": [
{
"name": "TOPefekt s.r.o.",
"homepage": "http://www.topefekt.com"
},
{
"name": "Lukáš Piják",
"homepage": "http://www.lukaspijak.com"
}
],
"description": "PHP SDK for access to BulkGate portal API",
"homepage": "https://www.bulkgate.com",
"keywords": [
"bulkgate",
"io",
"nette",
"sms"
],
"time": "2018-09-10T11:25:38+00:00"
},
{
"name": "bulkgate/sms",
"version": "2.0.4",
"source": {
"type": "git",
"url": "https://github.com/BulkGate/sms.git",
"reference": "59e5232cdb63dccb20ca9b12ebf785bf54e395d1"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/BulkGate/sms/zipball/59e5232cdb63dccb20ca9b12ebf785bf54e395d1",
"reference": "59e5232cdb63dccb20ca9b12ebf785bf54e395d1",
"shasum": ""
},
"require": {
"bulkgate/message": ">=2.0.2 <3.0.0",
"bulkgate/utils": "^2.0",
"php": ">=7.1.0"
},
"require-dev": {
"nette/tester": "~2.0",
"tracy/tracy": "^2.4"
},
"type": "library",
"autoload": {
"classmap": [
"src/"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-3-Clause"
],
"authors": [
{
"name": "TOPefekt s.r.o.",
"homepage": "http://www.topefekt.com"
},
{
"name": "Lukáš Piják",
"homepage": "http://www.lukaspijak.com"
}
],
"description": "Simple PHP SDK for sending SMS via BulkGate portal. For credentials contact us.",
"homepage": "https://www.bulkgate.com",
"keywords": [
"bulkgate",
"nette",
"sms"
],
"time": "2019-03-26T11:52:15+00:00"
},
{
"name": "bulkgate/utils",
"version": "2.0.1",
"source": {
"type": "git",
"url": "https://github.com/BulkGate/utils.git",
"reference": "6d39b25c24e8f1001bd420fc2239b9afabb9c5d9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/BulkGate/utils/zipball/6d39b25c24e8f1001bd420fc2239b9afabb9c5d9",
"reference": "6d39b25c24e8f1001bd420fc2239b9afabb9c5d9",
"shasum": ""
},
"require": {
"php": ">=7.1.0"
},
"require-dev": {
"nette/tester": "~2.0"
},
"type": "library",
"autoload": {
"classmap": [
"src/"
]
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-3-Clause"
],
"authors": [
{
"name": "TOPefekt s.r.o.",
"homepage": "http://www.topefekt.com"
},
{
"name": "Lukáš Piják",
"homepage": "http://www.lukaspijak.com"
}
],
"description": "Generic utilites for BulkGate portal PHP SDK",
"homepage": "https://www.bulkgate.com",
"keywords": [
"bulkgate",
"compress",
"iterator",
"json",
"sms",
"strict"
],
"time": "2018-03-23T11:53:39+00:00"
},
{ {
"name": "doctrine/annotations", "name": "doctrine/annotations",
"version": "v1.2.7", "version": "v1.2.7",
...@@ -73,7 +228,7 @@ ...@@ -73,7 +228,7 @@
"docblock", "docblock",
"parser" "parser"
], ],
"time": "2015-08-31 12:32:49" "time": "2015-08-31T12:32:49+00:00"
}, },
{ {
"name": "doctrine/cache", "name": "doctrine/cache",
...@@ -143,7 +298,7 @@ ...@@ -143,7 +298,7 @@
"cache", "cache",
"caching" "caching"
], ],
"time": "2015-12-19 05:03:47" "time": "2015-12-19T05:03:47+00:00"
}, },
{ {
"name": "doctrine/collections", "name": "doctrine/collections",
...@@ -209,7 +364,7 @@ ...@@ -209,7 +364,7 @@
"collections", "collections",
"iterator" "iterator"
], ],
"time": "2015-04-14 22:21:58" "time": "2015-04-14T22:21:58+00:00"
}, },
{ {
"name": "doctrine/common", "name": "doctrine/common",
...@@ -282,7 +437,7 @@ ...@@ -282,7 +437,7 @@
"persistence", "persistence",
"spl" "spl"
], ],
"time": "2015-12-25 13:10:16" "time": "2015-12-25T13:10:16+00:00"
}, },
{ {
"name": "doctrine/dbal", "name": "doctrine/dbal",
...@@ -353,7 +508,7 @@ ...@@ -353,7 +508,7 @@
"persistence", "persistence",
"queryobject" "queryobject"
], ],
"time": "2016-09-09 19:13:33" "time": "2016-09-09T19:13:33+00:00"
}, },
{ {
"name": "doctrine/doctrine-bundle", "name": "doctrine/doctrine-bundle",
...@@ -434,7 +589,7 @@ ...@@ -434,7 +589,7 @@
"orm", "orm",
"persistence" "persistence"
], ],
"time": "2016-08-10 15:35:22" "time": "2016-08-10T15:35:22+00:00"
}, },
{ {
"name": "doctrine/doctrine-cache-bundle", "name": "doctrine/doctrine-cache-bundle",
...@@ -522,7 +677,7 @@ ...@@ -522,7 +677,7 @@
"cache", "cache",
"caching" "caching"
], ],
"time": "2016-01-26 17:28:51" "time": "2016-01-26T17:28:51+00:00"
}, },
{ {
"name": "doctrine/inflector", "name": "doctrine/inflector",
...@@ -589,7 +744,7 @@ ...@@ -589,7 +744,7 @@
"singularize", "singularize",
"string" "string"
], ],
"time": "2015-11-06 14:35:42" "time": "2015-11-06T14:35:42+00:00"
}, },
{ {
"name": "doctrine/instantiator", "name": "doctrine/instantiator",
...@@ -643,7 +798,7 @@ ...@@ -643,7 +798,7 @@
"constructor", "constructor",
"instantiate" "instantiate"
], ],
"time": "2015-06-14 21:17:01" "time": "2015-06-14T21:17:01+00:00"
}, },
{ {
"name": "doctrine/lexer", "name": "doctrine/lexer",
...@@ -697,19 +852,19 @@ ...@@ -697,19 +852,19 @@
"lexer", "lexer",
"parser" "parser"
], ],
"time": "2014-09-09 13:34:57" "time": "2014-09-09T13:34:57+00:00"
}, },
{ {
"name": "doctrine/orm", "name": "doctrine/orm",
"version": "v2.4.8", "version": "v2.4.8",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/doctrine/doctrine2.git", "url": "https://github.com/doctrine/orm.git",
"reference": "5aedac1e5c5caaeac14798822c70325dc242d467" "reference": "5aedac1e5c5caaeac14798822c70325dc242d467"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/doctrine/doctrine2/zipball/5aedac1e5c5caaeac14798822c70325dc242d467", "url": "https://api.github.com/repos/doctrine/orm/zipball/5aedac1e5c5caaeac14798822c70325dc242d467",
"reference": "5aedac1e5c5caaeac14798822c70325dc242d467", "reference": "5aedac1e5c5caaeac14798822c70325dc242d467",
"shasum": "" "shasum": ""
}, },
...@@ -770,7 +925,7 @@ ...@@ -770,7 +925,7 @@
"database", "database",
"orm" "orm"
], ],
"time": "2015-08-31 13:19:01" "time": "2015-08-31T13:19:01+00:00"
}, },
{ {
"name": "friendsofsymfony/rest-bundle", "name": "friendsofsymfony/rest-bundle",
...@@ -867,7 +1022,7 @@ ...@@ -867,7 +1022,7 @@
"keywords": [ "keywords": [
"rest" "rest"
], ],
"time": "2016-11-23 12:09:05" "time": "2016-11-23T12:09:05+00:00"
}, },
{ {
"name": "incenteev/composer-parameter-handler", "name": "incenteev/composer-parameter-handler",
...@@ -918,7 +1073,7 @@ ...@@ -918,7 +1073,7 @@
"keywords": [ "keywords": [
"parameters management" "parameters management"
], ],
"time": "2015-11-10 17:04:01" "time": "2015-11-10T17:04:01+00:00"
}, },
{ {
"name": "ircmaxell/password-compat", "name": "ircmaxell/password-compat",
...@@ -960,7 +1115,7 @@ ...@@ -960,7 +1115,7 @@
"hashing", "hashing",
"password" "password"
], ],
"time": "2014-11-20 16:49:30" "time": "2014-11-20T16:49:30+00:00"
}, },
{ {
"name": "jdorn/sql-formatter", "name": "jdorn/sql-formatter",
...@@ -1010,7 +1165,7 @@ ...@@ -1010,7 +1165,7 @@
"highlight", "highlight",
"sql" "sql"
], ],
"time": "2014-01-12 16:20:24" "time": "2014-01-12T16:20:24+00:00"
}, },
{ {
"name": "jms/metadata", "name": "jms/metadata",
...@@ -1061,7 +1216,7 @@ ...@@ -1061,7 +1216,7 @@
"xml", "xml",
"yaml" "yaml"
], ],
"time": "2016-12-05 10:18:33" "time": "2016-12-05T10:18:33+00:00"
}, },
{ {
"name": "jms/parser-lib", "name": "jms/parser-lib",
...@@ -1096,7 +1251,7 @@ ...@@ -1096,7 +1251,7 @@
"Apache2" "Apache2"
], ],
"description": "A library for easily creating recursive-descent parsers.", "description": "A library for easily creating recursive-descent parsers.",
"time": "2012-11-18 18:08:43" "time": "2012-11-18T18:08:43+00:00"
}, },
{ {
"name": "jms/serializer", "name": "jms/serializer",
...@@ -1171,7 +1326,7 @@ ...@@ -1171,7 +1326,7 @@
"serialization", "serialization",
"xml" "xml"
], ],
"time": "2016-11-13 10:20:11" "time": "2016-11-13T10:20:11+00:00"
}, },
{ {
"name": "jms/serializer-bundle", "name": "jms/serializer-bundle",
...@@ -1241,7 +1396,7 @@ ...@@ -1241,7 +1396,7 @@
"serialization", "serialization",
"xml" "xml"
], ],
"time": "2015-11-10 12:26:42" "time": "2015-11-10T12:26:42+00:00"
}, },
{ {
"name": "michelf/php-markdown", "name": "michelf/php-markdown",
...@@ -1292,7 +1447,7 @@ ...@@ -1292,7 +1447,7 @@
"keywords": [ "keywords": [
"markdown" "markdown"
], ],
"time": "2016-10-29 18:58:20" "time": "2016-10-29T18:58:20+00:00"
}, },
{ {
"name": "mobiledetect/mobiledetectlib", "name": "mobiledetect/mobiledetectlib",
...@@ -1346,7 +1501,7 @@ ...@@ -1346,7 +1501,7 @@
"mobile detector", "mobile detector",
"php mobile detect" "php mobile detect"
], ],
"time": "2016-11-11 14:56:25" "time": "2016-11-11T14:56:25+00:00"
}, },
{ {
"name": "monolog/monolog", "name": "monolog/monolog",
...@@ -1424,7 +1579,7 @@ ...@@ -1424,7 +1579,7 @@
"logging", "logging",
"psr-3" "psr-3"
], ],
"time": "2016-07-29 03:23:52" "time": "2016-07-29T03:23:52+00:00"
}, },
{ {
"name": "nelmio/api-doc-bundle", "name": "nelmio/api-doc-bundle",
...@@ -1509,7 +1664,7 @@ ...@@ -1509,7 +1664,7 @@
"documentation", "documentation",
"rest" "rest"
], ],
"time": "2016-06-13 09:12:09" "time": "2016-06-13T09:12:09+00:00"
}, },
{ {
"name": "paragonie/random_compat", "name": "paragonie/random_compat",
...@@ -1557,7 +1712,7 @@ ...@@ -1557,7 +1712,7 @@
"pseudorandom", "pseudorandom",
"random" "random"
], ],
"time": "2016-04-03 06:00:07" "time": "2016-04-03T06:00:07+00:00"
}, },
{ {
"name": "phing/phing", "name": "phing/phing",
...@@ -1650,7 +1805,7 @@ ...@@ -1650,7 +1805,7 @@
"task", "task",
"tool" "tool"
], ],
"time": "2016-10-13 09:01:45" "time": "2016-10-13T09:01:45+00:00"
}, },
{ {
"name": "phpcollection/phpcollection", "name": "phpcollection/phpcollection",
...@@ -1698,7 +1853,7 @@ ...@@ -1698,7 +1853,7 @@
"sequence", "sequence",
"set" "set"
], ],
"time": "2015-05-17 12:39:23" "time": "2015-05-17T12:39:23+00:00"
}, },
{ {
"name": "phpoption/phpoption", "name": "phpoption/phpoption",
...@@ -1748,7 +1903,7 @@ ...@@ -1748,7 +1903,7 @@
"php", "php",
"type" "type"
], ],
"time": "2015-07-25 16:39:46" "time": "2015-07-25T16:39:46+00:00"
}, },
{ {
"name": "propel/propel-bundle", "name": "propel/propel-bundle",
...@@ -1811,7 +1966,7 @@ ...@@ -1811,7 +1966,7 @@
"persistence", "persistence",
"propel" "propel"
], ],
"time": "2016-02-15 21:33:58" "time": "2016-02-15T21:33:58+00:00"
}, },
{ {
"name": "propel/propel1", "name": "propel/propel1",
...@@ -1874,7 +2029,7 @@ ...@@ -1874,7 +2029,7 @@
"orm", "orm",
"persistence" "persistence"
], ],
"time": "2014-02-25 09:13:58" "time": "2014-02-25T09:13:58+00:00"
}, },
{ {
"name": "psr/log", "name": "psr/log",
...@@ -1921,7 +2076,7 @@ ...@@ -1921,7 +2076,7 @@
"psr", "psr",
"psr-3" "psr-3"
], ],
"time": "2016-09-19 16:02:08" "time": "2016-09-19T16:02:08+00:00"
}, },
{ {
"name": "sensio/distribution-bundle", "name": "sensio/distribution-bundle",
...@@ -1973,7 +2128,7 @@ ...@@ -1973,7 +2128,7 @@
"configuration", "configuration",
"distribution" "distribution"
], ],
"time": "2016-09-14 20:25:12" "time": "2016-09-14T20:25:12+00:00"
}, },
{ {
"name": "sensio/framework-extra-bundle", "name": "sensio/framework-extra-bundle",
...@@ -2035,7 +2190,7 @@ ...@@ -2035,7 +2190,7 @@
"annotations", "annotations",
"controllers" "controllers"
], ],
"time": "2016-03-25 17:08:27" "time": "2016-03-25T17:08:27+00:00"
}, },
{ {
"name": "sensiolabs/security-checker", "name": "sensiolabs/security-checker",
...@@ -2079,7 +2234,7 @@ ...@@ -2079,7 +2234,7 @@
} }
], ],
"description": "A security checker for your composer.lock", "description": "A security checker for your composer.lock",
"time": "2015-11-07 08:07:40" "time": "2015-11-07T08:07:40+00:00"
}, },
{ {
"name": "suncat/mobile-detect-bundle", "name": "suncat/mobile-detect-bundle",
...@@ -2140,7 +2295,7 @@ ...@@ -2140,7 +2295,7 @@
"mobile view managing", "mobile view managing",
"symfony mobile" "symfony mobile"
], ],
"time": "2016-03-24 13:25:38" "time": "2016-03-24T13:25:38+00:00"
}, },
{ {
"name": "swiftmailer/swiftmailer", "name": "swiftmailer/swiftmailer",
...@@ -2193,7 +2348,7 @@ ...@@ -2193,7 +2348,7 @@
"mail", "mail",
"mailer" "mailer"
], ],
"time": "2016-07-08 11:51:25" "time": "2016-07-08T11:51:25+00:00"
}, },
{ {
"name": "symfony/monolog-bundle", "name": "symfony/monolog-bundle",
...@@ -2253,7 +2408,7 @@ ...@@ -2253,7 +2408,7 @@
"log", "log",
"logging" "logging"
], ],
"time": "2016-04-13 16:21:01" "time": "2016-04-13T16:21:01+00:00"
}, },
{ {
"name": "symfony/polyfill-apcu", "name": "symfony/polyfill-apcu",
...@@ -2306,7 +2461,7 @@ ...@@ -2306,7 +2461,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-intl-icu", "name": "symfony/polyfill-intl-icu",
...@@ -2364,7 +2519,7 @@ ...@@ -2364,7 +2519,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-mbstring", "name": "symfony/polyfill-mbstring",
...@@ -2423,7 +2578,7 @@ ...@@ -2423,7 +2578,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-php54", "name": "symfony/polyfill-php54",
...@@ -2481,7 +2636,7 @@ ...@@ -2481,7 +2636,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-php55", "name": "symfony/polyfill-php55",
...@@ -2537,7 +2692,7 @@ ...@@ -2537,7 +2692,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-php56", "name": "symfony/polyfill-php56",
...@@ -2593,7 +2748,7 @@ ...@@ -2593,7 +2748,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-php70", "name": "symfony/polyfill-php70",
...@@ -2652,7 +2807,7 @@ ...@@ -2652,7 +2807,7 @@
"portable", "portable",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/polyfill-util", "name": "symfony/polyfill-util",
...@@ -2704,7 +2859,7 @@ ...@@ -2704,7 +2859,7 @@
"polyfill", "polyfill",
"shim" "shim"
], ],
"time": "2016-05-18 14:26:46" "time": "2016-05-18T14:26:46+00:00"
}, },
{ {
"name": "symfony/security-acl", "name": "symfony/security-acl",
...@@ -2765,7 +2920,7 @@ ...@@ -2765,7 +2920,7 @@
], ],
"description": "Symfony Security Component - ACL (Access Control List)", "description": "Symfony Security Component - ACL (Access Control List)",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2015-12-28 09:39:09" "time": "2015-12-28T09:39:09+00:00"
}, },
{ {
"name": "symfony/swiftmailer-bundle", "name": "symfony/swiftmailer-bundle",
...@@ -2822,7 +2977,7 @@ ...@@ -2822,7 +2977,7 @@
], ],
"description": "Symfony SwiftmailerBundle", "description": "Symfony SwiftmailerBundle",
"homepage": "http://symfony.com", "homepage": "http://symfony.com",
"time": "2016-01-15 16:41:20" "time": "2016-01-15T16:41:20+00:00"
}, },
{ {
"name": "symfony/symfony", "name": "symfony/symfony",
...@@ -2957,7 +3112,7 @@ ...@@ -2957,7 +3112,7 @@
"keywords": [ "keywords": [
"framework" "framework"
], ],
"time": "2016-10-03 18:44:12" "time": "2016-10-03T18:44:12+00:00"
}, },
{ {
"name": "twig/twig", "name": "twig/twig",
...@@ -3018,7 +3173,7 @@ ...@@ -3018,7 +3173,7 @@
"keywords": [ "keywords": [
"templating" "templating"
], ],
"time": "2016-10-25 19:17:17" "time": "2016-10-25T19:17:17+00:00"
}, },
{ {
"name": "willdurand/jsonp-callback-validator", "name": "willdurand/jsonp-callback-validator",
...@@ -3058,7 +3213,7 @@ ...@@ -3058,7 +3213,7 @@
} }
], ],
"description": "JSONP callback validator.", "description": "JSONP callback validator.",
"time": "2014-01-20 22:35:06" "time": "2014-01-20T22:35:06+00:00"
}, },
{ {
"name": "willdurand/negotiation", "name": "willdurand/negotiation",
...@@ -3110,7 +3265,7 @@ ...@@ -3110,7 +3265,7 @@
"header", "header",
"negotiation" "negotiation"
], ],
"time": "2016-10-14 09:17:47" "time": "2016-10-14T09:17:47+00:00"
} }
], ],
"packages-dev": [ "packages-dev": [
...@@ -3164,7 +3319,7 @@ ...@@ -3164,7 +3319,7 @@
} }
], ],
"description": "This bundle generates code for you", "description": "This bundle generates code for you",
"time": "2016-09-06 01:30:19" "time": "2016-09-06T01:30:19+00:00"
}, },
{ {
"name": "symfony/phpunit-bridge", "name": "symfony/phpunit-bridge",
...@@ -3219,7 +3374,7 @@ ...@@ -3219,7 +3374,7 @@
], ],
"description": "Symfony PHPUnit Bridge", "description": "Symfony PHPUnit Bridge",
"homepage": "https://symfony.com", "homepage": "https://symfony.com",
"time": "2016-08-19 06:48:01" "time": "2016-08-19T06:48:01+00:00"
} }
], ],
"aliases": [], "aliases": [],
......
...@@ -5,6 +5,9 @@ use AppBundle\Model\om\BaseSms; ...@@ -5,6 +5,9 @@ use AppBundle\Model\om\BaseSms;
use Monolog\Logger; use Monolog\Logger;
use Symfony\Component\DependencyInjection\Container; use Symfony\Component\DependencyInjection\Container;
use AppBundle\Lib\Utiles; use AppBundle\Lib\Utiles;
use BulkGate\Sms\Sender;
use BulkGate\Message\Connection;
use BulkGate\Sms\Message;
class Sms extends BaseSms class Sms extends BaseSms
{ {
...@@ -50,20 +53,43 @@ class Sms extends BaseSms ...@@ -50,20 +53,43 @@ class Sms extends BaseSms
$sms->save(); $sms->save();
//$urlDescarga = Sms::acortarUrl($url); $urlDescarga = Sms::acortarUrl($url);
$urlDescarga = $url; //$urlDescarga = $url;
//$mensaje=$mensaje . $urlDescarga;
//$mensaje=$mensaje . 'http://cort.as/-Jvtw';
$mensaje=$mensaje . $urlDescarga; $mensaje=$mensaje . $urlDescarga;
$post['to'] = array($movil); // $post['to'] = array($movil);
$mensaje=$mensaje . $urlDescarga; // $mensaje=$mensaje . $urlDescarga;
$post['to'] = array('584165388803');
$post['text'] = $mensaje;
$post['from'] = "McAfee";
$user ="gearlabs";
$password = 'G1e2a3r4';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,
"https://gateway.plusmms.net/rest/message");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($post));
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
"Accept: application/json",
"Authorization: Basic ".base64_encode($user.":".$password)
));
$result = curl_exec ($ch);
print_r($result);
$post['to'] = array($movil); /* $post['to'] = array($movil);
$post['text'] = $mensaje; $post['text'] = $mensaje;
$post['from'] = Utiles::getParametroConfiguracion("from_sms"); $post['from'] = Utiles::getParametroConfiguracion("from_sms");
$user =Utiles::getParametroConfiguracion("usuario_sms"); $user =Utiles::getParametroConfiguracion("usuario_sms");
...@@ -88,14 +114,22 @@ class Sms extends BaseSms ...@@ -88,14 +114,22 @@ class Sms extends BaseSms
$info = curl_getinfo($ch); $info = curl_getinfo($ch);
print_r($info['request_header']); print_r($info['request_header']);
print_r($result); print_r($result);*/
//print_r($result['error']['code']); //print_r($result['error']['code']);
$log->debug($tag.'enviando mensaje...'. $urlDescarga); $log->debug($tag.'enviando mensaje...'. $urlDescarga);
/***************************************/ /***************************************/
/* $request = '{
/*$connection = new Connection('4535', 'ElsgoG5xHwoAi4vevzBRIXZduAiMySMXgb9FAuVi3pEdgU8GnW');
$sender = new Sender($connection);
$message = new Message('584128000742', $mensaje);
$response = $sender->send($message);
print_r($response);
*/
/*$request = '{
"api_key":"9df2cfda7cc871680ede6ec24b4a479d", "api_key":"9df2cfda7cc871680ede6ec24b4a479d",
"report_url":"http://servidoctor.com/callback/script", "report_url":"http://servidoctor.com/callback/script",
"concat":1, "concat":1,
...@@ -124,7 +158,7 @@ class Sms extends BaseSms ...@@ -124,7 +158,7 @@ class Sms extends BaseSms
if (curl_errno($ch) != 0 ){ if (curl_errno($ch) != 0 ){
die("curl error: ".curl_errno($ch)); die("curl error: ".curl_errno($ch));
} */ }*/
/***************************************/ /***************************************/
if($result['error']['code']==0){ if($result['error']['code']==0){
...@@ -159,13 +193,13 @@ class Sms extends BaseSms ...@@ -159,13 +193,13 @@ class Sms extends BaseSms
} }
/* public static function acortar_url($url) { /* public static function acortar_url($url) {
$usuario = "gearlabs"; $usuario = "gearlabs";
$apikey = "R_8bf0031b8f644fec93997b7b23568b76"; $apikey = "R_8bf0031b8f644fec93997b7b23568b76";
$temp = "http://api.bit.ly/v3/shorten?login=".$usuario."&apiKey=".$apikey."&uri=".$url."&format=txt"; $temp = "http://api.bit.ly/v3/shorten?login=".$usuario."&apiKey=".$apikey."&uri=".$url."&format=txt";
return file_get_contents($temp); return file_get_contents($temp);
}*/ }
*/
public static function acortarUrl($data){ public static function acortarUrl($data){
$url = "http://url.gearlabs.cl/acortar"; $url = "http://url.gearlabs.cl/acortar";
......
...@@ -36,8 +36,8 @@ class McafeeEnviarSmsCommand extends ContainerAwareCommand ...@@ -36,8 +36,8 @@ class McafeeEnviarSmsCommand extends ContainerAwareCommand
$log->debug('************************Iniciando McafeeEnviarSmsCommand ************************'); $log->debug('************************Iniciando McafeeEnviarSmsCommand ************************');
$tt = new TiempoTranscurrido(); $tt = new TiempoTranscurrido();
$fp = fopen("/opt/sdp/intelsecuritymovistar/etc/sms/3_36460.csv", "r"); //$fp = fopen("/opt/sdp/intelsecuritymovistar/etc/sms/3_36460.csv", "r");
//$fp = fopen("C:\ana3\movistarChile\prueba.csv", "r"); $fp = fopen("C:\ana3\movistarChile\prueba.csv", "r");
if (!$fp) { if (!$fp) {
$log->warning('Error al intentar abrir el archivo'); $log->warning('Error al intentar abrir el archivo');
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment