max_stars_repo_path
stringlengths
4
587
max_stars_repo_name
stringlengths
5
118
max_stars_count
int64
0
39.9k
id
stringlengths
1
8
content
stringlengths
1
1.05M
score
float64
-1.14
3.53
int_score
int64
0
4
src/Models/FlowInfo.php
antchain-openapi-sdk-php/propertychain
6
14399212
<?php // This file is auto-generated, don't edit it. Thanks. namespace AntChain\PROPERTYCHAIN\Models; use AlibabaCloud\Tea\Model; class FlowInfo extends Model { // 备注 /** * @example comment * * @var string */ public $comment; // 操作时间 /** * @example operateTime * * @var string */ public $operateTime; // 操作人 /** * @example operator * * @var string */ public $operator; // 操作状态【NONE,WAITING,AGREED,REJECTED,CANCELED,ALL】 /** * @example WAITING * * @var string */ public $status; protected $_name = [ 'comment' => 'comment', 'operateTime' => 'operate_time', 'operator' => 'operator', 'status' => 'status', ]; public function validate() { } public function toMap() { $res = []; if (null !== $this->comment) { $res['comment'] = $this->comment; } if (null !== $this->operateTime) { $res['operate_time'] = $this->operateTime; } if (null !== $this->operator) { $res['operator'] = $this->operator; } if (null !== $this->status) { $res['status'] = $this->status; } return $res; } /** * @param array $map * * @return FlowInfo */ public static function fromMap($map = []) { $model = new self(); if (isset($map['comment'])) { $model->comment = $map['comment']; } if (isset($map['operate_time'])) { $model->operateTime = $map['operate_time']; } if (isset($map['operator'])) { $model->operator = $map['operator']; } if (isset($map['status'])) { $model->status = $map['status']; } return $model; } }
1.34375
1
app/Http/Controllers/ReunionController.php
F0085/TaskAPI
1
14399220
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\ReunionModel; use App\Reunio_Responsable_Model; use App\Reunio_Participante_Model; class ReunionController extends Controller { /** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function __construct(ReunionModel $Reunion) { $this->Reunion=$Reunion; } public function index() { $respon = ReunionModel::with('Usuario','Responsables','Participantes')->get(); return $respon; } //TRAER REUNIONES POR ESTADO PENDIENTE Y POR EL USUARIO QUE LAS CREAR public function ReunionPorEstado_User($estado ,$idUsuario) { $respon = ReunionModel::with('Usuario','Responsables','Participantes')->where('Estado','=',$estado)->where('Id_Usuario','=',$idUsuario)->get(); return $respon; } //TRAER REUNIONES POR RESPONSABLES public function MisReunionesResponsables($idUsuario) { $res=Reunio_Responsable_Model::with('Reunion','Usuario')->where('Id_Usuario','=',$idUsuario)->get(); return $res; } //TRAER REUNIONES POR PARTICIPANTES public function MisReunionesParticipantes($idUsuario) { $res=Reunio_Participante_Model::with('Reunion','Usuario')->where('Id_Usuario','=',$idUsuario)->get(); return $res; } //TRAER REUNIONES PARA EL ADMINISTRADOR public function ReunionAdmin($estado){ $respon = ReunionModel::with('Usuario','Responsables','Participantes')->where('Estado','=',$estado)->get(); return $respon; } /** * Show the form for creating a new resource. * * @return \Illuminate\Http\Response */ public function create() { // } /** * Store a newly created resource in storage. * * @param \Illuminate\Http\Request $request * @return \Illuminate\Http\Response */ public function store(Request $request) { $input = $request->all(); return $this->Reunion->create($input); } /** * Display the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function show($id) { $respon = ReunionModel::with('Usuario','Responsables','Participantes')->where('Id_Reunion','=',$id)->get(); return $respon; } /** * Show the form for editing the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function edit($id) { // } /** * Update the specified resource in storage. * * @param \Illuminate\Http\Request $request * @param int $id * @return \Illuminate\Http\Response */ public function update(Request $request, $id) { $input = $request->all(); $this->Reunion->where('Id_Reunion', $id)->update($input); return $this->Reunion ->find($id); } public function ReporteReunionshow($id) { $respon = ReunionModel::with('Usuario','Responsables','Participantes','Observacion')->where('Id_Reunion','=',$id)->get(); return $respon; } /** * Remove the specified resource from storage. * * @param int $id * @return \Illuminate\Http\Response */ public function destroy($id) { } }
1.273438
1
application/index/controller/Search.php
kk-stars/KK-BLOG
1
14399228
<?php namespace app\index\controller; use think\Controller; class Search extends Comm { public function search(){ $text = input('k'); $text = strip_tags($text);//清除变量里的HTML和PHP标签 $text = '%' . $text . '%'; $result = db('article') -> alias('a') -> join('cate c','a.articleCate = c.cateId') -> where([ 'a.articleTitle|a.articleTags|a.articleKeywords|a.articleDescription' => ['like',$text], 'a.status' => 1 ]) -> paginate('13'); if($result){ $this -> assign('art',$result); } return view(); } } ?>
0.964844
1
tests/Feature/ExampleTest.php
wilcarjose/werp
0
14399236
<?php namespace Tests\Feature; use Tests\TestCase; use Werp\User; use Werp\Modules\Core\Products\Models\Category; use Illuminate\Foundation\Testing\RefreshDatabase; use Illuminate\Foundation\Testing\WithoutMiddleware; class ExampleTest extends TestCase { use WithoutMiddleware; use RefreshDatabase; public function setUp() { parent::setUp(); shell_exec('php artisan migrate:fresh --seed --database=mysql_tests'); $this->user = factory(User::class)->create(); $this->actingAs($this->user); } /** * A basic test example. * * @return void */ public function testBasicTest() { $response = $this->get('/'); $response->assertStatus(200); } /** * A basic test example. * * @return void */ public function testAdminPage() { $response = $this->get('/admin/home'); $response->assertStatus(200); } /** * A basic test example. * * @return void */ public function testCategoriesListPage() { $response = $this->get('/admin/products/categories'); $response->assertStatus(200); } /** * A basic test example. * * @return void */ public function testCategoriesNewPage() { $response = $this->get('/admin/products/categories/create'); $response->assertStatus(200); } /** * A basic test example. * * @return void */ public function testCategoriesEditPage() { $category = factory(Category::class)->create(); $response = $this->get('/admin/products/categories/'.$category->id.'/edit'); $response->assertStatus(200); } }
1.429688
1
views/administrator.php
BiGDoGKD/singhacabsSystem
0
14399244
<?php error_reporting(E_ALL & ~E_NOTICE); session_start(); if (!isset($_SESSION["A"])) { header("Location: ../error.html"); exit; } $uname = $_SESSION["A"]; ?> <?php $temp = 0; if ($temp != 2) { include("./dbconnection/usercon.php"); require_once("./dbconnection/dbcon.php"); } define('adminaccess', true); ?> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Administrator</title> <link rel="stylesheet" href="userstyles.css" /> <link rel="stylesheet" href="tablestyles.css" /> </head> <body> <style> body { font-family: "Lato", sans-serif; transition: background-color .5s; } .sidenav { height: 100%; width: 0; position: fixed; z-index: 2; top: 0; left: 0; background-color: #111; overflow-x: hidden; transition: 0.5s; padding-top: 60px; text-align: center; } .sidenav a { padding: 8px 8px 8px 8px; text-decoration: none; font-size: 25px; color: #818181; display: block; transition: 0.3s; } .sidenav a:hover { color: #f1f1f1; } .sidenav .closebtn { position: absolute; top: 0; right: 25px; font-size: 36px; margin-left: 50px; } .profile-card { border: solid 1px #818181; border-radius: 45px; width: 200px; height: 250px; margin: auto auto 50px auto; } .profile-card>img { width: 75px; margin: 20px 0 0 0; } .role { margin: 15px 0 15px 0; font-size: 1.3em; color: #818181; } .username { color: #818181; font-size: 1em; } .logout_s { margin: 15px 0 0 0; color: #fff; border: 0px solid; border-radius: 15px; padding: 8px 15px 8px 15px; background: #e7a300; cursor: pointer; } @media screen and (max-height: 450px) { .sidenav { padding-top: 15px; } .sidenav a { font-size: 18px; } } </style> <div class="container"> <div class="top-menu"> <div class="account" onclick="openNav()"> <img src="./img/profile.svg" style="height:50px;" alt=""> <span class="menu-title" style="font-size:1.5em;margin:10px 0 0 20px;color:#6f7274;"> Account</span> </div> </div> <div class="content"> <div class="side-menu"> <div id="mySidenav" class="sidenav"> <a href="javascript:void(0)" class="closebtn" onclick="closeNav()">&times;</a> <div class="profile-card"> <img src="./img/profile.svg" alt=""> <h2 class="role">Administrator</h2> <span class="username"><?php echo $_SESSION["A"]; ?></span><br /> <!-- <a href="#" style="font-size: 1em;"><span class="logout">Logout</span></a> --> <button class="logout_s" onclick="location.href='logout.php?logout'">Logout</button> </div> <a href="#" onclick="accountsView()">User Accounts</a> <a href="#" onclick="managersView()">Managers</a> <a href="#" onclick="createMView()">Create Manager</a> <a href="#" onclick="driversView()">Drivers</a> <a href="#" onclick="ridesView()">Rides</a> <a href="#" onclick="vehiclesView()">Vehicles</a> <a href="#" onclick="vehicletypesView()">Vehicle Types</a> <a href="#" onclick="settingsView()">Account Settings</a> </div> </div> <div id="accounts-view"> <?php include 'accounts.php' ?> </div> <div id="vehicles-view" style="display: none;"> <?php include 'vehicles.php' ?> </div> <div id="drivers-view" style="display: none;"> <?php include 'drivers.php' ?> </div> <div id="managers-view" style="display: none;"> <?php include 'managers.php' ?> </div> <style> #createM-view { display: flex; flex-direction: column; justify-content: center; } </style> <div id="createM-view" style="display: none;"> <?php include 'createmanager.php' ?> </div> <div id="vehicletypes-view" style="display: none;"> <?php include 'vehicletypes.php' ?> </div> <div id="rides-view" style="display: none;"> <?php include 'rides.php' ?> </div> <div id="settings-view" style="display: none;"> <?php include 'editcurrentuser.php' ?> </div> </div> <div class="footer1"> <div id="footer"> <?php include 'footer.php' ?> </div> </div> </div> <script> function openNav() { document.getElementById("mySidenav").style.width = "400px"; document.getElementById("main").style.marginLeft = "250px"; document.body.style.backgroundColor = "rgba(0,0,0,0.4)"; } function closeNav() { document.getElementById("mySidenav").style.width = "0"; document.getElementById("main").style.marginLeft = "0"; document.body.style.backgroundColor = "white"; } function vehiclesView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "block"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "none"; } function accountsView() { document.getElementById("accounts-view").style.display = "block"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "none"; } function driversView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "block"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "none"; } function managersView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "block"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "none"; } function vehicletypesView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "block"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "none"; } function ridesView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "block"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "none"; } function settingsView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "block"; document.getElementById("createM-view").style.display = "none"; } function createMView() { document.getElementById("accounts-view").style.display = "none"; document.getElementById("vehicles-view").style.display = "none"; document.getElementById("drivers-view").style.display = "none"; document.getElementById("managers-view").style.display = "none"; document.getElementById("vehicletypes-view").style.display = "none"; document.getElementById("rides-view").style.display = "none"; document.getElementById("settings-view").style.display = "none"; document.getElementById("createM-view").style.display = "block"; } </script> </body> </html>
0.832031
1
resources/views/user/pages/index.blade.php
Palash001/Air-Reservation
0
14399252
@extends('user.layouts.app') @section('title','Home page') @section('main-content') <div class="fh5co-hero"> <div class="fh5co-overlay"></div> <div class="fh5co-cover" data-stellar-background-ratio="0.5" style="background-image: url( {{ asset('user/images/cover_bg_1.jpg') }})"> <div class="desc"> <div class="container"> <div class="row"> <div class="col-md-12"> <div class="tabulation animate-box"> <!-- Nav tabs --> <!-- <ul class="nav nav-tabs" role="tablist"> <li role="presentation" class="active"> <a href="#flights" aria-controls="flights" role="tab" data-toggle="tab">Flights</a> </li> </ul> --> <div id="myCarousel" class="carousel slide" data-ride="carousel" data-interval="1300"> <!-- Indicators --> <ol class="carousel-indicators"> <li data-target="#myCarousel" data-slide-to="0" class="active"></li> <li data-target="#myCarousel" data-slide-to="1"></li> <li data-target="#myCarousel" data-slide-to="2"></li> </ol> <!-- Wrapper for slides --> <div class="carousel-inner"> <div class="item active"> <img src="{{asset('user/images/aln1.jpg')}}" alt="Los Angeles" style="width:100%;"> <div class="carousel-caption"> <h3>Lufthansa</h3> <p>LA is always so much fun!</p> </div> </div> <div class="item"> <img src="{{asset('user/images/aln2.jpg')}}" alt="Chicago" style="width:100%;"> <div class="carousel-caption"> <h3>Boeing</h3> <p>Thank you, Chicago!</p> </div> </div> <div class="item"> <img src="{{asset('user/images/aln3.jpg')}}" alt="New York" style="width:100%;"> <div class="carousel-caption"> <h3>Air Buss</h3> <p>We love Air Bus</p> </div> </div> </div> <!-- Left and right controls --> <a class="left carousel-control" href="#myCarousel" data-slide="prev"> <span class="glyphicon glyphicon-chevron-left"></span> <span class="sr-only">Previous</span> </a> <a class="right carousel-control" href="#myCarousel" data-slide="next"> <span class="glyphicon glyphicon-chevron-right"></span> <span class="sr-only">Next</span> </a> </div> <!-- Tab panes --> <!--Form Search herer--> </div> <!--end of table of animation class--> </div> </div> </div> </div> </div> </div> <div id="fh5co-tours" class="fh5co-section-gray"> <div class="container"> <div class="row"> <div class="col-md-8 col-md-offset-2 text-center heading-section animate-box"> <h3>Hot Tours</h3> <p>Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.</p> </div> </div> <div class="row"> <div class="col-md-4 col-sm-6 fh5co-tours animate-box" data-animate-effect="fadeIn"> <div href="#"><img src="{{asset('user/images/place-1.jpg')}}" alt="Free HTML5 Website Template by FreeHTML5.co" class="img-responsive"> <div class="desc"> <span></span> <h3>New York</h3> <span>3 nights + Flight 5*Hotel</span> <span class="price">$1,000</span> <a class="btn btn-primary btn-outline" href="#">Book Now <i class="icon-arrow-right22"></i></a> </div> </div> </div> <div class="col-md-4 col-sm-6 fh5co-tours animate-box" data-animate-effect="fadeIn"> <div href="#"><img src="{{asset('user/images/place-2.jpg')}}" alt="Free HTML5 Website Template by FreeHTML5.co" class="img-responsive"> <div class="desc"> <span></span> <h3>Philippines</h3> <span>4 nights + Flight 5*Hotel</span> <span class="price">$1,000</span> <a class="btn btn-primary btn-outline" href="#">Book Now <i class="icon-arrow-right22"></i></a> </div> </div> </div> <div class="col-md-4 col-sm-6 fh5co-tours animate-box" data-animate-effect="fadeIn"> <div href="#"><img src="{{asset('user/images/place-3.jpg')}}" alt="Free HTML5 Website Template by FreeHTML5.co" class="img-responsive"> <div class="desc"> <span></span> <h3>Hongkong</h3> <span>2 nights + Flight 4*Hotel</span> <span class="price">$1,000</span> <a class="btn btn-primary btn-outline" href="#">Book Now <i class="icon-arrow-right22"></i></a> </div> </div> </div> <div class="col-md-12 text-center animate-box"> <p><a class="btn btn-primary btn-outline btn-lg" href="#">See All Offers <i class="icon-arrow-right22"></i></a></p> </div> </div> </div> </div> <!---Parallax----> <div class="parallax"></div> <div id="fh5co-features"> <div class="container"> <div class="row"> <div class="col-md-4 animate-box"> <div class="feature-left"> <span class="icon"> <i class="icon-hotairballoon"></i> </span> <div class="feature-copy"> <h3>Family Travel</h3> <p>Facilis ipsum reprehenderit nemo molestias. Aut cum mollitia reprehenderit.</p> <p><a href="#">Learn More</a></p> </div> </div> </div> <div class="col-md-4 animate-box"> <div class="feature-left"> <span class="icon"> <i class="icon-search"></i> </span> <div class="feature-copy"> <h3>Travel Plans</h3> <p>Facilis ipsum reprehenderit nemo molestias. Aut cum mollitia reprehenderit.</p> <p><a href="#">Learn More</a></p> </div> </div> </div> <div class="col-md-4 animate-box"> <div class="feature-left"> <span class="icon"> <i class="icon-wallet"></i> </span> <div class="feature-copy"> <h3>Honeymoon</h3> <p>Facilis ipsum reprehenderit nemo molestias. Aut cum mollitia reprehenderit.</p> <p><a href="#">Learn More</a></p> </div> </div> </div> </div> <div class="row"> <div class="col-md-4 animate-box"> <div class="feature-left"> <span class="icon"> <i class="icon-wine"></i> </span> <div class="feature-copy"> <h3>Business Travel</h3> <p>Facilis ipsum reprehenderit nemo molestias. Aut cum mollitia reprehenderit.</p> <p><a href="#">Learn More</a></p> </div> </div> </div> <div class="col-md-4 animate-box"> <div class="feature-left"> <span class="icon"> <i class="icon-genius"></i> </span> <div class="feature-copy"> <h3>Solo Travel</h3> <p>Facilis ipsum reprehenderit nemo molestias. Aut cum mollitia reprehenderit.</p> <p><a href="#">Learn More</a></p> </div> </div> </div> <div class="col-md-4 animate-box"> <div class="feature-left"> <span class="icon"> <i class="icon-chat"></i> </span> <div class="feature-copy"> <h3>Explorer</h3> <p>Facilis ipsum reprehenderit nemo molestias. Aut cum mollitia reprehenderit.</p> <p><a href="#">Learn More</a></p> </div> </div> </div> </div> </div> </div> <!--end of parallax--> <div id="fh5co-destination"> <div class="tour-fluid"> <div class="row"> <div class="col-md-12"> <ul id="fh5co-destination-list" class="animate-box"> <li class="one-forth text-center" style="background-image: url({{ asset('user/images/place-1.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Los Angeles</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-2.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Hongkong</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/images/place-3.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Italy</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-4.jpg')}}) "> <a href="#"> <div class="case-studies-summary"> <h2>Philippines</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-5.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Japan</h2> </div> </a> </li> <li class="one-half text-center"> <div class="title-bg"> <div class="case-studies-summary"> <h2>Most Popular Destinations</h2> <span><a href="#">View All Destinations</a></span> </div> </div> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-6.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Paris</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-7.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Singapore</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-8.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Madagascar</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-9.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Egypt</h2> </div> </a> </li> <li class="one-forth text-center" style="background-image: url({{asset('user/images/place-10.jpg')}})"> <a href="#"> <div class="case-studies-summary"> <h2>Indonesia</h2> </div> </a> </li> </ul> </div> </div> </div> </div> <div id="fh5co-blog-section" class="fh5co-section-gray"> <div class="container"> <div class="row"> <div class="col-md-8 col-md-offset-2 text-center heading-section animate-box"> <h3>Recent From Blog</h3> <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Velit est facilis maiores, perspiciatis accusamus asperiores sint consequuntur debitis.</p> </div> </div> </div> <div class="container"> <div class="row row-bottom-padded-md"> <div class="col-lg-4 col-md-4 col-sm-6"> <div class="fh5co-blog animate-box"> <a href="#"><img class="img-responsive" src="{{asset('user/images/place-1.jpg')}}" alt=""></a> <div class="blog-text"> <div class="prod-title"> <h3><a href="#">30% Discount to Travel All Around the World</a></h3> <span class="posted_by">Sep. 15th</span> <span class="comment"><a href="">21<i class="icon-bubble2"></i></a></span> <p>Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.</p> <p><a href="#">Learn More...</a></p> </div> </div> </div> </div> <div class="col-lg-4 col-md-4 col-sm-6"> <div class="fh5co-blog animate-box"> <a href="#"><img class="img-responsive" src="{{asset('user/images/place-2.jpg')}}" alt=""></a> <div class="blog-text"> <div class="prod-title"> <h3><a href="#">Planning for Vacation</a></h3> <span class="posted_by">Sep. 15th</span> <span class="comment"><a href="">21<i class="icon-bubble2"></i></a></span> <p>Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.</p> <p><a href="#">Learn More...</a></p> </div> </div> </div> </div> <div class="clearfix visible-sm-block"></div> <div class="col-lg-4 col-md-4 col-sm-6"> <div class="fh5co-blog animate-box"> <a href="#"><img class="img-responsive" src="{{asset('FrontEnd/images/place-3.jpg')}}" alt=""></a> <div class="blog-text"> <div class="prod-title"> <h3><a href="#">Visit Tokyo Japan</a></h3> <span class="posted_by">Sep. 15th</span> <span class="comment"><a href="">21<i class="icon-bubble2"></i></a></span> <p>Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.</p> <p><a href="#">Learn More...</a></p> </div> </div> </div> </div> <div class="clearfix visible-md-block"></div> </div> <div class="col-md-12 text-center animate-box"> <p><a class="btn btn-primary btn-outline btn-lg" href="#">See All Post <i class="icon-arrow-right22"></i></a></p> </div> </div> </div> <!-- fh5co-blog-section --> <div id="fh5co-testimonial" style="background-image:url({{asset('FrontEnd/images/img_bg_1.jpg')}})"> <div class="container"> <div class="row animate-box"> <div class="col-md-8 col-md-offset-2 text-center fh5co-heading"> <h2>Happy Clients</h2> </div> </div> <div class="row"> <div class="col-md-4"> <div class="box-testimony animate-box"> <blockquote> <span class="quote"><span><i class="icon-quotes-right"></i></span></span> <p>&ldquo;Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts. Separated they live in Bookmarksgrove right at the coast of the Semantics, a large language ocean.&rdquo;</p> </blockquote> <p class="author"><NAME>, CEO <a href="http://freehtml5.co/" target="_blank">FREEHTML5.co</a> <span class="subtext">Creative Director</span></p> </div> </div> <div class="col-md-4"> <div class="box-testimony animate-box"> <blockquote> <span class="quote"><span><i class="icon-quotes-right"></i></span></span> <p>&ldquo;Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.&rdquo;</p> </blockquote> <p class="author"><NAME>, CEO <a href="http://freehtml5.co/" target="_blank">FREEHTML5.co</a> <span class="subtext">Creative Director</span></p> </div> </div> <div class="col-md-4"> <div class="box-testimony animate-box"> <blockquote> <span class="quote"><span><i class="icon-quotes-right"></i></span></span> <p>&ldquo;Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts. Separated they live in Bookmarksgrove right at the coast of the Semantics, a large language ocean.&rdquo;</p> </blockquote> <p class="author"><NAME>, Founder <a href="#">FREEHTML5.co</a> <span class="subtext">Creative Director</span></p> </div> </div> </div> </div> </div> @endsection
0.8125
1
app/lang/en/admin/outgoing/table.php
jkisanga/pbsme
0
14399260
<?php return array( 'received' => 'Received Date', 'date' => 'Mail Date', 'reference' => 'Reference Number', 'address' => 'Address', 'subject' => 'Subject', 'status' => 'Status', );
0.441406
0
resources/views/layouts/master.blade.php
rayenebenmansour20/bilio1
0
14399268
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="<KEY>" crossorigin="anonymous"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta2/css/all.min.css" integrity="sha512-YWzhKL2whUzgiheMoBFwW8CKV4qpHQAEuvilg9FAn5VJUDwKZZxkJNuGM4XkWuk94WCrrwslk8yWNGmY1EduTA==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <link rel="stylesheet" href="css/style.css"> <title>Dashboard</title> </head> <body> <div class="d-flex" id="wrapper"> <!-- Sidebar --> <div class="bg-dark" id="sidebar-wrapper"> <div class="sidebar-heading text-center py-5 primary-text fs-4 fw-bold text-uppercase border-bottom"><i class="mx-auto"></i>Biblio</div> <div class="list-group list-group-flush my-3"> <a href="#" class="list-group-item list-group-item-action bg-transparent second-text active"><i class="fas fa-book me-2"></i>Livres</a> <a href="#" class="list-group-item list-group-item-action bg-transparent second-text fw-bold"><i class="fas fa-user-group me-2"></i>Abonnées</a> <a href="#" class="list-group-item list-group-item-action bg-transparent second-text fw-bold"><i class="fas fa-circle-check me-2"></i>Emprunts</a> <a href="#" class="list-group-item list-group-item-action bg-transparent text-danger fw-bold"><i class="fas fa-power-off me-2"></i>Logout</a> </div> </div> <!-- /#sidebar-wrapper --> <!-- Page Content --> <div id="page-content-wrapper"> <nav class="navbar navbar-expand-lg navbar-light bg-transparent py-4 px-4"> <div class="d-flex align-items-center"> <i class="fas fa-bars second-text fs-2 me-3" id="menu-toggle"></i> <h2 class="fs-2 m-0">Dashboard</h2> </div> <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="navbarSupportedContent"> <ul class="navbar-nav ms-auto mb-2 mb-lg-0"> <li class="nav-item"> <a href="#" class="nav-link fw-bold">Home</a> </li> <li class="nav-item"> <a href="#" class="nav-link fw-bold">Contact</a> </li> <li class="nav-item dropdown"> <a class="nav-link dropdown-toggle second-text fw-bold" href="#" id="navbarDropdown" role="button" data-bs-toggle="dropdown" aria-expanded="false"> <i class="fas fa-user me-2"></i><NAME> </a> <ul class="dropdown-menu" aria-labelledby="navbarDropdown"> <li><a class="dropdown-item" href="#">Profile</a></li> <li><a class="dropdown-item" href="#">Settings</a></li> <li><a class="dropdown-item" href="#">Logout</a></li> </ul> </li> </ul> </div> </nav> <!-- cards <section class="p-5"> <div class="row"> <div class="col-sm"> <div class="card"> <img src="https://images-na.ssl-images-amazon.com/images/I/51yMBnBopTL._AC._SR360,460.jpg" class="card-img-top" alt="Je m'appelle Kylian"> <div class="card-body"> <h3>Je m'appele Kylian</h3> <h5>Faro</h5> <p>BD - Enfants</p> </div> </div> </div> <div class="col-sm"> <div class="card"> <img src="https://images-na.ssl-images-amazon.com/images/I/41OdE0k7WFL._SX343_BO1,204,203,200_.jpg" class="card-img-top" alt="Je m'appelle Kylian"> <div class="card-body"> <h3>Après</h3> <h5><NAME></h5> <p>Romans</p> </div> </div> </div> <div class="col-sm"> <div class="card"> <img src="https://images-na.ssl-images-amazon.com/images/I/51yMBnBopTL._AC._SR360,460.jpg" class="card-img-top" alt="Je m'appelle Kylian"> <div class="card-body"> <h3>Je m'appele Kylian</h3> <p>BD - Enfants</p> </div> </div> </div> <div class="col-sm"> <div class="card"> <img src="https://images-na.ssl-images-amazon.com/images/I/51yMBnBopTL._AC._SR360,460.jpg" class="card-img-top" alt="Je m'appelle Kylian"> <div class="card-body"> <h3>Je m'appele Kylian</h3> <p>BD - Enfants</p> </div> </div> </div> </section> --> @yield('contentA') </div> </div> </div> <!-- /#page-content-wrapper --> </div> <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="<KEY>" crossorigin="anonymous"></script> <script> var el = document.getElementById("wrapper"); var toggleButton = document.getElementById("menu-toggle"); toggleButton.onclick = function () { el.classList.toggle("toggled"); }; </script> </body> </html>
0.769531
1
resources/views/components/home/vid-alle.blade.php
coha-it/laravel-landinpages
0
14399276
<!-- Video start --> <section id="alle" class="half-section p-0"> <h2 class="d-none">heading</h2> <div class="container-fluid"> <div class="row align-items-center"> <div class="col-md-6 col-sm-12 p-0 equalheight XXXcol-video bg-primary wow fadeInLeft"> <div class="video-content-setting center-block text-left text-xs-center equalheight"> <h2 class="color-white font-weight-light mb-2rem mb-xxs-3" style="font-size: 34px;">Das ist natürlich nicht immer leicht. Aber die Wissenschaft hat gezeigt: <span class="font-weight-bold">Es liegt in unserer Hand!</span></h2> <p class="color-white "> Über die letzten Jahre haben wir etliche Unternehmen und Menschen auf diesem Weg begleitet. Auch hier gab es auf dem Weg immer wieder Herausforderungen, die es zu bewältigen galt. Doch all diese Krisen konnten letztendlich überwunden werden und wir haben dabei <strong>viele wertvolle Erfahrungen und Erkenntnisse gesammelt</strong>. </p> <p class=" color-white mb-35px"> In dem folgenden Video erzählt Dr. <NAME>, wie Du diese Erkenntnisse nutzen kannst, um selbst gestärkt aus dieser Krise hervorzugehen: </p> <a data-fancybox href="@yield('vid-alle')" class="btn-setting btn-hvr-setting-main btn-white btn-hvr">Video abspielen</a> </div> </div> <div class="col-md-6 col-sm-12 p-0 equalheight XXXcol-video video-bg order-lg-2 wow fadeInRight"> <div data-fancybox href="@yield('vid-alle')" class="image hover-effect pointer_c"> <img alt="stats" src="{{ asset('images/_/oliver-quad-2.jpg') }}" class="equalheight video-img-setting" style="object-fit: cover;object-position: right;"> </div> <a data-fancybox href="@yield('vid-alle')" class="video-play-button position-absolute wow fadeInLeft oliver_alle_play_button_c"> <i class="ti ti-control-play"></i> </a> </div> </div> </div> </section> <!-- Video ends -->
0.9375
1
src/Stalk/AffiliateBundle/StalkAffiliateBundle.php
VanbOK/affiliate-program
2
14399284
<?php namespace Stalk\AffiliateBundle; use Symfony\Component\HttpKernel\Bundle\Bundle; class StalkAffiliateBundle extends Bundle { }
0.542969
1
src/RepositoryHydration/Repository/ResultSetMappingCompanyRepository.php
pdt256/article
0
14399292
<?php namespace pdt256\article\RepositoryHydration\Repository; use Doctrine\ORM\Query\ResultSetMapping; use pdt256\article\common\Repository\AbstractEntityRepository; use pdt256\article\RepositoryHydration\DTO\CompanyStatsDTO; use pdt256\article\RepositoryHydration\Entity\Employee; final class ResultSetMappingCompanyRepository extends AbstractEntityRepository implements CompanyRepositoryInterface { public function getCompanyStats(int $companyId): CompanyStatsDTO { $resultSetMapping = new ResultSetMapping; $resultSetMapping ->addScalarResult('sclr_0', 'totalActiveEmployees', 'integer') ->addScalarResult('sclr_1', 'totalInactiveEmployees', 'integer'); $companyStatsArray = $this->getEntityManager() ->createQueryBuilder() ->addSelect('SUM(IF(Employee.isActive=1,1,0)) AS totalActiveEmployees') ->addSelect('SUM(IF(Employee.isActive=0,1,0)) AS totalInactiveEmployees') ->from(Employee::class, 'Employee') ->where('Employee.company = :companyId') ->setParameter('companyId', $companyId) ->setMaxResults(1) ->getQuery() ->setResultSetMapping($resultSetMapping) ->getArrayResult(); return new CompanyStatsDTO( $companyStatsArray[0]['totalActiveEmployees'], $companyStatsArray[0]['totalInactiveEmployees'] ); } }
1.257813
1
app/Http/Controllers/Admin/UserController.php
CoderProsenjit/boilerwithcms
363
14399300
<?php namespace App\Http\Controllers\Admin; use App\Base\Controllers\AdminController; use App\Http\Controllers\Admin\DataTables\UserDataTable; use App\Models\User; use Illuminate\Http\Request; class UserController extends AdminController { /** * @var array */ protected $validation = [ 'email' => 'required|email|max:255|unique:users,email', 'password' => '<PASSWORD>' ]; /** * @param \App\Http\Controllers\Admin\DataTables\UserDataTable $dataTable * * @return mixed */ public function index(UserDataTable $dataTable) { return $dataTable->render('admin.table', ['link' => route('admin.user.create')]); } /** * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View|string */ public function create() { return view('admin.forms.user', $this->formVariables('user', null)); } /** * @param \Illuminate\Http\Request $request * * @return \Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector * @throws \Exception */ public function store(Request $request) { return $this->createFlashRedirect(User::class, $request); } /** * @param \App\Models\User $user * * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View|string */ public function show(User $user) { return view('admin.show', ['object' => $user]); } /** * @param \App\Models\User $user * * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View|string */ public function edit(User $user) { return view('admin.forms.user', $this->formVariables('user', $user)); } /** * @param \App\Models\User $user * @param \Illuminate\Http\Request $request * * @return \Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector * @throws \Exception */ public function update(User $user, Request $request) { return $this->saveFlashRedirect($user, $request); } /** * @param \App\Models\User $user * * @return \Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector * @throws \Exception */ public function destroy(User $user) { if ($user->id !== auth()->user()->id) { return $this->destroyFlashRedirect($user); } return $this->redirectRoutePath('index', 'admin.delete.self'); } }
1.28125
1
app/Models/ChatMessage.php
arabelhousseyn/joy
0
14399308
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\SoftDeletes; class ChatMessage extends Model { use HasFactory, SoftDeletes; protected $fillable = [ 'chat_id', 'sender_id', 'receiver_id', 'message' ]; protected $hidden = [ 'created_at', 'updated_at', 'deleted_at' ]; public function chat() { return $this->belongsTo(Chat::class,'chat_id')->withDefault(); } public function sender() { return $this->belongsTo(User::class,'sender_id')->withDefault(); } public function receiver() { return $this->belongsTo(User::class,'receiver_id')->withDefault(); } }
0.957031
1
resources/views/company/applicantslist.blade.php
manish4926/udyog
0
14399316
@extends('layout.master') @section('content') <div class="row"> @include('company.sidemenu') <div class="col-md-8"> <div class="white-card"> <div class="row"> <h3 class="title-blue">Applicants</h3> </div> @foreach($applicants as $applicant) <div class="row"> <div class="col-12"> <div class="card"> <div class=""> <div class="card-body"> <div class="row"> <div class="col-md-8"> <h5 class="card-title"><i class="fas fa-bolt red"></i>{{$applicant->firstname}} {{$applicant->lastname}}</h5> </div> <div class="col-md-8"> <a href="{{route('userprofile',['user'=> $applicant->user_id ])}}" class="btn btn-outline-primary lg-btn-padding"> See Profile</a> </div> </div> </div> </div> </div> </div> </div> @endforeach </div> </div> </div> @push('bottomscript') @endpush @endsection
1.046875
1
app/UserLanguage.php
barman47/about-cert
0
14399324
<?php namespace App; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\Pivot; use App\Traits\UsesUuid; class UserLanguage extends Pivot { use UsesUuid; protected $table = "user_languages"; }
0.621094
1
app/Media.php
ljse/filemanager
0
14399332
<?php namespace App; class Media extends Model { public function categories() { return $this->belongsToMany(Category::class, 'category_media', 'media_id'); } public function category_medias() { return $this->belongsToMany(Category_media::class, 'category_media', 'category_id', 'media_id'); } }
0.855469
1
app/Models/Fund.php
yegobox/misscareerafrica
0
14399340
<?php namespace App\Models; use Eloquent as Model; /** * Class Fund * @package App\Models * @version October 1, 2019, 5:31 pm UTC * * @property string full_name * @property string email * @property string phone_number * @property string background * @property string financial_status * @property string career_background * @property string attachement * @property string why_give_capital * @property string how_capital_transform_life * @property string how_will_you_make_profit * @property string comptentitive_advantage */ class Fund extends Model { public $table = 'funds'; public $fillable = [ 'full_name', 'email', 'phone_number', 'background', 'financial_status', 'career_background', 'attachement', 'why_give_capital', 'how_capital_transform_life', 'how_will_you_make_profit', 'comptentitive_advantage' ]; /** * The attributes that should be casted to native types. * * @var array */ protected $casts = [ 'id' => 'integer', 'full_name' => 'string', 'email' => 'string', 'phone_number' => 'string', 'attachement' => 'string' ]; /** * Validation rules * * @var array */ public static $rules = [ 'attachement'=> 'required', 'email'=> 'required', 'full_name'=> 'required', 'phone_number'=> 'required' ]; }
1.289063
1
resources/views/order/_form.blade.php
razat91/oa
0
14399348
{!! Form::label('name', 'Фамилия, Имя') !!} {!! Form::text('name', null, ['placeholder'=>'<NAME>', 'class'=>'form-control']) !!} </div> <div class="form-group"> {!! Form::label('address', 'Адрес') !!} {!! Form::text('address',null, ['placeholder'=>'Район, улица, дом', 'class'=>'form-control']) !!} </div> <div class="form-group"> {!! Form::label('phone', 'Номер телефона') !!} {!! Form::text('phone', null,['placeholder'=>'Мобильный, городской', 'class'=>'form-control']) !!} </div> <div class="form-group"> {!! Form::label('email', 'Электронный адрес') !!} {!! Form::text('email', null,['placeholder'=>'', 'class'=>'form-control']) !!} </div> <div class="form-group"> {!! Form::label('desc', 'Ваше пожелание') !!} {!! Form::textarea('desc', null, ['placeholder'=>'', 'class'=>'form-control']) !!} </div> {!! Form::submit($submit_text, ['class'=>'btn primary']) !!}
0.707031
1
relocation/relocated/vendor/phpstan/php-8-stubs/stubs/ext/oci8/oci_lob_size.php
tenantcloud/php-better-reflection
0
14399356
<?php function oci_lob_size(\OCILob $lob) : int|false { }
0.152344
0
controllers/Orders.php
mage2/cart
3
14399364
<?php namespace Mage2\Cart\Controllers; use BackendMenu; use Backend\Classes\Controller; use Mage2\Cart\Models\Address; /** * Orders Back-end Controller */ class Orders extends Controller { public $implement = [ 'Backend.Behaviors.FormController', 'Backend.Behaviors.ListController' ]; public $formConfig = 'config_form.yaml'; public $listConfig = 'config_list.yaml'; public function __construct() { parent::__construct(); BackendMenu::setContext('Mage2.Cart', 'cart', 'orders'); } public function listOverrideColumnValue($model, $column, $definition) { if($column == "shipping_address") { $shipppingAddressModel = Address::find($model->address_shipping_id); $addressLabel = $shipppingAddressModel->address_1 . " , " . $shipppingAddressModel->address_2 . " , " . $shipppingAddressModel->city . " " . $shipppingAddressModel->country; return $addressLabel; } if($column == "billing_address") { $shipppingAddressModel = Address::find($model->address_shipping_id); $addressLabel = $shipppingAddressModel->address_1 . " , " . $shipppingAddressModel->address_2 . " , " . $shipppingAddressModel->city . " " . $shipppingAddressModel->country; return $addressLabel; } } public function formExtendFieldsBefore($form) { $shipppingAddressModel = Address::find($form->model->address_shipping_id); $form->model->shipping_address = $shipppingAddressModel->address_1 . " , " . $shipppingAddressModel->address_2 . " , " . $shipppingAddressModel->city . " " . $shipppingAddressModel->country; $form->model->billing_address = $shipppingAddressModel->address_1 . " , " . $shipppingAddressModel->address_2 . " , " . $shipppingAddressModel->city . " " . $shipppingAddressModel->country; } }
1.421875
1
app/Http/Controllers/Api/Billing/BalanceController.php
paranarimasu/AnimeThemes
23
14399372
<?php declare(strict_types=1); namespace App\Http\Controllers\Api\Billing; use App\Http\Controllers\Controller; use App\Http\Requests\Api\Billing\Balance\BalanceDestroyRequest; use App\Http\Requests\Api\Billing\Balance\BalanceForceDeleteRequest; use App\Http\Requests\Api\Billing\Balance\BalanceIndexRequest; use App\Http\Requests\Api\Billing\Balance\BalanceRestoreRequest; use App\Http\Requests\Api\Billing\Balance\BalanceShowRequest; use App\Http\Requests\Api\Billing\Balance\BalanceStoreRequest; use App\Http\Requests\Api\Billing\Balance\BalanceUpdateRequest; use App\Models\Billing\Balance; use Illuminate\Http\JsonResponse; use Spatie\RouteDiscovery\Attributes\Route; /** * Class BalanceController. */ class BalanceController extends Controller { /** * Display a listing of the resource. * * @param BalanceIndexRequest $request * @return JsonResponse */ #[Route(fullUri: 'balance', name: 'balance.index')] public function index(BalanceIndexRequest $request): JsonResponse { $balances = $request->getQuery()->index(); return $balances->toResponse($request); } /** * Store a newly created resource. * * @param BalanceStoreRequest $request * @return JsonResponse */ #[Route(fullUri: 'balance', name: 'balance.store', middleware: 'auth:sanctum')] public function store(BalanceStoreRequest $request): JsonResponse { $resource = $request->getQuery()->store(); return $resource->toResponse($request); } /** * Display the specified resource. * * @param BalanceShowRequest $request * @param Balance $balance * @return JsonResponse */ #[Route(fullUri: 'balance/{balance}', name: 'balance.show')] public function show(BalanceShowRequest $request, Balance $balance): JsonResponse { $resource = $request->getQuery()->show($balance); return $resource->toResponse($request); } /** * Update the specified resource. * * @param BalanceUpdateRequest $request * @param Balance $balance * @return JsonResponse */ #[Route(fullUri: 'balance/{balance}', name: 'balance.update', middleware: 'auth:sanctum')] public function update(BalanceUpdateRequest $request, Balance $balance): JsonResponse { $resource = $request->getQuery()->update($balance); return $resource->toResponse($request); } /** * Remove the specified resource. * * @param BalanceDestroyRequest $request * @param Balance $balance * @return JsonResponse */ #[Route(fullUri: 'balance/{balance}', name: 'balance.destroy', middleware: 'auth:sanctum')] public function destroy(BalanceDestroyRequest $request, Balance $balance): JsonResponse { $resource = $request->getQuery()->destroy($balance); return $resource->toResponse($request); } /** * Restore the specified resource. * * @param BalanceRestoreRequest $request * @param Balance $balance * @return JsonResponse */ #[Route(method: 'patch', fullUri: 'restore/balance/{balance}', name: 'balance.restore', middleware: 'auth:sanctum')] public function restore(BalanceRestoreRequest $request, Balance $balance): JsonResponse { $resource = $request->getQuery()->restore($balance); return $resource->toResponse($request); } /** * Hard-delete the specified resource. * * @param BalanceForceDeleteRequest $request * @param Balance $balance * @return JsonResponse */ #[Route(method: 'delete', fullUri: 'forceDelete/balance/{balance}', name: 'balance.forceDelete', middleware: 'auth:sanctum')] public function forceDelete(BalanceForceDeleteRequest $request, Balance $balance): JsonResponse { return $request->getQuery()->forceDelete($balance); } }
1.390625
1
resources/views/book/book_edit.blade.php
clarioclaud/taskdoodle
0
14399380
@extends('admin.admin_master') @section('admin') <div class="content_wrapper"> <br> <div class="row"> <div class="col-md-1"></div> <div class="col-md-6"> <div class="panel"> <div class="panel_header"> <div class="panel_title"><span>Edit Book</span></div> </div> <div class="panel_body"> <form action="{{ route('book.update') }}" method="post" enctype="multipart/form-data"> @csrf <input type="hidden" name="id" value="{{ $book->id }}"> <input type="hidden" name="old_image" value="{{ $book->image }}"> <div class="form-group"> <label for="name">Book Name</label> <input type="text" name="name" id="name" class="form-control" value="{{ $book->name }}"> </div> <div class="form-group"> <label for="description">Book Description</label> <input type="text" name="description" id="description" class="form-control" value="{{ $book->description }}"> </div> <div class="form-group"> <label for="name">Book Image</label> <input type="file" name="image" id="image" class="form-control" ><br> <img src="{{ asset($book->image) }}" width="100px" height="100px"> </div> <button type="submit" name="update" class="btn btn-info">Update</button> </form> </div> </div> </div> </div> </div> @endsection
1.046875
1
application/controllers/admin/Categoria.php
phmachado94/codeigniter3
0
14399388
<?php defined('BASEPATH') OR exit('No direct script access allowed'); class Categoria extends CI_Controller { public function __construct() { parent::__construct(); $this->load->model('categorias_model', 'modelCategorias'); $this->categorias = $this->modelCategorias->listar_categorias(); if (!$this->session->userdata('logado')) { redirect(base_url('admin/login')); } } public function index() { $this->load->library('table'); $dados['categorias'] = $this->categorias; //Dados a serem enviados para o Cabeçalho $dados['titulo'] = 'Painel de Controle'; $dados['subtitulo'] = 'Categoria'; $this->load->view('backend/template/html-header', $dados); $this->load->view('backend/template/template'); $this->load->view('backend/categoria'); $this->load->view('backend/template/html-footer'); } public function inserir() { $this->load->library('form_validation'); $this->form_validation->set_rules('txtCategoria', 'Nome da Categoria', 'required|min_length[3]|is_unique[categoria.titulo]'); if (!$this->form_validation->run()) { $this->index(); } else { $titulo = $this->input->post('txtCategoria'); if ($this->modelCategorias->adicionar($titulo)) { redirect(base_url('admin/categoria')); echo "Cadastrada com sucesso!"; } else { echo "Houve um erro ao cadastrar!"; } } } public function excluir($id) { if ($this->modelCategorias->excluir($id)) { redirect(base_url('admin/categoria')); echo "Excluída com sucesso!"; } else { echo "Houve um erro ao excluir!"; } } public function alterar($id) { $this->load->library('table'); $dados['categorias'] = $this->modelCategorias->listar_categoria($id); //Dados a serem enviados para o Cabeçalho $dados['titulo'] = 'Painel de Controle'; $dados['subtitulo'] = 'Categoria'; $this->load->view('backend/template/html-header', $dados); $this->load->view('backend/template/template'); $this->load->view('backend/alterar-categoria'); $this->load->view('backend/template/html-footer'); } public function salvar_alteracoes($idCript) { $this->load->library('form_validation'); $this->form_validation->set_rules('txtCategoria', 'Nome da Categoria', 'required|min_length[3]|is_unique[categoria.titulo]'); if (!$this->form_validation->run()) { $this->alterar($idCript); } else { $id = $this->input->post('txtId'); $titulo = $this->input->post('txtCategoria'); if ($this->modelCategorias->alterar($titulo, $id)) { redirect(base_url('admin/categoria')); echo "Alterada com sucesso!"; } else { echo "Houve um erro ao alterar!"; } } } }
1.28125
1
includes/Core/styles-font-menu/classes/sfm-plugin.php
wp-plugins/x-forms-express
1
14399396
<?php require_once dirname(__FILE__) . '/sfm-admin.php'; require_once dirname(__FILE__) . '/sfm-group.php'; require_once dirname(__FILE__) . '/sfm-group-standard.php'; require_once dirname(__FILE__) . '/sfm-group-google.php'; require_once dirname(__FILE__) . '/sfm-single-standard.php'; require_once dirname(__FILE__) . '/sfm-single-google.php'; require_once dirname(__FILE__) . '/sfm-image-preview.php'; /** * Controller class * Holds instances of models in vars * Loads views from views/ directory * * Follows the Singleton pattern. @see http://jumping-duck.com/tutorial/wordpress-plugin-structure/ * @example Access plugin instance with $font_dropdown = SFM_Plugin::get_instance(); */ class SFM_Plugin { /** * @var string The plugin version. */ var $version = '1.0.1'; /** * @var Styles_Font_Menu Instance of the class. */ protected static $instance = false; /** * @var string Class to apply to menu element and prefix to selectors. */ public $menu_class = 'sfm'; /** * @var SFM_Admin Methods for WordPress admin user interface. */ var $admin; /** * @var SFM_Group_Standard Web standard font families and CSS font stacks. */ var $standard_fonts; /** * @var SFM_Group_Google Connects to Google Font API. */ var $google_fonts; /** * @var SFM_Image_Preview Generate image preview of a font. */ var $image_preview; /** * Set with site_url() because we might not be running as a plugin. * * @var string URL for the styles-font-menu directory. */ var $plugin_url; /** * Set with dirname(__FILE__) because we might not be running as a plugin. * * @var string Path for the styles-font-menu directory. */ var $plugin_directory; /** * Intentionally inaccurate if we're running as a plugin. * * @var string Plugin basename, only if we're running as a plugin. */ var $plugin_basename; /** * print_scripts() runs as late as possible to avoid processing Google Fonts. * This prevents running multiple times. * * @var bool Whether we have already registered scripts or not. */ var $scripts_printed = false; /** * Don't use this. Use ::get_instance() instead. */ public function __construct() { if ( !self::$instance ) { $message = '<code>' . __CLASS__ . '</code> is a singleton.<br/> Please get an instantiate it with <code>' . __CLASS__ . '::get_instance();</code>'; wp_die( $message ); } } public static function get_instance() { if ( !is_a( self::$instance, __CLASS__ ) ) { self::$instance = true; self::$instance = new self(); self::$instance->init(); } return self::$instance; } /** * Initial setup. Called by get_instance. */ protected function init() { // Fix for IIS paths $normalized_abspath = str_replace(array('/', '\\'), '/', ABSPATH ); $this->plugin_directory = str_replace(array('/', '\\'), '/', dirname( dirname( __FILE__ ) ) ); $this->plugin_url = site_url( str_replace( $normalized_abspath, '', $this->plugin_directory ) ); $this->plugin_basename = plugin_basename( $this->plugin_directory . '/plugin.php' ); $this->admin = new SFM_Admin( $this ); $this->google_fonts = new SFM_Group_Google(); $this->standard_fonts = new SFM_Group_Standard(); $this->image_preview = new SFM_Image_Preview(); /** * Output dropdown menu anywhere styles_font_menu action is called. * @example <code>do_action( 'styles_font_menu' );</code> */ add_action( 'styles_font_menu', array( $this, 'get_view_menu' ), 10, 2 ); } public function print_scripts() { if ( $this->scripts_printed ) { return false; } wp_register_script( 'styles-chosen', $this->plugin_url . '/js/chosen/chosen.jquery.min.js', array( 'jquery' ), $this->version ); wp_register_script( 'styles-font-menu', $this->plugin_url . '/js/styles-font-menu.js', array( 'jquery', 'styles-chosen' ), $this->version ); wp_register_style( 'styles-chosen', $this->plugin_url . '/js/chosen/chosen.css', array(), $this->version ); wp_register_style( 'styles-font-menu', $this->plugin_url . '/css/styles-font-menu.css', array(), $this->version ); // wp_register_style( 'styles-chosen', $this->plugin_url . '/js/chosen/chosen.min.css', array(), $this->version ); // Pass Google Font Families to javascript // This saves on bandwidth by outputing them once, // then appending them to all <select> elements client-side wp_localize_script( 'styles-font-menu', 'styles_standard_fonts', $this->standard_fonts->option_values ); wp_localize_script( 'styles-font-menu', 'styles_google_options', $this->google_fonts->option_values ); // Output scripts and dependencies // Tracks whether dependencies have already been output wp_print_scripts( array( 'styles-font-menu' ) ); wp_print_styles( array( 'styles-chosen' ) ); wp_print_styles( array( 'styles-font-menu' ) ); // Generated scripts for font previews echo '<style>' . $this->standard_fonts->get_menu_css() . '</style>'; $this->scripts_printed = true; } /** * Display views/menu.php */ public function get_view_menu( $attributes = '', $value = false ) { $args = compact( 'attributes', 'value' ); $this->get_view( 'menu', $args ); } /** * Display any view from the views/ directory. * Allows views to have access to $this */ public function get_view( $file = 'menu', $args = array() ) { extract( $args ); $file = dirname( dirname( __FILE__ ) ) . "/views/$file.php"; if ( file_exists( $file ) ) { include $file; } } }
1.195313
1
vizitm/forms/manage/request/RequestCreateForm.php
Ornelius/vizitm
0
14399404
<?php namespace vizitm\forms\manage\request; use vizitm\forms\CompositeForm; /** * @property PhotoCreateForm $photo */ class RequestCreateForm extends CompositeForm { public ?int $user_id = null; public ?int $building_id = null; public ?string $description = null; public ?int $type = null; public ?int $type_of_work = null; public ?int $room = null; public ?int $importance = null; public $due_date ; public function __construct($config = []) { $this->photo = new PhotoCreateForm(); parent::__construct($config); } public function attributeLabels(): array { return [ 'building_id' => 'Адрес здания', 'description' => 'Описание проблемы', 'type' => 'Тип заявки', 'type_of_work' => 'Тип работы', 'room' => 'Тип помещения', 'importance' => 'Срочность', 'due_date' => 'Дата исполнения' ]; } /** * {@inheritdoc} */ public function rules(): array { return [ [['building_id', 'description', 'type', 'room'], 'required'], [['building_id', 'type', 'room', 'importance'], 'integer'], //[['building_id', 'user_id', 'created_at', 'deleted', 'deleted_at', 'done', 'done_at', 'invoice', 'invoce_at', 'type_of_work', 'status'], 'integer'], [['description'], 'string'], ['due_date', 'default', 'value' => null], ['due_date', 'date', 'timestampAttribute' => 'due_date'], //[['building_id'], 'unique'], //[['user_id'], 'unique'], //[['building_id'], 'exist', 'skipOnError' => true, 'targetClass' => Building::class, 'targetAttribute' => ['building_id' => 'id']], //[['user_id'], 'exist', 'skipOnError' => true, 'targetClass' => Users::class, 'targetAttribute' => ['user_id' => 'id']], //[['photo_id'], 'exist', 'skipOnError' => true, 'targetClass' => Photo::class], ]; } protected function internalForms(): array { return ['photo']; } }
1.132813
1
manage-subject/deactivate.php
shyamjanammahato/E-Helpdesk
0
14399412
<?php include "../config.php"; if($ck!='1') { header("Location: ../login/index.php"); } $sl=$_REQUEST['sl']; $query_update="UPDATE subject_tbl set stat='0' where sl='$sl' "; $result_update=mysqli_query($conn,$query_update); if(isset($result_update)) { ?> <script language="JavaScript"> alert("Successfully Deactivated the subject"); document.location.href="../manage-subject/index.php"; </script> <?php } ?>
0.820313
1
resources/views/home/page.blade.php
dan89farhan/a2computer
0
14399420
<h2>This is page page</h2> <?php print_r($data);
0.304688
0
applications/frontend/modules/training/views/wml/dbopen.php
greathqy/socialphp
0
14399428
<?php if (isset($opened)): ?> 成功开通培训班,有效期<?php echo $payconfig['days'];?>天。<br /> <a href="<?php echo linkwml('training', 'index');?>">继续</a> <?php elseif (isset($prolonged)): ?> 延长了培训班有效期<?php echo $payconfig['days'];?>天<br /> <a href="<?php echo linkwml('training', 'index');?>">继续</a> <?php elseif (isset($failed)): ?> 钻石不足,无法开通/延长,请<a href="">充值</a><br /> <?php else: ?> <?php if ($classroom): ?> 你已经用钻石开通过培训班了,你要使用<?php echo $payconfig['price'];?>钻石延长时间<?php echo $payconfig['days'];?>天吗?<br /> <a href="<?php echo linkwml('training', 'dbopen', array('confirm' => 1));?>">确认延长</a><br /> <a href="<?php echo $link_prev;?>">返回</a> <?php else: ?> 你要使用<?php echo $payconfig['price'];?>钻石开通培训班<?php echo $payconfig['days'];?>天吗?<br /> <a href="<?php echo linkwml('training', 'dbopen', array('confirm' => 1));?>">确认开通</a> <?php endif; ?> <?php endif; ?>
0.800781
1
resources/views/user/interview/index.blade.php
ilhamhafidz404/smart-iduka-final
0
14399436
@extends('layouts.userlayout') @section('title','Kategori') @section('nama_halaman','management Loker') @section('css') <!-- DataTables --> <link rel="stylesheet" href="{{asset('AdminLte/plugins/datatables-bs4/css/dataTables.bootstrap4.min.css')}}"> <link rel="stylesheet" href="{{asset('AdminLte/plugins/datatables-responsive/css/responsive.bootstrap4.min.css')}}"> <link rel="stylesheet" href="{{asset('AdminLte/plugins/datatables-buttons/css/buttons.bootstrap4.min.css')}}"> @endsection @section('content') <!-- Main content --> <section class="content"> <div class="container-fluid"> <div class="card mb-3"> <div class="card-header"> <h3>List Lamaran kerja saya</h3> </div> <div class="card-body"> <table class="table table-bordered table-hover table-sm table-striped" id="table-lamaran"> <thead class="table-primary"> <tr> <th>No</th> <th>Nama Perusahaan</th> <th>Judul Loker</th> <th>tempat</th> <th colspan="2" >tanggal</th> <th>Status</th> </tr> </thead> <tbody> @foreach($interview as $inv) <tr> <td>{{$loop->iteration}}</td> <td>{{$inv->pelamar->company->name}}</td> <td>{{$inv->pelamar->post->title}}</td> <td>{{$inv->tempat}}</td> <td>{{$inv->tanggal}}</td> <td>{{$inv->waktu}}</td> @if($inv->status == 'success') <td>Telah Interview</td> @endif @if($inv->status == 'pending') <td>Belum Interview</td> @endif </tr> @endforeach </tbody> </table> </div> </div> </div> <!-- /.container-fluid --> </section> <!-- /.content --> @endsection <!------------------------------------ BAGIAN JAVASCRIPT ------------------------------------------> @section('js') {{--<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.js"></script>--}} <!-- jQuery --> <script src="{{asset('plugins/jquery/jquery.min.js')}}"></script> <!-- Bootstrap 4 --> <script src="{{asset('plugins/bootstrap/js/bootstrap.bundle.min.js')}}"></script> <!-- DataTables & Plugins --> <script src="{{asset('AdminLte/plugins/datatables/jquery.dataTables.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-bs4/js/dataTables.bootstrap4.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-responsive/js/dataTables.responsive.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-responsive/js/responsive.bootstrap4.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-buttons/js/dataTables.buttons.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-buttons/js/buttons.bootstrap4.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/jszip/jszip.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/pdfmake/pdfmake.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/pdfmake/vfs_fonts.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-buttons/js/buttons.html5.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-buttons/js/buttons.print.min.js')}}"></script> <script src="{{asset('AdminLte/plugins/datatables-buttons/js/buttons.colVis.min.js')}}"></script> <script> $(document).ready(function() { $('#table-lamaran').DataTable(); } ); </script> @endsection
1.125
1
application/modules/Auth/views/auth/body_form_login.php
Robroblemol/AppPsicologia
0
14399444
<div class="container"> <div class="card card-login mx-auto mt-5"> <div class="card-header"> Login </div> <div class="card-body"> <?php if($message!=null){?> <div class="alert alert-info" id="infoMessage"><?php echo $message;?> </div> <?php }?> <p>Por favor inicie seccion con nombre de usuario o email</p> <?php echo form_open("Auth/login");?> <p> <?php echo lang('login_identity_label', 'identity');?> <?php echo form_input($identity);?> </p> <p> <?php echo lang('login_password_label', 'password');?> <?php echo form_input($password);?> </p> <div class="custom-control custom-checkbox"> <?php echo form_checkbox('remember', '1', FALSE, 'id="remember" class="custom-control-input"');?> <label class="custom-control-label" for="remember"> <?php echo lang('login_remember_label', 'remember');?> </label> </div> <p><?php echo form_submit('submit', lang('login_submit_btn'),'class ="btn btn-primary"');?></p> <?php echo form_close();?> <div> <p><a href="forgot_password"><?php echo lang('login_forgot_password');?></a></p> </div> </div> </div> </div>
0.667969
1
src/Stfalcon/Bundle/BlogBundle/Admin/PostCategoryAdmin.php
metalslave/portfolio
30
14399452
<?php namespace Stfalcon\Bundle\BlogBundle\Admin; use Sonata\AdminBundle\Admin\Admin; use Sonata\AdminBundle\Datagrid\DatagridMapper; use Sonata\AdminBundle\Datagrid\ListMapper; use Sonata\AdminBundle\Form\FormMapper; use Stfalcon\Bundle\BlogBundle\Entity\Post; use Stfalcon\Bundle\BlogBundle\Entity\PostCategory; use Stfalcon\Bundle\BlogBundle\Entity\PostCategoryTranslation; /** * Class PostCategoryAdmin. */ class PostCategoryAdmin extends Admin { private $prevPosts = null; /** * {@inheritdoc} */ public function prePersist($object) { $this->updateSlug($object); } /** * @param PostCategory $object * * @return mixed|void */ public function preUpdate($object) { $this->updateSlug($object); /** @var Post $post */ foreach ($this->prevPosts as $post) { if (!$object->getPosts()->contains($post)) { $post->setCategory(null); } } /** @var Post $post */ foreach ($object->getPosts() as $post) { $post->setCategory($object); } } /** * @param FormMapper $formMapper */ protected function configureFormFields(FormMapper $formMapper) { /** @var PostCategory $postCategory */ $postCategory = $this->getSubject(); $objectId = $postCategory->getId(); if ($objectId) { $this->prevPosts = clone $postCategory->getPosts(); } $formMapper ->add( 'translations', 'a2lix_translations_gedmo', [ 'translatable_class' => 'Stfalcon\Bundle\BlogBundle\Entity\PostCategory', 'fields' => [ 'name' => [ 'label' => 'Name', 'locale_options' => [ 'ru' => [ 'required' => true, ], 'en' => [ 'required' => false, ], ], ], ], 'label' => 'Перевод', ] ) ->add('slug', null, [ 'disabled' => \is_null($objectId)]) ->add('posts', null, [ 'help' => \is_null($objectId) ? 'добавлять посты можно только после создания категории' : 'выбирете посты для категори', 'disabled' => \is_null($objectId), ]) ; } /** * {@inheritdoc} */ protected function configureListFields(ListMapper $listMapper) { $listMapper ->addIdentifier('name') ->add('posts') ->add('_action', 'actions', [ 'label' => 'Действия', 'actions' => [ 'edit' => [], 'delete' => [], ], ]); } /** * {@inheritdoc} */ protected function configureDatagridFilters(DatagridMapper $filterMapper) { $filterMapper->add('name'); } /** * @param PostCategory $object */ private function updateSlug($object) { /** * @var $translation PostCategoryTranslation */ foreach ($object->getTranslations() as $key => $translation) { if ('en' === $translation->getLocale() && $translation->getContent()) { $object->setSlug($translation->getContent()); break; } } } }
1.1875
1
app/Shop/Addresses/Address.php
michael-hampton/laracom
2
14399460
<?php namespace App\Shop\Addresses; use App\Shop\Customers\Customer; use App\Shop\Orders\Order; use App\Shop\Provinces\Province; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\SoftDeletes; use App\Shop\Cities\City; use App\Shop\Countries\Country; use Sofa\Eloquence\Eloquence; use Watson\Validating\ValidatingTrait; class Address extends Model { use SoftDeletes, Eloquence, ValidatingTrait; /** * * @var type */ protected $rules = [ 'create' => [ 'alias' => ['required'], 'address_1' => ['required'] ], 'update' => [ 'alias' => ['required'], 'address_1' => ['required'] ] ]; /** * The attributes that are mass assignable. * * @var array */ public $fillable = [ 'alias', 'address_1', 'address_2', 'zip', 'city', 'state_code', 'province_id', 'country_id', 'customer_id', 'status', 'phone' ]; /** * The attributes that should be hidden for arrays. * * @var array */ protected $hidden = []; protected $dates = ['deleted_at']; public function customer() { return $this->belongsTo(Customer::class); } public function country() { return $this->belongsTo(Country::class); } public function province() { return $this->belongsTo(Province::class); } /** * @deprecated * * @return \Illuminate\Database\Eloquent\Relations\BelongsTo */ public function city() { return $this->belongsTo(City::class, 'city'); } public function orders() { return $this->hasMany(Order::class); } /** * * @param type $blUpdate * @return boolean */ public function validate($blUpdate = false) { $rules = $blUpdate === false ? $this->rules['create'] : $this->rules['update']; $this->setRules($rules); $blValid = $this->isValid(); if (!$blValid) { $this->validationFailures = $this->getErrors()->all(); return false; } return true; } /** * * @return type */ public function getValidationFailures() { return $this->validationFailures; } }
1.53125
2
app/Models/busquedas.php
MaximilianoVillalba/CustomerdbLaravelWeb-01
0
14399468
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Facades\DB; class busquedas extends Model { use HasFactory; protected $atable = 'busquedas'; protected $primaryKey = 'idBusqueda'; protected $fillable = array('idRubro', 'empresa', 'titulo', 'descripcion'); protected $hidden = ['created_at', 'updated_at']; public static function obtenerbusquedaPorRubro($idRubro) { $busquedas = DB::select('SELECT * FROM busquedas WHERE idRubro=' . $idRubro . ''); return $busquedas; } public static function obtenerPrueba($idRubro) { $busquedas = DB::select('SELECT * FROM busquedas WHERE idRubro=' . $idRubro . ''); $resp = json_encode($busquedas); return $resp; } }
1.15625
1
resources/views/campaigns/update.blade.php
HugoVirot/DataTracks
0
14399476
@extends ('layouts.app') @section('title') Ajouter produit @endsection @section('content') <main class="container"> <div class="container text-center"> @if ($errors->any()) <div class="alert alert-danger"> <ul> @foreach ($errors->all() as $error) <li>{{ $error }}</li> @endforeach </ul> </div> @endif </div> <div> <div class="row bg-dark text-light font-weight-bold p-2 mb-4">Modifier les produits de la campagne</div> <div class=" container table-info border border-dark p-5 mb-2"> <form class="col-3 mx-auto" action="{{ route('campaigns.update', $campaign) }}" method="POST"> @csrf @method('PUT') <div class="form-group"> @foreach ($products as $product) <div class="custom-control custom-checkbox"> <input type="checkbox" @foreach ($campaignProductsIDs as $cP) @if ($product->id == $cP->product_id)) checked="checked" @break @endIf @endforeach class="custom-control-input" name="product{{ $product->id }}" value={{ $product -> id }} id="product{{ $product->id }}"> <label class="custom-control-label" for="product{{ $product->id }}">{{ $product->name }}</label> </div> @endforeach </div> <div class="row"> <div class="form-group"> <input type="hidden" name="id" id="id" value="{{ $campaign->id }}"> </div> <div class="col-6"> <a class="btn btn-secondary" href="{{ route('campaigns.index') }}"> Annuler </a> </div> <div class="col-6"> <button type="submit" class="btn btn-secondary">Valider</button> </div> </div> </form> </div> </div> </main> @endsection
1.257813
1
pset7/public/index.php
evansekeful/cs50xmiami
1
14399484
<?php // configuration require("../includes/config.php"); if ($_SESSION["id"] == NULL) { redirect("login.php"); } else { // user's portfolio require("../includes/positions.php"); // render portfolio render("portfolio.php", ["balance" => $balance, "positions" => $positions, "title" => "Portfolio"]); } ?>
0.820313
1
routes/web.php
andymohammad/project-psk-7b1
0
14399492
<?php //use Illuminate\Routing\Route; /* |-------------------------------------------------------------------------- | Web Routes |-------------------------------------------------------------------------- | | Here is where you can register web routes for your application. These | routes are loaded by the RouteServiceProvider within a group which | contains the "web" middleware group. Now create something great! | */ Route::get('/', function () { return view('auth.login'); }); Route::get('/login', 'AuthController@login')->name('login'); Route::post('/postlogin', 'AuthController@postlogin'); Route::get('logout', 'AuthController@logout')->middleware('auth','checkRole:admin,mahasiswa'); Route::get('/dashboard', 'AdminController@dashboard')->middleware('auth','checkRole:admin,mahasiswa'); Route::get('/profile', 'UserController@profile'); Route::post('profile', 'UserController@uploadfoto'); //Route::get('/dashboard/{id}/detail', 'MahasiswaController')->middleware('auth', 'checkRole:admin,mahasiswa,dosen'); Auth::routes(); //user route //Route::get('users/{user}', ['as' => 'user.edit', 'uses' => 'UserController@edit']); //Route::patch('user/{user}/update', ['as' => 'users.update', 'uses' => 'UserController@update']); Route::get('/datamhs', 'MahasiswaController@datamhs')->middleware('auth','checkRole:admin'); Route::post('/datamhs/create', 'MahasiswaController@create')->middleware('auth'); Route::get('/datamhs/{id}/edit', 'MahasiswaController@edit')->middleware('auth'); Route::post('/datamhs/{id}/update', 'MahasiswaController@update')->middleware('auth'); Route::get('/datamhs/{id}/delete', 'MahasiswaController@delete')->middleware('auth'); Route::get('/home', 'HomeController@index')->name('home');
1.046875
1
php/hhvm-3.15.6-dev/72c0ba429f7638ad079a792e585fec994ba9c9d611867bde2c1d928405ebf61d.php
ChrisTimperley/interpreter-bugs
90
14399500
<?php ini_set("intl.error_level", E_WARNING); $c = new IntlGregorianCalendar(NULL, 'pt_PT'); function eh($errno, $errstr) { echo "error: $errno, $errstr\n"; } set_error_handler('eh'); try { var_dump($c->equals()); } catch (Error $ex) { echo "error: " . $ex->getCode() . ", " . $ex->getMessage() . "\n\n"; } try { var_dump($c->equals(new stdclass)); } catch (Error $ex) { echo "error: " . $ex->getCode() . ", " . $ex->getMessage() . "\n\n"; } try { var_dump($c->equals(1, 2)); } catch (Error $ex) { echo "error: " . $ex->getCode() . ", " . $ex->getMessage() . "\n\n"; } try { var_dump(intlcal_equals($c, array())); } catch (Error $ex) { echo "error: " . $ex->getCode() . ", " . $ex->getMessage() . "\n\n"; } try { var_dump(intlcal_equals(1, $c)); } catch (Error $ex) { echo "error: " . $ex->getCode() . ", " . $ex->getMessage() . "\n\n"; }{ echo "error: " . $ex->getCode() . ", " . $ex->getMessage() . "\n\n"; }
1.25
1
app/Http/Controllers/Admin/StockController.php
kelostrada/depot
0
14399508
<?php namespace App\Http\Controllers\Admin; use App\Http\Controllers\Controller; use App\Models\Invoice; use App\Models\Product; use App\Models\Stock; use Carbon\Carbon; use Illuminate\Http\Request; use Symfony\Component\DomCrawler\Crawler; class StockController extends Controller { public function index() { return view('admin.import_stock'); } public function importStock(Request $request) { $company = $request->get('company'); $content = $request->get('invoice_content'); if ($company == "Blackfire") { $this->addBlackfireStock($content); } if ($company == "Ynaris") { $this->addYnarisStock($content); } return redirect('admin/stock'); } private function addBlackfireStock($content) { // find invoice name and date $crawler = new Crawler($content); $crawler = $crawler->filterXPath("//table/tbody/tr[td[text()='Invoice ID']]/td[2]"); $invoice_name = $crawler->text(); $crawler = new Crawler($content); $crawler = $crawler->filterXPath("//table/tbody/tr[td[text()='Invoice Date']]/td[2]"); $carbon = Carbon::createFromFormat('d.m.Y', $crawler->text()); $invoice_date = $carbon->isoFormat("YYYY-MM-DD"); $invoice = Invoice::firstOrNew(['name' => $invoice_name]); $invoice->name = $invoice_name; $invoice->date = $invoice_date; $invoice->save(); // find tables that have headers (only invoice related tables have headers in blackfire invoices) $crawler = new Crawler($content); $crawler = $crawler->filterXPath("//table/tbody[tr/th]"); $data = []; foreach ($crawler as $tbody) { $tbody = new Crawler($tbody); $tbody = $tbody->filterXPath("tbody/tr[td]"); foreach($tbody as $tr) { $row = []; $tr = new Crawler($tr); $tr = $tr->filter('td'); foreach ($tr as $td) { $row[] = $td->nodeValue; } $data[] = $row; } } $data = array_filter($data, function($row) { return count($row) == 7; }); $data = array_values($data); $data = array_map(function($row) { $ref_upc = explode("\n", $row[1]); $ref = trim($ref_upc[0]); $upc = isset($ref_upc[1]) ? trim($ref_upc[1]) : ""; $name = $row[2]; if (strpos($name, "UP - ") === 0) { $ref = "UP-{$ref}"; } if (strpos($name, "Dragon Shield") === 0) { $ref = "AT-{$ref}"; } return [ 'ref' => $ref, 'upc' => $upc, 'name' => $row[2], 'quantity' => $row[4], 'price' => floatval(trim(str_replace(["€", ","], ["", "."], $row[5]))), 'currency' => 'EUR' ]; }, $data); $this->addProductsStocks($data, $invoice); } private function addYnarisStock($content) { // echo $content; // find invoice name and date $crawler = new Crawler($content); $crawler = $crawler->filterXPath("//table/tbody/tr[td/p[text()='Facture']]/td[2]"); $invoice_name = $crawler->text(); $crawler = new Crawler($content); $crawler = $crawler->filterXPath("//table/tbody/tr[td/p[text()='Date de facturation']]/td[2]"); $carbon = Carbon::createFromFormat('d/m/Y', $crawler->text()); $invoice_date = $carbon->isoFormat("YYYY-MM-DD"); $invoice = Invoice::firstOrNew(['name' => $invoice_name]); $invoice->name = $invoice_name; $invoice->date = $invoice_date; $invoice->save(); // find tables that have headers (only invoice related tables have headers in blackfire invoices) $crawler = new Crawler($content); $crawler = $crawler->filterXPath("//table[thead/tr/th]/tbody"); $data = []; foreach ($crawler as $tbody) { $tbody = new Crawler($tbody); $tbody = $tbody->filterXPath("tbody/tr[td]"); foreach($tbody as $tr) { $row = []; $tr = new Crawler($tr); $tr = $tr->filter('td'); foreach ($tr as $td) { $row[] = $td->nodeValue; } $data[] = $row; } } $data = array_filter($data, function($row) { return count($row) == 5; }); $data = array_values($data); $data = array_map(function($row) { $ref = str_replace(" ", "-", trim($row[0])); if (strpos($ref, "VGE-V-") === 0) { if (strpos($ref, "-SP") !== false) { $ref = str_replace("-SP", "SP", $ref); } $ref = "{$ref}-EN"; } return [ 'ref' => $ref, 'upc' => '', 'name' => trim($row[1]), 'quantity' => (int)trim($row[2]), 'price' => floatval(trim(str_replace(["€", ","], ["", "."], $row[3]))), 'currency' => 'EUR' ]; }, $data); $this->addProductsStocks($data, $invoice); } private function addProductsStocks($data, $invoice) { $data = array_filter($data, function($row) { return $row['price'] > 0; }); $data = array_values($data); foreach ($data as $product_data) { $products = Product::where('ref', $product_data['ref']) ->orWhere(function($q) use ($product_data) { return $q->where('upc', $product_data['upc'])->where('upc', '!=', '')->whereNotNull('upc'); })->get(); $foundProductsCount = count($products); if ($foundProductsCount > 1) { throw new \Exception("Product conflict: {$product_data['ref']} {$product_data['upc']}"); } if ($foundProductsCount == 1) { $product = $products[0]; if (empty($product->upc)) { $product->upc = $product_data['upc']; $product->save(); } } else { $product = new Product(); $product->quantity = 0; $product->price = 0; $product->name = $product_data['name']; $product->ref = $product_data['ref']; $product->upc = $product_data['upc']; $product->save(); } if ($invoice->stocks()->where('product_id', '=', $product->id)->get()->isEmpty()) { $stock = new Stock(); $stock->product_id = $product->id; $stock->invoice_id = $invoice->id; $stock->quantity = $product_data['quantity']; $stock->price = $product_data['price']; $stock->currency = $product_data['currency']; $stock->save(); } } } }
1.421875
1
console/migrations/m181204_080653_add_reboardcase_to_ott_channel.php
Luckylewin/superweb
4
14399516
<?php use yii\db\Migration; use common\models\OttChannel; /** * Class m181204_080653_add_reboardcase_to_ott_channel */ class m181204_080653_add_reboardcase_to_ott_channel extends Migration { /** * {@inheritdoc} */ public function safeUp() { } /** * {@inheritdoc} */ public function safeDown() { echo "m181204_080653_add_reboardcase_to_ott_channel cannot be reverted.\n"; return false; } // Use up()/down() to run migration code without a transaction. public function up() { // 回播可用,回播算法,时移可用,时移算法 $this->addColumn(OttChannel::tableName(), 'rebroadcast_use_flag', 'tinyint(1) not null default 0'); $this->addColumn(OttChannel::tableName(), 'rebroadcast_method', 'char(20) not null default ""'); $this->addColumn(OttChannel::tableName(), 'shifting_use_flag', 'tinyint(1) not null default 0'); $this->addColumn(OttChannel::tableName(), 'shifting_method', 'char(20) not null default ""'); } public function down() { echo "m181204_080653_add_reboardcase_to_ott_channel cannot be reverted.\n"; $this->dropColumn(OttChannel::tableName(), 'rebroadcast_use_flag'); $this->dropColumn(OttChannel::tableName(), 'rebroadcast_method'); $this->dropColumn(OttChannel::tableName(), 'shifting_use_flag'); $this->dropColumn(OttChannel::tableName(), 'shifting_method'); return true; } }
1.15625
1
app/Services/TagService.php
whitexiong/laravue
1
14399524
<?php namespace App\Services; class TagService { public function list() { } }
0.462891
0
t3scan/vendor/typo3/cms-scanner/config/Matcher/v7/ConstantMatcher.php
pluswerk/grumphp-typo3scan-task
0
14399532
<?php return [ 'PATH_tslib' => [ 'restFiles' => [ 'Breaking-61459-RemovalTslib.rst', ], ], 'REQUIRED_EXTENSIONS' => [ 'restFiles' => [ 'Breaking-62416-DeprecatedCodeRemovalInCoreSysext.rst', ], ], 'TYPO3_extTableDef_script' => [ 'restFiles' => [ 'Deprecation-65344-ExtTables.rst', ], ], 'TYPO3_MOD_PATH' => [ 'restFiles' => [ 'Breaking-67987-RemovedEntryScriptHandling.rst', ], ], 'PATH_typo3_mod' => [ 'restFiles' => [ 'Breaking-67987-RemovedEntryScriptHandling.rst', ], ], 'TYPO3_URL_ORG' => [ 'restFiles' => [ 'Breaking-68814-RemoveOfBaseConstantTYPO3_URL_ORG.rst', ], ], 'TYPO3_cliKey' => [ 'restFiles' => [ 'Deprecation-68804-CLI-relatedConstantsAndMethods.rst', ], ], 'TYPO3_cliInclude' => [ 'restFiles' => [ 'Deprecation-68804-CLI-relatedConstantsAndMethods.rst', ], ], ];
0.691406
1
system/core/Controller.php
DilipDKalsariya/bharatFitness
0
14399540
<?php /** * CodeIgniter * * An open source application development framework for PHP * * This content is released under the MIT License (MIT) * * Copyright (c) 2014 - 2018, British Columbia Institute of Technology * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. * * @package CodeIgniter * @author EllisLab Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. (https://ellislab.com/) * @copyright Copyright (c) 2014 - 2018, British Columbia Institute of Technology (http://bcit.ca/) * @license http://opensource.org/licenses/MIT MIT License * @link https://codeigniter.com * @since Version 1.0.0 * @filesource */ defined('BASEPATH') OR exit('No direct script access allowed'); /** * Application Controller Class * * This class object is the super class that every library in * CodeIgniter will be assigned to. * * @package CodeIgniter * @subpackage Libraries * @category Libraries * @author EllisLab Dev Team * @link https://codeigniter.com/user_guide/general/controllers.html */ class CI_Controller { /** * Reference to the CI singleton * * @var object */ private static $instance; public $UID; //login user id /** * Class constructor * * @return void */ public function __construct() { self::$instance =& $this; // Assign all the class objects that were instantiated by the // bootstrap file (CodeIgniter.php) to local class variables // so that CI can run as one big super object. foreach (is_loaded() as $var => $class) { $this->$var =& load_class($class); } $this->load =& load_class('Loader', 'core'); $this->load->initialize(); log_message('info', 'Controller Class Initialized'); } // -------------------------------------------------------------------- /** * Get the CI singleton * * @static * @return object */ public static function &get_instance() { return self::$instance; } /** * @param $rule get validation array and from this validate * requested data * for version v1 */ public function check_validation_v1($rule = array()) { // pr($rule); die; if (!empty($rule)) { foreach ($rule as $key => $val) { $_POST[$key] = $val['value']; //For handle array field validation if (is_array($val['value'])) { $msg_arr = array(); if (array_key_exists("message_array", $val)) { $msg_arr = $val["message_array"]; } if (!empty($val['value'])) { foreach ($val['value'] as $k => $v) { unset($_POST[$key]); $_POST[$key . "_" . $k] = $v; $this->form_validation->set_rules($key . "_" . $k, isset($val["field_name"]) ? $val["field_name"] : $key, $val["rule"], $msg_arr); } } else { $_POST[$key] = ""; $this->form_validation->set_rules($key, isset($val["field_name"]) ? $val["field_name"] : $key, $val["rule"], $msg_arr); } } else { $msg_arr = array(); if (array_key_exists("message_array", $val)) { $msg_arr = $val["message_array"]; } $this->form_validation->set_rules($key, isset($val["field_name"]) ? $val["field_name"] : $key, $val["rule"], $msg_arr); } } if ($this->form_validation->run() == false) { $this->form_validation->set_error_delimiters('', ''); // For the remove <p> tag from error validation. $data = array(); $i = 0; foreach ($rule as $key => $val) { $message[$i] = form_error($key); if ($message[$i] != "") { $fieldDigit = filter_var($key, FILTER_SANITIZE_NUMBER_INT); $fieldName = rtrim($key, "1234567890"); if (array_key_exists("message_array", $val)) { $msg = $message[$i]; } else { $msg = substr($message[$i], 0, 3) == "The" ? str_replace("field ", "", ltrim(strtolower($message[$i]), "the")) : $message[$i]; } $msg = str_replace("otp", "OTP", ucfirst(trim(str_replace("_", " ", $msg)))); $res["errorData"][] = array( "index" => $fieldDigit ? $fieldDigit : $i, "fieldName" => $fieldName, "message" => $msg ); $message[$i] = $msg; } $i++; } log_message('error', 'API - validation false'); log_message('error', "Validation false:" . json_encode($res)); respond_error_to_api_v1(implode(' and ', array_filter($message)), $res); } } } public function check_auth() { $auth = $this->input->request_headers(); //get request data $user = $this->common->check_authentication(@$auth['substantiation']); $this->UID = $user['id']; } }
1.117188
1
application/models/admin/Account_model.php
armwurfel/salon
0
14399548
<?php class Account_model extends CI_Model{ public function add_account($data){ $this->db->insert('accounts', $data); return true; } public function get_tasks_salary($data){ $query ='select COUNT( at.task_id ) as TotalTasks , SUM( (select t.task_price from tasks t where t.id = at.task_id) ) as TotalEarning from assign_tasks at where at.task_status = 1 AND at.worker_id = ' . $data['worker_id'] . ' AND at.task_date >= ' . '"' . $data['salary_month_start'] . '"' . ' AND at.task_date <= ' . '"' . $data['salary_month_end'] . '"'; return $this->db->query($query)->result_array(); } public function get_all_accounts(){ $query = $this->db->get('accounts'); return $result = $query->result_array(); } public function get_account_by_id($id){ $query = $this->db->get_where('accounts', array('id' => $id)); return $result = $query->row_array(); } public function edit_account($data, $id){ $this->db->where('id', $id); $this->db->update('accounts', $data); return true; } } ?>
1.53125
2
database/seeds/AksesKategoriSeeder.php
nandohidayat/simpeg_backend
0
14399556
<?php use Illuminate\Database\Seeder; use Illuminate\Support\Facades\DB; class AksesKategoriSeeder extends Seeder { /** * Run the database seeds. * * @return void */ public function run() { DB::table('akses_kategoris')->insert([ 'kategori' => 'Karyawan', 'icon' => 'mdi-card-account-details' ]); DB::table('akses_kategoris')->insert([ 'kategori' => 'Database', 'icon' => 'mdi-database' ]); } }
0.851563
1
config/plugins/wordpress/wordpress-sendgrid.php
kubanezi2/demoweb1.github.io
3
14399564
<?php /** * Configuration - Plugin: Sendgrid * @url: https://wordpress.org/plugins/sendgrid-email-delivery-simplified/ */ if (!empty(getenv('SENDGRID_USERNAME')) && !empty(getenv('SENDGRID_PASSWORD'))) { // Auth method ('credentials') define('SENDGRID_AUTH_METHOD', 'credentials'); define('SENDGRID_USERNAME', getenv('SENDGRID_USERNAME')); define('SENDGRID_PASSWORD', getenv('<PASSWORD>')); } else if (!empty(getenv('SENDGRID_API_KEY'))) { // Auth method ('apikey') define('SENDGRID_AUTH_METHOD', 'apikey'); define('SENDGRID_API_KEY', getenv('SENDGRID_API_KEY')); }
0.949219
1
library/Account/Form/UpgradeAccounts.php
shilpabharamanaik/shilpazend3Fisdap
0
14399572
<?php /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Copyright (C) 1996-2011. This is an unpublished work of * * Headwaters Software, Inc. * * ALL RIGHTS RESERVED * * This program is a trade secret of Headwaters Software, Inc. and * * it is not to be copied, distributed, reproduced, published, or * * adapted without prior authorization of Headwaters Software, Inc. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * / /** * Form for upgrading students */ /** * @package Account */ class Account_Form_UpgradeAccounts extends Fisdap_Form_Base { /** * @var array the decorators for the form */ protected static $_formDecorators = array( 'FormErrors', array('ViewScript', array('viewScript' => "forms/upgradeAccountsForm.phtml")), array('Form', array('class' => 'upgrade-accounts-form')), ); /** * @var integer */ public $configuration; /** * @var array */ public $students; /** * @param int $userId the id of the user interacting with this form * @param $options mixed additional Zend_Form options */ public function __construct($configuration = 0, $students = array(), $instructors = array(), $options = null) { $this->configuration = $configuration; $this->students = $students; parent::__construct($options); } /** * init method that adds all the elements to the form */ public function init() { parent::init(); $this->setAttrib("id", "upgrade-students-form"); $this->addJsFile("/js/library/Account/Form/upgrade-accounts.js"); $configuration = new Zend_Form_Element_Hidden("configuration"); $configuration->setDecorators(array("ViewHelper")) ->setOrder(1); $this->addElement($configuration); $this->setDecorators(self::$_formDecorators); } public function process($post) { $students = $post['studentIDs']; if (count($students) == 0) { return "Please select a student."; } $errorText = ""; foreach ($students as $studentId) { $student = \Fisdap\EntityUtils::getEntity("StudentLegacy", $studentId); if (!$post['products_' . $studentId] && !$post['downgradeProducts_' . $studentId] && !$post['reduceAttemptProducts_' . $studentId]) { if (strlen($errorText) > 1) { $errorText .= "<br />"; } $errorText .= $student->first_name . " " . $student->last_name . " does not have any products selected."; } } if (strlen($errorText) > 1) { return array('error' => $errorText, 'orderId' => null); } // get products that have multiple attempts upgradeability, this is useful for checking later $repo = \Fisdap\EntityUtils::getRepository('Product'); $productsWithAttempts = $repo->getProductsWithMoodleCourses(); $productsWithAttemptsConfig = 0; $productsWithAttemptsContexts = array(); foreach ($productsWithAttempts as $product) { $productsWithAttemptsConfig += $product->configuration; foreach ($product->moodle_quizzes as $moodleTest) { $productsWithAttemptsContexts[$moodleTest->getContext()]['products'][$product->id] = $product; if (!isset($productsWithAttemptsContexts[$moodleTest->getContext()]['contextConfig']) || (!($product->configuration & $productsWithAttemptsContexts[$moodleTest->getContext()]['contextConfig']))) { $productsWithAttemptsContexts[$moodleTest->getContext()]['contextConfig'] += $product->configuration; } } } //Create new order for upgrade $order = \Fisdap\EntityUtils::getEntity("Order"); $order->user = \Fisdap\Entity\User::getLoggedInUser(); $order->upgrade_purchase = true; $order->order_type = 1; //Loop over selected students and add the products $warningMessages = array(); foreach ($students as $studentId) { // get the products upgrade / downgrade config values $upgradeConfig = $downgradeConfig = $reduceConfig = 0; if (is_array($post['products_' . $studentId])) { $upgradeConfig = array_sum($post['products_' . $studentId]); } if (is_array($post['downgradeProducts_' . $studentId])) { $downgradeConfig = array_sum($post['downgradeProducts_' . $studentId]); } if (is_array($post['reduceAttemptProducts_' . $studentId])) { $reduceConfig = array_sum($post['reduceAttemptProducts_' . $studentId]); } // make sure we have at least one product selected for upgrade or downgrade otherwise don't add an orderConfig if ($upgradeConfig || $downgradeConfig || $reduceConfig) { $student = \Fisdap\EntityUtils::getEntity("StudentLegacy", $studentId); $serialNumber = $student->getUserContext()->getPrimarySerialNumber(); // check to see if there are any "additional moodle attempts" products in the upgrade config // if so, make sure the user has a Moodle account established in that context // (can't upgrade a moodle account that doesn't exist) if ($upgradeConfig & $productsWithAttemptsConfig) { // check for moodle ID in each matched product's context foreach ($productsWithAttemptsContexts as $context => $info) { if ($upgradeConfig & $info['contextConfig']) { $checkedIds = \Fisdap\MoodleUtils::getMoodleUserIds(array($student->user->id => $student->user->username), $context); if (!$checkedIds[$student->user->id]) { // we don't have a verified user ID in Moodle for this user in this context, // so we have to remove this context's products from the upgrade configuration $productNames = array(); $needWarning = false; foreach ($info['products'] as $product) { if ($product->configuration & $upgradeConfig & $serialNumber->configuration) { $productNames[] = $product->name; $upgradeConfig -= $product->configuration; $needWarning = true; } } if ($needWarning) { $warningMessages[] = $student->first_name . ' ' . $student->last_name . " - You cannot buy additional attempts for a student who hasn't taken the test yet.<br>"; } } } } } // check one more time for actual products to upgrade, as some may have been dropped due to the moodle account check if ($upgradeConfig || $downgradeConfig || $reduceConfig) { //Create and add order config to order $orderConfig = \Fisdap\EntityUtils::getEntity("OrderConfiguration"); $order->addOrderConfiguration($orderConfig); //Save the rest of the order config details $orderConfig->upgraded_user = $student->user; //check for a null response from getCurrentRoleData() -- user might have never logged in to set this if (is_null($student->user->getCurrentRoleData())) { //this will force a current user context to be set for the user if there isn't one already. $upgraded_user_context = $student->user->getCurrentUserContext(); } $orderConfig->configuration = $upgradeConfig; $orderConfig->downgrade_configuration = $downgradeConfig; $orderConfig->reduce_configuration = $reduceConfig; $orderConfig->certification_level = $student->user->getCurrentRoleData()->getCertification(); $orderConfig->quantity = 1; $orderConfig->calculateFinalPrice(); } } } //Add order config to order and save $order->save(); // format any warning messages if (count($warningMessages) == 0) { $warningMessages = null; } else { $warningMessages = implode(' ', $warningMessages); } return array('orderId' => $order->id, 'warning' => $warningMessages); } }
1.328125
1
resources/views/unidades/edit.blade.php
AldairMartinez234/Proyecto-tesis-Laravel
0
14399580
<div class="container"> <form action="{{route('unidades.update')}}" method="POST"> @method('PUT') @csrf <div class="modal fade" id="edit_unidades" tabindex="-1" role="dialog"> <div class="modal-dialog" data-backdrop="static"> <div class="modal-content"> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal"> <span>Cerrar</span> </button> <div class="container-fluid" style="margin: 0px 0;"> <div class="page-header"> <h3 class="text-center all-tittle">SISTEMA DE CONTROL DE OXIGENO MEDICINAL <br><small>Administración de unidade medicas</small></h3> </div> </div> <div class="text-center all-tittle">REGISTRO PARA CREAR UNA NUEVA UNIDA MEDICA</div> </div> <div class="modal-body"> <input type="hidden" name="id" id="id" value=""> <div class="form-group col-md-6"> <label>Unidad</label> <input type="text" class="form-control" id="unidad" name="unidad" data-toggle="tooltip" data-placement="top"> </div> <div class="form-group col-md-6"> <label>Nombre del responsable</label> <input id="nombre" type="text" class="form-control" name="nombre" value=""> </div> <div class="form-group col-md-6"> <label>Telefono</label> <input type="number" class="form-control" id="telefono" name="telefono" data-toggle="tooltip" data-placement="top"> </div> <div class="form-group col-md-6"> <label>Telefono (opcional)</label> <input type="number" class="form-control" id="telefono2" name="telefono2" data-toggle="tooltip" data-placement="top"> </div> <div class="form-group col-md-6"> <label>Extension</label> <input id="ext" type="number" class="form-control" name="ext" value=""> </div> <div class="form-group col-md-6"> <label>Red</label> <input id="red" type="number" class="form-control" name="red" value=""> </div> <div class="form-group col-md-6"> <label>Red (opcional)</label> <input id="red1" type="number" class="form-control" name="red1" value=""> </div> <div class="form-group col-md-6"> <label>Telefono Particular</label> <input type="number" class="form-control" id="tel_parti" name="tel_parti" data-toggle="tooltip" data-placement="top"> </div> <div class="form-group col-md-6"> <label>Telefono Particular (opcional)</label> <input type="number" class="form-control" id="tel_parti1" name="tel_parti1" data-toggle="tooltip" data-placement="top"> </div> </div> <div class="modal-footer"> <p class="text-center"> <button type="submit" class="btn btn-primary"><i class="zmdi zmdi-floppy"></i> {{ __('Guardar') }} </button> <button class="btn btn-danger" type="button" data-dismiss="modal"> <span class="glyphicon glyphicon-remove"></span>Cerrar </button> </p> </div> </form> </div> </div> </div> </div>
0.828125
1
app/Payment.php
Tootsiebrown/Sitecode
0
14399588
<?php namespace App; use App\Models\Listing; use Carbon\Carbon; use Illuminate\Database\Eloquent\Model; /** * App\Payment * * @property int $id * @property int|null $ad_id * @property int|null $user_id * @property string|null $amount * @property string|null $payment_method * @property string|null $status * @property string|null $currency * @property string|null $token_id * @property string|null $card_last4 * @property string|null $card_id * @property string|null $client_ip * @property string|null $charge_id_or_token * @property string|null $payer_email * @property string|null $description * @property string|null $local_transaction_id * @property int|null $payment_created * @property \Illuminate\Support\Carbon|null $created_at * @property \Illuminate\Support\Carbon|null $updated_at * @property-read Listing|null $ad * @property-read \App\User|null $user * @method static \Illuminate\Database\Eloquent\Builder|Payment newModelQuery() * @method static \Illuminate\Database\Eloquent\Builder|Payment newQuery() * @method static \Illuminate\Database\Eloquent\Builder|Payment query() * @mixin \Eloquent */ class Payment extends Model { protected $guarded = []; public function ad() { return $this->belongsTo(Listing::class); } public function user() { return $this->belongsTo(User::class); } public function created_at_datetime() { $created_date_time = $this->created_at->timezone(get_option('default_timezone'))->format(get_option('date_format_custom') . ' ' . get_option('time_format_custom')); return $created_date_time; } public function payment_completed_at() { $created_date_time = ''; if ($this->payment_created) { $created_date_time = Carbon::createFromTimestamp($this->payment_created, get_option('default_timezone'))->format(get_option('date_format_custom') . ' ' . get_option('time_format_custom')); } return $created_date_time; } }
1.304688
1
controllers/pages_controller.php
bedita/web-starter-kit
0
14399596
<?php class PagesController extends FrontendController { public $helpers = array('BeFront'); public $uses = array() ; /** * Load common data for all frontend pages */ protected function beditaBeforeFilter() { $this->set('feedNames', $this->Section->feedsAvailable(Configure::read('frontendAreaId'))); $this->set('sectionsTree', $this->loadSectionsTree(Configure::read('frontendAreaId'))); } /** * Before render filter */ protected function beditaBeforeRender() { // uncomment to set basic layout as default //$this->layout = 'basic'; } }
1.0625
1
resources/views/product/index.blade.php
rownakabdullahomi/ecommerce_with_laravel
0
14399604
@extends('layouts.starlight') @section('page_title') Product @endsection @section('product') active @endsection @section('content') @include('layouts.nav') <!-- ########## START: MAIN PANEL ########## --> <div class="sl-mainpanel"> <nav class="breadcrumb sl-breadcrumb"> <a class="breadcrumb-item" href="{{ url('home') }}">Dashboard</a> <span class="breadcrumb-item active">Product</span> </nav> <div class="sl-pagebody"> <div class="container"> <div class="row"> <div class="col-md-8"> <div class="card"> <div class="card-header"> Category List </div> <div class="card-body"> {{-- <div class="alert alert-success text-center"> <h4> Total Category: {{ $total_categories }} </h4> </div> --}} <table class="table table-striped"> <thead> <tr> <th scope="col">Serial No</th> <th scope="col">Product Name</th> <th scope="col">Category Name</th> <th scope="col">Product Description</th> <th scope="col">Product Price</th> <th scope="col">Product Quantity</th> <th scope="col">Product Photo</th> {{-- <th scope="col">Added By</th> <th scope="col">Created at</th> <th scope="col">Action</th> --}} </tr> </thead> @foreach ($products as $key => $product) <tbody> <tr> <th>{{ $loop->index + 1 }}</th> {{-- <td>{{ $product }}</td> --}} <td>{{ $product->product_name }}</td> <td>{{ App\Models\Category::find($product->category_id)->category_name }}</td> <td>{{ $product->product_description }}</td> <td>{{ $product->product_price }}</td> <td>{{ $product->product_quantity }}</td> <td> <img src="{{ asset('uploads/product_photos') }}/{{ $product->product_photo }}" alt="" class="w-100" "> </td> {{-- <td> {{ App\Models\User::find($product->added_by)->name }} ({{ $product->added_by }}) <br/> {{ App\Models\User::find($product->added_by)->email }} </td> <td>{{ $product->created_at }}</td> <td> <a href="{{ url('category/delete') }}/{{ $product->id }}" class="btn btn-danger btn-sm">Delete</a> </td> --}} </tr> </tbody> @endforeach </table> {{-- {{ $categories->links() }} --}} </div> </div> </div> <div class="col-md-4"> <div class="card"> <div class="card-header"> Add Product </div> <div class="card-body"> @if (session('productuploadstatus')) <div class="alert alert-success"> {{ session('productuploadstatus') }} </div> @endif <form action="{{ url('product/insert') }}" method="POST" enctype="multipart/form-data"> @csrf <div class="form-group"> <label>Category Name</label> <select class="form-control" name="category_id" id=""> <option value="">Select One</option> @foreach ($categories as $category) <option value="{{ $category->id }}">{{ $category->category_name }}</option> @endforeach </select> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Sub Category Name</label> <select class="form-control" name="sub_category_id" id=""> <option value="">Select One</option> @foreach ($subcategories as $subcategory) <option value="{{ $subcategory->id }}">{{ App\Models\Category::find($subcategory->category_id)->category_name }}-{{ $subcategory->sub_category_name }}</option> @endforeach </select> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Product Name</label> <input type="text" class="form-control" name="product_name" id=""> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Product Description</label> <textarea class="form-control" rows="4" name="product_description"></textarea> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Product Price</label> <input type="text" class="form-control" name="product_price" id=""> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Product Quantity</label> <input type="text" class="form-control" name="product_quantity" id=""> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Product Photo</label> <input type="file" class="form-control" name="product_photo" id=""> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <div class="form-group"> <label>Product Thumbnail Photos</label> <input type="file" class="form-control" name="product_thumbnail_photos[]" multiple id=""> @error('category_name') <span class="text-danger">{{ $message }}</span> @enderror </div> <button type="submit" class="btn btn-primary">Add Product</button> </form> </div> </div> @if (session('deletestatus')) <div class="alert alert-danger"> {{ session('deletestatus') }} </div> @endif </div> </div> </div> </div><!-- sl-pagebody --> </div><!-- sl-mainpanel --> <!-- ########## END: MAIN PANEL ########## --> @endsection
1.101563
1
app/Models/T_post.php
NguyenVanGiang29/Doan
0
14399612
<?php namespace App\Models; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; class T_post extends Model { use HasFactory; protected $table = 't_posts'; protected $fillable = [ 'post_id', 'tutor_id', 'subject', 'class', 'achievement', 'method', 'price', 'desc', ]; public function tutor(){ return $this->belongsTo(Tutor::class, 'tutor_id', 'id'); } public function p_offer(){ return $this->hasMany(P_offer::class, 't_post_id', 'id'); } public function p_save(){ return $this->hasMany(P_save::class, 't_post_id', 'id'); } public function t_request(){ return $this->hasMany(T_request::class, 't_post_id', 'id'); } }
1.023438
1
routes/web.php
oilstone/template-api
1
14399620
<?php use Illuminate\Support\Facades\Route; /* |-------------------------------------------------------------------------- | Web Routes |-------------------------------------------------------------------------- | | Here is where you can register web routes for your application. These | routes are loaded by the RouteServiceProvider within a group which | contains the "web" middleware group. Now create something great! | */ Route::get('/', 'Controller@home'); Route::group(['prefix' => 'monitors'], function () { Route::get('ping', 'Monitor@ping'); Route::get('status', 'Monitor@status'); Route::get('heartbeat', 'Monitor@heartbeat'); });
0.945313
1
app/views/Home/error.blade_.php
anabellchan/upload-data
0
14399628
@extends('layouts.basic') @section('headers') <style> </style> @stop @section('maincontent') <div class="container"> <div class="row"> <div class="col-lg-12 text-center"> <h2 class="section-heading">The following errors must be corrected:</h2> </div> </div> <div class="row"> <div class="col-lg-12 text-center"> <p>{{$message}}</p> </div> </div> <div class="row"> <div class="col-lg-12 text-center"> <a href="/">Back</a> </div> </div> </div> @stop
0.632813
1
database/seeds/OrderinfoTableSeeder.php
absiddique4584/online-shop
0
14399636
<?php use Illuminate\Database\Seeder; use App\Models\OrderInfo; class OrderinfoTableSeeder extends Seeder { /** * Run the database seeds. * * @return void */ public function run() { $faker = Faker\Factory::create(); foreach (range(1,20)as $index){ OrderInfo::create([ 'order_id'=>rand(1,20), 'product_id'=>rand(1,20), 'product_name'=>$faker->name, 'product_price'=>rand(100,200), 'product_qty'=>rand(1,3), ]); } } }
1
1
src/Services/PageService.php
nattreid/web-manager
0
14399644
<?php declare(strict_types=1); namespace NAttreid\WebManager\Services; use Kdyby\Translation\Translator; use NAttreid\Cms\Configurator\Configurator; use NAttreid\WebManager\IConfigurator; use NAttreid\WebManager\Model\Content\Content; use NAttreid\WebManager\Model\Orm; use NAttreid\WebManager\Model\Pages\Page; use Nette\Application\BadRequestException; use Nette\Application\Routers\Route; use Nette\Http\IResponse; use Nette\Routing\RouteList; use Nette\SmartObject; use Nextras\Dbal\UniqueConstraintViolationException; use Nextras\Orm\Collection\ICollection; use Nextras\Orm\Model\Model; /** * Sluzba obsahu manageru * * @property-read string $defaultLink * @property-read string $pageLink * @property-read string $onePageLink * * @author Attreid <<EMAIL>> */ class PageService { use SmartObject; /** @var Orm */ private $orm; /** @var string */ private $defaultLink; /** @var string */ private $pageLink; /** @var string */ private $onePageLink; /** @var string */ private $module; /** @var Translator */ private $translator; /** @var IConfigurator */ private $configurator; public function __construct(string $defaultLink, string $pageLink, string $onePageLink, string $module, Model $orm, Translator $translator, Configurator $configurator) { $this->defaultLink = $defaultLink; $this->pageLink = $pageLink; $this->onePageLink = $onePageLink; $this->module = $module; $this->orm = $orm; $this->translator = $translator; $this->configurator = $configurator; } /** * Vytvori routy * @param RouteList $routes * @param string $url */ public function createRoute(RouteList $routes, string $url): void { $this->createPageRoute($routes, $url); $this->createDefaultPageRoutes($routes, $url); } /** * Vytvori routy stranek * @param RouteList $routes * @param string $url */ public function createPageRoute(RouteList $routes, string $url): void { list($presenter, $action) = explode(':', $this->pageLink); $routes[] = new Route($url . '[<url .*>]', [ 'presenter' => $presenter, 'action' => $action, null => [ Route::FILTER_IN => function ($params) { if ($this->orm->pages->exists($params['url'])) { return $params; } return null; } ], ]); } /** * Vytvori routy defaultni stranky * @param RouteList $routes * @param string $url */ public function createDefaultPageRoutes(RouteList $routes, string $url): void { if ($this->configurator->onePage) { $routes[] = new Route($url, $this->onePageLink); $routes->addRoute($url . 'index.php', $this->onePageLink, Route::ONE_WAY); $routes[] = new Route($url . '<presenter>[/<action>]', $this->defaultLink); } else { $routes[] = new Route($url, $this->defaultLink); $routes->addRoute($url . 'index.php', $this->defaultLink, Route::ONE_WAY); $routes[] = new Route($url . '<presenter>[/<action>]', $this->defaultLink); } } /** * Vrati stranku * @param string $url * @return Page * @throws BadRequestException */ public function getPage(string $url = null): Page { $page = $this->orm->pages->getByUrl($url, $this->translator->getLocale()); if (!$page || !$page->visible) { throw new BadRequestException('', IResponse::S404_NOT_FOUND); } return $page; } /** * @return string */ protected function getDefaultLink(): string { return ':' . $this->module . ':' . $this->defaultLink; } /** * @return string */ protected function getPageLink(): string { return ':' . $this->module . ':' . $this->pageLink; } /** * @return string */ protected function getOnePageLink(): string { return ':' . $this->module . ':' . $this->onePageLink; } /** * Vrati stranky bez HP * @return Page[]|ICollection */ public function findPages(): ICollection { return $this->orm->pages->findByLocale($this->translator->getLocale()); } /** * Vrati stranky v menu * @return Page[]|ICollection */ public function findMenuPages(): ICollection { return $this->orm->pages->findMenu($this->translator->getLocale()); } /** * Vrati stranky pro onePage * @return Page[]|ICollection */ public function findOnePages(): ICollection { return $this->orm->pages->findOnePage($this->translator->getLocale()); } /** * Vrati stranky v paticce * @return Page[]|ICollection */ public function findFooterPages(): ICollection { return $this->orm->pages->findFooter($this->translator->getLocale()); } /** * Vrati text * @param string $const * @return Content * @throws UniqueConstraintViolationException */ public function getContent(string $const): Content { $locale = $this->translator->getLocale(); $content = $this->orm->content->getByConst($const, $locale); if (!$content) { $content = new Content; $this->orm->content->attach($content); $content->name = $const; $content->setLocale($locale); $content->setConst($const); $content->content = ''; $this->orm->content->persistAndFlush($content); } return $content; } }
1.359375
1
app/Http/Controllers/ProductController.php
fabiancampanaa/javierastudilloV1
0
14399652
<?php namespace App\Http\Controllers; use App\Product; use Illuminate\Http\Request; use Session; class ProductController extends Controller { /** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $products = Product::orderBy('id', 'ASC')->paginate(20); return view('Products.index', compact('products')); } /** * Show the form for creating a new resource. * * @return \Illuminate\Http\Response */ public function create() { return view('Products.create'); } /** * Store a newly created resource in storage. * * @param \Illuminate\Http\Request $request * @return \Illuminate\Http\Response */ public function store(Request $request) { $request->validate([ 'Producto' => 'required', 'Costo' => 'required', 'PrecioVenta' => 'required', ]); Product::create($request->all()); Session::flash('message','Producto Creado Correctamente'); return redirect()->route('Product.index'); } /** * Display the specified resource. * * @param \App\Product $product * @return \Illuminate\Http\Response */ public function show(Product $product) { // } /** * Show the form for editing the specified resource. * * @param \App\Product $product * @return \Illuminate\Http\Response */ public function edit($id) { $product = Product::find($id); return view('Products.modificar', compact('product')); } /** * Update the specified resource in storage. * * @param \Illuminate\Http\Request $request * @param \App\Product $product * @return \Illuminate\Http\Response */ public function update(Request $request, Product $product) { $request->validate([ 'Producto' => 'required', 'Costo' => 'required', 'PrecioVenta' => 'required', ]); $id = $request->id; $input = $request->all(); $product = Product::findOrFail($id); $product->fill($input)->save(); $product->Producto = $request->Producto; $product->Costo = $request->Costo; $product->PrecioVenta = $request->PrecioVenta; $product->save(); Session::flash('message','Producto Modificado Correctamente'); return redirect()->route('Product.index'); } /** * Remove the specified resource from storage. * * @param \App\Product $product * @return \Illuminate\Http\Response */ public function destroy($id) { $product = Product::findOrFail($id); $product->delete(); Session::flash('message','Producto Eliminado Correctamente'); return redirect()->route('Product.index'); //return view('Products.errores', compact('error')); } }
1.390625
1
temp/metadata/orm/CertificatsCenter.php
manuroot/sf22_changements
4
14399660
<?php use Doctrine\ORM\Mapping as ORM; /** * CertificatsCenter * * @ORM\Table(name="certificats_center") * @ORM\Entity */ class CertificatsCenter { /** * @var integer * * @ORM\Column(name="id", type="integer", nullable=false) * @ORM\Id * @ORM\GeneratedValue(strategy="IDENTITY") */ private $id; /** * @var string * * @ORM\Column(name="file_name", type="string", length=50, nullable=false) */ private $fileName; /** * @var string * * @ORM\Column(name="cn_name", type="string", length=50, nullable=false) */ private $cnName; /** * @var \DateTime * * @ORM\Column(name="start_date", type="date", nullable=false) */ private $startDate; /** * @var \DateTime * * @ORM\Column(name="end_time", type="date", nullable=false) */ private $endTime; /** * @var \DateTime * * @ORM\Column(name="added_date", type="date", nullable=false) */ private $addedDate; /** * @var string * * @ORM\Column(name="server_name", type="string", length=90, nullable=false) */ private $serverName; /** * @var integer * * @ORM\Column(name="port", type="integer", nullable=false) */ private $port; /** * @var string * * @ORM\Column(name="service_name", type="string", length=50, nullable=false) */ private $serviceName; /** * @var string * * @ORM\Column(name="way", type="string", length=20, nullable=false) */ private $way; /** * @var boolean * * @ORM\Column(name="status_file", type="boolean", nullable=false) */ private $statusFile; /** * @var \Projet * * @ORM\ManyToOne(targetEntity="Projet") * @ORM\JoinColumns({ * @ORM\JoinColumn(name="project", referencedColumnName="id") * }) */ private $project; /** * @var \Filetype * * @ORM\ManyToOne(targetEntity="Filetype") * @ORM\JoinColumns({ * @ORM\JoinColumn(name="type_cert", referencedColumnName="id") * }) */ private $typeCert; }
1.164063
1
application/views/layout/aside.php
eltigueeere/apuestasCodeigniter
0
14399668
<aside class="main-sidebar"> <!-- sidebar: style can be found in sidebar.less --> <section class="sidebar"> <!-- Sidebar user panel (optional) --> <div class="user-panel"> <div class="pull-left image"> <img src="<?php echo base_url('recursos/img/user.jpg');?>" class="img-circle" alt="User Image"> </div> <div class="pull-left info"> <p><?php echo $this->session->userdata('username'); ?></p> <!-- Status --> <a><i class="fa fa-circle text-success"></i> Online</a> </div> </div> <!-- Sidebar Menu --> <ul class="sidebar-menu" data-widget="tree"> <li id="li" class="checado"></li> <!-- <li class="header">MENU</li> --> <?php $this->db->select('catModulo.idAplicacion,catAplicacion.nombreAplicacion,catAplicacion.urlAplicacion,catAplicacion.icon'); $this->db->join('catModulo','catModulo.idModulo = tbPermisoUsuario.idModulo'); $this->db->join('catAplicacion','catAplicacion.idAplicacion = catModulo.idAplicacion'); $this->db->where('tbPermisoUsuario.idUsuario', $this->session->userdata('idUsuario')); $this->db->group_by('catModulo.idAplicacion'); $aplicaciones = $this->db->get('tbPermisoUsuario')->result(); foreach ($aplicaciones as $app){ if($app->idAplicacion!=1){ ?> <li class="treeview" id="<?php echo $app->urlAplicacion; ?>"> <a href="#"><i class="fa fa-<?php echo $app->icon; ?> "></i> <span><?php echo $app->nombreAplicacion; ?></span> <span class="pull-right-container"><i class="fa fa-angle-left pull-right"></i></span> </a> <ul class="treeview-menu"> <?php $this->db->select('tbPermisoUsuario.idModulo,catModulo.nombreModulo,catModulo.urlModulo,catModulo.iconModulo'); $this->db->join('catModulo','catModulo.idModulo = tbPermisoUsuario.idModulo'); $this->db->where('tbPermisoUsuario.idUsuario', $this->session->userdata('idUsuario')); $this->db->where('catModulo.idAplicacion', $app->idAplicacion); $this->db->where('tbPermisoUsuario.idStatus', 1); $this->db->group_by('tbPermisoUsuario.idModulo'); $modulos = $this->db->get('tbPermisoUsuario')->result(); foreach ($modulos as $mod){ if($mod->idModulo!=1){ ?> <li <?php if(@$mod->idModulo==@$_POST['prm']){echo 'class="active"';}?>><a onclick="recarga_<?php echo $mod->idModulo;?>();" style="cursor:pointer;"><i class="fa fa-<?php echo $mod->iconModulo; ?>"></i> <span><?php echo $mod->nombreModulo; ?></span></a></li> <form name="frm-<?php echo $mod->idModulo;?>" method="post" action="<?php echo base_url($app->urlAplicacion.'/'.$mod->urlModulo)?>"> <input type="hidden" name="prm" value="<?php echo $mod->idModulo;?>"> </form> <script type="text/javascript"> function recarga_<?php echo $mod->idModulo;?>(){ document.forms["frm-<?php echo $mod->idModulo;?>"].submit(); } </script> <?php }} ?> </ul> </li> <?php }} ?> </ul> <!-- /.sidebar-menu --> </section> <!-- /.sidebar --> </aside>
1.085938
1
resources/views/charts/top.blade.php
Jenishls/ITSupport
0
14399676
<div class="col-sm-12 col-md-12 col-lg-4"> <div class="m-portlet m-portlet m-portlet--border-bottom-brand "> <div class="m-portlet__body"> <div class="m-widget26"> <div class="m-widget26__number"> <span class="m-widget17__icon"> <i class="flaticon-time m--font-danger"></i> </span> {{$ticket->count()}} <small>Total Tickets</small> </div> </div> </div> </div> </div> <div class="col-sm-12 col-md-12 col-lg-4"> <div class="m-portlet m-portlet m-portlet--border-bottom-danger "> <div class="m-portlet__body"> <div class="m-widget26"> <div class="m-widget26__number"> <span class="m-widget26__icon"> </span> <i class="flaticon-pie-chart m--font-danger"></i> {{$ticket->where('status','<>','Closed')->count()}} <small>Open Tickets</small> </div> </div> </div> </div> </div> <div class="col-sm-12 col-md-12 col-lg-4"> <div class="m-portlet m-portlet m-portlet--border-bottom-success "> <div class="m-portlet__body"> <div class="m-widget26"> <div class="m-widget26__number"> <span class="m-widget17__icon"> <i class="flaticon-paper-plane m--font-info"></i> </span> {{$ticket->where('status','Closed')->count()}} <small>Closed Tickets</small> </div> </div> </div> </div> </div> </div>
0.527344
1
app/AtaquesSeguimientos.php
alka653/pepper
1
14399684
<?php namespace App; use Illuminate\Database\Eloquent\Model; class AtaquesSeguimientos extends Model{ protected $guarded = []; public $timestamps = false; public static function getTipo($tipo){ switch($tipo){ case 'V': $tipo = 'Victima'; break; case 'A': $tipo = 'Atacante'; break; } return $tipo; } public static function saveData($data){ $data['fecha'] = date('Y-m-d', strtotime($data['fecha'])); return AtaquesSeguimientos::create($data); } public static function updateData($request){ $ataque_seguimiento = AtaquesSeguimientos::find($request->seguimiento); $ataque_seguimiento->descripcion = $request->descripcion; $ataque_seguimiento->tipo = $request->tipo; $ataque_seguimiento->fecha = date('Y-m-d', strtotime($request->fecha)); $ataque_seguimiento->save(); return $ataque_seguimiento; } }
1.21875
1
website/app/CPU.php
albuszheng/OnlineCOMParts
0
14399692
<?php namespace App; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Facades\DB; class CPU extends Model { /** * The table associated with the model. * * @var string */ protected $table = 'CPU'; protected $primaryKey = 'Name'; /** * Indicates if the model should be timestamped. * * @var bool */ public $timestamps = false; public static function getCPU() { $CPU = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') // ->join('inventory', 'inventory.ProductID', '=', 'products.id') // ->join('store', 'store.id', '=', 'inventory.StoreID') ->get(); return $CPU; } public static function getCPUByName($name) { $CPU = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->where('Name', 'like', $name) ->get(); return $CPU; } public static function getCPUByManufacturer($manufacturerList) { $CPUs = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->whereIn('Manufacturer', $manufacturerList) ->get(); return $CPUs; } public static function getCPUBySeries($series) { $query = "%".$series."%"; $CPUs = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->where('Name', 'like', $query) ->get(); return $CPUs; } public static function getCPUByCoreNum($coreNumMin, $coreNumMax) { $CPUs = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->where('Cores', '>=', $coreNumMin) ->where('Cores', '<=', $coreNumMax) ->get(); return $CPUs; } public static function getCPUBySpeed($speedMin, $speedMax) { $CPUs = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->where('OperatingFrenquency', '>=', $speedMin) ->where('OperatingFrenquency', '<=', $speedMax) ->get(); return $CPUs; } public static function getCPUByPower($powerMin, $powerMax) { $CPUs = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->where('ThermalDesignPower', '>=', $powerMin) ->where('ThermalDesignPower', '<=', $powerMax) ->get(); return $CPUs; } public static function getCPUByPrice($priceMin, $priceMax) { $CPUs = DB::table('CPU') ->join('products', 'products.ProductName', '=', 'CPU.Name') ->where('products.ProductName', '>=', $priceMin) ->where('products.ProductName', '<=', $priceMax) ->get(); return $CPUs; } public function product() { return $this->hasMany(Product::class, 'Name', 'ProductName'); } }
1.5625
2
logout.php
Fmendescn/DasboardEstatistico
0
14399700
<?php // Inicia sessões, para assim poder destruí-las session_start(); session_destroy(); header("Location: cadastro.html"); ?>
0.145508
0
html/class/commentrenderer.php
nao-pon/legacy
1
14399708
<?php // $Id: commentrenderer.php,v 1.1 2007/05/15 02:34:21 minahito Exp $ // ------------------------------------------------------------------------ // // XOOPS - PHP Content Management System // // Copyright (c) 2000 XOOPS.org // // <http://www.xoops.org/> // // ------------------------------------------------------------------------ // // This program is free software; you can redistribute it and/or modify // // it under the terms of the GNU General Public License as published by // // the Free Software Foundation; either version 2 of the License, or // // (at your option) any later version. // // // // You may not change or alter any portion of this comment or credits // // of supporting developers from this source code or any supporting // // source code which is considered copyrighted (c) material of the // // original comment or credit authors. // // // // This program is distributed in the hope that it will be useful, // // but WITHOUT ANY WARRANTY; without even the implied warranty of // // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // // GNU General Public License for more details. // // // // You should have received a copy of the GNU General Public License // // along with this program; if not, write to the Free Software // // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // // ------------------------------------------------------------------------ // // Author: <NAME> (AKA onokazu) // // URL: http://www.xoops.org/ http://jp.xoops.org/ http://www.myweb.ne.jp/ // // Project: The XOOPS Project (http://www.xoops.org/) // // ------------------------------------------------------------------------- // /** * Display comments * * @package kernel * @subpackage comment * * @author <NAME> <<EMAIL>> * @copyright (c) 2000-2003 The Xoops Project - www.xoops.org */ class XoopsCommentRenderer { /**#@+ * @access private */ var $_tpl; var $_comments = null; var $_useIcons = true; var $_doIconCheck = false; var $_memberHandler; var $_statusText; /**#@-*/ /** * Constructor * * @param object &$tpl * @param boolean $use_icons * @param boolean $do_iconcheck **/ function XoopsCommentRenderer(&$tpl, $use_icons = true, $do_iconcheck = false) { $this->_tpl =& $tpl; $this->_useIcons = $use_icons; $this->_doIconCheck = $do_iconcheck; $this->_memberHandler =& xoops_gethandler('member'); $this->_statusText = array(XOOPS_COMMENT_PENDING => '<span style="text-decoration: none; font-weight: bold; color: #00ff00;">'._CM_PENDING.'</span>', XOOPS_COMMENT_ACTIVE => '<span style="text-decoration: none; font-weight: bold; color: #ff0000;">'._CM_ACTIVE.'</span>', XOOPS_COMMENT_HIDDEN => '<span style="text-decoration: none; font-weight: bold; color: #0000ff;">'._CM_HIDDEN.'</span>'); } /** * Access the only instance of this class * * @param object $tpl reference to a {@link Smarty} object * @param boolean $use_icons * @param boolean $do_iconcheck * @return **/ function &instance(&$tpl, $use_icons = true, $do_iconcheck = false) { static $instance; if (!isset($instance)) { $instance = new XoopsCommentRenderer($tpl, $use_icons, $do_iconcheck); } return $instance; } /** * Accessor * * @param object &$comments_arr array of {@link XoopsComment} objects **/ function setComments(&$comments_arr) { if (isset($this->_comments)) { unset($this->_comments); } $this->_comments =& $comments_arr; } /** * Render the comments in flat view * * @param boolean $admin_view **/ function renderFlatView($admin_view = false) { $count = count($this->_comments); for ($i = 0; $i < $count; $i++) { if (false != $this->_useIcons) { $title = $this->_getTitleIcon($this->_comments[$i]->getVar('com_icon')).'&nbsp;'.$this->_comments[$i]->getVar('com_title'); } else { $title = $this->_comments[$i]->getVar('com_title'); } $poster = $this->_getPosterArray($this->_comments[$i]->getVar('com_uid')); if (false != $admin_view) { $text = $this->_comments[$i]->getVar('com_text').'<div style="text-align:right; margin-top: 2px; margin-bottom: 0px; margin-right: 2px;">'._CM_STATUS.': '.$this->_statusText[$this->_comments[$i]->getVar('com_status')].'<br />IP: <span style="font-weight: bold;">'.$this->_comments[$i]->getVar('com_ip').'</span></div>'; } else { // hide comments that are not active if (XOOPS_COMMENT_ACTIVE != $this->_comments[$i]->getVar('com_status')) { continue; } else { $text = $this->_comments[$i]->getVar('com_text'); } } $this->_tpl->append('comments', array('id' => $this->_comments[$i]->getVar('com_id'), 'title' => $title, 'text' => $text, 'date_posted' => formatTimestamp($this->_comments[$i]->getVar('com_created'), 'm'), 'date_modified' => formatTimestamp($this->_comments[$i]->getVar('com_modified'), 'm'), 'poster' => $poster)); } } /** * Render the comments in thread view * * This method calls itself recursively * * @param integer $comment_id Should be "0" when called by client * @param boolean $admin_view * @param boolean $show_nav **/ function renderThreadView($comment_id = 0, $admin_view = false, $show_nav = true) { include_once XOOPS_ROOT_PATH.'/class/tree.php'; // construct comment tree $xot = new XoopsObjectTree($this->_comments, 'com_id', 'com_pid', 'com_rootid'); $tree =& $xot->getTree(); if (false != $this->_useIcons) { $title = $this->_getTitleIcon($tree[$comment_id]['obj']->getVar('com_icon')).'&nbsp;'.$tree[$comment_id]['obj']->getVar('com_title'); } else { $title = $tree[$comment_id]['obj']->getVar('com_title'); } if (false != $show_nav && $tree[$comment_id]['obj']->getVar('com_pid') != 0) { $this->_tpl->assign('lang_top', _CM_TOP); $this->_tpl->assign('lang_parent', _CM_PARENT); $this->_tpl->assign('show_threadnav', true); } else { $this->_tpl->assign('show_threadnav', false); } if (false != $admin_view) { // admins can see all $text = $tree[$comment_id]['obj']->getVar('com_text').'<div style="text-align:right; margin-top: 2px; margin-bottom: 0px; margin-right: 2px;">'._CM_STATUS.': '.$this->_statusText[$tree[$comment_id]['obj']->getVar('com_status')].'<br />IP: <span style="font-weight: bold;">'.$tree[$comment_id]['obj']->getVar('com_ip').'</span></div>'; } else { // hide comments that are not active if (XOOPS_COMMENT_ACTIVE != $tree[$comment_id]['obj']->getVar('com_status')) { // if there are any child comments, display them as root comments if (isset($tree[$comment_id]['child']) && !empty($tree[$comment_id]['child'])) { foreach ($tree[$comment_id]['child'] as $child_id) { $this->renderThreadView($child_id, $admin_view, false); } } return; } else { $text = $tree[$comment_id]['obj']->getVar('com_text'); } } $replies = array(); $this->_renderThreadReplies($tree, $comment_id, $replies, '&nbsp;&nbsp;', $admin_view); $show_replies = (count($replies) > 0) ? true : false; $this->_tpl->append('comments', array('pid' => $tree[$comment_id]['obj']->getVar('com_pid'), 'id' => $tree[$comment_id]['obj']->getVar('com_id'), 'itemid' => $tree[$comment_id]['obj']->getVar('com_itemid'), 'rootid' => $tree[$comment_id]['obj']->getVar('com_rootid'), 'title' => $title, 'text' => $text, 'date_posted' => formatTimestamp($tree[$comment_id]['obj']->getVar('com_created'), 'm'), 'date_modified' => formatTimestamp($tree[$comment_id]['obj']->getVar('com_modified'), 'm'), 'poster' => $this->_getPosterArray($tree[$comment_id]['obj']->getVar('com_uid')), 'replies' => $replies, 'show_replies' => $show_replies)); } /** * Render replies to a thread * * @param array &$thread * @param int $key * @param array $replies * @param string $prefix * @param bool $admin_view * @param integer $depth * @param string $current_prefix * * @access private **/ function _renderThreadReplies(&$thread, $key, &$replies, $prefix, $admin_view, $depth = 0, $current_prefix = '') { if ($depth > 0) { if (false != $this->_useIcons) { $title = $this->_getTitleIcon($thread[$key]['obj']->getVar('com_icon')).'&nbsp;'.$thread[$key]['obj']->getVar('com_title'); } else { $title = $thread[$key]['obj']->getVar('com_title'); } $title = (false != $admin_view) ? $title.' '.$this->_statusText[$thread[$key]['obj']->getVar('com_status')] : $title; $replies[] = array('id' => $key, 'prefix' => $current_prefix, 'date_posted' => formatTimestamp($thread[$key]['obj']->getVar('com_created'), 'm'), 'title' => $title, 'root_id' => $thread[$key]['obj']->getVar('com_rootid'), 'status' => $this->_statusText[$thread[$key]['obj']->getVar('com_status')], 'poster' => $this->_getPosterName($thread[$key]['obj']->getVar('com_uid'))); $current_prefix .= $prefix; } if (isset($thread[$key]['child']) && !empty($thread[$key]['child'])) { $depth++; foreach ($thread[$key]['child'] as $childkey) { if (!$admin_view && $thread[$childkey]['obj']->getVar('com_status') != XOOPS_COMMENT_ACTIVE) { // skip this comment if it is not active and continue on processing its child comments instead if (isset($thread[$childkey]['child']) && !empty($thread[$childkey]['child'])) { foreach ($thread[$childkey]['child'] as $childchildkey) { $this->_renderThreadReplies($thread, $childchildkey, $replies, $prefix, $admin_view, $depth); } } } else { $this->_renderThreadReplies($thread, $childkey, $replies, $prefix, $admin_view, $depth, $current_prefix); } } } } /** * Render comments in nested view * * Danger: Recursive! * * @param integer $comment_id Always "0" when called by client. * @param boolean $admin_view **/ function renderNestView($comment_id = 0, $admin_view = false) { include_once XOOPS_ROOT_PATH.'/class/tree.php'; $xot = new XoopsObjectTree($this->_comments, 'com_id', 'com_pid', 'com_rootid'); $tree =& $xot->getTree(); if (false != $this->_useIcons) { $title = $this->_getTitleIcon($tree[$comment_id]['obj']->getVar('com_icon')).'&nbsp;'.$tree[$comment_id]['obj']->getVar('com_title'); } else { $title = $tree[$comment_id]['obj']->getVar('com_title'); } if (false != $admin_view) { $text = $tree[$comment_id]['obj']->getVar('com_text').'<div style="text-align:right; margin-top: 2px; margin-bottom: 0px; margin-right: 2px;">'._CM_STATUS.': '.$this->_statusText[$tree[$comment_id]['obj']->getVar('com_status')].'<br />IP: <span style="font-weight: bold;">'.$tree[$comment_id]['obj']->getVar('com_ip').'</span></div>'; } else { // skip this comment if it is not active and continue on processing its child comments instead if (XOOPS_COMMENT_ACTIVE != $tree[$comment_id]['obj']->getVar('com_status')) { // if there are any child comments, display them as root comments if (isset($tree[$comment_id]['child']) && !empty($tree[$comment_id]['child'])) { foreach ($tree[$comment_id]['child'] as $child_id) { $this->renderNestView($child_id, $admin_view); } } return; } else { $text = $tree[$comment_id]['obj']->getVar('com_text'); } } $replies = array(); $this->_renderNestReplies($tree, $comment_id, $replies, 25, $admin_view); $this->_tpl->append('comments', array('pid' => $tree[$comment_id]['obj']->getVar('com_pid'), 'id' => $tree[$comment_id]['obj']->getVar('com_id'), 'itemid' => $tree[$comment_id]['obj']->getVar('com_itemid'), 'rootid' => $tree[$comment_id]['obj']->getVar('com_rootid'), 'title' => $title, 'text' => $text, 'date_posted' => formatTimestamp($tree[$comment_id]['obj']->getVar('com_created'), 'm'), 'date_modified' => formatTimestamp($tree[$comment_id]['obj']->getVar('com_modified'), 'm'), 'poster' => $this->_getPosterArray($tree[$comment_id]['obj']->getVar('com_uid')), 'replies' => $replies)); } /** * Render replies in nested view * * @param array $thread * @param int $key * @param array $replies * @param string $prefix * @param bool $admin_view * @param integer $depth * * @access private **/ function _renderNestReplies(&$thread, $key, &$replies, $prefix, $admin_view, $depth = 0) { if ($depth > 0) { if (false != $this->_useIcons) { $title = $this->_getTitleIcon($thread[$key]['obj']->getVar('com_icon')).'&nbsp;'.$thread[$key]['obj']->getVar('com_title'); } else { $title = $thread[$key]['obj']->getVar('com_title'); } $text = (false != $admin_view) ? $thread[$key]['obj']->getVar('com_text').'<div style="text-align:right; margin-top: 2px; margin-right: 2px;">'._CM_STATUS.': '.$this->_statusText[$thread[$key]['obj']->getVar('com_status')].'<br />IP: <span style="font-weight: bold;">'.$thread[$key]['obj']->getVar('com_ip').'</span></div>' : $thread[$key]['obj']->getVar('com_text'); $replies[] = array('id' => $key, 'prefix' => $prefix, 'pid' => $thread[$key]['obj']->getVar('com_pid'), 'itemid' => $thread[$key]['obj']->getVar('com_itemid'), 'rootid' => $thread[$key]['obj']->getVar('com_rootid'), 'title' => $title, 'text' => $text, 'date_posted' => formatTimestamp($thread[$key]['obj']->getVar('com_created'), 'm'), 'date_modified' => formatTimestamp($thread[$key]['obj']->getVar('com_modified'), 'm'), 'poster' => $this->_getPosterArray($thread[$key]['obj']->getVar('com_uid'))); $prefix = $prefix + 25; } if (isset($thread[$key]['child']) && !empty($thread[$key]['child'])) { $depth++; foreach ($thread[$key]['child'] as $childkey) { if (!$admin_view && $thread[$childkey]['obj']->getVar('com_status') != XOOPS_COMMENT_ACTIVE) { // skip this comment if it is not active and continue on processing its child comments instead if (isset($thread[$childkey]['child']) && !empty($thread[$childkey]['child'])) { foreach ($thread[$childkey]['child'] as $childchildkey) { $this->_renderNestReplies($thread, $childchildkey, $replies, $prefix, $admin_view, $depth); } } } else { $this->_renderNestReplies($thread, $childkey, $replies, $prefix, $admin_view, $depth); } } } } /** * Get the name of the poster * * @param int $poster_id * @return string * * @access private **/ function _getPosterName($poster_id) { $poster['id'] = intval($poster_id); if ($poster['id'] > 0) { $com_poster =& $this->_memberHandler->getUser($poster_id); if (is_object($com_poster)) { $poster['uname'] = '<a href="'.XOOPS_URL.'/userinfo.php?uid='.$poster['id'].'">'.$com_poster->getVar('uname').'</a>'; return $poster; } } $poster['id'] = 0; // to cope with deleted user accounts $poster['uname'] = $GLOBALS['xoopsConfig']['anonymous']; return $poster; } /** * Get an array with info about the poster * * @param int $poster_id * @return array * * @access private **/ function _getPosterArray($poster_id) { $poster['id'] = intval($poster_id); if ($poster['id'] > 0) { $com_poster =& $this->_memberHandler->getUser($poster['id']); if (is_object($com_poster)) { $poster['uname'] = '<a href="'.XOOPS_URL.'/userinfo.php?uid='.$poster['id'].'">'.$com_poster->getVar('uname').'</a>'; $poster_rank = $com_poster->rank(); $poster['rank_image'] = ($poster_rank['image'] != '') ? $poster_rank['image'] : 'blank.gif'; $poster['rank_title'] = $poster_rank['title']; $poster['avatar'] = $com_poster->getVar('user_avatar'); $poster['regdate'] = formatTimestamp($com_poster->getVar('user_regdate'), 's'); $poster['from'] = $com_poster->getVar('user_from'); $poster['postnum'] = $com_poster->getVar('posts'); $poster['status'] = $com_poster->isOnline() ? _CM_ONLINE : ''; return $poster; } } $poster['id'] = 0; // to cope with deleted user accounts $poster['uname'] = $GLOBALS['xoopsConfig']['anonymous']; $poster['rank_title'] = ''; $poster['avatar'] = 'blank.gif'; $poster['regdate'] = ''; $poster['from'] = ''; $poster['postnum'] = 0; $poster['status'] = ''; return $poster; } /** * Get the IMG tag for the title icon * * @param string $icon_image * @return string HTML IMG tag * * @access private **/ function _getTitleIcon($icon_image) { $icon_image = trim($icon_image); if ($icon_image != '') { $icon_image = htmlspecialchars($icon_image); if (false != $this->_doIconCheck) { if (!file_exists(XOOPS_URL.'/images/subject/'.$icon_image)) { return '<img src="'.XOOPS_URL.'/images/icons/no_posticon.gif" alt="" />'; } else { return '<img src="'.XOOPS_URL.'/images/subject/'.$icon_image.'" alt="" />'; } } else { return '<img src="'.XOOPS_URL.'/images/subject/'.$icon_image.'" alt="" />'; } } return '<img src="'.XOOPS_URL.'/images/icons/no_posticon.gif" alt="" />'; } } ?>
1.210938
1
app/Models/Food.php
shaimz/calculator
0
14399716
<?php namespace App\Models; use Illuminate\Database\Eloquent\Model; class Food extends Model { public $timestamps = false; protected $table = 'food'; public function data(){ return $this->belongsTo(Food::class,'id','food_id'); } public function group(){ return $this->hasOne(Group::class,'id','group_id'); } }
0.839844
1
resources/views/akses/edit.blade.php
aslamtea/blog
0
14399724
@extends('layouts/header') @section('judul', 'aslam tampan') @section('container') <!-- page content --> <div class="right_col" role="main"> <!-- top tiles --> <div class="row"> <div class="col-8"> <h1 class="mt-3"> robah</h1> <div class="card-body"> <form action="/akses/{{$akses->id}}" method="post" enctype="multipart/form-data"> @method('patch') @csrf <div class="form-group"> <label for="role_id">role</label> <input type="text" name="role_id" id="role_id" class="form-control @error('role_id') is-invalid @enderror" placeholder="role_id" value="{{$akses->role_id}}"> @error('role_id') <div class="invalid-feedback"> {{$message}} </div> @enderror </div> <div class="form-group"> <label for="menu_id">menu id</label> <input type="text" name="menu_id" id="menu_id" class="form-control @error('menu_id') is-invalid @enderror" placeholder="menu_id" value="{{$akses->menu_id}}"> @error('menu_id') <div class="invalid-feedback"> {{$message}} </div> @enderror </div> <button type="submit" class="btn btn-primary float-right">robah Data</button> </form> </div> </div> <!-- /page content --> @endsection
1.1875
1
src/Adapter/NullAdapter.php
mjrider/mjrider-flysystemfctory
4
14399732
<?php namespace MJRider\FlysystemFactory\Adapter; use League\Flysystem\Adapter\NullAdapter as FL; /** * Static factory class for creating a null Adapter */ class NullAdapter implements AdapterFactoryInterface { /** * @inheritDoc */ public static function create($url) { $adapter = new FL(); return $adapter; } }
0.960938
1
resources/views/home.blade.php
Almad0/laravel-boolean
0
14399740
@extends('layout.app') @section('headTitle') Home @endsection @section('main') <h1>Home Page</h1> @endsection
0.470703
0
database/factories/ScholarshipRequirementItemFactory.php
RhannelD/fams
0
14399748
<?php namespace Database\Factories; use App\Models\ScholarshipRequirementItem; use Illuminate\Database\Eloquent\Factories\Factory; use Illuminate\Support\Arr; class ScholarshipRequirementItemFactory extends Factory { /** * The name of the factory's corresponding model. * * @var string */ protected $model = ScholarshipRequirementItem::class; /** * Define the model's default state. * * @return array */ public function definition() { $types = ['question', 'question', 'file', 'file', 'file', 'radio', 'check']; return [ 'requirement_id' => 1, 'item' => $this->faker->sentence($nbWords = 4, $variableNbWords = true), 'type' => Arr::random($types), 'note' => $this->faker->sentence($nbWords = 10, $variableNbWords = true), 'position' => 1, ]; } }
1.25
1
common/func/FilterFunc.php
ChenXinGuang1003/KGhrms
0
14399756
<?php /** * Created by PhpStorm. * User: admin * Date: 2016/9/11 * Time: 8:37 */ namespace common\func; use common\models\Edu; use common\models\Persons; use common\models\PostKey; use Yii; use common\models\Level; use common\models\Posts; use backend\models\Role; class FilterFunc { public static function transLevel($id){ return Level::find()->where(['level_id'=>$id])->one()->level_name; } public static function transRole($id){ return Role::find()->where(['role_id'=>$id])->one()->role_name; } public static function transPost($id){ if($id){ return Posts::find()->where(['post_id'=>$id])->one()->post_name; }else{ return ''; } } public static function transEdu($id){ return Edu::find()->where(['edu_id'=>$id])->one()->edu_name; } public static function transIsKey($post,$card_no){ $is_key = PostKey::find()->where(['post_id'=>$post,'key_no'=>$card_no])->one(); return count($is_key)>0 ? '在岗': '储备'; } public static function transCardNo($card_no){ return Persons::find()->where(['card_no'=>$card_no])->one()->name; } const DATE_FORMAT = 'php:Y-m-d'; const DATETIME_FORMAT = 'php:Y-m-d H:i:s'; const TIME_FORMAT = 'php:H:i:s'; public static function convert($dateStr, $type='date', $format = null) { if ($type === 'datetime') { $fmt = ($format == null) ? self::DATETIME_FORMAT : $format; } elseif ($type === 'time') { $fmt = ($format == null) ? self::TIME_FORMAT : $format; } else { $fmt = ($format == null) ? self::DATE_FORMAT : $format; } return Yii::$app->formatter->asDate($dateStr, $fmt); } }
1.304688
1
src/Base/Lancamentos/ContaReceberCancelarRecebimento.php
glauberportella/omie-php-sdk
0
14399764
<?php namespace Omie\Base\Lancamentos; /** * Requisição de cancelamento de lançamento de baixa do recebimento. * * @pw_element integer $codigo_baixa Código da baixa do contas a receber no Omie. * @pw_element string $codigo_baixa_integracao Código da baixa do integrador para identificar a baixa do título do contas a receber. * @pw_complex conta_receber_cancelar_recebimento */ class ContaReceberCancelarRecebimento { /** * Código da baixa do contas a receber no Omie. * * @var integer */ public $codigo_baixa; /** * Código da baixa do integrador para identificar a baixa do título do contas a receber. * * @var string */ public $codigo_baixa_integracao; }
0.71875
1
application/views/family/login.php
iamuchejude/ssppbaruwa2
1
14399772
<div class="form-area-header"> <h1>Login</h1> <p>Fill the form below to login to your family's account</p> </div> <form action="<?= base_url() ?>auth/family_login" method="post"> <?php if($this->session->flashdata('login_message') !== null) { ?> <p class="flashdata <?= $this->session->flashdata('login_message')['code']; ?>"><?= $this->session->flashdata('login_message')['msg']; ?></p> <?php } ?> <div class="row one clear"> <div class="input-group"> <label>Family Name</label> <input type="text" name="family_name" value="<?= set_value('family_name') ?>" required placeholder="Family Name"> </div> </div> <div class="row one clear"> <div class="input-group"> <label>Passkey</label> <input type="password" name="family_passkey" required placeholder="<PASSWORD>key"> </div> </div> <button class="full" type="submit">Login</button> </form> <div class="clear" style="padding: 10px 0; text-align: center; margin-top: 30px;"> <p>Don't have an account? <a href="<?= base_url() ?>family/register">Register now</a></p> <p>Forgot Password? <a href="<?= base_url() ?>family/recover">Recover</a></p> </div>
0.859375
1
app/Sewa.php
MichaelKevinAdinata27RPL/web-admin-rental-mobil
0
14399780
<?php namespace App; use Illuminate\Database\Eloquent\Model; class Sewa extends Model { protected $table = "sewa"; protected $primaryKey = "id_sewa"; protected $fillable = ["id_sewa", "id_mobil", "id_karyawan", "id_pelanggan", "tgl_sewa", "tgl_kembali", "total_bayar"]; public $incrementing = false; //agar primary key dapat diisi char public function karyawan() { return $this->belongsTo("App\Karyawan", "id_karyawan"); } public function pelanggan() { return $this->belongsTo("App\Pelanggan", "id_pelanggan"); } public function mobil() { return $this->belongsTo("App\Mobil", "id_mobil"); } }
0.953125
1
fusionforge/www/index_std.php
simtk/src
0
14399788
<?php /** * * index_std.php * * File to display front page. * * Copyright 2005-2019, SimTK Team * * This file is part of the SimTK web portal originating from * Simbios, the NIH National Center for Physics-Based * Simulation of Biological Structures at Stanford University, * funded under the NIH Roadmap for Medical Research, grant * U54 GM072970, with continued maintenance and enhancement * funded under NIH grants R01 GM107340 & R01 GM104139, and * the U.S. Army Medical Research & Material Command award * W81XWH-15-1-0232R01. * * SimTK is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as * published by the Free Software Foundation, either version 3 of * the License, or (at your option) any later version. * * SimTK is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public * License along with SimTK. If not, see * <http://www.gnu.org/licenses/>. */ require_once $gfcommon.'include/FusionForge.class.php'; require_once $gfcommon.'include/tag_cloud.php'; require_once $gfcommon.'include/Stats.class.php'; require_once $gfwww.'include/forum_db_utils.php'; ?> <style> .project_representation>.wrapper_text>h4>a { font-size: 20px; } .project_representation>.wrapper_text>.type { color: rgb(94,150,225); font-size: 14px; } .project_representation>.wrapper_text>.content { color: rgb(167,167,167);; font-size: 14px; } </style> <div class='row'> <div class='home_page_header'> <div class='left_container'> <div class='home_page_descr'> <p>Enabling groundbreaking biomedical research via open access to high-quality simulation tools, accurate models, and the people behind them. </p> </div> </div> <div class='right_container'> <div class='home_page_info'> <?php $ff = new FusionForge(); echo $ff->getNumberOfHostedProjects(); ?> <a href="/search/search.php?srch=&search=search&type_of_search=soft&sort=downloads&page=0&">projects</a><br/> <?php echo $ff->getTotalDownloads(); // echo '&nbsp;<a href="#">downloads</a><br/>'; echo '&nbsp;downloads<br/>'; echo $ff->getNumberOfActiveUsers(); echo '&nbsp;members<br/>'; // echo '&nbsp;<a href="#">members</a><br/>'; ?> <div class="btn-ctabox"><a class="btn-cta" href='account/register.php'>Join Us</a></div> </div> </div> </div> </div> <div class='projects_slideshow'> <div class='projects_slide'> <div id="carousel-example-generic" class="carousel slide" data-ride="carousel"> <!-- Wrapper for slides --> <div class="carousel-inner" role="listbox"> <div class="item active"> <img src="images/featuredProjects/dummy1.jpg" alt="Dummy1"> <div class="carousel-caption"> <a href="/projects/dummy1"><H2>Dummy1</H2></a> <p>Dummy1... <a href="/projects/dummy1">Learn more</a> </p> </div> </div> <div class="item"> <img src="images/featuredProjects/dummy2.jpg" alt="Dummy2"> <div class="carousel-caption"> <a href="/projects/dummy2"><H2>Dummy2</H2></a> <p>Dummy2... <a href="/projects/dummy2">Learn more</a> </p> </div> </div> </div> <!-- Controls --> <a class="left carousel-control" href="#carousel-example-generic" role="button" data-slide="prev"> <div class="simtk_carousel_arrow left" aria-hidden="true"></div> <span class="sr-only">Previous</span> </a> <a class="right carousel-control" href="#carousel-example-generic" role="button" data-slide="next"> <div class="simtk_carousel_arrow right" aria-hidden="true"></div> <span class="sr-only">Next</span> </a> </div> </div> </div> <?php $arrProjLink = array(); $arrLogo = array(); $arrSummary = array(); $arrValue = array(); // Get top downloads in past week. $ff->getTopDownloadProjects($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15); /* // Get most active stats. $ff->getMostActiveProjects($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15); */ // Get projects with recent forum posts. $arrGroupIds = getMostForumPostsProjects($arrNumPosts); $ff->getMostForumPostsProjects($arrProjLink, $arrLogo, $arrValue, $arrSummary, $arrGroupIds, $arrNumPosts, 15); // Get projects with new download files. $ff->getProjectsNewDownloadFiles($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15); // Get projects with most total followers. $ff->getNumFollowersProjects($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15); // Get projects with most new followers (in the last week). $ff->getNumFollowersProjects($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15, 7); // Get projects with most new members (in the last week). $ff->getProjectsNewMembers($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15); // Get top total downloads. $ff->getTopTotalDownloadProjects($arrProjLink, $arrLogo, $arrValue, $arrSummary, 15); ?> <div class='news_and_trending_projects'> <div class='two_third_col'> <h2>Trending Projects</h2> <?php // Randomize keys and pick 15 only from the associative array. // Get the keys. $keys = array_keys($arrProjLink); // Randomize keys. shuffle($keys); $cntKeys = 0; foreach ($keys as $unixGroupName) { $cntKeys++; if ($cntKeys > 15) { // Done. break; } ?> <div class="project_representation"> <div class="wrapper_img"> <a href="/projects/<?php echo $unixGroupName; ?>"> <img onError="this.onerror=null;this.src='/logos/_thumb';" alt="Image not available" src="/logos/<?php if (!empty($arrLogo[$unixGroupName])) { echo $arrLogo[$unixGroupName]; } else { // No logo specified. Use a default. echo "_thumb"; } ?>"/> </a> </div> <div class="wrapper_text"> <h4><?php echo $arrProjLink[$unixGroupName]; ?></h4> <?php echo wordwrap($arrSummary[$unixGroupName], 50, "<br/>\n", true); ?><br/> <?php $theValues = $arrValue[$unixGroupName]; for ($cnt = 0; $cnt < count($theValues); $cnt++) { ?> <?php echo $theValues[$cnt]; ?><br/> <?php } ?> </div> </div> <?php } ?> </div> <div class='one_third_col'> <div class='module_category'> <h2>By Category</h2> <div class='item_category'> <span class='category_header'>Biological applications</span> <ul> <li><a href="/category/category.php?cat=309&sort=date&page=0&srch=&">Cardiovascular system</a></li> <li><a href="/category/category.php?cat=421&sort=date&page=0&srch=&">Cell</a></li> <li><a href="/category/category.php?cat=308&sort=date&page=0&srch=&">Myosin</a></li> <li><a href="/category/category.php?cat=310&sort=date&page=0&srch=&">Neuromuscular system</a></li> <li><a href="/category/category.php?cat=406&sort=date&page=0&srch=&">Protein</a></li> <li><a href="/category/category.php?cat=307&sort=date&page=0&srch=&">RNA</a></li> <li><a href="/category/category.php?cat=420&sort=date&page=0&srch=&">Tissue</a></li> </ul> </div> <div class='item_category'> <span class='category_header'>Biocomputational focus</span> <ul> <li><a href="/category/category.php?cat=411&sort=date&page=0&srch=&">Experimental analysis</a></li> <li><a href="/category/category.php?cat=412&sort=date&page=0&srch=&">Image processing</a></li> <li><a href="/category/category.php?cat=426&sort=date&page=0&srch=&">Network modeling and analysis</a></li> <li><a href="/category/category.php?cat=409&sort=date&page=0&srch=&">Physics-based simulation</a></li> <li><a href="/category/category.php?cat=416&sort=date&page=0&srch=&">Statistical analysis</a></li> <li><a href="/category/category.php?cat=415&sort=date&page=0&srch=&">Visualization</a></li> </ul> </div> </div> <?php $arrCommunities = array(); $resCommunities = db_query_params('SELECT trove_cat_id, fullname FROM trove_cat ' . 'WHERE parent=1000 ' . 'ORDER BY trove_cat_id', array()); $cntCommunities = db_numrows($resCommunities); if ($cntCommunities > 0) { ?> <div class='module_category'> <h2>Communities</h2> <div class='item_category'> <ul> <?php } while ($theRow = db_fetch_array($resCommunities)) { $trove_cat_id = $theRow['trove_cat_id']; $fullname = $theRow['fullname']; echo '<li><a href="/category/communityPage.php?cat=' . $trove_cat_id . '&sort=date&page=0&srch=&">' . $fullname . '</a></li>'; } echo '<li><a href="/communities.php">See all communities...</a></li>'; if ($cntCommunities > 0) { ?> <ul> </div> </div> <?php } ?> <div class='module_home_news'> <h2>Jobs</h2> <div style="clear: both;"></div> <div class="item_home_news"> <h4><a href="/opportunities.php">See all job openings...</a></h4> </div> <div style="clear: both;"></div> </div> <div class='module_home_news'> <h2 id="news">News</h2> <?php // echo news_show_latest(0,10,true,false,false,-1, true); // echo news_show_latest(0,10,true,false,false,0,false); echo news_show_latest(0,5,true,false,false,0,false,true); ?> </div> </div> </div> <?php
0.980469
1
systems/language.php
agiletechvn/ninenine
0
14399796
<?php // +--------------------------------------------------------------------------+ // | Authors : <NAME> ; <NAME> | // | Email : <EMAIL>; <EMAIL> | // | Mobile : (+84) 936 885 466; (+84) 1214 149 420 | // | Date : 11/2011 | // | Website : http://maskfinalphp.com | // +--------------------------------------------------------------------------+ // | Copyrights (C) 2011 by MASKFINAL | // | All rights reserved | // +--------------------------------------------------------------------------+ $lang = array(); /** * @param $file * @return array */ function read_language($files){ $lang = array(); foreach($files as $file){ if(file_exists($file)){ $lines = file($file,FILE_SKIP_EMPTY_LINES); // Special char if(isset($lines[0][0]) && ord($lines[0][0]) === 239) $lines[0] = substr($lines[0], 3); $key = false; foreach($lines as $line){ $line = trim($line); if(!$line || $line[0] === '#') continue; if ($key){ $lang[$key] = $line; $key = false; } else $key = $line; } } } return $lang; } function extend_language($cache_path, $lang_files, $merge=TRUE){ global $lang; $time = 0; foreach($lang_files as $f) if(($t=@filemtime($f))>$time) $time = $t; if(!$time) return; $cache_file = $cache_path . LANGUAGE . "$time.php"; if(!file_exists($cache_file)){ $temp = read_language($lang_files); $lang = array_merge($lang, $temp); if($merge){ $content = array('<?php $lang=array('); foreach($temp as $k=>$v) $content[] = "'".str_replace("'", "\\'", $k)."'=>'" . str_replace("'", "\\'", $v) ."',"; $content[] = ');'; } else { $content = array('<?php '); foreach($temp as $k=>$v) $content[] = "\$lang['".str_replace("'", "\\'", $k)."']='" . str_replace("'", "\\'", $v) ."';"; } if(!is_dir($cache_path)) mkdir($cache_path); else { $files = scandir($cache_path); foreach($files as $file) if(substr($file,0,2) === LANGUAGE) unlink($cache_path . $file); } file_put_contents($cache_file, $content); $GLOBALS['compile_template'] = TRUE; }else // the cache file maybe include more than one during event driving process include_once($cache_file); } /** * utility functions * @param $str * @return string */ function t($str){ global $lang; return isset($lang[$str]) ? $lang[$str] : $str; }
1.554688
2
application/models/Avenant_partenaire_relai_model.php
rltbruce/api_paeb
0
14399804
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); class Avenant_partenaire_relai_model extends CI_Model { protected $table = 'avenant_partenaire_relai'; public function add($avenant_partenaire_relai) { $this->db->set($this->_set($avenant_partenaire_relai)) ->insert($this->table); if($this->db->affected_rows() === 1) { return $this->db->insert_id(); }else{ return null; } } public function update($id, $avenant_partenaire_relai) { $this->db->set($this->_set($avenant_partenaire_relai)) ->where('id', (int) $id) ->update($this->table); if($this->db->affected_rows() === 1) { return true; }else{ return null; } } public function _set($avenant_partenaire_relai) { return array( 'description' => $avenant_partenaire_relai['description'], 'ref_avenant' => $avenant_partenaire_relai['ref_avenant'], 'montant' => $avenant_partenaire_relai['montant'], 'date_signature' => $avenant_partenaire_relai['date_signature'], 'validation' => $avenant_partenaire_relai['validation'], 'id_contrat_partenaire_relai' => $avenant_partenaire_relai['id_contrat_partenaire_relai'] ); } public function delete($id) { $this->db->where('id', (int) $id)->delete($this->table); if($this->db->affected_rows() === 1) { return true; }else{ return null; } } public function findAll() { $result = $this->db->select('*') ->from($this->table) ->order_by('date_signature') ->get() ->result(); if($result) { return $result; }else{ return null; } } public function findById($id) { $this->db->where("id", $id); $q = $this->db->get($this->table); if ($q->num_rows() > 0) { return $q->row(); } } public function findAllByContrat_partenaire_relai($id_contrat_partenaire_relai) { $result = $this->db->select('*') ->from($this->table) ->where("id_contrat_partenaire_relai", $id_contrat_partenaire_relai) ->order_by('id') ->get() ->result(); if($result) { return $result; }else{ return null; } } public function getavenantBycontrat($id_contrat_partenaire_relai) { $result = $this->db->select('*') ->from($this->table) ->where("id_contrat_partenaire_relai", $id_contrat_partenaire_relai) ->order_by('id') ->get() ->result(); if($result) { return $result; }else{ return null; } } public function findavenantByContrat($id_contrat_partenaire_relai) { $result = $this->db->select('*') ->from($this->table) ->where("id_contrat_partenaire_relai", $id_contrat_partenaire_relai) ->order_by('id') ->get() ->result(); if($result) { return $result; }else{ return null; } } public function findavenantvalideByContrat($id_contrat_partenaire_relai) { $result = $this->db->select('*') ->from($this->table) ->where("id_contrat_partenaire_relai", $id_contrat_partenaire_relai) ->where("validation", 1) ->order_by('id') ->get() ->result(); if($result) { return $result; }else{ return null; } } public function findavenantvalideById($id_avenant_partenaire) { $result = $this->db->select('*') ->from($this->table) ->where("id", $id_avenant_partenaire) ->where("validation", 1) ->get() ->result(); if($result) { return $result; }else{ return null; } } public function findavenantinvalideByContrat($id_contrat_partenaire_relai) { $result = $this->db->select('*') ->from($this->table) ->where("id_contrat_partenaire_relai", $id_contrat_partenaire_relai) ->where("validation", 0) ->order_by('id') ->get() ->result(); if($result) { return $result; }else{ return null; } } }
1.28125
1
src/Util/ParamParser.php
cristianosoy/portal
1
14399812
<?php /** * UserFrosting (http://www.userfrosting.com) * * @link https://github.com/userfrosting/UserFrosting * @license https://github.com/userfrosting/UserFrosting/blob/master/licenses/UserFrosting.md (MIT License) */ namespace UserFrosting\Sprinkle\Portal\Util; use Interop\Container\ContainerInterface; use UserFrosting\Fortress\RequestDataTransformer; use UserFrosting\Fortress\RequestSchema; use UserFrosting\Fortress\ServerSideValidator; use UserFrosting\Sprinkle\Core\Util\EnvironmentInfo; use UserFrosting\Support\Exception\BadRequestException; /** * URL Parameter util class. * * @author <NAME> (https://schroeer.co) */ class ParamParser { /** * Get an object of our model by a given id url parameter. * * @param string $classMappingName The name of the model´s class mapping. * @param array $params An array of parameters including the id. * @return \UserFrosting\Sprinkle\Core\Database\Models\Model|null An instance of a model object. * @throws BadRequestException If the passed array with params does not contain the id. */ public static function getObjectById($classMappingName, array $params) { /** @var \Interop\Container\ContainerInterface $ci */ $ci = EnvironmentInfo::$ci; // Load the request schema $schema = new RequestSchema('schema://requests/get-by-id.json'); // Whitelist and set parameter defaults $transformer = new RequestDataTransformer($schema); $data = $transformer->transform($params); // Validate, and throw exception on validation errors. $validator = new ServerSideValidator($schema, $ci->translator); if (!$validator->validate($data)) { $ex = new BadRequestException(); foreach ($validator->errors() as $idx => $field) { foreach ($field as $eidx => $error) { $ex->addUserMessage($error); } } throw $ex; } /** @var \UserFrosting\Sprinkle\Core\Util\ClassMapper $classMapper */ $classMapper = $ci->classMapper; // Get the object by primary key $object = $classMapper->staticMethod($classMappingName, 'find', $data['id']); return $object; } }
1.671875
2
src/IceHockeyOffensiveStats/IIceHockeyOffensiveStatsRepository.php
elinoretenorio/php-crud-for-sports-db
0
14399820
<?php declare(strict_types=1); namespace Sports\IceHockeyOffensiveStats; interface IIceHockeyOffensiveStatsRepository { public function insert(IceHockeyOffensiveStatsDto $dto): int; public function update(IceHockeyOffensiveStatsDto $dto): int; public function get(int $id): ?IceHockeyOffensiveStatsDto; public function getAll(): array; public function delete(int $id): int; }
1.054688
1
resources/views/backend/cabinUserDetailsPopup.blade.php
sarathiscookie/cabinapi
0
14399828
<div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span> </button> <h4 class="modal-title">@lang("cabins.userUpdateModalHeading") <span class="sufixhfour"> &raquo {{ $user->cabin_name_append }} </span> </h4> </div> <div class="responseUpdateUserMessage"></div> <div class="modal-body"> <div class="row"> <div class="col-md-6"> <ul class="list-group"> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalFirstName") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrFirstname}} </span> </p></li> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalLastName") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrLastname}} </span> </p></li> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalEmail") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrEmail}} </span> </p></li> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalTelephone") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrTelephone}} </span> </p></li> </ul> </div> <div class="col-md-6"> <ul class="list-group"> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalMobile") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrMobile}} </span> </p></li> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalStreet") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrAddress}} </span> </p></li> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalZipcode") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrZip}} </span> </p></li> <li class="list-group-item"><h4 class="list-group-item-heading"> @lang("cabins.userUpdateModalCity") </h4> <p class="list-group-item-text"> <span class="modalvalDisplay"> {{ $user->usrCity}} </span> </p></li> </ul> </div> </div> </div> <div class="modal-footer"> <button type="button" class="btn btn-default" data-dismiss="modal">@lang("cabins.closeBtn") </button> </div>
0.933594
1
resources/views/images/create.blade.php
necococo/nani-neco2020
0
14399836
@extends('layouts.app') @section('content') {!! Form::open(['route' => 'images.store', 'files' => true ]) !!} {!! Form::file('file') !!} {!! Form::submit('Upload', ['class' => 'btn btn-success']) !!} {!! Form::close() !!} @endsection <!--<form action="{{ action('ImagesController@store') }}" method="post" enctype="multipart/form-data">--> <!-- <input type="file" name="file">--> <!-- {{ csrf_field() }}--> <!-- <input class="btn btn-primary" type="submit" value="Upload">--> <!--</form>-->
0.921875
1
views/nps-sales-survey/_form.php
copriwolf/questionS
0
14399844
<?php use yii\helpers\Html; use yii\widgets\ActiveForm; /* @var $this yii\web\View */ /* @var $model app\models\ModNpsSalesSurvey */ /* @var $form yii\widgets\ActiveForm */ ?> <div class="mod-nps-sales-survey-form"> <?php $form = ActiveForm::begin(); ?> <?= $form->field($model, 'Name')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'Phone')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'S1')->textInput() ?> <?= $form->field($model, 'S1Other')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'S2')->textInput() ?> <?= $form->field($model, 'S2Other')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'S3')->textInput() ?> <?= $form->field($model, 'S4')->textInput() ?> <?= $form->field($model, 'S5')->textInput() ?> <?= $form->field($model, 'A1')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A2')->textInput() ?> <?= $form->field($model, 'A3')->textInput() ?> <?= $form->field($model, 'A31')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42A1')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42A2')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42A3')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42A4')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42A5')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42B1')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42B2')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42B3')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42B4')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'A42B5')->textInput(['maxlength' => true]) ?> <?= $form->field($model, 'C1')->textInput() ?> <?= $form->field($model, 'C2')->textInput() ?> <?= $form->field($model, 'C3')->textInput() ?> <?= $form->field($model, 'C3Other')->textInput(['maxlength' => true]) ?> <div class="form-group"> <?= Html::submitButton($model->isNewRecord ? 'Create' : 'Update', ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']) ?> </div> <?php ActiveForm::end(); ?> </div>
1
1
app/Http/Controllers/WelcomeController.php
anashm/ProjetMedicaleMedisystem
0
14399852
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use Session; use Auth; class WelcomeController extends Controller { public function welcome(){ Auth::logout(); //Session::flush(); return view('welcome'); } }
0.738281
1
application/controllers/BarangCucian.php
wildanokt/oemah_laundry-backend
0
14399860
<?php defined('BASEPATH') or exit('No direct script access allowed'); require APPPATH . '/libraries/REST_Controller.php'; use Restserver\Libraries\REST_Controller; class BarangCucian extends REST_Controller { public function __construct() { parent::__construct(); $this->load->model('BarangCucian_model', 'barang'); header('Access-Control-Allow-Origin: *'); } public function index_get() { $id = $this->get('id'); if ($id == null) { $barang = $this->barang->getBarang(); if ($barang) { //success $this->response([ 'status' => true, 'data' => $barang, ], REST_Controller::HTTP_OK); } else { //fail $this->response([ 'status' => false, 'error' => 'Data kosong', ], REST_Controller::HTTP_NOT_FOUND); } } else { $barang = $this->barang->getBarangbyID($id); if ($barang) { //success $this->response([ 'status' => true, 'data' => $barang, ], REST_Controller::HTTP_OK); } else { //fail $this->response([ 'status' => false, 'error' => 'Data kosong', ], REST_Controller::HTTP_NOT_FOUND); } } } public function index_post() { $auth = [ 'username' => $this->post('usernameAdmin'), 'password' => $this->post('<PASSWORD>') ]; $arr = [ 'nama' => ucwords($this->post('barang')), 'harga' => $this->post('harga'), 'lama' => $this->post('lama') ]; // cek autentikasi dan cek field kosong if ($this->barang->authInsert($auth) && !(in_array(null, $arr, false))) { if ($this->barang->isNameUnique($arr['nama']) == false) { $this->response([ 'status' => false, 'message' => 'Nama barang sudah ada. Pilih nama yang lain', 'data' => $arr ], REST_Controller::HTTP_OK); } if ($this->barang->insertBarang($arr)) { $this->response([ 'status' => true, 'message' => 'Data berhasil dimasukkan', 'data' => $arr ], REST_Controller::HTTP_OK); } else { $this->response([ 'status' => false, 'message' => 'Data gagal dimasukkan', 'data' => $arr ], REST_Controller::HTTP_BAD_REQUEST); } } else { $this->response([ 'status' => false, 'message' => 'Illegal akses' ], REST_Controller::HTTP_BAD_REQUEST); } } }
1.171875
1
bbs/src/service/design/srv/model/link/PwDesignLinkDataService.php
asen477/trunksit.com
0
14399868
<?php Wind::import('SRV:design.srv.model.PwDesignModelBase'); /** * 门户数据 - 友情链接 * * @author jinlong.panjl <<EMAIL>> * @copyright ©2003-2103 phpwind.com * @license http://www.phpwind.com * @version $Id$ * @package wind */ class PwDesignLinkDataService extends PwDesignModelBase{ public function decorateAddProperty($model) { $data = array(); $data['linkType'] = $this->_getCateGorys(); return $data; } public function decorateEditProperty($moduleBo) { $model = $moduleBo->getModel(); $property = $moduleBo->getProperty(); $data = array(); $data['linkType'] = $this->_getCateGorys(); return $data; } protected function getData($field, $order, $limit, $offset) { Wind::import('SRV:link.vo.PwLinkSo'); $so = new PwLinkSo(); $so->setIfcheck(1); $field['linkType'] && $so->setTypeid($field['linkType']); $field['isLog'] != -1 && $so->setLogo($field['isLog']); $list = $this->_getLinkDs()->searchLink($so, $limit, $offset); if (!$list) return array(); foreach ($list AS $k => $v) { $list[$k]['lid'] = $v['lid']; $list[$k]['name'] = $this->_formatTitle($v['name']); $list[$k]['url'] = $v['url']; $list[$k]['logo'] = $v['logo']; $list[$k]['contact'] = $v['contact']; } return $list; } private function _getCateGorys(){ $cateGorys = $this->_getLinkDs()->getAllTypes(); $data = array(0 => '全部'); foreach ($cateGorys as $v) { $data[$v['typeid']] = $v['typename']; } return $data; } /** * PwLink * * @return PwLink */ private function _getLinkDs() { return Wekit::load('link.PwLink'); } } ?>
1.421875
1
application/views/report_monthly.php
woflramite/puskita
0
14399876
<head> <title>Puskita - Arsip</title> <meta charset="UTF-8"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script> </head> <style> .vertical-center { min-height: 200px; display: flex; align-items: center; } .navbar{ margin-bottom: 50px; } </style> <body style="background-color:#d8d8d8"> <!---------------------------------------------------JUMBOTRON---------------------------------------------------> <div class="jumbotron vertical-center" style="padding-left:10px"> <h2>Arsip Bulanan</h2> </div> <!---------------------------------------------------JUMBOTRON---------------------------------------------------> <!---------------------------------------------------SELECT DATE---------------------------------------------------> <div class="container-fluid" style="padding:40px 50px 40px 50px;background-color:white"> <form class="form-group" action="<?php echo base_url('report/archive'); ?>" method="post"><center> <table> <tr> <td> <font color="#FF0000"><?php echo form_error('month'); ?> <select class="form-control" name="month" id="month" value="<?php echo set_value('month');?>"> <option value="">Pilih Bulan</option> <option value="1">Januari</option> <option value="2">Februari</option> <option value="3">Maret</option> <option value="4">April</option> <option value="5">Mei</option> <option value="6">Juni</option> <option value="7">Juli</option> <option value="8">Agustus</option> <option value="9">September</option> <option value="10">Oktober</option> <option value="11">November</option> <option value="12">Desember</option> </select> </td> <td> <font color="#FF0000"><?php echo form_error('year'); ?> <select class="form-control" name="year" id="year" value="<?php echo set_value('year');?>"> <option value="">Pilih Tahun</option> <?php for ($i=2000; $i<=2017; $i++) { echo '<option value="'.$i.'">'.$i."</option>"; } ?> </select> </td> </tr> <tr> <td colspan="2"> <button type="submit" class="btn btn-primary btn-block">Lihat Arsip</button> </td> </tr> </table> <center></form> </div> <!---------------------------------------------------SELECT DATE---------------------------------------------------> </body>
0.898438
1
resources/views/welcome.blade.php
Pomoshhuk/diplom
0
14399884
@extends('layouts.app') @section('title') Тестирование студентов в ПГУ @stop @section('content') <div class="welcome"> <div class="welcome__header"> @if (isset($user)) Здравствуйте, {{$user['name']}}.<br> @endif Добро пожаловать на главную страницу приложения тестирования студентов</div> <div class="welcome__support"> @if (isset($role)) @if ($role=='teacher') <a href="/test" class="welcome__btn welcome__btn--solo">Перейти к созданию тестов</a> @elseif ($role=='user') <a href="/pass" class="welcome__btn welcome__btn--solo">Просмотр тестов на прохождение</a> @endif @else <a class="welcome__btn" href="/register">Зарегистрируйтесь</a> или <a class="welcome__btn" href="/login">войдите</a> в свою учетную запись! @endif </div> </div> @stop
0.980469
1
application/controllers/transaksi.php
pancasona28/RPLBO-
0
14399892
<?php defined('BASEPATH') OR exit('No direct script access allowed'); class Transaksi extends CI_Controller { public function __construct() { parent::__construct(); $this->load->model('m_transaksi'); } public function tambah() { $isi['content'] = 'backend/transaksi/t_transaksi'; $isi['judul'] = 'Form Tambah Transaksi'; $isi['konsumen']= $this->db->get('konsumen')->result(); $isi['paket']= $this->db->get('paket')->result(); $isi['kode_transaksi'] = $this->m_transaksi->generateKode(); $this->load->view('backend/dashboard', $isi); } public function getHargaPaket() { $kode_paket = $this->input->post('kode_paket'); $data = $this->m_transaksi->getHargaPaket($kode_paket); echo json_encode($data); } public function simpan() { $data = array( 'kode_transaksi' => $this->input->post('kode_transaksi'), 'kode_konsumen' => $this->input->post('kode_konsumen'), 'kode_paket' => $this->input->post('kode_paket'), 'tgl_masuk' => $this->input->post('tgl_masuk'), 'tgl_ambil' => '', 'berat' => $this->input->post('berat'), 'grand_total' => $this->input->post('grand_total'), 'bayar' => $this->input->post('bayar'), 'status' => $this->input->post('status') ); $query = $this->db->insert('transaksi', $data); if ($query = true) { $this->session->set_flashdata('info', 'Data Transaksi Berhasil di Simpan'); redirect('transaksi/tambah','refresh'); } } public function riwayat() { $isi['content'] = 'backend/transaksi/riwayat_transaksi'; $isi['judul'] = 'Riwayat Transaksi'; $isi['data'] = $this->m_transaksi->getAllRiwayat(); $this->load->view('backend/dashboard', $isi); } public function update_status() { $kode_transaksi = $this->input->post('kt'); $status = $this->input->post('stt'); $tgl_ambil = date('Y-m-d h:i:s'); $status_bayar = 'Lunas'; if ($status == "Baru" OR $status == "Proses") { $this->m_transaksi->update_status($kode_transaksi, $status); }else{ $this->m_transaksi->update_status1($kode_transaksi, $status, $tgl_ambil, $status_bayar); } } public function edit_transaksi($kode_transaksi) { $isi['content'] = 'backend/transaksi/edit_transaksi'; $isi['judul'] = 'Form Edit Transaksi'; $isi['transaksi'] = $this->m_transaksi->edit_transaksi($kode_transaksi); $isi['konsumen'] = $this->db->get('konsumen')->result(); $isi['paket'] = $this->db->get('paket')->result(); $this->load->view('backend/dashboard', $isi); } public function update() { $kode_transaksi = $this->input->post('kode_transaksi'); $data = array( 'kode_transaksi' => $this->input->post('kode_transaksi'), 'kode_konsumen' => $this->input->post('kode_konsumen'), 'kode_paket' => $this->input->post('kode_paket'), 'tgl_masuk' => $this->input->post('tgl_masuk'), 'tgl_ambil' => '', 'berat' => $this->input->post('berat'), 'grand_total' => $this->input->post('grand_total'), 'bayar' => $this->input->post('bayar'), 'status' => $this->input->post('status') ); $query = $this->m_transaksi->update($kode_transaksi, $data); if ($query = true) { $this->session->set_flashdata('info', 'Data Transaksi Berhasil di Update'); redirect('transaksi/riwayat','refresh'); } } public function detail($kode_transaksi) { $this->load->library('dompdf_gen'); $isi['transaksi'] = $this->m_transaksi->detail($kode_transaksi); $this->load->view('backend/transaksi/detail', $isi); $paper_size = 'A5'; $orientation = 'landscape'; $html = $this->output->get_output(); $this->dompdf->set_paper($paper_size, $orientation); $this->dompdf->load_html($html); $this->dompdf->render(); $this->dompdf->stream("Detail Transaksi", array('Attachment' =>0)); } }
1.164063
1
resources/views/backend/dashboard/galeri/add.blade.php
bayuuv/tepat
0
14399900
@include('backend.dashboard.templates.header2') <!-- partial end --> <div class="container-fluid page-body-wrapper"> <!-- partial:partials/_sidebar.html --> @include('backend.dashboard.templates.sidebar') <!-- partial end --> <!-- content-wrapper start --> <div class="main-panel"> <div class="content-wrapper"> <div class="page-header"> <h3 class="page-title"> <span class="page-title-icon bg-gradient-primary text-white mr-2"> <i class="mdi mdi-account-group"></i> </span> Tambah Galeri </h3> <nav aria-label="breadcrumb"> <ul class="breadcrumb"> <a href="{{url('setting-pages/galeri')}}">Galeri</a>&nbsp;/&nbsp;Tambah Galeri baru </ul> </nav> </div> @if(Session::has('message')) <div class="alert alert-success" role="alert"> <strong>{{ Session::get('message') }}</strong> </div> @endif <div class="row"> <div class="col-12 grid-margin stretch-card"> <div class="card"> <div class="card-body"> <h4 class="card-title">Galeri</h4> <p class="card-description"> Tambah Galeri baru </p> <form action="{{url('setting-pages/galeri/store')}}" class="forms-sample" method="POST" enctype="multipart/form-data"> {{ csrf_field() }} <div class="row"> <div class="col"> <div class="form-group"> <label for="exampleInputJudul">Judul</label>&nbsp<label style="color:red;">{{$errors->first('judul')}}</label> <input type="text" class="form-control" id="exampleInputJudul" name="judul" placeholder="Judul" value="{{ old('judul') }}"> </div> <div class="form-group"> <label>Cover</label> <input type="file" name="cover_file" class="file-upload-default"> <div class="input-group col-xs-12"> <input type="text" class="form-control file-upload-info" name="img_cover" placeholder="Unggah cover"> <span class="input-group-append"> <button class="file-upload-browse btn btn-gradient-primary" type="button">Upload</button> </span> </div> </div> <div class="form-group"> <label for="inputIsi">Gambar</label>&nbsp<label style="color:red;">{{$errors->first('gambar')}}</label> <input type="file" id="gambar" name="gambar[]" accept=".jpg, .png, .jpeg" multiple> </div> <div class="form-group"> <label for="exampleInputVideo">Link</label>&nbsp<label style="color:red;">{{$errors->first('video')}}</label> <input type="text" class="form-control" id="exampleInputVideo" name="video" placeholder="Link Video Youtube" value="{{ old('video') }}"> </div> <div class="form-group"> <label for="ket">Keterangan</label>&nbsp<label style="color:red;">{{$errors->first('ket')}}</label> <textarea name="ket" id="ket"></textarea> <script type="text/javascript"> var editor = CKEDITOR.replace('ket'); CKFinder.setupCKEditor(editor); </script> </div> <div class="form-group"> <label for="exampleInputTipe">Tipe</label>&nbsp<label style="color:red;">{{$errors->first('tipe')}}</label> <select class="form-control" id="exampleInputTipe" name="tipe"> <option>Pilih Tipe</option> <option value="gambar">Gambar</option> <option value="video">Video</option> </select> </div> </div> </div> <button type="submit" class="btn btn-gradient-primary mr-2">Simpan</button> <a href="{{url('setting-pages/galeri')}}" class="btn btn-light">Batal</a> </form> </div> </div> </div> </div> </div> <!-- content-wrapper ends --> @include('backend.dashboard.templates.footer2')
0.957031
1
app/Models/Subject.php
Mohamed-Hassan-M-M/teachers
0
14399908
<?php namespace App\Models; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Carbon; class Subject extends Model { protected $fillable = [ 'name_ar', 'name_en', 'class_id' ]; protected $appends = [ 'name' ]; public function getCreatedAtAttribute($key) { return Carbon::parse($this->attributes['created_at'])->format('Y/m/d'); } public function getNameAttribute($key) { return $this->attributes['name_'.app()->getLocale()]; } /* relations*/ public function classes() { return $this->belongsTo(Classes::class, 'class_id', 'id'); } public function teachers() { return $this->belongsToMany(User::class, 'teacher_subjects', 'subject_id', 'teacher_id')->where('type', '2'); } }
1.257813
1
src/Intl/LanguageSwitcher.php
ukrainian-model-association/webapp-legacy
0
14399916
<?php namespace App\Intl; use session; class LanguageSwitcher { public function __construct() { } public static function create() { return new self(); } public function __toString() { $selectors = array_map([$this, 'createLanguageSelector'], [LanguageTypes::RU, LanguageTypes::EN]); return sprintf('<div class="btn-group" role="group" aria-label="Language Switcher">%s</div>', PHP_EOL . implode(PHP_EOL, $selectors) . PHP_EOL); } public function createLanguageSelector($language) { $className = 'light'; if (session::get('language') === $language) { $className = 'dark'; } return sprintf('<a href="/sign/language?code=%s" class="btn btn-sm btn-%s">%s</a>', strtolower($language), $className, strtoupper($language)); } }
1.203125
1
database/migrations/2020_12_03_071704_update_master_pre.php
Icareconnect/Backend
0
14399924
<?php use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; class UpdateMasterPre extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::table('master_preferences', function (Blueprint $table) { $table->string('show_on')->comment('both,sp,user')->default('both'); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::table('master_preferences', function (Blueprint $table) { $table->dropColumn('show_on'); }); } }
0.996094
1
app/Http/Controllers/ProveedorController.php
DryMemoG/Apiproyecto
0
14399932
<?php namespace App\Http\Controllers; use App\Proveedor; use Illuminate\Http\Request; use Illuminate\Support\Facades\Validator; class ProveedorController extends Controller { public function index(Request $request) { $info = Proveedor::all(); return response()->json([ 'success' => true, 'message' =>'Listado de proveedores', 'data' => $info ], 200); } public function show($id) { try { $info = Proveedor::where('idproveedor','=',$id)->firstOrFail(); return response()->json([ 'success' => true, 'message' =>'Proveedor buscado', 'data' => $info ], 200); } catch (\Throwable $th) { return response()->json(['message' => "El proveedor numero {$id} no existe"], 404); } } //fin de show public function store(Request $request) { $this->Validate($request, [ 'nombreproveedor' => 'required', 'direccion' => 'required', 'NIT' => 'required', 'fechacontrato' =>'required' ]); $info = Proveedor::wherenombreproveedor($request->get('nombreproveedor')) ->first(); if($info) { return response()->json(['message' => "El Proveedor{$request->get('nombreproveedor')} ya existe"], 404); } $input = $request->all(); Proveedor::create($input); return response()->json([ 'success' => true, 'message' =>'Registro insertado correctamente' ], 200); }//fin funcion store public function update($id, Request $request) { try{ $info = TipoProducto::where('idproveedor','=',$id)->firstOrFail(); TipoProducto::where('idproveedor', $id) ->update(['nombreproveedor'=>$request->get('nombreproveedor'), 'direccion'=>$request->get('direccion'), 'impuesto'=>$request->get('impuesto'), 'NIT'=>$request->get('NIT'), 'fechachontrato'=>$request->get('fechacontrato'),]); return response()->json([ 'success' => true, 'message' =>'Registro actualizado correctamente' ], 200); } catch(\Throwable $th){ return response()->json(['message' => "El Proveedor numero {$id} no existe"], 404); } } }
1.398438
1
resources/lang/en/controller_cabinet.php
dagoba/amazon-prj
0
14399940
<?php return [ 'standard_error' => 'An error has occurred. Contact the site administration.', /** * ActiveTicketMessagesController.php */ 'active_ticket_messages_message' => 'Enter a message to send.', 'active_ticket_messages_success' => 'Message sent. Wait for a response from the support service.', /** * ActiveTicketsController.php */ 'active_tickets_success' => 'Ticket closed.', /** * AddTicketsController.php */ 'add_tickets_theme' => 'Please enter a topic name for the ticket.', 'add_tickets_message' => 'Please enter a message for the ticket.', 'add_tickets_success' => 'New ticket added. Wait for a response from the support service.', /** * AllshopsController.php */ 'all_shops_rate' => 'You must fill in "your attachment" field.', 'all_shops_no_money' => 'There are not enough funds in your account.', 'all_shops_min_sum' => 'Minimum bid amount for this position', /** * BalanceDepositController.php */ 'balance_deposit_min_sum' => 'The minimum amount of replenishment must be at least 0.01 $.', 'balance_deposit_success' => 'Application for refill successfully created.', /** * BalanceWithdrawalController.php */ 'balance_withdrawal_success' => 'Request for withdrawal successfully created.', 'balance_withdrawal_no_money' => 'There are not enough funds in your account.', 'balance_withdrawal_min_sum' => 'The minimum withdrawal amount must be at least $ 1.', /** * CabinetController.php */ 'cabinet_name' => 'The field "USERNAME" should not be empty.', 'cabinet_email' => 'The field "EMAIL ADDRESS" must not be empty.', 'cabinet_success' => 'Your data has been successfully changed.', /** * ChangepasswordController.php */ 'change_password_current' => 'Please enter current password.', 'change_password_password' => 'Please enter password.', 'change_password_success' => 'The change was successful.', 'change_password_correct_current' => 'Please enter correct current password.', ];
0.478516
0
protected/components/Profile.php
RickAQ-Dev/yii_ent_system
0
14399948
<?php class Profile extends CWidget { private $_user; public function init() { $this->_user = Yii::app()->user; } public function run() { $this->render('Profile/profile', array( 'user' => $this->_user )); } }
1.007813
1
src/Controller/PicturesController.php
mecbil/SnowTricks
1
14399956
<?php namespace App\Controller; use App\Entity\Pictures; use App\Form\PicturesType; use App\Entity\Vids; use App\Form\VidsType; use App\Entity\Comments; use App\Form\CommentsType; use App\Entity\Tricks; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Symfony\Component\HttpFoundation\Response; use Symfony\Component\Routing\Annotation\Route; use Doctrine\Persistence\ManagerRegistry; use Symfony\Component\HttpFoundation\Request; class PicturesController extends AbstractController { /** * @Route("/pictures/delete/{id}", name="pictures_delete") */ public function delete($id, ManagerRegistry $doctrine): Response { $repopicture = $doctrine->getRepository(Pictures::class); $picture = $repopicture->find($id); $em = $doctrine->getManager(); $em->remove($picture); $em->flush(); return $this->redirectToRoute('tricks_show', [ 'id' => ($picture->getTricks())->getId(), ]); } /** * @Route("/pictures/edit/{id}", name="pictures_edit") */ public function edit(Pictures $picture, Request $request, ManagerRegistry $doctrine): Response { $idtricks = $picture->getTricks(); $repotricks = $doctrine->getRepository(Tricks::class); $tricks = $repotricks->find($idtricks); $repocomments = $doctrine->getRepository(Comments::class); $allcomments = $repocomments->findBy(['tricks' => $idtricks], ['created_at' => 'DESC']); $formpicture = $this->createForm(PicturesType::class, $picture); $formpicture->handleRequest($request); if ($formpicture->isSubmitted() && $formpicture->isValid()) { // Traitement de l'image $file = $formpicture->get('link')->getData(); $fichier = $file->getClientOriginalName(); // moves the file to the directory where images are stored $file->move( $this->getParameter('images_directory'), $fichier ); $picture->setLink($fichier); $em = $doctrine->getManager(); $em->flush(); return $this->redirectToRoute('tricks_show', [ 'onglet' => '', 'id' => ($picture->getTricks())->getId(), ]); } $vids = new Vids(); $formvids = $this->createForm(VidsType::class, $vids); $comments = new Comments(); $formcomments = $this->createForm(CommentsType::class, $comments); return $this->render('tricks/showonetricks.html.twig', [ 'onglet' => 'imgage', 'subvid' => $vids->getId() !== null, 'subim' => $picture->getId() !== null, 'id' => ($picture->getTricks())->getId(), 'activee' => 'Connexion', 'Tricks' => $tricks, 'formpictures' => $formpicture->createView(), 'formvids' => $formvids->createView(), 'formcomments' => $formcomments->createView(), 'comments' => $allcomments, ]); } }
1.234375
1
Module/Book/Domain/Entities/ChapterEntity.php
zx648383079/PHP-WeChat
0
14399964
<?php namespace Module\Book\Domain\Entities; use Domain\Entities\Entity; /** * Class ChapterEntity * @package Module\Book\Domain\Entities * @property integer $id * @property string $title 章节名 * @property string $content 章节内容 * @property boolean $is_vip vip章节 * @property float $price 章节价格 * @property integer $book_id * @property integer $type * @property integer $parent_id * @property integer $status * @property integer $position * @property integer $size * @property integer $deleted_at * @property integer $updated_at * @property integer $created_at */ class ChapterEntity extends Entity { public static function tableName() { return 'book_chapter'; } protected function rules() { return [ 'book_id' => 'int', 'title' => 'required|string:0,200', 'parent_id' => 'int', 'price' => 'int', 'status' => 'int:0,127', 'position' => 'int', 'type' => 'int:0,127', 'size' => 'int', 'source' => 'string:0,200', 'deleted_at' => 'int', 'created_at' => 'int', 'updated_at' => 'int', ]; } protected function labels() { return [ 'id' => 'Id', 'book_id' => '书', 'title' => '标题', 'parent_id' => '上级', 'position' => '排序', 'status' => '状态', 'source' => '来源', 'size' => '字数', 'deleted_at' => '删除时间', 'created_at' => '发布时间', 'updated_at' => '更新时间', ]; } }
1.289063
1
resources/views/partials/charging.blade.php
thwolter/ctrade
0
14399972
<div class="form-group row"> {!! Form::label('deduct', 'Verrechnen', ['class' => 'col-md-2 offset-md-1 col-form-label']) !!} <div class="col-md-8"> <div class="checkbox"> {!! Form::checkbox('deduct', 'yes', true) !!} <span style="padding-left: 7px">Mit Cashbestand verrechnen</span> </div> <div class="space-10"></div> <p class="help-block"> Anklicken, wenn die neue Position den Cashbestand des Portfolios reduzieren soll. Oder freilassen, wenn die Position den Portfoliowert erhöhen soll. </p> </div> </div>
0.472656
0
MessageCachePerformance.php
Wikia/mediawiki-extensions-MessageCachePerformance
0
14399980
<?php // Copyright 2021 Fandom, Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. use AhoCorasick\MultiStringMatcher; class MessageCachePerformance { /** * Prefixes for messages that are known not to exist in core/extensions and are not user-customizable. */ private const NONEXISTENT_MSG_PREFIXES = [ // Special:SpecialPages and GlobalShortcuts 'specialpages-specialpagegroup-', // Used by SkinTemplate for Vector <-> Monobook B/C 'oasis-view-', 'oasis-action-', 'apioutput-view-', 'fallback-view-', 'mobileve-view-', 'fandommobile-view-', 'hydra-view-', 'hydra-action-', 'hydradark-view-', 'hydradark-action-', 'minerva-view-', 'minerva-action-', 'exvius-view-', 'exvius-action-', // LanguageConverter 'conversion-ns', // Linker 'tooltip-', 'accesskey-', // SkinTemplate namespace tab navigation 'nstab-', ]; /** * Map of known message keys defined by core/extensions (key => true) * @var bool[] $knownMsgKeys */ private static $knownMsgKeys; /** * Matcher for NONEXISTENT_MSG_PREFIXES * @var MultiStringMatcher $notExistentMsgMatcher */ private static $notExistentMsgMatcher; /** * Hook: MessageCache::get * Due to https://phabricator.wikimedia.org/T193271, lookups for messages that are not defined in core/extensions * and are not customized on the wiki trigger memcached/APCu lookups. This can be quite expensive when many wikis * and messages are involved. * * This hook catches the most common messages being looked up that are known not to exist, and short-circuits the * MessageCache lookup by explicitly designating them as nonexistent. * * @see MessageCache::get() * * @param string &$lcKey message key being looked up */ public static function onMessageCacheGet( &$lcKey ): bool { $knownMsgKeys = self::getKnownMsgKeys(); // Message is known to exist in code - nothing to do. if ( isset( $knownMsgKeys[$lcKey] ) ) { return true; } // The message is known to not exist in code and cannot be customized if ( self::getNotExistentMsgMatcher()->searchIn( $lcKey ) ) { return false; } return true; } /** * Preload all known message keys defined by core/extensions * @return bool[] map of message key => true */ private static function getKnownMsgKeys(): array { if ( !self::$knownMsgKeys ) { global $wgLanguageCode; self::$knownMsgKeys = array_flip( Language::getMessageKeysFor( $wgLanguageCode ) ); } return self::$knownMsgKeys; } private static function getNotExistentMsgMatcher(): MultiStringMatcher { if ( !self::$notExistentMsgMatcher ) { self::$notExistentMsgMatcher = new MultiStringMatcher( self::NONEXISTENT_MSG_PREFIXES ); } return self::$notExistentMsgMatcher; } }
1.234375
1
controllers/ApiController.php
camilo-nguyen-goldenowl/YiiProject
0
14399988
<?php namespace app\controllers; use Yii; use app\models\Posts; use app\models\PostsSearch; use yii\base\BaseObject; use yii\filters\auth\HttpBearerAuth; use yii\rest\ActiveController; use yii\web\Controller; use yii\web\NotFoundHttpException; use yii\filters\VerbFilter; /** * PostsController implements the CRUD actions for Posts model. */ class ApiController extends ActiveController { public function actions() { $actions = parent::actions(); unset($actions['create']); unset($actions['update']); unset($actions['delete']); unset($actions['view']); unset($actions['index']); return $actions; } public function behaviors() { $behaviors = parent::behaviors(); $behaviors['authenticator'] = [ 'class' => HttpBearerAuth::className(), ]; return $behaviors; } }
1.078125
1
resources/views/backend/colloques/confirmation.blade.php
droitformation/webshop
0
14399996
@extends('backend.layouts.master') @section('content') <p><a href="{{ url('admin/colloque/'.$colloque->id) }}" class="btn btn-default"><i class="fa fa-arrow-left"></i> &nbsp;Retour au colloque</a></p> <div class="row"> <div class="col-md-12"> <h3 class="text-info">Confirmer et envoyer les liens aux emails</h3> </div> </div> <div class="row"> <div class="col-md-8"> <div class="panel panel-default"> <div class="panel-body"> <h3>Colloque:</h3> @if(!$emails->isEmpty()) <div class="well well-sm" style="padding: 5px 10px;"> <div class="row"> <div class="col-md-8"> <h3 style="margin-bottom: 0;"><strong>{{ $colloque->titre }}</strong></h3> </div> <div class="col-md-4 text-right"> <form action="{{ url('admin/slide/send') }}" method="POST">{!! csrf_field() !!} <input type="hidden" name="colloque_id" value="{{ $colloque->id }}"> <button class="btn btn-primary">Envoyer les liens</button> </form> </div> </div> </div> <h3>Emails:</h3> <ul> @foreach($emails as $email) <li>{{ $email }}</li> @endforeach </ul> @else <p class="text-danger"><i class="fa fa-exclamation-triangle"></i> &nbsp;Aucun email dans cette liste</p> @endif </div> </div> </div> </div> @stop
1.039063
1