al-rimi/submit 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

al-rimi/submit

最新稳定版本:v1.5.4

Composer 安装命令:

composer require al-rimi/submit

包简介

A simple submission system for managing student submissions.

README 文档

README

A simple and customizable system for managing submissions. Designed for Laravel applications, it offers essential tools to streamline submission processes with minimal setup.

Installation

Step 1: Install the Package

composer require al-rimi/submit

Step 2: Run the Installation Command

php artisan submit:install
This command performs the following tasks:
  1. Publishes assets, views, and configuration files.
  2. Installs necessary Node.js dependencies.
  3. Updates the vite.config.js file with Submit assets (submit.css and submit.js).
  4. Builds assets using npm run build.
  5. Runs database migrations.
  6. Seeds the database with example data.

Features

  • Submission Management: Collect, validate, and store student submissions effectively.
  • Email Notifications: Rreceive notifications after each submission.
  • Dynamic Table Management: Displays and updates student submissions dynamically without page reloads.
  • Auto-fill: Custom JS script for client side auto fill.
  • UI: vanilla CSS with simple animations and clean look..

Customization

Environment Variables

To enable submission notifications and set a deadline, add the following variables to your .env file:

NOTIFICATION_EMAIL=      # Email address to receive submission notifications  
SUBMISSION_DEADLINE=     # Submission deadline in ISO 8601 format (e.g., "YYYY-MM-DDTHH:MM:SS")  

Routes

The package publishes its routes to routes/submit.php. You can customize these routes to:

  • Change view paths.
  • Add middleware for additional security or access control.

Views

All customizable views are published to your project for easy modification:

  • Submission Page: resources/views/submissions.blade.php
  • Email Template: resources/views/emails/submissions_email.blade.php

CSS and JavaScript

dependency-free assets for styling and interactivity in vanilla CSS and JavaScript:

  • CSS File: resources/css/submit.css
  • JavaScript File: resources/js/submit.js

Database

The package provides database migrations and a sample seeder to kickstart your setup:

  • Migrations: Automatically created tables for submission data.
  • Seeder: database/Seeders/StudentsTableSeeder.php populates the database with example records.

Troubleshooting

Vite Configuration

The package automatically adds resources/css/submit.css and resources/js/submit.js to vite.config.js. If this step fails, manually update your vite.config.js file:

export default defineConfig({
    input: [
        'resources/css/app.css',
        'resources/js/app.js',
        'resources/css/submit.css',
        'resources/js/submit.js'
    ],
    // other Vite configuration
});
Build Issues

If you encounter build issues, ensure Node.js and npm are properly installed. Then rerun:

npm install
npm run build

Uninstallation

Step 1: Remove all traces of the Submit package:

php artisan submit:uninstall

Step 2: remove the package:

composer remove al-rimi/submit

Requirements

  • PHP 8.0 or higher
  • Laravel 10.x or 11.x
  • Node.js (for Vite asset compilation)

Have questions or facing issues? Check out the issues page.

License

This package is open-source and is licensed under the MIT License.

统计信息

  • 总下载量: 27
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 4
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-11-17

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固