# basic syntax
get 'home/index', to: 'home#index' # localhost:3000/home/index
get 'home/index' # localhost:3000/home/index
# set default controller for home page
root 'home#index'
root to: 'home#index'
- Validations are used to ensure that only valid data is saved into your database.
Database constriants
:database-dependent
, testing and maintenance difficultClient-side validation
:unreliable
, immediate feedback on the client-sideController-level validation
: difficult to test and maintain, controller should beslim
create
andcreate!
save
andsave!
import re,pymongo,time,os
import pandas as pd
import warnings; warnings.simplefilter('ignore')
from fontTools.ttLib import TTFont
from fontTools.unicode import unichr
from config import *
from pyquery import PyQuery as pq
from aip import AipOcr
from PIL import Image
NewerOlder