upload image

This commit is contained in:
2020-12-04 11:07:12 +07:00
parent 4187fc7239
commit df39cdf602
10 changed files with 60 additions and 4 deletions

View File

@@ -172,4 +172,15 @@ class ListManagementController extends Controller {
}
}
public function actionUpload() {
if (Yii::$app->request->post()) {
$model = new common();
Yii::$app->response->format = "json";
return [
"dataPath" => "BiFace/",
"url" => $model->UploadFile("AnhNhanVien", ["PNG", "JPG", "JPEG", "GIF"], "temp")
];
}
}
}