Exemplo n.º 1
0
 public function run()
 {
     AttachmentMime::insert([['resource_id_019' => 'spas-spa', 'mime_019' => 'image/jpeg'], ['resource_id_019' => 'spas-spa', 'mime_019' => 'image/png']]);
 }
Exemplo n.º 2
0
 public function updateCustomRecord($parameters)
 {
     AttachmentMime::where('id_019', $parameters['id'])->update(['resource_id_019' => $this->request->input('resource'), 'mime_019' => $this->request->input('mime')]);
 }
Exemplo n.º 3
0
 public function run()
 {
     AttachmentMime::insert([['resource_id_019' => 'crm-customer', 'mime_019' => 'image/jpeg'], ['resource_id_019' => 'crm-customer', 'mime_019' => 'image/png'], ['resource_id_019' => 'crm-customer', 'mime_019' => 'text/plain'], ['resource_id_019' => 'crm-customer', 'mime_019' => 'application/pdf'], ['resource_id_019' => 'crm-customer', 'mime_019' => 'application/msword'], ['resource_id_019' => 'crm-customer', 'mime_019' => 'application/msexcel'], ['resource_id_019' => 'crm-customer', 'mime_019' => 'application/zip']]);
 }
Exemplo n.º 4
0
 /**
  * get string with mimes to getfile plugin
  *
  * @param $resource
  * @return null|string
  */
 public static function getMimesAccept($resource)
 {
     $attachmentMimes = AttachmentMime::builder()->where('resource_id_019', $resource)->get();
     $index = 1;
     $mimes = null;
     foreach ($attachmentMimes as $attachmentMime) {
         $mimes .= "'" . $attachmentMime->mime_019 . "'";
         if ($index < count($attachmentMimes)) {
             $mimes .= ", ";
         }
         $index++;
     }
     return $mimes;
 }
Exemplo n.º 5
0
 public function run()
 {
     AttachmentMime::insert([['resource_id_019' => 'cms-article', 'mime_019' => 'image/jpeg'], ['resource_id_019' => 'cms-article', 'mime_019' => 'image/png'], ['resource_id_019' => 'cms-article', 'mime_019' => 'application/pdf']]);
 }
 public function run()
 {
     AttachmentMime::insert([['resource_id_019' => 'market-product', 'mime_019' => 'image/jpeg'], ['resource_id_019' => 'market-product', 'mime_019' => 'image/png']]);
 }